RTEMS 4.11
Annotated Report
Fri Jun 13 12:23:23 2014

4000b81c <IMFS_chown>: int IMFS_chown( const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group ) {
4000b81c:	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();                                                 
4000b820:	40 00 02 5c 	call  4000c190 <geteuid>                       
4000b824:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
                                                                      
  if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )               
4000b828:	c2 17 60 3c 	lduh  [ %i5 + 0x3c ], %g1                      
4000b82c:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
4000b830:	91 32 20 10 	srl  %o0, 0x10, %o0                            
4000b834:	80 a2 00 01 	cmp  %o0, %g1                                  
4000b838:	02 80 00 0a 	be  4000b860 <IMFS_chown+0x44>                 <== ALWAYS TAKEN
4000b83c:	80 a2 20 00 	cmp  %o0, 0                                    
4000b840:	22 80 00 09 	be,a   4000b864 <IMFS_chown+0x48>              <== NOT EXECUTED
4000b844:	f2 37 60 3c 	sth  %i1, [ %i5 + 0x3c ]                       <== NOT EXECUTED
    rtems_set_errno_and_return_minus_one( EPERM );                    
4000b848:	40 00 10 76 	call  4000fa20 <__errno>                       <== NOT EXECUTED
4000b84c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4000b850:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
4000b854:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4000b858:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000b85c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
#endif                                                                
                                                                      
  jnode->st_uid = owner;                                              
4000b860:	f2 37 60 3c 	sth  %i1, [ %i5 + 0x3c ]                       
  jnode->st_gid = group;                                              
4000b864:	f4 37 60 3e 	sth  %i2, [ %i5 + 0x3e ]                       
                                                                      
static inline void IMFS_update_ctime( IMFS_jnode_t *jnode )           
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
4000b868:	90 07 bf f8 	add  %fp, -8, %o0                              
4000b86c:	7f ff e0 12 	call  400038b4 <gettimeofday>                  
4000b870:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_ctime = now.tv_sec;                                     
4000b874:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000b878:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
                                                                      
  IMFS_update_ctime( jnode );                                         
                                                                      
  return 0;                                                           
}                                                                     
4000b87c:	81 c7 e0 08 	ret                                            
4000b880:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40006108 <IMFS_dump_directory>: */ static void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) {
40006108:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000610c:	fa 06 20 50 	ld  [ %i0 + 0x50 ], %i5                        
        the_node = the_node->next ) {                                 
                                                                      
    the_jnode = (IMFS_jnode_t *) the_node;                            
                                                                      
    for ( i=0 ; i<=level ; i++ )                                      
      fprintf(stdout, "...." );                                       
40006110:	37 10 00 90 	sethi  %hi(0x40024000), %i3                    
    case IMFS_FIFO:                                                   
      fprintf(stdout, " FIFO not printed\n" );                        
      return;                                                         
                                                                      
    default:                                                          
      fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) );     
40006114:	35 10 00 90 	sethi  %hi(0x40024000), %i2                    
)                                                                     
{                                                                     
  IMFS_assert( the_jnode );                                           
                                                                      
  fprintf(stdout, "%s", the_jnode->name );                            
  switch( IMFS_type( the_jnode ) ) {                                  
40006118:	21 10 00 18 	sethi  %hi(0x40006000), %l0                    
                                                                      
    default:                                                          
      fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) );     
      return;                                                         
  }                                                                   
  puts("");                                                           
4000611c:	23 10 00 91 	sethi  %hi(0x40024400), %l1                    
    case IMFS_SYM_LINK:                                               
      fprintf(stdout, " links not printed\n" );                       
      return;                                                         
                                                                      
    case IMFS_FIFO:                                                   
      fprintf(stdout, " FIFO not printed\n" );                        
40006120:	25 10 00 90 	sethi  %hi(0x40024000), %l2                    
        the_node = the_node->next ) {                                 
                                                                      
    the_jnode = (IMFS_jnode_t *) the_node;                            
                                                                      
    for ( i=0 ; i<=level ; i++ )                                      
      fprintf(stdout, "...." );                                       
40006124:	b6 16 e0 18 	or  %i3, 0x18, %i3                             
    case IMFS_FIFO:                                                   
      fprintf(stdout, " FIFO not printed\n" );                        
      return;                                                         
                                                                      
    default:                                                          
      fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) );     
40006128:	b4 16 a0 88 	or  %i2, 0x88, %i2                             
)                                                                     
{                                                                     
  IMFS_assert( the_jnode );                                           
                                                                      
  fprintf(stdout, "%s", the_jnode->name );                            
  switch( IMFS_type( the_jnode ) ) {                                  
4000612c:	a0 14 20 ec 	or  %l0, 0xec, %l0                             
                                                                      
    default:                                                          
      fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) );     
      return;                                                         
  }                                                                   
  puts("");                                                           
40006130:	a2 14 60 a0 	or  %l1, 0xa0, %l1                             
    case IMFS_SYM_LINK:                                               
      fprintf(stdout, " links not printed\n" );                       
      return;                                                         
                                                                      
    case IMFS_FIFO:                                                   
      fprintf(stdout, " FIFO not printed\n" );                        
40006134:	a4 14 a0 70 	or  %l2, 0x70, %l2                             
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(                             
  const Chain_Control *the_chain,                                     
  const Chain_Node    *the_node                                       
)                                                                     
{                                                                     
  return (the_node == _Chain_Immutable_tail( the_chain ));            
40006138:	82 06 20 54 	add  %i0, 0x54, %g1                            
  IMFS_assert( level >= 0 );                                          
  IMFS_assert( IMFS_is_directory( the_directory ) );                  
                                                                      
  the_chain = &the_directory->info.directory.Entries;                 
                                                                      
  for ( the_node = rtems_chain_first( the_chain );                    
4000613c:	80 a7 40 01 	cmp  %i5, %g1                                  
40006140:	02 80 00 5c 	be  400062b0 <IMFS_dump_directory+0x1a8>       
40006144:	b8 10 20 00 	clr  %i4                                       
        !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++ )                                      
40006148:	80 a7 00 19 	cmp  %i4, %i1                                  
4000614c:	14 80 00 09 	bg  40006170 <IMFS_dump_directory+0x68>        
40006150:	01 00 00 00 	nop                                            
      fprintf(stdout, "...." );                                       
40006154:	7f ff ec 56 	call  400012ac <__getreent>                    
40006158:	b8 07 20 01 	inc  %i4                                       
4000615c:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           
40006160:	40 00 39 5a 	call  400146c8 <fputs>                         
40006164:	90 10 00 1b 	mov  %i3, %o0                                  
        !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++ )                                      
40006168:	10 bf ff f9 	b  4000614c <IMFS_dump_directory+0x44>         
4000616c:	80 a7 00 19 	cmp  %i4, %i1                                  
  IMFS_jnode_t *the_jnode                                             
)                                                                     
{                                                                     
  IMFS_assert( the_jnode );                                           
                                                                      
  fprintf(stdout, "%s", the_jnode->name );                            
40006170:	7f ff ec 4f 	call  400012ac <__getreent>                    
40006174:	01 00 00 00 	nop                                            
40006178:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           
4000617c:	40 00 39 53 	call  400146c8 <fputs>                         
40006180:	90 07 60 0c 	add  %i5, 0xc, %o0                             
  rtems_chain_extract_unprotected( &node->Node );                     
}                                                                     
                                                                      
static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node )
{                                                                     
  return node->control->imfs_type;                                    
40006184:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        
  switch( IMFS_type( the_jnode ) ) {                                  
40006188:	c2 00 40 00 	ld  [ %g1 ], %g1                               
4000618c:	80 a0 60 06 	cmp  %g1, 6                                    
40006190:	18 80 00 33 	bgu  4000625c <IMFS_dump_directory+0x154>      <== NEVER TAKEN
40006194:	01 00 00 00 	nop                                            
40006198:	83 28 60 02 	sll  %g1, 2, %g1                               
4000619c:	c2 04 00 01 	ld  [ %l0 + %g1 ], %g1                         
400061a0:	81 c0 40 00 	jmp  %g1                                       
400061a4:	01 00 00 00 	nop                                            
    case IMFS_DIRECTORY:                                              
      fprintf(stdout, "/" );                                          
400061a8:	7f ff ec 41 	call  400012ac <__getreent>                    
400061ac:	01 00 00 00 	nop                                            
400061b0:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           
400061b4:	40 00 39 11 	call  400145f8 <fputc>                         
400061b8:	90 10 20 2f 	mov  0x2f, %o0                                 
400061bc:	30 80 00 31 	b,a   40006280 <IMFS_dump_directory+0x178>     
      break;                                                          
                                                                      
    case IMFS_DEVICE:                                                 
      fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")",           
400061c0:	7f ff ec 3b 	call  400012ac <__getreent>                    
400061c4:	01 00 00 00 	nop                                            
400061c8:	13 10 00 90 	sethi  %hi(0x40024000), %o1                    
400061cc:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           
400061d0:	92 12 60 20 	or  %o1, 0x20, %o1                             
400061d4:	10 80 00 09 	b  400061f8 <IMFS_dump_directory+0xf0>         
400061d8:	d4 1f 60 50 	ldd  [ %i5 + 0x50 ], %o2                       
        the_jnode->info.device.major, the_jnode->info.device.minor ); 
      break;                                                          
                                                                      
    case IMFS_LINEAR_FILE:                                            
      fprintf(stdout, " (file %" PRId32 " %p)",                       
400061dc:	7f ff ec 34 	call  400012ac <__getreent>                    
400061e0:	01 00 00 00 	nop                                            
400061e4:	d4 07 60 54 	ld  [ %i5 + 0x54 ], %o2                        
400061e8:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           
400061ec:	d6 07 60 58 	ld  [ %i5 + 0x58 ], %o3                        
400061f0:	13 10 00 90 	sethi  %hi(0x40024000), %o1                    
400061f4:	92 12 60 38 	or  %o1, 0x38, %o1	! 40024038 <__FUNCTION__.6501+0x148>
400061f8:	40 00 38 e4 	call  40014588 <fprintf>                       
400061fc:	01 00 00 00 	nop                                            
40006200:	30 80 00 20 	b,a   40006280 <IMFS_dump_directory+0x178>     
        the_jnode->info.file.indirect,                                
        the_jnode->info.file.doubly_indirect,                         
        the_jnode->info.file.triply_indirect                          
      );                                                              
#else                                                                 
      fprintf(stdout, " (file %" PRId32 ")",                          
40006204:	7f ff ec 2a 	call  400012ac <__getreent>                    
40006208:	01 00 00 00 	nop                                            
4000620c:	d4 07 60 54 	ld  [ %i5 + 0x54 ], %o2                        
40006210:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           
40006214:	13 10 00 90 	sethi  %hi(0x40024000), %o1                    
40006218:	40 00 38 dc 	call  40014588 <fprintf>                       
4000621c:	92 12 60 48 	or  %o1, 0x48, %o1	! 40024048 <__FUNCTION__.6501+0x158>
40006220:	30 80 00 18 	b,a   40006280 <IMFS_dump_directory+0x178>     
    case IMFS_HARD_LINK:                                              
      fprintf(stdout, " links not printed\n" );                       
      return;                                                         
                                                                      
    case IMFS_SYM_LINK:                                               
      fprintf(stdout, " links not printed\n" );                       
40006224:	7f ff ec 22 	call  400012ac <__getreent>                    
40006228:	01 00 00 00 	nop                                            
4000622c:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           
40006230:	11 10 00 90 	sethi  %hi(0x40024000), %o0                    
40006234:	10 80 00 06 	b  4000624c <IMFS_dump_directory+0x144>        
40006238:	90 12 20 58 	or  %o0, 0x58, %o0	! 40024058 <__FUNCTION__.6501+0x168>
      return;                                                         
                                                                      
    case IMFS_FIFO:                                                   
      fprintf(stdout, " FIFO not printed\n" );                        
4000623c:	7f ff ec 1c 	call  400012ac <__getreent>                    
40006240:	01 00 00 00 	nop                                            
40006244:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           
40006248:	90 10 00 12 	mov  %l2, %o0                                  
4000624c:	40 00 39 1f 	call  400146c8 <fputs>                         
40006250:	01 00 00 00 	nop                                            
}                                                                     
                                                                      
static inline bool IMFS_is_directory( const IMFS_jnode_t *node )      
{                                                                     
  return node->control->imfs_type == IMFS_DIRECTORY;                  
40006254:	10 80 00 0e 	b  4000628c <IMFS_dump_directory+0x184>        
40006258:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        
      return;                                                         
                                                                      
    default:                                                          
      fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) );     
4000625c:	7f ff ec 14 	call  400012ac <__getreent>                    <== NOT EXECUTED
40006260:	01 00 00 00 	nop                                            <== NOT EXECUTED
  rtems_chain_extract_unprotected( &node->Node );                     
}                                                                     
                                                                      
static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node )
{                                                                     
  return node->control->imfs_type;                                    
40006264:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        <== NOT EXECUTED
40006268:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
4000626c:	d4 00 40 00 	ld  [ %g1 ], %o2                               <== NOT EXECUTED
40006270:	40 00 38 c6 	call  40014588 <fprintf>                       <== NOT EXECUTED
40006274:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
}                                                                     
                                                                      
static inline bool IMFS_is_directory( const IMFS_jnode_t *node )      
{                                                                     
  return node->control->imfs_type == IMFS_DIRECTORY;                  
40006278:	10 80 00 05 	b  4000628c <IMFS_dump_directory+0x184>        <== NOT EXECUTED
4000627c:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        <== NOT EXECUTED
      return;                                                         
  }                                                                   
  puts("");                                                           
40006280:	40 00 3f ff 	call  4001627c <puts>                          
40006284:	90 10 00 11 	mov  %l1, %o0                                  
40006288:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        
    the_jnode = (IMFS_jnode_t *) the_node;                            
                                                                      
    for ( i=0 ; i<=level ; i++ )                                      
      fprintf(stdout, "...." );                                       
    IMFS_print_jnode( the_jnode );                                    
    if ( IMFS_is_directory( the_jnode ) )                             
4000628c:	c2 00 40 00 	ld  [ %g1 ], %g1                               
40006290:	80 a0 60 00 	cmp  %g1, 0                                    
40006294:	32 bf ff a9 	bne,a   40006138 <IMFS_dump_directory+0x30>    
40006298:	fa 07 40 00 	ld  [ %i5 ], %i5                               
      IMFS_dump_directory( the_jnode, level + 1 );                    
4000629c:	90 10 00 1d 	mov  %i5, %o0                                  
400062a0:	7f ff ff 9a 	call  40006108 <IMFS_dump_directory>           
400062a4:	92 06 60 01 	add  %i1, 1, %o1                               
                                                                      
  the_chain = &the_directory->info.directory.Entries;                 
                                                                      
  for ( the_node = rtems_chain_first( the_chain );                    
        !rtems_chain_is_tail( the_chain, the_node );                  
        the_node = the_node->next ) {                                 
400062a8:	10 bf ff a4 	b  40006138 <IMFS_dump_directory+0x30>         
400062ac:	fa 07 40 00 	ld  [ %i5 ], %i5                               
400062b0:	81 c7 e0 08 	ret                                            
400062b4:	81 e8 00 00 	restore                                        
                                                                      

4000b9d4 <IMFS_eval_token>: rtems_filesystem_eval_path_context_t *ctx, void *arg, const char *token, size_t tokenlen ) {
4000b9d4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_filesystem_eval_path_generic_status status =                  
    RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;                          
  rtems_filesystem_location_info_t *currentloc =                      
    rtems_filesystem_eval_path_get_currentloc( ctx );                 
  IMFS_jnode_t *dir = currentloc->node_access;                        
4000b9d8:	f8 06 20 20 	ld  [ %i0 + 0x20 ], %i4                        
  bool access_ok = rtems_filesystem_eval_path_check_access(           
4000b9dc:	90 10 00 18 	mov  %i0, %o0                                  
4000b9e0:	d4 07 20 30 	ld  [ %i4 + 0x30 ], %o2                        
4000b9e4:	d6 17 20 3c 	lduh  [ %i4 + 0x3c ], %o3                      
4000b9e8:	d8 17 20 3e 	lduh  [ %i4 + 0x3e ], %o4                      
4000b9ec:	40 00 02 92 	call  4000c434 <rtems_filesystem_eval_path_check_access>
4000b9f0:	92 10 20 01 	mov  1, %o1                                    
    dir->st_mode,                                                     
    dir->st_uid,                                                      
    dir->st_gid                                                       
  );                                                                  
                                                                      
  if ( access_ok ) {                                                  
4000b9f4:	80 a2 20 00 	cmp  %o0, 0                                    
4000b9f8:	02 80 00 66 	be  4000bb90 <IMFS_eval_token+0x1bc>           
4000b9fc:	80 a6 e0 01 	cmp  %i3, 1                                    
static inline bool rtems_filesystem_is_current_directory(             
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  return tokenlen == 1 && token [0] == '.';                           
4000ba00:	12 80 00 06 	bne  4000ba18 <IMFS_eval_token+0x44>           
4000ba04:	82 10 20 00 	clr  %g1                                       
4000ba08:	c2 4e 80 00 	ldsb  [ %i2 ], %g1                             
4000ba0c:	82 18 60 2e 	xor  %g1, 0x2e, %g1                            
4000ba10:	80 a0 00 01 	cmp  %g0, %g1                                  
4000ba14:	82 60 3f ff 	subx  %g0, -1, %g1                             
  IMFS_jnode_t *dir,                                                  
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  if ( rtems_filesystem_is_current_directory( token, tokenlen ) ) {   
4000ba18:	80 a0 60 00 	cmp  %g1, 0                                    
4000ba1c:	12 80 00 29 	bne  4000bac0 <IMFS_eval_token+0xec>           
4000ba20:	80 a6 e0 02 	cmp  %i3, 2                                    
static inline bool rtems_filesystem_is_parent_directory(              
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  return tokenlen == 2 && token [0] == '.' && token [1] == '.';       
4000ba24:	12 80 00 0b 	bne  4000ba50 <IMFS_eval_token+0x7c>           
4000ba28:	80 a0 60 00 	cmp  %g1, 0                                    
4000ba2c:	c4 4e 80 00 	ldsb  [ %i2 ], %g2                             
4000ba30:	80 a0 a0 2e 	cmp  %g2, 0x2e                                 
4000ba34:	12 80 00 07 	bne  4000ba50 <IMFS_eval_token+0x7c>           
4000ba38:	80 a0 60 00 	cmp  %g1, 0                                    
4000ba3c:	c2 4e a0 01 	ldsb  [ %i2 + 1 ], %g1                         
4000ba40:	82 18 60 2e 	xor  %g1, 0x2e, %g1                            
4000ba44:	80 a0 00 01 	cmp  %g0, %g1                                  
4000ba48:	82 60 3f ff 	subx  %g0, -1, %g1                             
    return dir;                                                       
  } else {                                                            
    if ( rtems_filesystem_is_parent_directory( token, tokenlen ) ) {  
4000ba4c:	80 a0 60 00 	cmp  %g1, 0                                    
4000ba50:	22 80 00 04 	be,a   4000ba60 <IMFS_eval_token+0x8c>         
4000ba54:	fa 07 20 50 	ld  [ %i4 + 0x50 ], %i5                        
      return dir->Parent;                                             
4000ba58:	10 80 00 15 	b  4000baac <IMFS_eval_token+0xd8>             
4000ba5c:	fa 07 20 08 	ld  [ %i4 + 8 ], %i5                           
    } else {                                                          
      rtems_chain_control *entries = &dir->info.directory.Entries;    
      rtems_chain_node *current = rtems_chain_first( entries );       
      rtems_chain_node *tail = rtems_chain_tail( entries );           
4000ba60:	b2 07 20 54 	add  %i4, 0x54, %i1                            
                                                                      
      while ( current != tail ) {                                     
4000ba64:	80 a7 40 19 	cmp  %i5, %i1                                  
4000ba68:	02 80 00 4c 	be  4000bb98 <IMFS_eval_token+0x1c4>           
4000ba6c:	90 07 60 0c 	add  %i5, 0xc, %o0                             
        IMFS_jnode_t *entry = (IMFS_jnode_t *) current;               
        bool match = strncmp( entry->name, token, tokenlen ) == 0     
4000ba70:	92 10 00 1a 	mov  %i2, %o1                                  
4000ba74:	40 00 13 7b 	call  40010860 <strncmp>                       
4000ba78:	94 10 00 1b 	mov  %i3, %o2                                  
          && entry->name [tokenlen] == '\0';                          
4000ba7c:	80 a2 20 00 	cmp  %o0, 0                                    
4000ba80:	12 80 00 06 	bne  4000ba98 <IMFS_eval_token+0xc4>           
4000ba84:	82 10 20 00 	clr  %g1                                       
4000ba88:	82 07 40 1b 	add  %i5, %i3, %g1                             
4000ba8c:	c2 48 60 0c 	ldsb  [ %g1 + 0xc ], %g1                       
4000ba90:	80 a0 00 01 	cmp  %g0, %g1                                  
4000ba94:	82 60 3f ff 	subx  %g0, -1, %g1                             
                                                                      
        if ( match ) {                                                
4000ba98:	80 a0 60 00 	cmp  %g1, 0                                    
4000ba9c:	12 80 00 05 	bne  4000bab0 <IMFS_eval_token+0xdc>           
4000baa0:	80 a7 60 00 	cmp  %i5, 0                                    
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
4000baa4:	10 bf ff f0 	b  4000ba64 <IMFS_eval_token+0x90>             
4000baa8:	fa 07 40 00 	ld  [ %i5 ], %i5                               
  );                                                                  
                                                                      
  if ( access_ok ) {                                                  
    IMFS_jnode_t *entry = IMFS_search_in_directory( dir, token, tokenlen );
                                                                      
    if ( entry != NULL ) {                                            
4000baac:	80 a7 60 00 	cmp  %i5, 0                                    
4000bab0:	32 80 00 06 	bne,a   4000bac8 <IMFS_eval_token+0xf4>        
4000bab4:	c4 07 60 4c 	ld  [ %i5 + 0x4c ], %g2                        
            rtems_filesystem_eval_path_restart( ctx, fs_root_ptr );   
          }                                                           
        }                                                             
      }                                                               
    } else {                                                          
      status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY;           
4000bab8:	81 c7 e0 08 	ret                                            
4000babc:	91 e8 20 02 	restore  %g0, 2, %o0                           
  IMFS_jnode_t *dir,                                                  
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  if ( rtems_filesystem_is_current_directory( token, tokenlen ) ) {   
4000bac0:	ba 10 00 1c 	mov  %i4, %i5                                  
  rtems_chain_extract_unprotected( &node->Node );                     
}                                                                     
                                                                      
static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node )
{                                                                     
  return node->control->imfs_type;                                    
4000bac4:	c4 07 60 4c 	ld  [ %i5 + 0x4c ], %g2                        
                                                                      
  if ( access_ok ) {                                                  
    IMFS_jnode_t *entry = IMFS_search_in_directory( dir, token, tokenlen );
                                                                      
    if ( entry != NULL ) {                                            
      bool terminal = !rtems_filesystem_eval_path_has_path( ctx );    
4000bac8:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
4000bacc:	c4 00 80 00 	ld  [ %g2 ], %g2                               
4000bad0:	80 a0 00 01 	cmp  %g0, %g1                                  
                                                                      
static inline void rtems_filesystem_eval_path_clear_token(            
  rtems_filesystem_eval_path_context_t *ctx                           
)                                                                     
{                                                                     
  ctx->tokenlen = 0;                                                  
4000bad4:	c0 26 20 0c 	clr  [ %i0 + 0xc ]                             
4000bad8:	82 60 3f ff 	subx  %g0, -1, %g1                             
      bool follow_sym_link = (eval_flags & RTEMS_FS_FOLLOW_SYM_LINK) != 0;
      IMFS_jnode_types_t type = IMFS_type( entry );                   
                                                                      
      rtems_filesystem_eval_path_clear_token( ctx );                  
                                                                      
      if ( type == IMFS_HARD_LINK && (follow_hard_link || !terminal)) {
4000badc:	80 a0 a0 02 	cmp  %g2, 2                                    
4000bae0:	12 80 00 0a 	bne  4000bb08 <IMFS_eval_token+0x134>          
4000bae4:	c6 06 20 10 	ld  [ %i0 + 0x10 ], %g3                        
4000bae8:	80 a0 60 00 	cmp  %g1, 0                                    
4000baec:	22 80 00 2d 	be,a   4000bba0 <IMFS_eval_token+0x1cc>        
4000baf0:	fa 07 60 50 	ld  [ %i5 + 0x50 ], %i5                        
4000baf4:	80 88 e0 08 	btst  8, %g3                                   
4000baf8:	22 80 00 2b 	be,a   4000bba4 <IMFS_eval_token+0x1d0>        
4000bafc:	c4 17 20 34 	lduh  [ %i4 + 0x34 ], %g2                      
        entry = entry->info.hard_link.link_node;                      
4000bb00:	10 80 00 28 	b  4000bba0 <IMFS_eval_token+0x1cc>            
4000bb04:	fa 07 60 50 	ld  [ %i5 + 0x50 ], %i5                        
      }                                                               
                                                                      
      if ( type == IMFS_SYM_LINK && (follow_sym_link || !terminal)) { 
4000bb08:	80 a0 a0 03 	cmp  %g2, 3                                    
4000bb0c:	12 80 00 10 	bne  4000bb4c <IMFS_eval_token+0x178>          
4000bb10:	80 a0 a0 00 	cmp  %g2, 0                                    
4000bb14:	80 a0 60 00 	cmp  %g1, 0                                    
4000bb18:	02 80 00 04 	be  4000bb28 <IMFS_eval_token+0x154>           
4000bb1c:	80 88 e0 10 	btst  0x10, %g3                                
4000bb20:	22 80 00 21 	be,a   4000bba4 <IMFS_eval_token+0x1d0>        
4000bb24:	c4 17 20 34 	lduh  [ %i4 + 0x34 ], %g2                      
        const char *target = entry->info.sym_link.name;               
4000bb28:	fa 07 60 50 	ld  [ %i5 + 0x50 ], %i5                        
                                                                      
        rtems_filesystem_eval_path_recursive( ctx, target, strlen( target ) );
4000bb2c:	40 00 13 1d 	call  400107a0 <strlen>                        
4000bb30:	90 10 00 1d 	mov  %i5, %o0                                  
4000bb34:	92 10 00 1d 	mov  %i5, %o1                                  
4000bb38:	94 10 00 08 	mov  %o0, %o2                                  
4000bb3c:	7f ff e3 28 	call  400047dc <rtems_filesystem_eval_path_recursive>
4000bb40:	90 10 00 18 	mov  %i0, %o0                                  
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
4000bb44:	81 c7 e0 08 	ret                                            
4000bb48:	91 e8 20 01 	restore  %g0, 1, %o0                           
  IMFS_jnode_types_t type                                             
)                                                                     
{                                                                     
  rtems_filesystem_global_location_t **fs_root_ptr = NULL;            
                                                                      
  if ( type == IMFS_DIRECTORY ) {                                     
4000bb4c:	32 80 00 16 	bne,a   4000bba4 <IMFS_eval_token+0x1d0>       
4000bb50:	c4 17 20 34 	lduh  [ %i4 + 0x34 ], %g2                      
    if ( node->info.directory.mt_fs != NULL ) {                       
4000bb54:	d2 07 60 5c 	ld  [ %i5 + 0x5c ], %o1                        
4000bb58:	80 a2 60 00 	cmp  %o1, 0                                    
4000bb5c:	02 80 00 11 	be  4000bba0 <IMFS_eval_token+0x1cc>           
4000bb60:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
          if ( !terminal ) {                                          
            status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE;     
          }                                                           
        } else {                                                      
          access_ok = rtems_filesystem_eval_path_check_access(        
4000bb64:	d4 07 60 30 	ld  [ %i5 + 0x30 ], %o2                        
4000bb68:	d6 17 60 3c 	lduh  [ %i5 + 0x3c ], %o3                      
4000bb6c:	d8 17 60 3e 	lduh  [ %i5 + 0x3e ], %o4                      
{                                                                     
  rtems_filesystem_global_location_t **fs_root_ptr = NULL;            
                                                                      
  if ( type == IMFS_DIRECTORY ) {                                     
    if ( node->info.directory.mt_fs != NULL ) {                       
      fs_root_ptr = &node->info.directory.mt_fs->mt_fs_root;          
4000bb70:	b8 02 60 24 	add  %o1, 0x24, %i4                            
                                                                      
          if ( !terminal ) {                                          
            status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE;     
          }                                                           
        } else {                                                      
          access_ok = rtems_filesystem_eval_path_check_access(        
4000bb74:	40 00 02 30 	call  4000c434 <rtems_filesystem_eval_path_check_access>
4000bb78:	92 10 20 01 	mov  1, %o1                                    
            RTEMS_FS_PERMS_EXEC,                                      
            entry->st_mode,                                           
            entry->st_uid,                                            
            entry->st_gid                                             
          );                                                          
          if ( access_ok ) {                                          
4000bb7c:	80 a2 20 00 	cmp  %o0, 0                                    
4000bb80:	02 80 00 04 	be  4000bb90 <IMFS_eval_token+0x1bc>           <== NEVER TAKEN
4000bb84:	90 10 00 18 	mov  %i0, %o0                                  
            rtems_filesystem_eval_path_restart( ctx, fs_root_ptr );   
4000bb88:	7f ff e2 fc 	call  40004778 <rtems_filesystem_eval_path_restart>
4000bb8c:	92 10 00 1c 	mov  %i4, %o1                                  
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
4000bb90:	81 c7 e0 08 	ret                                            
4000bb94:	91 e8 20 01 	restore  %g0, 1, %o0                           
            rtems_filesystem_eval_path_restart( ctx, fs_root_ptr );   
          }                                                           
        }                                                             
      }                                                               
    } else {                                                          
      status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY;           
4000bb98:	81 c7 e0 08 	ret                                            
4000bb9c:	91 e8 20 02 	restore  %g0, 2, %o0                           
      } else {                                                        
        rtems_filesystem_global_location_t **fs_root_ptr =            
          IMFS_is_mount_point( entry, type );                         
                                                                      
        if ( fs_root_ptr == NULL ) {                                  
          --dir->reference_count;                                     
4000bba0:	c4 17 20 34 	lduh  [ %i4 + 0x34 ], %g2                      
4000bba4:	84 00 bf ff 	add  %g2, -1, %g2                              
4000bba8:	c4 37 20 34 	sth  %g2, [ %i4 + 0x34 ]                       
          ++entry->reference_count;                                   
4000bbac:	c4 17 60 34 	lduh  [ %i5 + 0x34 ], %g2                      
4000bbb0:	84 00 a0 01 	inc  %g2                                       
4000bbb4:	c4 37 60 34 	sth  %g2, [ %i5 + 0x34 ]                       
          currentloc->node_access = entry;                            
4000bbb8:	fa 26 20 20 	st  %i5, [ %i0 + 0x20 ]                        
    dir->st_uid,                                                      
    dir->st_gid                                                       
  );                                                                  
                                                                      
  if ( access_ok ) {                                                  
    IMFS_jnode_t *entry = IMFS_search_in_directory( dir, token, tokenlen );
4000bbbc:	c4 07 60 50 	ld  [ %i5 + 0x50 ], %g2                        
                                                                      
        if ( fs_root_ptr == NULL ) {                                  
          --dir->reference_count;                                     
          ++entry->reference_count;                                   
          currentloc->node_access = entry;                            
          currentloc->node_access_2 =                                 
4000bbc0:	c4 26 20 24 	st  %g2, [ %i0 + 0x24 ]                        
                                                                      
static inline void IMFS_Set_handlers( rtems_filesystem_location_info_t *loc )
{                                                                     
  IMFS_jnode_t *node = (IMFS_jnode_t *) loc->node_access;             
                                                                      
  loc->handlers = node->control->handlers;                            
4000bbc4:	c4 07 60 4c 	ld  [ %i5 + 0x4c ], %g2                        
4000bbc8:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
4000bbcc:	c4 26 20 28 	st  %g2, [ %i0 + 0x28 ]                        
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
4000bbd0:	b0 08 60 ff 	and  %g1, 0xff, %i0                            
      status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY;           
    }                                                                 
  }                                                                   
                                                                      
  return status;                                                      
}                                                                     
4000bbd4:	81 c7 e0 08 	ret                                            
4000bbd8:	81 e8 00 00 	restore                                        
                                                                      

40003e9c <IMFS_fifo_write>: static ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
40003e9c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  IMFS_jnode_t *jnode = iop->pathinfo.node_access;                    
40003ea0:	f8 06 20 1c 	ld  [ %i0 + 0x1c ], %i4                        
                                                                      
  int err = pipe_write(JNODE2PIPE(jnode), buffer, count, iop);        
40003ea4:	92 10 00 19 	mov  %i1, %o1                                  
40003ea8:	d0 07 20 50 	ld  [ %i4 + 0x50 ], %o0                        
40003eac:	94 10 00 1a 	mov  %i2, %o2                                  
40003eb0:	40 00 2a 2a 	call  4000e758 <pipe_write>                    
40003eb4:	96 10 00 18 	mov  %i0, %o3                                  
  if (err > 0) {                                                      
40003eb8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003ebc:	04 80 00 09 	ble  40003ee0 <IMFS_fifo_write+0x44>           
40003ec0:	90 07 bf f8 	add  %fp, -8, %o0                              
                                                                      
static inline void IMFS_mtime_ctime_update( IMFS_jnode_t *jnode )     
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
40003ec4:	40 00 03 cc 	call  40004df4 <gettimeofday>                  
40003ec8:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_mtime = now.tv_sec;                                     
40003ecc:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
40003ed0:	c2 27 20 44 	st  %g1, [ %i4 + 0x44 ]                        
  jnode->stat_ctime = now.tv_sec;                                     
40003ed4:	c2 27 20 48 	st  %g1, [ %i4 + 0x48 ]                        
40003ed8:	81 c7 e0 08 	ret                                            
40003edc:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
    IMFS_mtime_ctime_update(jnode);                                   
  }                                                                   
                                                                      
  IMFS_FIFO_RETURN(err);                                              
40003ee0:	80 a7 60 00 	cmp  %i5, 0                                    
40003ee4:	02 80 00 06 	be  40003efc <IMFS_fifo_write+0x60>            <== NEVER TAKEN
40003ee8:	b0 10 20 00 	clr  %i0                                       
40003eec:	40 00 37 5a 	call  40011c54 <__errno>                       
40003ef0:	ba 20 00 1d 	neg  %i5                                       
40003ef4:	b0 10 3f ff 	mov  -1, %i0                                   
40003ef8:	fa 22 00 00 	st  %i5, [ %o0 ]                               
}                                                                     
40003efc:	81 c7 e0 08 	ret                                            
40003f00:	81 e8 00 00 	restore                                        
                                                                      

4000bc1c <IMFS_fsunmount>: ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) void IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) {
4000bc1c:	9d e3 bf 88 	save  %sp, -120, %sp                           
   /*                                                                 
    * Traverse tree that starts at the mt_fs_root and deallocate memory
    * associated memory space                                         
    */                                                                
                                                                      
   loc = temp_mt_entry->mt_fs_root->location;                         
4000bc20:	f8 06 20 24 	ld  [ %i0 + 0x24 ], %i4                        
4000bc24:	90 07 bf e8 	add  %fp, -24, %o0                             
4000bc28:	92 10 00 1c 	mov  %i4, %o1                                  
4000bc2c:	40 00 11 63 	call  400101b8 <memcpy>                        
4000bc30:	94 10 20 18 	mov  0x18, %o2                                 
   jnode = (IMFS_jnode_t *)loc.node_access;                           
4000bc34:	fa 07 bf f0 	ld  [ %fp + -16 ], %i5                         
                                                                      
   /*                                                                 
    *  Set this to null to indicate that it is being unmounted.       
    */                                                                
                                                                      
   temp_mt_entry->mt_fs_root->location.node_access = NULL;            
4000bc38:	c0 27 20 08 	clr  [ %i4 + 8 ]                               
                                                                      
static inline void IMFS_Set_handlers( rtems_filesystem_location_info_t *loc )
{                                                                     
  IMFS_jnode_t *node = (IMFS_jnode_t *) loc->node_access;             
                                                                      
  loc->handlers = node->control->handlers;                            
4000bc3c:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        
                                                                      
   do {                                                               
     next = jnode->Parent;                                            
4000bc40:	f8 07 60 08 	ld  [ %i5 + 8 ], %i4                           
4000bc44:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
     loc.node_access = (void *)jnode;                                 
     IMFS_Set_handlers( &loc );                                       
                                                                      
     if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) {
4000bc48:	c2 00 40 00 	ld  [ %g1 ], %g1                               
                                                                      
   temp_mt_entry->mt_fs_root->location.node_access = NULL;            
                                                                      
   do {                                                               
     next = jnode->Parent;                                            
     loc.node_access = (void *)jnode;                                 
4000bc4c:	fa 27 bf f0 	st  %i5, [ %fp + -16 ]                         
     IMFS_Set_handlers( &loc );                                       
                                                                      
     if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) {
4000bc50:	80 a0 60 00 	cmp  %g1, 0                                    
4000bc54:	12 80 00 07 	bne  4000bc70 <IMFS_fsunmount+0x54>            
4000bc58:	c4 27 bf f8 	st  %g2, [ %fp + -8 ]                          
4000bc5c:	c4 07 60 50 	ld  [ %i5 + 0x50 ], %g2                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000bc60:	82 07 60 54 	add  %i5, 0x54, %g1                            
4000bc64:	80 a0 80 01 	cmp  %g2, %g1                                  
4000bc68:	32 80 00 10 	bne,a   4000bca8 <IMFS_fsunmount+0x8c>         
4000bc6c:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        
        result = IMFS_rmnod( NULL, &loc );                            
4000bc70:	90 10 20 00 	clr  %o0                                       
4000bc74:	7f ff de 3c 	call  40003564 <IMFS_rmnod>                    
4000bc78:	92 07 bf e8 	add  %fp, -24, %o1                             
        if ( result != 0 )                                            
4000bc7c:	80 a2 20 00 	cmp  %o0, 0                                    
4000bc80:	02 80 00 04 	be  4000bc90 <IMFS_fsunmount+0x74>             <== ALWAYS TAKEN
4000bc84:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
	  rtems_fatal_error_occurred( 0xdeadbeef );                          
4000bc88:	7f ff f0 3f 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
4000bc8c:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
        IMFS_node_destroy( jnode );                                   
4000bc90:	7f ff dd 66 	call  40003228 <IMFS_node_destroy>             
4000bc94:	90 10 00 1d 	mov  %i5, %o0                                  
        jnode = next;                                                 
     }                                                                
     if ( jnode != NULL ) {                                           
4000bc98:	80 a7 20 00 	cmp  %i4, 0                                    
4000bc9c:	02 80 00 0e 	be  4000bcd4 <IMFS_fsunmount+0xb8>             
4000bca0:	ba 10 00 1c 	mov  %i4, %i5                                  
  return node->control->imfs_type;                                    
}                                                                     
                                                                      
static inline bool IMFS_is_directory( const IMFS_jnode_t *node )      
{                                                                     
  return node->control->imfs_type == IMFS_DIRECTORY;                  
4000bca4:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        
       if ( IMFS_is_directory( jnode ) ) {                            
4000bca8:	c2 00 40 00 	ld  [ %g1 ], %g1                               
4000bcac:	80 a0 60 00 	cmp  %g1, 0                                    
4000bcb0:	32 bf ff e4 	bne,a   4000bc40 <IMFS_fsunmount+0x24>         <== NEVER TAKEN
4000bcb4:	c2 07 60 4c 	ld  [ %i5 + 0x4c ], %g1                        <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000bcb8:	c2 07 60 50 	ld  [ %i5 + 0x50 ], %g1                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000bcbc:	84 07 60 54 	add  %i5, 0x54, %g2                            
         if ( jnode_has_children( jnode ) )                           
4000bcc0:	80 a0 40 02 	cmp  %g1, %g2                                  
4000bcc4:	02 bf ff de 	be  4000bc3c <IMFS_fsunmount+0x20>             
4000bcc8:	80 a0 60 00 	cmp  %g1, 0                                    
           jnode = jnode_get_first_child( jnode );                    
       }                                                              
     }                                                                
   } while (jnode != NULL);                                           
4000bccc:	12 bf ff dc 	bne  4000bc3c <IMFS_fsunmount+0x20>            <== ALWAYS TAKEN
4000bcd0:	ba 10 00 01 	mov  %g1, %i5                                  
4000bcd4:	81 c7 e0 08 	ret                                            
4000bcd8:	81 e8 00 00 	restore                                        
                                                                      

40003114 <IMFS_initialize_support>: int IMFS_initialize_support( rtems_filesystem_mount_table_entry_t *mt_entry, const rtems_filesystem_operations_table *op_table, const IMFS_node_control *const node_controls [IMFS_TYPE_COUNT] ) {
40003114:	9d e3 bf a0 	save  %sp, -96, %sp                            
  static int imfs_instance;                                           
                                                                      
  int rv = 0;                                                         
  IMFS_fs_info_t *fs_info = calloc( 1, sizeof( *fs_info ) );          
40003118:	90 10 20 01 	mov  1, %o0                                    
4000311c:	40 00 01 a7 	call  400037b8 <calloc>                        
40003120:	92 10 20 24 	mov  0x24, %o1                                 
                                                                      
  if ( fs_info != NULL ) {                                            
40003124:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003128:	02 80 00 26 	be  400031c0 <IMFS_initialize_support+0xac>    
4000312c:	05 10 00 5f 	sethi  %hi(0x40017c00), %g2                    
    IMFS_jnode_t *root_node;                                          
                                                                      
    fs_info->instance = imfs_instance++;                              
40003130:	c2 00 a1 70 	ld  [ %g2 + 0x170 ], %g1	! 40017d70 <imfs_instance.6711>
    memcpy(                                                           
40003134:	92 10 00 1a 	mov  %i2, %o1                                  
  IMFS_fs_info_t *fs_info = calloc( 1, sizeof( *fs_info ) );          
                                                                      
  if ( fs_info != NULL ) {                                            
    IMFS_jnode_t *root_node;                                          
                                                                      
    fs_info->instance = imfs_instance++;                              
40003138:	86 00 60 01 	add  %g1, 1, %g3                               
4000313c:	c2 27 40 00 	st  %g1, [ %i5 ]                               
40003140:	c6 20 a1 70 	st  %g3, [ %g2 + 0x170 ]                       
    memcpy(                                                           
40003144:	94 10 20 1c 	mov  0x1c, %o2                                 
40003148:	40 00 34 1c 	call  400101b8 <memcpy>                        
4000314c:	90 07 60 08 	add  %i5, 8, %o0                               
      fs_info->node_controls,                                         
      node_controls,                                                  
      sizeof( fs_info->node_controls )                                
    );                                                                
                                                                      
    root_node = IMFS_allocate_node(                                   
40003150:	d2 07 60 08 	ld  [ %i5 + 8 ], %o1                           
40003154:	90 10 00 1d 	mov  %i5, %o0                                  
40003158:	15 10 00 57 	sethi  %hi(0x40015c00), %o2                    
4000315c:	96 10 20 00 	clr  %o3                                       
40003160:	94 12 a0 48 	or  %o2, 0x48, %o2                             
40003164:	19 00 00 10 	sethi  %hi(0x4000), %o4                        
40003168:	9a 10 20 00 	clr  %o5                                       
4000316c:	40 00 21 c6 	call  4000b884 <IMFS_allocate_node>            
40003170:	98 13 21 ed 	or  %o4, 0x1ed, %o4                            
      "",                                                             
      0,                                                              
      (S_IFDIR | 0755),                                               
      NULL                                                            
    );                                                                
    if ( root_node != NULL ) {                                        
40003174:	80 a2 20 00 	cmp  %o0, 0                                    
40003178:	02 80 00 10 	be  400031b8 <IMFS_initialize_support+0xa4>    <== NEVER TAKEN
4000317c:	03 10 00 58 	sethi  %hi(0x40016000), %g1                    
                                                                      
static inline void IMFS_Set_handlers( rtems_filesystem_location_info_t *loc )
{                                                                     
  IMFS_jnode_t *node = (IMFS_jnode_t *) loc->node_access;             
                                                                      
  loc->handlers = node->control->handlers;                            
40003180:	c4 02 20 4c 	ld  [ %o0 + 0x4c ], %g2                        
      mt_entry->fs_info = fs_info;                                    
      mt_entry->ops = op_table;                                       
      mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS;
40003184:	82 10 60 dc 	or  %g1, 0xdc, %g1                             
40003188:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
4000318c:	c2 26 20 2c 	st  %g1, [ %i0 + 0x2c ]                        
      mt_entry->mt_fs_root->location.node_access = root_node;         
40003190:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
      0,                                                              
      (S_IFDIR | 0755),                                               
      NULL                                                            
    );                                                                
    if ( root_node != NULL ) {                                        
      mt_entry->fs_info = fs_info;                                    
40003194:	fa 26 20 08 	st  %i5, [ %i0 + 8 ]                           
      mt_entry->ops = op_table;                                       
40003198:	f2 26 20 0c 	st  %i1, [ %i0 + 0xc ]                         
4000319c:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
      mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS;
      mt_entry->mt_fs_root->location.node_access = root_node;         
400031a0:	d0 20 60 08 	st  %o0, [ %g1 + 8 ]                           
    errno = ENOMEM;                                                   
    rv = -1;                                                          
  }                                                                   
                                                                      
  if ( rv == 0 ) {                                                    
    IMFS_determine_bytes_per_block(                                   
400031a4:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
400031a8:	84 10 20 06 	mov  6, %g2                                    
400031ac:	c6 00 63 2c 	ld  [ %g1 + 0x32c ], %g3                       
  int bit_mask;                                                       
                                                                      
  /*                                                                  
   * check, whether requested bytes per block is valid                
   */                                                                 
  for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) {
400031b0:	10 80 00 0e 	b  400031e8 <IMFS_initialize_support+0xd4>     
400031b4:	82 10 20 10 	mov  0x10, %g1                                 
      mt_entry->ops = op_table;                                       
      mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS;
      mt_entry->mt_fs_root->location.node_access = root_node;         
      IMFS_Set_handlers( &mt_entry->mt_fs_root->location );           
    } else {                                                          
      free(fs_info);                                                  
400031b8:	40 00 01 95 	call  4000380c <free>                          <== NOT EXECUTED
400031bc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      errno = ENOMEM;                                                 
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    errno = ENOMEM;                                                   
400031c0:	40 00 32 18 	call  4000fa20 <__errno>                       
400031c4:	b0 10 3f ff 	mov  -1, %i0                                   
400031c8:	82 10 20 0c 	mov  0xc, %g1                                  
400031cc:	c2 22 00 00 	st  %g1, [ %o0 ]                               
      IMFS_MEMFILE_DEFAULT_BYTES_PER_BLOCK                            
    );                                                                
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
400031d0:	81 c7 e0 08 	ret                                            
400031d4:	81 e8 00 00 	restore                                        
  for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) {
    if (bit_mask == requested_bytes_per_block) {                      
      is_valid = true;                                                
      break;                                                          
    }                                                                 
    if(bit_mask > requested_bytes_per_block)                          
400031d8:	14 80 00 09 	bg  400031fc <IMFS_initialize_support+0xe8>    
400031dc:	84 80 bf ff 	addcc  %g2, -1, %g2                            
  int bit_mask;                                                       
                                                                      
  /*                                                                  
   * check, whether requested bytes per block is valid                
   */                                                                 
  for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) {
400031e0:	02 80 00 07 	be  400031fc <IMFS_initialize_support+0xe8>    <== NEVER TAKEN
400031e4:	83 28 60 01 	sll  %g1, 1, %g1                               
    if (bit_mask == requested_bytes_per_block) {                      
400031e8:	80 a0 40 03 	cmp  %g1, %g3                                  
400031ec:	12 bf ff fb 	bne  400031d8 <IMFS_initialize_support+0xc4>   
400031f0:	01 00 00 00 	nop                                            
      break;                                                          
    }                                                                 
    if(bit_mask > requested_bytes_per_block)                          
      break;                                                          
  }                                                                   
  *dest_bytes_per_block = ((is_valid)                                 
400031f4:	10 80 00 04 	b  40003204 <IMFS_initialize_support+0xf0>     
400031f8:	05 10 00 5f 	sethi  %hi(0x40017c00), %g2                    
			   ? requested_bytes_per_block                                     
			   : default_bytes_per_block);                                     
400031fc:	82 10 20 80 	mov  0x80, %g1                                 
      break;                                                          
    }                                                                 
    if(bit_mask > requested_bytes_per_block)                          
      break;                                                          
  }                                                                   
  *dest_bytes_per_block = ((is_valid)                                 
40003200:	05 10 00 5f 	sethi  %hi(0x40017c00), %g2                    
40003204:	c2 20 a1 74 	st  %g1, [ %g2 + 0x174 ]	! 40017d74 <imfs_memfile_bytes_per_block>
  const IMFS_node_control *const node_controls [IMFS_TYPE_COUNT]      
)                                                                     
{                                                                     
  static int imfs_instance;                                           
                                                                      
  int rv = 0;                                                         
40003208:	81 c7 e0 08 	ret                                            
4000320c:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40004920 <IMFS_make_generic_node>: const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) {
40004920:	9d e3 bf 48 	save  %sp, -184, %sp                           
  int rv = 0;                                                         
                                                                      
  mode &= ~rtems_filesystem_umask;                                    
40004924:	40 00 05 74 	call  40005ef4 <rtems_current_user_env_get>    
40004928:	01 00 00 00 	nop                                            
4000492c:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           
                                                                      
  switch (mode & S_IFMT) {                                            
40004930:	05 00 00 18 	sethi  %hi(0x6000), %g2                        
  void *context                                                       
)                                                                     
{                                                                     
  int rv = 0;                                                         
                                                                      
  mode &= ~rtems_filesystem_umask;                                    
40004934:	b2 2e 40 01 	andn  %i1, %g1, %i1                            
                                                                      
  switch (mode & S_IFMT) {                                            
40004938:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
4000493c:	82 0e 40 01 	and  %i1, %g1, %g1                             
40004940:	80 a0 40 02 	cmp  %g1, %g2                                  
40004944:	22 80 00 11 	be,a   40004988 <IMFS_make_generic_node+0x68>  
40004948:	c2 06 80 00 	ld  [ %i2 ], %g1                               
4000494c:	18 80 00 08 	bgu  4000496c <IMFS_make_generic_node+0x4c>    <== NEVER TAKEN
40004950:	05 00 00 20 	sethi  %hi(0x8000), %g2                        
40004954:	05 00 00 04 	sethi  %hi(0x1000), %g2                        
40004958:	80 a0 40 02 	cmp  %g1, %g2                                  
4000495c:	02 80 00 0a 	be  40004984 <IMFS_make_generic_node+0x64>     <== NEVER TAKEN
40004960:	05 00 00 08 	sethi  %hi(0x2000), %g2                        
40004964:	10 80 00 06 	b  4000497c <IMFS_make_generic_node+0x5c>      
40004968:	80 a0 40 02 	cmp  %g1, %g2                                  
4000496c:	80 a0 40 02 	cmp  %g1, %g2                                  <== NOT EXECUTED
40004970:	02 80 00 05 	be  40004984 <IMFS_make_generic_node+0x64>     <== NOT EXECUTED
40004974:	05 00 00 30 	sethi  %hi(0xc000), %g2                        <== NOT EXECUTED
40004978:	80 a0 40 02 	cmp  %g1, %g2                                  <== NOT EXECUTED
4000497c:	12 80 00 06 	bne  40004994 <IMFS_make_generic_node+0x74>    
40004980:	01 00 00 00 	nop                                            
      rv = -1;                                                        
      break;                                                          
  }                                                                   
                                                                      
  if ( rv == 0 ) {                                                    
    if ( node_control->imfs_type == IMFS_GENERIC ) {                  
40004984:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40004988:	80 a0 60 07 	cmp  %g1, 7                                    
4000498c:	02 80 00 08 	be  400049ac <IMFS_make_generic_node+0x8c>     
40004990:	92 10 00 18 	mov  %i0, %o1                                  
        rv = -1;                                                      
      }                                                               
                                                                      
      rtems_filesystem_eval_path_cleanup( &ctx );                     
    } else {                                                          
      errno = EINVAL;                                                 
40004994:	40 00 3f f9 	call  40014978 <__errno>                       
40004998:	b0 10 3f ff 	mov  -1, %i0                                   
4000499c:	82 10 20 16 	mov  0x16, %g1                                 
400049a0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400049a4:	81 c7 e0 08 	ret                                            
400049a8:	81 e8 00 00 	restore                                        
    if ( node_control->imfs_type == IMFS_GENERIC ) {                  
      rtems_filesystem_eval_path_context_t ctx;                       
      int eval_flags = RTEMS_FS_FOLLOW_LINK                           
        | RTEMS_FS_MAKE                                               
        | RTEMS_FS_EXCLUSIVE;                                         
      const rtems_filesystem_location_info_t *currentloc =            
400049ac:	94 10 20 78 	mov  0x78, %o2                                 
400049b0:	40 00 06 e5 	call  40006544 <rtems_filesystem_eval_path_start>
400049b4:	90 07 bf c8 	add  %fp, -56, %o0                             
        rtems_filesystem_eval_path_start( &ctx, path, eval_flags );   
                                                                      
      if ( IMFS_is_imfs_instance( currentloc ) ) {                    
400049b8:	7f ff ff c8 	call  400048d8 <IMFS_is_imfs_instance>         
400049bc:	ba 10 00 08 	mov  %o0, %i5                                  
400049c0:	80 a2 20 00 	cmp  %o0, 0                                    
400049c4:	02 80 00 15 	be  40004a18 <IMFS_make_generic_node+0xf8>     
400049c8:	90 07 bf c8 	add  %fp, -56, %o0                             
        IMFS_types_union info;                                        
        IMFS_jnode_t *new_node;                                       
                                                                      
        info.generic.context = context;                               
        new_node = IMFS_create_node_with_control(                     
400049cc:	d4 1f bf d0 	ldd  [ %fp + -48 ], %o2                        
                                                                      
      if ( IMFS_is_imfs_instance( currentloc ) ) {                    
        IMFS_types_union info;                                        
        IMFS_jnode_t *new_node;                                       
                                                                      
        info.generic.context = context;                               
400049d0:	f6 27 bf b0 	st  %i3, [ %fp + -80 ]                         
        new_node = IMFS_create_node_with_control(                     
400049d4:	90 10 00 1d 	mov  %i5, %o0                                  
400049d8:	92 10 00 1a 	mov  %i2, %o1                                  
400049dc:	98 10 00 19 	mov  %i1, %o4                                  
400049e0:	9a 07 bf b0 	add  %fp, -80, %o5                             
400049e4:	40 00 2d 7f 	call  4000ffe0 <IMFS_create_node_with_control> 
400049e8:	b0 10 3f ff 	mov  -1, %i0                                   
          rtems_filesystem_eval_path_get_tokenlen( &ctx ),            
          mode,                                                       
          &info                                                       
        );                                                            
                                                                      
        if ( new_node != NULL ) {                                     
400049ec:	80 a2 20 00 	cmp  %o0, 0                                    
400049f0:	02 80 00 0d 	be  40004a24 <IMFS_make_generic_node+0x104>    
400049f4:	90 07 bf a8 	add  %fp, -88, %o0                             
          IMFS_jnode_t *parent = currentloc->node_access;             
400049f8:	fa 07 60 08 	ld  [ %i5 + 8 ], %i5                           
                                                                      
static inline void IMFS_mtime_ctime_update( IMFS_jnode_t *jnode )     
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
400049fc:	40 00 01 d9 	call  40005160 <gettimeofday>                  
40004a00:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_mtime = now.tv_sec;                                     
40004a04:	c2 07 bf a8 	ld  [ %fp + -88 ], %g1                         
40004a08:	b0 10 20 00 	clr  %i0                                       
40004a0c:	c2 27 60 44 	st  %g1, [ %i5 + 0x44 ]                        
  jnode->stat_ctime = now.tv_sec;                                     
40004a10:	10 80 00 05 	b  40004a24 <IMFS_make_generic_node+0x104>     
40004a14:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
          IMFS_mtime_ctime_update( parent );                          
        } else {                                                      
          rv = -1;                                                    
        }                                                             
      } else {                                                        
        rtems_filesystem_eval_path_error( &ctx, ENOTSUP );            
40004a18:	92 10 20 86 	mov  0x86, %o1                                 
40004a1c:	40 00 06 17 	call  40006278 <rtems_filesystem_eval_path_error>
40004a20:	b0 10 3f ff 	mov  -1, %i0                                   
        rv = -1;                                                      
      }                                                               
                                                                      
      rtems_filesystem_eval_path_cleanup( &ctx );                     
40004a24:	40 00 06 d0 	call  40006564 <rtems_filesystem_eval_path_cleanup>
40004a28:	90 07 bf c8 	add  %fp, -56, %o0                             
40004a2c:	81 c7 e0 08 	ret                                            
40004a30:	81 e8 00 00 	restore                                        
                                                                      

4000dfec <IMFS_memfile_addblock>: */ MEMFILE_STATIC int IMFS_memfile_addblock( IMFS_jnode_t *the_jnode, unsigned int block ) {
4000dfec:	9d e3 bf a0 	save  %sp, -96, %sp                            
  IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE );          
                                                                      
  /*                                                                  
   * Obtain the pointer for the specified block number                
   */                                                                 
  block_entry_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 1 );
4000dff0:	94 10 20 01 	mov  1, %o2                                    
4000dff4:	90 10 00 18 	mov  %i0, %o0                                  
4000dff8:	7f ff fe d6 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000dffc:	92 10 00 19 	mov  %i1, %o1                                  
  if ( !block_entry_ptr )                                             
4000e000:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e004:	32 80 00 04 	bne,a   4000e014 <IMFS_memfile_addblock+0x28>  <== ALWAYS TAKEN
4000e008:	c2 07 40 00 	ld  [ %i5 ], %g1                               
    return 1;                                                         
4000e00c:	81 c7 e0 08 	ret                                            
4000e010:	91 e8 20 01 	restore  %g0, 1, %o0                           
                                                                      
  if ( *block_entry_ptr )                                             
4000e014:	80 a0 60 00 	cmp  %g1, 0                                    
4000e018:	12 80 00 08 	bne  4000e038 <IMFS_memfile_addblock+0x4c>     
4000e01c:	b0 10 20 00 	clr  %i0                                       
    return 0;                                                         
                                                                      
  /*                                                                  
   *  There is no memory for this block number so allocate it.        
   */                                                                 
  memory = memfile_alloc_block();                                     
4000e020:	7f ff fe bf 	call  4000db1c <memfile_alloc_block>           
4000e024:	01 00 00 00 	nop                                            
  if ( !memory )                                                      
4000e028:	80 a2 20 00 	cmp  %o0, 0                                    
4000e02c:	02 bf ff f8 	be  4000e00c <IMFS_memfile_addblock+0x20>      
4000e030:	01 00 00 00 	nop                                            
    return 1;                                                         
                                                                      
  *block_entry_ptr = memory;                                          
4000e034:	d0 27 40 00 	st  %o0, [ %i5 ]                               
  return 0;                                                           
}                                                                     
4000e038:	81 c7 e0 08 	ret                                            
4000e03c:	81 e8 00 00 	restore                                        
                                                                      

4000e09c <IMFS_memfile_extend>: MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) {
4000e09c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE );        
                                                                      
  /*                                                                  
   *  Verify new file size is supported                               
   */                                                                 
  if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE )                      
4000e0a0:	21 10 00 5f 	sethi  %hi(0x40017c00), %l0                    
4000e0a4:	fa 04 21 74 	ld  [ %l0 + 0x174 ], %i5	! 40017d74 <imfs_memfile_bytes_per_block>
4000e0a8:	a4 10 00 10 	mov  %l0, %l2                                  
4000e0ac:	b9 37 60 02 	srl  %i5, 2, %i4                               
4000e0b0:	92 10 00 1c 	mov  %i4, %o1                                  
4000e0b4:	40 00 14 cf 	call  400133f0 <.umul>                         
4000e0b8:	90 07 20 01 	add  %i4, 1, %o0                               
4000e0bc:	92 10 00 1c 	mov  %i4, %o1                                  
4000e0c0:	40 00 14 cc 	call  400133f0 <.umul>                         
4000e0c4:	90 02 20 01 	inc  %o0                                       
4000e0c8:	92 10 00 1d 	mov  %i5, %o1                                  
4000e0cc:	40 00 14 c9 	call  400133f0 <.umul>                         
4000e0d0:	90 02 3f ff 	add  %o0, -1, %o0                              
4000e0d4:	82 10 20 00 	clr  %g1                                       
4000e0d8:	80 a0 40 1a 	cmp  %g1, %i2                                  
4000e0dc:	34 80 00 0b 	bg,a   4000e108 <IMFS_memfile_extend+0x6c>     <== NEVER TAKEN
4000e0e0:	f8 06 20 50 	ld  [ %i0 + 0x50 ], %i4                        <== NOT EXECUTED
4000e0e4:	80 a0 40 1a 	cmp  %g1, %i2                                  
4000e0e8:	12 80 00 04 	bne  4000e0f8 <IMFS_memfile_extend+0x5c>       <== NEVER TAKEN
4000e0ec:	80 a2 00 1b 	cmp  %o0, %i3                                  
4000e0f0:	38 80 00 06 	bgu,a   4000e108 <IMFS_memfile_extend+0x6c>    
4000e0f4:	f8 06 20 50 	ld  [ %i0 + 0x50 ], %i4                        
    rtems_set_errno_and_return_minus_one( EFBIG );                    
4000e0f8:	40 00 06 4a 	call  4000fa20 <__errno>                       
4000e0fc:	01 00 00 00 	nop                                            
4000e100:	10 80 00 20 	b  4000e180 <IMFS_memfile_extend+0xe4>         
4000e104:	82 10 20 1b 	mov  0x1b, %g1	! 1b <_TLS_Alignment+0x1a>      
                                                                      
  /*                                                                  
   *  Verify new file size is actually larger than current size       
   */                                                                 
  if ( new_length <= the_jnode->info.file.size )                      
4000e108:	80 a6 80 1c 	cmp  %i2, %i4                                  
4000e10c:	14 80 00 07 	bg  4000e128 <IMFS_memfile_extend+0x8c>        <== NEVER TAKEN
4000e110:	e0 06 20 54 	ld  [ %i0 + 0x54 ], %l0                        
4000e114:	80 a6 80 1c 	cmp  %i2, %i4                                  
4000e118:	12 80 00 45 	bne  4000e22c <IMFS_memfile_extend+0x190>      <== NEVER TAKEN
4000e11c:	80 a6 c0 10 	cmp  %i3, %l0                                  
4000e120:	08 80 00 43 	bleu  4000e22c <IMFS_memfile_extend+0x190>     <== NEVER TAKEN
4000e124:	01 00 00 00 	nop                                            
    return 0;                                                         
                                                                      
  /*                                                                  
   *  Calculate the number of range of blocks to allocate             
   */                                                                 
  new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;             
4000e128:	a3 3f 60 1f 	sra  %i5, 0x1f, %l1                            
4000e12c:	96 10 00 1d 	mov  %i5, %o3                                  
4000e130:	94 10 00 11 	mov  %l1, %o2                                  
4000e134:	90 10 00 1a 	mov  %i2, %o0                                  
4000e138:	40 00 16 40 	call  40013a38 <__divdi3>                      
4000e13c:	92 10 00 1b 	mov  %i3, %o1                                  
  old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
4000e140:	94 10 00 11 	mov  %l1, %o2                                  
4000e144:	90 10 00 1c 	mov  %i4, %o0                                  
4000e148:	96 10 00 1d 	mov  %i5, %o3                                  
    return 0;                                                         
                                                                      
  /*                                                                  
   *  Calculate the number of range of blocks to allocate             
   */                                                                 
  new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;             
4000e14c:	a6 10 00 09 	mov  %o1, %l3                                  
  old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
4000e150:	40 00 16 3a 	call  40013a38 <__divdi3>                      
4000e154:	92 10 00 10 	mov  %l0, %o1                                  
  offset = the_jnode->info.file.size - old_blocks * IMFS_MEMFILE_BYTES_PER_BLOCK;
                                                                      
  /*                                                                  
   *  Now allocate each of those blocks.                              
   */                                                                 
  for ( block=old_blocks ; block<=new_blocks ; block++ ) {            
4000e158:	a2 10 20 00 	clr  %l1                                       
  /*                                                                  
   *  Calculate the number of range of blocks to allocate             
   */                                                                 
  new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;             
  old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
  offset = the_jnode->info.file.size - old_blocks * IMFS_MEMFILE_BYTES_PER_BLOCK;
4000e15c:	90 10 00 09 	mov  %o1, %o0                                  
                                                                      
  /*                                                                  
   *  Calculate the number of range of blocks to allocate             
   */                                                                 
  new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;             
  old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
4000e160:	b8 10 00 09 	mov  %o1, %i4                                  
  offset = the_jnode->info.file.size - old_blocks * IMFS_MEMFILE_BYTES_PER_BLOCK;
4000e164:	40 00 14 a3 	call  400133f0 <.umul>                         
4000e168:	92 10 00 1d 	mov  %i5, %o1                                  
                                                                      
  /*                                                                  
   *  Now allocate each of those blocks.                              
   */                                                                 
  for ( block=old_blocks ; block<=new_blocks ; block++ ) {            
4000e16c:	10 80 00 1c 	b  4000e1dc <IMFS_memfile_extend+0x140>        
4000e170:	a0 24 00 08 	sub  %l0, %o0, %l0                             
       }                                                              
    } else {                                                          
       for ( ; block>=old_blocks ; block-- ) {                        
         IMFS_memfile_remove_block( the_jnode, block );               
       }                                                              
       rtems_set_errno_and_return_minus_one( ENOSPC );                
4000e174:	40 00 06 2b 	call  4000fa20 <__errno>                       
4000e178:	01 00 00 00 	nop                                            
4000e17c:	82 10 20 1c 	mov  0x1c, %g1	! 1c <_TLS_Alignment+0x1b>      
4000e180:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000e184:	81 c7 e0 08 	ret                                            
4000e188:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  /*                                                                  
   *  Now allocate each of those blocks.                              
   */                                                                 
  for ( block=old_blocks ; block<=new_blocks ; block++ ) {            
    if ( !IMFS_memfile_addblock( the_jnode, block ) ) {               
4000e18c:	7f ff ff 98 	call  4000dfec <IMFS_memfile_addblock>         
4000e190:	92 10 00 1d 	mov  %i5, %o1                                  
4000e194:	80 a2 20 00 	cmp  %o0, 0                                    
4000e198:	12 80 00 17 	bne  4000e1f4 <IMFS_memfile_extend+0x158>      
4000e19c:	80 a6 60 00 	cmp  %i1, 0                                    
       if ( zero_fill ) {                                             
4000e1a0:	22 80 00 0f 	be,a   4000e1dc <IMFS_memfile_extend+0x140>    
4000e1a4:	a2 04 60 01 	inc  %l1                                       
          size_t count = IMFS_MEMFILE_BYTES_PER_BLOCK - offset;       
4000e1a8:	e8 04 a1 74 	ld  [ %l2 + 0x174 ], %l4                       
          block_p *block_ptr =                                        
4000e1ac:	92 10 00 1d 	mov  %i5, %o1                                  
4000e1b0:	94 10 20 00 	clr  %o2                                       
4000e1b4:	7f ff fe 67 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000e1b8:	90 10 00 18 	mov  %i0, %o0                                  
            IMFS_memfile_get_block_pointer( the_jnode, block, 0 );    
                                                                      
          memset( &(*block_ptr) [offset], 0, count);                  
4000e1bc:	d0 02 00 00 	ld  [ %o0 ], %o0                               
   *  Now allocate each of those blocks.                              
   */                                                                 
  for ( block=old_blocks ; block<=new_blocks ; block++ ) {            
    if ( !IMFS_memfile_addblock( the_jnode, block ) ) {               
       if ( zero_fill ) {                                             
          size_t count = IMFS_MEMFILE_BYTES_PER_BLOCK - offset;       
4000e1c0:	a8 25 00 10 	sub  %l4, %l0, %l4                             
          block_p *block_ptr =                                        
            IMFS_memfile_get_block_pointer( the_jnode, block, 0 );    
                                                                      
          memset( &(*block_ptr) [offset], 0, count);                  
4000e1c4:	90 02 00 10 	add  %o0, %l0, %o0                             
4000e1c8:	92 10 20 00 	clr  %o1                                       
4000e1cc:	94 10 00 14 	mov  %l4, %o2                                  
4000e1d0:	40 00 08 39 	call  400102b4 <memset>                        
4000e1d4:	a0 10 20 00 	clr  %l0                                       
4000e1d8:	a2 04 60 01 	inc  %l1                                       
4000e1dc:	ba 04 40 1c 	add  %l1, %i4, %i5                             
  offset = the_jnode->info.file.size - old_blocks * IMFS_MEMFILE_BYTES_PER_BLOCK;
                                                                      
  /*                                                                  
   *  Now allocate each of those blocks.                              
   */                                                                 
  for ( block=old_blocks ; block<=new_blocks ; block++ ) {            
4000e1e0:	80 a7 40 13 	cmp  %i5, %l3                                  
4000e1e4:	08 bf ff ea 	bleu  4000e18c <IMFS_memfile_extend+0xf0>      
4000e1e8:	90 10 00 18 	mov  %i0, %o0                                  
4000e1ec:	10 80 00 0a 	b  4000e214 <IMFS_memfile_extend+0x178>        
4000e1f0:	f4 3e 20 50 	std  %i2, [ %i0 + 0x50 ]                       
                                                                      
          memset( &(*block_ptr) [offset], 0, count);                  
          offset = 0;                                                 
       }                                                              
    } else {                                                          
       for ( ; block>=old_blocks ; block-- ) {                        
4000e1f4:	80 a7 40 1c 	cmp  %i5, %i4                                  
4000e1f8:	0a bf ff df 	bcs  4000e174 <IMFS_memfile_extend+0xd8>       
4000e1fc:	92 10 00 1d 	mov  %i5, %o1                                  
         IMFS_memfile_remove_block( the_jnode, block );               
4000e200:	90 10 00 18 	mov  %i0, %o0                                  
4000e204:	7f ff ff 98 	call  4000e064 <IMFS_memfile_remove_block>     
4000e208:	ba 07 7f ff 	add  %i5, -1, %i5                              
                                                                      
          memset( &(*block_ptr) [offset], 0, count);                  
          offset = 0;                                                 
       }                                                              
    } else {                                                          
       for ( ; block>=old_blocks ; block-- ) {                        
4000e20c:	10 bf ff fb 	b  4000e1f8 <IMFS_memfile_extend+0x15c>        
4000e210:	80 a7 40 1c 	cmp  %i5, %i4                                  
                                                                      
static inline void IMFS_mtime_ctime_update( IMFS_jnode_t *jnode )     
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
4000e214:	90 07 bf f8 	add  %fp, -8, %o0                              
4000e218:	7f ff d5 a7 	call  400038b4 <gettimeofday>                  
4000e21c:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_mtime = now.tv_sec;                                     
4000e220:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000e224:	c2 26 20 44 	st  %g1, [ %i0 + 0x44 ]                        
  jnode->stat_ctime = now.tv_sec;                                     
4000e228:	c2 26 20 48 	st  %g1, [ %i0 + 0x48 ]                        
   */                                                                 
  the_jnode->info.file.size = new_length;                             
                                                                      
  IMFS_mtime_ctime_update(the_jnode);                                 
  return 0;                                                           
}                                                                     
4000e22c:	81 c7 e0 08 	ret                                            
4000e230:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000db50 <IMFS_memfile_get_block_pointer>: #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) {
4000db50:	9d e3 bf a0 	save  %sp, -96, %sp                            
  my_block = block;                                                   
                                                                      
  /*                                                                  
   *  Is the block number in the simple indirect portion?             
   */                                                                 
  if ( my_block <= LAST_INDIRECT ) {                                  
4000db54:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
4000db58:	fa 00 61 74 	ld  [ %g1 + 0x174 ], %i5	! 40017d74 <imfs_memfile_bytes_per_block>
4000db5c:	bb 37 60 02 	srl  %i5, 2, %i5                               
4000db60:	82 07 7f ff 	add  %i5, -1, %g1                              
4000db64:	80 a6 40 01 	cmp  %i1, %g1                                  
4000db68:	18 80 00 18 	bgu  4000dbc8 <IMFS_memfile_get_block_pointer+0x78>
4000db6c:	90 07 60 01 	add  %i5, 1, %o0                               
    p = info->indirect;                                               
                                                                      
    if ( malloc_it ) {                                                
4000db70:	80 a6 a0 00 	cmp  %i2, 0                                    
4000db74:	02 80 00 10 	be  4000dbb4 <IMFS_memfile_get_block_pointer+0x64>
4000db78:	c2 06 20 58 	ld  [ %i0 + 0x58 ], %g1                        
                                                                      
      if ( !p ) {                                                     
4000db7c:	80 a0 60 00 	cmp  %g1, 0                                    
4000db80:	32 80 00 0a 	bne,a   4000dba8 <IMFS_memfile_get_block_pointer+0x58>
4000db84:	f0 06 20 58 	ld  [ %i0 + 0x58 ], %i0                        
        p = memfile_alloc_block();                                    
4000db88:	7f ff ff e5 	call  4000db1c <memfile_alloc_block>           
4000db8c:	01 00 00 00 	nop                                            
        if ( !p )                                                     
4000db90:	80 a2 20 00 	cmp  %o0, 0                                    
4000db94:	32 80 00 04 	bne,a   4000dba4 <IMFS_memfile_get_block_pointer+0x54><== ALWAYS TAKEN
4000db98:	d0 26 20 58 	st  %o0, [ %i0 + 0x58 ]                        
           return 0;                                                  
4000db9c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000dba0:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
        info->indirect = p;                                           
      }                                                               
      return &info->indirect[ my_block ];                             
4000dba4:	f0 06 20 58 	ld  [ %i0 + 0x58 ], %i0                        
4000dba8:	b3 2e 60 02 	sll  %i1, 2, %i1                               
4000dbac:	81 c7 e0 08 	ret                                            
4000dbb0:	91 ee 00 19 	restore  %i0, %i1, %o0                         
    }                                                                 
                                                                      
    if ( !p )                                                         
4000dbb4:	80 a0 60 00 	cmp  %g1, 0                                    
4000dbb8:	02 bf ff f9 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dbbc:	b3 2e 60 02 	sll  %i1, 2, %i1                               
      return 0;                                                       
                                                                      
    return &info->indirect[ my_block ];                               
4000dbc0:	81 c7 e0 08 	ret                                            
4000dbc4:	91 e8 40 19 	restore  %g1, %i1, %o0                         
                                                                      
  /*                                                                  
   *  Is the block number in the doubly indirect portion?             
   */                                                                 
                                                                      
  if ( my_block <= LAST_DOUBLY_INDIRECT ) {                           
4000dbc8:	40 00 16 0a 	call  400133f0 <.umul>                         
4000dbcc:	92 10 00 1d 	mov  %i5, %o1                                  
4000dbd0:	82 02 3f ff 	add  %o0, -1, %g1                              
4000dbd4:	80 a6 40 01 	cmp  %i1, %g1                                  
4000dbd8:	18 80 00 2c 	bgu  4000dc88 <IMFS_memfile_get_block_pointer+0x138>
4000dbdc:	b8 10 00 08 	mov  %o0, %i4                                  
    my_block -= FIRST_DOUBLY_INDIRECT;                                
4000dbe0:	b2 26 40 1d 	sub  %i1, %i5, %i1                             
                                                                      
    singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dbe4:	92 10 00 1d 	mov  %i5, %o1                                  
4000dbe8:	40 00 16 e8 	call  40013788 <.urem>                         
4000dbec:	90 10 00 19 	mov  %i1, %o0                                  
    doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dbf0:	92 10 00 1d 	mov  %i5, %o1                                  
   */                                                                 
                                                                      
  if ( my_block <= LAST_DOUBLY_INDIRECT ) {                           
    my_block -= FIRST_DOUBLY_INDIRECT;                                
                                                                      
    singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dbf4:	b8 10 00 08 	mov  %o0, %i4                                  
    doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dbf8:	40 00 16 38 	call  400134d8 <.udiv>                         
4000dbfc:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
    p = info->doubly_indirect;                                        
    if ( malloc_it ) {                                                
4000dc00:	80 a6 a0 00 	cmp  %i2, 0                                    
                                                                      
  if ( my_block <= LAST_DOUBLY_INDIRECT ) {                           
    my_block -= FIRST_DOUBLY_INDIRECT;                                
                                                                      
    singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;                     
    doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dc04:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    p = info->doubly_indirect;                                        
    if ( malloc_it ) {                                                
4000dc08:	02 80 00 17 	be  4000dc64 <IMFS_memfile_get_block_pointer+0x114>
4000dc0c:	d0 06 20 5c 	ld  [ %i0 + 0x5c ], %o0                        
                                                                      
      if ( !p ) {                                                     
4000dc10:	80 a2 20 00 	cmp  %o0, 0                                    
4000dc14:	12 80 00 08 	bne  4000dc34 <IMFS_memfile_get_block_pointer+0xe4>
4000dc18:	bb 2f 60 02 	sll  %i5, 2, %i5                               
        p = memfile_alloc_block();                                    
4000dc1c:	7f ff ff c0 	call  4000db1c <memfile_alloc_block>           
4000dc20:	01 00 00 00 	nop                                            
        if ( !p )                                                     
4000dc24:	80 a2 20 00 	cmp  %o0, 0                                    
4000dc28:	02 bf ff dd 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dc2c:	01 00 00 00 	nop                                            
           return 0;                                                  
        info->doubly_indirect = p;                                    
4000dc30:	d0 26 20 5c 	st  %o0, [ %i0 + 0x5c ]                        
      }                                                               
                                                                      
      p1 = (block_p *)p[ doubly ];                                    
4000dc34:	b6 02 00 1d 	add  %o0, %i5, %i3                             
4000dc38:	d0 02 00 1d 	ld  [ %o0 + %i5 ], %o0                         
      if ( !p1 ) {                                                    
4000dc3c:	80 a2 20 00 	cmp  %o0, 0                                    
4000dc40:	12 80 00 4a 	bne  4000dd68 <IMFS_memfile_get_block_pointer+0x218>
4000dc44:	b1 2f 20 02 	sll  %i4, 2, %i0                               
        p1 = memfile_alloc_block();                                   
4000dc48:	7f ff ff b5 	call  4000db1c <memfile_alloc_block>           
4000dc4c:	01 00 00 00 	nop                                            
        if ( !p1 )                                                    
4000dc50:	80 a2 20 00 	cmp  %o0, 0                                    
4000dc54:	02 bf ff d2 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dc58:	01 00 00 00 	nop                                            
           return 0;                                                  
        p[ doubly ] = (block_p) p1;                                   
4000dc5c:	10 80 00 43 	b  4000dd68 <IMFS_memfile_get_block_pointer+0x218>
4000dc60:	d0 26 c0 00 	st  %o0, [ %i3 ]                               
      }                                                               
                                                                      
      return (block_p *)&p1[ singly ];                                
    }                                                                 
                                                                      
    if ( !p )                                                         
4000dc64:	80 a2 20 00 	cmp  %o0, 0                                    
4000dc68:	02 bf ff cd 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dc6c:	bb 2f 60 02 	sll  %i5, 2, %i5                               
      return 0;                                                       
                                                                      
    p = (block_p *)p[ doubly ];                                       
4000dc70:	c2 02 00 1d 	ld  [ %o0 + %i5 ], %g1                         
    if ( !p )                                                         
4000dc74:	80 a0 60 00 	cmp  %g1, 0                                    
4000dc78:	02 bf ff c9 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dc7c:	01 00 00 00 	nop                                            
      return 0;                                                       
                                                                      
    return (block_p *)&p[ singly ];                                   
4000dc80:	10 80 00 48 	b  4000dda0 <IMFS_memfile_get_block_pointer+0x250>
4000dc84:	b1 2f 20 02 	sll  %i4, 2, %i0                               
  }                                                                   
                                                                      
  /*                                                                  
   *  Is the block number in the triply indirect portion?             
   */                                                                 
  if ( my_block <= LAST_TRIPLY_INDIRECT ) {                           
4000dc88:	90 02 20 01 	inc  %o0                                       
4000dc8c:	40 00 15 d9 	call  400133f0 <.umul>                         
4000dc90:	92 10 00 1d 	mov  %i5, %o1                                  
4000dc94:	90 02 3f ff 	add  %o0, -1, %o0                              
4000dc98:	80 a6 40 08 	cmp  %i1, %o0                                  
4000dc9c:	18 bf ff c0 	bgu  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dca0:	b2 26 40 1c 	sub  %i1, %i4, %i1                             
    my_block -= FIRST_TRIPLY_INDIRECT;                                
                                                                      
    singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dca4:	92 10 00 1d 	mov  %i5, %o1                                  
4000dca8:	40 00 16 b8 	call  40013788 <.urem>                         
4000dcac:	90 10 00 19 	mov  %i1, %o0                                  
    doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dcb0:	92 10 00 1d 	mov  %i5, %o1                                  
   *  Is the block number in the triply indirect portion?             
   */                                                                 
  if ( my_block <= LAST_TRIPLY_INDIRECT ) {                           
    my_block -= FIRST_TRIPLY_INDIRECT;                                
                                                                      
    singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dcb4:	b6 10 00 08 	mov  %o0, %i3                                  
    doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;                     
4000dcb8:	40 00 16 08 	call  400134d8 <.udiv>                         
4000dcbc:	90 10 00 19 	mov  %i1, %o0                                  
    triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS;                       
4000dcc0:	92 10 00 1d 	mov  %i5, %o1                                  
4000dcc4:	40 00 16 05 	call  400134d8 <.udiv>                         
4000dcc8:	b2 10 00 08 	mov  %o0, %i1                                  
    doubly %= IMFS_MEMFILE_BLOCK_SLOTS;                               
4000dccc:	92 10 00 1d 	mov  %i5, %o1                                  
  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;                       
4000dcd0:	b8 10 00 08 	mov  %o0, %i4                                  
    doubly %= IMFS_MEMFILE_BLOCK_SLOTS;                               
4000dcd4:	40 00 16 ad 	call  40013788 <.urem>                         
4000dcd8:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
    p = info->triply_indirect;                                        
                                                                      
    if ( malloc_it ) {                                                
4000dcdc:	80 a6 a0 00 	cmp  %i2, 0                                    
    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;                               
4000dce0:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    p = info->triply_indirect;                                        
                                                                      
    if ( malloc_it ) {                                                
4000dce4:	02 80 00 23 	be  4000dd70 <IMFS_memfile_get_block_pointer+0x220>
4000dce8:	d0 06 20 60 	ld  [ %i0 + 0x60 ], %o0                        
      if ( !p ) {                                                     
4000dcec:	80 a2 20 00 	cmp  %o0, 0                                    
4000dcf0:	12 80 00 08 	bne  4000dd10 <IMFS_memfile_get_block_pointer+0x1c0>
4000dcf4:	b9 2f 20 02 	sll  %i4, 2, %i4                               
        p = memfile_alloc_block();                                    
4000dcf8:	7f ff ff 89 	call  4000db1c <memfile_alloc_block>           
4000dcfc:	01 00 00 00 	nop                                            
        if ( !p )                                                     
4000dd00:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd04:	02 bf ff a6 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dd08:	01 00 00 00 	nop                                            
           return 0;                                                  
        info->triply_indirect = p;                                    
4000dd0c:	d0 26 20 60 	st  %o0, [ %i0 + 0x60 ]                        
      }                                                               
                                                                      
      p1 = (block_p *) p[ triply ];                                   
4000dd10:	b4 02 00 1c 	add  %o0, %i4, %i2                             
4000dd14:	d0 02 00 1c 	ld  [ %o0 + %i4 ], %o0                         
      if ( !p1 ) {                                                    
4000dd18:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd1c:	12 80 00 08 	bne  4000dd3c <IMFS_memfile_get_block_pointer+0x1ec>
4000dd20:	bb 2f 60 02 	sll  %i5, 2, %i5                               
        p1 = memfile_alloc_block();                                   
4000dd24:	7f ff ff 7e 	call  4000db1c <memfile_alloc_block>           
4000dd28:	01 00 00 00 	nop                                            
        if ( !p1 )                                                    
4000dd2c:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd30:	02 bf ff 9b 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dd34:	01 00 00 00 	nop                                            
           return 0;                                                  
        p[ triply ] = (block_p) p1;                                   
4000dd38:	d0 26 80 00 	st  %o0, [ %i2 ]                               
      }                                                               
                                                                      
      p2 = (block_p *)p1[ doubly ];                                   
4000dd3c:	b8 02 00 1d 	add  %o0, %i5, %i4                             
4000dd40:	d0 02 00 1d 	ld  [ %o0 + %i5 ], %o0                         
      if ( !p2 ) {                                                    
4000dd44:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd48:	12 80 00 08 	bne  4000dd68 <IMFS_memfile_get_block_pointer+0x218>
4000dd4c:	b1 2e e0 02 	sll  %i3, 2, %i0                               
        p2 = memfile_alloc_block();                                   
4000dd50:	7f ff ff 73 	call  4000db1c <memfile_alloc_block>           
4000dd54:	01 00 00 00 	nop                                            
        if ( !p2 )                                                    
4000dd58:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd5c:	02 bf ff 90 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dd60:	01 00 00 00 	nop                                            
           return 0;                                                  
        p1[ doubly ] = (block_p) p2;                                  
4000dd64:	d0 27 00 00 	st  %o0, [ %i4 ]                               
      }                                                               
      return (block_p *)&p2[ singly ];                                
4000dd68:	81 c7 e0 08 	ret                                            
4000dd6c:	91 ea 00 18 	restore  %o0, %i0, %o0                         
    }                                                                 
                                                                      
    if ( !p )                                                         
4000dd70:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd74:	02 bf ff 8a 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dd78:	b9 2f 20 02 	sll  %i4, 2, %i4                               
      return 0;                                                       
                                                                      
    p1 = (block_p *) p[ triply ];                                     
4000dd7c:	c2 02 00 1c 	ld  [ %o0 + %i4 ], %g1                         
    if ( !p1 )                                                        
4000dd80:	80 a0 60 00 	cmp  %g1, 0                                    
4000dd84:	02 bf ff 86 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dd88:	bb 2f 60 02 	sll  %i5, 2, %i5                               
      return 0;                                                       
                                                                      
    p2 = (block_p *)p1[ doubly ];                                     
4000dd8c:	c2 00 40 1d 	ld  [ %g1 + %i5 ], %g1                         
    if ( !p2 )                                                        
4000dd90:	80 a0 60 00 	cmp  %g1, 0                                    
4000dd94:	02 bf ff 82 	be  4000db9c <IMFS_memfile_get_block_pointer+0x4c><== NEVER TAKEN
4000dd98:	01 00 00 00 	nop                                            
      return 0;                                                       
                                                                      
    return (block_p *)&p2[ singly ];                                  
4000dd9c:	b1 2e e0 02 	sll  %i3, 2, %i0                               
                                                                      
  /*                                                                  
   *  This means the requested block number is out of range.          
   */                                                                 
  return 0;                                                           
}                                                                     
4000dda0:	81 c7 e0 08 	ret                                            
4000dda4:	91 e8 40 18 	restore  %g1, %i0, %o0                         
                                                                      

4000dda8 <IMFS_memfile_read>: IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) {
4000dda8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_chain_extract_unprotected( &node->Node );                     
}                                                                     
                                                                      
static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node )
{                                                                     
  return node->control->imfs_type;                                    
4000ddac:	c2 06 20 4c 	ld  [ %i0 + 0x4c ], %g1                        
4000ddb0:	ba 10 00 18 	mov  %i0, %i5                                  
   *  Linear files (as created from a tar file are easier to handle   
   *  than block files).                                              
   */                                                                 
  my_length = length;                                                 
                                                                      
  if ( IMFS_type( the_jnode ) == IMFS_LINEAR_FILE ) {                 
4000ddb4:	c2 00 40 00 	ld  [ %g1 ], %g1                               
   IMFS_jnode_t    *the_jnode,                                        
   off_t            start,                                            
   unsigned char   *destination,                                      
   unsigned int     length                                            
)                                                                     
{                                                                     
4000ddb8:	a0 10 00 19 	mov  %i1, %l0                                  
4000ddbc:	a2 10 00 1a 	mov  %i2, %l1                                  
   *  Linear files (as created from a tar file are easier to handle   
   *  than block files).                                              
   */                                                                 
  my_length = length;                                                 
                                                                      
  if ( IMFS_type( the_jnode ) == IMFS_LINEAR_FILE ) {                 
4000ddc0:	80 a0 60 05 	cmp  %g1, 5                                    
4000ddc4:	12 80 00 1a 	bne  4000de2c <IMFS_memfile_read+0x84>         
4000ddc8:	a4 10 00 1b 	mov  %i3, %l2                                  
    unsigned char  *file_ptr;                                         
                                                                      
    file_ptr = (unsigned char *)the_jnode->info.linearfile.direct;    
                                                                      
    if (my_length > (the_jnode->info.linearfile.size - start))        
4000ddcc:	f4 1e 20 50 	ldd  [ %i0 + 0x50 ], %i2                       
4000ddd0:	82 10 20 00 	clr  %g1                                       
4000ddd4:	86 a6 c0 11 	subcc  %i3, %l1, %g3                           
4000ddd8:	84 66 80 19 	subx  %i2, %i1, %g2                            
4000dddc:	80 a0 40 02 	cmp  %g1, %g2                                  
4000dde0:	14 80 00 07 	bg  4000ddfc <IMFS_memfile_read+0x54>          <== NEVER TAKEN
4000dde4:	d2 06 20 58 	ld  [ %i0 + 0x58 ], %o1                        
4000dde8:	80 a0 40 02 	cmp  %g1, %g2                                  
4000ddec:	12 80 00 05 	bne  4000de00 <IMFS_memfile_read+0x58>         <== NEVER TAKEN
4000ddf0:	80 a7 00 03 	cmp  %i4, %g3                                  
4000ddf4:	28 80 00 04 	bleu,a   4000de04 <IMFS_memfile_read+0x5c>     <== NEVER TAKEN
4000ddf8:	92 02 40 11 	add  %o1, %l1, %o1                             <== NOT EXECUTED
      my_length = the_jnode->info.linearfile.size - start;            
4000ddfc:	b8 26 c0 11 	sub  %i3, %l1, %i4                             
                                                                      
    memcpy(dest, &file_ptr[start], my_length);                        
4000de00:	92 02 40 11 	add  %o1, %l1, %o1                             
4000de04:	94 10 00 1c 	mov  %i4, %o2                                  
4000de08:	40 00 08 ec 	call  400101b8 <memcpy>                        
4000de0c:	90 10 00 12 	mov  %l2, %o0                                  
                                                                      
static inline void IMFS_update_atime( IMFS_jnode_t *jnode )           
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
4000de10:	90 07 bf f8 	add  %fp, -8, %o0                              
4000de14:	7f ff d6 a8 	call  400038b4 <gettimeofday>                  
4000de18:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_atime = now.tv_sec;                                     
4000de1c:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000de20:	c2 27 60 40 	st  %g1, [ %i5 + 0x40 ]                        
                                                                      
    IMFS_update_atime( the_jnode );                                   
                                                                      
    return my_length;                                                 
4000de24:	81 c7 e0 08 	ret                                            
4000de28:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
  /*                                                                  
   *  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 )                        
4000de2c:	c4 06 20 50 	ld  [ %i0 + 0x50 ], %g2                        
4000de30:	86 10 20 00 	clr  %g3                                       
4000de34:	c2 06 20 54 	ld  [ %i0 + 0x54 ], %g1                        
4000de38:	80 a0 c0 02 	cmp  %g3, %g2                                  
4000de3c:	14 80 00 08 	bg  4000de5c <IMFS_memfile_read+0xb4>          <== NEVER TAKEN
4000de40:	88 07 00 1a 	add  %i4, %i2, %g4                             
4000de44:	80 a0 c0 02 	cmp  %g3, %g2                                  
4000de48:	12 80 00 07 	bne  4000de64 <IMFS_memfile_read+0xbc>         <== NEVER TAKEN
4000de4c:	33 10 00 5f 	sethi  %hi(0x40017c00), %i1                    
4000de50:	80 a1 00 01 	cmp  %g4, %g1                                  
4000de54:	08 80 00 05 	bleu  4000de68 <IMFS_memfile_read+0xc0>        
4000de58:	f6 06 61 74 	ld  [ %i1 + 0x174 ], %i3                       
    my_length = the_jnode->info.file.size - start;                    
4000de5c:	b8 20 40 11 	sub  %g1, %l1, %i4                             
   */                                                                 
                                                                      
  /*                                                                  
   *  Phase 1: possibly the last part of one block                    
   */                                                                 
  start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;                
4000de60:	33 10 00 5f 	sethi  %hi(0x40017c00), %i1                    
4000de64:	f6 06 61 74 	ld  [ %i1 + 0x174 ], %i3	! 40017d74 <imfs_memfile_bytes_per_block>
4000de68:	90 10 00 10 	mov  %l0, %o0                                  
4000de6c:	b5 3e e0 1f 	sra  %i3, 0x1f, %i2                            
4000de70:	96 10 00 1b 	mov  %i3, %o3                                  
4000de74:	94 10 00 1a 	mov  %i2, %o2                                  
4000de78:	40 00 17 e2 	call  40013e00 <__moddi3>                      
4000de7c:	92 10 00 11 	mov  %l1, %o1                                  
  block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;                       
4000de80:	90 10 00 10 	mov  %l0, %o0                                  
   */                                                                 
                                                                      
  /*                                                                  
   *  Phase 1: possibly the last part of one block                    
   */                                                                 
  start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;                
4000de84:	a6 10 00 09 	mov  %o1, %l3                                  
  block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;                       
4000de88:	94 10 00 1a 	mov  %i2, %o2                                  
4000de8c:	92 10 00 11 	mov  %l1, %o1                                  
4000de90:	40 00 16 ea 	call  40013a38 <__divdi3>                      
4000de94:	96 10 00 1b 	mov  %i3, %o3                                  
  if ( start_offset )  {                                              
4000de98:	80 a4 e0 00 	cmp  %l3, 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;                       
4000de9c:	b4 10 00 09 	mov  %o1, %i2                                  
  if ( start_offset )  {                                              
4000dea0:	02 80 00 17 	be  4000defc <IMFS_memfile_read+0x154>         
4000dea4:	a0 10 00 19 	mov  %i1, %l0                                  
    to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset;            
4000dea8:	b6 26 c0 13 	sub  %i3, %l3, %i3                             
4000deac:	80 a7 00 1b 	cmp  %i4, %i3                                  
4000deb0:	08 80 00 03 	bleu  4000debc <IMFS_memfile_read+0x114>       
4000deb4:	b2 10 00 1c 	mov  %i4, %i1                                  
4000deb8:	b2 10 00 1b 	mov  %i3, %i1                                  
    if ( to_copy > my_length )                                        
      to_copy = my_length;                                            
    block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
4000debc:	90 10 00 1d 	mov  %i5, %o0                                  
4000dec0:	92 10 00 1a 	mov  %i2, %o1                                  
4000dec4:	94 10 20 00 	clr  %o2                                       
4000dec8:	7f ff ff 22 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000decc:	b0 10 20 00 	clr  %i0                                       
    if ( !block_ptr )                                                 
4000ded0:	80 a2 20 00 	cmp  %o0, 0                                    
4000ded4:	02 80 00 33 	be  4000dfa0 <IMFS_memfile_read+0x1f8>         <== NEVER TAKEN
4000ded8:	94 10 00 19 	mov  %i1, %o2                                  
      return copied;                                                  
    memcpy( dest, &(*block_ptr)[ start_offset ], to_copy );           
4000dedc:	d2 02 00 00 	ld  [ %o0 ], %o1                               
4000dee0:	90 10 00 12 	mov  %l2, %o0                                  
4000dee4:	92 02 40 13 	add  %o1, %l3, %o1                             
4000dee8:	40 00 08 b4 	call  400101b8 <memcpy>                        
4000deec:	a4 04 80 19 	add  %l2, %i1, %l2                             
    dest += to_copy;                                                  
    block++;                                                          
4000def0:	b4 06 a0 01 	inc  %i2                                       
    my_length -= to_copy;                                             
4000def4:	10 80 00 03 	b  4000df00 <IMFS_memfile_read+0x158>          
4000def8:	b8 27 00 19 	sub  %i4, %i1, %i4                             
   */                                                                 
  last_byte = start + length;                                         
  if ( last_byte > the_jnode->info.file.size )                        
    my_length = the_jnode->info.file.size - start;                    
                                                                      
  copied = 0;                                                         
4000defc:	b2 10 20 00 	clr  %i1                                       
  }                                                                   
                                                                      
  /*                                                                  
   *  Phase 2: all of zero of more blocks                             
   */                                                                 
  to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;                             
4000df00:	f6 04 21 74 	ld  [ %l0 + 0x174 ], %i3                       
  while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {               
4000df04:	b0 10 00 19 	mov  %i1, %i0                                  
4000df08:	a4 24 80 19 	sub  %l2, %i1, %l2                             
4000df0c:	c2 04 21 74 	ld  [ %l0 + 0x174 ], %g1                       
4000df10:	80 a7 00 01 	cmp  %i4, %g1                                  
4000df14:	0a 80 00 10 	bcs  4000df54 <IMFS_memfile_read+0x1ac>        
4000df18:	b2 04 80 18 	add  %l2, %i0, %i1                             
    block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
4000df1c:	90 10 00 1d 	mov  %i5, %o0                                  
4000df20:	92 10 00 1a 	mov  %i2, %o1                                  
4000df24:	7f ff ff 0b 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000df28:	94 10 20 00 	clr  %o2                                       
    if ( !block_ptr )                                                 
4000df2c:	82 92 20 00 	orcc  %o0, 0, %g1                              
4000df30:	02 80 00 1c 	be  4000dfa0 <IMFS_memfile_read+0x1f8>         <== NEVER TAKEN
4000df34:	90 10 00 19 	mov  %i1, %o0                                  
      return copied;                                                  
    memcpy( dest, &(*block_ptr)[ 0 ], to_copy );                      
4000df38:	d2 00 40 00 	ld  [ %g1 ], %o1                               
4000df3c:	94 10 00 1b 	mov  %i3, %o2                                  
4000df40:	40 00 08 9e 	call  400101b8 <memcpy>                        
4000df44:	b4 06 a0 01 	inc  %i2                                       
    dest += to_copy;                                                  
    block++;                                                          
    my_length -= to_copy;                                             
4000df48:	b8 27 00 1b 	sub  %i4, %i3, %i4                             
    copied += to_copy;                                                
4000df4c:	10 bf ff f0 	b  4000df0c <IMFS_memfile_read+0x164>          
4000df50:	b0 06 00 1b 	add  %i0, %i3, %i0                             
  /*                                                                  
   *  Phase 3: possibly the first part of one block                   
   */                                                                 
  IMFS_assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK );            
                                                                      
  if ( my_length ) {                                                  
4000df54:	80 a7 20 00 	cmp  %i4, 0                                    
4000df58:	02 80 00 0e 	be  4000df90 <IMFS_memfile_read+0x1e8>         
4000df5c:	90 07 bf f8 	add  %fp, -8, %o0                              
    block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
4000df60:	90 10 00 1d 	mov  %i5, %o0                                  
4000df64:	92 10 00 1a 	mov  %i2, %o1                                  
4000df68:	7f ff fe fa 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000df6c:	94 10 20 00 	clr  %o2                                       
    if ( !block_ptr )                                                 
4000df70:	82 92 20 00 	orcc  %o0, 0, %g1                              
4000df74:	02 80 00 0b 	be  4000dfa0 <IMFS_memfile_read+0x1f8>         <== NEVER TAKEN
4000df78:	90 10 00 19 	mov  %i1, %o0                                  
      return copied;                                                  
    memcpy( dest, &(*block_ptr)[ 0 ], my_length );                    
4000df7c:	d2 00 40 00 	ld  [ %g1 ], %o1                               
4000df80:	94 10 00 1c 	mov  %i4, %o2                                  
4000df84:	40 00 08 8d 	call  400101b8 <memcpy>                        
4000df88:	b0 07 00 18 	add  %i4, %i0, %i0                             
                                                                      
static inline void IMFS_update_atime( IMFS_jnode_t *jnode )           
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
4000df8c:	90 07 bf f8 	add  %fp, -8, %o0                              
4000df90:	7f ff d6 49 	call  400038b4 <gettimeofday>                  
4000df94:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_atime = now.tv_sec;                                     
4000df98:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000df9c:	c2 27 60 40 	st  %g1, [ %i5 + 0x40 ]                        
  }                                                                   
                                                                      
  IMFS_update_atime( the_jnode );                                     
                                                                      
  return copied;                                                      
}                                                                     
4000dfa0:	81 c7 e0 08 	ret                                            
4000dfa4:	81 e8 00 00 	restore                                        
                                                                      

4000e590 <IMFS_memfile_remove>: * is better to stick to simple, easy to understand algorithms. */ IMFS_jnode_t *IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) {
4000e590:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
                                                                      
  /*                                                                  
   *  Eventually this could be set smarter at each call to            
   *  memfile_free_blocks_in_table to greatly speed this up.          
   */                                                                 
  to_free = IMFS_MEMFILE_BLOCK_SLOTS;                                 
4000e594:	37 10 00 5f 	sethi  %hi(0x40017c00), %i3                    <== NOT EXECUTED
   *    + doubly indirect                                             
   *    + triply indirect                                             
   */                                                                 
  info = &the_jnode->info.file;                                       
                                                                      
  if ( info->indirect ) {                                             
4000e598:	c2 06 20 58 	ld  [ %i0 + 0x58 ], %g1                        <== NOT EXECUTED
                                                                      
  /*                                                                  
   *  Eventually this could be set smarter at each call to            
   *  memfile_free_blocks_in_table to greatly speed this up.          
   */                                                                 
  to_free = IMFS_MEMFILE_BLOCK_SLOTS;                                 
4000e59c:	fa 06 e1 74 	ld  [ %i3 + 0x174 ], %i5                       <== NOT EXECUTED
   *    + doubly indirect                                             
   *    + triply indirect                                             
   */                                                                 
  info = &the_jnode->info.file;                                       
                                                                      
  if ( info->indirect ) {                                             
4000e5a0:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e5a4:	02 80 00 05 	be  4000e5b8 <IMFS_memfile_remove+0x28>        <== NOT EXECUTED
4000e5a8:	bb 37 60 02 	srl  %i5, 2, %i5                               <== NOT EXECUTED
    memfile_free_blocks_in_table( &info->indirect, to_free );         
4000e5ac:	90 06 20 58 	add  %i0, 0x58, %o0                            <== NOT EXECUTED
4000e5b0:	7f ff ff e5 	call  4000e544 <memfile_free_blocks_in_table>  <== NOT EXECUTED
4000e5b4:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  if ( info->doubly_indirect ) {                                      
4000e5b8:	c2 06 20 5c 	ld  [ %i0 + 0x5c ], %g1                        <== NOT EXECUTED
4000e5bc:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e5c0:	02 80 00 14 	be  4000e610 <IMFS_memfile_remove+0x80>        <== NOT EXECUTED
4000e5c4:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
    for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {                  
4000e5c8:	c2 06 e1 74 	ld  [ %i3 + 0x174 ], %g1                       <== NOT EXECUTED
4000e5cc:	83 30 60 02 	srl  %g1, 2, %g1                               <== NOT EXECUTED
4000e5d0:	80 a7 00 01 	cmp  %i4, %g1                                  <== NOT EXECUTED
4000e5d4:	1a 80 00 0c 	bcc  4000e604 <IMFS_memfile_remove+0x74>       <== NOT EXECUTED
4000e5d8:	83 2f 20 02 	sll  %i4, 2, %g1                               <== NOT EXECUTED
      if ( info->doubly_indirect[i] ) {                               
4000e5dc:	c4 06 20 5c 	ld  [ %i0 + 0x5c ], %g2                        <== NOT EXECUTED
4000e5e0:	90 00 80 01 	add  %g2, %g1, %o0                             <== NOT EXECUTED
4000e5e4:	c2 00 80 01 	ld  [ %g2 + %g1 ], %g1                         <== NOT EXECUTED
4000e5e8:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e5ec:	22 bf ff f7 	be,a   4000e5c8 <IMFS_memfile_remove+0x38>     <== NOT EXECUTED
4000e5f0:	b8 07 20 01 	inc  %i4                                       <== NOT EXECUTED
        memfile_free_blocks_in_table(                                 
4000e5f4:	7f ff ff d4 	call  4000e544 <memfile_free_blocks_in_table>  <== NOT EXECUTED
4000e5f8:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
  if ( info->indirect ) {                                             
    memfile_free_blocks_in_table( &info->indirect, to_free );         
  }                                                                   
                                                                      
  if ( info->doubly_indirect ) {                                      
    for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {                  
4000e5fc:	10 bf ff f3 	b  4000e5c8 <IMFS_memfile_remove+0x38>         <== NOT EXECUTED
4000e600:	b8 07 20 01 	inc  %i4                                       <== 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 );  
4000e604:	90 06 20 5c 	add  %i0, 0x5c, %o0                            <== NOT EXECUTED
4000e608:	7f ff ff cf 	call  4000e544 <memfile_free_blocks_in_table>  <== NOT EXECUTED
4000e60c:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
                                                                      
  }                                                                   
                                                                      
  if ( info->triply_indirect ) {                                      
4000e610:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1                        <== NOT EXECUTED
4000e614:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e618:	02 80 00 25 	be  4000e6ac <IMFS_memfile_remove+0x11c>       <== NOT EXECUTED
4000e61c:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
    for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {                  
4000e620:	b2 16 e1 74 	or  %i3, 0x174, %i1                            <== NOT EXECUTED
4000e624:	c2 06 40 00 	ld  [ %i1 ], %g1                               <== NOT EXECUTED
4000e628:	83 30 60 02 	srl  %g1, 2, %g1                               <== NOT EXECUTED
4000e62c:	80 a7 00 01 	cmp  %i4, %g1                                  <== NOT EXECUTED
4000e630:	1a 80 00 1c 	bcc  4000e6a0 <IMFS_memfile_remove+0x110>      <== NOT EXECUTED
4000e634:	a2 10 00 19 	mov  %i1, %l1                                  <== NOT EXECUTED
      p = (block_p *) info->triply_indirect[i];                       
4000e638:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1                        <== NOT EXECUTED
4000e63c:	a1 2f 20 02 	sll  %i4, 2, %l0                               <== NOT EXECUTED
4000e640:	f6 00 40 10 	ld  [ %g1 + %l0 ], %i3                         <== NOT EXECUTED
      if ( !p )  /* ensure we have a valid pointer */                 
4000e644:	80 a6 e0 00 	cmp  %i3, 0                                    <== NOT EXECUTED
4000e648:	02 80 00 16 	be  4000e6a0 <IMFS_memfile_remove+0x110>       <== NOT EXECUTED
4000e64c:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
         break;                                                       
      for ( j=0 ; j<IMFS_MEMFILE_BLOCK_SLOTS ; j++ ) {                
4000e650:	c2 04 40 00 	ld  [ %l1 ], %g1                               <== NOT EXECUTED
4000e654:	83 30 60 02 	srl  %g1, 2, %g1                               <== NOT EXECUTED
4000e658:	80 a6 80 01 	cmp  %i2, %g1                                  <== NOT EXECUTED
4000e65c:	3a 80 00 0b 	bcc,a   4000e688 <IMFS_memfile_remove+0xf8>    <== NOT EXECUTED
4000e660:	d0 06 20 60 	ld  [ %i0 + 0x60 ], %o0                        <== NOT EXECUTED
        if ( p[j] ) {                                                 
4000e664:	c2 06 c0 00 	ld  [ %i3 ], %g1                               <== NOT EXECUTED
4000e668:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e66c:	02 80 00 04 	be  4000e67c <IMFS_memfile_remove+0xec>        <== NOT EXECUTED
4000e670:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
          memfile_free_blocks_in_table( (block_p **)&p[j], to_free);  
4000e674:	7f ff ff b4 	call  4000e544 <memfile_free_blocks_in_table>  <== NOT EXECUTED
4000e678:	92 10 00 1d 	mov  %i5, %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++ ) {                
4000e67c:	b4 06 a0 01 	inc  %i2                                       <== NOT EXECUTED
4000e680:	10 bf ff f4 	b  4000e650 <IMFS_memfile_remove+0xc0>         <== NOT EXECUTED
4000e684:	b6 06 e0 04 	add  %i3, 4, %i3                               <== NOT EXECUTED
        if ( p[j] ) {                                                 
          memfile_free_blocks_in_table( (block_p **)&p[j], to_free);  
        }                                                             
      }                                                               
      memfile_free_blocks_in_table(                                   
4000e688:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4000e68c:	90 02 00 10 	add  %o0, %l0, %o0                             <== NOT EXECUTED
4000e690:	7f ff ff ad 	call  4000e544 <memfile_free_blocks_in_table>  <== NOT EXECUTED
4000e694:	b8 07 20 01 	inc  %i4                                       <== 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++ ) {                  
4000e698:	10 bf ff e4 	b  4000e628 <IMFS_memfile_remove+0x98>         <== NOT EXECUTED
4000e69c:	c2 06 40 00 	ld  [ %i1 ], %g1                               <== NOT EXECUTED
        }                                                             
      }                                                               
      memfile_free_blocks_in_table(                                   
        (block_p **)&info->triply_indirect[i], to_free );             
    }                                                                 
    memfile_free_blocks_in_table(                                     
4000e6a0:	90 06 20 60 	add  %i0, 0x60, %o0                            <== NOT EXECUTED
4000e6a4:	7f ff ff a8 	call  4000e544 <memfile_free_blocks_in_table>  <== NOT EXECUTED
4000e6a8:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
        (block_p **)&info->triply_indirect, to_free );                
  }                                                                   
                                                                      
  return the_jnode;                                                   
}                                                                     
4000e6ac:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e6b0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e064 <IMFS_memfile_remove_block>: */ MEMFILE_STATIC void IMFS_memfile_remove_block( IMFS_jnode_t *the_jnode, unsigned int block ) {
4000e064:	9d e3 bf a0 	save  %sp, -96, %sp                            
  block_p *block_ptr;                                                 
  block_p  ptr;                                                       
                                                                      
  block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );  
4000e068:	94 10 20 00 	clr  %o2                                       
4000e06c:	90 10 00 18 	mov  %i0, %o0                                  
4000e070:	7f ff fe b8 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000e074:	92 10 00 19 	mov  %i1, %o1                                  
  if ( block_ptr ) {                                                  
4000e078:	80 a2 20 00 	cmp  %o0, 0                                    
4000e07c:	02 80 00 06 	be  4000e094 <IMFS_memfile_remove_block+0x30>  <== NEVER TAKEN
4000e080:	01 00 00 00 	nop                                            
    ptr = *block_ptr;                                                 
4000e084:	f0 02 00 00 	ld  [ %o0 ], %i0                               
    *block_ptr = 0;                                                   
4000e088:	c0 22 00 00 	clr  [ %o0 ]                                   
    memfile_free_block( ptr );                                        
4000e08c:	7f ff ff ed 	call  4000e040 <memfile_free_block>            
4000e090:	81 e8 00 00 	restore                                        
4000e094:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e098:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e2a4 <IMFS_memfile_write>: IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) {
4000e2a4:	9d e3 bf 98 	save  %sp, -104, %sp                           
   *  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 + my_length;                                      
  if ( last_byte > the_jnode->info.file.size ) {                      
4000e2a8:	c2 06 20 50 	ld  [ %i0 + 0x50 ], %g1                        
4000e2ac:	86 10 20 00 	clr  %g3                                       
  /*                                                                  
   *  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 + my_length;                                      
4000e2b0:	96 07 00 1a 	add  %i4, %i2, %o3                             
  if ( last_byte > the_jnode->info.file.size ) {                      
4000e2b4:	80 a0 c0 01 	cmp  %g3, %g1                                  
4000e2b8:	14 80 00 1b 	bg  4000e324 <IMFS_memfile_write+0x80>         <== NEVER TAKEN
4000e2bc:	c4 06 20 54 	ld  [ %i0 + 0x54 ], %g2                        
4000e2c0:	80 a0 c0 01 	cmp  %g3, %g1                                  
4000e2c4:	12 80 00 06 	bne  4000e2dc <IMFS_memfile_write+0x38>        <== NEVER TAKEN
4000e2c8:	23 10 00 5f 	sethi  %hi(0x40017c00), %l1                    
4000e2cc:	80 a2 c0 02 	cmp  %o3, %g2                                  
4000e2d0:	18 80 00 16 	bgu  4000e328 <IMFS_memfile_write+0x84>        
4000e2d4:	80 a6 40 01 	cmp  %i1, %g1                                  
   */                                                                 
                                                                      
  /*                                                                  
   *  Phase 1: possibly the last part of one block                    
   */                                                                 
  start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;                
4000e2d8:	23 10 00 5f 	sethi  %hi(0x40017c00), %l1                    
4000e2dc:	fa 04 61 74 	ld  [ %l1 + 0x174 ], %i5	! 40017d74 <imfs_memfile_bytes_per_block>
4000e2e0:	92 10 00 1a 	mov  %i2, %o1                                  
4000e2e4:	a5 3f 60 1f 	sra  %i5, 0x1f, %l2                            
4000e2e8:	96 10 00 1d 	mov  %i5, %o3                                  
4000e2ec:	94 10 00 12 	mov  %l2, %o2                                  
4000e2f0:	40 00 16 c4 	call  40013e00 <__moddi3>                      
4000e2f4:	90 10 00 19 	mov  %i1, %o0                                  
  block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;                       
4000e2f8:	90 10 00 19 	mov  %i1, %o0                                  
   */                                                                 
                                                                      
  /*                                                                  
   *  Phase 1: possibly the last part of one block                    
   */                                                                 
  start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;                
4000e2fc:	a0 10 00 09 	mov  %o1, %l0                                  
  block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;                       
4000e300:	94 10 00 12 	mov  %l2, %o2                                  
4000e304:	92 10 00 1a 	mov  %i2, %o1                                  
4000e308:	40 00 15 cc 	call  40013a38 <__divdi3>                      
4000e30c:	96 10 00 1d 	mov  %i5, %o3                                  
  if ( start_offset )  {                                              
4000e310:	80 a4 20 00 	cmp  %l0, 0                                    
4000e314:	12 80 00 17 	bne  4000e370 <IMFS_memfile_write+0xcc>        
4000e318:	b4 10 00 09 	mov  %o1, %i2                                  
    status = IMFS_memfile_extend( the_jnode, zero_fill, last_byte );  
    if ( status )                                                     
      return status;                                                  
  }                                                                   
                                                                      
  copied = 0;                                                         
4000e31c:	10 80 00 28 	b  4000e3bc <IMFS_memfile_write+0x118>         
4000e320:	ba 10 20 00 	clr  %i5                                       
   *  in memory file, then extend the length.                         
   */                                                                 
                                                                      
  last_byte = start + my_length;                                      
  if ( last_byte > the_jnode->info.file.size ) {                      
    bool zero_fill = start > the_jnode->info.file.size;               
4000e324:	80 a6 40 01 	cmp  %i1, %g1                                  <== NOT EXECUTED
4000e328:	14 80 00 09 	bg  4000e34c <IMFS_memfile_write+0xa8>         <== NEVER TAKEN
4000e32c:	92 10 20 01 	mov  1, %o1                                    
4000e330:	80 a6 40 01 	cmp  %i1, %g1                                  
4000e334:	32 80 00 06 	bne,a   4000e34c <IMFS_memfile_write+0xa8>     <== NEVER TAKEN
4000e338:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4000e33c:	80 a6 80 02 	cmp  %i2, %g2                                  
4000e340:	18 80 00 04 	bgu  4000e350 <IMFS_memfile_write+0xac>        
4000e344:	90 10 00 18 	mov  %i0, %o0                                  
4000e348:	92 10 20 00 	clr  %o1                                       
                                                                      
    status = IMFS_memfile_extend( the_jnode, zero_fill, last_byte );  
4000e34c:	90 10 00 18 	mov  %i0, %o0                                  
4000e350:	92 0a 60 01 	and  %o1, 1, %o1                               
4000e354:	7f ff ff 52 	call  4000e09c <IMFS_memfile_extend>           
4000e358:	94 10 20 00 	clr  %o2                                       
    if ( status )                                                     
4000e35c:	82 92 20 00 	orcc  %o0, 0, %g1                              
4000e360:	02 bf ff df 	be  4000e2dc <IMFS_memfile_write+0x38>         
4000e364:	23 10 00 5f 	sethi  %hi(0x40017c00), %l1                    
  }                                                                   
                                                                      
  IMFS_mtime_ctime_update( the_jnode );                               
                                                                      
  return copied;                                                      
}                                                                     
4000e368:	81 c7 e0 08 	ret                                            
4000e36c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
   *  Phase 1: possibly the last part of one block                    
   */                                                                 
  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;            
4000e370:	ba 27 40 10 	sub  %i5, %l0, %i5                             
4000e374:	80 a7 40 1c 	cmp  %i5, %i4                                  
4000e378:	38 80 00 02 	bgu,a   4000e380 <IMFS_memfile_write+0xdc>     
4000e37c:	ba 10 00 1c 	mov  %i4, %i5                                  
    if ( to_copy > my_length )                                        
      to_copy = my_length;                                            
    block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
4000e380:	90 10 00 18 	mov  %i0, %o0                                  
4000e384:	92 10 00 1a 	mov  %i2, %o1                                  
4000e388:	7f ff fd f2 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000e38c:	94 10 20 00 	clr  %o2                                       
    if ( !block_ptr )                                                 
4000e390:	80 a2 20 00 	cmp  %o0, 0                                    
4000e394:	02 80 00 34 	be  4000e464 <IMFS_memfile_write+0x1c0>        <== NEVER TAKEN
4000e398:	82 10 20 00 	clr  %g1                                       
        block,                                                        
        to_copy,                                                      
        src                                                           
      );                                                              
    #endif                                                            
    memcpy( &(*block_ptr)[ start_offset ], src, to_copy );            
4000e39c:	d0 02 00 00 	ld  [ %o0 ], %o0                               
4000e3a0:	92 10 00 1b 	mov  %i3, %o1                                  
4000e3a4:	90 02 00 10 	add  %o0, %l0, %o0                             
4000e3a8:	94 10 00 1d 	mov  %i5, %o2                                  
4000e3ac:	40 00 07 83 	call  400101b8 <memcpy>                        
4000e3b0:	b6 06 c0 1d 	add  %i3, %i5, %i3                             
    src += to_copy;                                                   
    block++;                                                          
4000e3b4:	b4 06 a0 01 	inc  %i2                                       
    my_length -= to_copy;                                             
4000e3b8:	b8 27 00 1d 	sub  %i4, %i5, %i4                             
                                                                      
  /*                                                                  
   *  Phase 2: all of zero of more blocks                             
   */                                                                 
                                                                      
  to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;                             
4000e3bc:	f2 04 61 74 	ld  [ %l1 + 0x174 ], %i1                       
4000e3c0:	b6 26 c0 1d 	sub  %i3, %i5, %i3                             
  while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {               
4000e3c4:	c2 04 61 74 	ld  [ %l1 + 0x174 ], %g1                       
4000e3c8:	80 a7 00 01 	cmp  %i4, %g1                                  
4000e3cc:	0a 80 00 10 	bcs  4000e40c <IMFS_memfile_write+0x168>       
4000e3d0:	a0 06 c0 1d 	add  %i3, %i5, %l0                             
    block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
4000e3d4:	90 10 00 18 	mov  %i0, %o0                                  
4000e3d8:	92 10 00 1a 	mov  %i2, %o1                                  
4000e3dc:	7f ff fd dd 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000e3e0:	94 10 20 00 	clr  %o2                                       
    if ( !block_ptr )                                                 
4000e3e4:	80 a2 20 00 	cmp  %o0, 0                                    
4000e3e8:	02 80 00 1e 	be  4000e460 <IMFS_memfile_write+0x1bc>        <== NEVER TAKEN
4000e3ec:	94 10 00 19 	mov  %i1, %o2                                  
      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 );                       
4000e3f0:	d0 02 00 00 	ld  [ %o0 ], %o0                               
4000e3f4:	92 10 00 10 	mov  %l0, %o1                                  
4000e3f8:	40 00 07 70 	call  400101b8 <memcpy>                        
4000e3fc:	b4 06 a0 01 	inc  %i2                                       
    src += to_copy;                                                   
    block++;                                                          
    my_length -= to_copy;                                             
4000e400:	b8 27 00 19 	sub  %i4, %i1, %i4                             
4000e404:	10 bf ff f0 	b  4000e3c4 <IMFS_memfile_write+0x120>         
4000e408:	ba 07 40 19 	add  %i5, %i1, %i5                             
   *  Phase 3: possibly the first part of one block                   
   */                                                                 
  IMFS_assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK );            
                                                                      
  to_copy = my_length;                                                
  if ( my_length ) {                                                  
4000e40c:	80 a7 20 00 	cmp  %i4, 0                                    
4000e410:	02 80 00 0f 	be  4000e44c <IMFS_memfile_write+0x1a8>        
4000e414:	90 07 bf f8 	add  %fp, -8, %o0                              
    block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
4000e418:	90 10 00 18 	mov  %i0, %o0                                  
4000e41c:	92 10 00 1a 	mov  %i2, %o1                                  
4000e420:	7f ff fd cc 	call  4000db50 <IMFS_memfile_get_block_pointer>
4000e424:	94 10 20 00 	clr  %o2                                       
    if ( !block_ptr )                                                 
4000e428:	80 a2 20 00 	cmp  %o0, 0                                    
4000e42c:	02 80 00 0e 	be  4000e464 <IMFS_memfile_write+0x1c0>        <== NEVER TAKEN
4000e430:	82 10 00 1d 	mov  %i5, %g1                                  
      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 );                     
4000e434:	d0 02 00 00 	ld  [ %o0 ], %o0                               
4000e438:	92 10 00 10 	mov  %l0, %o1                                  
4000e43c:	94 10 00 1c 	mov  %i4, %o2                                  
4000e440:	40 00 07 5e 	call  400101b8 <memcpy>                        
4000e444:	ba 07 40 1c 	add  %i5, %i4, %i5                             
                                                                      
static inline void IMFS_mtime_ctime_update( IMFS_jnode_t *jnode )     
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
4000e448:	90 07 bf f8 	add  %fp, -8, %o0                              
4000e44c:	7f ff d5 1a 	call  400038b4 <gettimeofday>                  
4000e450:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_mtime = now.tv_sec;                                     
4000e454:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000e458:	c2 26 20 44 	st  %g1, [ %i0 + 0x44 ]                        
  jnode->stat_ctime = now.tv_sec;                                     
4000e45c:	c2 26 20 48 	st  %g1, [ %i0 + 0x48 ]                        
4000e460:	82 10 00 1d 	mov  %i5, %g1                                  
  }                                                                   
                                                                      
  IMFS_mtime_ctime_update( the_jnode );                               
                                                                      
  return copied;                                                      
}                                                                     
4000e464:	b0 10 00 01 	mov  %g1, %i0                                  
4000e468:	81 c7 e0 08 	ret                                            
4000e46c:	81 e8 00 00 	restore                                        
                                                                      

400033dc <IMFS_mount>: #endif #include "imfs.h" int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
400033dc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
  IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; 
400033e0:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
400033e4:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
  return node->control->imfs_type;                                    
}                                                                     
                                                                      
static inline bool IMFS_is_directory( const IMFS_jnode_t *node )      
{                                                                     
  return node->control->imfs_type == IMFS_DIRECTORY;                  
400033e8:	c4 00 60 4c 	ld  [ %g1 + 0x4c ], %g2                        
                                                                      
  if ( IMFS_is_directory( node ) ) {                                  
400033ec:	c4 00 80 00 	ld  [ %g2 ], %g2                               
400033f0:	80 a0 a0 00 	cmp  %g2, 0                                    
400033f4:	12 80 00 0d 	bne  40003428 <IMFS_mount+0x4c>                
400033f8:	01 00 00 00 	nop                                            
    if ( node->info.directory.mt_fs == NULL ) {                       
400033fc:	c4 00 60 5c 	ld  [ %g1 + 0x5c ], %g2                        
40003400:	80 a0 a0 00 	cmp  %g2, 0                                    
40003404:	12 80 00 05 	bne  40003418 <IMFS_mount+0x3c>                <== NEVER TAKEN
40003408:	01 00 00 00 	nop                                            
      node->info.directory.mt_fs = mt_entry;                          
4000340c:	f0 20 60 5c 	st  %i0, [ %g1 + 0x5c ]                        
40003410:	81 c7 e0 08 	ret                                            
40003414:	91 e8 20 00 	restore  %g0, 0, %o0                           
    } else {                                                          
      errno = EBUSY;                                                  
40003418:	40 00 31 82 	call  4000fa20 <__errno>                       <== NOT EXECUTED
4000341c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40003420:	10 80 00 05 	b  40003434 <IMFS_mount+0x58>                  <== NOT EXECUTED
40003424:	82 10 20 10 	mov  0x10, %g1	! 10 <_TLS_Alignment+0xf>       <== NOT EXECUTED
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    errno = ENOTDIR;                                                  
40003428:	40 00 31 7e 	call  4000fa20 <__errno>                       
4000342c:	01 00 00 00 	nop                                            
40003430:	82 10 20 14 	mov  0x14, %g1	! 14 <_TLS_Alignment+0x13>      
40003434:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40003438:	81 c7 e0 08 	ret                                            
4000343c:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      

4000bd5c <IMFS_node_remove_directory>: } static IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node ) {
4000bd5c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ( !rtems_chain_is_empty( &node->info.directory.Entries ) ) {     
4000bd60:	c4 06 20 50 	ld  [ %i0 + 0x50 ], %g2                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000bd64:	82 06 20 54 	add  %i0, 0x54, %g1                            
4000bd68:	80 a0 80 01 	cmp  %g2, %g1                                  
4000bd6c:	22 80 00 06 	be,a   4000bd84 <IMFS_node_remove_directory+0x28>
4000bd70:	c2 06 20 5c 	ld  [ %i0 + 0x5c ], %g1                        
    errno = ENOTEMPTY;                                                
4000bd74:	40 00 0f 2b 	call  4000fa20 <__errno>                       
4000bd78:	01 00 00 00 	nop                                            
4000bd7c:	10 80 00 08 	b  4000bd9c <IMFS_node_remove_directory+0x40>  
4000bd80:	82 10 20 5a 	mov  0x5a, %g1	! 5a <_TLS_Alignment+0x59>      
    node = NULL;                                                      
  } else if ( IMFS_is_mount_point( node ) ) {                         
4000bd84:	80 a0 60 00 	cmp  %g1, 0                                    
4000bd88:	02 80 00 07 	be  4000bda4 <IMFS_node_remove_directory+0x48> <== ALWAYS TAKEN
4000bd8c:	01 00 00 00 	nop                                            
    errno = EBUSY;                                                    
4000bd90:	40 00 0f 24 	call  4000fa20 <__errno>                       <== NOT EXECUTED
4000bd94:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000bd98:	82 10 20 10 	mov  0x10, %g1	! 10 <_TLS_Alignment+0xf>       <== NOT EXECUTED
4000bd9c:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000bda0:	b0 10 20 00 	clr  %i0                                       
    node = NULL;                                                      
  }                                                                   
                                                                      
  return node;                                                        
}                                                                     
4000bda4:	81 c7 e0 08 	ret                                            
4000bda8:	81 e8 00 00 	restore                                        
                                                                      

40003440 <IMFS_node_type>: rtems_filesystem_node_types_t IMFS_node_type( const rtems_filesystem_location_info_t *loc ) { const IMFS_jnode_t *node = loc->node_access;
40003440:	c4 02 20 08 	ld  [ %o0 + 8 ], %g2                           
  rtems_chain_extract_unprotected( &node->Node );                     
}                                                                     
                                                                      
static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node )
{                                                                     
  return node->control->imfs_type;                                    
40003444:	c2 00 a0 4c 	ld  [ %g2 + 0x4c ], %g1                        
40003448:	c2 00 40 00 	ld  [ %g1 ], %g1                               
  IMFS_jnode_types_t imfs_type = IMFS_type( node );                   
  rtems_filesystem_node_types_t type;                                 
                                                                      
  switch ( imfs_type ) {                                              
4000344c:	80 a0 60 02 	cmp  %g1, 2                                    
40003450:	02 80 00 06 	be  40003468 <IMFS_node_type+0x28>             
40003454:	80 a0 60 05 	cmp  %g1, 5                                    
40003458:	02 80 00 07 	be  40003474 <IMFS_node_type+0x34>             <== NEVER TAKEN
4000345c:	90 10 20 04 	mov  4, %o0                                    
40003460:	81 c3 e0 08 	retl                                           
40003464:	90 10 00 01 	mov  %g1, %o0                                  
    case IMFS_HARD_LINK:                                              
      type = IMFS_type( node->info.hard_link.link_node );             
40003468:	c2 00 a0 50 	ld  [ %g2 + 0x50 ], %g1                        
4000346c:	c2 00 60 4c 	ld  [ %g1 + 0x4c ], %g1                        
40003470:	d0 00 40 00 	ld  [ %g1 ], %o0                               
      type = imfs_type;                                               
      break;                                                          
  }                                                                   
                                                                      
  return type;                                                        
}                                                                     
40003474:	81 c3 e0 08 	retl                                           
                                                                      

400034bc <IMFS_rename>: const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) {
400034bc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int rv = 0;                                                         
  IMFS_jnode_t *node = oldloc->node_access;                           
400034c0:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           
  /*                                                                  
   * FIXME: Due to insufficient checks we can create inaccessible nodes with
   * this operation.                                                  
   */                                                                 
                                                                      
  if ( node->Parent != NULL ) {                                       
400034c4:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
400034c8:	80 a0 60 00 	cmp  %g1, 0                                    
400034cc:	02 80 00 20 	be  4000354c <IMFS_rename+0x90>                <== NEVER TAKEN
400034d0:	f4 06 a0 08 	ld  [ %i2 + 8 ], %i2                           
    if ( namelen < IMFS_NAME_MAX ) {                                  
400034d4:	80 a7 20 1f 	cmp  %i4, 0x1f                                 
400034d8:	18 80 00 19 	bgu  4000353c <IMFS_rename+0x80>               
400034dc:	94 10 00 1c 	mov  %i4, %o2                                  
      memcpy( node->name, name, namelen );                            
400034e0:	92 10 00 1b 	mov  %i3, %o1                                  
400034e4:	40 00 33 35 	call  400101b8 <memcpy>                        
400034e8:	90 07 60 0c 	add  %i5, 0xc, %o0                             
      node->name [namelen] = '\0';                                    
400034ec:	b8 07 40 1c 	add  %i5, %i4, %i4                             
400034f0:	c0 2f 20 0c 	clrb  [ %i4 + 0xc ]                            
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
400034f4:	c4 07 40 00 	ld  [ %i5 ], %g2                               
  previous       = the_node->previous;                                
400034f8:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
                                                                      
static inline void IMFS_update_ctime( IMFS_jnode_t *jnode )           
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
400034fc:	90 07 bf f8 	add  %fp, -8, %o0                              
  next->previous = previous;                                          
40003500:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
40003504:	c4 20 40 00 	st  %g2, [ %g1 ]                               
static inline void IMFS_add_to_directory(                             
  IMFS_jnode_t *dir,                                                  
  IMFS_jnode_t *node                                                  
)                                                                     
{                                                                     
  node->Parent = dir;                                                 
40003508:	f4 27 60 08 	st  %i2, [ %i5 + 8 ]                           
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000350c:	c2 06 a0 58 	ld  [ %i2 + 0x58 ], %g1                        
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40003510:	84 06 a0 54 	add  %i2, 0x54, %g2                            
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
40003514:	c4 27 40 00 	st  %g2, [ %i5 ]                               
  tail->previous = the_node;                                          
40003518:	fa 26 a0 58 	st  %i5, [ %i2 + 0x58 ]                        
  old_last->next = the_node;                                          
4000351c:	fa 20 40 00 	st  %i5, [ %g1 ]                               
  the_node->previous = old_last;                                      
40003520:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
                                                                      
static inline void IMFS_update_ctime( IMFS_jnode_t *jnode )           
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
40003524:	40 00 00 e4 	call  400038b4 <gettimeofday>                  
40003528:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_ctime = now.tv_sec;                                     
4000352c:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
40003530:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
  const rtems_filesystem_location_info_t *newparentloc,               
  const char *name,                                                   
  size_t namelen                                                      
)                                                                     
{                                                                     
  int rv = 0;                                                         
40003534:	81 c7 e0 08 	ret                                            
40003538:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      
      IMFS_remove_from_directory( node );                             
      IMFS_add_to_directory( new_parent, node );                      
      IMFS_update_ctime( node );                                      
    } else {                                                          
      errno = ENAMETOOLONG;                                           
4000353c:	40 00 31 39 	call  4000fa20 <__errno>                       
40003540:	01 00 00 00 	nop                                            
40003544:	10 80 00 05 	b  40003558 <IMFS_rename+0x9c>                 
40003548:	82 10 20 5b 	mov  0x5b, %g1	! 5b <_TLS_Alignment+0x5a>      
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    errno = EINVAL;                                                   
4000354c:	40 00 31 35 	call  4000fa20 <__errno>                       <== NOT EXECUTED
40003550:	01 00 00 00 	nop                                            <== NOT EXECUTED
40003554:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
40003558:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
4000355c:	81 c7 e0 08 	ret                                            
40003560:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      

4000363c <IMFS_unmount>: #endif #include "imfs.h" int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
4000363c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
  IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; 
40003640:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
40003644:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
  return node->control->imfs_type;                                    
}                                                                     
                                                                      
static inline bool IMFS_is_directory( const IMFS_jnode_t *node )      
{                                                                     
  return node->control->imfs_type == IMFS_DIRECTORY;                  
40003648:	c4 00 60 4c 	ld  [ %g1 + 0x4c ], %g2                        
                                                                      
  if ( IMFS_is_directory( node ) ) {                                  
4000364c:	c4 00 80 00 	ld  [ %g2 ], %g2                               
40003650:	80 a0 a0 00 	cmp  %g2, 0                                    
40003654:	12 80 00 0d 	bne  40003688 <IMFS_unmount+0x4c>              <== NEVER TAKEN
40003658:	01 00 00 00 	nop                                            
    if ( node->info.directory.mt_fs == mt_entry ) {                   
4000365c:	c4 00 60 5c 	ld  [ %g1 + 0x5c ], %g2                        
40003660:	80 a0 80 18 	cmp  %g2, %i0                                  
40003664:	12 80 00 05 	bne  40003678 <IMFS_unmount+0x3c>              <== NEVER TAKEN
40003668:	01 00 00 00 	nop                                            
      node->info.directory.mt_fs = NULL;                              
4000366c:	c0 20 60 5c 	clr  [ %g1 + 0x5c ]                            
40003670:	81 c7 e0 08 	ret                                            
40003674:	91 e8 20 00 	restore  %g0, 0, %o0                           
    } else {                                                          
      errno = EINVAL;                                                 
40003678:	40 00 30 ea 	call  4000fa20 <__errno>                       <== NOT EXECUTED
4000367c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40003680:	10 80 00 05 	b  40003694 <IMFS_unmount+0x58>                <== NOT EXECUTED
40003684:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    errno = ENOTDIR;                                                  
40003688:	40 00 30 e6 	call  4000fa20 <__errno>                       <== NOT EXECUTED
4000368c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40003690:	82 10 20 14 	mov  0x14, %g1	! 14 <_TLS_Alignment+0x13>      <== NOT EXECUTED
40003694:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40003698:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000369c:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      

40003aa8 <RTEMS_Malloc_Initialize>: void RTEMS_Malloc_Initialize( const Heap_Area *areas, size_t area_count, Heap_Initialization_or_extend_handler extend ) {
40003aa8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Heap_Control *heap = RTEMS_Malloc_Heap;                             
40003aac:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
40003ab0:	f6 00 63 28 	ld  [ %g1 + 0x328 ], %i3	! 40016b28 <RTEMS_Malloc_Heap>
                                                                      
  if ( !rtems_configuration_get_unified_work_area() ) {               
40003ab4:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
40003ab8:	c2 08 61 c1 	ldub  [ %g1 + 0x1c1 ], %g1	! 400155c1 <Configuration+0x39>
40003abc:	80 a0 60 00 	cmp  %g1, 0                                    
40003ac0:	12 80 00 1a 	bne  40003b28 <RTEMS_Malloc_Initialize+0x80>   
40003ac4:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
40003ac8:	3b 10 00 21 	sethi  %hi(0x40008400), %i5                    
40003acc:	b8 10 20 00 	clr  %i4                                       
40003ad0:	ba 17 63 ac 	or  %i5, 0x3ac, %i5                            
40003ad4:	a0 10 00 1d 	mov  %i5, %l0                                  
    Heap_Initialization_or_extend_handler init_or_extend = _Heap_Initialize;
    uintptr_t page_size = CPU_HEAP_ALIGNMENT;                         
    size_t i;                                                         
                                                                      
    for (i = 0; i < area_count; ++i) {                                
40003ad8:	80 a7 00 19 	cmp  %i4, %i1                                  
40003adc:	02 80 00 0c 	be  40003b0c <RTEMS_Malloc_Initialize+0x64>    
40003ae0:	90 10 00 1b 	mov  %i3, %o0                                  
      const Heap_Area *area = &areas [i];                             
      uintptr_t space_available = (*init_or_extend)(                  
40003ae4:	d2 06 00 00 	ld  [ %i0 ], %o1                               
40003ae8:	d4 06 20 04 	ld  [ %i0 + 4 ], %o2                           
40003aec:	9f c7 40 00 	call  %i5                                      
40003af0:	96 10 20 08 	mov  8, %o3                                    
        area->begin,                                                  
        area->size,                                                   
        page_size                                                     
      );                                                              
                                                                      
      if ( space_available > 0 ) {                                    
40003af4:	80 a2 20 00 	cmp  %o0, 0                                    
40003af8:	32 80 00 02 	bne,a   40003b00 <RTEMS_Malloc_Initialize+0x58><== ALWAYS TAKEN
40003afc:	ba 10 00 1a 	mov  %i2, %i5                                  
  if ( !rtems_configuration_get_unified_work_area() ) {               
    Heap_Initialization_or_extend_handler init_or_extend = _Heap_Initialize;
    uintptr_t page_size = CPU_HEAP_ALIGNMENT;                         
    size_t i;                                                         
                                                                      
    for (i = 0; i < area_count; ++i) {                                
40003b00:	b8 07 20 01 	inc  %i4                                       
40003b04:	10 bf ff f5 	b  40003ad8 <RTEMS_Malloc_Initialize+0x30>     
40003b08:	b0 06 20 08 	add  %i0, 8, %i0                               
      if ( space_available > 0 ) {                                    
        init_or_extend = extend;                                      
      }                                                               
    }                                                                 
                                                                      
    if ( init_or_extend == _Heap_Initialize ) {                       
40003b0c:	80 a7 40 10 	cmp  %i5, %l0                                  
40003b10:	12 80 00 06 	bne  40003b28 <RTEMS_Malloc_Initialize+0x80>   
40003b14:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
      _Terminate(                                                     
40003b18:	90 10 20 00 	clr  %o0                                       
40003b1c:	92 10 20 01 	mov  1, %o1                                    
40003b20:	40 00 13 ba 	call  40008a08 <_Terminate>                    
40003b24:	94 10 20 17 	mov  0x17, %o2                                 
  }                                                                   
                                                                      
  /*                                                                  
   *  If configured, initialize the statistics support                
   */                                                                 
  if ( rtems_malloc_statistics_helpers != NULL ) {                    
40003b28:	c2 00 60 bc 	ld  [ %g1 + 0xbc ], %g1                        
40003b2c:	80 a0 60 00 	cmp  %g1, 0                                    
40003b30:	02 80 00 05 	be  40003b44 <RTEMS_Malloc_Initialize+0x9c>    
40003b34:	3b 10 00 60 	sethi  %hi(0x40018000), %i5                    
    (*rtems_malloc_statistics_helpers->initialize)();                 
40003b38:	c2 00 40 00 	ld  [ %g1 ], %g1                               
40003b3c:	9f c0 40 00 	call  %g1                                      
40003b40:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  MSBUMP( space_available, _Protected_heap_Get_size( heap ) );        
40003b44:	f8 07 63 40 	ld  [ %i5 + 0x340 ], %i4                       
40003b48:	40 00 16 0b 	call  40009374 <_Protected_heap_Get_size>      
40003b4c:	90 10 00 1b 	mov  %i3, %o0                                  
40003b50:	90 02 00 1c 	add  %o0, %i4, %o0                             
40003b54:	d0 27 63 40 	st  %o0, [ %i5 + 0x340 ]                       
40003b58:	81 c7 e0 08 	ret                                            
40003b5c:	81 e8 00 00 	restore                                        
                                                                      

400038ec <Stack_check_Dump_threads_usage>: static rtems_printk_plugin_t print_handler; static void Stack_check_Dump_threads_usage( Thread_Control *the_thread ) {
400038ec:	9d e3 bf 98 	save  %sp, -104, %sp                           <== NOT EXECUTED
                                                                      
  /*                                                                  
   *  Obtain interrupt stack information                              
   */                                                                 
  #if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)                          
    if (the_thread == (Thread_Control *) -1) {                        
400038f0:	80 a6 3f ff 	cmp  %i0, -1                                   <== NOT EXECUTED
400038f4:	32 80 00 0a 	bne,a   4000391c <Stack_check_Dump_threads_usage+0x30><== NOT EXECUTED
400038f8:	e0 06 21 18 	ld  [ %i0 + 0x118 ], %l0                       <== NOT EXECUTED
      if (!Stack_check_Interrupt_stack.area)                          
400038fc:	3b 10 00 66 	sethi  %hi(0x40019800), %i5                    <== NOT EXECUTED
40003900:	ba 17 63 4c 	or  %i5, 0x34c, %i5	! 40019b4c <Stack_check_Interrupt_stack><== NOT EXECUTED
40003904:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           <== NOT EXECUTED
40003908:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000390c:	02 80 00 4a 	be  40003a34 <Stack_check_Dump_threads_usage+0x148><== NOT EXECUTED
40003910:	a0 10 20 00 	clr  %l0                                       <== NOT EXECUTED
        return;                                                       
      stack = &Stack_check_Interrupt_stack;                           
      the_thread = 0;                                                 
40003914:	10 80 00 04 	b  40003924 <Stack_check_Dump_threads_usage+0x38><== NOT EXECUTED
40003918:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
      current = 0;                                                    
    } else                                                            
  #endif                                                              
    {                                                                 
      stack  = &the_thread->Start.Initial_stack;                      
4000391c:	ba 06 20 b4 	add  %i0, 0xb4, %i5                            <== NOT EXECUTED
      current = (void *)_CPU_Context_Get_SP( &the_thread->Registers );
    }                                                                 
                                                                      
  low  = Stack_check_usable_stack_start(stack);                       
40003920:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           <== NOT EXECUTED
  size = Stack_check_usable_stack_size(stack);                        
40003924:	f6 07 40 00 	ld  [ %i5 ], %i3                               <== NOT EXECUTED
    {                                                                 
      stack  = &the_thread->Start.Initial_stack;                      
      current = (void *)_CPU_Context_Get_SP( &the_thread->Registers );
    }                                                                 
                                                                      
  low  = Stack_check_usable_stack_start(stack);                       
40003928:	84 00 60 10 	add  %g1, 0x10, %g2                            <== NOT EXECUTED
  size = Stack_check_usable_stack_size(stack);                        
4000392c:	b6 06 ff f0 	add  %i3, -16, %i3                             <== NOT EXECUTED
    /*                                                                
     * start at lower memory and find first word that does not        
     * match pattern                                                  
     */                                                               
                                                                      
    base += PATTERN_SIZE_WORDS;                                       
40003930:	82 00 60 20 	add  %g1, 0x20, %g1                            <== NOT EXECUTED
    for (ebase = base + length; base < ebase; base++)                 
40003934:	86 0e ff fc 	and  %i3, -4, %g3                              <== NOT EXECUTED
      if (*base != U32_PATTERN)                                       
40003938:	09 29 69 69 	sethi  %hi(0xa5a5a400), %g4                    <== 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++)                 
4000393c:	86 00 40 03 	add  %g1, %g3, %g3                             <== NOT EXECUTED
      if (*base != U32_PATTERN)                                       
40003940:	88 11 21 a5 	or  %g4, 0x1a5, %g4                            <== 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++)                 
40003944:	80 a0 40 03 	cmp  %g1, %g3                                  <== NOT EXECUTED
40003948:	1a 80 00 0c 	bcc  40003978 <Stack_check_Dump_threads_usage+0x8c><== NOT EXECUTED
4000394c:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
      if (*base != U32_PATTERN)                                       
40003950:	f8 00 40 00 	ld  [ %g1 ], %i4                               <== NOT EXECUTED
40003954:	80 a7 00 04 	cmp  %i4, %g4                                  <== NOT EXECUTED
40003958:	12 80 00 04 	bne  40003968 <Stack_check_Dump_threads_usage+0x7c><== NOT EXECUTED
4000395c:	80 a0 60 00 	cmp  %g1, 0                                    <== 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++)                 
40003960:	10 bf ff f9 	b  40003944 <Stack_check_Dump_threads_usage+0x58><== NOT EXECUTED
40003964:	82 00 60 04 	add  %g1, 4, %g1                               <== 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 )                                              
40003968:	02 80 00 04 	be  40003978 <Stack_check_Dump_threads_usage+0x8c><== NOT EXECUTED
4000396c:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
    used = Stack_check_Calculate_used( low, size, high_water_mark );  
40003970:	b8 00 80 1b 	add  %g2, %i3, %i4                             <== NOT EXECUTED
40003974:	b8 27 00 01 	sub  %i4, %g1, %i4                             <== NOT EXECUTED
  else                                                                
    used = 0;                                                         
                                                                      
                                                                      
  #if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)                          
    if ( the_thread )                                                 
40003978:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
4000397c:	33 10 00 65 	sethi  %hi(0x40019400), %i1                    <== NOT EXECUTED
40003980:	02 80 00 11 	be  400039c4 <Stack_check_Dump_threads_usage+0xd8><== NOT EXECUTED
40003984:	35 10 00 65 	sethi  %hi(0x40019400), %i2                    <== NOT EXECUTED
  #endif                                                              
    {                                                                 
      (*print_handler)(                                               
40003988:	f0 06 20 08 	ld  [ %i0 + 8 ], %i0                           <== NOT EXECUTED
4000398c:	e4 06 a1 54 	ld  [ %i2 + 0x154 ], %l2                       <== NOT EXECUTED
40003990:	e2 06 61 50 	ld  [ %i1 + 0x150 ], %l1                       <== NOT EXECUTED
40003994:	94 07 bf f8 	add  %fp, -8, %o2                              <== NOT EXECUTED
40003998:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4000399c:	40 00 12 cf 	call  400084d8 <rtems_object_get_name>         <== NOT EXECUTED
400039a0:	92 10 20 05 	mov  5, %o1                                    <== NOT EXECUTED
400039a4:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    <== NOT EXECUTED
400039a8:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
400039ac:	92 12 62 f0 	or  %o1, 0x2f0, %o1                            <== NOT EXECUTED
400039b0:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
400039b4:	9f c4 40 00 	call  %l1                                      <== NOT EXECUTED
400039b8:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
400039bc:	10 80 00 09 	b  400039e0 <Stack_check_Dump_threads_usage+0xf4><== NOT EXECUTED
400039c0:	d4 07 60 04 	ld  [ %i5 + 4 ], %o2                           <== NOT EXECUTED
        rtems_object_get_name( the_thread->Object.id, sizeof(name), name )
      );                                                              
    }                                                                 
    #if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)                        
      else {                                                          
        (*print_handler)( print_context, "0x%08" PRIx32 "  INTR", ~0 );
400039c4:	c2 06 61 50 	ld  [ %i1 + 0x150 ], %g1                       <== NOT EXECUTED
400039c8:	d0 06 a1 54 	ld  [ %i2 + 0x154 ], %o0                       <== NOT EXECUTED
400039cc:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    <== NOT EXECUTED
400039d0:	94 10 3f ff 	mov  -1, %o2                                   <== NOT EXECUTED
400039d4:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
400039d8:	92 12 63 00 	or  %o1, 0x300, %o1                            <== NOT EXECUTED
                                                                      
  (*print_handler)(                                                   
    print_context,                                                    
    " %010p - %010p %010p  %8" PRId32 "   ",                          
    stack->area,                                                      
    stack->area + stack->size - 1,                                    
400039dc:	d4 07 60 04 	ld  [ %i5 + 4 ], %o2                           <== NOT EXECUTED
400039e0:	d6 07 40 00 	ld  [ %i5 ], %o3                               <== NOT EXECUTED
      else {                                                          
        (*print_handler)( print_context, "0x%08" PRIx32 "  INTR", ~0 );
      }                                                               
    #endif                                                            
                                                                      
  (*print_handler)(                                                   
400039e4:	c2 06 61 50 	ld  [ %i1 + 0x150 ], %g1                       <== NOT EXECUTED
400039e8:	d0 06 a1 54 	ld  [ %i2 + 0x154 ], %o0                       <== NOT EXECUTED
    print_context,                                                    
    " %010p - %010p %010p  %8" PRId32 "   ",                          
    stack->area,                                                      
    stack->area + stack->size - 1,                                    
400039ec:	96 02 ff ff 	add  %o3, -1, %o3                              <== NOT EXECUTED
      else {                                                          
        (*print_handler)( print_context, "0x%08" PRIx32 "  INTR", ~0 );
      }                                                               
    #endif                                                            
                                                                      
  (*print_handler)(                                                   
400039f0:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    <== NOT EXECUTED
400039f4:	96 02 80 0b 	add  %o2, %o3, %o3                             <== NOT EXECUTED
400039f8:	92 12 63 10 	or  %o1, 0x310, %o1                            <== NOT EXECUTED
400039fc:	98 10 00 10 	mov  %l0, %o4                                  <== NOT EXECUTED
40003a00:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40003a04:	9a 10 00 1b 	mov  %i3, %o5                                  <== NOT EXECUTED
    stack->area + stack->size - 1,                                    
    current,                                                          
    size                                                              
  );                                                                  
                                                                      
  if (Stack_check_Initialized == 0) {                                 
40003a08:	03 10 00 65 	sethi  %hi(0x40019400), %g1                    <== NOT EXECUTED
40003a0c:	c2 00 61 58 	ld  [ %g1 + 0x158 ], %g1	! 40019558 <Stack_check_Initialized><== NOT EXECUTED
      else {                                                          
        (*print_handler)( print_context, "0x%08" PRIx32 "  INTR", ~0 );
      }                                                               
    #endif                                                            
                                                                      
  (*print_handler)(                                                   
40003a10:	23 10 00 65 	sethi  %hi(0x40019400), %l1                    <== NOT EXECUTED
40003a14:	31 10 00 65 	sethi  %hi(0x40019400), %i0                    <== NOT EXECUTED
    stack->area + stack->size - 1,                                    
    current,                                                          
    size                                                              
  );                                                                  
                                                                      
  if (Stack_check_Initialized == 0) {                                 
40003a18:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
    (*print_handler)( print_context, "Unavailable\n" );               
40003a1c:	d0 06 21 54 	ld  [ %i0 + 0x154 ], %o0                       <== NOT EXECUTED
    stack->area + stack->size - 1,                                    
    current,                                                          
    size                                                              
  );                                                                  
                                                                      
  if (Stack_check_Initialized == 0) {                                 
40003a20:	12 80 00 07 	bne  40003a3c <Stack_check_Dump_threads_usage+0x150><== NOT EXECUTED
40003a24:	c2 04 61 50 	ld  [ %l1 + 0x150 ], %g1                       <== NOT EXECUTED
    (*print_handler)( print_context, "Unavailable\n" );               
40003a28:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    <== NOT EXECUTED
40003a2c:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40003a30:	92 12 63 30 	or  %o1, 0x330, %o1	! 40016f30 <__FUNCTION__.6501+0x168><== NOT EXECUTED
40003a34:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003a38:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  } else {                                                            
    (*print_handler)( print_context, "%8" PRId32 "\n", used );        
40003a3c:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    <== NOT EXECUTED
40003a40:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
40003a44:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40003a48:	92 12 63 40 	or  %o1, 0x340, %o1                            <== NOT EXECUTED
40003a4c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003a50:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40002d2c <Stack_check_report_blown_task>: Thread_Control *running, bool pattern_ok ) RTEMS_COMPILER_NO_RETURN_ATTRIBUTE; void Stack_check_report_blown_task(Thread_Control *running, bool pattern_ok) {
40002d2c:	9d e3 bf 80 	save  %sp, -128, %sp                           <== NOT EXECUTED
  Stack_Control *stack = &running->Start.Initial_stack;               
  void          *pattern_area = Stack_check_Get_pattern(stack);       
  char           name[32];                                            
                                                                      
  printk("BLOWN STACK!!!\n");                                         
40002d30:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
) RTEMS_COMPILER_NO_RETURN_ATTRIBUTE;                                 
                                                                      
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(stack);       
40002d34:	fa 06 20 b8 	ld  [ %i0 + 0xb8 ], %i5                        <== NOT EXECUTED
  char           name[32];                                            
                                                                      
  printk("BLOWN STACK!!!\n");                                         
40002d38:	40 00 05 28 	call  400041d8 <printk>                        <== NOT EXECUTED
40002d3c:	90 12 20 70 	or  %o0, 0x70, %o0                             <== NOT EXECUTED
  printk("task control block: 0x%08" PRIxPTR "\n", running);          
40002d40:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
40002d44:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
40002d48:	40 00 05 24 	call  400041d8 <printk>                        <== NOT EXECUTED
40002d4c:	90 12 20 80 	or  %o0, 0x80, %o0	! 40015480 <__FUNCTION__.6501+0x190><== NOT EXECUTED
  printk("task ID: 0x%08lx\n", (unsigned long) running->Object.id);   
40002d50:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           <== NOT EXECUTED
40002d54:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
40002d58:	40 00 05 20 	call  400041d8 <printk>                        <== NOT EXECUTED
40002d5c:	90 12 20 a0 	or  %o0, 0xa0, %o0	! 400154a0 <__FUNCTION__.6501+0x1b0><== NOT EXECUTED
  printk(                                                             
40002d60:	d2 06 20 0c 	ld  [ %i0 + 0xc ], %o1                         <== NOT EXECUTED
40002d64:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
40002d68:	40 00 05 1c 	call  400041d8 <printk>                        <== NOT EXECUTED
40002d6c:	90 12 20 b8 	or  %o0, 0xb8, %o0	! 400154b8 <__FUNCTION__.6501+0x1c8><== NOT EXECUTED
    "task name: 0x%08" PRIx32 "\n",                                   
    running->Object.name.name_u32                                     
  );                                                                  
  printk(                                                             
40002d70:	d0 06 20 08 	ld  [ %i0 + 8 ], %o0                           <== NOT EXECUTED
40002d74:	94 07 bf e0 	add  %fp, -32, %o2                             <== NOT EXECUTED
40002d78:	40 00 10 e1 	call  400070fc <rtems_object_get_name>         <== NOT EXECUTED
40002d7c:	92 10 20 20 	mov  0x20, %o1                                 <== NOT EXECUTED
40002d80:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
40002d84:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
40002d88:	40 00 05 14 	call  400041d8 <printk>                        <== NOT EXECUTED
40002d8c:	90 12 20 d0 	or  %o0, 0xd0, %o0	! 400154d0 <__FUNCTION__.6501+0x1e0><== NOT EXECUTED
  );                                                                  
  printk(                                                             
    "task stack area (%lu Bytes): 0x%08" PRIxPTR " .. 0x%08" PRIxPTR "\n",
    (unsigned long) stack->size,                                      
    stack->area,                                                      
    ((char *) stack->area + stack->size)                              
40002d90:	d4 06 20 b8 	ld  [ %i0 + 0xb8 ], %o2                        <== NOT EXECUTED
40002d94:	d2 06 20 b4 	ld  [ %i0 + 0xb4 ], %o1                        <== NOT EXECUTED
  );                                                                  
  printk(                                                             
    "task name string: %s\n",                                         
    rtems_object_get_name(running->Object.id, sizeof(name), name)     
  );                                                                  
  printk(                                                             
40002d98:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
40002d9c:	96 02 80 09 	add  %o2, %o1, %o3                             <== NOT EXECUTED
40002da0:	40 00 05 0e 	call  400041d8 <printk>                        <== NOT EXECUTED
40002da4:	90 12 20 e8 	or  %o0, 0xe8, %o0                             <== NOT EXECUTED
    "task stack area (%lu Bytes): 0x%08" PRIxPTR " .. 0x%08" PRIxPTR "\n",
    (unsigned long) stack->size,                                      
    stack->area,                                                      
    ((char *) stack->area + stack->size)                              
  );                                                                  
  if (!pattern_ok) {                                                  
40002da8:	80 a6 60 00 	cmp  %i1, 0                                    <== NOT EXECUTED
40002dac:	32 80 00 09 	bne,a   40002dd0 <Stack_check_report_blown_task+0xa4><== NOT EXECUTED
40002db0:	d2 06 20 0c 	ld  [ %i0 + 0xc ], %o1                         <== NOT EXECUTED
    printk(                                                           
40002db4:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    <== NOT EXECUTED
40002db8:	92 10 20 10 	mov  0x10, %o1                                 <== NOT EXECUTED
40002dbc:	90 12 21 18 	or  %o0, 0x118, %o0                            <== NOT EXECUTED
40002dc0:	94 07 60 08 	add  %i5, 8, %o2                               <== NOT EXECUTED
40002dc4:	40 00 05 05 	call  400041d8 <printk>                        <== NOT EXECUTED
40002dc8:	96 07 60 18 	add  %i5, 0x18, %o3                            <== NOT EXECUTED
          rtems_configuration_get_user_multiprocessing_table()->node  
      );                                                              
    }                                                                 
  #endif                                                              
                                                                      
  rtems_fatal(                                                        
40002dcc:	d2 06 20 0c 	ld  [ %i0 + 0xc ], %o1                         <== NOT EXECUTED
40002dd0:	40 00 13 23 	call  40007a5c <rtems_fatal>                   <== NOT EXECUTED
40002dd4:	90 10 20 08 	mov  8, %o0                                    <== NOT EXECUTED
                                                                      

4000aa38 <_CORE_RWLock_Release>: CORE_RWLock_Status _CORE_RWLock_Release( CORE_RWLock_Control *the_rwlock, Thread_Control *executing ) {
4000aa38:	9d e3 bf a0 	save  %sp, -96, %sp                            
   *  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 );                                              
4000aa3c:	7f ff e4 ce 	call  40003d74 <sparc_disable_interrupts>      
4000aa40:	01 00 00 00 	nop                                            
    if ( the_rwlock->current_state == CORE_RWLOCK_UNLOCKED){          
4000aa44:	c2 06 20 44 	ld  [ %i0 + 0x44 ], %g1                        
4000aa48:	80 a0 60 00 	cmp  %g1, 0                                    
4000aa4c:	12 80 00 08 	bne  4000aa6c <_CORE_RWLock_Release+0x34>      
4000aa50:	80 a0 60 01 	cmp  %g1, 1                                    
      _ISR_Enable( level );                                           
4000aa54:	7f ff e4 cb 	call  40003d80 <sparc_enable_interrupts>       
4000aa58:	b0 10 20 00 	clr  %i0                                       
      executing->Wait.return_code = CORE_RWLOCK_UNAVAILABLE;          
4000aa5c:	82 10 20 02 	mov  2, %g1                                    
4000aa60:	c2 26 60 34 	st  %g1, [ %i1 + 0x34 ]                        
4000aa64:	81 c7 e0 08 	ret                                            
4000aa68:	81 e8 00 00 	restore                                        
      return CORE_RWLOCK_SUCCESSFUL;                                  
    }                                                                 
    if ( the_rwlock->current_state == CORE_RWLOCK_LOCKED_FOR_READING ) {
4000aa6c:	32 80 00 0b 	bne,a   4000aa98 <_CORE_RWLock_Release+0x60>   
4000aa70:	c0 26 60 34 	clr  [ %i1 + 0x34 ]                            
	the_rwlock->number_of_readers -= 1;                                  
4000aa74:	c2 06 20 48 	ld  [ %i0 + 0x48 ], %g1                        
4000aa78:	82 00 7f ff 	add  %g1, -1, %g1                              
	if ( the_rwlock->number_of_readers != 0 ) {                          
4000aa7c:	80 a0 60 00 	cmp  %g1, 0                                    
4000aa80:	02 80 00 05 	be  4000aa94 <_CORE_RWLock_Release+0x5c>       
4000aa84:	c2 26 20 48 	st  %g1, [ %i0 + 0x48 ]                        
          /* must be unlocked again */                                
	  _ISR_Enable( level );                                              
4000aa88:	7f ff e4 be 	call  40003d80 <sparc_enable_interrupts>       
4000aa8c:	b0 10 20 00 	clr  %i0                                       
          return CORE_RWLOCK_SUCCESSFUL;                              
4000aa90:	30 80 00 24 	b,a   4000ab20 <_CORE_RWLock_Release+0xe8>     
        }                                                             
    }                                                                 
                                                                      
    /* CORE_RWLOCK_LOCKED_FOR_WRITING or READING with readers */      
    executing->Wait.return_code = CORE_RWLOCK_SUCCESSFUL;             
4000aa94:	c0 26 60 34 	clr  [ %i1 + 0x34 ]                            
                                                                      
    /*                                                                
     * Implicitly transition to "unlocked" and find another thread interested
     * in obtaining this rwlock.                                      
     */                                                               
    the_rwlock->current_state = CORE_RWLOCK_UNLOCKED;                 
4000aa98:	c0 26 20 44 	clr  [ %i0 + 0x44 ]                            
  _ISR_Enable( level );                                               
4000aa9c:	7f ff e4 b9 	call  40003d80 <sparc_enable_interrupts>       
4000aaa0:	01 00 00 00 	nop                                            
                                                                      
  next = _Thread_queue_Dequeue( &the_rwlock->Wait_queue );            
4000aaa4:	40 00 07 7e 	call  4000c89c <_Thread_queue_Dequeue>         
4000aaa8:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  if ( next ) {                                                       
4000aaac:	80 a2 20 00 	cmp  %o0, 0                                    
4000aab0:	22 80 00 1c 	be,a   4000ab20 <_CORE_RWLock_Release+0xe8>    
4000aab4:	b0 10 20 00 	clr  %i0                                       
    if ( next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE ) {
4000aab8:	c2 02 20 30 	ld  [ %o0 + 0x30 ], %g1                        
4000aabc:	80 a0 60 01 	cmp  %g1, 1                                    
4000aac0:	32 80 00 05 	bne,a   4000aad4 <_CORE_RWLock_Release+0x9c>   
4000aac4:	c2 06 20 48 	ld  [ %i0 + 0x48 ], %g1                        
      the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_WRITING;     
4000aac8:	82 10 20 02 	mov  2, %g1                                    
      return CORE_RWLOCK_SUCCESSFUL;                                  
4000aacc:	10 80 00 14 	b  4000ab1c <_CORE_RWLock_Release+0xe4>        
4000aad0:	c2 26 20 44 	st  %g1, [ %i0 + 0x44 ]                        
    }                                                                 
                                                                      
    /*                                                                
     * Must be CORE_RWLOCK_THREAD_WAITING_FOR_READING                 
     */                                                               
    the_rwlock->number_of_readers += 1;                               
4000aad4:	82 00 60 01 	inc  %g1                                       
4000aad8:	c2 26 20 48 	st  %g1, [ %i0 + 0x48 ]                        
    the_rwlock->current_state = CORE_RWLOCK_LOCKED_FOR_READING;       
4000aadc:	82 10 20 01 	mov  1, %g1                                    
4000aae0:	c2 26 20 44 	st  %g1, [ %i0 + 0x44 ]                        
                                                                      
    /*                                                                
     * Now see if more readers can be let go.                         
     */                                                               
    while ( 1 ) {                                                     
      next = _Thread_queue_First( &the_rwlock->Wait_queue );          
4000aae4:	40 00 08 96 	call  4000cd3c <_Thread_queue_First>           
4000aae8:	90 10 00 18 	mov  %i0, %o0                                  
      if ( !next ||                                                   
4000aaec:	92 92 20 00 	orcc  %o0, 0, %o1                              
4000aaf0:	22 80 00 0c 	be,a   4000ab20 <_CORE_RWLock_Release+0xe8>    
4000aaf4:	b0 10 20 00 	clr  %i0                                       
4000aaf8:	c2 02 60 30 	ld  [ %o1 + 0x30 ], %g1                        
4000aafc:	80 a0 60 01 	cmp  %g1, 1                                    
4000ab00:	02 80 00 07 	be  4000ab1c <_CORE_RWLock_Release+0xe4>       <== NEVER TAKEN
4000ab04:	90 10 00 18 	mov  %i0, %o0                                  
           next->Wait.option == CORE_RWLOCK_THREAD_WAITING_FOR_WRITE )
        return CORE_RWLOCK_SUCCESSFUL;                                
      the_rwlock->number_of_readers += 1;                             
4000ab08:	c2 06 20 48 	ld  [ %i0 + 0x48 ], %g1                        
4000ab0c:	82 00 60 01 	inc  %g1                                       
      _Thread_queue_Extract( &the_rwlock->Wait_queue, next );         
4000ab10:	40 00 08 50 	call  4000cc50 <_Thread_queue_Extract>         
4000ab14:	c2 26 20 48 	st  %g1, [ %i0 + 0x48 ]                        
    }                                                                 
4000ab18:	30 bf ff f3 	b,a   4000aae4 <_CORE_RWLock_Release+0xac>     
  }                                                                   
                                                                      
  /* indentation is to match _ISR_Disable at top */                   
                                                                      
  return CORE_RWLOCK_SUCCESSFUL;                                      
}                                                                     
4000ab1c:	b0 10 20 00 	clr  %i0                                       
4000ab20:	81 c7 e0 08 	ret                                            
4000ab24:	81 e8 00 00 	restore                                        
                                                                      

4000ab28 <_CORE_RWLock_Timeout>: void _CORE_RWLock_Timeout( Objects_Id id, void *ignored ) {
4000ab28:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Thread_Control       *the_thread;                                   
  Objects_Locations     location;                                     
                                                                      
  the_thread = _Thread_Get( id, &location );                          
4000ab2c:	90 10 00 18 	mov  %i0, %o0                                  
4000ab30:	40 00 06 85 	call  4000c544 <_Thread_Get>                   
4000ab34:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
4000ab38:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000ab3c:	80 a0 60 00 	cmp  %g1, 0                                    
4000ab40:	12 80 00 07 	bne  4000ab5c <_CORE_RWLock_Timeout+0x34>      <== NEVER TAKEN
4000ab44:	01 00 00 00 	nop                                            
#if defined(RTEMS_MULTIPROCESSING)                                    
    case OBJECTS_REMOTE:  /* impossible */                            
#endif                                                                
      break;                                                          
    case OBJECTS_LOCAL:                                               
      _Thread_queue_Process_timeout( the_thread );                    
4000ab48:	40 00 08 be 	call  4000ce40 <_Thread_queue_Process_timeout> 
4000ab4c:	01 00 00 00 	nop                                            
   *                                                                  
   * This routine decrements the thread dispatch level.               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4000ab50:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable( level );                                            
#endif                                                                
                                                                      
    --disable_level;                                                  
4000ab54:	84 00 bf ff 	add  %g2, -1, %g2                              
    _Thread_Dispatch_disable_level = disable_level;                   
4000ab58:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
4000ab5c:	81 c7 e0 08 	ret                                            
4000ab60:	81 e8 00 00 	restore                                        
                                                                      

4000846c <_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 ) {
4000846c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level       level;                                              
  CORE_semaphore_Status status;                                       
                                                                      
  status = CORE_SEMAPHORE_STATUS_SUCCESSFUL;                          
                                                                      
  if ( (the_thread = _Thread_queue_Dequeue(&the_semaphore->Wait_queue)) ) {
40008470:	90 10 00 18 	mov  %i0, %o0                                  
40008474:	40 00 07 4a 	call  4000a19c <_Thread_queue_Dequeue>         
40008478:	ba 10 00 18 	mov  %i0, %i5                                  
4000847c:	80 a2 20 00 	cmp  %o0, 0                                    
40008480:	12 80 00 0e 	bne  400084b8 <_CORE_semaphore_Surrender+0x4c> 
40008484:	b0 10 20 00 	clr  %i0                                       
    if ( !_Objects_Is_local_id( the_thread->Object.id ) )             
      (*api_semaphore_mp_support) ( the_thread, id );                 
#endif                                                                
                                                                      
  } else {                                                            
    _ISR_Disable( level );                                            
40008488:	7f ff e7 eb 	call  40002434 <sparc_disable_interrupts>      
4000848c:	01 00 00 00 	nop                                            
      if ( the_semaphore->count < the_semaphore->Attributes.maximum_count )
40008490:	c2 07 60 48 	ld  [ %i5 + 0x48 ], %g1                        
40008494:	c4 07 60 40 	ld  [ %i5 + 0x40 ], %g2                        
40008498:	80 a0 40 02 	cmp  %g1, %g2                                  
4000849c:	1a 80 00 05 	bcc  400084b0 <_CORE_semaphore_Surrender+0x44> <== NEVER TAKEN
400084a0:	b0 10 20 04 	mov  4, %i0                                    
        the_semaphore->count += 1;                                    
400084a4:	82 00 60 01 	inc  %g1                                       
{                                                                     
  Thread_Control *the_thread;                                         
  ISR_Level       level;                                              
  CORE_semaphore_Status status;                                       
                                                                      
  status = CORE_SEMAPHORE_STATUS_SUCCESSFUL;                          
400084a8:	b0 10 20 00 	clr  %i0                                       
#endif                                                                
                                                                      
  } else {                                                            
    _ISR_Disable( level );                                            
      if ( the_semaphore->count < the_semaphore->Attributes.maximum_count )
        the_semaphore->count += 1;                                    
400084ac:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
      else                                                            
        status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED;               
    _ISR_Enable( level );                                             
400084b0:	7f ff e7 e4 	call  40002440 <sparc_enable_interrupts>       
400084b4:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  return status;                                                      
}                                                                     
400084b8:	81 c7 e0 08 	ret                                            
400084bc:	81 e8 00 00 	restore                                        
                                                                      

400071cc <_Event_Surrender>: rtems_event_set event_in, Event_Control *event, Thread_blocking_operation_States *sync_state, States_Control wait_state ) {
400071cc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_event_set seized_events;                                      
  rtems_option    option_set;                                         
                                                                      
  option_set = the_thread->Wait.option;                               
                                                                      
  _ISR_Disable( level );                                              
400071d0:	7f ff ec 99 	call  40002434 <sparc_disable_interrupts>      
400071d4:	fa 06 20 30 	ld  [ %i0 + 0x30 ], %i5                        
RTEMS_INLINE_ROUTINE void _Event_sets_Post(                           
  rtems_event_set  the_new_events,                                    
  rtems_event_set *the_event_set                                      
)                                                                     
{                                                                     
  *the_event_set |= the_new_events;                                   
400071d8:	c2 06 80 00 	ld  [ %i2 ], %g1                               
400071dc:	b2 16 40 01 	or  %i1, %g1, %i1                              
400071e0:	f2 26 80 00 	st  %i1, [ %i2 ]                               
                                                                      
  /*                                                                  
   * At this point the event condition is a speculative quantity.  Later state
   * checks will show if the thread actually waits for an event.      
   */                                                                 
  event_condition = the_thread->Wait.count;                           
400071e4:	c4 06 20 24 	ld  [ %i0 + 0x24 ], %g2                        
                                                                      
  seized_events = _Event_sets_Get( pending_events, event_condition ); 
                                                                      
  if (                                                                
400071e8:	82 8e 40 02 	andcc  %i1, %g2, %g1                           
400071ec:	02 80 00 31 	be  400072b0 <_Event_Surrender+0xe4>           
400071f0:	80 a0 40 02 	cmp  %g1, %g2                                  
    !_Event_sets_Is_empty( seized_events )                            
      && ( seized_events == event_condition || _Options_Is_any( option_set ) )
400071f4:	02 80 00 04 	be  40007204 <_Event_Surrender+0x38>           
400071f8:	80 8f 60 02 	btst  2, %i5                                   
400071fc:	02 80 00 2d 	be  400072b0 <_Event_Surrender+0xe4>           
40007200:	01 00 00 00 	nop                                            
     *  section issue to deal with.  The entity sending to the executing thread
     *  can be either the executing thread or an ISR.  In case it is the
     *  executing thread, then the blocking operation state is not equal to
     *  THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED.                   
     */                                                               
    if ( _Thread_Is_executing( the_thread ) &&                        
40007204:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
40007208:	80 a6 00 02 	cmp  %i0, %g2                                  
4000720c:	32 80 00 0e 	bne,a   40007244 <_Event_Surrender+0x78>       
40007210:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
40007214:	c4 06 c0 00 	ld  [ %i3 ], %g2                               
40007218:	80 a0 a0 01 	cmp  %g2, 1                                    
4000721c:	32 80 00 0a 	bne,a   40007244 <_Event_Surrender+0x78>       
40007220:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
RTEMS_INLINE_ROUTINE rtems_event_set _Event_sets_Clear(               
 rtems_event_set the_event_set,                                       
 rtems_event_set the_mask                                             
)                                                                     
{                                                                     
   return ( the_event_set & ~(the_mask) );                            
40007224:	b2 2e 40 01 	andn  %i1, %g1, %i1                            
      event->pending_events = _Event_sets_Clear(                      
        pending_events,                                               
        seized_events                                                 
      );                                                              
      the_thread->Wait.count = 0;                                     
      *(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
40007228:	c4 06 20 28 	ld  [ %i0 + 0x28 ], %g2                        
     *  executing thread, then the blocking operation state is not equal to
     *  THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED.                   
     */                                                               
    if ( _Thread_Is_executing( the_thread ) &&                        
         *sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
      event->pending_events = _Event_sets_Clear(                      
4000722c:	f2 26 80 00 	st  %i1, [ %i2 ]                               
        pending_events,                                               
        seized_events                                                 
      );                                                              
      the_thread->Wait.count = 0;                                     
40007230:	c0 26 20 24 	clr  [ %i0 + 0x24 ]                            
      *(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
40007234:	c2 20 80 00 	st  %g1, [ %g2 ]                               
      *sync_state = THREAD_BLOCKING_OPERATION_SATISFIED;              
40007238:	82 10 20 03 	mov  3, %g1                                    
4000723c:	10 80 00 1d 	b  400072b0 <_Event_Surrender+0xe4>            
40007240:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
    } else if ( _States_Are_set( the_thread->current_state, wait_state ) ) {
40007244:	80 8f 00 02 	btst  %i4, %g2                                 
40007248:	02 80 00 1a 	be  400072b0 <_Event_Surrender+0xe4>           <== NEVER TAKEN
4000724c:	b2 2e 40 01 	andn  %i1, %g1, %i1                            
      event->pending_events = _Event_sets_Clear(                      
        pending_events,                                               
        seized_events                                                 
      );                                                              
      the_thread->Wait.count = 0;                                     
      *(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
40007250:	c4 06 20 28 	ld  [ %i0 + 0x28 ], %g2                        
      );                                                              
      the_thread->Wait.count = 0;                                     
      *(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
      *sync_state = THREAD_BLOCKING_OPERATION_SATISFIED;              
    } else if ( _States_Are_set( the_thread->current_state, wait_state ) ) {
      event->pending_events = _Event_sets_Clear(                      
40007254:	f2 26 80 00 	st  %i1, [ %i2 ]                               
        pending_events,                                               
        seized_events                                                 
      );                                                              
      the_thread->Wait.count = 0;                                     
40007258:	c0 26 20 24 	clr  [ %i0 + 0x24 ]                            
      *(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
4000725c:	c2 20 80 00 	st  %g1, [ %g2 ]                               
                                                                      
      _ISR_Flash( level );                                            
40007260:	7f ff ec 78 	call  40002440 <sparc_enable_interrupts>       
40007264:	01 00 00 00 	nop                                            
40007268:	7f ff ec 73 	call  40002434 <sparc_disable_interrupts>      
4000726c:	01 00 00 00 	nop                                            
                                                                      
      if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {             
40007270:	c2 06 20 50 	ld  [ %i0 + 0x50 ], %g1                        
40007274:	80 a0 60 02 	cmp  %g1, 2                                    
40007278:	02 80 00 06 	be  40007290 <_Event_Surrender+0xc4>           
4000727c:	82 10 20 03 	mov  3, %g1                                    
        _ISR_Enable( level );                                         
40007280:	7f ff ec 70 	call  40002440 <sparc_enable_interrupts>       
40007284:	33 04 03 ff 	sethi  %hi(0x100ffc00), %i1                    
                                                                      
RTEMS_INLINE_ROUTINE void _Thread_Unblock (                           
  Thread_Control *the_thread                                          
)                                                                     
{                                                                     
  _Thread_Clear_state( the_thread, STATES_BLOCKED );                  
40007288:	10 80 00 08 	b  400072a8 <_Event_Surrender+0xdc>            
4000728c:	b2 16 63 f8 	or  %i1, 0x3f8, %i1	! 100ffff8 <RAM_SIZE+0xfcffff8>
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(                       
  Watchdog_Control *the_watchdog                                      
)                                                                     
{                                                                     
                                                                      
  the_watchdog->state = WATCHDOG_REMOVE_IT;                           
40007290:	c2 26 20 50 	st  %g1, [ %i0 + 0x50 ]                        
        _Thread_Unblock( the_thread );                                
      } else {                                                        
        _Watchdog_Deactivate( &the_thread->Timer );                   
        _ISR_Enable( level );                                         
40007294:	7f ff ec 6b 	call  40002440 <sparc_enable_interrupts>       
40007298:	33 04 03 ff 	sethi  %hi(0x100ffc00), %i1                    
        (void) _Watchdog_Remove( &the_thread->Timer );                
4000729c:	40 00 0f 7f 	call  4000b098 <_Watchdog_Remove>              
400072a0:	90 06 20 48 	add  %i0, 0x48, %o0                            
400072a4:	b2 16 63 f8 	or  %i1, 0x3f8, %i1                            
400072a8:	40 00 0a 31 	call  40009b6c <_Thread_Clear_state>           
400072ac:	81 e8 00 00 	restore                                        
        _Thread_Unblock( the_thread );                                
      }                                                               
      return;                                                         
    }                                                                 
  }                                                                   
  _ISR_Enable( level );                                               
400072b0:	7f ff ec 64 	call  40002440 <sparc_enable_interrupts>       
400072b4:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

400072b8 <_Event_Timeout>: void _Event_Timeout( Objects_Id id, void *arg ) {
400072b8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  ISR_Level                         level;                            
  Thread_blocking_operation_States *sync_state;                       
                                                                      
  sync_state = arg;                                                   
                                                                      
  the_thread = _Thread_Get( id, &location );                          
400072bc:	90 10 00 18 	mov  %i0, %o0                                  
400072c0:	40 00 0a e1 	call  40009e44 <_Thread_Get>                   
400072c4:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
400072c8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
400072cc:	80 a0 60 00 	cmp  %g1, 0                                    
400072d0:	12 80 00 1f 	bne  4000734c <_Event_Timeout+0x94>            <== NEVER TAKEN
400072d4:	ba 10 00 08 	mov  %o0, %i5                                  
       *                                                              
       *  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 );                                          
400072d8:	7f ff ec 57 	call  40002434 <sparc_disable_interrupts>      
400072dc:	01 00 00 00 	nop                                            
         * This test is necessary to avoid state corruption if the timeout
         * happens after the event condition is satisfied in          
         * _Event_Surrender().  A satisfied event condition is indicated with
         * count set to zero.                                         
         */                                                           
        if ( !the_thread->Wait.count ) {                              
400072e0:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
400072e4:	80 a0 60 00 	cmp  %g1, 0                                    
400072e8:	32 80 00 05 	bne,a   400072fc <_Event_Timeout+0x44>         
400072ec:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
          _ISR_Enable( level );                                       
400072f0:	7f ff ec 54 	call  40002440 <sparc_enable_interrupts>       
400072f4:	01 00 00 00 	nop                                            
400072f8:	30 80 00 12 	b,a   40007340 <_Event_Timeout+0x88>           
          _Objects_Put_without_thread_dispatch( &the_thread->Object );
          return;                                                     
        }                                                             
                                                                      
        the_thread->Wait.count = 0;                                   
        if ( _Thread_Is_executing( the_thread ) ) {                   
400072fc:	80 a7 40 01 	cmp  %i5, %g1                                  
40007300:	12 80 00 08 	bne  40007320 <_Event_Timeout+0x68>            
40007304:	c0 27 60 24 	clr  [ %i5 + 0x24 ]                            
          if ( *sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
40007308:	c2 06 40 00 	ld  [ %i1 ], %g1                               
4000730c:	80 a0 60 01 	cmp  %g1, 1                                    
40007310:	12 80 00 05 	bne  40007324 <_Event_Timeout+0x6c>            <== NEVER TAKEN
40007314:	82 10 20 06 	mov  6, %g1                                    
            *sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;          
40007318:	82 10 20 02 	mov  2, %g1                                    
4000731c:	c2 26 40 00 	st  %g1, [ %i1 ]                               
        }                                                             
                                                                      
        the_thread->Wait.return_code = RTEMS_TIMEOUT;                 
40007320:	82 10 20 06 	mov  6, %g1                                    
40007324:	c2 27 60 34 	st  %g1, [ %i5 + 0x34 ]                        
      _ISR_Enable( level );                                           
40007328:	7f ff ec 46 	call  40002440 <sparc_enable_interrupts>       
4000732c:	01 00 00 00 	nop                                            
40007330:	13 04 03 ff 	sethi  %hi(0x100ffc00), %o1                    
40007334:	90 10 00 1d 	mov  %i5, %o0                                  
40007338:	40 00 0a 0d 	call  40009b6c <_Thread_Clear_state>           
4000733c:	92 12 63 f8 	or  %o1, 0x3f8, %o1                            
   *                                                                  
   * This routine decrements the thread dispatch level.               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40007340:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable( level );                                            
#endif                                                                
                                                                      
    --disable_level;                                                  
40007344:	84 00 bf ff 	add  %g2, -1, %g2                              
    _Thread_Dispatch_disable_level = disable_level;                   
40007348:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
4000734c:	81 c7 e0 08 	ret                                            
40007350:	81 e8 00 00 	restore                                        
                                                                      

4000712c <_Freechain_Get>: } void *_Freechain_Get(Freechain_Control *freechain) {
4000712c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ( _Chain_Is_empty( &freechain->Freechain ) ) {                   
40007130:	c4 06 00 00 	ld  [ %i0 ], %g2                               
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40007134:	82 06 20 04 	add  %i0, 4, %g1                               
40007138:	80 a0 80 01 	cmp  %g2, %g1                                  
4000713c:	22 80 00 08 	be,a   4000715c <_Freechain_Get+0x30>          
40007140:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_first_unprotected(        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
40007144:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  Chain_Node *new_first = old_first->next;                            
40007148:	c4 00 40 00 	ld  [ %g1 ], %g2                               
                                                                      
  head->next = new_first;                                             
4000714c:	c4 26 00 00 	st  %g2, [ %i0 ]                               
  new_first->previous = head;                                         
40007150:	f0 20 a0 04 	st  %i0, [ %g2 + 4 ]                           
    if ( !( *freechain->extend )( freechain ) ) {                     
      return NULL;                                                    
    }                                                                 
  }                                                                   
                                                                      
  return _Chain_Get_first_unprotected( &freechain->Freechain );       
40007154:	81 c7 e0 08 	ret                                            
40007158:	91 e8 00 01 	restore  %g0, %g1, %o0                         
}                                                                     
                                                                      
void *_Freechain_Get(Freechain_Control *freechain)                    
{                                                                     
  if ( _Chain_Is_empty( &freechain->Freechain ) ) {                   
    if ( !( *freechain->extend )( freechain ) ) {                     
4000715c:	9f c0 40 00 	call  %g1                                      
40007160:	90 10 00 18 	mov  %i0, %o0                                  
40007164:	80 a2 20 00 	cmp  %o0, 0                                    
40007168:	32 bf ff f8 	bne,a   40007148 <_Freechain_Get+0x1c>         <== ALWAYS TAKEN
4000716c:	c2 06 00 00 	ld  [ %i0 ], %g1                               
      return NULL;                                                    
    }                                                                 
  }                                                                   
                                                                      
  return _Chain_Get_first_unprotected( &freechain->Freechain );       
}                                                                     
40007170:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40007174:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
                                                                      

4000d8c8 <_Heap_Extend>: Heap_Control *heap, void *extend_area_begin_ptr, uintptr_t extend_area_size, uintptr_t unused __attribute__((unused)) ) {
4000d8c8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Heap_Block *start_block = first_block;                              
  Heap_Block *merge_below_block = NULL;                               
  Heap_Block *merge_above_block = NULL;                               
  Heap_Block *link_below_block = NULL;                                
  Heap_Block *link_above_block = NULL;                                
  Heap_Block *extend_first_block = NULL;                              
4000d8cc:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
  Heap_Block *extend_last_block = NULL;                               
4000d8d0:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
  uintptr_t const page_size = heap->page_size;                        
  uintptr_t const min_block_size = heap->min_block_size;              
  uintptr_t const extend_area_begin = (uintptr_t) extend_area_begin_ptr;
  uintptr_t const extend_area_end = extend_area_begin + extend_area_size;
4000d8d4:	ba 06 40 1a 	add  %i1, %i2, %i5                             
  uintptr_t extend_area_size,                                         
  uintptr_t unused __attribute__((unused))                            
)                                                                     
{                                                                     
  Heap_Statistics *const stats = &heap->stats;                        
  Heap_Block *const first_block = heap->first_block;                  
4000d8d8:	e4 06 20 20 	ld  [ %i0 + 0x20 ], %l2                        
  Heap_Block *merge_above_block = NULL;                               
  Heap_Block *link_below_block = NULL;                                
  Heap_Block *link_above_block = NULL;                                
  Heap_Block *extend_first_block = NULL;                              
  Heap_Block *extend_last_block = NULL;                               
  uintptr_t const page_size = heap->page_size;                        
4000d8dc:	ec 06 20 10 	ld  [ %i0 + 0x10 ], %l6                        
  uintptr_t const min_block_size = heap->min_block_size;              
4000d8e0:	d6 06 20 14 	ld  [ %i0 + 0x14 ], %o3                        
  uintptr_t const free_size = stats->free_size;                       
  uintptr_t extend_first_block_size = 0;                              
  uintptr_t extended_size = 0;                                        
  bool extend_area_ok = false;                                        
                                                                      
  if ( extend_area_end < extend_area_begin ) {                        
4000d8e4:	80 a7 40 19 	cmp  %i5, %i1                                  
4000d8e8:	1a 80 00 04 	bcc  4000d8f8 <_Heap_Extend+0x30>              
4000d8ec:	e6 06 20 30 	ld  [ %i0 + 0x30 ], %l3                        
    return 0;                                                         
4000d8f0:	81 c7 e0 08 	ret                                            
4000d8f4:	91 e8 20 00 	restore  %g0, 0, %o0                           
  }                                                                   
                                                                      
  extend_area_ok = _Heap_Get_first_and_last_block(                    
4000d8f8:	90 10 00 19 	mov  %i1, %o0                                  
4000d8fc:	92 10 00 1a 	mov  %i2, %o1                                  
4000d900:	94 10 00 16 	mov  %l6, %o2                                  
4000d904:	98 07 bf f8 	add  %fp, -8, %o4                              
4000d908:	7f ff ec 3f 	call  40008a04 <_Heap_Get_first_and_last_block>
4000d90c:	9a 07 bf fc 	add  %fp, -4, %o5                              
    page_size,                                                        
    min_block_size,                                                   
    &extend_first_block,                                              
    &extend_last_block                                                
  );                                                                  
  if (!extend_area_ok ) {                                             
4000d910:	80 a2 20 00 	cmp  %o0, 0                                    
4000d914:	02 bf ff f7 	be  4000d8f0 <_Heap_Extend+0x28>               
4000d918:	b6 10 00 12 	mov  %l2, %i3                                  
4000d91c:	a2 10 20 00 	clr  %l1                                       
4000d920:	a8 10 20 00 	clr  %l4                                       
4000d924:	b8 10 20 00 	clr  %i4                                       
4000d928:	a0 10 20 00 	clr  %l0                                       
    return 0;                                                         
  }                                                                   
                                                                      
  do {                                                                
    uintptr_t const sub_area_begin = (start_block != first_block) ?   
      (uintptr_t) start_block : heap->area_begin;                     
4000d92c:	80 a6 c0 12 	cmp  %i3, %l2                                  
4000d930:	12 80 00 03 	bne  4000d93c <_Heap_Extend+0x74>              <== NEVER TAKEN
4000d934:	aa 10 00 1b 	mov  %i3, %l5                                  
4000d938:	ea 06 20 18 	ld  [ %i0 + 0x18 ], %l5                        
    uintptr_t const sub_area_end = start_block->prev_size;            
4000d93c:	f4 06 c0 00 	ld  [ %i3 ], %i2                               
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(                      
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return value - (value % alignment);                                 
4000d940:	92 10 00 16 	mov  %l6, %o1                                  
4000d944:	40 00 18 f8 	call  40013d24 <.urem>                         
4000d948:	90 10 00 1a 	mov  %i2, %o0                                  
4000d94c:	ae 06 bf f8 	add  %i2, -8, %l7                              
    Heap_Block *const end_block =                                     
      _Heap_Block_of_alloc_area( sub_area_end, page_size );           
                                                                      
    if (                                                              
4000d950:	80 a5 40 1d 	cmp  %l5, %i5                                  
4000d954:	1a 80 00 05 	bcc  4000d968 <_Heap_Extend+0xa0>              
4000d958:	90 25 c0 08 	sub  %l7, %o0, %o0                             
4000d95c:	80 a6 40 1a 	cmp  %i1, %i2                                  
4000d960:	0a bf ff e4 	bcs  4000d8f0 <_Heap_Extend+0x28>              
4000d964:	01 00 00 00 	nop                                            
      sub_area_end > extend_area_begin && extend_area_end > sub_area_begin
    ) {                                                               
      return 0;                                                       
    }                                                                 
                                                                      
    if ( extend_area_end == sub_area_begin ) {                        
4000d968:	80 a7 40 15 	cmp  %i5, %l5                                  
4000d96c:	02 80 00 06 	be  4000d984 <_Heap_Extend+0xbc>               
4000d970:	80 a7 40 1a 	cmp  %i5, %i2                                  
      merge_below_block = start_block;                                
    } else if ( extend_area_end < sub_area_end ) {                    
4000d974:	2a 80 00 05 	bcs,a   4000d988 <_Heap_Extend+0xc0>           
4000d978:	a8 10 00 1b 	mov  %i3, %l4                                  
      link_below_block = start_block;                                 
    }                                                                 
                                                                      
    if ( sub_area_end == extend_area_begin ) {                        
4000d97c:	10 80 00 04 	b  4000d98c <_Heap_Extend+0xc4>                
4000d980:	80 a6 80 19 	cmp  %i2, %i1                                  
4000d984:	a0 10 00 1b 	mov  %i3, %l0                                  
4000d988:	80 a6 80 19 	cmp  %i2, %i1                                  
4000d98c:	12 80 00 05 	bne  4000d9a0 <_Heap_Extend+0xd8>              
4000d990:	80 a6 80 19 	cmp  %i2, %i1                                  
      start_block->prev_size = extend_area_end;                       
4000d994:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
4000d998:	10 80 00 04 	b  4000d9a8 <_Heap_Extend+0xe0>                
4000d99c:	b8 10 00 08 	mov  %o0, %i4                                  
                                                                      
      merge_above_block = end_block;                                  
    } else if ( sub_area_end < extend_area_begin ) {                  
4000d9a0:	2a 80 00 02 	bcs,a   4000d9a8 <_Heap_Extend+0xe0>           
4000d9a4:	a2 10 00 08 	mov  %o0, %l1                                  
    - 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;                
4000d9a8:	f6 02 20 04 	ld  [ %o0 + 4 ], %i3                           
4000d9ac:	b6 0e ff fe 	and  %i3, -2, %i3                              
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
4000d9b0:	b6 06 c0 08 	add  %i3, %o0, %i3                             
      link_above_block = end_block;                                   
    }                                                                 
                                                                      
    start_block = _Heap_Block_at( end_block, _Heap_Block_size( end_block ) );
  } while ( start_block != first_block );                             
4000d9b4:	80 a6 c0 12 	cmp  %i3, %l2                                  
4000d9b8:	12 bf ff e1 	bne  4000d93c <_Heap_Extend+0x74>              
4000d9bc:	aa 10 00 1b 	mov  %i3, %l5                                  
                                                                      
  if ( extend_area_begin < heap->area_begin ) {                       
4000d9c0:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
4000d9c4:	80 a6 40 01 	cmp  %i1, %g1                                  
4000d9c8:	3a 80 00 04 	bcc,a   4000d9d8 <_Heap_Extend+0x110>          
4000d9cc:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        
4000d9d0:	10 80 00 05 	b  4000d9e4 <_Heap_Extend+0x11c>               
4000d9d4:	f2 26 20 18 	st  %i1, [ %i0 + 0x18 ]                        
    heap->area_begin = extend_area_begin;                             
  } else if ( heap->area_end < extend_area_end ) {                    
4000d9d8:	80 a0 40 1d 	cmp  %g1, %i5                                  
4000d9dc:	2a 80 00 02 	bcs,a   4000d9e4 <_Heap_Extend+0x11c>          
4000d9e0:	fa 26 20 1c 	st  %i5, [ %i0 + 0x1c ]                        
    heap->area_end = extend_area_end;                                 
  }                                                                   
                                                                      
  extend_first_block_size =                                           
    (uintptr_t) extend_last_block - (uintptr_t) extend_first_block;   
4000d9e4:	c4 07 bf f8 	ld  [ %fp + -8 ], %g2                          
4000d9e8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                                                                      
  extend_first_block->prev_size = extend_area_end;                    
4000d9ec:	fa 20 80 00 	st  %i5, [ %g2 ]                               
    heap->area_begin = extend_area_begin;                             
  } else if ( heap->area_end < extend_area_end ) {                    
    heap->area_end = extend_area_end;                                 
  }                                                                   
                                                                      
  extend_first_block_size =                                           
4000d9f0:	86 20 40 02 	sub  %g1, %g2, %g3                             
    (uintptr_t) extend_last_block - (uintptr_t) extend_first_block;   
                                                                      
  extend_first_block->prev_size = extend_area_end;                    
  extend_first_block->size_and_flag =                                 
    extend_first_block_size | HEAP_PREV_BLOCK_USED;                   
4000d9f4:	88 10 e0 01 	or  %g3, 1, %g4                                
                                                                      
  extend_first_block_size =                                           
    (uintptr_t) extend_last_block - (uintptr_t) extend_first_block;   
                                                                      
  extend_first_block->prev_size = extend_area_end;                    
  extend_first_block->size_and_flag =                                 
4000d9f8:	c8 20 a0 04 	st  %g4, [ %g2 + 4 ]                           
    extend_first_block_size | HEAP_PREV_BLOCK_USED;                   
  _Heap_Protection_block_initialize( heap, extend_first_block );      
                                                                      
  extend_last_block->prev_size = extend_first_block_size;             
4000d9fc:	c6 20 40 00 	st  %g3, [ %g1 ]                               
  extend_last_block->size_and_flag = 0;                               
  _Heap_Protection_block_initialize( heap, extend_last_block );       
                                                                      
  if ( (uintptr_t) extend_first_block < (uintptr_t) heap->first_block ) {
4000da00:	c6 06 20 20 	ld  [ %i0 + 0x20 ], %g3                        
4000da04:	80 a0 c0 02 	cmp  %g3, %g2                                  
4000da08:	08 80 00 04 	bleu  4000da18 <_Heap_Extend+0x150>            
4000da0c:	c0 20 60 04 	clr  [ %g1 + 4 ]                               
4000da10:	10 80 00 06 	b  4000da28 <_Heap_Extend+0x160>               
4000da14:	c4 26 20 20 	st  %g2, [ %i0 + 0x20 ]                        
    heap->first_block = extend_first_block;                           
  } else if ( (uintptr_t) extend_last_block > (uintptr_t) heap->last_block ) {
4000da18:	c4 06 20 24 	ld  [ %i0 + 0x24 ], %g2                        
4000da1c:	80 a0 80 01 	cmp  %g2, %g1                                  
4000da20:	2a 80 00 02 	bcs,a   4000da28 <_Heap_Extend+0x160>          
4000da24:	c2 26 20 24 	st  %g1, [ %i0 + 0x24 ]                        
    heap->last_block = extend_last_block;                             
  }                                                                   
                                                                      
  if ( merge_below_block != NULL ) {                                  
4000da28:	80 a4 20 00 	cmp  %l0, 0                                    
4000da2c:	02 80 00 14 	be  4000da7c <_Heap_Extend+0x1b4>              
4000da30:	b2 06 60 08 	add  %i1, 8, %i1                               
  Heap_Control *heap,                                                 
  uintptr_t extend_area_begin,                                        
  Heap_Block *first_block                                             
)                                                                     
{                                                                     
  uintptr_t const page_size = heap->page_size;                        
4000da34:	f6 06 20 10 	ld  [ %i0 + 0x10 ], %i3                        
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_up(                        
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  uintptr_t remainder = value % alignment;                            
4000da38:	92 10 00 1b 	mov  %i3, %o1                                  
4000da3c:	40 00 18 ba 	call  40013d24 <.urem>                         
4000da40:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
  if ( remainder != 0 ) {                                             
4000da44:	80 a2 20 00 	cmp  %o0, 0                                    
4000da48:	02 80 00 04 	be  4000da58 <_Heap_Extend+0x190>              
4000da4c:	c2 04 00 00 	ld  [ %l0 ], %g1                               
    return value - remainder + alignment;                             
4000da50:	b2 06 40 1b 	add  %i1, %i3, %i1                             
4000da54:	b2 26 40 08 	sub  %i1, %o0, %i1                             
  uintptr_t const new_first_block_alloc_begin =                       
    _Heap_Align_up( extend_area_begin + HEAP_BLOCK_HEADER_SIZE, page_size );
  uintptr_t const new_first_block_begin =                             
4000da58:	92 06 7f f8 	add  %i1, -8, %o1                              
  uintptr_t const first_block_begin = (uintptr_t) first_block;        
  uintptr_t const new_first_block_size =                              
    first_block_begin - new_first_block_begin;                        
  Heap_Block *const new_first_block = (Heap_Block *) new_first_block_begin;
                                                                      
  new_first_block->prev_size = first_block->prev_size;                
4000da5c:	c2 26 7f f8 	st  %g1, [ %i1 + -8 ]                          
  uintptr_t const new_first_block_alloc_begin =                       
    _Heap_Align_up( extend_area_begin + HEAP_BLOCK_HEADER_SIZE, page_size );
  uintptr_t const new_first_block_begin =                             
    new_first_block_alloc_begin - HEAP_BLOCK_HEADER_SIZE;             
  uintptr_t const first_block_begin = (uintptr_t) first_block;        
  uintptr_t const new_first_block_size =                              
4000da60:	82 24 00 09 	sub  %l0, %o1, %g1                             
    first_block_begin - new_first_block_begin;                        
  Heap_Block *const new_first_block = (Heap_Block *) new_first_block_begin;
                                                                      
  new_first_block->prev_size = first_block->prev_size;                
  new_first_block->size_and_flag = new_first_block_size | HEAP_PREV_BLOCK_USED;
4000da64:	82 10 60 01 	or  %g1, 1, %g1                                
                                                                      
  _Heap_Free_block( heap, new_first_block );                          
4000da68:	90 10 00 18 	mov  %i0, %o0                                  
4000da6c:	7f ff ff 81 	call  4000d870 <_Heap_Free_block>              
4000da70:	c2 22 60 04 	st  %g1, [ %o1 + 4 ]                           
      link_below_block,                                               
      extend_last_block                                               
    );                                                                
  }                                                                   
                                                                      
  if ( merge_above_block != NULL ) {                                  
4000da74:	10 80 00 08 	b  4000da94 <_Heap_Extend+0x1cc>               
4000da78:	80 a7 20 00 	cmp  %i4, 0                                    
    heap->last_block = extend_last_block;                             
  }                                                                   
                                                                      
  if ( merge_below_block != NULL ) {                                  
    _Heap_Merge_below( heap, extend_area_begin, merge_below_block );  
  } else if ( link_below_block != NULL ) {                            
4000da7c:	80 a5 20 00 	cmp  %l4, 0                                    
4000da80:	02 80 00 04 	be  4000da90 <_Heap_Extend+0x1c8>              
4000da84:	a8 25 00 01 	sub  %l4, %g1, %l4                             
{                                                                     
  uintptr_t const last_block_begin = (uintptr_t) last_block;          
  uintptr_t const link_begin = (uintptr_t) link;                      
                                                                      
  last_block->size_and_flag =                                         
    (link_begin - last_block_begin) | HEAP_PREV_BLOCK_USED;           
4000da88:	a8 15 20 01 	or  %l4, 1, %l4                                
)                                                                     
{                                                                     
  uintptr_t const last_block_begin = (uintptr_t) last_block;          
  uintptr_t const link_begin = (uintptr_t) link;                      
                                                                      
  last_block->size_and_flag =                                         
4000da8c:	e8 20 60 04 	st  %l4, [ %g1 + 4 ]                           
      link_below_block,                                               
      extend_last_block                                               
    );                                                                
  }                                                                   
                                                                      
  if ( merge_above_block != NULL ) {                                  
4000da90:	80 a7 20 00 	cmp  %i4, 0                                    
4000da94:	02 80 00 15 	be  4000dae8 <_Heap_Extend+0x220>              
4000da98:	ba 07 7f f8 	add  %i5, -8, %i5                              
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(                      
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return value - (value % alignment);                                 
4000da9c:	d2 06 20 10 	ld  [ %i0 + 0x10 ], %o1                        
  uintptr_t extend_area_end                                           
)                                                                     
{                                                                     
  uintptr_t const page_size = heap->page_size;                        
  uintptr_t const last_block_begin = (uintptr_t) last_block;          
  uintptr_t const last_block_new_size = _Heap_Align_down(             
4000daa0:	ba 27 40 1c 	sub  %i5, %i4, %i5                             
4000daa4:	40 00 18 a0 	call  40013d24 <.urem>                         
4000daa8:	90 10 00 1d 	mov  %i5, %o0                                  
  );                                                                  
  Heap_Block *const new_last_block =                                  
    _Heap_Block_at( last_block, last_block_new_size );                
                                                                      
  new_last_block->size_and_flag =                                     
    (last_block->size_and_flag - last_block_new_size)                 
4000daac:	c4 07 20 04 	ld  [ %i4 + 4 ], %g2                           
4000dab0:	90 27 40 08 	sub  %i5, %o0, %o0                             
    page_size                                                         
  );                                                                  
  Heap_Block *const new_last_block =                                  
    _Heap_Block_at( last_block, last_block_new_size );                
                                                                      
  new_last_block->size_and_flag =                                     
4000dab4:	82 02 00 1c 	add  %o0, %i4, %g1                             
    (last_block->size_and_flag - last_block_new_size)                 
4000dab8:	84 20 80 08 	sub  %g2, %o0, %g2                             
      | HEAP_PREV_BLOCK_USED;                                         
4000dabc:	84 10 a0 01 	or  %g2, 1, %g2                                
    page_size                                                         
  );                                                                  
  Heap_Block *const new_last_block =                                  
    _Heap_Block_at( last_block, last_block_new_size );                
                                                                      
  new_last_block->size_and_flag =                                     
4000dac0:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(                       
  Heap_Block *block,                                                  
  uintptr_t size                                                      
)                                                                     
{                                                                     
  uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;       
4000dac4:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
    (last_block->size_and_flag - last_block_new_size)                 
      | HEAP_PREV_BLOCK_USED;                                         
                                                                      
  _Heap_Block_set_size( last_block, last_block_new_size );            
                                                                      
  _Heap_Free_block( heap, last_block );                               
4000dac8:	92 10 00 1c 	mov  %i4, %o1                                  
4000dacc:	82 08 60 01 	and  %g1, 1, %g1                               
                                                                      
  block->size_and_flag = size | flag;                                 
4000dad0:	90 12 00 01 	or  %o0, %g1, %o0                              
4000dad4:	d0 27 20 04 	st  %o0, [ %i4 + 4 ]                           
4000dad8:	7f ff ff 66 	call  4000d870 <_Heap_Free_block>              
4000dadc:	90 10 00 18 	mov  %i0, %o0                                  
      extend_first_block,                                             
      extend_last_block                                               
    );                                                                
  }                                                                   
                                                                      
  if ( merge_below_block == NULL && merge_above_block == NULL ) {     
4000dae0:	10 80 00 0f 	b  4000db1c <_Heap_Extend+0x254>               
4000dae4:	80 a7 20 00 	cmp  %i4, 0                                    
    );                                                                
  }                                                                   
                                                                      
  if ( merge_above_block != NULL ) {                                  
    _Heap_Merge_above( heap, merge_above_block, extend_area_end );    
  } else if ( link_above_block != NULL ) {                            
4000dae8:	80 a4 60 00 	cmp  %l1, 0                                    
4000daec:	02 80 00 0b 	be  4000db18 <_Heap_Extend+0x250>              
4000daf0:	c4 07 bf f8 	ld  [ %fp + -8 ], %g2                          
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(                       
  Heap_Block *block,                                                  
  uintptr_t size                                                      
)                                                                     
{                                                                     
  uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;       
4000daf4:	c6 04 60 04 	ld  [ %l1 + 4 ], %g3                           
    _Heap_Link_above(                                                 
4000daf8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000dafc:	86 08 e0 01 	and  %g3, 1, %g3                               
)                                                                     
{                                                                     
  uintptr_t const link_begin = (uintptr_t) link;                      
  uintptr_t const first_block_begin = (uintptr_t) first_block;        
                                                                      
  _Heap_Block_set_size( link, first_block_begin - link_begin );       
4000db00:	84 20 80 11 	sub  %g2, %l1, %g2                             
                                                                      
  block->size_and_flag = size | flag;                                 
4000db04:	84 10 c0 02 	or  %g3, %g2, %g2                              
4000db08:	c4 24 60 04 	st  %g2, [ %l1 + 4 ]                           
                                                                      
  last_block->size_and_flag |= HEAP_PREV_BLOCK_USED;                  
4000db0c:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
4000db10:	84 10 a0 01 	or  %g2, 1, %g2                                
4000db14:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
      extend_first_block,                                             
      extend_last_block                                               
    );                                                                
  }                                                                   
                                                                      
  if ( merge_below_block == NULL && merge_above_block == NULL ) {     
4000db18:	80 a7 20 00 	cmp  %i4, 0                                    
4000db1c:	32 80 00 09 	bne,a   4000db40 <_Heap_Extend+0x278>          
4000db20:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
4000db24:	80 a4 20 00 	cmp  %l0, 0                                    
4000db28:	32 80 00 06 	bne,a   4000db40 <_Heap_Extend+0x278>          
4000db2c:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
    _Heap_Free_block( heap, extend_first_block );                     
4000db30:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
4000db34:	7f ff ff 4f 	call  4000d870 <_Heap_Free_block>              
4000db38:	90 10 00 18 	mov  %i0, %o0                                  
 */                                                                   
RTEMS_INLINE_ROUTINE void _Heap_Set_last_block_size( Heap_Control *heap )
{                                                                     
  _Heap_Block_set_size(                                               
    heap->last_block,                                                 
    (uintptr_t) heap->first_block - (uintptr_t) heap->last_block      
4000db3c:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
 * This feature will be used to terminate the scattered heap area list.  See
 * also _Heap_Extend().                                               
 */                                                                   
RTEMS_INLINE_ROUTINE void _Heap_Set_last_block_size( Heap_Control *heap )
{                                                                     
  _Heap_Block_set_size(                                               
4000db40:	c4 06 20 20 	ld  [ %i0 + 0x20 ], %g2                        
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(                       
  Heap_Block *block,                                                  
  uintptr_t size                                                      
)                                                                     
{                                                                     
  uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;       
4000db44:	c6 00 60 04 	ld  [ %g1 + 4 ], %g3                           
 * This feature will be used to terminate the scattered heap area list.  See
 * also _Heap_Extend().                                               
 */                                                                   
RTEMS_INLINE_ROUTINE void _Heap_Set_last_block_size( Heap_Control *heap )
{                                                                     
  _Heap_Block_set_size(                                               
4000db48:	84 20 80 01 	sub  %g2, %g1, %g2                             
RTEMS_INLINE_ROUTINE void _Heap_Block_set_size(                       
  Heap_Block *block,                                                  
  uintptr_t size                                                      
)                                                                     
{                                                                     
  uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;       
4000db4c:	86 08 e0 01 	and  %g3, 1, %g3                               
                                                                      
  block->size_and_flag = size | flag;                                 
4000db50:	84 10 c0 02 	or  %g3, %g2, %g2                              
4000db54:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
  }                                                                   
                                                                      
  _Heap_Set_last_block_size( heap );                                  
                                                                      
  extended_size = stats->free_size - free_size;                       
4000db58:	c2 06 20 30 	ld  [ %i0 + 0x30 ], %g1                        
4000db5c:	a6 20 40 13 	sub  %g1, %l3, %l3                             
                                                                      
  /* Statistics */                                                    
  stats->size += extended_size;                                       
4000db60:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
4000db64:	82 00 40 13 	add  %g1, %l3, %g1                             
4000db68:	c2 26 20 2c 	st  %g1, [ %i0 + 0x2c ]                        
                                                                      
  return extended_size;                                               
}                                                                     
4000db6c:	81 c7 e0 08 	ret                                            
4000db70:	91 e8 00 13 	restore  %g0, %l3, %o0                         
                                                                      

4000d61c <_Heap_Free>: return do_free; } #endif bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr ) {
4000d61c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  /*                                                                  
   * If NULL return true so a free on NULL is considered a valid release. This
   * is a special case that could be handled by the in heap check how-ever that
   * would result in false being returned which is wrong.             
   */                                                                 
  if ( alloc_begin_ptr == NULL ) {                                    
4000d620:	80 a6 60 00 	cmp  %i1, 0                                    
4000d624:	02 80 00 7d 	be  4000d818 <_Heap_Free+0x1fc>                
4000d628:	86 10 20 01 	mov  1, %g3                                    
4000d62c:	d2 06 20 10 	ld  [ %i0 + 0x10 ], %o1                        
4000d630:	40 00 18 56 	call  40013788 <.urem>                         
4000d634:	90 10 00 19 	mov  %i1, %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           
4000d638:	f4 06 20 20 	ld  [ %i0 + 0x20 ], %i2                        
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(                      
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return value - (value % alignment);                                 
4000d63c:	ba 06 7f f8 	add  %i1, -8, %i5                              
  uintptr_t alloc_begin,                                              
  uintptr_t page_size                                                 
)                                                                     
{                                                                     
  return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )   
    - HEAP_BLOCK_HEADER_SIZE);                                        
4000d640:	90 27 40 08 	sub  %i5, %o0, %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;             
4000d644:	80 a2 00 1a 	cmp  %o0, %i2                                  
4000d648:	0a 80 00 05 	bcs  4000d65c <_Heap_Free+0x40>                
4000d64c:	82 10 20 00 	clr  %g1                                       
4000d650:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
4000d654:	80 a0 40 08 	cmp  %g1, %o0                                  
4000d658:	82 60 3f ff 	subx  %g0, -1, %g1                             
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           
4000d65c:	82 08 60 01 	and  %g1, 1, %g1                               
  }                                                                   
                                                                      
  alloc_begin = (uintptr_t) alloc_begin_ptr;                          
  block = _Heap_Block_of_alloc_area( alloc_begin, heap->page_size );  
                                                                      
  if ( !_Heap_Is_block_in_heap( heap, block ) ) {                     
4000d660:	80 a0 60 00 	cmp  %g1, 0                                    
4000d664:	02 80 00 6d 	be  4000d818 <_Heap_Free+0x1fc>                
4000d668:	86 10 00 01 	mov  %g1, %g3                                  
                                                                      
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )          
{                                                                     
  Heap_Statistics *const stats = &heap->stats;                        
  uintptr_t alloc_begin;                                              
  Heap_Block *block;                                                  
4000d66c:	f8 02 20 04 	ld  [ %o0 + 4 ], %i4                           
    - 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;                
4000d670:	84 0f 3f fe 	and  %i4, -2, %g2                              
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
4000d674:	82 00 80 08 	add  %g2, %o0, %g1                             
  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;             
4000d678:	80 a0 40 1a 	cmp  %g1, %i2                                  
4000d67c:	0a 80 00 05 	bcs  4000d690 <_Heap_Free+0x74>                <== NEVER TAKEN
4000d680:	88 10 20 00 	clr  %g4                                       
4000d684:	c6 06 20 24 	ld  [ %i0 + 0x24 ], %g3                        
4000d688:	80 a0 c0 01 	cmp  %g3, %g1                                  
4000d68c:	88 60 3f ff 	subx  %g0, -1, %g4                             
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           
4000d690:	88 09 20 01 	and  %g4, 1, %g4                               
  _Heap_Protection_block_check( heap, block );                        
                                                                      
  block_size = _Heap_Block_size( block );                             
  next_block = _Heap_Block_at( block, block_size );                   
                                                                      
  if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {                
4000d694:	80 a1 20 00 	cmp  %g4, 0                                    
4000d698:	02 80 00 60 	be  4000d818 <_Heap_Free+0x1fc>                
4000d69c:	86 10 00 04 	mov  %g4, %g3                                  
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )          
{                                                                     
  Heap_Statistics *const stats = &heap->stats;                        
  uintptr_t alloc_begin;                                              
  Heap_Block *block;                                                  
  Heap_Block *next_block = NULL;                                      
4000d6a0:	fa 00 60 04 	ld  [ %g1 + 4 ], %i5                           
    return false;                                                     
  }                                                                   
                                                                      
  _Heap_Protection_block_check( heap, next_block );                   
                                                                      
  if ( !_Heap_Is_prev_used( next_block ) ) {                          
4000d6a4:	80 8f 60 01 	btst  1, %i5                                   
4000d6a8:	22 80 00 5c 	be,a   4000d818 <_Heap_Free+0x1fc>             <== NEVER TAKEN
4000d6ac:	86 10 20 00 	clr  %g3                                       <== NOT EXECUTED
  if ( !_Heap_Protection_determine_block_free( heap, block ) ) {      
    return true;                                                      
  }                                                                   
                                                                      
  next_block_size = _Heap_Block_size( next_block );                   
  next_is_free = next_block != heap->last_block                       
4000d6b0:	de 06 20 24 	ld  [ %i0 + 0x24 ], %o7                        
    && !_Heap_Is_prev_used( _Heap_Block_at( next_block, next_block_size ));
4000d6b4:	80 a0 40 0f 	cmp  %g1, %o7                                  
4000d6b8:	02 80 00 07 	be  4000d6d4 <_Heap_Free+0xb8>                 
4000d6bc:	ba 0f 7f fe 	and  %i5, -2, %i5                              
4000d6c0:	88 00 40 1d 	add  %g1, %i5, %g4                             
4000d6c4:	f2 01 20 04 	ld  [ %g4 + 4 ], %i1                           
4000d6c8:	b2 1e 60 01 	xor  %i1, 1, %i1                               
4000d6cc:	10 80 00 03 	b  4000d6d8 <_Heap_Free+0xbc>                  
4000d6d0:	b2 0e 60 01 	and  %i1, 1, %i1                               
4000d6d4:	b2 10 20 00 	clr  %i1                                       
                                                                      
  if ( !_Heap_Is_prev_used( block ) ) {                               
4000d6d8:	80 8f 20 01 	btst  1, %i4                                   
4000d6dc:	12 80 00 25 	bne  4000d770 <_Heap_Free+0x154>               
4000d6e0:	b2 0e 60 01 	and  %i1, 1, %i1                               
    uintptr_t const prev_size = block->prev_size;                     
4000d6e4:	f8 02 00 00 	ld  [ %o0 ], %i4                               
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
4000d6e8:	88 22 00 1c 	sub  %o0, %i4, %g4                             
  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;             
4000d6ec:	80 a1 00 1a 	cmp  %g4, %i2                                  
4000d6f0:	0a 80 00 04 	bcs  4000d700 <_Heap_Free+0xe4>                <== NEVER TAKEN
4000d6f4:	b6 10 20 00 	clr  %i3                                       
4000d6f8:	80 a3 c0 04 	cmp  %o7, %g4                                  
4000d6fc:	b6 60 3f ff 	subx  %g0, -1, %i3                             
    Heap_Block * const prev_block = _Heap_Block_at( block, -prev_size );
                                                                      
    if ( !_Heap_Is_block_in_heap( heap, prev_block ) ) {              
4000d700:	b6 8e e0 01 	andcc  %i3, 1, %i3                             
4000d704:	22 80 00 45 	be,a   4000d818 <_Heap_Free+0x1fc>             <== NEVER TAKEN
4000d708:	86 10 00 1b 	mov  %i3, %g3                                  <== NOT EXECUTED
  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;                 
4000d70c:	f6 01 20 04 	ld  [ %g4 + 4 ], %i3                           
      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) ) {                        
4000d710:	80 8e e0 01 	btst  1, %i3                                   
4000d714:	02 80 00 40 	be  4000d814 <_Heap_Free+0x1f8>                <== NEVER TAKEN
4000d718:	80 a6 60 00 	cmp  %i1, 0                                    
      _HAssert( false );                                              
      return( false );                                                
    }                                                                 
                                                                      
    if ( next_is_free ) {       /* coalesce both */                   
4000d71c:	02 80 00 0e 	be  4000d754 <_Heap_Free+0x138>                
4000d720:	b8 00 80 1c 	add  %g2, %i4, %i4                             
      uintptr_t const size = block_size + prev_size + next_block_size;
4000d724:	ba 07 00 1d 	add  %i4, %i5, %i5                             
  return _Heap_Free_list_tail(heap)->prev;                            
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block ) 
{                                                                     
  Heap_Block *next = block->next;                                     
4000d728:	f8 00 60 08 	ld  [ %g1 + 8 ], %i4                           
  Heap_Block *prev = block->prev;                                     
4000d72c:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
                                                                      
  prev->next = next;                                                  
4000d730:	f8 20 60 08 	st  %i4, [ %g1 + 8 ]                           
  next->prev = prev;                                                  
4000d734:	c2 27 20 0c 	st  %g1, [ %i4 + 0xc ]                         
      _Heap_Free_list_remove( next_block );                           
      stats->free_blocks -= 1;                                        
4000d738:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
4000d73c:	82 00 7f ff 	add  %g1, -1, %g1                              
4000d740:	c2 26 20 38 	st  %g1, [ %i0 + 0x38 ]                        
      prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;        
4000d744:	82 17 60 01 	or  %i5, 1, %g1                                
4000d748:	c2 21 20 04 	st  %g1, [ %g4 + 4 ]                           
4000d74c:	10 80 00 28 	b  4000d7ec <_Heap_Free+0x1d0>                 
4000d750:	fa 27 40 04 	st  %i5, [ %i5 + %g4 ]                         
      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;        
4000d754:	ba 17 20 01 	or  %i4, 1, %i5                                
4000d758:	fa 21 20 04 	st  %i5, [ %g4 + 4 ]                           
      next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;             
4000d75c:	c8 00 60 04 	ld  [ %g1 + 4 ], %g4                           
4000d760:	88 09 3f fe 	and  %g4, -2, %g4                              
4000d764:	c8 20 60 04 	st  %g4, [ %g1 + 4 ]                           
      next_block->prev_size = size;                                   
4000d768:	10 80 00 21 	b  4000d7ec <_Heap_Free+0x1d0>                 
4000d76c:	f8 20 80 08 	st  %i4, [ %g2 + %o0 ]                         
    }                                                                 
  } else if ( next_is_free ) {    /* coalesce next */                 
4000d770:	80 a6 60 00 	cmp  %i1, 0                                    
4000d774:	22 80 00 0d 	be,a   4000d7a8 <_Heap_Free+0x18c>             
4000d778:	c8 06 20 08 	ld  [ %i0 + 8 ], %g4                           
    uintptr_t const size = block_size + next_block_size;              
4000d77c:	88 07 40 02 	add  %i5, %g2, %g4                             
RTEMS_INLINE_ROUTINE void _Heap_Free_list_replace(                    
  Heap_Block *old_block,                                              
  Heap_Block *new_block                                               
)                                                                     
{                                                                     
  Heap_Block *next = old_block->next;                                 
4000d780:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
  Heap_Block *prev = old_block->prev;                                 
4000d784:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
                                                                      
  new_block->next = next;                                             
4000d788:	fa 22 20 08 	st  %i5, [ %o0 + 8 ]                           
  new_block->prev = prev;                                             
4000d78c:	c2 22 20 0c 	st  %g1, [ %o0 + 0xc ]                         
                                                                      
  next->prev = new_block;                                             
4000d790:	d0 27 60 0c 	st  %o0, [ %i5 + 0xc ]                         
  prev->next = new_block;                                             
4000d794:	d0 20 60 08 	st  %o0, [ %g1 + 8 ]                           
    _Heap_Free_list_replace( next_block, block );                     
    block->size_and_flag = size | HEAP_PREV_BLOCK_USED;               
4000d798:	82 11 20 01 	or  %g4, 1, %g1                                
4000d79c:	c2 22 20 04 	st  %g1, [ %o0 + 4 ]                           
4000d7a0:	10 80 00 13 	b  4000d7ec <_Heap_Free+0x1d0>                 
4000d7a4:	c8 21 00 08 	st  %g4, [ %g4 + %o0 ]                         
)                                                                     
{                                                                     
  Heap_Block *next = block_before->next;                              
                                                                      
  new_block->next = next;                                             
  new_block->prev = block_before;                                     
4000d7a8:	f0 22 20 0c 	st  %i0, [ %o0 + 0xc ]                         
  Heap_Block *new_block                                               
)                                                                     
{                                                                     
  Heap_Block *next = block_before->next;                              
                                                                      
  new_block->next = next;                                             
4000d7ac:	c8 22 20 08 	st  %g4, [ %o0 + 8 ]                           
  new_block->prev = block_before;                                     
  block_before->next = new_block;                                     
4000d7b0:	d0 26 20 08 	st  %o0, [ %i0 + 8 ]                           
  next->prev = new_block;                                             
4000d7b4:	d0 21 20 0c 	st  %o0, [ %g4 + 0xc ]                         
    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;         
4000d7b8:	88 10 a0 01 	or  %g2, 1, %g4                                
4000d7bc:	c8 22 20 04 	st  %g4, [ %o0 + 4 ]                           
    next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;               
4000d7c0:	c8 00 60 04 	ld  [ %g1 + 4 ], %g4                           
4000d7c4:	88 09 3f fe 	and  %g4, -2, %g4                              
4000d7c8:	c8 20 60 04 	st  %g4, [ %g1 + 4 ]                           
    next_block->prev_size = block_size;                               
                                                                      
    /* Statistics */                                                  
    ++stats->free_blocks;                                             
4000d7cc:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
    /* 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;               
    next_block->prev_size = block_size;                               
4000d7d0:	c4 20 80 08 	st  %g2, [ %g2 + %o0 ]                         
                                                                      
    /* Statistics */                                                  
    ++stats->free_blocks;                                             
    if ( stats->max_free_blocks < stats->free_blocks ) {              
4000d7d4:	c8 06 20 3c 	ld  [ %i0 + 0x3c ], %g4                        
    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;                                             
4000d7d8:	82 00 60 01 	inc  %g1                                       
    if ( stats->max_free_blocks < stats->free_blocks ) {              
4000d7dc:	80 a1 00 01 	cmp  %g4, %g1                                  
4000d7e0:	1a 80 00 03 	bcc  4000d7ec <_Heap_Free+0x1d0>               
4000d7e4:	c2 26 20 38 	st  %g1, [ %i0 + 0x38 ]                        
      stats->max_free_blocks = stats->free_blocks;                    
4000d7e8:	c2 26 20 3c 	st  %g1, [ %i0 + 0x3c ]                        
    }                                                                 
  }                                                                   
                                                                      
  /* Statistics */                                                    
  --stats->used_blocks;                                               
4000d7ec:	c2 06 20 40 	ld  [ %i0 + 0x40 ], %g1                        
4000d7f0:	82 00 7f ff 	add  %g1, -1, %g1                              
4000d7f4:	c2 26 20 40 	st  %g1, [ %i0 + 0x40 ]                        
  ++stats->frees;                                                     
4000d7f8:	c2 06 20 50 	ld  [ %i0 + 0x50 ], %g1                        
4000d7fc:	82 00 60 01 	inc  %g1                                       
4000d800:	c2 26 20 50 	st  %g1, [ %i0 + 0x50 ]                        
  stats->free_size += block_size;                                     
4000d804:	c2 06 20 30 	ld  [ %i0 + 0x30 ], %g1                        
4000d808:	84 00 40 02 	add  %g1, %g2, %g2                             
                                                                      
  return( true );                                                     
4000d80c:	10 80 00 03 	b  4000d818 <_Heap_Free+0x1fc>                 
4000d810:	c4 26 20 30 	st  %g2, [ %i0 + 0x30 ]                        
                                                                      
  alloc_begin = (uintptr_t) alloc_begin_ptr;                          
  block = _Heap_Block_of_alloc_area( alloc_begin, heap->page_size );  
                                                                      
  if ( !_Heap_Is_block_in_heap( heap, block ) ) {                     
    return false;                                                     
4000d814:	86 10 20 00 	clr  %g3                                       <== NOT EXECUTED
  --stats->used_blocks;                                               
  ++stats->frees;                                                     
  stats->free_size += block_size;                                     
                                                                      
  return( true );                                                     
}                                                                     
4000d818:	b0 08 e0 01 	and  %g3, 1, %i0                               
4000d81c:	81 c7 e0 08 	ret                                            
4000d820:	81 e8 00 00 	restore                                        
                                                                      

400084d4 <_Heap_Greedy_allocate_all_except_largest>: Heap_Block *_Heap_Greedy_allocate_all_except_largest( Heap_Control *heap, uintptr_t *allocatable_size ) {
400084d4:	9d e3 bf 90 	save  %sp, -112, %sp                           
  Heap_Information info;                                              
                                                                      
  _Heap_Get_free_information( heap, &info );                          
400084d8:	90 10 00 18 	mov  %i0, %o0                                  
400084dc:	40 00 14 6a 	call  4000d684 <_Heap_Get_free_information>    
400084e0:	92 07 bf f4 	add  %fp, -12, %o1                             
                                                                      
  if ( info.largest > 0 ) {                                           
400084e4:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
400084e8:	80 a0 60 00 	cmp  %g1, 0                                    
400084ec:	22 80 00 04 	be,a   400084fc <_Heap_Greedy_allocate_all_except_largest+0x28><== NEVER TAKEN
400084f0:	c0 26 40 00 	clr  [ %i1 ]                                   <== NOT EXECUTED
    *allocatable_size = info.largest - HEAP_BLOCK_HEADER_SIZE + HEAP_ALLOC_BONUS;
400084f4:	82 00 7f fc 	add  %g1, -4, %g1                              
400084f8:	c2 26 40 00 	st  %g1, [ %i1 ]                               
  } else {                                                            
    *allocatable_size = 0;                                            
  }                                                                   
                                                                      
  return _Heap_Greedy_allocate( heap, allocatable_size, 1 );          
400084fc:	90 10 00 18 	mov  %i0, %o0                                  
40008500:	92 10 00 19 	mov  %i1, %o1                                  
40008504:	7f ff ff c4 	call  40008414 <_Heap_Greedy_allocate>         
40008508:	94 10 20 01 	mov  1, %o2                                    
}                                                                     
4000850c:	81 c7 e0 08 	ret                                            
40008510:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000b840 <_Heap_Iterate>: void _Heap_Iterate( Heap_Control *heap, Heap_Block_visitor visitor, void *visitor_arg ) {
4000b840:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Heap_Block *current = heap->first_block;                            
4000b844:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
  Heap_Block *end = heap->last_block;                                 
4000b848:	f8 06 20 24 	ld  [ %i0 + 0x24 ], %i4                        
  bool stop = false;                                                  
4000b84c:	90 10 20 00 	clr  %o0                                       
                                                                      
  while ( !stop && current != end ) {                                 
4000b850:	80 a0 40 1c 	cmp  %g1, %i4                                  
4000b854:	02 80 00 0e 	be  4000b88c <_Heap_Iterate+0x4c>              
4000b858:	90 1a 20 01 	xor  %o0, 1, %o0                               
4000b85c:	80 8a 20 ff 	btst  0xff, %o0                                
4000b860:	02 80 00 0b 	be  4000b88c <_Heap_Iterate+0x4c>              <== NEVER TAKEN
4000b864:	90 10 00 01 	mov  %g1, %o0                                  
    - 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;                
4000b868:	d2 00 60 04 	ld  [ %g1 + 4 ], %o1                           
4000b86c:	92 0a 7f fe 	and  %o1, -2, %o1                              
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
4000b870:	ba 00 40 09 	add  %g1, %o1, %i5                             
  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;                 
4000b874:	d4 07 60 04 	ld  [ %i5 + 4 ], %o2                           
    uintptr_t size = _Heap_Block_size( current );                     
    Heap_Block *next = _Heap_Block_at( current, size );               
    bool used = _Heap_Is_prev_used( next );                           
                                                                      
    stop = (*visitor)( current, size, used, visitor_arg );            
4000b878:	96 10 00 1a 	mov  %i2, %o3                                  
4000b87c:	9f c6 40 00 	call  %i1                                      
4000b880:	94 0a a0 01 	and  %o2, 1, %o2                               
                                                                      
    current = next;                                                   
4000b884:	10 bf ff f3 	b  4000b850 <_Heap_Iterate+0x10>               
4000b888:	82 10 00 1d 	mov  %i5, %g1                                  
4000b88c:	81 c7 e0 08 	ret                                            
4000b890:	81 e8 00 00 	restore                                        
                                                                      

40015260 <_Heap_Size_of_alloc_area>: bool _Heap_Size_of_alloc_area( Heap_Control *heap, void *alloc_begin_ptr, uintptr_t *alloc_size ) {
40015260:	9d e3 bf a0 	save  %sp, -96, %sp                            
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(                      
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return value - (value % alignment);                                 
40015264:	d2 06 20 10 	ld  [ %i0 + 0x10 ], %o1                        
40015268:	7f ff f9 48 	call  40013788 <.urem>                         
4001526c:	90 10 00 19 	mov  %i1, %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           
40015270:	c8 06 20 20 	ld  [ %i0 + 0x20 ], %g4                        
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(                      
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return value - (value % alignment);                                 
40015274:	ba 06 7f f8 	add  %i1, -8, %i5                              
  uintptr_t alloc_begin,                                              
  uintptr_t page_size                                                 
)                                                                     
{                                                                     
  return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )   
    - HEAP_BLOCK_HEADER_SIZE);                                        
40015278:	90 27 40 08 	sub  %i5, %o0, %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;             
4001527c:	80 a2 00 04 	cmp  %o0, %g4                                  
40015280:	0a 80 00 05 	bcs  40015294 <_Heap_Size_of_alloc_area+0x34>  
40015284:	82 10 20 00 	clr  %g1                                       
40015288:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
4001528c:	80 a0 40 08 	cmp  %g1, %o0                                  
40015290:	82 60 3f ff 	subx  %g0, -1, %g1                             
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           
40015294:	82 08 60 01 	and  %g1, 1, %g1                               
  uintptr_t const alloc_begin = (uintptr_t) alloc_begin_ptr;          
  Heap_Block *block = _Heap_Block_of_alloc_area( alloc_begin, page_size );
  Heap_Block *next_block = NULL;                                      
  uintptr_t block_size = 0;                                           
                                                                      
  if ( !_Heap_Is_block_in_heap( heap, block ) ) {                     
40015298:	80 a0 60 00 	cmp  %g1, 0                                    
4001529c:	02 80 00 17 	be  400152f8 <_Heap_Size_of_alloc_area+0x98>   
400152a0:	86 10 00 01 	mov  %g1, %g3                                  
    - 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;                
400152a4:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           
400152a8:	82 08 7f fe 	and  %g1, -2, %g1                              
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
400152ac:	82 00 40 08 	add  %g1, %o0, %g1                             
  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;             
400152b0:	80 a0 40 04 	cmp  %g1, %g4                                  
400152b4:	0a 80 00 05 	bcs  400152c8 <_Heap_Size_of_alloc_area+0x68>  <== NEVER TAKEN
400152b8:	84 10 20 00 	clr  %g2                                       
400152bc:	c4 06 20 24 	ld  [ %i0 + 0x24 ], %g2                        
400152c0:	80 a0 80 01 	cmp  %g2, %g1                                  
400152c4:	84 60 3f ff 	subx  %g0, -1, %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           
400152c8:	84 08 a0 01 	and  %g2, 1, %g2                               
  }                                                                   
                                                                      
  block_size = _Heap_Block_size( block );                             
  next_block = _Heap_Block_at( block, block_size );                   
                                                                      
  if (                                                                
400152cc:	80 a0 a0 00 	cmp  %g2, 0                                    
400152d0:	02 80 00 0a 	be  400152f8 <_Heap_Size_of_alloc_area+0x98>   <== NEVER TAKEN
400152d4:	86 10 00 02 	mov  %g2, %g3                                  
  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;                 
400152d8:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
    !_Heap_Is_block_in_heap( heap, next_block )                       
      || !_Heap_Is_prev_used( next_block )                            
400152dc:	80 88 a0 01 	btst  1, %g2                                   
400152e0:	02 80 00 05 	be  400152f4 <_Heap_Size_of_alloc_area+0x94>   <== NEVER TAKEN
400152e4:	82 20 40 19 	sub  %g1, %i1, %g1                             
  ) {                                                                 
    return false;                                                     
  }                                                                   
                                                                      
  *alloc_size = (uintptr_t) next_block + HEAP_ALLOC_BONUS - alloc_begin;
400152e8:	82 00 60 04 	add  %g1, 4, %g1                               
                                                                      
  return true;                                                        
400152ec:	10 80 00 03 	b  400152f8 <_Heap_Size_of_alloc_area+0x98>    
400152f0:	c2 26 80 00 	st  %g1, [ %i2 ]                               
  Heap_Block *block = _Heap_Block_of_alloc_area( alloc_begin, page_size );
  Heap_Block *next_block = NULL;                                      
  uintptr_t block_size = 0;                                           
                                                                      
  if ( !_Heap_Is_block_in_heap( heap, block ) ) {                     
    return false;                                                     
400152f4:	86 10 20 00 	clr  %g3                                       <== NOT EXECUTED
  }                                                                   
                                                                      
  *alloc_size = (uintptr_t) next_block + HEAP_ALLOC_BONUS - alloc_begin;
                                                                      
  return true;                                                        
}                                                                     
400152f8:	b0 08 e0 01 	and  %g3, 1, %i0                               
400152fc:	81 c7 e0 08 	ret                                            
40015300:	81 e8 00 00 	restore                                        
                                                                      

4000962c <_Heap_Walk>: bool _Heap_Walk( Heap_Control *heap, int source, bool dump ) {
4000962c:	9d e3 bf 80 	save  %sp, -128, %sp                           
40009630:	ac 10 00 19 	mov  %i1, %l6                                  
  uintptr_t const page_size = heap->page_size;                        
40009634:	f8 06 20 10 	ld  [ %i0 + 0x10 ], %i4                        
  uintptr_t const min_block_size = heap->min_block_size;              
40009638:	f6 06 20 14 	ld  [ %i0 + 0x14 ], %i3                        
  Heap_Block *const first_block = heap->first_block;                  
4000963c:	f2 06 20 20 	ld  [ %i0 + 0x20 ], %i1                        
  Heap_Block *const last_block = heap->last_block;                    
  Heap_Block *block = first_block;                                    
  Heap_Walk_printer printer = dump ?                                  
    _Heap_Walk_print : _Heap_Walk_print_nothing;                      
40009640:	80 a6 a0 00 	cmp  %i2, 0                                    
40009644:	02 80 00 05 	be  40009658 <_Heap_Walk+0x2c>                 
40009648:	e0 06 20 24 	ld  [ %i0 + 0x24 ], %l0                        
4000964c:	3b 10 00 25 	sethi  %hi(0x40009400), %i5                    
40009650:	10 80 00 04 	b  40009660 <_Heap_Walk+0x34>                  
40009654:	ba 17 61 dc 	or  %i5, 0x1dc, %i5	! 400095dc <_Heap_Walk_print>
40009658:	3b 10 00 25 	sethi  %hi(0x40009400), %i5                    
4000965c:	ba 17 61 d4 	or  %i5, 0x1d4, %i5	! 400095d4 <_Heap_Walk_print_nothing>
40009660:	05 10 00 6a 	sethi  %hi(0x4001a800), %g2                    
                                                                      
  if ( !_System_state_Is_up( _System_state_Get() ) ) {                
40009664:	c4 00 a1 d4 	ld  [ %g2 + 0x1d4 ], %g2	! 4001a9d4 <_System_state_Current>
40009668:	80 a0 a0 02 	cmp  %g2, 2                                    
4000966c:	22 80 00 04 	be,a   4000967c <_Heap_Walk+0x50>              
40009670:	c4 06 20 1c 	ld  [ %i0 + 0x1c ], %g2                        
    return true;                                                      
40009674:	10 80 01 30 	b  40009b34 <_Heap_Walk+0x508>                 
40009678:	a6 10 20 01 	mov  1, %l3                                    
  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)(                                                         
4000967c:	da 06 20 18 	ld  [ %i0 + 0x18 ], %o5                        
40009680:	c4 23 a0 5c 	st  %g2, [ %sp + 0x5c ]                        
40009684:	f2 23 a0 60 	st  %i1, [ %sp + 0x60 ]                        
40009688:	e0 23 a0 64 	st  %l0, [ %sp + 0x64 ]                        
4000968c:	c4 06 20 08 	ld  [ %i0 + 8 ], %g2                           
40009690:	90 10 00 16 	mov  %l6, %o0                                  
40009694:	c4 23 a0 68 	st  %g2, [ %sp + 0x68 ]                        
40009698:	c4 06 20 0c 	ld  [ %i0 + 0xc ], %g2                         
4000969c:	92 10 20 00 	clr  %o1                                       
400096a0:	c4 23 a0 6c 	st  %g2, [ %sp + 0x6c ]                        
400096a4:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
400096a8:	96 10 00 1c 	mov  %i4, %o3                                  
400096ac:	94 12 a0 f0 	or  %o2, 0xf0, %o2                             
400096b0:	9f c7 40 00 	call  %i5                                      
400096b4:	98 10 00 1b 	mov  %i3, %o4                                  
    heap->area_begin, heap->area_end,                                 
    first_block, last_block,                                          
    first_free_block, last_free_block                                 
  );                                                                  
                                                                      
  if ( page_size == 0 ) {                                             
400096b8:	80 a7 20 00 	cmp  %i4, 0                                    
400096bc:	12 80 00 07 	bne  400096d8 <_Heap_Walk+0xac>                
400096c0:	80 8f 20 07 	btst  7, %i4                                   
    (*printer)( source, true, "page size is zero\n" );                
400096c4:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
400096c8:	90 10 00 16 	mov  %l6, %o0                                  
400096cc:	92 10 20 01 	mov  1, %o1                                    
400096d0:	10 80 00 37 	b  400097ac <_Heap_Walk+0x180>                 
400096d4:	94 12 a1 88 	or  %o2, 0x188, %o2                            
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if ( !_Addresses_Is_aligned( (void *) page_size ) ) {               
400096d8:	22 80 00 08 	be,a   400096f8 <_Heap_Walk+0xcc>              
400096dc:	90 10 00 1b 	mov  %i3, %o0                                  
    (*printer)(                                                       
400096e0:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
400096e4:	90 10 00 16 	mov  %l6, %o0                                  
400096e8:	92 10 20 01 	mov  1, %o1                                    
400096ec:	94 12 a1 a0 	or  %o2, 0x1a0, %o2                            
400096f0:	10 80 00 4a 	b  40009818 <_Heap_Walk+0x1ec>                 
400096f4:	96 10 00 1c 	mov  %i4, %o3                                  
RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned(                           
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return (value % alignment) == 0;                                    
400096f8:	7f ff e1 3d 	call  40001bec <.urem>                         
400096fc:	92 10 00 1c 	mov  %i4, %o1                                  
    );                                                                
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if ( !_Heap_Is_aligned( min_block_size, page_size ) ) {             
40009700:	80 a2 20 00 	cmp  %o0, 0                                    
40009704:	22 80 00 08 	be,a   40009724 <_Heap_Walk+0xf8>              
40009708:	90 06 60 08 	add  %i1, 8, %o0                               
    (*printer)(                                                       
4000970c:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009710:	90 10 00 16 	mov  %l6, %o0                                  
40009714:	92 10 20 01 	mov  1, %o1                                    
40009718:	94 12 a1 c0 	or  %o2, 0x1c0, %o2                            
4000971c:	10 80 00 3f 	b  40009818 <_Heap_Walk+0x1ec>                 
40009720:	96 10 00 1b 	mov  %i3, %o3                                  
40009724:	7f ff e1 32 	call  40001bec <.urem>                         
40009728:	92 10 00 1c 	mov  %i4, %o1                                  
    );                                                                
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if (                                                                
4000972c:	80 a2 20 00 	cmp  %o0, 0                                    
40009730:	22 80 00 07 	be,a   4000974c <_Heap_Walk+0x120>             
40009734:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           
    !_Heap_Is_aligned( _Heap_Alloc_area_of_block( first_block ), page_size )
  ) {                                                                 
    (*printer)(                                                       
40009738:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
4000973c:	90 10 00 16 	mov  %l6, %o0                                  
40009740:	92 10 20 01 	mov  1, %o1                                    
40009744:	10 80 01 03 	b  40009b50 <_Heap_Walk+0x524>                 
40009748:	94 12 a1 e8 	or  %o2, 0x1e8, %o2                            
    );                                                                
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if ( !_Heap_Is_prev_used( first_block ) ) {                         
4000974c:	80 88 a0 01 	btst  1, %g2                                   
40009750:	32 80 00 07 	bne,a   4000976c <_Heap_Walk+0x140>            
40009754:	f4 04 20 04 	ld  [ %l0 + 4 ], %i2                           
    (*printer)(                                                       
40009758:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
4000975c:	90 10 00 16 	mov  %l6, %o0                                  
40009760:	92 10 20 01 	mov  1, %o1                                    
40009764:	10 80 00 12 	b  400097ac <_Heap_Walk+0x180>                 
40009768:	94 12 a2 20 	or  %o2, 0x220, %o2                            
    - 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;                
4000976c:	b4 0e bf fe 	and  %i2, -2, %i2                              
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
40009770:	b4 04 00 1a 	add  %l0, %i2, %i2                             
  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;                 
40009774:	c4 06 a0 04 	ld  [ %i2 + 4 ], %g2                           
    );                                                                
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if ( _Heap_Is_free( last_block ) ) {                                
40009778:	80 88 a0 01 	btst  1, %g2                                   
4000977c:	12 80 00 07 	bne  40009798 <_Heap_Walk+0x16c>               
40009780:	80 a6 80 19 	cmp  %i2, %i1                                  
    (*printer)(                                                       
40009784:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009788:	90 10 00 16 	mov  %l6, %o0                                  
4000978c:	92 10 20 01 	mov  1, %o1                                    
40009790:	10 80 00 07 	b  400097ac <_Heap_Walk+0x180>                 
40009794:	94 12 a2 50 	or  %o2, 0x250, %o2                            
    );                                                                
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if (                                                                
40009798:	02 80 00 0a 	be  400097c0 <_Heap_Walk+0x194>                
4000979c:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
    _Heap_Block_at( last_block, _Heap_Block_size( last_block ) ) != first_block
  ) {                                                                 
    (*printer)(                                                       
400097a0:	90 10 00 16 	mov  %l6, %o0                                  
400097a4:	92 10 20 01 	mov  1, %o1                                    
400097a8:	94 12 a2 68 	or  %o2, 0x268, %o2                            
400097ac:	9f c7 40 00 	call  %i5                                      
400097b0:	a6 10 20 00 	clr  %l3                                       
400097b4:	b0 0c e0 ff 	and  %l3, 0xff, %i0                            
400097b8:	81 c7 e0 08 	ret                                            
400097bc:	81 e8 00 00 	restore                                        
  int source,                                                         
  Heap_Walk_printer printer,                                          
  Heap_Control *heap                                                  
)                                                                     
{                                                                     
  uintptr_t const page_size = heap->page_size;                        
400097c0:	e2 06 20 10 	ld  [ %i0 + 0x10 ], %l1                        
  return &heap->free_list;                                            
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{                                                                     
  return _Heap_Free_list_head(heap)->next;                            
400097c4:	d6 06 20 08 	ld  [ %i0 + 8 ], %o3                           
  const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
400097c8:	10 80 00 03 	b  400097d4 <_Heap_Walk+0x1a8>                 
400097cc:	b2 10 00 18 	mov  %i0, %i1                                  
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    prev_block = free_block;                                          
    free_block = free_block->next;                                    
400097d0:	d6 02 e0 08 	ld  [ %o3 + 8 ], %o3                           
  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 ) {                            
400097d4:	80 a2 c0 18 	cmp  %o3, %i0                                  
400097d8:	22 80 00 34 	be,a   400098a8 <_Heap_Walk+0x27c>             
400097dc:	b2 10 00 1a 	mov  %i2, %i1                                  
  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;             
400097e0:	c6 06 20 20 	ld  [ %i0 + 0x20 ], %g3                        
400097e4:	80 a0 c0 0b 	cmp  %g3, %o3                                  
400097e8:	18 80 00 05 	bgu  400097fc <_Heap_Walk+0x1d0>               
400097ec:	84 10 20 00 	clr  %g2                                       
400097f0:	c4 06 20 24 	ld  [ %i0 + 0x24 ], %g2                        
400097f4:	80 a0 80 0b 	cmp  %g2, %o3                                  
400097f8:	84 60 3f ff 	subx  %g0, -1, %g2                             
    if ( !_Heap_Is_block_in_heap( heap, free_block ) ) {              
400097fc:	80 a0 a0 00 	cmp  %g2, 0                                    
40009800:	12 80 00 0b 	bne  4000982c <_Heap_Walk+0x200>               
40009804:	90 02 e0 08 	add  %o3, 8, %o0                               
      (*printer)(                                                     
40009808:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
4000980c:	90 10 00 16 	mov  %l6, %o0                                  
40009810:	92 10 20 01 	mov  1, %o1                                    
40009814:	94 12 a2 98 	or  %o2, 0x298, %o2                            
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( _Heap_Is_used( free_block ) ) {                              
      (*printer)(                                                     
40009818:	9f c7 40 00 	call  %i5                                      
4000981c:	a6 10 20 00 	clr  %l3                                       
40009820:	b0 0c e0 ff 	and  %l3, 0xff, %i0                            
40009824:	81 c7 e0 08 	ret                                            
40009828:	81 e8 00 00 	restore                                        
RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned(                           
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return (value % alignment) == 0;                                    
4000982c:	d6 27 bf fc 	st  %o3, [ %fp + -4 ]                          
40009830:	7f ff e0 ef 	call  40001bec <.urem>                         
40009834:	92 10 00 11 	mov  %l1, %o1                                  
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if (                                                              
40009838:	80 a2 20 00 	cmp  %o0, 0                                    
4000983c:	02 80 00 07 	be  40009858 <_Heap_Walk+0x22c>                
40009840:	d6 07 bf fc 	ld  [ %fp + -4 ], %o3                          
      !_Heap_Is_aligned( _Heap_Alloc_area_of_block( free_block ), page_size )
    ) {                                                               
      (*printer)(                                                     
40009844:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009848:	90 10 00 16 	mov  %l6, %o0                                  
4000984c:	92 10 20 01 	mov  1, %o1                                    
40009850:	10 bf ff f2 	b  40009818 <_Heap_Walk+0x1ec>                 
40009854:	94 12 a2 b8 	or  %o2, 0x2b8, %o2                            
    - 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;                
40009858:	c4 02 e0 04 	ld  [ %o3 + 4 ], %g2                           
4000985c:	84 08 bf fe 	and  %g2, -2, %g2                              
                                                                      
RTEMS_INLINE_ROUTINE bool _Heap_Is_used(                              
  const Heap_Block *block                                             
)                                                                     
{                                                                     
  const Heap_Block *const next_block =                                
40009860:	84 02 c0 02 	add  %o3, %g2, %g2                             
  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;                 
40009864:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( _Heap_Is_used( free_block ) ) {                              
40009868:	80 88 a0 01 	btst  1, %g2                                   
4000986c:	22 80 00 07 	be,a   40009888 <_Heap_Walk+0x25c>             
40009870:	d8 02 e0 0c 	ld  [ %o3 + 0xc ], %o4                         
      (*printer)(                                                     
40009874:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009878:	90 10 00 16 	mov  %l6, %o0                                  
4000987c:	92 10 20 01 	mov  1, %o1                                    
40009880:	10 bf ff e6 	b  40009818 <_Heap_Walk+0x1ec>                 
40009884:	94 12 a2 e8 	or  %o2, 0x2e8, %o2                            
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( free_block->prev != prev_block ) {                           
40009888:	80 a3 00 19 	cmp  %o4, %i1                                  
4000988c:	02 bf ff d1 	be  400097d0 <_Heap_Walk+0x1a4>                
40009890:	b2 10 00 0b 	mov  %o3, %i1                                  
      (*printer)(                                                     
40009894:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009898:	90 10 00 16 	mov  %l6, %o0                                  
4000989c:	92 10 20 01 	mov  1, %o1                                    
400098a0:	10 80 00 2b 	b  4000994c <_Heap_Walk+0x320>                 
400098a4:	94 12 a3 08 	or  %o2, 0x308, %o2                            
      " (= first free)"                                               
        : (block->prev == free_list_head ? " (= head)" : ""),         
    block->next,                                                      
    block->next == last_free_block ?                                  
      " (= last free)"                                                
        : (block->next == free_list_tail ? " (= tail)" : "")          
400098a8:	23 10 00 5c 	sethi  %hi(0x40017000), %l1                    
400098ac:	2f 10 00 5b 	sethi  %hi(0x40016c00), %l7                    
{                                                                     
  uintptr_t const page_size = heap->page_size;                        
  uintptr_t const min_block_size = heap->min_block_size;              
  Heap_Block *const first_block = heap->first_block;                  
  Heap_Block *const last_block = heap->last_block;                    
  Heap_Block *block = first_block;                                    
400098b0:	e4 06 60 04 	ld  [ %i1 + 4 ], %l2                           
  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;             
400098b4:	da 06 20 20 	ld  [ %i0 + 0x20 ], %o5                        
    uintptr_t const block_begin = (uintptr_t) block;                  
    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;        
    bool const is_not_last_block = block != last_block;               
400098b8:	9e 1e 40 10 	xor  %i1, %l0, %o7                             
400098bc:	80 a0 00 0f 	cmp  %g0, %o7                                  
    - 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;                
400098c0:	aa 0c bf fe 	and  %l2, -2, %l5                              
400098c4:	98 40 20 00 	addx  %g0, 0, %o4                              
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(                      
  const Heap_Block *block,                                            
  uintptr_t offset                                                    
)                                                                     
{                                                                     
  return (Heap_Block *) ((uintptr_t) block + offset);                 
400098c8:	a8 05 40 19 	add  %l5, %i1, %l4                             
  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;                 
400098cc:	a4 0c a0 01 	and  %l2, 1, %l2                               
  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;             
400098d0:	80 a3 40 14 	cmp  %o5, %l4                                  
400098d4:	18 80 00 05 	bgu  400098e8 <_Heap_Walk+0x2bc>               <== NEVER TAKEN
400098d8:	9e 10 20 00 	clr  %o7                                       
400098dc:	de 06 20 24 	ld  [ %i0 + 0x24 ], %o7                        
400098e0:	80 a3 c0 14 	cmp  %o7, %l4                                  
400098e4:	9e 60 3f ff 	subx  %g0, -1, %o7                             
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           
400098e8:	9e 0b e0 01 	and  %o7, 1, %o7                               
                                                                      
    if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {              
400098ec:	80 a3 e0 00 	cmp  %o7, 0                                    
400098f0:	12 80 00 07 	bne  4000990c <_Heap_Walk+0x2e0>               
400098f4:	a6 10 00 0f 	mov  %o7, %l3                                  
      (*printer)(                                                     
400098f8:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
400098fc:	90 10 00 16 	mov  %l6, %o0                                  
40009900:	92 10 20 01 	mov  1, %o1                                    
40009904:	10 80 00 31 	b  400099c8 <_Heap_Walk+0x39c>                 
40009908:	94 12 a3 40 	or  %o2, 0x340, %o2                            
RTEMS_INLINE_ROUTINE bool _Heap_Is_aligned(                           
  uintptr_t value,                                                    
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return (value % alignment) == 0;                                    
4000990c:	d8 27 bf f8 	st  %o4, [ %fp + -8 ]                          
40009910:	90 10 00 15 	mov  %l5, %o0                                  
40009914:	7f ff e0 b6 	call  40001bec <.urem>                         
40009918:	92 10 00 1c 	mov  %i4, %o1                                  
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( !_Heap_Is_aligned( block_size, page_size ) && is_not_last_block ) {
4000991c:	80 a2 20 00 	cmp  %o0, 0                                    
40009920:	02 80 00 10 	be  40009960 <_Heap_Walk+0x334>                
40009924:	d8 07 bf f8 	ld  [ %fp + -8 ], %o4                          
40009928:	80 a3 20 00 	cmp  %o4, 0                                    
4000992c:	02 80 00 0e 	be  40009964 <_Heap_Walk+0x338>                
40009930:	80 a5 40 1b 	cmp  %l5, %i3                                  
      (*printer)(                                                     
40009934:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009938:	90 10 00 16 	mov  %l6, %o0                                  
4000993c:	92 10 20 01 	mov  1, %o1                                    
40009940:	94 12 a3 70 	or  %o2, 0x370, %o2                            
40009944:	96 10 00 19 	mov  %i1, %o3                                  
40009948:	98 10 00 15 	mov  %l5, %o4                                  
4000994c:	9f c7 40 00 	call  %i5                                      
40009950:	a6 10 20 00 	clr  %l3                                       
40009954:	b0 0c e0 ff 	and  %l3, 0xff, %i0                            
40009958:	81 c7 e0 08 	ret                                            
4000995c:	81 e8 00 00 	restore                                        
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( block_size < min_block_size && is_not_last_block ) {         
40009960:	80 a5 40 1b 	cmp  %l5, %i3                                  
40009964:	9e 40 20 00 	addx  %g0, 0, %o7                              
40009968:	9e 0b 00 0f 	and  %o4, %o7, %o7                             
4000996c:	80 a3 e0 00 	cmp  %o7, 0                                    
40009970:	02 80 00 0c 	be  400099a0 <_Heap_Walk+0x374>                
40009974:	a6 10 00 0f 	mov  %o7, %l3                                  
      (*printer)(                                                     
40009978:	90 10 00 16 	mov  %l6, %o0                                  
4000997c:	92 10 20 01 	mov  1, %o1                                    
40009980:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
40009984:	96 10 00 19 	mov  %i1, %o3                                  
40009988:	94 12 a3 a0 	or  %o2, 0x3a0, %o2                            
4000998c:	98 10 00 15 	mov  %l5, %o4                                  
40009990:	9f c7 40 00 	call  %i5                                      
40009994:	9a 10 00 1b 	mov  %i3, %o5                                  
  if ( !_System_state_Is_up( _System_state_Get() ) ) {                
    return true;                                                      
  }                                                                   
                                                                      
  if ( !_Heap_Walk_check_control( source, printer, heap ) ) {         
    return false;                                                     
40009998:	10 80 00 67 	b  40009b34 <_Heap_Walk+0x508>                 
4000999c:	a6 10 20 00 	clr  %l3                                       
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( next_block_begin <= block_begin && is_not_last_block ) {     
400099a0:	80 a6 40 14 	cmp  %i1, %l4                                  
400099a4:	2a 80 00 0f 	bcs,a   400099e0 <_Heap_Walk+0x3b4>            
400099a8:	de 05 20 04 	ld  [ %l4 + 4 ], %o7                           
400099ac:	80 a3 20 00 	cmp  %o4, 0                                    
400099b0:	22 80 00 0c 	be,a   400099e0 <_Heap_Walk+0x3b4>             
400099b4:	de 05 20 04 	ld  [ %l4 + 4 ], %o7                           
      (*printer)(                                                     
400099b8:	15 10 00 5b 	sethi  %hi(0x40016c00), %o2                    
400099bc:	90 10 00 16 	mov  %l6, %o0                                  
400099c0:	92 10 20 01 	mov  1, %o1                                    
400099c4:	94 12 a3 d0 	or  %o2, 0x3d0, %o2                            
400099c8:	96 10 00 19 	mov  %i1, %o3                                  
400099cc:	9f c7 40 00 	call  %i5                                      
400099d0:	98 10 00 14 	mov  %l4, %o4                                  
400099d4:	b0 0c e0 ff 	and  %l3, 0xff, %i0                            
400099d8:	81 c7 e0 08 	ret                                            
400099dc:	81 e8 00 00 	restore                                        
      );                                                              
                                                                      
      return false;                                                   
    }                                                                 
                                                                      
    if ( !_Heap_Is_prev_used( next_block ) ) {                        
400099e0:	80 8b e0 01 	btst  1, %o7                                   
400099e4:	12 80 00 3f 	bne  40009ae0 <_Heap_Walk+0x4b4>               
400099e8:	90 10 00 16 	mov  %l6, %o0                                  
    false,                                                            
    "block 0x%08x: size %u, prev 0x%08x%s, next 0x%08x%s\n",          
    block,                                                            
    block_size,                                                       
    block->prev,                                                      
    block->prev == first_free_block ?                                 
400099ec:	da 06 60 0c 	ld  [ %i1 + 0xc ], %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)(                                                         
400099f0:	d8 06 20 08 	ld  [ %i0 + 8 ], %o4                           
400099f4:	80 a3 40 0c 	cmp  %o5, %o4                                  
400099f8:	02 80 00 08 	be  40009a18 <_Heap_Walk+0x3ec>                
400099fc:	de 06 20 0c 	ld  [ %i0 + 0xc ], %o7                         
    block,                                                            
    block_size,                                                       
    block->prev,                                                      
    block->prev == first_free_block ?                                 
      " (= first free)"                                               
        : (block->prev == free_list_head ? " (= head)" : ""),         
40009a00:	80 a3 40 18 	cmp  %o5, %i0                                  
40009a04:	12 80 00 07 	bne  40009a20 <_Heap_Walk+0x3f4>               
40009a08:	96 14 60 78 	or  %l1, 0x78, %o3                             
40009a0c:	17 10 00 5b 	sethi  %hi(0x40016c00), %o3                    
40009a10:	10 80 00 04 	b  40009a20 <_Heap_Walk+0x3f4>                 
40009a14:	96 12 e0 c0 	or  %o3, 0xc0, %o3	! 40016cc0 <_Semaphore_Translate_core_mutex_return_code_+0x88>
  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)(                                                         
40009a18:	03 10 00 5b 	sethi  %hi(0x40016c00), %g1                    
40009a1c:	96 10 60 b0 	or  %g1, 0xb0, %o3	! 40016cb0 <_Semaphore_Translate_core_mutex_return_code_+0x78>
    block->prev,                                                      
    block->prev == first_free_block ?                                 
      " (= first free)"                                               
        : (block->prev == free_list_head ? " (= head)" : ""),         
    block->next,                                                      
    block->next == last_free_block ?                                  
40009a20:	d8 06 60 08 	ld  [ %i1 + 8 ], %o4                           
  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)(                                                         
40009a24:	80 a3 00 0f 	cmp  %o4, %o7                                  
40009a28:	02 80 00 06 	be  40009a40 <_Heap_Walk+0x414>                
40009a2c:	80 a3 00 18 	cmp  %o4, %i0                                  
      " (= first free)"                                               
        : (block->prev == free_list_head ? " (= head)" : ""),         
    block->next,                                                      
    block->next == last_free_block ?                                  
      " (= last free)"                                                
        : (block->next == free_list_tail ? " (= tail)" : "")          
40009a30:	12 80 00 06 	bne  40009a48 <_Heap_Walk+0x41c>               
40009a34:	9e 14 60 78 	or  %l1, 0x78, %o7                             
40009a38:	10 80 00 04 	b  40009a48 <_Heap_Walk+0x41c>                 
40009a3c:	9e 15 e0 e0 	or  %l7, 0xe0, %o7                             
  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)(                                                         
40009a40:	03 10 00 5b 	sethi  %hi(0x40016c00), %g1                    
40009a44:	9e 10 60 d0 	or  %g1, 0xd0, %o7	! 40016cd0 <_Semaphore_Translate_core_mutex_return_code_+0x98>
40009a48:	d6 23 a0 5c 	st  %o3, [ %sp + 0x5c ]                        
40009a4c:	d8 23 a0 60 	st  %o4, [ %sp + 0x60 ]                        
40009a50:	de 23 a0 64 	st  %o7, [ %sp + 0x64 ]                        
40009a54:	90 10 00 16 	mov  %l6, %o0                                  
40009a58:	92 10 20 00 	clr  %o1                                       
40009a5c:	15 10 00 5c 	sethi  %hi(0x40017000), %o2                    
40009a60:	96 10 00 19 	mov  %i1, %o3                                  
40009a64:	94 12 a0 08 	or  %o2, 8, %o2                                
40009a68:	9f c7 40 00 	call  %i5                                      
40009a6c:	98 10 00 15 	mov  %l5, %o4                                  
    block->next == last_free_block ?                                  
      " (= last free)"                                                
        : (block->next == free_list_tail ? " (= tail)" : "")          
  );                                                                  
                                                                      
  if ( block_size != next_block->prev_size ) {                        
40009a70:	da 05 00 00 	ld  [ %l4 ], %o5                               
40009a74:	80 a5 40 0d 	cmp  %l5, %o5                                  
40009a78:	02 80 00 0c 	be  40009aa8 <_Heap_Walk+0x47c>                
40009a7c:	80 a4 a0 00 	cmp  %l2, 0                                    
    (*printer)(                                                       
40009a80:	e8 23 a0 5c 	st  %l4, [ %sp + 0x5c ]                        
40009a84:	90 10 00 16 	mov  %l6, %o0                                  
40009a88:	92 10 20 01 	mov  1, %o1                                    
40009a8c:	15 10 00 5c 	sethi  %hi(0x40017000), %o2                    
40009a90:	96 10 00 19 	mov  %i1, %o3                                  
40009a94:	94 12 a0 40 	or  %o2, 0x40, %o2                             
40009a98:	9f c7 40 00 	call  %i5                                      
40009a9c:	98 10 00 15 	mov  %l5, %o4                                  
  if ( !_System_state_Is_up( _System_state_Get() ) ) {                
    return true;                                                      
  }                                                                   
                                                                      
  if ( !_Heap_Walk_check_control( source, printer, heap ) ) {         
    return false;                                                     
40009aa0:	10 80 00 25 	b  40009b34 <_Heap_Walk+0x508>                 
40009aa4:	a6 10 20 00 	clr  %l3                                       
    );                                                                
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if ( !prev_used ) {                                                 
40009aa8:	32 80 00 07 	bne,a   40009ac4 <_Heap_Walk+0x498>            
40009aac:	c8 06 20 08 	ld  [ %i0 + 8 ], %g4                           
    (*printer)(                                                       
40009ab0:	15 10 00 5c 	sethi  %hi(0x40017000), %o2                    
40009ab4:	90 10 00 16 	mov  %l6, %o0                                  
40009ab8:	92 10 20 01 	mov  1, %o1                                    
40009abc:	10 80 00 25 	b  40009b50 <_Heap_Walk+0x524>                 
40009ac0:	94 12 a0 80 	or  %o2, 0x80, %o2                             
)                                                                     
{                                                                     
  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 ) {                            
40009ac4:	80 a1 00 18 	cmp  %g4, %i0                                  
40009ac8:	02 80 00 1e 	be  40009b40 <_Heap_Walk+0x514>                
40009acc:	80 a1 00 19 	cmp  %g4, %i1                                  
    if ( free_block == block ) {                                      
40009ad0:	02 80 00 15 	be  40009b24 <_Heap_Walk+0x4f8>                
40009ad4:	80 a5 00 1a 	cmp  %l4, %i2                                  
      return true;                                                    
    }                                                                 
    free_block = free_block->next;                                    
40009ad8:	10 bf ff fb 	b  40009ac4 <_Heap_Walk+0x498>                 
40009adc:	c8 01 20 08 	ld  [ %g4 + 8 ], %g4                           
                                                                      
    if ( !_Heap_Is_prev_used( next_block ) ) {                        
      if ( !_Heap_Walk_check_free_block( source, printer, heap, block ) ) {
        return false;                                                 
      }                                                               
    } else if (prev_used) {                                           
40009ae0:	80 a4 a0 00 	cmp  %l2, 0                                    
40009ae4:	02 80 00 09 	be  40009b08 <_Heap_Walk+0x4dc>                
40009ae8:	92 10 20 00 	clr  %o1                                       
      (*printer)(                                                     
40009aec:	15 10 00 5c 	sethi  %hi(0x40017000), %o2                    
40009af0:	96 10 00 19 	mov  %i1, %o3                                  
40009af4:	94 12 a0 b0 	or  %o2, 0xb0, %o2                             
40009af8:	9f c7 40 00 	call  %i5                                      
40009afc:	98 10 00 15 	mov  %l5, %o4                                  
40009b00:	10 80 00 09 	b  40009b24 <_Heap_Walk+0x4f8>                 
40009b04:	80 a5 00 1a 	cmp  %l4, %i2                                  
        "block 0x%08x: size %u\n",                                    
        block,                                                        
        block_size                                                    
      );                                                              
    } else {                                                          
      (*printer)(                                                     
40009b08:	da 06 40 00 	ld  [ %i1 ], %o5                               
40009b0c:	15 10 00 5c 	sethi  %hi(0x40017000), %o2                    
40009b10:	96 10 00 19 	mov  %i1, %o3                                  
40009b14:	94 12 a0 c8 	or  %o2, 0xc8, %o2                             
40009b18:	9f c7 40 00 	call  %i5                                      
40009b1c:	98 10 00 15 	mov  %l5, %o4                                  
        block->prev_size                                              
      );                                                              
    }                                                                 
                                                                      
    block = next_block;                                               
  } while ( block != first_block );                                   
40009b20:	80 a5 00 1a 	cmp  %l4, %i2                                  
40009b24:	02 80 00 04 	be  40009b34 <_Heap_Walk+0x508>                
40009b28:	a6 10 20 01 	mov  1, %l3                                    
40009b2c:	10 bf ff 61 	b  400098b0 <_Heap_Walk+0x284>                 
40009b30:	b2 10 00 14 	mov  %l4, %i1                                  
40009b34:	b0 0c e0 ff 	and  %l3, 0xff, %i0                            
40009b38:	81 c7 e0 08 	ret                                            
40009b3c:	81 e8 00 00 	restore                                        
                                                                      
    return false;                                                     
  }                                                                   
                                                                      
  if ( !_Heap_Walk_is_in_free_list( heap, block ) ) {                 
    (*printer)(                                                       
40009b40:	15 10 00 5c 	sethi  %hi(0x40017000), %o2                    
40009b44:	90 10 00 16 	mov  %l6, %o0                                  
40009b48:	92 10 20 01 	mov  1, %o1                                    
40009b4c:	94 12 a0 f0 	or  %o2, 0xf0, %o2                             
40009b50:	10 bf ff 32 	b  40009818 <_Heap_Walk+0x1ec>                 
40009b54:	96 10 00 19 	mov  %i1, %o3                                  
                                                                      

40008ab4 <_Objects_Allocate_unprotected>: } Objects_Control *_Objects_Allocate_unprotected( Objects_Information *information ) {
40008ab4:	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 )                                       
40008ab8:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
40008abc:	80 a0 60 00 	cmp  %g1, 0                                    
40008ac0:	12 80 00 04 	bne  40008ad0 <_Objects_Allocate_unprotected+0x1c><== ALWAYS TAKEN
40008ac4:	ba 10 00 18 	mov  %i0, %i5                                  
    return NULL;                                                      
40008ac8:	81 c7 e0 08 	ret                                            
40008acc:	91 e8 20 00 	restore  %g0, 0, %o0                           
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40008ad0:	f8 06 20 20 	ld  [ %i0 + 0x20 ], %i4                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40008ad4:	b4 06 20 24 	add  %i0, 0x24, %i2                            
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40008ad8:	80 a7 00 1a 	cmp  %i4, %i2                                  
40008adc:	02 80 00 06 	be  40008af4 <_Objects_Allocate_unprotected+0x40>
40008ae0:	b6 06 20 20 	add  %i0, 0x20, %i3                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40008ae4:	c2 07 00 00 	ld  [ %i4 ], %g1                               
                                                                      
  head->next = new_first;                                             
40008ae8:	c2 26 20 20 	st  %g1, [ %i0 + 0x20 ]                        
  new_first->previous = head;                                         
40008aec:	10 80 00 03 	b  40008af8 <_Objects_Allocate_unprotected+0x44>
40008af0:	f6 20 60 04 	st  %i3, [ %g1 + 4 ]                           
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
    return _Chain_Get_first_unprotected(the_chain);                   
  else                                                                
    return NULL;                                                      
40008af4:	b8 10 20 00 	clr  %i4                                       
   *  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_Get_inactive( information );                  
                                                                      
  if ( information->auto_extend ) {                                   
40008af8:	c2 0f 60 12 	ldub  [ %i5 + 0x12 ], %g1                      
40008afc:	80 a0 60 00 	cmp  %g1, 0                                    
40008b00:	02 80 00 20 	be  40008b80 <_Objects_Allocate_unprotected+0xcc>
40008b04:	b0 10 00 1c 	mov  %i4, %i0                                  
    /*                                                                
     *  If the list is empty then we are out of objects and need to   
     *  extend information base.                                      
     */                                                               
                                                                      
    if ( !the_object ) {                                              
40008b08:	80 a7 20 00 	cmp  %i4, 0                                    
40008b0c:	32 80 00 0c 	bne,a   40008b3c <_Objects_Allocate_unprotected+0x88>
40008b10:	c4 07 60 08 	ld  [ %i5 + 8 ], %g2                           
      _Objects_Extend_information( information );                     
40008b14:	40 00 00 2a 	call  40008bbc <_Objects_Extend_information>   
40008b18:	90 10 00 1d 	mov  %i5, %o0                                  
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40008b1c:	f8 07 60 20 	ld  [ %i5 + 0x20 ], %i4                        
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40008b20:	80 a7 00 1a 	cmp  %i4, %i2                                  
40008b24:	02 bf ff e9 	be  40008ac8 <_Objects_Allocate_unprotected+0x14>
40008b28:	01 00 00 00 	nop                                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40008b2c:	c2 07 00 00 	ld  [ %i4 ], %g1                               
                                                                      
  head->next = new_first;                                             
40008b30:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
  new_first->previous = head;                                         
40008b34:	f6 20 60 04 	st  %i3, [ %g1 + 4 ]                           
    }                                                                 
                                                                      
    if ( the_object ) {                                               
      uint32_t   block;                                               
                                                                      
      block = (uint32_t) _Objects_Get_index( the_object->id ) -       
40008b38:	c4 07 60 08 	ld  [ %i5 + 8 ], %g2                           
40008b3c:	d0 07 20 08 	ld  [ %i4 + 8 ], %o0                           
              _Objects_Get_index( information->minimum_id );          
      block /= information->allocation_size;                          
40008b40:	d2 17 60 14 	lduh  [ %i5 + 0x14 ], %o1                      
    }                                                                 
                                                                      
    if ( the_object ) {                                               
      uint32_t   block;                                               
                                                                      
      block = (uint32_t) _Objects_Get_index( the_object->id ) -       
40008b44:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
40008b48:	82 10 63 ff 	or  %g1, 0x3ff, %g1	! ffff <_TLS_Alignment+0xfffe>
40008b4c:	90 0a 00 01 	and  %o0, %g1, %o0                             
40008b50:	82 08 80 01 	and  %g2, %g1, %g1                             
              _Objects_Get_index( information->minimum_id );          
      block /= information->allocation_size;                          
40008b54:	40 00 2a 61 	call  400134d8 <.udiv>                         
40008b58:	90 22 00 01 	sub  %o0, %g1, %o0                             
                                                                      
      information->inactive_per_block[ block ]--;                     
40008b5c:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        
40008b60:	91 2a 20 02 	sll  %o0, 2, %o0                               
40008b64:	c4 00 40 08 	ld  [ %g1 + %o0 ], %g2                         
      information->inactive--;                                        
40008b68:	b0 10 00 1c 	mov  %i4, %i0                                  
                                                                      
      block = (uint32_t) _Objects_Get_index( the_object->id ) -       
              _Objects_Get_index( information->minimum_id );          
      block /= information->allocation_size;                          
                                                                      
      information->inactive_per_block[ block ]--;                     
40008b6c:	84 00 bf ff 	add  %g2, -1, %g2                              
40008b70:	c4 20 40 08 	st  %g2, [ %g1 + %o0 ]                         
      information->inactive--;                                        
40008b74:	c2 17 60 2c 	lduh  [ %i5 + 0x2c ], %g1                      
40008b78:	82 00 7f ff 	add  %g1, -1, %g1                              
40008b7c:	c2 37 60 2c 	sth  %g1, [ %i5 + 0x2c ]                       
    );                                                                
  }                                                                   
#endif                                                                
                                                                      
  return the_object;                                                  
}                                                                     
40008b80:	81 c7 e0 08 	ret                                            
40008b84:	81 e8 00 00 	restore                                        
                                                                      

40008bbc <_Objects_Extend_information>: */ void _Objects_Extend_information( Objects_Information *information ) {
40008bbc:	9d e3 bf a0 	save  %sp, -96, %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 )                           
40008bc0:	f2 06 20 34 	ld  [ %i0 + 0x34 ], %i1                        
 */                                                                   
                                                                      
void _Objects_Extend_information(                                     
  Objects_Information *information                                    
)                                                                     
{                                                                     
40008bc4:	ba 10 00 18 	mov  %i0, %i5                                  
  /*                                                                  
   *  Search for a free block of indexes. If we do NOT need to allocate or
   *  extend the block table, then we will change do_extend.          
   */                                                                 
  do_extend     = true;                                               
  minimum_index = _Objects_Get_index( information->minimum_id );      
40008bc8:	f4 16 20 0a 	lduh  [ %i0 + 0xa ], %i2                       
  index_base    = minimum_index;                                      
  block         = 0;                                                  
                                                                      
  /* if ( information->maximum < minimum_index ) */                   
  if ( information->object_blocks == NULL )                           
40008bcc:	80 a6 60 00 	cmp  %i1, 0                                    
40008bd0:	e8 16 20 14 	lduh  [ %i0 + 0x14 ], %l4                      
40008bd4:	02 80 00 18 	be  40008c34 <_Objects_Extend_information+0x78>
40008bd8:	e0 16 20 10 	lduh  [ %i0 + 0x10 ], %l0                      
    block_count = 0;                                                  
  else {                                                              
    block_count = information->maximum / information->allocation_size;
40008bdc:	91 2c 20 10 	sll  %l0, 0x10, %o0                            
40008be0:	b1 2d 20 10 	sll  %l4, 0x10, %i0                            
40008be4:	91 32 20 10 	srl  %o0, 0x10, %o0                            
40008be8:	b1 36 20 10 	srl  %i0, 0x10, %i0                            
  /*                                                                  
   *  Search for a free block of indexes. If we do NOT need to allocate or
   *  extend the block table, then we will change do_extend.          
   */                                                                 
  do_extend     = true;                                               
  minimum_index = _Objects_Get_index( information->minimum_id );      
40008bec:	b8 10 00 1a 	mov  %i2, %i4                                  
                                                                      
  /* if ( information->maximum < minimum_index ) */                   
  if ( information->object_blocks == NULL )                           
    block_count = 0;                                                  
  else {                                                              
    block_count = information->maximum / information->allocation_size;
40008bf0:	92 10 00 18 	mov  %i0, %o1                                  
40008bf4:	40 00 2a 39 	call  400134d8 <.udiv>                         
40008bf8:	b6 10 20 00 	clr  %i3                                       
40008bfc:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
40008c00:	a7 32 20 10 	srl  %o0, 0x10, %l3                            
                                                                      
    for ( ; block < block_count; block++ ) {                          
40008c04:	80 a6 c0 13 	cmp  %i3, %l3                                  
40008c08:	1a 80 00 09 	bcc  40008c2c <_Objects_Extend_information+0x70>
40008c0c:	83 2e e0 02 	sll  %i3, 2, %g1                               
      if ( information->object_blocks[ block ] == NULL ) {            
40008c10:	c2 06 40 01 	ld  [ %i1 + %g1 ], %g1                         
40008c14:	80 a0 60 00 	cmp  %g1, 0                                    
40008c18:	22 80 00 0b 	be,a   40008c44 <_Objects_Extend_information+0x88>
40008c1c:	b2 10 20 00 	clr  %i1                                       
        do_extend = false;                                            
        break;                                                        
      } else                                                          
        index_base += information->allocation_size;                   
40008c20:	b8 07 00 18 	add  %i4, %i0, %i4                             
  if ( information->object_blocks == NULL )                           
    block_count = 0;                                                  
  else {                                                              
    block_count = information->maximum / information->allocation_size;
                                                                      
    for ( ; block < block_count; block++ ) {                          
40008c24:	10 bf ff f8 	b  40008c04 <_Objects_Extend_information+0x48> 
40008c28:	b6 06 e0 01 	inc  %i3                                       
40008c2c:	10 80 00 06 	b  40008c44 <_Objects_Extend_information+0x88> 
40008c30:	b2 10 20 01 	mov  1, %i1                                    
  /*                                                                  
   *  Search for a free block of indexes. If we do NOT need to allocate or
   *  extend the block table, then we will change do_extend.          
   */                                                                 
  do_extend     = true;                                               
  minimum_index = _Objects_Get_index( information->minimum_id );      
40008c34:	b8 10 00 1a 	mov  %i2, %i4                                  
                                                                      
  /*                                                                  
   *  Search for a free block of indexes. If we do NOT need to allocate or
   *  extend the block table, then we will change do_extend.          
   */                                                                 
  do_extend     = true;                                               
40008c38:	b2 10 20 01 	mov  1, %i1                                    
  minimum_index = _Objects_Get_index( information->minimum_id );      
  index_base    = minimum_index;                                      
  block         = 0;                                                  
40008c3c:	b6 10 20 00 	clr  %i3                                       
40008c40:	a6 10 20 00 	clr  %l3                                       
        break;                                                        
      } else                                                          
        index_base += information->allocation_size;                   
    }                                                                 
  }                                                                   
  index_end = index_base + information->allocation_size;              
40008c44:	a9 2d 20 10 	sll  %l4, 0x10, %l4                            
                                                                      
  maximum = (uint32_t) information->maximum + information->allocation_size;
40008c48:	a1 2c 20 10 	sll  %l0, 0x10, %l0                            
        break;                                                        
      } else                                                          
        index_base += information->allocation_size;                   
    }                                                                 
  }                                                                   
  index_end = index_base + information->allocation_size;              
40008c4c:	a9 35 20 10 	srl  %l4, 0x10, %l4                            
                                                                      
  maximum = (uint32_t) information->maximum + information->allocation_size;
40008c50:	a1 34 20 10 	srl  %l0, 0x10, %l0                            
  /*                                                                  
   *  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 ) {                           
40008c54:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
        index_base += information->allocation_size;                   
    }                                                                 
  }                                                                   
  index_end = index_base + information->allocation_size;              
                                                                      
  maximum = (uint32_t) information->maximum + information->allocation_size;
40008c58:	a0 04 00 14 	add  %l0, %l4, %l0                             
  /*                                                                  
   *  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 ) {                           
40008c5c:	82 10 63 ff 	or  %g1, 0x3ff, %g1                            
40008c60:	80 a4 00 01 	cmp  %l0, %g1                                  
40008c64:	18 80 00 8d 	bgu  40008e98 <_Objects_Extend_information+0x2dc>
40008c68:	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;      
40008c6c:	d2 07 60 18 	ld  [ %i5 + 0x18 ], %o1                        
40008c70:	40 00 29 e0 	call  400133f0 <.umul>                         
40008c74:	90 10 00 14 	mov  %l4, %o0                                  
  if ( information->auto_extend ) {                                   
40008c78:	c2 0f 60 12 	ldub  [ %i5 + 0x12 ], %g1                      
40008c7c:	80 a0 60 00 	cmp  %g1, 0                                    
40008c80:	02 80 00 09 	be  40008ca4 <_Objects_Extend_information+0xe8>
40008c84:	01 00 00 00 	nop                                            
    new_object_block = _Workspace_Allocate( block_size );             
40008c88:	40 00 09 bc 	call  4000b378 <_Workspace_Allocate>           
40008c8c:	01 00 00 00 	nop                                            
    if ( !new_object_block )                                          
40008c90:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40008c94:	12 80 00 08 	bne  40008cb4 <_Objects_Extend_information+0xf8><== ALWAYS TAKEN
40008c98:	80 8e 60 ff 	btst  0xff, %i1                                
40008c9c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40008ca0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
      return;                                                         
  } else {                                                            
    new_object_block = _Workspace_Allocate_or_fatal_error( block_size );
40008ca4:	40 00 09 cc 	call  4000b3d4 <_Workspace_Allocate_or_fatal_error>
40008ca8:	01 00 00 00 	nop                                            
40008cac:	b0 10 00 08 	mov  %o0, %i0                                  
  }                                                                   
                                                                      
  /*                                                                  
   *  Do we need to grow the tables?                                  
   */                                                                 
  if ( do_extend ) {                                                  
40008cb0:	80 8e 60 ff 	btst  0xff, %i1                                
40008cb4:	02 80 00 59 	be  40008e18 <_Objects_Extend_information+0x25c>
40008cb8:	a8 07 00 14 	add  %i4, %l4, %l4                             
     */                                                               
                                                                      
    /*                                                                
     *  Up the block count and maximum                                
     */                                                               
    block_count++;                                                    
40008cbc:	a6 04 e0 01 	inc  %l3                                       
     *      1. object_blocks        : void*                           
     *      2. inactive_per_blocks : uint32_t                         
     *      3. local_table         : Objects_Name*                    
     */                                                               
    object_blocks_size = (uintptr_t)_Addresses_Align_up(              
        (void*)(block_count * sizeof(void*)),                         
40008cc0:	a7 2c e0 02 	sll  %l3, 2, %l3                               
  void *address,                                                      
  size_t alignment                                                    
)                                                                     
{                                                                     
  uintptr_t mask = alignment - (uintptr_t)1;                          
  return (void*)(((uintptr_t)address + mask) & ~mask);                
40008cc4:	a2 04 e0 07 	add  %l3, 7, %l1                               
40008cc8:	a2 0c 7f f8 	and  %l1, -8, %l1                              
    inactive_per_block_size =                                         
        (uintptr_t)_Addresses_Align_up(                               
            (void*)(block_count * sizeof(uint32_t)),                  
            CPU_ALIGNMENT                                             
        );                                                            
    block_size = object_blocks_size + inactive_per_block_size +       
40008ccc:	83 2c 60 01 	sll  %l1, 1, %g1                               
        ((maximum + minimum_index) * sizeof(Objects_Control *));      
40008cd0:	90 04 00 1a 	add  %l0, %i2, %o0                             
40008cd4:	91 2a 20 02 	sll  %o0, 2, %o0                               
    inactive_per_block_size =                                         
        (uintptr_t)_Addresses_Align_up(                               
            (void*)(block_count * sizeof(uint32_t)),                  
            CPU_ALIGNMENT                                             
        );                                                            
    block_size = object_blocks_size + inactive_per_block_size +       
40008cd8:	90 00 40 08 	add  %g1, %o0, %o0                             
        ((maximum + minimum_index) * sizeof(Objects_Control *));      
    if ( information->auto_extend ) {                                 
40008cdc:	c2 0f 60 12 	ldub  [ %i5 + 0x12 ], %g1                      
40008ce0:	80 a0 60 00 	cmp  %g1, 0                                    
40008ce4:	02 80 00 09 	be  40008d08 <_Objects_Extend_information+0x14c>
40008ce8:	01 00 00 00 	nop                                            
      object_blocks = _Workspace_Allocate( block_size );              
40008cec:	40 00 09 a3 	call  4000b378 <_Workspace_Allocate>           
40008cf0:	01 00 00 00 	nop                                            
      if ( !object_blocks ) {                                         
40008cf4:	b2 92 20 00 	orcc  %o0, 0, %i1                              
40008cf8:	32 80 00 08 	bne,a   40008d18 <_Objects_Extend_information+0x15c><== ALWAYS TAKEN
40008cfc:	c2 17 60 10 	lduh  [ %i5 + 0x10 ], %g1                      
        _Workspace_Free( new_object_block );                          
40008d00:	40 00 09 af 	call  4000b3bc <_Workspace_Free>               <== NOT EXECUTED
40008d04:	81 e8 00 00 	restore                                        <== NOT EXECUTED
        return;                                                       
      }                                                               
    } else {                                                          
      object_blocks = _Workspace_Allocate_or_fatal_error( block_size );
40008d08:	40 00 09 b3 	call  4000b3d4 <_Workspace_Allocate_or_fatal_error>
40008d0c:	01 00 00 00 	nop                                            
40008d10:	b2 10 00 08 	mov  %o0, %i1                                  
     *  Take the block count down. Saves all the (block_count - 1)    
     *  in the copies.                                                
     */                                                               
    block_count--;                                                    
                                                                      
    if ( information->maximum > minimum_index ) {                     
40008d14:	c2 17 60 10 	lduh  [ %i5 + 0x10 ], %g1                      
RTEMS_INLINE_ROUTINE void *_Addresses_Add_offset (                    
  const void *base,                                                   
  uintptr_t   offset                                                  
)                                                                     
{                                                                     
  return (void *)((uintptr_t)base + offset);                          
40008d18:	a4 06 40 11 	add  %i1, %l1, %l2                             
40008d1c:	80 a0 40 1a 	cmp  %g1, %i2                                  
40008d20:	18 80 00 04 	bgu  40008d30 <_Objects_Extend_information+0x174>
40008d24:	a2 04 80 11 	add  %l2, %l1, %l1                             
40008d28:	10 80 00 13 	b  40008d74 <_Objects_Extend_information+0x1b8>
40008d2c:	82 10 20 00 	clr  %g1                                       
      /*                                                              
       *  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,                                          
40008d30:	d2 07 60 34 	ld  [ %i5 + 0x34 ], %o1                        
              information->object_blocks,                             
              block_count * sizeof(void*) );                          
40008d34:	aa 04 ff fc 	add  %l3, -4, %l5                              
      /*                                                              
       *  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,                                          
40008d38:	90 10 00 19 	mov  %i1, %o0                                  
40008d3c:	40 00 1d 1f 	call  400101b8 <memcpy>                        
40008d40:	94 10 00 15 	mov  %l5, %o2                                  
              information->object_blocks,                             
              block_count * sizeof(void*) );                          
      memcpy( inactive_per_block,                                     
40008d44:	d2 07 60 30 	ld  [ %i5 + 0x30 ], %o1                        
40008d48:	94 10 00 15 	mov  %l5, %o2                                  
40008d4c:	40 00 1d 1b 	call  400101b8 <memcpy>                        
40008d50:	90 10 00 12 	mov  %l2, %o0                                  
              information->inactive_per_block,                        
              block_count * sizeof(uint32_t) );                       
      memcpy( local_table,                                            
              information->local_table,                               
              (information->maximum + minimum_index) * sizeof(Objects_Control *) );
40008d54:	c2 17 60 10 	lduh  [ %i5 + 0x10 ], %g1                      
              information->object_blocks,                             
              block_count * sizeof(void*) );                          
      memcpy( inactive_per_block,                                     
              information->inactive_per_block,                        
              block_count * sizeof(uint32_t) );                       
      memcpy( local_table,                                            
40008d58:	d2 07 60 1c 	ld  [ %i5 + 0x1c ], %o1                        
              information->local_table,                               
              (information->maximum + minimum_index) * sizeof(Objects_Control *) );
40008d5c:	94 00 40 1a 	add  %g1, %i2, %o2                             
              information->object_blocks,                             
              block_count * sizeof(void*) );                          
      memcpy( inactive_per_block,                                     
              information->inactive_per_block,                        
              block_count * sizeof(uint32_t) );                       
      memcpy( local_table,                                            
40008d60:	90 10 00 11 	mov  %l1, %o0                                  
40008d64:	40 00 1d 15 	call  400101b8 <memcpy>                        
40008d68:	95 2a a0 02 	sll  %o2, 2, %o2                               
40008d6c:	10 80 00 09 	b  40008d90 <_Objects_Extend_information+0x1d4>
40008d70:	a6 04 ff fc 	add  %l3, -4, %l3                              
    } else {                                                          
                                                                      
      /*                                                              
       *  Deal with the special case of the 0 to minimum_index        
       */                                                             
      for ( index = 0; index < minimum_index; index++ ) {             
40008d74:	80 a0 40 1a 	cmp  %g1, %i2                                  
40008d78:	02 80 00 05 	be  40008d8c <_Objects_Extend_information+0x1d0>
40008d7c:	85 28 60 02 	sll  %g1, 2, %g2                               
40008d80:	82 00 60 01 	inc  %g1                                       
        local_table[ index ] = NULL;                                  
40008d84:	10 bf ff fc 	b  40008d74 <_Objects_Extend_information+0x1b8>
40008d88:	c0 20 80 11 	clr  [ %g2 + %l1 ]                             
    }                                                                 
                                                                      
    /*                                                                
     *  Initialise the new entries in the table.                      
     */                                                               
    object_blocks[block_count] = NULL;                                
40008d8c:	a6 04 ff fc 	add  %l3, -4, %l3                              
40008d90:	c0 26 40 13 	clr  [ %i1 + %l3 ]                             
    inactive_per_block[block_count] = 0;                              
40008d94:	c0 24 80 13 	clr  [ %l2 + %l3 ]                             
                                                                      
    for ( index = index_base ; index < index_end ; ++index ) {        
40008d98:	82 10 00 1c 	mov  %i4, %g1                                  
40008d9c:	80 a0 40 14 	cmp  %g1, %l4                                  
40008da0:	1a 80 00 05 	bcc  40008db4 <_Objects_Extend_information+0x1f8>
40008da4:	85 28 60 02 	sll  %g1, 2, %g2                               
40008da8:	82 00 60 01 	inc  %g1                                       
      local_table[ index ] = NULL;                                    
40008dac:	10 bf ff fc 	b  40008d9c <_Objects_Extend_information+0x1e0>
40008db0:	c0 20 80 11 	clr  [ %g2 + %l1 ]                             
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40008db4:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40008db8:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40008dbc:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
    }                                                                 
                                                                      
    _Thread_Disable_dispatch();                                       
    _ISR_Disable( level );                                            
40008dc0:	7f ff e5 9d 	call  40002434 <sparc_disable_interrupts>      
40008dc4:	01 00 00 00 	nop                                            
  uint32_t         the_class,                                         
  uint32_t         node,                                              
  uint32_t         index                                              
)                                                                     
{                                                                     
  return (( (Objects_Id) the_api )   << OBJECTS_API_START_BIT)   |    
40008dc8:	c2 07 40 00 	ld  [ %i5 ], %g1                               
40008dcc:	05 00 00 40 	sethi  %hi(0x10000), %g2                       
40008dd0:	83 28 60 18 	sll  %g1, 0x18, %g1                            
40008dd4:	82 10 40 02 	or  %g1, %g2, %g1                              
    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;                 
40008dd8:	e0 37 60 10 	sth  %l0, [ %i5 + 0x10 ]                       
         (( (Objects_Id) the_class ) << OBJECTS_CLASS_START_BIT) |    
40008ddc:	a0 10 40 10 	or  %g1, %l0, %l0                              
    information->maximum_id = _Objects_Build_id(                      
40008de0:	c2 17 60 04 	lduh  [ %i5 + 4 ], %g1                         
    }                                                                 
                                                                      
    _Thread_Disable_dispatch();                                       
    _ISR_Disable( level );                                            
                                                                      
    old_tables = information->object_blocks;                          
40008de4:	f4 07 60 34 	ld  [ %i5 + 0x34 ], %i2                        
40008de8:	83 28 60 1b 	sll  %g1, 0x1b, %g1                            
                                                                      
    information->object_blocks = object_blocks;                       
40008dec:	f2 27 60 34 	st  %i1, [ %i5 + 0x34 ]                        
  uint32_t         the_class,                                         
  uint32_t         node,                                              
  uint32_t         index                                              
)                                                                     
{                                                                     
  return (( (Objects_Id) the_api )   << OBJECTS_API_START_BIT)   |    
40008df0:	a0 14 00 01 	or  %l0, %g1, %l0                              
    information->inactive_per_block = inactive_per_block;             
40008df4:	e4 27 60 30 	st  %l2, [ %i5 + 0x30 ]                        
    information->local_table = local_table;                           
40008df8:	e2 27 60 1c 	st  %l1, [ %i5 + 0x1c ]                        
    information->maximum = (Objects_Maximum) maximum;                 
    information->maximum_id = _Objects_Build_id(                      
40008dfc:	e0 27 60 0c 	st  %l0, [ %i5 + 0xc ]                         
        information->the_class,                                       
        _Objects_Local_node,                                          
        information->maximum                                          
      );                                                              
                                                                      
    _ISR_Enable( level );                                             
40008e00:	7f ff e5 90 	call  40002440 <sparc_enable_interrupts>       
40008e04:	01 00 00 00 	nop                                            
    _Thread_Enable_dispatch();                                        
40008e08:	40 00 04 04 	call  40009e18 <_Thread_Enable_dispatch>       
40008e0c:	01 00 00 00 	nop                                            
                                                                      
    _Workspace_Free( old_tables );                                    
40008e10:	40 00 09 6b 	call  4000b3bc <_Workspace_Free>               
40008e14:	90 10 00 1a 	mov  %i2, %o0                                  
  }                                                                   
                                                                      
  /*                                                                  
   *  Assign the new object block to the object block table.          
   */                                                                 
  information->object_blocks[ block ] = new_object_block;             
40008e18:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
40008e1c:	b7 2e e0 02 	sll  %i3, 2, %i3                               
40008e20:	f0 20 40 1b 	st  %i0, [ %g1 + %i3 ]                         
                                                                      
  /*                                                                  
   *  Append to inactive chain.                                       
   */                                                                 
  the_object = information->object_blocks[ block ];                   
40008e24:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
40008e28:	07 00 00 40 	sethi  %hi(0x10000), %g3                       
40008e2c:	c2 00 40 1b 	ld  [ %g1 + %i3 ], %g1                         
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40008e30:	88 07 60 24 	add  %i5, 0x24, %g4                            
  for ( index = index_base ; index < index_end ; ++index ) {          
40008e34:	80 a7 00 14 	cmp  %i4, %l4                                  
40008e38:	3a 80 00 13 	bcc,a   40008e84 <_Objects_Extend_information+0x2c8>
40008e3c:	c4 07 60 30 	ld  [ %i5 + 0x30 ], %g2                        
40008e40:	f4 07 40 00 	ld  [ %i5 ], %i2                               
    the_object->id = _Objects_Build_id(                               
40008e44:	c4 17 60 04 	lduh  [ %i5 + 4 ], %g2                         
40008e48:	b5 2e a0 18 	sll  %i2, 0x18, %i2                            
         (( (Objects_Id) the_class ) << OBJECTS_CLASS_START_BIT) |    
40008e4c:	85 28 a0 1b 	sll  %g2, 0x1b, %g2                            
  uint32_t         the_class,                                         
  uint32_t         node,                                              
  uint32_t         index                                              
)                                                                     
{                                                                     
  return (( (Objects_Id) the_api )   << OBJECTS_API_START_BIT)   |    
40008e50:	b4 16 80 03 	or  %i2, %g3, %i2                              
         (( (Objects_Id) the_class ) << OBJECTS_CLASS_START_BIT) |    
40008e54:	84 16 80 02 	or  %i2, %g2, %g2                              
  uint32_t         the_class,                                         
  uint32_t         node,                                              
  uint32_t         index                                              
)                                                                     
{                                                                     
  return (( (Objects_Id) the_api )   << OBJECTS_API_START_BIT)   |    
40008e58:	84 10 80 1c 	or  %g2, %i4, %g2                              
40008e5c:	c4 20 60 08 	st  %g2, [ %g1 + 8 ]                           
  Chain_Node *old_last = tail->previous;                              
40008e60:	c4 07 60 28 	ld  [ %i5 + 0x28 ], %g2                        
                                                                      
  the_node->next = tail;                                              
40008e64:	c8 20 40 00 	st  %g4, [ %g1 ]                               
  tail->previous = the_node;                                          
40008e68:	c2 27 60 28 	st  %g1, [ %i5 + 0x28 ]                        
  old_last->next = the_node;                                          
40008e6c:	c2 20 80 00 	st  %g1, [ %g2 ]                               
  the_node->previous = old_last;                                      
40008e70:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
      index                                                           
    );                                                                
                                                                      
    _Chain_Append_unprotected( &information->Inactive, &the_object->Node );
                                                                      
    the_object = (Objects_Control *)                                  
40008e74:	c4 07 60 18 	ld  [ %i5 + 0x18 ], %g2                        
                                                                      
  /*                                                                  
   *  Append to inactive chain.                                       
   */                                                                 
  the_object = information->object_blocks[ block ];                   
  for ( index = index_base ; index < index_end ; ++index ) {          
40008e78:	b8 07 20 01 	inc  %i4                                       
      index                                                           
    );                                                                
                                                                      
    _Chain_Append_unprotected( &information->Inactive, &the_object->Node );
                                                                      
    the_object = (Objects_Control *)                                  
40008e7c:	10 bf ff ee 	b  40008e34 <_Objects_Extend_information+0x278>
40008e80:	82 00 40 02 	add  %g1, %g2, %g1                             
      ( (char *) the_object + information->size );                    
  }                                                                   
                                                                      
  information->inactive_per_block[ block ] = information->allocation_size;
40008e84:	c2 17 60 14 	lduh  [ %i5 + 0x14 ], %g1                      
40008e88:	c2 20 80 1b 	st  %g1, [ %g2 + %i3 ]                         
  information->inactive =                                             
    (Objects_Maximum)(information->inactive + information->allocation_size);
40008e8c:	c4 17 60 2c 	lduh  [ %i5 + 0x2c ], %g2                      
40008e90:	82 00 80 01 	add  %g2, %g1, %g1                             
    the_object = (Objects_Control *)                                  
      ( (char *) the_object + information->size );                    
  }                                                                   
                                                                      
  information->inactive_per_block[ block ] = information->allocation_size;
  information->inactive =                                             
40008e94:	c2 37 60 2c 	sth  %g1, [ %i5 + 0x2c ]                       
40008e98:	81 c7 e0 08 	ret                                            
40008e9c:	81 e8 00 00 	restore                                        
                                                                      

40008f60 <_Objects_Get_information>: Objects_Information *_Objects_Get_information( Objects_APIs the_api, uint16_t the_class ) {
40008f60:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Objects_Information *info;                                          
  int the_class_api_maximum;                                          
                                                                      
  if ( !the_class )                                                   
40008f64:	80 a6 60 00 	cmp  %i1, 0                                    
40008f68:	12 80 00 04 	bne  40008f78 <_Objects_Get_information+0x18>  
40008f6c:	01 00 00 00 	nop                                            
    return NULL;                                                      
40008f70:	81 c7 e0 08 	ret                                            
40008f74:	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 );      
40008f78:	40 00 12 2b 	call  4000d824 <_Objects_API_maximum_class>    
40008f7c:	90 10 00 18 	mov  %i0, %o0                                  
  if ( the_class_api_maximum == 0 )                                   
40008f80:	80 a2 20 00 	cmp  %o0, 0                                    
40008f84:	02 bf ff fb 	be  40008f70 <_Objects_Get_information+0x10>   
40008f88:	80 a6 40 08 	cmp  %i1, %o0                                  
    return NULL;                                                      
                                                                      
  if ( the_class > (uint32_t) the_class_api_maximum )                 
40008f8c:	18 bf ff f9 	bgu  40008f70 <_Objects_Get_information+0x10>  
40008f90:	03 10 00 61 	sethi  %hi(0x40018400), %g1                    
    return NULL;                                                      
                                                                      
  if ( !_Objects_Information_table[ the_api ] )                       
40008f94:	b1 2e 20 02 	sll  %i0, 2, %i0                               
40008f98:	82 10 60 20 	or  %g1, 0x20, %g1                             
40008f9c:	c2 00 40 18 	ld  [ %g1 + %i0 ], %g1                         
40008fa0:	80 a0 60 00 	cmp  %g1, 0                                    
40008fa4:	02 bf ff f3 	be  40008f70 <_Objects_Get_information+0x10>   <== NEVER TAKEN
40008fa8:	b3 2e 60 02 	sll  %i1, 2, %i1                               
    return NULL;                                                      
                                                                      
  info = _Objects_Information_table[ the_api ][ the_class ];          
40008fac:	f0 00 40 19 	ld  [ %g1 + %i1 ], %i0                         
  if ( !info )                                                        
40008fb0:	80 a6 20 00 	cmp  %i0, 0                                    
40008fb4:	02 bf ff ef 	be  40008f70 <_Objects_Get_information+0x10>   <== NEVER TAKEN
40008fb8:	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 )                                         
40008fbc:	c2 16 20 10 	lduh  [ %i0 + 0x10 ], %g1                      
40008fc0:	80 a0 60 00 	cmp  %g1, 0                                    
40008fc4:	02 bf ff eb 	be  40008f70 <_Objects_Get_information+0x10>   
40008fc8:	01 00 00 00 	nop                                            
      return NULL;                                                    
  #endif                                                              
                                                                      
  return info;                                                        
}                                                                     
40008fcc:	81 c7 e0 08 	ret                                            
40008fd0:	81 e8 00 00 	restore                                        
                                                                      

4000cc1c <_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;
4000cc1c:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           
4000cc20:	92 22 40 01 	sub  %o1, %g1, %o1                             
                                                                      
  if ( information->maximum >= index ) {                              
4000cc24:	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;                           
4000cc28:	92 02 60 01 	inc  %o1                                       
                                                                      
  if ( information->maximum >= index ) {                              
4000cc2c:	80 a0 40 09 	cmp  %g1, %o1                                  
4000cc30:	0a 80 00 09 	bcs  4000cc54 <_Objects_Get_no_protection+0x38>
4000cc34:	93 2a 60 02 	sll  %o1, 2, %o1                               
    if ( (the_object = information->local_table[ index ]) != NULL ) { 
4000cc38:	c2 02 20 1c 	ld  [ %o0 + 0x1c ], %g1                        
4000cc3c:	d0 00 40 09 	ld  [ %g1 + %o1 ], %o0                         
4000cc40:	80 a2 20 00 	cmp  %o0, 0                                    
4000cc44:	02 80 00 05 	be  4000cc58 <_Objects_Get_no_protection+0x3c> <== NEVER TAKEN
4000cc48:	82 10 20 01 	mov  1, %g1                                    
      *location = OBJECTS_LOCAL;                                      
      return the_object;                                              
4000cc4c:	81 c3 e0 08 	retl                                           
4000cc50:	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;                                          
4000cc54:	82 10 20 01 	mov  1, %g1                                    
  return NULL;                                                        
4000cc58:	90 10 20 00 	clr  %o0                                       
}                                                                     
4000cc5c:	81 c3 e0 08 	retl                                           
4000cc60:	c2 22 80 00 	st  %g1, [ %o2 ]                               
                                                                      

4000d3b0 <_Objects_Id_to_name>: Objects_Name_or_id_lookup_errors _Objects_Id_to_name ( Objects_Id id, Objects_Name *name ) {
4000d3b0:	9d e3 bf 98 	save  %sp, -104, %sp                           
                                                                      
  /*                                                                  
   *  Caller is trusted for name != NULL.                             
   */                                                                 
                                                                      
  tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Get_executing()->Object.id : id;
4000d3b4:	80 a6 20 00 	cmp  %i0, 0                                    
4000d3b8:	12 80 00 05 	bne  4000d3cc <_Objects_Id_to_name+0x1c>       
4000d3bc:	83 36 20 18 	srl  %i0, 0x18, %g1                            
4000d3c0:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
4000d3c4:	f0 00 60 08 	ld  [ %g1 + 8 ], %i0                           
4000d3c8:	83 36 20 18 	srl  %i0, 0x18, %g1                            
4000d3cc:	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 )                      
4000d3d0:	84 00 7f ff 	add  %g1, -1, %g2                              
4000d3d4:	80 a0 a0 02 	cmp  %g2, 2                                    
4000d3d8:	08 80 00 04 	bleu  4000d3e8 <_Objects_Id_to_name+0x38>      
4000d3dc:	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;                                        
4000d3e0:	81 c7 e0 08 	ret                                            
4000d3e4:	91 e8 20 03 	restore  %g0, 3, %o0                           
                                                                      
  if ( !_Objects_Information_table[ the_api ] )                       
4000d3e8:	05 10 00 c0 	sethi  %hi(0x40030000), %g2                    
4000d3ec:	84 10 a3 60 	or  %g2, 0x360, %g2	! 40030360 <_Objects_Information_table>
4000d3f0:	c2 00 80 01 	ld  [ %g2 + %g1 ], %g1                         
4000d3f4:	80 a0 60 00 	cmp  %g1, 0                                    
4000d3f8:	02 bf ff fa 	be  4000d3e0 <_Objects_Id_to_name+0x30>        
4000d3fc:	85 36 20 1b 	srl  %i0, 0x1b, %g2                            
    return OBJECTS_INVALID_ID;                                        
                                                                      
  the_class = _Objects_Get_class( tmpId );                            
                                                                      
  information = _Objects_Information_table[ the_api ][ the_class ];   
4000d400:	85 28 a0 02 	sll  %g2, 2, %g2                               
4000d404:	d0 00 40 02 	ld  [ %g1 + %g2 ], %o0                         
  if ( !information )                                                 
4000d408:	80 a2 20 00 	cmp  %o0, 0                                    
4000d40c:	02 bf ff f5 	be  4000d3e0 <_Objects_Id_to_name+0x30>        <== NEVER TAKEN
4000d410:	01 00 00 00 	nop                                            
    return OBJECTS_INVALID_ID;                                        
                                                                      
  #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)                 
    if ( information->is_string )                                     
4000d414:	c2 0a 20 38 	ldub  [ %o0 + 0x38 ], %g1                      
4000d418:	80 a0 60 00 	cmp  %g1, 0                                    
4000d41c:	12 bf ff f1 	bne  4000d3e0 <_Objects_Id_to_name+0x30>       <== NEVER TAKEN
4000d420:	92 10 00 18 	mov  %i0, %o1                                  
      return OBJECTS_INVALID_ID;                                      
  #endif                                                              
                                                                      
  the_object = _Objects_Get( information, tmpId, &ignored_location ); 
4000d424:	7f ff ff c8 	call  4000d344 <_Objects_Get>                  
4000d428:	94 07 bf fc 	add  %fp, -4, %o2                              
  if ( !the_object )                                                  
4000d42c:	80 a2 20 00 	cmp  %o0, 0                                    
4000d430:	02 bf ff ec 	be  4000d3e0 <_Objects_Id_to_name+0x30>        
4000d434:	01 00 00 00 	nop                                            
    return OBJECTS_INVALID_ID;                                        
                                                                      
  *name = the_object->name;                                           
4000d438:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
  _Objects_Put( the_object );                                         
  return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;                        
4000d43c:	b0 10 20 00 	clr  %i0                                       
RTEMS_INLINE_ROUTINE void _Objects_Put(                               
  Objects_Control *the_object                                         
)                                                                     
{                                                                     
  (void) the_object;                                                  
  _Thread_Enable_dispatch();                                          
4000d440:	40 00 03 5f 	call  4000e1bc <_Thread_Enable_dispatch>       
4000d444:	c2 26 40 00 	st  %g1, [ %i1 ]                               
4000d448:	81 c7 e0 08 	ret                                            
4000d44c:	81 e8 00 00 	restore                                        
                                                                      

4000792c <_POSIX_Keys_Free_memory>: #include <rtems/score/chainimpl.h> void _POSIX_Keys_Free_memory( POSIX_Keys_Control *the_key ) {
4000792c:	9d e3 bf 78 	save  %sp, -136, %sp                           
  POSIX_Keys_Key_value_pair search_node;                              
  POSIX_Keys_Key_value_pair *p;                                       
  RBTree_Node *iter, *next;                                           
  Objects_Id key_id;                                                  
                                                                      
  key_id = the_key->Object.id;                                        
40007930:	f6 06 20 08 	ld  [ %i0 + 8 ], %i3                           
  search_node.key = key_id;                                           
  search_node.thread_id = 0;                                          
  iter = _RBTree_Find( &_POSIX_Keys_Key_value_lookup_tree, &search_node.Key_value_lookup_node );
40007934:	39 10 00 65 	sethi  %hi(0x40019400), %i4                    
  POSIX_Keys_Key_value_pair *p;                                       
  RBTree_Node *iter, *next;                                           
  Objects_Id key_id;                                                  
                                                                      
  key_id = the_key->Object.id;                                        
  search_node.key = key_id;                                           
40007938:	f6 27 bf f4 	st  %i3, [ %fp + -12 ]                         
  search_node.thread_id = 0;                                          
4000793c:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
  iter = _RBTree_Find( &_POSIX_Keys_Key_value_lookup_tree, &search_node.Key_value_lookup_node );
40007940:	90 17 22 a8 	or  %i4, 0x2a8, %o0                            
40007944:	92 07 bf e4 	add  %fp, -28, %o1                             
40007948:	40 00 0a 7e 	call  4000a340 <_RBTree_Find>                  
4000794c:	b2 10 00 1c 	mov  %i4, %i1                                  
  if ( !iter )                                                        
40007950:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40007954:	02 80 00 2d 	be  40007a08 <_POSIX_Keys_Free_memory+0xdc>    
40007958:	01 00 00 00 	nop                                            
    return;                                                           
  /**                                                                 
   * find the smallest thread_id node in the rbtree.                  
   */                                                                 
  next = _RBTree_Next( iter, RBT_LEFT );                              
4000795c:	40 00 0b 38 	call  4000a63c <_RBTree_Next>                  
40007960:	92 10 20 00 	clr  %o1	! 0 <_TLS_BSS_size>                   
40007964:	b8 10 00 08 	mov  %o0, %i4                                  
  p = _RBTree_Container_of( next, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
40007968:	82 02 3f f8 	add  %o0, -8, %g1                              
  while ( next != NULL && p->key == key_id) {                         
4000796c:	80 a7 20 00 	cmp  %i4, 0                                    
40007970:	32 80 00 07 	bne,a   4000798c <_POSIX_Keys_Free_memory+0x60>
40007974:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
                                                                      
RTEMS_INLINE_ROUTINE void _POSIX_Keys_Key_value_pair_free(            
  POSIX_Keys_Key_value_pair *key_value_pair                           
)                                                                     
{                                                                     
  _Freechain_Put( &_POSIX_Keys_Keypool, key_value_pair );             
40007978:	31 10 00 65 	sethi  %hi(0x40019400), %i0                    
  }                                                                   
                                                                      
  /**                                                                 
   * delete all nodes belongs to the_key from the rbtree and chain.   
   */                                                                 
  p = _RBTree_Container_of( iter, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
4000797c:	b8 07 7f f8 	add  %i5, -8, %i4                              
  while ( iter != NULL && p->key == key_id ) {                        
    next = _RBTree_Next( iter, RBT_RIGHT );                           
    _RBTree_Extract( &_POSIX_Keys_Key_value_lookup_tree, iter );      
40007980:	b2 16 62 a8 	or  %i1, 0x2a8, %i1                            
40007984:	10 80 00 1d 	b  400079f8 <_POSIX_Keys_Free_memory+0xcc>     
40007988:	b0 16 22 64 	or  %i0, 0x264, %i0                            
  /**                                                                 
   * find the smallest thread_id node in the rbtree.                  
   */                                                                 
  next = _RBTree_Next( iter, RBT_LEFT );                              
  p = _RBTree_Container_of( next, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
  while ( next != NULL && p->key == key_id) {                         
4000798c:	80 a0 40 1b 	cmp  %g1, %i3                                  
40007990:	12 bf ff fb 	bne  4000797c <_POSIX_Keys_Free_memory+0x50>   <== NEVER TAKEN
40007994:	31 10 00 65 	sethi  %hi(0x40019400), %i0                    
    iter = next;                                                      
    next = _RBTree_Next( iter, RBT_LEFT );                            
40007998:	90 10 00 1c 	mov  %i4, %o0                                  
4000799c:	92 10 20 00 	clr  %o1                                       
400079a0:	40 00 0b 27 	call  4000a63c <_RBTree_Next>                  
400079a4:	ba 10 00 1c 	mov  %i4, %i5                                  
    p = _RBTree_Container_of( next, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
400079a8:	82 02 3f f8 	add  %o0, -8, %g1                              
   */                                                                 
  next = _RBTree_Next( iter, RBT_LEFT );                              
  p = _RBTree_Container_of( next, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
  while ( next != NULL && p->key == key_id) {                         
    iter = next;                                                      
    next = _RBTree_Next( iter, RBT_LEFT );                            
400079ac:	10 bf ff f0 	b  4000796c <_POSIX_Keys_Free_memory+0x40>     
400079b0:	b8 10 00 08 	mov  %o0, %i4                                  
  /**                                                                 
   * delete all nodes belongs to the_key from the rbtree and chain.   
   */                                                                 
  p = _RBTree_Container_of( iter, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
  while ( iter != NULL && p->key == key_id ) {                        
    next = _RBTree_Next( iter, RBT_RIGHT );                           
400079b4:	40 00 0b 22 	call  4000a63c <_RBTree_Next>                  
400079b8:	90 10 00 1d 	mov  %i5, %o0                                  
    _RBTree_Extract( &_POSIX_Keys_Key_value_lookup_tree, iter );      
400079bc:	92 10 00 1d 	mov  %i5, %o1                                  
  /**                                                                 
   * delete all nodes belongs to the_key from the rbtree and chain.   
   */                                                                 
  p = _RBTree_Container_of( iter, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
  while ( iter != NULL && p->key == key_id ) {                        
    next = _RBTree_Next( iter, RBT_RIGHT );                           
400079c0:	b4 10 00 08 	mov  %o0, %i2                                  
    _RBTree_Extract( &_POSIX_Keys_Key_value_lookup_tree, iter );      
400079c4:	40 00 09 f3 	call  4000a190 <_RBTree_Extract>               
400079c8:	90 10 00 19 	mov  %i1, %o0                                  
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
400079cc:	c4 07 00 00 	ld  [ %i4 ], %g2                               
  previous       = the_node->previous;                                
400079d0:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
400079d4:	92 10 00 1c 	mov  %i4, %o1                                  
  next->previous = previous;                                          
400079d8:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
400079dc:	c4 20 40 00 	st  %g2, [ %g1 ]                               
400079e0:	40 00 05 fa 	call  400091c8 <_Freechain_Put>                
400079e4:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  /**                                                                 
   * delete all nodes belongs to the_key from the rbtree and chain.   
   */                                                                 
  p = _RBTree_Container_of( iter, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
  while ( iter != NULL && p->key == key_id ) {                        
400079e8:	80 a6 a0 00 	cmp  %i2, 0                                    
400079ec:	02 80 00 07 	be  40007a08 <_POSIX_Keys_Free_memory+0xdc>    
400079f0:	b8 06 bf f8 	add  %i2, -8, %i4                              
    next = _RBTree_Next( iter, RBT_RIGHT );                           
    _RBTree_Extract( &_POSIX_Keys_Key_value_lookup_tree, iter );      
    _Chain_Extract_unprotected( &p->Key_values_per_thread_node );     
    _POSIX_Keys_Key_value_pair_free( p );                             
                                                                      
    iter = next;                                                      
400079f4:	ba 10 00 1a 	mov  %i2, %i5                                  
                                                                      
  /**                                                                 
   * delete all nodes belongs to the_key from the rbtree and chain.   
   */                                                                 
  p = _RBTree_Container_of( iter, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
  while ( iter != NULL && p->key == key_id ) {                        
400079f8:	c2 07 20 18 	ld  [ %i4 + 0x18 ], %g1                        
400079fc:	80 a0 40 1b 	cmp  %g1, %i3                                  
40007a00:	02 bf ff ed 	be  400079b4 <_POSIX_Keys_Free_memory+0x88>    
40007a04:	92 10 20 01 	mov  1, %o1                                    
40007a08:	81 c7 e0 08 	ret                                            
40007a0c:	81 e8 00 00 	restore                                        
                                                                      

4000c774 <_POSIX_Keys_Key_value_lookup_tree_compare_function>: int diff; n1 = _RBTree_Container_of( node1, POSIX_Keys_Key_value_pair, Key_value_lookup_node ); n2 = _RBTree_Container_of( node2, POSIX_Keys_Key_value_pair, Key_value_lookup_node ); diff = n1->key - n2->key;
4000c774:	c4 02 60 10 	ld  [ %o1 + 0x10 ], %g2                        
  POSIX_Keys_Key_value_pair *n1;                                      
  POSIX_Keys_Key_value_pair *n2;                                      
  Objects_Id thread_id1, thread_id2;                                  
  int diff;                                                           
                                                                      
  n1 = _RBTree_Container_of( node1, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
4000c778:	82 02 3f f8 	add  %o0, -8, %g1                              
  n2 = _RBTree_Container_of( node2, POSIX_Keys_Key_value_pair, Key_value_lookup_node );
                                                                      
  diff = n1->key - n2->key;                                           
4000c77c:	d0 02 20 10 	ld  [ %o0 + 0x10 ], %o0                        
  if ( diff )                                                         
4000c780:	90 a2 00 02 	subcc  %o0, %g2, %o0                           
4000c784:	12 80 00 0c 	bne  4000c7b4 <_POSIX_Keys_Key_value_lookup_tree_compare_function+0x40>
4000c788:	92 02 7f f8 	add  %o1, -8, %o1                              
    return diff;                                                      
                                                                      
  thread_id1 = n1->thread_id;                                         
4000c78c:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
  thread_id2 = n2->thread_id;                                         
4000c790:	c2 02 60 1c 	ld  [ %o1 + 0x1c ], %g1                        
                                                                      
  /**                                                                 
   * if thread_id1 or thread_id2 equals to 0, only key1 and key2 is valued.
   * it enables us search node only by pthread_key_t type key.        
   */                                                                 
  if ( thread_id1 && thread_id2 )                                     
4000c794:	80 a0 60 00 	cmp  %g1, 0                                    
4000c798:	02 80 00 06 	be  4000c7b0 <_POSIX_Keys_Key_value_lookup_tree_compare_function+0x3c><== NEVER TAKEN
4000c79c:	80 a2 20 00 	cmp  %o0, 0                                    
4000c7a0:	22 80 00 05 	be,a   4000c7b4 <_POSIX_Keys_Key_value_lookup_tree_compare_function+0x40>
4000c7a4:	90 10 20 00 	clr  %o0                                       
    return thread_id1 - thread_id2;                                   
4000c7a8:	81 c3 e0 08 	retl                                           
4000c7ac:	90 22 00 01 	sub  %o0, %g1, %o0                             
  return 0;                                                           
4000c7b0:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
}                                                                     
4000c7b4:	81 c3 e0 08 	retl                                           
                                                                      

4000c7bc <_POSIX_Keys_Keypool_extend>: return _Objects_Maximum_per_allocation( max ); } static bool _POSIX_Keys_Keypool_extend( Freechain_Control *keypool ) {
4000c7bc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  return 0;                                                           
}                                                                     
                                                                      
static uint32_t _POSIX_Keys_Get_keypool_bump_count( void )            
{                                                                     
  uint32_t max = Configuration.maximum_key_value_pairs;               
4000c7c0:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
4000c7c4:	c2 00 61 98 	ld  [ %g1 + 0x198 ], %g1	! 40015598 <Configuration+0x10>
                                                                      
  return _Objects_Is_unlimited( max ) ?                               
4000c7c8:	80 a0 60 00 	cmp  %g1, 0                                    
4000c7cc:	36 80 00 14 	bge,a   4000c81c <_POSIX_Keys_Keypool_extend+0x60><== NEVER TAKEN
4000c7d0:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
4000c7d4:	3b 00 00 3f 	sethi  %hi(0xfc00), %i5                        
4000c7d8:	ba 17 63 ff 	or  %i5, 0x3ff, %i5	! ffff <_TLS_Alignment+0xfffe>
static bool _POSIX_Keys_Keypool_extend( Freechain_Control *keypool )  
{                                                                     
  size_t bump_count = _POSIX_Keys_Get_keypool_bump_count();           
  bool ok = bump_count > 0;                                           
                                                                      
  if ( ok ) {                                                         
4000c7dc:	ba 88 40 1d 	andcc  %g1, %i5, %i5                           
4000c7e0:	12 80 00 04 	bne  4000c7f0 <_POSIX_Keys_Keypool_extend+0x34><== ALWAYS TAKEN
4000c7e4:	83 2f 60 05 	sll  %i5, 5, %g1                               
                                                                      
  return _Objects_Maximum_per_allocation( max );                      
}                                                                     
                                                                      
static bool _POSIX_Keys_Keypool_extend( Freechain_Control *keypool )  
{                                                                     
4000c7e8:	10 80 00 0d 	b  4000c81c <_POSIX_Keys_Keypool_extend+0x60>  <== NOT EXECUTED
4000c7ec:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
  size_t bump_count = _POSIX_Keys_Get_keypool_bump_count();           
  bool ok = bump_count > 0;                                           
                                                                      
  if ( ok ) {                                                         
    size_t size = bump_count * sizeof( POSIX_Keys_Key_value_pair );   
4000c7f0:	91 2f 60 02 	sll  %i5, 2, %o0                               
    POSIX_Keys_Key_value_pair *nodes = _Workspace_Allocate( size );   
4000c7f4:	7f ff fa e1 	call  4000b378 <_Workspace_Allocate>           
4000c7f8:	90 02 00 01 	add  %o0, %g1, %o0                             
                                                                      
    ok = nodes != NULL;                                               
                                                                      
    if ( ok ) {                                                       
4000c7fc:	92 92 20 00 	orcc  %o0, 0, %o1                              
4000c800:	22 80 00 07 	be,a   4000c81c <_POSIX_Keys_Keypool_extend+0x60><== NEVER TAKEN
4000c804:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
      _Chain_Initialize(                                              
4000c808:	90 10 00 18 	mov  %i0, %o0                                  
4000c80c:	94 10 00 1d 	mov  %i5, %o2                                  
4000c810:	96 10 20 24 	mov  0x24, %o3                                 
4000c814:	7f ff ee 3d 	call  40008108 <_Chain_Initialize>             
4000c818:	b0 10 20 01 	mov  1, %i0                                    
      );                                                              
    }                                                                 
  }                                                                   
                                                                      
  return ok;                                                          
}                                                                     
4000c81c:	b0 0e 20 01 	and  %i0, 1, %i0                               
4000c820:	81 c7 e0 08 	ret                                            
4000c824:	81 e8 00 00 	restore                                        
                                                                      

4000c9c8 <_POSIX_Message_queue_Receive_support>: size_t msg_len, unsigned int *msg_prio, bool wait, Watchdog_Interval timeout ) {
4000c9c8:	9d e3 bf 90 	save  %sp, -112, %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(             
4000c9cc:	11 10 00 a8 	sethi  %hi(0x4002a000), %o0                    
4000c9d0:	92 10 00 18 	mov  %i0, %o1                                  
4000c9d4:	90 12 23 40 	or  %o0, 0x340, %o0                            
4000c9d8:	40 00 0c c8 	call  4000fcf8 <_Objects_Get>                  
4000c9dc:	94 07 bf f8 	add  %fp, -8, %o2                              
  size_t                           length_out;                        
  bool                             do_wait;                           
  Thread_Control                  *executing;                         
                                                                      
  the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location );        
  switch ( location ) {                                               
4000c9e0:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000c9e4:	80 a0 60 00 	cmp  %g1, 0                                    
4000c9e8:	12 80 00 3c 	bne  4000cad8 <_POSIX_Message_queue_Receive_support+0x110>
4000c9ec:	01 00 00 00 	nop                                            
                                                                      
    case OBJECTS_LOCAL:                                               
      if ( (the_mq_fd->oflag & O_ACCMODE) == O_WRONLY ) {             
4000c9f0:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
4000c9f4:	84 08 60 03 	and  %g1, 3, %g2                               
4000c9f8:	80 a0 a0 01 	cmp  %g2, 1                                    
4000c9fc:	32 80 00 05 	bne,a   4000ca10 <_POSIX_Message_queue_Receive_support+0x48>
4000ca00:	d0 02 20 10 	ld  [ %o0 + 0x10 ], %o0                        
RTEMS_INLINE_ROUTINE void _Objects_Put(                               
  Objects_Control *the_object                                         
)                                                                     
{                                                                     
  (void) the_object;                                                  
  _Thread_Enable_dispatch();                                          
4000ca04:	40 00 10 33 	call  40010ad0 <_Thread_Enable_dispatch>       
4000ca08:	01 00 00 00 	nop                                            
4000ca0c:	30 80 00 33 	b,a   4000cad8 <_POSIX_Message_queue_Receive_support+0x110>
        rtems_set_errno_and_return_minus_one( EBADF );                
      }                                                               
                                                                      
      the_mq = the_mq_fd->Queue;                                      
                                                                      
      if ( msg_len < the_mq->Message_queue.maximum_message_size ) {   
4000ca10:	c4 02 20 68 	ld  [ %o0 + 0x68 ], %g2                        
4000ca14:	80 a6 80 02 	cmp  %i2, %g2                                  
4000ca18:	1a 80 00 08 	bcc  4000ca38 <_POSIX_Message_queue_Receive_support+0x70>
4000ca1c:	84 10 3f ff 	mov  -1, %g2                                   
4000ca20:	40 00 10 2c 	call  40010ad0 <_Thread_Enable_dispatch>       
4000ca24:	01 00 00 00 	nop                                            
        _Objects_Put( &the_mq_fd->Object );                           
        rtems_set_errno_and_return_minus_one( EMSGSIZE );             
4000ca28:	40 00 29 30 	call  40016ee8 <__errno>                       
4000ca2c:	01 00 00 00 	nop                                            
4000ca30:	10 80 00 2d 	b  4000cae4 <_POSIX_Message_queue_Receive_support+0x11c>
4000ca34:	82 10 20 7a 	mov  0x7a, %g1	! 7a <_TLS_Alignment+0x79>      
      length_out = -1;                                                
                                                                      
      /*                                                              
       *  A timed receive with a bad time will do a poll regardless.  
       */                                                             
      if ( wait )                                                     
4000ca38:	80 a7 20 00 	cmp  %i4, 0                                    
4000ca3c:	02 80 00 05 	be  4000ca50 <_POSIX_Message_queue_Receive_support+0x88>
4000ca40:	c4 27 bf fc 	st  %g2, [ %fp + -4 ]                          
        do_wait = (the_mq_fd->oflag & O_NONBLOCK) ? false : true;     
4000ca44:	b9 30 60 0e 	srl  %g1, 0xe, %i4                             
4000ca48:	b8 1f 20 01 	xor  %i4, 1, %i4                               
4000ca4c:	b8 0f 20 01 	and  %i4, 1, %i4                               
        do_wait = wait;                                               
                                                                      
      /*                                                              
       *  Now perform the actual message receive                      
       */                                                             
      executing = _Thread_Executing;                                  
4000ca50:	f4 01 a0 18 	ld  [ %g6 + 0x18 ], %i2                        
      _CORE_message_queue_Seize(                                      
4000ca54:	90 02 20 1c 	add  %o0, 0x1c, %o0                            
4000ca58:	92 10 00 1a 	mov  %i2, %o1                                  
4000ca5c:	94 10 00 18 	mov  %i0, %o2                                  
4000ca60:	96 10 00 19 	mov  %i1, %o3                                  
4000ca64:	98 07 bf fc 	add  %fp, -4, %o4                              
4000ca68:	9a 10 00 1c 	mov  %i4, %o5                                  
4000ca6c:	40 00 08 4e 	call  4000eba4 <_CORE_message_queue_Seize>     
4000ca70:	fa 23 a0 5c 	st  %i5, [ %sp + 0x5c ]                        
4000ca74:	40 00 10 17 	call  40010ad0 <_Thread_Enable_dispatch>       
4000ca78:	01 00 00 00 	nop                                            
        do_wait,                                                      
        timeout                                                       
      );                                                              
                                                                      
      _Objects_Put( &the_mq_fd->Object );                             
      if (msg_prio) {                                                 
4000ca7c:	80 a6 e0 00 	cmp  %i3, 0                                    
4000ca80:	22 80 00 08 	be,a   4000caa0 <_POSIX_Message_queue_Receive_support+0xd8><== NEVER TAKEN
4000ca84:	c2 06 a0 34 	ld  [ %i2 + 0x34 ], %g1                        <== NOT EXECUTED
RTEMS_INLINE_ROUTINE unsigned int _POSIX_Message_queue_Priority_from_core(
  CORE_message_queue_Submit_types priority                            
)                                                                     
{                                                                     
  /* absolute value without a library dependency */                   
  return (unsigned int) ((priority >= 0) ? priority : -priority);     
4000ca88:	c4 06 a0 24 	ld  [ %i2 + 0x24 ], %g2                        
4000ca8c:	83 38 a0 1f 	sra  %g2, 0x1f, %g1                            
4000ca90:	84 18 40 02 	xor  %g1, %g2, %g2                             
4000ca94:	82 20 80 01 	sub  %g2, %g1, %g1                             
        *msg_prio = _POSIX_Message_queue_Priority_from_core(          
4000ca98:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
             executing->Wait.count                                    
          );                                                          
      }                                                               
                                                                      
      if ( !executing->Wait.return_code )                             
4000ca9c:	c2 06 a0 34 	ld  [ %i2 + 0x34 ], %g1                        
4000caa0:	80 a0 60 00 	cmp  %g1, 0                                    
4000caa4:	12 80 00 05 	bne  4000cab8 <_POSIX_Message_queue_Receive_support+0xf0>
4000caa8:	01 00 00 00 	nop                                            
        return length_out;                                            
4000caac:	f0 07 bf fc 	ld  [ %fp + -4 ], %i0                          
4000cab0:	81 c7 e0 08 	ret                                            
4000cab4:	81 e8 00 00 	restore                                        
                                                                      
      rtems_set_errno_and_return_minus_one(                           
4000cab8:	40 00 29 0c 	call  40016ee8 <__errno>                       
4000cabc:	b0 10 3f ff 	mov  -1, %i0                                   
4000cac0:	ba 10 00 08 	mov  %o0, %i5                                  
4000cac4:	40 00 00 94 	call  4000cd14 <_POSIX_Message_queue_Translate_core_message_queue_return_code>
4000cac8:	d0 06 a0 34 	ld  [ %i2 + 0x34 ], %o0                        
4000cacc:	d0 27 40 00 	st  %o0, [ %i5 ]                               
4000cad0:	81 c7 e0 08 	ret                                            
4000cad4:	81 e8 00 00 	restore                                        
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  rtems_set_errno_and_return_minus_one( EBADF );                      
4000cad8:	40 00 29 04 	call  40016ee8 <__errno>                       
4000cadc:	01 00 00 00 	nop                                            
4000cae0:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
4000cae4:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000cae8:	b0 10 3f ff 	mov  -1, %i0                                   
}                                                                     
4000caec:	81 c7 e0 08 	ret                                            
4000caf0:	81 e8 00 00 	restore                                        
                                                                      

4000f6fc <_POSIX_Semaphore_Create_support>: size_t name_len, int pshared, unsigned int value, POSIX_Semaphore_Control **the_sem ) {
4000f6fc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  POSIX_Semaphore_Control   *the_semaphore;                           
  CORE_semaphore_Attributes *the_sem_attr;                            
  char                      *name;                                    
                                                                      
  /* Sharing semaphores among processes is not currently supported */ 
  if (pshared != 0)                                                   
4000f700:	80 a6 a0 00 	cmp  %i2, 0                                    
4000f704:	22 80 00 06 	be,a   4000f71c <_POSIX_Semaphore_Create_support+0x20>
4000f708:	21 10 00 78 	sethi  %hi(0x4001e000), %l0                    
    rtems_set_errno_and_return_minus_one( ENOSYS );                   
4000f70c:	40 00 0a c3 	call  40012218 <__errno>                       
4000f710:	01 00 00 00 	nop                                            
4000f714:	10 80 00 0b 	b  4000f740 <_POSIX_Semaphore_Create_support+0x44>
4000f718:	82 10 20 58 	mov  0x58, %g1	! 58 <_TLS_Alignment+0x57>      
void _POSIX_Semaphore_Manager_initialization(void);                   
                                                                      
RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *                        
  _POSIX_Semaphore_Allocate_unprotected( void )                       
{                                                                     
  return (POSIX_Semaphore_Control *)                                  
4000f71c:	90 14 22 e4 	or  %l0, 0x2e4, %o0                            
4000f720:	7f ff ee 77 	call  4000b0fc <_Objects_Allocate_unprotected> 
4000f724:	a2 10 00 10 	mov  %l0, %l1                                  
                                                                      
  the_semaphore = _POSIX_Semaphore_Allocate_unprotected();            
  if ( !the_semaphore ) {                                             
4000f728:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000f72c:	12 80 00 08 	bne  4000f74c <_POSIX_Semaphore_Create_support+0x50>
4000f730:	80 a6 20 00 	cmp  %i0, 0                                    
    rtems_set_errno_and_return_minus_one( ENOSPC );                   
4000f734:	40 00 0a b9 	call  40012218 <__errno>                       
4000f738:	01 00 00 00 	nop                                            
4000f73c:	82 10 20 1c 	mov  0x1c, %g1	! 1c <_TLS_Alignment+0x1b>      
4000f740:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000f744:	81 c7 e0 08 	ret                                            
4000f748:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  /*                                                                  
   * Make a copy of the user's string for name just in case it was    
   * dynamically constructed.                                         
   */                                                                 
  if ( name_arg != NULL ) {                                           
4000f74c:	02 80 00 0e 	be  4000f784 <_POSIX_Semaphore_Create_support+0x88>
4000f750:	90 10 00 18 	mov  %i0, %o0                                  
    name = _Workspace_String_duplicate( name_arg, name_len );         
4000f754:	40 00 03 1f 	call  400103d0 <_Workspace_String_duplicate>   
4000f758:	92 10 00 19 	mov  %i1, %o1                                  
    if ( !name ) {                                                    
4000f75c:	b4 92 20 00 	orcc  %o0, 0, %i2                              
4000f760:	12 80 00 0b 	bne  4000f78c <_POSIX_Semaphore_Create_support+0x90><== ALWAYS TAKEN
4000f764:	80 a6 a0 00 	cmp  %i2, 0                                    
 */                                                                   
RTEMS_INLINE_ROUTINE void _POSIX_Semaphore_Free (                     
  POSIX_Semaphore_Control *the_semaphore                              
)                                                                     
{                                                                     
  _Objects_Free( &_POSIX_Semaphore_Information, &the_semaphore->Object );
4000f768:	90 14 22 e4 	or  %l0, 0x2e4, %o0                            <== NOT EXECUTED
4000f76c:	7f ff ef 5f 	call  4000b4e8 <_Objects_Free>                 <== NOT EXECUTED
4000f770:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
      _POSIX_Semaphore_Free( the_semaphore );                         
      rtems_set_errno_and_return_minus_one( ENOMEM );                 
4000f774:	40 00 0a a9 	call  40012218 <__errno>                       <== NOT EXECUTED
4000f778:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000f77c:	10 bf ff f1 	b  4000f740 <_POSIX_Semaphore_Create_support+0x44><== NOT EXECUTED
4000f780:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
    }                                                                 
  } else {                                                            
    name = NULL;                                                      
4000f784:	b4 10 20 00 	clr  %i2                                       
  }                                                                   
                                                                      
  the_semaphore->process_shared  = pshared;                           
                                                                      
  if ( name ) {                                                       
4000f788:	80 a6 a0 00 	cmp  %i2, 0                                    
4000f78c:	02 80 00 08 	be  4000f7ac <_POSIX_Semaphore_Create_support+0xb0>
4000f790:	c0 27 60 10 	clr  [ %i5 + 0x10 ]                            
    the_semaphore->named = true;                                      
4000f794:	82 10 20 01 	mov  1, %g1                                    
4000f798:	c2 2f 60 14 	stb  %g1, [ %i5 + 0x14 ]                       
    the_semaphore->open_count = 1;                                    
4000f79c:	82 10 20 01 	mov  1, %g1                                    
4000f7a0:	c2 27 60 18 	st  %g1, [ %i5 + 0x18 ]                        
4000f7a4:	10 80 00 05 	b  4000f7b8 <_POSIX_Semaphore_Create_support+0xbc>
4000f7a8:	c2 2f 60 15 	stb  %g1, [ %i5 + 0x15 ]                       
    the_semaphore->linked = true;                                     
  } else {                                                            
    the_semaphore->named = false;                                     
4000f7ac:	c0 2f 60 14 	clrb  [ %i5 + 0x14 ]                           
    the_semaphore->open_count = 0;                                    
4000f7b0:	c0 27 60 18 	clr  [ %i5 + 0x18 ]                            
    the_semaphore->linked = false;                                    
4000f7b4:	c0 2f 60 15 	clrb  [ %i5 + 0x15 ]                           
  the_sem_attr->discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;         
                                                                      
  /*                                                                  
   *  This effectively disables limit checking.                       
   */                                                                 
  the_sem_attr->maximum_count = 0xFFFFFFFF;                           
4000f7b8:	82 10 3f ff 	mov  -1, %g1                                   
   *  blocking tasks on this semaphore should be.  It could somehow   
   *  be derived from the current scheduling policy.  One             
   *  thing is certain, no matter what we decide, it won't be         
   *  the same as  all other POSIX implementations. :)                
   */                                                                 
  the_sem_attr->discipline = CORE_SEMAPHORE_DISCIPLINES_FIFO;         
4000f7bc:	c0 27 60 60 	clr  [ %i5 + 0x60 ]                            
                                                                      
  /*                                                                  
   *  This effectively disables limit checking.                       
   */                                                                 
  the_sem_attr->maximum_count = 0xFFFFFFFF;                           
4000f7c0:	c2 27 60 5c 	st  %g1, [ %i5 + 0x5c ]                        
                                                                      
  _CORE_semaphore_Initialize( &the_semaphore->Semaphore, the_sem_attr, value );
4000f7c4:	90 07 60 1c 	add  %i5, 0x1c, %o0                            
4000f7c8:	92 07 60 5c 	add  %i5, 0x5c, %o1                            
4000f7cc:	7f ff ec 6f 	call  4000a988 <_CORE_semaphore_Initialize>    
4000f7d0:	94 10 00 1b 	mov  %i3, %o2                                  
  #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)                 
    /* ASSERT: information->is_string */                              
    the_object->name.name_p = name;                                   
  #endif                                                              
                                                                      
  _Objects_Set_local_object(                                          
4000f7d4:	c2 17 60 0a 	lduh  [ %i5 + 0xa ], %g1                       
  const char          *name                                           
)                                                                     
{                                                                     
  #if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)                 
    /* ASSERT: information->is_string */                              
    the_object->name.name_p = name;                                   
4000f7d8:	f4 27 60 0c 	st  %i2, [ %i5 + 0xc ]                         
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open_string(                       
  Objects_Information *information,                                   
4000f7dc:	a2 14 62 e4 	or  %l1, 0x2e4, %l1                            
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
4000f7e0:	c4 04 60 1c 	ld  [ %l1 + 0x1c ], %g2                        
4000f7e4:	83 28 60 02 	sll  %g1, 2, %g1                               
4000f7e8:	fa 20 80 01 	st  %i5, [ %g2 + %g1 ]                         
    &_POSIX_Semaphore_Information,                                    
    &the_semaphore->Object,                                           
    name                                                              
  );                                                                  
                                                                      
  *the_sem = the_semaphore;                                           
4000f7ec:	fa 27 00 00 	st  %i5, [ %i4 ]                               
                                                                      
  return 0;                                                           
}                                                                     
4000f7f0:	81 c7 e0 08 	ret                                            
4000f7f4:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000c7b8 <_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 ];
4000c7b8:	c2 02 21 30 	ld  [ %o0 + 0x130 ], %g1                       
                                                                      
  if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
4000c7bc:	c4 00 60 f0 	ld  [ %g1 + 0xf0 ], %g2                        
4000c7c0:	80 a0 a0 00 	cmp  %g2, 0                                    
4000c7c4:	12 80 00 11 	bne  4000c808 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x50><== NEVER TAKEN
4000c7c8:	01 00 00 00 	nop                                            
4000c7cc:	c4 00 60 f4 	ld  [ %g1 + 0xf4 ], %g2                        
4000c7d0:	80 a0 a0 01 	cmp  %g2, 1                                    
4000c7d4:	12 80 00 0d 	bne  4000c808 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x50>
4000c7d8:	01 00 00 00 	nop                                            
       thread_support->cancelability_type == PTHREAD_CANCEL_ASYNCHRONOUS &&
4000c7dc:	c2 00 60 f8 	ld  [ %g1 + 0xf8 ], %g1                        
4000c7e0:	80 a0 60 00 	cmp  %g1, 0                                    
4000c7e4:	02 80 00 09 	be  4000c808 <_POSIX_Thread_Evaluate_cancellation_and_enable_dispatch+0x50>
4000c7e8:	01 00 00 00 	nop                                            
   *                                                                  
   * This routine decrements the thread dispatch level.               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4000c7ec:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
       thread_support->cancelation_requested ) {                      
    /* FIXME: This path is broken on SMP */                           
    _Thread_Unnest_dispatch();                                        
    /* FIXME: Cancelability state may change here */                  
    _POSIX_Thread_Exit( the_thread, PTHREAD_CANCELED );               
4000c7f0:	92 10 3f ff 	mov  -1, %o1                                   
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable( level );                                            
#endif                                                                
                                                                      
    --disable_level;                                                  
4000c7f4:	84 00 bf ff 	add  %g2, -1, %g2                              
    _Thread_Dispatch_disable_level = disable_level;                   
4000c7f8:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
4000c7fc:	82 13 c0 00 	mov  %o7, %g1                                  
4000c800:	40 00 01 f5 	call  4000cfd4 <_POSIX_Thread_Exit>            
4000c804:	9e 10 40 00 	mov  %g1, %o7                                  
4000c808:	82 13 c0 00 	mov  %o7, %g1                                  
4000c80c:	7f ff f5 a2 	call  40009e94 <_Thread_Enable_dispatch>       
4000c810:	9e 10 40 00 	mov  %g1, %o7                                  
                                                                      

4000d958 <_POSIX_Thread_Translate_sched_param>: int policy, struct sched_param *param, Thread_CPU_budget_algorithms *budget_algorithm, Thread_CPU_budget_algorithm_callout *budget_callout ) {
4000d958:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ( !_POSIX_Priority_Is_valid( param->sched_priority ) )           
4000d95c:	7f ff ff f4 	call  4000d92c <_POSIX_Priority_Is_valid>      
4000d960:	d0 06 40 00 	ld  [ %i1 ], %o0                               
4000d964:	80 a2 20 00 	cmp  %o0, 0                                    
4000d968:	32 80 00 04 	bne,a   4000d978 <_POSIX_Thread_Translate_sched_param+0x20><== ALWAYS TAKEN
4000d96c:	c0 26 80 00 	clr  [ %i2 ]                                   
    return EINVAL;                                                    
4000d970:	81 c7 e0 08 	ret                                            
4000d974:	91 e8 20 16 	restore  %g0, 0x16, %o0                        
                                                                      
  *budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;               
  *budget_callout = NULL;                                             
                                                                      
  if ( policy == SCHED_OTHER ) {                                      
4000d978:	80 a6 20 00 	cmp  %i0, 0                                    
4000d97c:	12 80 00 06 	bne  4000d994 <_POSIX_Thread_Translate_sched_param+0x3c>
4000d980:	c0 26 c0 00 	clr  [ %i3 ]                                   
    *budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;  
4000d984:	82 10 20 01 	mov  1, %g1                                    
4000d988:	c2 26 80 00 	st  %g1, [ %i2 ]                               
    return 0;                                                         
4000d98c:	81 c7 e0 08 	ret                                            
4000d990:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  if ( policy == SCHED_FIFO ) {                                       
4000d994:	80 a6 20 01 	cmp  %i0, 1                                    
4000d998:	02 80 00 29 	be  4000da3c <_POSIX_Thread_Translate_sched_param+0xe4>
4000d99c:	80 a6 20 02 	cmp  %i0, 2                                    
    *budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;             
    return 0;                                                         
  }                                                                   
                                                                      
  if ( policy == SCHED_RR ) {                                         
4000d9a0:	12 80 00 04 	bne  4000d9b0 <_POSIX_Thread_Translate_sched_param+0x58>
4000d9a4:	80 a6 20 04 	cmp  %i0, 4                                    
    *budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE;
4000d9a8:	10 80 00 25 	b  4000da3c <_POSIX_Thread_Translate_sched_param+0xe4>
4000d9ac:	f0 26 80 00 	st  %i0, [ %i2 ]                               
    return 0;                                                         
  }                                                                   
                                                                      
  if ( policy == SCHED_SPORADIC ) {                                   
4000d9b0:	12 bf ff f0 	bne  4000d970 <_POSIX_Thread_Translate_sched_param+0x18>
4000d9b4:	01 00 00 00 	nop                                            
    if ( (param->sched_ss_repl_period.tv_sec == 0) &&                 
4000d9b8:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4000d9bc:	80 a0 60 00 	cmp  %g1, 0                                    
4000d9c0:	32 80 00 07 	bne,a   4000d9dc <_POSIX_Thread_Translate_sched_param+0x84>
4000d9c4:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000d9c8:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
4000d9cc:	80 a0 60 00 	cmp  %g1, 0                                    
4000d9d0:	02 bf ff e8 	be  4000d970 <_POSIX_Thread_Translate_sched_param+0x18>
4000d9d4:	01 00 00 00 	nop                                            
         (param->sched_ss_repl_period.tv_nsec == 0) )                 
      return EINVAL;                                                  
                                                                      
    if ( (param->sched_ss_init_budget.tv_sec == 0) &&                 
4000d9d8:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000d9dc:	80 a0 60 00 	cmp  %g1, 0                                    
4000d9e0:	12 80 00 06 	bne  4000d9f8 <_POSIX_Thread_Translate_sched_param+0xa0>
4000d9e4:	01 00 00 00 	nop                                            
4000d9e8:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        
4000d9ec:	80 a0 60 00 	cmp  %g1, 0                                    
4000d9f0:	02 bf ff e0 	be  4000d970 <_POSIX_Thread_Translate_sched_param+0x18>
4000d9f4:	01 00 00 00 	nop                                            
         (param->sched_ss_init_budget.tv_nsec == 0) )                 
      return EINVAL;                                                  
                                                                      
    if ( _Timespec_To_ticks( ¶m->sched_ss_repl_period ) <         
4000d9f8:	7f ff f7 c8 	call  4000b918 <_Timespec_To_ticks>            
4000d9fc:	90 06 60 08 	add  %i1, 8, %o0                               
4000da00:	ba 10 00 08 	mov  %o0, %i5                                  
	 _Timespec_To_ticks( ¶m->sched_ss_init_budget ) )                
4000da04:	7f ff f7 c5 	call  4000b918 <_Timespec_To_ticks>            
4000da08:	90 06 60 10 	add  %i1, 0x10, %o0                            
                                                                      
    if ( (param->sched_ss_init_budget.tv_sec == 0) &&                 
         (param->sched_ss_init_budget.tv_nsec == 0) )                 
      return EINVAL;                                                  
                                                                      
    if ( _Timespec_To_ticks( ¶m->sched_ss_repl_period ) <         
4000da0c:	80 a7 40 08 	cmp  %i5, %o0                                  
4000da10:	0a bf ff d8 	bcs  4000d970 <_POSIX_Thread_Translate_sched_param+0x18>
4000da14:	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 ) )  
4000da18:	7f ff ff c5 	call  4000d92c <_POSIX_Priority_Is_valid>      
4000da1c:	d0 06 60 04 	ld  [ %i1 + 4 ], %o0                           
4000da20:	80 a2 20 00 	cmp  %o0, 0                                    
4000da24:	02 bf ff d3 	be  4000d970 <_POSIX_Thread_Translate_sched_param+0x18>
4000da28:	82 10 20 03 	mov  3, %g1                                    
      return EINVAL;                                                  
                                                                      
    *budget_algorithm  = THREAD_CPU_BUDGET_ALGORITHM_CALLOUT;         
4000da2c:	c2 26 80 00 	st  %g1, [ %i2 ]                               
    *budget_callout = _POSIX_Threads_Sporadic_budget_callout;         
4000da30:	03 10 00 1e 	sethi  %hi(0x40007800), %g1                    
4000da34:	82 10 62 d0 	or  %g1, 0x2d0, %g1	! 40007ad0 <_POSIX_Threads_Sporadic_budget_callout>
4000da38:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
    return 0;                                                         
  }                                                                   
                                                                      
  return EINVAL;                                                      
}                                                                     
4000da3c:	81 c7 e0 08 	ret                                            
4000da40:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40007840 <_POSIX_Threads_Initialize_user_threads_body>: #include <rtems/posix/priorityimpl.h> #include <rtems/posix/config.h> #include <rtems/posix/time.h> void _POSIX_Threads_Initialize_user_threads_body(void) {
40007840:	9d e3 bf 50 	save  %sp, -176, %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;
40007844:	03 10 00 7c 	sethi  %hi(0x4001f000), %g1                    
40007848:	82 10 61 1c 	or  %g1, 0x11c, %g1	! 4001f11c <Configuration_POSIX_API>
  maximum      = Configuration_POSIX_API.number_of_initialization_threads;
4000784c:	f6 00 60 2c 	ld  [ %g1 + 0x2c ], %i3                        
                                                                      
  if ( !user_threads || maximum == 0 )                                
40007850:	80 a6 e0 00 	cmp  %i3, 0                                    
40007854:	02 80 00 1b 	be  400078c0 <_POSIX_Threads_Initialize_user_threads_body+0x80><== NEVER TAKEN
40007858:	fa 00 60 30 	ld  [ %g1 + 0x30 ], %i5                        
4000785c:	80 a7 60 00 	cmp  %i5, 0                                    
40007860:	02 80 00 18 	be  400078c0 <_POSIX_Threads_Initialize_user_threads_body+0x80><== NEVER TAKEN
40007864:	b8 10 20 00 	clr  %i4                                       
                                                                      
  for ( index=0 ; index < maximum ; index++ ) {                       
    /*                                                                
     * There is no way for these calls to fail in this situation.     
     */                                                               
    eno = pthread_attr_init( &attr );                                 
40007868:	40 00 18 77 	call  4000da44 <pthread_attr_init>             
4000786c:	90 07 bf b4 	add  %fp, -76, %o0                             
    _Assert( eno == 0 );                                              
    eno = pthread_attr_setinheritsched( &attr, PTHREAD_EXPLICIT_SCHED );
40007870:	92 10 20 02 	mov  2, %o1                                    
40007874:	40 00 18 80 	call  4000da74 <pthread_attr_setinheritsched>  
40007878:	90 07 bf b4 	add  %fp, -76, %o0                             
    _Assert( eno == 0 );                                              
    eno = pthread_attr_setstacksize(&attr, user_threads[ index ].stack_size);
4000787c:	d2 07 60 04 	ld  [ %i5 + 4 ], %o1                           
40007880:	40 00 18 8c 	call  4000dab0 <pthread_attr_setstacksize>     
40007884:	90 07 bf b4 	add  %fp, -76, %o0                             
    _Assert( eno == 0 );                                              
                                                                      
    eno = pthread_create(                                             
40007888:	d4 07 40 00 	ld  [ %i5 ], %o2                               
4000788c:	92 07 bf b4 	add  %fp, -76, %o1                             
40007890:	90 07 bf b0 	add  %fp, -80, %o0                             
40007894:	7f ff ff 1f 	call  40007510 <pthread_create>                
40007898:	96 10 20 00 	clr  %o3                                       
      &thread_id,                                                     
      &attr,                                                          
      user_threads[ index ].thread_entry,                             
      NULL                                                            
    );                                                                
    if ( eno )                                                        
4000789c:	92 92 20 00 	orcc  %o0, 0, %o1                              
400078a0:	22 80 00 05 	be,a   400078b4 <_POSIX_Threads_Initialize_user_threads_body+0x74>
400078a4:	b8 07 20 01 	inc  %i4                                       
      _POSIX_Fatal_error( POSIX_FD_PTHREAD, eno );                    
400078a8:	40 00 04 5f 	call  40008a24 <_POSIX_Fatal_error>            
400078ac:	90 10 20 00 	clr  %o0                                       
   *                                                                  
   *  Setting the attributes explicitly is critical, since we don't want
   *  to inherit the idle tasks attributes.                           
   */                                                                 
                                                                      
  for ( index=0 ; index < maximum ; index++ ) {                       
400078b0:	b8 07 20 01 	inc  %i4                                       <== NOT EXECUTED
400078b4:	80 a7 00 1b 	cmp  %i4, %i3                                  
400078b8:	12 bf ff ec 	bne  40007868 <_POSIX_Threads_Initialize_user_threads_body+0x28><== NEVER TAKEN
400078bc:	ba 07 60 08 	add  %i5, 8, %i5                               
400078c0:	81 c7 e0 08 	ret                                            
400078c4:	81 e8 00 00 	restore                                        
                                                                      

4000cc10 <_POSIX_Threads_Sporadic_budget_TSR>: */ void _POSIX_Threads_Sporadic_budget_TSR( Objects_Id id __attribute__((unused)), void *argument ) {
4000cc10:	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 ];               
4000cc14:	fa 06 61 30 	ld  [ %i1 + 0x130 ], %i5                       
                                                                      
  /* ticks is guaranteed to be at least one */                        
  ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_init_budget );
4000cc18:	40 00 03 8c 	call  4000da48 <_Timespec_To_ticks>            
4000cc1c:	90 07 60 a4 	add  %i5, 0xa4, %o0                            
 */                                                                   
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(        
  int priority                                                        
)                                                                     
{                                                                     
  return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
4000cc20:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
4000cc24:	d2 08 62 a4 	ldub  [ %g1 + 0x2a4 ], %o1	! 40016aa4 <rtems_maximum_priority>
4000cc28:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        
                                                                      
  the_thread->cpu_time_budget = ticks;                                
4000cc2c:	d0 26 60 74 	st  %o0, [ %i1 + 0x74 ]                        
4000cc30:	92 22 40 01 	sub  %o1, %g1, %o1                             
   */                                                                 
  #if 0                                                               
    printk( "TSR %d %d %d\n", the_thread->resource_count,             
        the_thread->current_priority, new_priority );                 
  #endif                                                              
  if ( !_Thread_Owns_resources( the_thread ) ) {                      
4000cc34:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
4000cc38:	80 a0 60 00 	cmp  %g1, 0                                    
4000cc3c:	12 80 00 09 	bne  4000cc60 <_POSIX_Threads_Sporadic_budget_TSR+0x50><== NEVER TAKEN
4000cc40:	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 ) {              
4000cc44:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        
4000cc48:	80 a0 40 09 	cmp  %g1, %o1                                  
4000cc4c:	08 80 00 06 	bleu  4000cc64 <_POSIX_Threads_Sporadic_budget_TSR+0x54>
4000cc50:	90 07 60 9c 	add  %i5, 0x9c, %o0                            
      _Thread_Change_priority( the_thread, new_priority, true );      
4000cc54:	90 10 00 19 	mov  %i1, %o0                                  
4000cc58:	7f ff f3 83 	call  40009a64 <_Thread_Change_priority>       
4000cc5c:	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 );
4000cc60:	90 07 60 9c 	add  %i5, 0x9c, %o0                            
4000cc64:	40 00 03 79 	call  4000da48 <_Timespec_To_ticks>            
4000cc68:	31 10 00 61 	sethi  %hi(0x40018400), %i0                    
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
4000cc6c:	b0 16 20 b0 	or  %i0, 0xb0, %i0	! 400184b0 <_Watchdog_Ticks_chain>
  Watchdog_Control      *the_watchdog,                                
  Watchdog_Interval      units                                        
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
4000cc70:	d0 27 60 c0 	st  %o0, [ %i5 + 0xc0 ]                        
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
4000cc74:	7f ff f8 b4 	call  4000af44 <_Watchdog_Insert>              
4000cc78:	93 ef 60 b4 	restore  %i5, 0xb4, %o1                        
                                                                      

40007ad0 <_POSIX_Threads_Sporadic_budget_callout>: ) { POSIX_API_Control *api; uint32_t new_priority; api = the_thread->API_Extensions[ THREAD_API_POSIX ];
40007ad0:	c4 02 21 30 	ld  [ %o0 + 0x130 ], %g2                       
                                                                      
  /*                                                                  
   *  This will prevent the thread from consuming its entire "budget" 
   *  while at low priority.                                          
   */                                                                 
  the_thread->cpu_time_budget = UINT32_MAX;                           
40007ad4:	86 10 3f ff 	mov  -1, %g3                                   
 */                                                                   
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(        
  int priority                                                        
)                                                                     
{                                                                     
  return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
40007ad8:	c4 00 a0 98 	ld  [ %g2 + 0x98 ], %g2                        
40007adc:	c6 22 20 74 	st  %g3, [ %o0 + 0x74 ]                        
40007ae0:	07 10 00 7c 	sethi  %hi(0x4001f000), %g3                    
40007ae4:	d2 08 e1 14 	ldub  [ %g3 + 0x114 ], %o1	! 4001f114 <rtems_maximum_priority>
40007ae8:	92 22 40 02 	sub  %o1, %g2, %o1                             
   */                                                                 
  #if 0                                                               
    printk( "callout %d %d %d\n", the_thread->resource_count,         
	the_thread->current_priority, new_priority );                        
  #endif                                                              
  if ( !_Thread_Owns_resources( the_thread ) ) {                      
40007aec:	c4 02 20 1c 	ld  [ %o0 + 0x1c ], %g2                        
40007af0:	80 a0 a0 00 	cmp  %g2, 0                                    
40007af4:	12 80 00 09 	bne  40007b18 <_POSIX_Threads_Sporadic_budget_callout+0x48><== NEVER TAKEN
40007af8:	d2 22 20 18 	st  %o1, [ %o0 + 0x18 ]                        
    /*                                                                
     *  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 ) {              
40007afc:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
40007b00:	80 a0 40 09 	cmp  %g1, %o1                                  
40007b04:	1a 80 00 05 	bcc  40007b18 <_POSIX_Threads_Sporadic_budget_callout+0x48><== NEVER TAKEN
40007b08:	94 10 20 01 	mov  1, %o2                                    
      _Thread_Change_priority( the_thread, new_priority, true );      
40007b0c:	82 13 c0 00 	mov  %o7, %g1                                  
40007b10:	40 00 0a c8 	call  4000a630 <_Thread_Change_priority>       
40007b14:	9e 10 40 00 	mov  %g1, %o7                                  
40007b18:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
                                                                      

4000cc8c <_POSIX_Threads_Terminate_extension>: } static void _POSIX_Threads_Terminate_extension( Thread_Control *executing ) {
4000cc8c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Thread_Control     *the_thread;                                     
  POSIX_API_Control  *api;                                            
  void              **value_ptr;                                      
                                                                      
  api = executing->API_Extensions[ THREAD_API_POSIX ];                
4000cc90:	fa 06 21 30 	ld  [ %i0 + 0x130 ], %i5                       
                                                                      
  /*                                                                  
   *  Run the POSIX cancellation handlers                             
   */                                                                 
  _POSIX_Threads_cancel_run( executing );                             
4000cc94:	40 00 07 c0 	call  4000eb94 <_POSIX_Threads_cancel_run>     
4000cc98:	90 10 00 18 	mov  %i0, %o0                                  
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4000cc9c:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
4000cca0:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
4000cca4:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
  _Thread_Disable_dispatch();                                         
                                                                      
  /*                                                                  
   *  Wakeup all the tasks which joined with this one                 
   */                                                                 
  value_ptr = (void **) executing->Wait.return_argument;              
4000cca8:	f6 06 20 28 	ld  [ %i0 + 0x28 ], %i3                        
                                                                      
  while ( (the_thread = _Thread_queue_Dequeue( &api->Join_List )) )   
4000ccac:	b8 07 60 50 	add  %i5, 0x50, %i4                            
4000ccb0:	7f ff f5 3b 	call  4000a19c <_Thread_queue_Dequeue>         
4000ccb4:	90 10 00 1c 	mov  %i4, %o0                                  
4000ccb8:	80 a2 20 00 	cmp  %o0, 0                                    
4000ccbc:	22 80 00 05 	be,a   4000ccd0 <_POSIX_Threads_Terminate_extension+0x44><== ALWAYS TAKEN
4000ccc0:	c2 07 60 90 	ld  [ %i5 + 0x90 ], %g1                        
      *(void **)the_thread->Wait.return_argument = value_ptr;         
4000ccc4:	c2 02 20 28 	ld  [ %o0 + 0x28 ], %g1                        <== NOT EXECUTED
4000ccc8:	10 bf ff fa 	b  4000ccb0 <_POSIX_Threads_Terminate_extension+0x24><== NOT EXECUTED
4000cccc:	f6 20 40 00 	st  %i3, [ %g1 ]                               <== NOT EXECUTED
                                                                      
  if ( api->schedpolicy == SCHED_SPORADIC )                           
4000ccd0:	80 a0 60 04 	cmp  %g1, 4                                    
4000ccd4:	12 80 00 04 	bne  4000cce4 <_POSIX_Threads_Terminate_extension+0x58>
4000ccd8:	01 00 00 00 	nop                                            
    (void) _Watchdog_Remove( &api->Sporadic_timer );                  
4000ccdc:	7f ff f8 ef 	call  4000b098 <_Watchdog_Remove>              
4000cce0:	90 07 60 b4 	add  %i5, 0xb4, %o0                            
                                                                      
  _Thread_Enable_dispatch();                                          
4000cce4:	7f ff f4 4d 	call  40009e18 <_Thread_Enable_dispatch>       
4000cce8:	81 e8 00 00 	restore                                        
                                                                      

40007348 <_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) {
40007348:	9d e3 bf 98 	save  %sp, -104, %sp                           
  bool                 activated;                                     
                                                                      
  ptimer = (POSIX_Timer_Control *)data;                               
                                                                      
  /* Increment the number of expirations. */                          
  ptimer->overrun = ptimer->overrun + 1;                              
4000734c:	c2 06 60 68 	ld  [ %i1 + 0x68 ], %g1                        
40007350:	82 00 60 01 	inc  %g1                                       
40007354:	c2 26 60 68 	st  %g1, [ %i1 + 0x68 ]                        
                                                                      
  /* The timer must be reprogrammed */                                
  if ( ( ptimer->timer_data.it_interval.tv_sec  != 0 ) ||             
40007358:	c2 06 60 54 	ld  [ %i1 + 0x54 ], %g1                        
4000735c:	80 a0 60 00 	cmp  %g1, 0                                    
40007360:	32 80 00 07 	bne,a   4000737c <_POSIX_Timer_TSR+0x34>       
40007364:	d2 06 60 64 	ld  [ %i1 + 0x64 ], %o1                        
40007368:	c2 06 60 58 	ld  [ %i1 + 0x58 ], %g1                        
4000736c:	80 a0 60 00 	cmp  %g1, 0                                    
40007370:	02 80 00 1f 	be  400073ec <_POSIX_Timer_TSR+0xa4>           <== NEVER TAKEN
40007374:	82 10 20 04 	mov  4, %g1                                    
       ( ptimer->timer_data.it_interval.tv_nsec != 0 ) ) {            
    activated = _POSIX_Timer_Insert_helper(                           
40007378:	d2 06 60 64 	ld  [ %i1 + 0x64 ], %o1                        
4000737c:	d4 06 60 08 	ld  [ %i1 + 8 ], %o2                           
40007380:	90 06 60 10 	add  %i1, 0x10, %o0                            
40007384:	17 10 00 1c 	sethi  %hi(0x40007000), %o3                    
40007388:	98 10 00 19 	mov  %i1, %o4                                  
4000738c:	40 00 18 9c 	call  4000d5fc <_POSIX_Timer_Insert_helper>    
40007390:	96 12 e3 48 	or  %o3, 0x348, %o3                            
      ptimer->ticks,                                                  
      ptimer->Object.id,                                              
      _POSIX_Timer_TSR,                                               
      ptimer                                                          
    );                                                                
    if ( !activated )                                                 
40007394:	80 a2 20 00 	cmp  %o0, 0                                    
40007398:	02 80 00 1a 	be  40007400 <_POSIX_Timer_TSR+0xb8>           <== NEVER TAKEN
4000739c:	90 07 bf f8 	add  %fp, -8, %o0                              
                                                                      
  tod_as_timestamp_ptr =                                              
400073a0:	13 10 00 67 	sethi  %hi(0x40019c00), %o1                    
400073a4:	40 00 05 b7 	call  40008a80 <_TOD_Get_with_nanoseconds>     
400073a8:	92 12 61 40 	or  %o1, 0x140, %o1	! 40019d40 <_TOD>          
static inline void _TOD_Get(                                          
  struct timespec *tod_as_timespec                                    
)                                                                     
{                                                                     
  Timestamp_Control  tod_as_timestamp;                                
  Timestamp_Control *tod_as_timestamp_ptr;                            
400073ac:	f8 1a 00 00 	ldd  [ %o0 ], %i4                              
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
400073b0:	94 10 20 00 	clr  %o2                                       
400073b4:	90 10 00 1c 	mov  %i4, %o0                                  
400073b8:	92 10 00 1d 	mov  %i5, %o1                                  
400073bc:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
400073c0:	40 00 36 0e 	call  40014bf8 <__divdi3>                      
400073c4:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
400073c8:	90 10 00 1c 	mov  %i4, %o0                                  
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
400073cc:	d2 26 60 6c 	st  %o1, [ %i1 + 0x6c ]                        
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
400073d0:	94 10 20 00 	clr  %o2                                       
400073d4:	92 10 00 1d 	mov  %i5, %o1                                  
400073d8:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
400073dc:	40 00 36 f9 	call  40014fc0 <__moddi3>                      
400073e0:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
                                                                      
    /* Store the time when the timer was started again */             
    _TOD_Get( &ptimer->time );                                        
                                                                      
    /* The state really did not change but just to be safe */         
    ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;                     
400073e4:	82 10 20 03 	mov  3, %g1                                    
400073e8:	d2 26 60 70 	st  %o1, [ %i1 + 0x70 ]                        
  /*                                                                  
   * 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 ) ) {
400073ec:	d0 06 60 38 	ld  [ %i1 + 0x38 ], %o0                        
400073f0:	d2 06 60 44 	ld  [ %i1 + 0x44 ], %o1                        
400073f4:	40 00 17 97 	call  4000d250 <pthread_kill>                  
400073f8:	c2 2e 60 3c 	stb  %g1, [ %i1 + 0x3c ]                       
  }                                                                   
                                                                      
  /* After the signal handler returns, the count of expirations of the
   * timer must be set to 0.                                          
   */                                                                 
  ptimer->overrun = 0;                                                
400073fc:	c0 26 60 68 	clr  [ %i1 + 0x68 ]                            
40007400:	81 c7 e0 08 	ret                                            
40007404:	81 e8 00 00 	restore                                        
                                                                      

4000ca1c <_POSIX_signals_Action_handler>: Thread_Control *executing, Thread_Action *action, Per_CPU_Control *cpu, ISR_Level level ) {
4000ca1c:	9d e3 bf a0 	save  %sp, -96, %sp                            
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
4000ca20:	7f ff d6 88 	call  40002440 <sparc_enable_interrupts>       
4000ca24:	90 10 00 1b 	mov  %i3, %o0                                  
  int                 hold_errno;                                     
                                                                      
  (void) action;                                                      
  _Thread_Action_release_and_ISR_enable( cpu, level );                
                                                                      
  api = executing->API_Extensions[ THREAD_API_POSIX ];                
4000ca28:	fa 06 21 30 	ld  [ %i0 + 0x130 ], %i5                       
  hold_errno = executing->Wait.return_code;                           
                                                                      
  /*                                                                  
   * api may be NULL in case of a thread close in progress            
   */                                                                 
  if ( !api )                                                         
4000ca2c:	80 a7 60 00 	cmp  %i5, 0                                    
4000ca30:	02 80 00 0f 	be  4000ca6c <_POSIX_signals_Action_handler+0x50><== NEVER TAKEN
4000ca34:	f6 06 20 34 	ld  [ %i0 + 0x34 ], %i3                        
   *  processed at all.  No point in doing this loop otherwise.       
   */                                                                 
  while (1) {                                                         
    _POSIX_signals_Acquire( &lock_context );                          
      if ( !(~api->signals_blocked &                                  
            (api->signals_pending | _POSIX_signals_Pending)) ) {      
4000ca38:	35 10 00 63 	sethi  %hi(0x40018c00), %i2                    
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
4000ca3c:	7f ff d6 7e 	call  40002434 <sparc_disable_interrupts>      
4000ca40:	01 00 00 00 	nop                                            
4000ca44:	c4 06 a2 f4 	ld  [ %i2 + 0x2f4 ], %g2                       
4000ca48:	c2 07 60 e0 	ld  [ %i5 + 0xe0 ], %g1                        
4000ca4c:	82 10 80 01 	or  %g2, %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) {                                                         
    _POSIX_signals_Acquire( &lock_context );                          
      if ( !(~api->signals_blocked &                                  
4000ca50:	c4 07 60 dc 	ld  [ %i5 + 0xdc ], %g2                        
4000ca54:	80 a8 40 02 	andncc  %g1, %g2, %g0                          
4000ca58:	12 80 00 07 	bne  4000ca74 <_POSIX_signals_Action_handler+0x58>
4000ca5c:	01 00 00 00 	nop                                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
4000ca60:	7f ff d6 78 	call  40002440 <sparc_enable_interrupts>       
4000ca64:	01 00 00 00 	nop                                            
      _POSIX_signals_Check_signal( api, signo, false );               
      _POSIX_signals_Check_signal( api, signo, true );                
    }                                                                 
  }                                                                   
                                                                      
  executing->Wait.return_code = hold_errno;                           
4000ca68:	f6 26 20 34 	st  %i3, [ %i0 + 0x34 ]                        
4000ca6c:	81 c7 e0 08 	ret                                            
4000ca70:	81 e8 00 00 	restore                                        
4000ca74:	7f ff d6 73 	call  40002440 <sparc_enable_interrupts>       
4000ca78:	b8 10 20 1b 	mov  0x1b, %i4                                 
       break;                                                         
     }                                                                
    _POSIX_signals_Release( &lock_context );                          
                                                                      
    for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {          
      _POSIX_signals_Check_signal( api, signo, false );               
4000ca7c:	92 10 00 1c 	mov  %i4, %o1                                  
4000ca80:	94 10 20 00 	clr  %o2                                       
4000ca84:	40 00 08 83 	call  4000ec90 <_POSIX_signals_Check_signal>   
4000ca88:	90 10 00 1d 	mov  %i5, %o0                                  
      _POSIX_signals_Check_signal( api, signo, true );                
4000ca8c:	92 10 00 1c 	mov  %i4, %o1                                  
4000ca90:	90 10 00 1d 	mov  %i5, %o0                                  
4000ca94:	40 00 08 7f 	call  4000ec90 <_POSIX_signals_Check_signal>   
4000ca98:	94 10 20 01 	mov  1, %o2                                    
       _POSIX_signals_Release( &lock_context );                       
       break;                                                         
     }                                                                
    _POSIX_signals_Release( &lock_context );                          
                                                                      
    for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {          
4000ca9c:	b8 07 20 01 	inc  %i4                                       
4000caa0:	80 a7 20 20 	cmp  %i4, 0x20                                 
4000caa4:	12 bf ff f7 	bne  4000ca80 <_POSIX_signals_Action_handler+0x64>
4000caa8:	92 10 00 1c 	mov  %i4, %o1                                  
4000caac:	b8 10 20 01 	mov  1, %i4                                    
      _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 );               
4000cab0:	92 10 00 1c 	mov  %i4, %o1                                  
4000cab4:	94 10 20 00 	clr  %o2                                       
4000cab8:	40 00 08 76 	call  4000ec90 <_POSIX_signals_Check_signal>   
4000cabc:	90 10 00 1d 	mov  %i5, %o0                                  
      _POSIX_signals_Check_signal( api, signo, true );                
4000cac0:	92 10 00 1c 	mov  %i4, %o1                                  
4000cac4:	90 10 00 1d 	mov  %i5, %o0                                  
4000cac8:	40 00 08 72 	call  4000ec90 <_POSIX_signals_Check_signal>   
4000cacc:	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++ ) {      
4000cad0:	b8 07 20 01 	inc  %i4                                       
4000cad4:	80 a7 20 1b 	cmp  %i4, 0x1b                                 
4000cad8:	12 bf ff f7 	bne  4000cab4 <_POSIX_signals_Action_handler+0x98>
4000cadc:	92 10 00 1c 	mov  %i4, %o1                                  
4000cae0:	30 bf ff d7 	b,a   4000ca3c <_POSIX_signals_Action_handler+0x20>
                                                                      

4000ec90 <_POSIX_signals_Check_signal>: bool _POSIX_signals_Check_signal( POSIX_API_Control *api, int signo, bool is_global ) {
4000ec90:	9d e3 bf 68 	save  %sp, -152, %sp                           
  siginfo_t                   siginfo_struct;                         
  sigset_t                    saved_signals_blocked;                  
  Thread_Wait_information     stored_thread_wait_information;         
  Thread_Control             *executing;                              
                                                                      
  if ( ! _POSIX_signals_Clear_signals( api, signo, &siginfo_struct,   
4000ec94:	98 10 20 01 	mov  1, %o4                                    
4000ec98:	90 10 00 18 	mov  %i0, %o0                                  
4000ec9c:	92 10 00 19 	mov  %i1, %o1                                  
4000eca0:	94 07 bf cc 	add  %fp, -52, %o2                             
4000eca4:	96 10 00 1a 	mov  %i2, %o3                                  
4000eca8:	40 00 00 2d 	call  4000ed5c <_POSIX_signals_Clear_signals>  
4000ecac:	9a 10 20 01 	mov  1, %o5                                    
4000ecb0:	80 a2 20 00 	cmp  %o0, 0                                    
4000ecb4:	02 80 00 27 	be  4000ed50 <_POSIX_signals_Check_signal+0xc0>
4000ecb8:	b8 10 00 08 	mov  %o0, %i4                                  
  #endif                                                              
                                                                      
  /*                                                                  
   *  Just to prevent sending a signal which is currently being ignored.
   */                                                                 
  if ( _POSIX_signals_Vectors[ signo ].sa_handler == SIG_IGN )        
4000ecbc:	83 2e 60 04 	sll  %i1, 4, %g1                               
4000ecc0:	23 10 00 63 	sethi  %hi(0x40018c00), %l1                    
4000ecc4:	a1 2e 60 02 	sll  %i1, 2, %l0                               
4000ecc8:	a2 14 61 28 	or  %l1, 0x128, %l1                            
4000eccc:	a0 20 40 10 	sub  %g1, %l0, %l0                             
4000ecd0:	82 04 40 10 	add  %l1, %l0, %g1                             
4000ecd4:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
4000ecd8:	80 a7 60 01 	cmp  %i5, 1                                    
4000ecdc:	02 80 00 1c 	be  4000ed4c <_POSIX_signals_Check_signal+0xbc><== NEVER TAKEN
4000ece0:	90 07 bf d8 	add  %fp, -40, %o0                             
    return false;                                                     
                                                                      
  /*                                                                  
   *  Block the signals requested in sa_mask                          
   */                                                                 
  saved_signals_blocked = api->signals_blocked;                       
4000ece4:	f6 06 20 dc 	ld  [ %i0 + 0xdc ], %i3                        
  api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;    
4000ece8:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
  /*                                                                  
   *  We have to save the blocking information of the current wait queue
   *  because the signal handler may subsequently go on and put the thread
   *  on a wait queue, for its own purposes.                          
   */                                                                 
  memcpy( &stored_thread_wait_information, &executing->Wait,          
4000ecec:	f4 01 a0 18 	ld  [ %g6 + 0x18 ], %i2                        
                                                                      
  /*                                                                  
   *  Block the signals requested in sa_mask                          
   */                                                                 
  saved_signals_blocked = api->signals_blocked;                       
  api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;    
4000ecf0:	82 10 40 1b 	or  %g1, %i3, %g1                              
  /*                                                                  
   *  We have to save the blocking information of the current wait queue
   *  because the signal handler may subsequently go on and put the thread
   *  on a wait queue, for its own purposes.                          
   */                                                                 
  memcpy( &stored_thread_wait_information, &executing->Wait,          
4000ecf4:	b4 06 a0 20 	add  %i2, 0x20, %i2                            
                                                                      
  /*                                                                  
   *  Block the signals requested in sa_mask                          
   */                                                                 
  saved_signals_blocked = api->signals_blocked;                       
  api->signals_blocked |= _POSIX_signals_Vectors[ signo ].sa_mask;    
4000ecf8:	c2 26 20 dc 	st  %g1, [ %i0 + 0xdc ]                        
  /*                                                                  
   *  We have to save the blocking information of the current wait queue
   *  because the signal handler may subsequently go on and put the thread
   *  on a wait queue, for its own purposes.                          
   */                                                                 
  memcpy( &stored_thread_wait_information, &executing->Wait,          
4000ecfc:	92 10 00 1a 	mov  %i2, %o1                                  
4000ed00:	40 00 05 2e 	call  400101b8 <memcpy>                        
4000ed04:	94 10 20 28 	mov  0x28, %o2                                 
          sizeof( stored_thread_wait_information ));                  
                                                                      
  /*                                                                  
   *  Here, the signal handler function executes                      
   */                                                                 
  switch ( _POSIX_signals_Vectors[ signo ].sa_flags ) {               
4000ed08:	c2 04 40 10 	ld  [ %l1 + %l0 ], %g1                         
4000ed0c:	80 a0 60 02 	cmp  %g1, 2                                    
4000ed10:	12 80 00 07 	bne  4000ed2c <_POSIX_signals_Check_signal+0x9c>
4000ed14:	90 10 00 19 	mov  %i1, %o0                                  
    case SA_SIGINFO:                                                  
      (*_POSIX_signals_Vectors[ signo ].sa_sigaction)(                
4000ed18:	92 07 bf cc 	add  %fp, -52, %o1                             
4000ed1c:	9f c7 40 00 	call  %i5                                      
4000ed20:	94 10 20 00 	clr  %o2                                       
        signo,                                                        
        &siginfo_struct,                                              
        NULL        /* context is undefined per 1003.1b-1993, p. 66 */
      );                                                              
      break;                                                          
4000ed24:	10 80 00 05 	b  4000ed38 <_POSIX_signals_Check_signal+0xa8> 
4000ed28:	90 10 00 1a 	mov  %i2, %o0                                  
    default:                                                          
      (*_POSIX_signals_Vectors[ signo ].sa_handler)( signo );         
4000ed2c:	9f c7 40 00 	call  %i5                                      
4000ed30:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  /*                                                                  
   *  Restore the blocking information                                
   */                                                                 
  memcpy( &executing->Wait, &stored_thread_wait_information,          
4000ed34:	90 10 00 1a 	mov  %i2, %o0                                  
4000ed38:	92 07 bf d8 	add  %fp, -40, %o1                             
4000ed3c:	40 00 05 1f 	call  400101b8 <memcpy>                        
4000ed40:	94 10 20 28 	mov  0x28, %o2                                 
  /*                                                                  
   *  Restore the previous set of blocked signals                     
   */                                                                 
  api->signals_blocked = saved_signals_blocked;                       
                                                                      
  return true;                                                        
4000ed44:	10 80 00 03 	b  4000ed50 <_POSIX_signals_Check_signal+0xc0> 
4000ed48:	f6 26 20 dc 	st  %i3, [ %i0 + 0xdc ]                        
  Thread_Wait_information     stored_thread_wait_information;         
  Thread_Control             *executing;                              
                                                                      
  if ( ! _POSIX_signals_Clear_signals( api, signo, &siginfo_struct,   
                                       is_global, true, true ) )      
    return false;                                                     
4000ed4c:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
   *  Restore the previous set of blocked signals                     
   */                                                                 
  api->signals_blocked = saved_signals_blocked;                       
                                                                      
  return true;                                                        
}                                                                     
4000ed50:	b0 0f 20 ff 	and  %i4, 0xff, %i0                            
4000ed54:	81 c7 e0 08 	ret                                            
4000ed58:	81 e8 00 00 	restore                                        
                                                                      

4000f920 <_POSIX_signals_Clear_process_signals>:
4000f920:	82 02 3f ff 	add  %o0, -1, %g1                              
4000f924:	84 10 20 01 	mov  1, %g2                                    
4000f928:	85 28 80 01 	sll  %g2, %g1, %g2                             
  _Assert( _ISR_Get_level() != 0 );                                   
                                                                      
  clear_signal = true;                                                
  mask         = signo_to_mask( signo );                              
                                                                      
  if ( _POSIX_signals_Vectors[ signo ].sa_flags == SA_SIGINFO ) {     
4000f92c:	83 2a 20 02 	sll  %o0, 2, %g1                               
4000f930:	91 2a 20 04 	sll  %o0, 4, %o0                               
4000f934:	90 22 00 01 	sub  %o0, %g1, %o0                             
4000f938:	03 10 00 63 	sethi  %hi(0x40018c00), %g1                    
4000f93c:	82 10 61 28 	or  %g1, 0x128, %g1	! 40018d28 <_POSIX_signals_Vectors>
4000f940:	c2 00 40 08 	ld  [ %g1 + %o0 ], %g1                         
4000f944:	80 a0 60 02 	cmp  %g1, 2                                    
4000f948:	12 80 00 0a 	bne  4000f970 <_POSIX_signals_Clear_process_signals+0x50>
4000f94c:	03 10 00 63 	sethi  %hi(0x40018c00), %g1                    
    if ( !_Chain_Is_empty( &_POSIX_signals_Siginfo[ signo ] ) )       
4000f950:	03 10 00 63 	sethi  %hi(0x40018c00), %g1                    
4000f954:	82 10 62 f8 	or  %g1, 0x2f8, %g1	! 40018ef8 <_POSIX_signals_Siginfo>
4000f958:	86 02 00 01 	add  %o0, %g1, %g3                             
4000f95c:	c2 02 00 01 	ld  [ %o0 + %g1 ], %g1                         
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000f960:	86 00 e0 04 	add  %g3, 4, %g3                               
4000f964:	80 a0 40 03 	cmp  %g1, %g3                                  
4000f968:	12 80 00 05 	bne  4000f97c <_POSIX_signals_Clear_process_signals+0x5c><== NEVER TAKEN
4000f96c:	03 10 00 63 	sethi  %hi(0x40018c00), %g1                    
      clear_signal = false;                                           
  }                                                                   
                                                                      
  if ( clear_signal ) {                                               
    _POSIX_signals_Pending &= ~mask;                                  
4000f970:	c6 00 62 f4 	ld  [ %g1 + 0x2f4 ], %g3	! 40018ef4 <_POSIX_signals_Pending>
4000f974:	84 28 c0 02 	andn  %g3, %g2, %g2                            
4000f978:	c4 20 62 f4 	st  %g2, [ %g1 + 0x2f4 ]                       
4000f97c:	81 c3 e0 08 	retl                                           
                                                                      

4000818c <_POSIX_signals_Get_lowest>: sigset_t set ) { int signo; for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {
4000818c:	82 10 20 1b 	mov  0x1b, %g1                                 
40008190:	84 10 20 01 	mov  1, %g2                                    
40008194:	86 00 7f ff 	add  %g1, -1, %g3                              
40008198:	87 28 80 03 	sll  %g2, %g3, %g3                             
    if ( set & signo_to_mask( signo ) ) {                             
4000819c:	80 88 c0 08 	btst  %g3, %o0                                 
400081a0:	12 80 00 11 	bne  400081e4 <_POSIX_signals_Get_lowest+0x58> <== NEVER TAKEN
400081a4:	01 00 00 00 	nop                                            
  sigset_t   set                                                      
)                                                                     
{                                                                     
  int signo;                                                          
                                                                      
  for ( signo = SIGRTMIN ; signo <= SIGRTMAX ; signo++ ) {            
400081a8:	82 00 60 01 	inc  %g1                                       
400081ac:	80 a0 60 20 	cmp  %g1, 0x20                                 
400081b0:	12 bf ff fa 	bne  40008198 <_POSIX_signals_Get_lowest+0xc>  
400081b4:	86 00 7f ff 	add  %g1, -1, %g3                              
400081b8:	82 10 20 01 	mov  1, %g1                                    
400081bc:	84 10 20 01 	mov  1, %g2                                    
400081c0:	86 00 7f ff 	add  %g1, -1, %g3                              
400081c4:	87 28 80 03 	sll  %g2, %g3, %g3                             
                                                                      
  #if (SIGHUP != 1)                                                   
    #error "Assumption that SIGHUP==1 violated!!"                     
  #endif                                                              
  for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {        
    if ( set & signo_to_mask( signo ) ) {                             
400081c8:	80 88 c0 08 	btst  %g3, %o0                                 
400081cc:	12 80 00 06 	bne  400081e4 <_POSIX_signals_Get_lowest+0x58> 
400081d0:	01 00 00 00 	nop                                            
   */                                                                 
                                                                      
  #if (SIGHUP != 1)                                                   
    #error "Assumption that SIGHUP==1 violated!!"                     
  #endif                                                              
  for ( signo = SIGHUP ; signo <= __SIGLASTNOTRT ; signo++ ) {        
400081d4:	82 00 60 01 	inc  %g1                                       
400081d8:	80 a0 60 1b 	cmp  %g1, 0x1b                                 
400081dc:	12 bf ff fa 	bne  400081c4 <_POSIX_signals_Get_lowest+0x38> <== ALWAYS TAKEN
400081e0:	86 00 7f ff 	add  %g1, -1, %g3                              
   *  a return 0.  This routine will NOT be called unless a signal    
   *  is pending in the set passed in.                                
   */                                                                 
found_it:                                                             
  return signo;                                                       
}                                                                     
400081e4:	81 c3 e0 08 	retl                                           
400081e8:	90 10 00 01 	mov  %g1, %o0                                  
                                                                      

4002985c <_POSIX_signals_Unblock_thread>: bool _POSIX_signals_Unblock_thread( Thread_Control *the_thread, int signo, siginfo_t *info ) {
4002985c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
40029860:	7f ff 64 3d 	call  40002954 <sparc_disable_interrupts>      
40029864:	fa 06 21 30 	ld  [ %i0 + 0x130 ], %i5                       
RTEMS_INLINE_ROUTINE void _Chain_Append_if_is_off_chain_unprotected(  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  if ( _Chain_Is_node_off_chain( the_node ) ) {                       
40029868:	c2 07 60 e4 	ld  [ %i5 + 0xe4 ], %g1                        
4002986c:	80 a0 60 00 	cmp  %g1, 0                                    
40029870:	12 80 00 08 	bne  40029890 <_POSIX_signals_Unblock_thread+0x34>
40029874:	86 06 20 c8 	add  %i0, 0xc8, %g3                            
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
40029878:	c2 06 20 cc 	ld  [ %i0 + 0xcc ], %g1                        
                                                                      
  the_node->next = tail;                                              
4002987c:	c6 27 60 e4 	st  %g3, [ %i5 + 0xe4 ]                        
{                                                                     
  Per_CPU_Control *cpu;                                               
  ISR_Level        level;                                             
                                                                      
  cpu = _Thread_Action_ISR_disable_and_acquire( thread, &level );     
  _Chain_Append_if_is_off_chain_unprotected(                          
40029880:	84 07 60 e4 	add  %i5, 0xe4, %g2                            
  tail->previous = the_node;                                          
40029884:	c4 26 20 cc 	st  %g2, [ %i0 + 0xcc ]                        
  old_last->next = the_node;                                          
40029888:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  the_node->previous = old_last;                                      
4002988c:	c2 27 60 e8 	st  %g1, [ %i5 + 0xe8 ]                        
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
40029890:	7f ff 64 34 	call  40002960 <sparc_enable_interrupts>       
40029894:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   *  Is the thread is specifically waiting for a signal?             
   */                                                                 
                                                                      
  if ( _States_Is_interruptible_signal( the_thread->current_state ) ) {
40029898:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
4002989c:	09 04 00 20 	sethi  %hi(0x10008000), %g4                    
400298a0:	84 06 7f ff 	add  %i1, -1, %g2                              
400298a4:	86 10 20 01 	mov  1, %g3                                    
400298a8:	b8 08 40 04 	and  %g1, %g4, %i4                             
400298ac:	80 a7 00 04 	cmp  %i4, %g4                                  
400298b0:	12 80 00 1c 	bne  40029920 <_POSIX_signals_Unblock_thread+0xc4>
400298b4:	85 28 c0 02 	sll  %g3, %g2, %g2                             
                                                                      
    if ( (the_thread->Wait.option & mask) || (~api->signals_blocked & mask) ) {
400298b8:	c2 06 20 30 	ld  [ %i0 + 0x30 ], %g1                        
400298bc:	80 88 80 01 	btst  %g2, %g1                                 
400298c0:	12 80 00 06 	bne  400298d8 <_POSIX_signals_Unblock_thread+0x7c>
400298c4:	82 10 20 04 	mov  4, %g1                                    
400298c8:	c2 07 60 dc 	ld  [ %i5 + 0xdc ], %g1                        
400298cc:	80 a8 80 01 	andncc  %g2, %g1, %g0                          
400298d0:	02 80 00 3a 	be  400299b8 <_POSIX_signals_Unblock_thread+0x15c>
400298d4:	82 10 20 04 	mov  4, %g1                                    
      the_thread->Wait.return_code = EINTR;                           
400298d8:	c2 26 20 34 	st  %g1, [ %i0 + 0x34 ]                        
                                                                      
      the_info = (siginfo_t *) the_thread->Wait.return_argument;      
                                                                      
      if ( !info ) {                                                  
400298dc:	80 a6 a0 00 	cmp  %i2, 0                                    
400298e0:	12 80 00 07 	bne  400298fc <_POSIX_signals_Unblock_thread+0xa0>
400298e4:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
        the_info->si_signo = signo;                                   
        the_info->si_code = SI_USER;                                  
400298e8:	82 10 20 01 	mov  1, %g1                                    
      the_thread->Wait.return_code = EINTR;                           
                                                                      
      the_info = (siginfo_t *) the_thread->Wait.return_argument;      
                                                                      
      if ( !info ) {                                                  
        the_info->si_signo = signo;                                   
400298ec:	f2 22 00 00 	st  %i1, [ %o0 ]                               
        the_info->si_code = SI_USER;                                  
400298f0:	c2 22 20 04 	st  %g1, [ %o0 + 4 ]                           
400298f4:	10 80 00 05 	b  40029908 <_POSIX_signals_Unblock_thread+0xac>
400298f8:	c0 22 20 08 	clr  [ %o0 + 8 ]                               
        the_info->si_value.sival_int = 0;                             
      } else {                                                        
        *the_info = *info;                                            
400298fc:	92 10 00 1a 	mov  %i2, %o1                                  
40029900:	7f ff bf 39 	call  400195e4 <memcpy>                        
40029904:	94 10 20 0c 	mov  0xc, %o2                                  
      }                                                               
                                                                      
      _Thread_queue_Extract_with_proxy( the_thread );                 
40029908:	90 10 00 18 	mov  %i0, %o0                                  
4002990c:	7f ff ac bf 	call  40014c08 <_Thread_queue_Extract_with_proxy>
40029910:	b0 10 20 01 	mov  1, %i0                                    
40029914:	b0 0e 20 01 	and  %i0, 1, %i0                               
40029918:	81 c7 e0 08 	ret                                            
4002991c:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  /*                                                                  
   *  Thread is not waiting due to a sigwait.                         
   */                                                                 
  if ( ~api->signals_blocked & mask ) {                               
40029920:	c8 07 60 dc 	ld  [ %i5 + 0xdc ], %g4                        
40029924:	80 a8 80 04 	andncc  %g2, %g4, %g0                          
40029928:	02 80 00 24 	be  400299b8 <_POSIX_signals_Unblock_thread+0x15c>
4002992c:	05 04 00 00 	sethi  %hi(0x10000000), %g2                    
     *      it is not blocked, THEN                                   
     *        we need to dispatch at the end of this ISR.             
     *    + Any other combination, do nothing.                        
     */                                                               
                                                                      
    if ( _States_Is_interruptible_by_signal( the_thread->current_state ) ) {
40029930:	80 88 40 02 	btst  %g1, %g2                                 
40029934:	02 80 00 17 	be  40029990 <_POSIX_signals_Unblock_thread+0x134>
40029938:	80 a0 60 00 	cmp  %g1, 0                                    
      the_thread->Wait.return_code = EINTR;                           
4002993c:	84 10 20 04 	mov  4, %g2                                    
40029940:	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) )
40029944:	05 00 02 ef 	sethi  %hi(0xbbc00), %g2                       
40029948:	84 10 a2 e0 	or  %g2, 0x2e0, %g2	! bbee0 <_TLS_Alignment+0xbbedf>
4002994c:	80 88 40 02 	btst  %g1, %g2                                 
40029950:	02 80 00 06 	be  40029968 <_POSIX_signals_Unblock_thread+0x10c>
40029954:	80 88 60 08 	btst  8, %g1                                   
         _Thread_queue_Extract_with_proxy( the_thread );              
40029958:	7f ff ac ac 	call  40014c08 <_Thread_queue_Extract_with_proxy>
4002995c:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
    } else if ( the_thread->current_state == STATES_READY ) {         
      _Thread_Signal_notification( the_thread );                      
    }                                                                 
  }                                                                   
  return false;                                                       
40029960:	10 80 00 17 	b  400299bc <_POSIX_signals_Unblock_thread+0x160>
40029964:	b0 10 20 00 	clr  %i0                                       
       *  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 );              
       else if ( _States_Is_delaying(the_thread->current_state) ) {   
40029968:	22 80 00 15 	be,a   400299bc <_POSIX_signals_Unblock_thread+0x160><== NEVER TAKEN
4002996c:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
          (void) _Watchdog_Remove( &the_thread->Timer );              
40029970:	7f ff 96 de 	call  4000f4e8 <_Watchdog_Remove>              
40029974:	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 );                  
40029978:	90 10 00 18 	mov  %i0, %o0                                  
4002997c:	13 04 03 ff 	sethi  %hi(0x100ffc00), %o1                    
40029980:	7f ff 91 64 	call  4000df10 <_Thread_Clear_state>           
40029984:	92 12 63 f8 	or  %o1, 0x3f8, %o1	! 100ffff8 <RAM_SIZE+0xfcffff8>
                                                                      
    } else if ( the_thread->current_state == STATES_READY ) {         
      _Thread_Signal_notification( the_thread );                      
    }                                                                 
  }                                                                   
  return false;                                                       
40029988:	10 80 00 0d 	b  400299bc <_POSIX_signals_Unblock_thread+0x160>
4002998c:	b0 10 20 00 	clr  %i0                                       
       else if ( _States_Is_delaying(the_thread->current_state) ) {   
          (void) _Watchdog_Remove( &the_thread->Timer );              
          _Thread_Unblock( the_thread );                              
       }                                                              
                                                                      
    } else if ( the_thread->current_state == STATES_READY ) {         
40029990:	32 80 00 0b 	bne,a   400299bc <_POSIX_signals_Unblock_thread+0x160><== NEVER TAKEN
40029994:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
#endif                                                                
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE void _Thread_Signal_notification( Thread_Control *thread )
{                                                                     
  if ( _ISR_Is_in_progress() && _Thread_Is_executing( thread ) ) {    
40029998:	c4 01 a0 0c 	ld  [ %g6 + 0xc ], %g2                         
4002999c:	80 a0 a0 00 	cmp  %g2, 0                                    
400299a0:	22 80 00 07 	be,a   400299bc <_POSIX_signals_Unblock_thread+0x160>
400299a4:	b0 10 20 00 	clr  %i0                                       
400299a8:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
400299ac:	80 a6 00 02 	cmp  %i0, %g2                                  
400299b0:	22 80 00 02 	be,a   400299b8 <_POSIX_signals_Unblock_thread+0x15c><== ALWAYS TAKEN
400299b4:	c6 29 a0 14 	stb  %g3, [ %g6 + 0x14 ]                       
      _Thread_Signal_notification( the_thread );                      
    }                                                                 
  }                                                                   
  return false;                                                       
400299b8:	b0 10 20 00 	clr  %i0                                       
}                                                                     
400299bc:	b0 0e 20 01 	and  %i0, 1, %i0                               
400299c0:	81 c7 e0 08 	ret                                            
400299c4:	81 e8 00 00 	restore                                        
                                                                      

4000b010 <_RBTree_Initialize>: void *starting_address, size_t number_nodes, size_t node_size, bool is_unique ) {
4000b010:	9d e3 bf a0 	save  %sp, -96, %sp                            
  size_t      count;                                                  
  RBTree_Node *next;                                                  
                                                                      
  /* TODO: Error message? */                                          
  if (!the_rbtree) return;                                            
4000b014:	80 a6 20 00 	cmp  %i0, 0                                    
4000b018:	02 80 00 10 	be  4000b058 <_RBTree_Initialize+0x48>         <== NEVER TAKEN
4000b01c:	01 00 00 00 	nop                                            
    RBTree_Control          *the_rbtree,                              
    RBTree_Compare_function  compare_function,                        
    bool                     is_unique                                
    )                                                                 
{                                                                     
  the_rbtree->permanent_null   = NULL;                                
4000b020:	c0 26 00 00 	clr  [ %i0 ]                                   
  the_rbtree->root             = NULL;                                
4000b024:	c0 26 20 04 	clr  [ %i0 + 4 ]                               
  the_rbtree->first[0]         = NULL;                                
4000b028:	c0 26 20 08 	clr  [ %i0 + 8 ]                               
  the_rbtree->first[1]         = NULL;                                
4000b02c:	c0 26 20 0c 	clr  [ %i0 + 0xc ]                             
  the_rbtree->compare_function = compare_function;                    
4000b030:	f2 26 20 10 	st  %i1, [ %i0 + 0x10 ]                        
  the_rbtree->is_unique        = is_unique;                           
4000b034:	fa 2e 20 14 	stb  %i5, [ %i0 + 0x14 ]                       
  /* could do sanity checks here */                                   
  _RBTree_Initialize_empty(the_rbtree, compare_function, is_unique);  
                                                                      
  count = number_nodes;                                               
  next  = starting_address;                                           
  while ( count-- ) {                                                 
4000b038:	80 a6 e0 00 	cmp  %i3, 0                                    
4000b03c:	02 80 00 07 	be  4000b058 <_RBTree_Initialize+0x48>         
4000b040:	92 10 00 1a 	mov  %i2, %o1                                  
    _RBTree_Insert(the_rbtree, next);                                 
4000b044:	90 10 00 18 	mov  %i0, %o0                                  
4000b048:	7f ff ff 44 	call  4000ad58 <_RBTree_Insert>                
4000b04c:	b4 06 80 1c 	add  %i2, %i4, %i2                             
4000b050:	10 bf ff fa 	b  4000b038 <_RBTree_Initialize+0x28>          
4000b054:	b6 06 ff ff 	add  %i3, -1, %i3                              
4000b058:	81 c7 e0 08 	ret                                            
4000b05c:	81 e8 00 00 	restore                                        
                                                                      

40007e74 <_RBTree_Insert>: */ RBTree_Node *_RBTree_Insert( RBTree_Control *the_rbtree, RBTree_Node *the_node ) {
40007e74:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if(!the_node) return (RBTree_Node*)-1;                              
40007e78:	80 a6 60 00 	cmp  %i1, 0                                    
40007e7c:	02 80 00 80 	be  4000807c <_RBTree_Insert+0x208>            
40007e80:	01 00 00 00 	nop                                            
                                                                      
  RBTree_Node *iter_node = the_rbtree->root;                          
40007e84:	fa 06 20 04 	ld  [ %i0 + 4 ], %i5                           
  int compare_result;                                                 
                                                                      
  if (!iter_node) { /* special case: first node inserted */           
40007e88:	80 a7 60 00 	cmp  %i5, 0                                    
40007e8c:	32 80 00 16 	bne,a   40007ee4 <_RBTree_Insert+0x70>         
40007e90:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
    the_node->color = RBT_BLACK;                                      
40007e94:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
    the_rbtree->root = the_node;                                      
40007e98:	f2 26 20 04 	st  %i1, [ %i0 + 4 ]                           
    the_rbtree->first[0] = the_rbtree->first[1] = the_node;           
40007e9c:	f2 26 20 0c 	st  %i1, [ %i0 + 0xc ]                         
40007ea0:	f2 26 20 08 	st  %i1, [ %i0 + 8 ]                           
    the_node->parent = (RBTree_Node *) the_rbtree;                    
40007ea4:	f0 26 40 00 	st  %i0, [ %i1 ]                               
    the_node->child[RBT_LEFT] = the_node->child[RBT_RIGHT] = NULL;    
40007ea8:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
40007eac:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
40007eb0:	81 c7 e0 08 	ret                                            
40007eb4:	91 e8 20 00 	restore  %g0, 0, %o0                           
  } else {                                                            
    /* typical binary search tree insert, descend tree to leaf and insert */
    while (iter_node) {                                               
      compare_result = the_rbtree->compare_function(the_node, iter_node);
      if ( the_rbtree->is_unique && _RBTree_Is_equal( compare_result ) )
40007eb8:	02 80 00 73 	be  40008084 <_RBTree_Insert+0x210>            
40007ebc:	b8 38 00 08 	xnor  %g0, %o0, %i4                            
        return iter_node;                                             
      RBTree_Direction dir = !_RBTree_Is_lesser( compare_result );    
40007ec0:	b9 37 20 1f 	srl  %i4, 0x1f, %i4                            
      if (!iter_node->child[dir]) {                                   
40007ec4:	83 2f 20 02 	sll  %i4, 2, %g1                               
40007ec8:	84 07 40 01 	add  %i5, %g1, %g2                             
40007ecc:	c6 00 a0 04 	ld  [ %g2 + 4 ], %g3                           
40007ed0:	80 a0 e0 00 	cmp  %g3, 0                                    
40007ed4:	22 80 00 0d 	be,a   40007f08 <_RBTree_Insert+0x94>          
40007ed8:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
              (dir && _RBTree_Is_greater(compare_result)) ) {         
          the_rbtree->first[dir] = the_node;                          
        }                                                             
        break;                                                        
      } else {                                                        
        iter_node = iter_node->child[dir];                            
40007edc:	ba 10 00 03 	mov  %g3, %i5                                  
    the_node->parent = (RBTree_Node *) the_rbtree;                    
    the_node->child[RBT_LEFT] = the_node->child[RBT_RIGHT] = NULL;    
  } else {                                                            
    /* typical binary search tree insert, descend tree to leaf and insert */
    while (iter_node) {                                               
      compare_result = the_rbtree->compare_function(the_node, iter_node);
40007ee0:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
40007ee4:	90 10 00 19 	mov  %i1, %o0                                  
40007ee8:	9f c0 40 00 	call  %g1                                      
40007eec:	92 10 00 1d 	mov  %i5, %o1                                  
      if ( the_rbtree->is_unique && _RBTree_Is_equal( compare_result ) )
40007ef0:	c2 0e 20 14 	ldub  [ %i0 + 0x14 ], %g1                      
40007ef4:	80 a0 60 00 	cmp  %g1, 0                                    
40007ef8:	22 bf ff f2 	be,a   40007ec0 <_RBTree_Insert+0x4c>          
40007efc:	b8 38 00 08 	xnor  %g0, %o0, %i4                            
40007f00:	10 bf ff ee 	b  40007eb8 <_RBTree_Insert+0x44>              
40007f04:	80 a2 20 00 	cmp  %o0, 0                                    
        return iter_node;                                             
      RBTree_Direction dir = !_RBTree_Is_lesser( compare_result );    
      if (!iter_node->child[dir]) {                                   
        the_node->child[RBT_LEFT] = the_node->child[RBT_RIGHT] = NULL;
40007f08:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
        the_node->color = RBT_RED;                                    
40007f0c:	86 10 20 01 	mov  1, %g3                                    
40007f10:	c6 26 60 0c 	st  %g3, [ %i1 + 0xc ]                         
        iter_node->child[dir] = the_node;                             
40007f14:	f2 20 a0 04 	st  %i1, [ %g2 + 4 ]                           
        the_node->parent = iter_node;                                 
40007f18:	fa 26 40 00 	st  %i5, [ %i1 ]                               
40007f1c:	ba 06 00 01 	add  %i0, %g1, %i5                             
        /* update min/max */                                          
        compare_result = the_rbtree->compare_function(                
40007f20:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
40007f24:	d2 07 60 08 	ld  [ %i5 + 8 ], %o1                           
40007f28:	9f c0 40 00 	call  %g1                                      
40007f2c:	90 10 00 19 	mov  %i1, %o0                                  
            the_node,                                                 
            _RBTree_First(the_rbtree, dir)                            
        );                                                            
        if ( (!dir && _RBTree_Is_lesser(compare_result)) ||           
40007f30:	80 a7 20 00 	cmp  %i4, 0                                    
40007f34:	12 80 00 06 	bne  40007f4c <_RBTree_Insert+0xd8>            
40007f38:	80 a2 20 00 	cmp  %o0, 0                                    
40007f3c:	36 80 00 1e 	bge,a   40007fb4 <_RBTree_Insert+0x140>        
40007f40:	d0 06 40 00 	ld  [ %i1 ], %o0                               
              (dir && _RBTree_Is_greater(compare_result)) ) {         
          the_rbtree->first[dir] = the_node;                          
40007f44:	10 80 00 1b 	b  40007fb0 <_RBTree_Insert+0x13c>             
40007f48:	f2 27 60 08 	st  %i1, [ %i5 + 8 ]                           
        compare_result = the_rbtree->compare_function(                
            the_node,                                                 
            _RBTree_First(the_rbtree, dir)                            
        );                                                            
        if ( (!dir && _RBTree_Is_lesser(compare_result)) ||           
              (dir && _RBTree_Is_greater(compare_result)) ) {         
40007f4c:	34 80 00 19 	bg,a   40007fb0 <_RBTree_Insert+0x13c>         
40007f50:	f2 27 60 08 	st  %i1, [ %i5 + 8 ]                           
 *                                                                    
 *  @note It does NOT disable interrupts to ensure the atomicity of the
 *        append operation.                                           
 */                                                                   
static void _RBTree_Validate_insert(                                  
    RBTree_Node    *the_node                                          
40007f54:	10 80 00 18 	b  40007fb4 <_RBTree_Insert+0x140>             
40007f58:	d0 06 40 00 	ld  [ %i1 ], %o0                               
 */                                                                   
RTEMS_INLINE_ROUTINE bool _RBTree_Is_red(                             
    const RBTree_Node *the_node                                       
    )                                                                 
{                                                                     
  return (the_node && the_node->color == RBT_RED);                    
40007f5c:	82 18 60 01 	xor  %g1, 1, %g1                               
40007f60:	80 a0 00 01 	cmp  %g0, %g1                                  
40007f64:	82 60 3f ff 	subx  %g0, -1, %g1                             
  RBTree_Node *u,*g;                                                  
                                                                      
  /* note: the insert root case is handled already */                 
  /* if the parent is black, nothing needs to be done                 
   * otherwise may need to loop a few times */                        
  while (_RBTree_Is_red(_RBTree_Parent(the_node))) {                  
40007f68:	80 a0 60 00 	cmp  %g1, 0                                    
40007f6c:	02 80 00 3f 	be  40008068 <_RBTree_Insert+0x1f4>            
40007f70:	80 a7 60 00 	cmp  %i5, 0                                    
  const RBTree_Node *the_node                                         
)                                                                     
{                                                                     
  if(!the_node) return NULL;                                          
  if(!(the_node->parent)) return NULL;                                
  if(!(the_node->parent->parent)) return NULL;                        
40007f74:	02 80 00 06 	be  40007f8c <_RBTree_Insert+0x118>            <== NEVER TAKEN
40007f78:	82 10 20 00 	clr  %g1                                       
  if(!(the_node->parent->parent->parent)) return NULL;                
40007f7c:	c2 07 40 00 	ld  [ %i5 ], %g1                               
40007f80:	80 a0 60 00 	cmp  %g1, 0                                    
40007f84:	32 80 00 12 	bne,a   40007fcc <_RBTree_Insert+0x158>        <== ALWAYS TAKEN
40007f88:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
 */                                                                   
RTEMS_INLINE_ROUTINE bool _RBTree_Is_red(                             
    const RBTree_Node *the_node                                       
    )                                                                 
{                                                                     
  return (the_node && the_node->color == RBT_RED);                    
40007f8c:	84 10 20 00 	clr  %g2                                       <== NOT EXECUTED
    u = _RBTree_Parent_sibling(the_node);                             
    g = the_node->parent->parent;                                     
                                                                      
    /* if uncle is red, repaint uncle/parent black and grandparent red */
    if(_RBTree_Is_red(u)) {                                           
40007f90:	80 a0 a0 00 	cmp  %g2, 0                                    
40007f94:	22 80 00 1c 	be,a   40008004 <_RBTree_Insert+0x190>         
40007f98:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
      the_node->parent->color = RBT_BLACK;                            
40007f9c:	c0 22 20 0c 	clr  [ %o0 + 0xc ]                             
      u->color = RBT_BLACK;                                           
40007fa0:	c0 20 60 0c 	clr  [ %g1 + 0xc ]                             
      g->color = RBT_RED;                                             
40007fa4:	82 10 20 01 	mov  1, %g1                                    
40007fa8:	c2 27 60 0c 	st  %g1, [ %i5 + 0xc ]                         
      }                                                               
      the_node->parent->color = RBT_BLACK;                            
      g->color = RBT_RED;                                             
                                                                      
      /* now rotate grandparent in the other branch direction (toward uncle) */
      _RBTree_Rotate(g, (1-pdir));                                    
40007fac:	b2 10 00 1d 	mov  %i5, %i1                                  
 *                                                                    
 *  @note It does NOT disable interrupts to ensure the atomicity of the
 *        append operation.                                           
 */                                                                   
static void _RBTree_Validate_insert(                                  
    RBTree_Node    *the_node                                          
40007fb0:	d0 06 40 00 	ld  [ %i1 ], %o0                               
 */                                                                   
RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_Parent(                     
  const RBTree_Node *the_node                                         
)                                                                     
{                                                                     
  if (!the_node->parent->parent) return NULL;                         
40007fb4:	fa 02 00 00 	ld  [ %o0 ], %i5                               
40007fb8:	80 a7 60 00 	cmp  %i5, 0                                    
40007fbc:	32 bf ff e8 	bne,a   40007f5c <_RBTree_Insert+0xe8>         
40007fc0:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
40007fc4:	10 bf ff e9 	b  40007f68 <_RBTree_Insert+0xf4>              
40007fc8:	82 10 20 00 	clr  %g1                                       
{                                                                     
  if(!the_node) return NULL;                                          
  if(!(the_node->parent)) return NULL;                                
  if(!(the_node->parent->parent)) return NULL;                        
                                                                      
  if(the_node == the_node->parent->child[RBT_LEFT])                   
40007fcc:	80 a2 00 01 	cmp  %o0, %g1                                  
40007fd0:	22 80 00 02 	be,a   40007fd8 <_RBTree_Insert+0x164>         
40007fd4:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
 */                                                                   
RTEMS_INLINE_ROUTINE bool _RBTree_Is_red(                             
    const RBTree_Node *the_node                                       
    )                                                                 
{                                                                     
  return (the_node && the_node->color == RBT_RED);                    
40007fd8:	80 a0 60 00 	cmp  %g1, 0                                    
40007fdc:	02 bf ff ed 	be  40007f90 <_RBTree_Insert+0x11c>            
40007fe0:	84 10 20 00 	clr  %g2                                       
40007fe4:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
40007fe8:	80 a0 a0 01 	cmp  %g2, 1                                    
40007fec:	32 bf ff e9 	bne,a   40007f90 <_RBTree_Insert+0x11c>        
40007ff0:	84 10 20 00 	clr  %g2                                       
40007ff4:	10 80 00 02 	b  40007ffc <_RBTree_Insert+0x188>             
40007ff8:	84 10 20 01 	mov  1, %g2                                    
  while (_RBTree_Is_red(_RBTree_Parent(the_node))) {                  
    u = _RBTree_Parent_sibling(the_node);                             
    g = the_node->parent->parent;                                     
                                                                      
    /* if uncle is red, repaint uncle/parent black and grandparent red */
    if(_RBTree_Is_red(u)) {                                           
40007ffc:	10 bf ff e6 	b  40007f94 <_RBTree_Insert+0x120>             
40008000:	80 a0 a0 00 	cmp  %g2, 0                                    
      u->color = RBT_BLACK;                                           
      g->color = RBT_RED;                                             
      the_node = g;                                                   
    } else { /* if uncle is black */                                  
      RBTree_Direction dir = the_node != the_node->parent->child[0];  
      RBTree_Direction pdir = the_node->parent != g->child[0];        
40008004:	82 1a 00 01 	xor  %o0, %g1, %g1                             
40008008:	80 a0 00 01 	cmp  %g0, %g1                                  
      the_node->parent->color = RBT_BLACK;                            
      u->color = RBT_BLACK;                                           
      g->color = RBT_RED;                                             
      the_node = g;                                                   
    } else { /* if uncle is black */                                  
      RBTree_Direction dir = the_node != the_node->parent->child[0];  
4000800c:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           
      RBTree_Direction pdir = the_node->parent != g->child[0];        
40008010:	b8 40 20 00 	addx  %g0, 0, %i4                              
      the_node->parent->color = RBT_BLACK;                            
      u->color = RBT_BLACK;                                           
      g->color = RBT_RED;                                             
      the_node = g;                                                   
    } else { /* if uncle is black */                                  
      RBTree_Direction dir = the_node != the_node->parent->child[0];  
40008014:	82 1e 40 01 	xor  %i1, %g1, %g1                             
40008018:	80 a0 00 01 	cmp  %g0, %g1                                  
4000801c:	82 40 20 00 	addx  %g0, 0, %g1                              
      RBTree_Direction pdir = the_node->parent != g->child[0];        
                                                                      
      /* ensure node is on the same branch direction as parent */     
      if (dir != pdir) {                                              
40008020:	80 a0 40 1c 	cmp  %g1, %i4                                  
40008024:	22 80 00 08 	be,a   40008044 <_RBTree_Insert+0x1d0>         
40008028:	c2 06 40 00 	ld  [ %i1 ], %g1                               
        _RBTree_Rotate(the_node->parent, pdir);                       
4000802c:	7f ff ff 74 	call  40007dfc <_RBTree_Rotate>                
40008030:	92 10 00 1c 	mov  %i4, %o1                                  
        the_node = the_node->child[pdir];                             
40008034:	83 2f 20 02 	sll  %i4, 2, %g1                               
40008038:	b2 06 40 01 	add  %i1, %g1, %i1                             
4000803c:	f2 06 60 04 	ld  [ %i1 + 4 ], %i1                           
      }                                                               
      the_node->parent->color = RBT_BLACK;                            
40008040:	c2 06 40 00 	ld  [ %i1 ], %g1                               
      g->color = RBT_RED;                                             
40008044:	92 10 20 01 	mov  1, %o1                                    
      /* ensure node is on the same branch direction as parent */     
      if (dir != pdir) {                                              
        _RBTree_Rotate(the_node->parent, pdir);                       
        the_node = the_node->child[pdir];                             
      }                                                               
      the_node->parent->color = RBT_BLACK;                            
40008048:	c0 20 60 0c 	clr  [ %g1 + 0xc ]                             
      g->color = RBT_RED;                                             
4000804c:	d2 27 60 0c 	st  %o1, [ %i5 + 0xc ]                         
                                                                      
      /* now rotate grandparent in the other branch direction (toward uncle) */
      _RBTree_Rotate(g, (1-pdir));                                    
40008050:	90 10 00 1d 	mov  %i5, %o0                                  
40008054:	92 22 40 1c 	sub  %o1, %i4, %o1                             
40008058:	7f ff ff 69 	call  40007dfc <_RBTree_Rotate>                
4000805c:	ba 10 00 19 	mov  %i1, %i5                                  
40008060:	10 bf ff d4 	b  40007fb0 <_RBTree_Insert+0x13c>             
40008064:	b2 10 00 1d 	mov  %i5, %i1                                  
    }                                                                 
  }                                                                   
  if(!the_node->parent->parent) the_node->color = RBT_BLACK;          
40008068:	12 80 00 03 	bne  40008074 <_RBTree_Insert+0x200>           
4000806c:	b0 10 20 00 	clr  %i0                                       
40008070:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
40008074:	81 c7 e0 08 	ret                                            
40008078:	81 e8 00 00 	restore                                        
RBTree_Node *_RBTree_Insert(                                          
    RBTree_Control *the_rbtree,                                       
    RBTree_Node *the_node                                             
    )                                                                 
{                                                                     
  if(!the_node) return (RBTree_Node*)-1;                              
4000807c:	81 c7 e0 08 	ret                                            
40008080:	91 e8 3f ff 	restore  %g0, -1, %o0                          
40008084:	b0 10 00 1d 	mov  %i5, %i0                                  
                                                                      
    /* verify red-black properties */                                 
    _RBTree_Validate_insert(the_node);                                
  }                                                                   
  return (RBTree_Node*)0;                                             
}                                                                     
40008088:	81 c7 e0 08 	ret                                            
4000808c:	81 e8 00 00 	restore                                        
                                                                      

4000a70c <_RBTree_Iterate>: const RBTree_Control *rbtree, RBTree_Direction dir, RBTree_Visitor visitor, void *visitor_arg ) {
4000a70c:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
RTEMS_INLINE_ROUTINE RBTree_Direction _RBTree_Opposite_direction(     
  RBTree_Direction the_dir                                            
)                                                                     
{                                                                     
  return (RBTree_Direction) !((int) the_dir);                         
4000a710:	80 a0 00 19 	cmp  %g0, %i1                                  
4000a714:	82 60 3f ff 	subx  %g0, -1, %g1                             
RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_First(                      
  const RBTree_Control *the_rbtree,                                   
  RBTree_Direction dir                                                
)                                                                     
{                                                                     
  return the_rbtree->first[dir];                                      
4000a718:	82 00 60 02 	add  %g1, 2, %g1                               
4000a71c:	83 28 60 02 	sll  %g1, 2, %g1                               
4000a720:	fa 06 00 01 	ld  [ %i0 + %g1 ], %i5                         
  RBTree_Direction opp_dir = _RBTree_Opposite_direction( dir );       
  const RBTree_Node *current = _RBTree_First( rbtree, opp_dir );      
  bool stop = false;                                                  
4000a724:	b8 10 20 00 	clr  %i4                                       
                                                                      
  while ( !stop && current != NULL ) {                                
4000a728:	80 a7 60 00 	cmp  %i5, 0                                    
4000a72c:	02 80 00 0e 	be  4000a764 <_RBTree_Iterate+0x58>            
4000a730:	b8 1f 20 01 	xor  %i4, 1, %i4                               
4000a734:	80 8f 20 ff 	btst  0xff, %i4                                
4000a738:	02 80 00 0b 	be  4000a764 <_RBTree_Iterate+0x58>            <== NEVER TAKEN
4000a73c:	90 10 00 1d 	mov  %i5, %o0                                  
    stop = (*visitor)( current, dir, visitor_arg );                   
4000a740:	92 10 00 19 	mov  %i1, %o1                                  
4000a744:	9f c6 80 00 	call  %i2                                      
4000a748:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
    current = _RBTree_Next( current, dir );                           
4000a74c:	92 10 00 19 	mov  %i1, %o1                                  
  RBTree_Direction opp_dir = _RBTree_Opposite_direction( dir );       
  const RBTree_Node *current = _RBTree_First( rbtree, opp_dir );      
  bool stop = false;                                                  
                                                                      
  while ( !stop && current != NULL ) {                                
    stop = (*visitor)( current, dir, visitor_arg );                   
4000a750:	b8 10 00 08 	mov  %o0, %i4                                  
                                                                      
    current = _RBTree_Next( current, dir );                           
4000a754:	40 00 00 06 	call  4000a76c <_RBTree_Next>                  
4000a758:	90 10 00 1d 	mov  %i5, %o0                                  
4000a75c:	10 bf ff f3 	b  4000a728 <_RBTree_Iterate+0x1c>             
4000a760:	ba 10 00 08 	mov  %o0, %i5                                  
4000a764:	81 c7 e0 08 	ret                                            
4000a768:	81 e8 00 00 	restore                                        
                                                                      

4000f3dc <_RBTree_Rotate>: RBTree_Node *the_node, RBTree_Direction dir ) { RBTree_Node *c; if (the_node == NULL) return;
4000f3dc:	80 a2 20 00 	cmp  %o0, 0                                    
4000f3e0:	02 80 00 1b 	be  4000f44c <_RBTree_Rotate+0x70>             <== NEVER TAKEN
4000f3e4:	80 a0 00 09 	cmp  %g0, %o1                                  
 */                                                                   
RTEMS_INLINE_ROUTINE RBTree_Direction _RBTree_Opposite_direction(     
  RBTree_Direction the_dir                                            
)                                                                     
{                                                                     
  return (RBTree_Direction) !((int) the_dir);                         
4000f3e8:	84 60 3f ff 	subx  %g0, -1, %g2                             
4000f3ec:	85 28 a0 02 	sll  %g2, 2, %g2                               
4000f3f0:	84 02 00 02 	add  %o0, %g2, %g2                             
    RBTree_Direction dir                                              
    )                                                                 
{                                                                     
  RBTree_Node *c;                                                     
  if (the_node == NULL) return;                                       
  if (the_node->child[_RBTree_Opposite_direction(dir)] == NULL) return;
4000f3f4:	c2 00 a0 04 	ld  [ %g2 + 4 ], %g1                           
4000f3f8:	80 a0 60 00 	cmp  %g1, 0                                    
4000f3fc:	02 80 00 14 	be  4000f44c <_RBTree_Rotate+0x70>             <== NEVER TAKEN
4000f400:	93 2a 60 02 	sll  %o1, 2, %o1                               
4000f404:	92 00 40 09 	add  %g1, %o1, %o1                             
                                                                      
  c = the_node->child[_RBTree_Opposite_direction(dir)];               
  the_node->child[_RBTree_Opposite_direction(dir)] = c->child[dir];   
4000f408:	c6 02 60 04 	ld  [ %o1 + 4 ], %g3                           
4000f40c:	c6 20 a0 04 	st  %g3, [ %g2 + 4 ]                           
                                                                      
  if (c->child[dir])                                                  
4000f410:	c4 02 60 04 	ld  [ %o1 + 4 ], %g2                           
4000f414:	80 a0 a0 00 	cmp  %g2, 0                                    
4000f418:	32 80 00 02 	bne,a   4000f420 <_RBTree_Rotate+0x44>         
4000f41c:	d0 20 80 00 	st  %o0, [ %g2 ]                               
    c->child[dir]->parent = the_node;                                 
                                                                      
  c->child[dir] = the_node;                                           
4000f420:	d0 22 60 04 	st  %o0, [ %o1 + 4 ]                           
                                                                      
  the_node->parent->child[the_node != the_node->parent->child[0]] = c;
4000f424:	c4 02 00 00 	ld  [ %o0 ], %g2                               
4000f428:	c6 00 a0 04 	ld  [ %g2 + 4 ], %g3                           
4000f42c:	86 1a 00 03 	xor  %o0, %g3, %g3                             
4000f430:	80 a0 00 03 	cmp  %g0, %g3                                  
4000f434:	86 40 20 00 	addx  %g0, 0, %g3                              
4000f438:	87 28 e0 02 	sll  %g3, 2, %g3                               
4000f43c:	86 00 80 03 	add  %g2, %g3, %g3                             
4000f440:	c2 20 e0 04 	st  %g1, [ %g3 + 4 ]                           
                                                                      
  c->parent = the_node->parent;                                       
4000f444:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  the_node->parent = c;                                               
4000f448:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000f44c:	81 c3 e0 08 	retl                                           
                                                                      

4000f394 <_RBTree_Sibling>: */ RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_Sibling( const RBTree_Node *the_node ) { if(!the_node) return NULL;
4000f394:	80 a2 20 00 	cmp  %o0, 0                                    
4000f398:	02 80 00 0f 	be  4000f3d4 <_RBTree_Sibling+0x40>            <== NEVER TAKEN
4000f39c:	82 10 20 00 	clr  %g1                                       
  if(!(the_node->parent)) return NULL;                                
4000f3a0:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000f3a4:	80 a0 60 00 	cmp  %g1, 0                                    
4000f3a8:	02 80 00 0b 	be  4000f3d4 <_RBTree_Sibling+0x40>            <== NEVER TAKEN
4000f3ac:	01 00 00 00 	nop                                            
  if(!(the_node->parent->parent)) return NULL;                        
4000f3b0:	c4 00 40 00 	ld  [ %g1 ], %g2                               
4000f3b4:	80 a0 a0 00 	cmp  %g2, 0                                    
4000f3b8:	22 80 00 07 	be,a   4000f3d4 <_RBTree_Sibling+0x40>         
4000f3bc:	82 10 20 00 	clr  %g1                                       
                                                                      
  if(the_node == the_node->parent->child[RBT_LEFT])                   
4000f3c0:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
4000f3c4:	80 a2 00 02 	cmp  %o0, %g2                                  
4000f3c8:	32 80 00 03 	bne,a   4000f3d4 <_RBTree_Sibling+0x40>        
4000f3cc:	82 10 00 02 	mov  %g2, %g1                                  
4000f3d0:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
    return the_node->parent->child[RBT_RIGHT];                        
  else                                                                
    return the_node->parent->child[RBT_LEFT];                         
}                                                                     
4000f3d4:	81 c3 e0 08 	retl                                           
4000f3d8:	90 10 00 01 	mov  %g1, %o0                                  
                                                                      

4000d290 <_RTEMS_Tasks_Invoke_task_variable_dtor>: void _RTEMS_Tasks_Invoke_task_variable_dtor( Thread_Control *the_thread, rtems_task_variable_t *tvp ) {
4000d290:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  void (*dtor)(void *);                                               
  void *value;                                                        
                                                                      
  dtor = tvp->dtor;                                                   
  if (_Thread_Get_executing() == the_thread) {                        
4000d294:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        <== NOT EXECUTED
4000d298:	80 a0 80 18 	cmp  %g2, %i0                                  <== NOT EXECUTED
4000d29c:	12 80 00 07 	bne  4000d2b8 <_RTEMS_Tasks_Invoke_task_variable_dtor+0x28><== NOT EXECUTED
4000d2a0:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        <== NOT EXECUTED
    value = *tvp->ptr;                                                
4000d2a4:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           <== NOT EXECUTED
    *tvp->ptr = tvp->gval;                                            
4000d2a8:	c6 06 60 08 	ld  [ %i1 + 8 ], %g3                           <== NOT EXECUTED
  void (*dtor)(void *);                                               
  void *value;                                                        
                                                                      
  dtor = tvp->dtor;                                                   
  if (_Thread_Get_executing() == the_thread) {                        
    value = *tvp->ptr;                                                
4000d2ac:	d0 00 80 00 	ld  [ %g2 ], %o0                               <== NOT EXECUTED
4000d2b0:	10 80 00 03 	b  4000d2bc <_RTEMS_Tasks_Invoke_task_variable_dtor+0x2c><== NOT EXECUTED
4000d2b4:	c6 20 80 00 	st  %g3, [ %g2 ]                               <== NOT EXECUTED
    *tvp->ptr = tvp->gval;                                            
  } else {                                                            
    value = tvp->tval;                                                
4000d2b8:	d0 06 60 0c 	ld  [ %i1 + 0xc ], %o0                         <== NOT EXECUTED
  }                                                                   
                                                                      
  if ( dtor )                                                         
4000d2bc:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000d2c0:	02 80 00 04 	be  4000d2d0 <_RTEMS_Tasks_Invoke_task_variable_dtor+0x40><== NOT EXECUTED
4000d2c4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    (*dtor)(value);                                                   
4000d2c8:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
4000d2cc:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
  _Workspace_Free(tvp);                                               
4000d2d0:	7f ff f8 3b 	call  4000b3bc <_Workspace_Free>               <== NOT EXECUTED
4000d2d4:	91 e8 00 19 	restore  %g0, %i1, %o0                         <== NOT EXECUTED
                                                                      

4000d188 <_RTEMS_tasks_Switch_extension>: /* * Per Task Variables are only enabled in uniprocessor configurations */ tvp = executing->task_variables;
4000d188:	c2 02 21 34 	ld  [ %o0 + 0x134 ], %g1                       
  while (tvp) {                                                       
4000d18c:	80 a0 60 00 	cmp  %g1, 0                                    
4000d190:	22 80 00 09 	be,a   4000d1b4 <_RTEMS_tasks_Switch_extension+0x2c><== ALWAYS TAKEN
4000d194:	c2 02 61 34 	ld  [ %o1 + 0x134 ], %g1                       
    tvp->tval = *tvp->ptr;                                            
4000d198:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           <== NOT EXECUTED
4000d19c:	c6 00 80 00 	ld  [ %g2 ], %g3                               <== NOT EXECUTED
4000d1a0:	c6 20 60 0c 	st  %g3, [ %g1 + 0xc ]                         <== NOT EXECUTED
    *tvp->ptr = tvp->gval;                                            
4000d1a4:	c6 00 60 08 	ld  [ %g1 + 8 ], %g3                           <== NOT EXECUTED
4000d1a8:	c6 20 80 00 	st  %g3, [ %g2 ]                               <== NOT EXECUTED
    tvp = (rtems_task_variable_t *)tvp->next;                         
4000d1ac:	10 bf ff f8 	b  4000d18c <_RTEMS_tasks_Switch_extension+0x4><== NOT EXECUTED
4000d1b0:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
  }                                                                   
                                                                      
  tvp = heir->task_variables;                                         
  while (tvp) {                                                       
4000d1b4:	80 a0 60 00 	cmp  %g1, 0                                    
4000d1b8:	02 80 00 09 	be  4000d1dc <_RTEMS_tasks_Switch_extension+0x54><== ALWAYS TAKEN
4000d1bc:	01 00 00 00 	nop                                            
    tvp->gval = *tvp->ptr;                                            
4000d1c0:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           <== NOT EXECUTED
4000d1c4:	c6 00 80 00 	ld  [ %g2 ], %g3                               <== NOT EXECUTED
4000d1c8:	c6 20 60 08 	st  %g3, [ %g1 + 8 ]                           <== NOT EXECUTED
    *tvp->ptr = tvp->tval;                                            
4000d1cc:	c6 00 60 0c 	ld  [ %g1 + 0xc ], %g3                         <== NOT EXECUTED
4000d1d0:	c6 20 80 00 	st  %g3, [ %g2 ]                               <== NOT EXECUTED
    tvp = (rtems_task_variable_t *)tvp->next;                         
4000d1d4:	10 bf ff f8 	b  4000d1b4 <_RTEMS_tasks_Switch_extension+0x2c><== NOT EXECUTED
4000d1d8:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
  }                                                                   
}                                                                     
4000d1dc:	81 c3 e0 08 	retl                                           
                                                                      

4000d20c <_RTEMS_tasks_Terminate_extension>: } static void _RTEMS_tasks_Terminate_extension( Thread_Control *executing ) {
4000d20c:	9d e3 bf a0 	save  %sp, -96, %sp                            
   */                                                                 
  #if !defined(RTEMS_SMP)                                             
    do {                                                              
      rtems_task_variable_t *tvp, *next;                              
                                                                      
      tvp = executing->task_variables;                                
4000d210:	d2 06 21 34 	ld  [ %i0 + 0x134 ], %o1                       
      executing->task_variables = NULL;                               
4000d214:	c0 26 21 34 	clr  [ %i0 + 0x134 ]                           
      while (tvp) {                                                   
4000d218:	80 a2 60 00 	cmp  %o1, 0                                    
4000d21c:	02 80 00 07 	be  4000d238 <_RTEMS_tasks_Terminate_extension+0x2c><== ALWAYS TAKEN
4000d220:	01 00 00 00 	nop                                            
	next = (rtems_task_variable_t *)tvp->next;                           
4000d224:	fa 02 40 00 	ld  [ %o1 ], %i5                               <== NOT EXECUTED
	_RTEMS_Tasks_Invoke_task_variable_dtor( executing, tvp );            
4000d228:	40 00 00 1a 	call  4000d290 <_RTEMS_Tasks_Invoke_task_variable_dtor><== NOT EXECUTED
4000d22c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
	tvp = next;                                                          
4000d230:	10 bf ff fa 	b  4000d218 <_RTEMS_tasks_Terminate_extension+0xc><== NOT EXECUTED
4000d234:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
  #endif                                                              
                                                                      
  /*                                                                  
   *  Run all the key destructors                                     
   */                                                                 
  _POSIX_Keys_Run_destructors( executing );                           
4000d238:	40 00 06 6b 	call  4000ebe4 <_POSIX_Keys_Run_destructors>   
4000d23c:	81 e8 00 00 	restore                                        
                                                                      

40008148 <_Rate_monotonic_Get_status>: bool _Rate_monotonic_Get_status( Rate_monotonic_Control *the_period, Rate_monotonic_Period_time_t *wall_since_last_period, Thread_CPU_usage_t *cpu_since_last_period ) {
40008148:	9d e3 bf 98 	save  %sp, -104, %sp                           
 */                                                                   
static inline void _TOD_Get_uptime(                                   
  Timestamp_Control *time                                             
)                                                                     
{                                                                     
  _TOD_Get_with_nanoseconds( time, &_TOD.uptime );                    
4000814c:	13 10 00 68 	sethi  %hi(0x4001a000), %o1                    
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    Timestamp_Control        uptime;                                  
  #endif                                                              
    Thread_Control          *owning_thread = the_period->owner;       
40008150:	f6 06 20 40 	ld  [ %i0 + 0x40 ], %i3                        
40008154:	90 07 bf f8 	add  %fp, -8, %o0                              
40008158:	40 00 06 9f 	call  40009bd4 <_TOD_Get_with_nanoseconds>     
4000815c:	92 12 63 68 	or  %o1, 0x368, %o1                            
  /*                                                                  
   *  Determine elapsed wall time since period initiated.             
   */                                                                 
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    _TOD_Get_uptime( &uptime );                                       
    _Timestamp_Subtract(                                              
40008160:	c4 1f bf f8 	ldd  [ %fp + -8 ], %g2                         
  const Timestamp64_Control *_start,                                  
  const Timestamp64_Control *_end,                                    
  Timestamp64_Control       *_result                                  
)                                                                     
{                                                                     
  *_result = *_end - *_start;                                         
40008164:	f8 1e 20 50 	ldd  [ %i0 + 0x50 ], %i4                       
      if (used < the_period->cpu_usage_period_initiated)              
        return false;                                                 
                                                                      
      *cpu_since_last_period = used - the_period->cpu_usage_period_initiated;
  #endif                                                              
  return true;                                                        
40008168:	82 10 20 01 	mov  1, %g1                                    
4000816c:	ba a0 c0 1d 	subcc  %g3, %i5, %i5                           
40008170:	b8 60 80 1c 	subx  %g2, %i4, %i4                            
40008174:	f8 3e 40 00 	std  %i4, [ %i1 ]                              
   *  Determine cpu usage since period initiated.                     
   */                                                                 
  used = owning_thread->cpu_time_used;                                
                                                                      
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    if (owning_thread == _Thread_Executing) {                         
40008178:	fa 01 a0 18 	ld  [ %g6 + 0x18 ], %i5                        
4000817c:	80 a6 c0 1d 	cmp  %i3, %i5                                  
40008180:	12 80 00 15 	bne  400081d4 <_Rate_monotonic_Get_status+0x8c>
40008184:	d8 1e e0 80 	ldd  [ %i3 + 0x80 ], %o4                       
40008188:	f8 19 a0 20 	ldd  [ %g6 + 0x20 ], %i4                       
4000818c:	86 a0 c0 1d 	subcc  %g3, %i5, %g3                           
40008190:	84 60 80 1c 	subx  %g2, %i4, %g2                            
static inline void _Timestamp64_implementation_Add_to(                
  Timestamp64_Control       *_time,                                   
  const Timestamp64_Control *_add                                     
)                                                                     
{                                                                     
  *_time += *_add;                                                    
40008194:	ba 83 40 03 	addcc  %o5, %g3, %i5                           
40008198:	b8 43 00 02 	addx  %o4, %g2, %i4                            
                                                                      
      /*                                                              
       *  The cpu usage info was reset while executing.  Can't        
       *  determine a status.                                         
       */                                                             
      if (_Timestamp_Less_than(&used, &the_period->cpu_usage_period_initiated))
4000819c:	c4 1e 20 48 	ldd  [ %i0 + 0x48 ], %g2                       
400081a0:	80 a0 80 1c 	cmp  %g2, %i4                                  
400081a4:	34 80 00 0c 	bg,a   400081d4 <_Rate_monotonic_Get_status+0x8c><== NEVER TAKEN
400081a8:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
400081ac:	32 80 00 06 	bne,a   400081c4 <_Rate_monotonic_Get_status+0x7c>
400081b0:	86 a7 40 03 	subcc  %i5, %g3, %g3                           
400081b4:	80 a0 c0 1d 	cmp  %g3, %i5                                  
400081b8:	18 80 00 06 	bgu  400081d0 <_Rate_monotonic_Get_status+0x88>
400081bc:	86 a7 40 03 	subcc  %i5, %g3, %g3                           
      if (used < the_period->cpu_usage_period_initiated)              
        return false;                                                 
                                                                      
      *cpu_since_last_period = used - the_period->cpu_usage_period_initiated;
  #endif                                                              
  return true;                                                        
400081c0:	82 10 20 01 	mov  1, %g1                                    
  const Timestamp64_Control *_start,                                  
  const Timestamp64_Control *_end,                                    
  Timestamp64_Control       *_result                                  
)                                                                     
{                                                                     
  *_result = *_end - *_start;                                         
400081c4:	84 67 00 02 	subx  %i4, %g2, %g2                            
400081c8:	10 80 00 03 	b  400081d4 <_Rate_monotonic_Get_status+0x8c>  
400081cc:	c4 3e 80 00 	std  %g2, [ %i2 ]                              
      /*                                                              
       *  The cpu usage info was reset while executing.  Can't        
       *  determine a status.                                         
       */                                                             
      if (_Timestamp_Less_than(&used, &the_period->cpu_usage_period_initiated))
        return false;                                                 
400081d0:	82 10 20 00 	clr  %g1                                       
        return false;                                                 
                                                                      
      *cpu_since_last_period = used - the_period->cpu_usage_period_initiated;
  #endif                                                              
  return true;                                                        
}                                                                     
400081d4:	b0 08 60 01 	and  %g1, 1, %i0                               
400081d8:	81 c7 e0 08 	ret                                            
400081dc:	81 e8 00 00 	restore                                        
                                                                      

400087fc <_Rate_monotonic_Timeout>: void _Rate_monotonic_Timeout( Objects_Id id, void *ignored ) {
400087fc:	9d e3 bf 98 	save  %sp, -104, %sp                           
40008800:	11 10 00 68 	sethi  %hi(0x4001a000), %o0                    
40008804:	92 10 00 18 	mov  %i0, %o1                                  
40008808:	90 12 22 a0 	or  %o0, 0x2a0, %o0                            
4000880c:	40 00 08 15 	call  4000a860 <_Objects_Get>                  
40008810:	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 ) {                                               
40008814:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40008818:	80 a0 60 00 	cmp  %g1, 0                                    
4000881c:	12 80 00 23 	bne  400088a8 <_Rate_monotonic_Timeout+0xac>   <== NEVER TAKEN
40008820:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    case OBJECTS_LOCAL:                                               
      the_thread = the_period->owner;                                 
40008824:	d0 02 20 40 	ld  [ %o0 + 0x40 ], %o0                        
      if ( _States_Is_waiting_for_period( the_thread->current_state ) &&
40008828:	03 00 00 10 	sethi  %hi(0x4000), %g1                        
 */                                                                   
RTEMS_INLINE_ROUTINE bool _States_Is_waiting_for_period (             
  States_Control the_states                                           
)                                                                     
{                                                                     
   return (the_states & STATES_WAITING_FOR_PERIOD);                   
4000882c:	c4 02 20 10 	ld  [ %o0 + 0x10 ], %g2                        
40008830:	80 88 80 01 	btst  %g2, %g1                                 
40008834:	22 80 00 0b 	be,a   40008860 <_Rate_monotonic_Timeout+0x64> 
40008838:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
4000883c:	c4 02 20 20 	ld  [ %o0 + 0x20 ], %g2                        
40008840:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
40008844:	80 a0 80 01 	cmp  %g2, %g1                                  
40008848:	32 80 00 06 	bne,a   40008860 <_Rate_monotonic_Timeout+0x64>
4000884c:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
40008850:	13 04 03 ff 	sethi  %hi(0x100ffc00), %o1                    
40008854:	40 00 0a ce 	call  4000b38c <_Thread_Clear_state>           
40008858:	92 12 63 f8 	or  %o1, 0x3f8, %o1	! 100ffff8 <RAM_SIZE+0xfcffff8>
4000885c:	30 80 00 06 	b,a   40008874 <_Rate_monotonic_Timeout+0x78>  
        _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 ) {
40008860:	80 a0 60 01 	cmp  %g1, 1                                    
40008864:	12 80 00 0d 	bne  40008898 <_Rate_monotonic_Timeout+0x9c>   
40008868:	82 10 20 04 	mov  4, %g1                                    
        the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING;    
4000886c:	82 10 20 03 	mov  3, %g1                                    
40008870:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
                                                                      
        _Rate_monotonic_Initiate_statistics( the_period );            
40008874:	7f ff fe a4 	call  40008304 <_Rate_monotonic_Initiate_statistics>
40008878:	90 10 00 1d 	mov  %i5, %o0                                  
  Watchdog_Control      *the_watchdog,                                
  Watchdog_Interval      units                                        
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
4000887c:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
40008880:	11 10 00 69 	sethi  %hi(0x4001a400), %o0                    
  Watchdog_Control      *the_watchdog,                                
  Watchdog_Interval      units                                        
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
40008884:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
40008888:	90 12 20 10 	or  %o0, 0x10, %o0                             
4000888c:	40 00 0f fc 	call  4000c87c <_Watchdog_Insert>              
40008890:	92 07 60 10 	add  %i5, 0x10, %o1                            
40008894:	30 80 00 02 	b,a   4000889c <_Rate_monotonic_Timeout+0xa0>  
                                                                      
        _Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
      } else                                                          
        the_period->state = RATE_MONOTONIC_EXPIRED;                   
40008898:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
   *                                                                  
   * This routine decrements the thread dispatch level.               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4000889c:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable( level );                                            
#endif                                                                
                                                                      
    --disable_level;                                                  
400088a0:	84 00 bf ff 	add  %g2, -1, %g2                              
    _Thread_Dispatch_disable_level = disable_level;                   
400088a4:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
400088a8:	81 c7 e0 08 	ret                                            
400088ac:	81 e8 00 00 	restore                                        
                                                                      

400081e0 <_Rate_monotonic_Update_statistics>: } static void _Rate_monotonic_Update_statistics( Rate_monotonic_Control *the_period ) {
400081e0:	9d e3 bf 90 	save  %sp, -112, %sp                           
                                                                      
  /*                                                                  
   *  Update the counts.                                              
   */                                                                 
  stats = &the_period->Statistics;                                    
  stats->count++;                                                     
400081e4:	c2 06 20 58 	ld  [ %i0 + 0x58 ], %g1                        
400081e8:	82 00 60 01 	inc  %g1                                       
400081ec:	c2 26 20 58 	st  %g1, [ %i0 + 0x58 ]                        
                                                                      
  if ( the_period->state == RATE_MONOTONIC_EXPIRED )                  
400081f0:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
400081f4:	80 a0 60 04 	cmp  %g1, 4                                    
400081f8:	12 80 00 05 	bne  4000820c <_Rate_monotonic_Update_statistics+0x2c>
400081fc:	90 10 00 18 	mov  %i0, %o0                                  
    stats->missed_count++;                                            
40008200:	c2 06 20 5c 	ld  [ %i0 + 0x5c ], %g1                        
40008204:	82 00 60 01 	inc  %g1                                       
40008208:	c2 26 20 5c 	st  %g1, [ %i0 + 0x5c ]                        
                                                                      
  /*                                                                  
   *  Grab status for time statistics.                                
   */                                                                 
  valid_status =                                                      
4000820c:	92 07 bf f8 	add  %fp, -8, %o1                              
40008210:	7f ff ff ce 	call  40008148 <_Rate_monotonic_Get_status>    
40008214:	94 07 bf f0 	add  %fp, -16, %o2                             
    _Rate_monotonic_Get_status( the_period, &since_last_period, &executed );
  if (!valid_status)                                                  
40008218:	80 a2 20 00 	cmp  %o0, 0                                    
4000821c:	02 80 00 38 	be  400082fc <_Rate_monotonic_Update_statistics+0x11c>
40008220:	c4 1f bf f0 	ldd  [ %fp + -16 ], %g2                        
static inline void _Timestamp64_implementation_Add_to(                
  Timestamp64_Control       *_time,                                   
  const Timestamp64_Control *_add                                     
)                                                                     
{                                                                     
  *_time += *_add;                                                    
40008224:	f8 1e 20 70 	ldd  [ %i0 + 0x70 ], %i4                       
   *  Update CPU time                                                 
   */                                                                 
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    _Timestamp_Add_to( &stats->total_cpu_time, &executed );           
                                                                      
    if ( _Timestamp_Less_than( &executed, &stats->min_cpu_time ) )    
40008228:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1                        
4000822c:	b6 87 40 03 	addcc  %i5, %g3, %i3                           
40008230:	b4 47 00 02 	addx  %i4, %g2, %i2                            
40008234:	80 a0 40 02 	cmp  %g1, %g2                                  
40008238:	14 80 00 09 	bg  4000825c <_Rate_monotonic_Update_statistics+0x7c>
4000823c:	f4 3e 20 70 	std  %i2, [ %i0 + 0x70 ]                       
40008240:	80 a0 40 02 	cmp  %g1, %g2                                  
40008244:	32 80 00 08 	bne,a   40008264 <_Rate_monotonic_Update_statistics+0x84><== NEVER TAKEN
40008248:	c2 06 20 68 	ld  [ %i0 + 0x68 ], %g1                        <== NOT EXECUTED
4000824c:	c2 06 20 64 	ld  [ %i0 + 0x64 ], %g1                        
40008250:	80 a0 40 03 	cmp  %g1, %g3                                  
40008254:	28 80 00 04 	bleu,a   40008264 <_Rate_monotonic_Update_statistics+0x84>
40008258:	c2 06 20 68 	ld  [ %i0 + 0x68 ], %g1                        
      stats->min_cpu_time = executed;                                 
4000825c:	c4 3e 20 60 	std  %g2, [ %i0 + 0x60 ]                       
                                                                      
    if ( _Timestamp_Greater_than( &executed, &stats->max_cpu_time ) ) 
40008260:	c2 06 20 68 	ld  [ %i0 + 0x68 ], %g1                        
40008264:	80 a0 40 02 	cmp  %g1, %g2                                  
40008268:	26 80 00 0a 	bl,a   40008290 <_Rate_monotonic_Update_statistics+0xb0><== NEVER TAKEN
4000826c:	c4 3e 20 68 	std  %g2, [ %i0 + 0x68 ]                       <== NOT EXECUTED
40008270:	80 a0 40 02 	cmp  %g1, %g2                                  
40008274:	32 80 00 08 	bne,a   40008294 <_Rate_monotonic_Update_statistics+0xb4><== NEVER TAKEN
40008278:	c4 1f bf f8 	ldd  [ %fp + -8 ], %g2                         <== NOT EXECUTED
4000827c:	c2 06 20 6c 	ld  [ %i0 + 0x6c ], %g1                        
40008280:	80 a0 40 03 	cmp  %g1, %g3                                  
40008284:	3a 80 00 04 	bcc,a   40008294 <_Rate_monotonic_Update_statistics+0xb4>
40008288:	c4 1f bf f8 	ldd  [ %fp + -8 ], %g2                         
      stats->max_cpu_time = executed;                                 
4000828c:	c4 3e 20 68 	std  %g2, [ %i0 + 0x68 ]                       
                                                                      
  /*                                                                  
   *  Update Wall time                                                
   */                                                                 
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    _Timestamp_Add_to( &stats->total_wall_time, &since_last_period ); 
40008290:	c4 1f bf f8 	ldd  [ %fp + -8 ], %g2                         
40008294:	f8 1e 20 88 	ldd  [ %i0 + 0x88 ], %i4                       
                                                                      
    if ( _Timestamp_Less_than( &since_last_period, &stats->min_wall_time ) )
40008298:	c2 06 20 78 	ld  [ %i0 + 0x78 ], %g1                        
4000829c:	b6 87 40 03 	addcc  %i5, %g3, %i3                           
400082a0:	b4 47 00 02 	addx  %i4, %g2, %i2                            
400082a4:	80 a0 40 02 	cmp  %g1, %g2                                  
400082a8:	14 80 00 09 	bg  400082cc <_Rate_monotonic_Update_statistics+0xec>
400082ac:	f4 3e 20 88 	std  %i2, [ %i0 + 0x88 ]                       
400082b0:	80 a0 40 02 	cmp  %g1, %g2                                  
400082b4:	32 80 00 08 	bne,a   400082d4 <_Rate_monotonic_Update_statistics+0xf4><== NEVER TAKEN
400082b8:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        <== NOT EXECUTED
400082bc:	c2 06 20 7c 	ld  [ %i0 + 0x7c ], %g1                        
400082c0:	80 a0 40 03 	cmp  %g1, %g3                                  
400082c4:	28 80 00 04 	bleu,a   400082d4 <_Rate_monotonic_Update_statistics+0xf4>
400082c8:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        
      stats->min_wall_time = since_last_period;                       
400082cc:	c4 3e 20 78 	std  %g2, [ %i0 + 0x78 ]                       
                                                                      
    if ( _Timestamp_Greater_than( &since_last_period, &stats->max_wall_time ) )
400082d0:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        
400082d4:	80 a0 40 02 	cmp  %g1, %g2                                  
400082d8:	26 80 00 09 	bl,a   400082fc <_Rate_monotonic_Update_statistics+0x11c><== NEVER TAKEN
400082dc:	c4 3e 20 80 	std  %g2, [ %i0 + 0x80 ]                       <== NOT EXECUTED
400082e0:	80 a0 40 02 	cmp  %g1, %g2                                  
400082e4:	12 80 00 06 	bne  400082fc <_Rate_monotonic_Update_statistics+0x11c><== NEVER TAKEN
400082e8:	01 00 00 00 	nop                                            
400082ec:	c2 06 20 84 	ld  [ %i0 + 0x84 ], %g1                        
400082f0:	80 a0 40 03 	cmp  %g1, %g3                                  
400082f4:	2a 80 00 02 	bcs,a   400082fc <_Rate_monotonic_Update_statistics+0x11c>
400082f8:	c4 3e 20 80 	std  %g2, [ %i0 + 0x80 ]                       
400082fc:	81 c7 e0 08 	ret                                            
40008300:	81 e8 00 00 	restore                                        
                                                                      

4000b24c <_Scheduler_CBS_Attach_thread>: int _Scheduler_CBS_Attach_thread ( Scheduler_CBS_Server_id server_id, rtems_id task_id ) {
4000b24c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Objects_Locations location;                                         
  Thread_Control *the_thread;                                         
                                                                      
  if ( server_id >= _Scheduler_CBS_Maximum_servers )                  
4000b250:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
4000b254:	c2 00 62 a0 	ld  [ %g1 + 0x2a0 ], %g1	! 40017ea0 <_Scheduler_CBS_Maximum_servers>
4000b258:	80 a6 00 01 	cmp  %i0, %g1                                  
4000b25c:	0a 80 00 04 	bcs  4000b26c <_Scheduler_CBS_Attach_thread+0x20>
4000b260:	83 2e 20 02 	sll  %i0, 2, %g1                               
    return SCHEDULER_CBS_ERROR_INVALID_PARAMETER;                     
4000b264:	81 c7 e0 08 	ret                                            
4000b268:	91 e8 3f ee 	restore  %g0, -18, %o0                         
                                                                      
  /* Server is not valid. */                                          
  if ( !_Scheduler_CBS_Server_list[server_id].initialized )           
4000b26c:	3b 10 00 67 	sethi  %hi(0x40019c00), %i5                    
4000b270:	b1 2e 20 04 	sll  %i0, 4, %i0                               
4000b274:	ba 17 63 20 	or  %i5, 0x320, %i5                            
4000b278:	b0 00 40 18 	add  %g1, %i0, %i0                             
4000b27c:	b8 07 40 18 	add  %i5, %i0, %i4                             
4000b280:	c2 0f 20 10 	ldub  [ %i4 + 0x10 ], %g1                      
4000b284:	80 a0 60 00 	cmp  %g1, 0                                    
4000b288:	02 80 00 1f 	be  4000b304 <_Scheduler_CBS_Attach_thread+0xb8>
4000b28c:	01 00 00 00 	nop                                            
    return SCHEDULER_CBS_ERROR_NOSERVER;                              
                                                                      
  /* Server is already attached to a thread. */                       
  if ( _Scheduler_CBS_Server_list[server_id].task_id != -1 )          
4000b290:	c2 07 40 18 	ld  [ %i5 + %i0 ], %g1                         
4000b294:	80 a0 7f ff 	cmp  %g1, -1                                   
4000b298:	12 80 00 1d 	bne  4000b30c <_Scheduler_CBS_Attach_thread+0xc0>
4000b29c:	90 10 00 19 	mov  %i1, %o0                                  
    return SCHEDULER_CBS_ERROR_FULL;                                  
                                                                      
  the_thread = _Thread_Get(task_id, &location);                       
4000b2a0:	40 00 03 95 	call  4000c0f4 <_Thread_Get>                   
4000b2a4:	92 07 bf fc 	add  %fp, -4, %o1                              
  /* The routine _Thread_Get may disable dispatch and not enable again. */
  if ( the_thread ) {                                                 
4000b2a8:	80 a2 20 00 	cmp  %o0, 0                                    
4000b2ac:	02 bf ff ee 	be  4000b264 <_Scheduler_CBS_Attach_thread+0x18>
4000b2b0:	01 00 00 00 	nop                                            
 *                                                                    
 * @{                                                                 
 */                                                                   
                                                                      
RTEMS_INLINE_ROUTINE Scheduler_CBS_Node *_Scheduler_CBS_Node_get(     
  Thread_Control *the_thread                                          
4000b2b4:	c2 02 20 88 	ld  [ %o0 + 0x88 ], %g1                        
    Scheduler_CBS_Node *node = _Scheduler_CBS_Node_get( the_thread ); 
                                                                      
    /* Thread is already attached to a server. */                     
    if ( node->cbs_server ) {                                         
4000b2b8:	c4 00 60 18 	ld  [ %g1 + 0x18 ], %g2                        
4000b2bc:	80 a0 a0 00 	cmp  %g2, 0                                    
4000b2c0:	22 80 00 05 	be,a   4000b2d4 <_Scheduler_CBS_Attach_thread+0x88><== ALWAYS TAKEN
4000b2c4:	f2 27 40 18 	st  %i1, [ %i5 + %i0 ]                         
RTEMS_INLINE_ROUTINE void _Objects_Put(                               
  Objects_Control *the_object                                         
)                                                                     
{                                                                     
  (void) the_object;                                                  
  _Thread_Enable_dispatch();                                          
4000b2c8:	40 00 03 80 	call  4000c0c8 <_Thread_Enable_dispatch>       <== NOT EXECUTED
4000b2cc:	b0 10 3f e6 	mov  -26, %i0                                  <== NOT EXECUTED
4000b2d0:	30 80 00 10 	b,a   4000b310 <_Scheduler_CBS_Attach_thread+0xc4><== NOT EXECUTED
      _Objects_Put( &the_thread->Object );                            
      return SCHEDULER_CBS_ERROR_FULL;                                
    }                                                                 
                                                                      
    _Scheduler_CBS_Server_list[server_id].task_id = task_id;          
    node->cbs_server = &_Scheduler_CBS_Server_list[server_id];        
4000b2d4:	f8 20 60 18 	st  %i4, [ %g1 + 0x18 ]                        
                                                                      
    the_thread->budget_callout   = _Scheduler_CBS_Budget_callout;     
4000b2d8:	03 10 00 2d 	sethi  %hi(0x4000b400), %g1                    
4000b2dc:	82 10 63 84 	or  %g1, 0x384, %g1	! 4000b784 <_Scheduler_CBS_Budget_callout>
4000b2e0:	c2 22 20 7c 	st  %g1, [ %o0 + 0x7c ]                        
    the_thread->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_CALLOUT;
4000b2e4:	82 10 20 03 	mov  3, %g1                                    
4000b2e8:	c2 22 20 78 	st  %g1, [ %o0 + 0x78 ]                        
    the_thread->is_preemptible   = true;                              
4000b2ec:	82 10 20 01 	mov  1, %g1                                    
    _Objects_Put( &the_thread->Object );                              
  } else {                                                            
    return SCHEDULER_CBS_ERROR_INVALID_PARAMETER;                     
  }                                                                   
                                                                      
  return SCHEDULER_CBS_OK;                                            
4000b2f0:	b0 10 20 00 	clr  %i0                                       
4000b2f4:	40 00 03 75 	call  4000c0c8 <_Thread_Enable_dispatch>       
4000b2f8:	c2 2a 20 70 	stb  %g1, [ %o0 + 0x70 ]                       
4000b2fc:	81 c7 e0 08 	ret                                            
4000b300:	81 e8 00 00 	restore                                        
  if ( server_id >= _Scheduler_CBS_Maximum_servers )                  
    return SCHEDULER_CBS_ERROR_INVALID_PARAMETER;                     
                                                                      
  /* Server is not valid. */                                          
  if ( !_Scheduler_CBS_Server_list[server_id].initialized )           
    return SCHEDULER_CBS_ERROR_NOSERVER;                              
4000b304:	81 c7 e0 08 	ret                                            
4000b308:	91 e8 3f e7 	restore  %g0, -25, %o0                         
                                                                      
  /* Server is already attached to a thread. */                       
  if ( _Scheduler_CBS_Server_list[server_id].task_id != -1 )          
    return SCHEDULER_CBS_ERROR_FULL;                                  
4000b30c:	b0 10 3f e6 	mov  -26, %i0                                  
  } else {                                                            
    return SCHEDULER_CBS_ERROR_INVALID_PARAMETER;                     
  }                                                                   
                                                                      
  return SCHEDULER_CBS_OK;                                            
}                                                                     
4000b310:	81 c7 e0 08 	ret                                            
4000b314:	81 e8 00 00 	restore                                        
                                                                      

4000b784 <_Scheduler_CBS_Budget_callout>: #include <rtems/score/wkspace.h> void _Scheduler_CBS_Budget_callout( Thread_Control *the_thread ) {
4000b784:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Priority_Control          new_priority;                             
  Scheduler_CBS_Node       *node;                                     
  Scheduler_CBS_Server_id   server_id;                                
                                                                      
  /* Put violating task to background until the end of period. */     
  new_priority = the_thread->Start.initial_priority;                  
4000b788:	d2 06 20 ac 	ld  [ %i0 + 0xac ], %o1                        
  if ( the_thread->real_priority != new_priority )                    
4000b78c:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
4000b790:	80 a0 40 09 	cmp  %g1, %o1                                  
4000b794:	32 80 00 02 	bne,a   4000b79c <_Scheduler_CBS_Budget_callout+0x18><== ALWAYS TAKEN
4000b798:	d2 26 20 18 	st  %o1, [ %i0 + 0x18 ]                        
    the_thread->real_priority = new_priority;                         
  if ( the_thread->current_priority != new_priority )                 
4000b79c:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
4000b7a0:	80 a0 40 09 	cmp  %g1, %o1                                  
4000b7a4:	02 80 00 04 	be  4000b7b4 <_Scheduler_CBS_Budget_callout+0x30><== NEVER TAKEN
4000b7a8:	90 10 00 18 	mov  %i0, %o0                                  
    _Thread_Change_priority(the_thread, new_priority, true);          
4000b7ac:	40 00 01 5a 	call  4000bd14 <_Thread_Change_priority>       
4000b7b0:	94 10 20 01 	mov  1, %o2                                    
4000b7b4:	fa 06 20 88 	ld  [ %i0 + 0x88 ], %i5                        
                                                                      
  /* Invoke callback function if any. */                              
  node = _Scheduler_CBS_Node_get( the_thread );                       
  if ( node->cbs_server->cbs_budget_overrun ) {                       
4000b7b8:	c2 07 60 18 	ld  [ %i5 + 0x18 ], %g1                        
4000b7bc:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000b7c0:	80 a0 a0 00 	cmp  %g2, 0                                    
4000b7c4:	02 80 00 09 	be  4000b7e8 <_Scheduler_CBS_Budget_callout+0x64><== NEVER TAKEN
4000b7c8:	01 00 00 00 	nop                                            
    _Scheduler_CBS_Get_server_id(                                     
4000b7cc:	d0 00 40 00 	ld  [ %g1 ], %o0                               
4000b7d0:	7f ff ff d0 	call  4000b710 <_Scheduler_CBS_Get_server_id>  
4000b7d4:	92 07 bf fc 	add  %fp, -4, %o1                              
        node->cbs_server->task_id,                                    
        &server_id                                                    
    );                                                                
    node->cbs_server->cbs_budget_overrun( server_id );                
4000b7d8:	c2 07 60 18 	ld  [ %i5 + 0x18 ], %g1                        
4000b7dc:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
4000b7e0:	9f c0 40 00 	call  %g1                                      
4000b7e4:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
4000b7e8:	81 c7 e0 08 	ret                                            
4000b7ec:	81 e8 00 00 	restore                                        
                                                                      

4000a58c <_Scheduler_CBS_Release_job>: Thread_Control *the_thread, uint32_t deadline ) { Scheduler_CBS_Node *node = _Scheduler_CBS_Node_get( the_thread ); Scheduler_CBS_Server *serv_info = node->cbs_server;
4000a58c:	c2 02 60 88 	ld  [ %o1 + 0x88 ], %g1                        
void _Scheduler_CBS_Release_job(                                      
  const Scheduler_Control *scheduler,                                 
  Thread_Control          *the_thread,                                
  uint32_t                 deadline                                   
)                                                                     
{                                                                     
4000a590:	90 10 00 09 	mov  %o1, %o0                                  
  Scheduler_CBS_Node   *node = _Scheduler_CBS_Node_get( the_thread ); 
  Scheduler_CBS_Server *serv_info = node->cbs_server;                 
  Priority_Control      new_priority;                                 
                                                                      
  if (deadline) {                                                     
4000a594:	80 a2 a0 00 	cmp  %o2, 0                                    
4000a598:	02 80 00 0f 	be  4000a5d4 <_Scheduler_CBS_Release_job+0x48> 
4000a59c:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
4000a5a0:	05 10 00 61 	sethi  %hi(0x40018400), %g2                    
    /* Initializing or shifting deadline. */                          
    if (serv_info)                                                    
      new_priority = (_Watchdog_Ticks_since_boot + serv_info->parameters.deadline)
4000a5a4:	d2 00 a3 80 	ld  [ %g2 + 0x380 ], %o1	! 40018780 <_Watchdog_Ticks_since_boot>
  Scheduler_CBS_Server *serv_info = node->cbs_server;                 
  Priority_Control      new_priority;                                 
                                                                      
  if (deadline) {                                                     
    /* Initializing or shifting deadline. */                          
    if (serv_info)                                                    
4000a5a8:	80 a0 60 00 	cmp  %g1, 0                                    
4000a5ac:	02 80 00 07 	be  4000a5c8 <_Scheduler_CBS_Release_job+0x3c> 
4000a5b0:	94 02 80 09 	add  %o2, %o1, %o2                             
      new_priority = (_Watchdog_Ticks_since_boot + serv_info->parameters.deadline)
4000a5b4:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
4000a5b8:	92 02 40 02 	add  %o1, %g2, %o1                             
4000a5bc:	05 20 00 00 	sethi  %hi(0x80000000), %g2                    
4000a5c0:	10 80 00 08 	b  4000a5e0 <_Scheduler_CBS_Release_job+0x54>  
4000a5c4:	92 2a 40 02 	andn  %o1, %g2, %o1                            
        & ~SCHEDULER_EDF_PRIO_MSB;                                    
    else                                                              
      new_priority = (_Watchdog_Ticks_since_boot + deadline)          
4000a5c8:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
4000a5cc:	10 80 00 07 	b  4000a5e8 <_Scheduler_CBS_Release_job+0x5c>  
4000a5d0:	92 2a 80 09 	andn  %o2, %o1, %o1                            
    /* Switch back to background priority. */                         
    new_priority = the_thread->Start.initial_priority;                
  }                                                                   
                                                                      
  /* Budget replenishment for the next job. */                        
  if (serv_info)                                                      
4000a5d4:	80 a0 60 00 	cmp  %g1, 0                                    
4000a5d8:	02 80 00 04 	be  4000a5e8 <_Scheduler_CBS_Release_job+0x5c> <== NEVER TAKEN
4000a5dc:	d2 02 60 ac 	ld  [ %o1 + 0xac ], %o1                        
    the_thread->cpu_time_budget = serv_info->parameters.budget;       
4000a5e0:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
4000a5e4:	c2 22 20 74 	st  %g1, [ %o0 + 0x74 ]                        
                                                                      
  the_thread->real_priority = new_priority;                           
4000a5e8:	d2 22 20 18 	st  %o1, [ %o0 + 0x18 ]                        
  _Thread_Change_priority(the_thread, new_priority, true);            
4000a5ec:	94 10 20 01 	mov  1, %o2                                    
4000a5f0:	82 13 c0 00 	mov  %o7, %g1                                  
4000a5f4:	40 00 01 0e 	call  4000aa2c <_Thread_Change_priority>       
4000a5f8:	9e 10 40 00 	mov  %g1, %o7                                  
                                                                      

4000a5fc <_Scheduler_CBS_Unblock>: void _Scheduler_CBS_Unblock( const Scheduler_Control *scheduler, Thread_Control *the_thread ) {
4000a5fc:	9d e3 bf a0 	save  %sp, -96, %sp                            
4000a600:	f8 06 60 88 	ld  [ %i1 + 0x88 ], %i4                        
{                                                                     
  Scheduler_EDF_Context *context =                                    
    _Scheduler_EDF_Get_context( scheduler );                          
  Scheduler_EDF_Node *node = _Scheduler_EDF_Node_get( the_thread );   
                                                                      
  _RBTree_Insert( &context->Ready, &node->Node );                     
4000a604:	d0 06 00 00 	ld  [ %i0 ], %o0                               
  Scheduler_CBS_Node   *node = _Scheduler_CBS_Node_get( the_thread ); 
  Scheduler_CBS_Server *serv_info = node->cbs_server;                 
4000a608:	fa 07 20 18 	ld  [ %i4 + 0x18 ], %i5                        
4000a60c:	7f ff ff 53 	call  4000a358 <_RBTree_Insert>                
4000a610:	92 07 20 04 	add  %i4, 4, %o1                               
  node->queue_state = SCHEDULER_EDF_QUEUE_STATE_YES;                  
4000a614:	82 10 20 01 	mov  1, %g1                                    
   * Late unblock rule for deadline-driven tasks. The remaining time to
   * deadline must be sufficient to serve the remaining computation time
   * without increased utilization of this task. It might cause a deadline
   * miss of another task.                                            
   */                                                                 
  if (serv_info) {                                                    
4000a618:	80 a7 60 00 	cmp  %i5, 0                                    
4000a61c:	02 80 00 19 	be  4000a680 <_Scheduler_CBS_Unblock+0x84>     
4000a620:	c2 27 20 14 	st  %g1, [ %i4 + 0x14 ]                        
    time_t deadline = serv_info->parameters.deadline;                 
    time_t budget = serv_info->parameters.budget;                     
    time_t deadline_left = the_thread->cpu_time_budget;               
    time_t budget_left = the_thread->real_priority -                  
4000a624:	03 10 00 61 	sethi  %hi(0x40018400), %g1                    
                           _Watchdog_Ticks_since_boot;                
                                                                      
    if ( deadline*budget_left > budget*deadline_left ) {              
4000a628:	d2 07 60 04 	ld  [ %i5 + 4 ], %o1                           
   */                                                                 
  if (serv_info) {                                                    
    time_t deadline = serv_info->parameters.deadline;                 
    time_t budget = serv_info->parameters.budget;                     
    time_t deadline_left = the_thread->cpu_time_budget;               
    time_t budget_left = the_thread->real_priority -                  
4000a62c:	d0 00 63 80 	ld  [ %g1 + 0x380 ], %o0                       
4000a630:	f8 06 60 18 	ld  [ %i1 + 0x18 ], %i4                        
                           _Watchdog_Ticks_since_boot;                
                                                                      
    if ( deadline*budget_left > budget*deadline_left ) {              
4000a634:	40 00 27 98 	call  40014494 <.umul>                         
4000a638:	90 27 00 08 	sub  %i4, %o0, %o0                             
4000a63c:	d2 06 60 74 	ld  [ %i1 + 0x74 ], %o1                        
4000a640:	b6 10 00 08 	mov  %o0, %i3                                  
4000a644:	40 00 27 94 	call  40014494 <.umul>                         
4000a648:	d0 07 60 08 	ld  [ %i5 + 8 ], %o0                           
4000a64c:	80 a6 c0 08 	cmp  %i3, %o0                                  
4000a650:	24 80 00 0d 	ble,a   4000a684 <_Scheduler_CBS_Unblock+0x88> 
4000a654:	c4 01 a0 1c 	ld  [ %g6 + 0x1c ], %g2                        
      /* Put late unblocked task to background until the end of period. */
      new_priority = the_thread->Start.initial_priority;              
4000a658:	d2 06 60 ac 	ld  [ %i1 + 0xac ], %o1                        
      if ( the_thread->real_priority != new_priority )                
4000a65c:	80 a7 00 09 	cmp  %i4, %o1                                  
4000a660:	32 80 00 02 	bne,a   4000a668 <_Scheduler_CBS_Unblock+0x6c> 
4000a664:	d2 26 60 18 	st  %o1, [ %i1 + 0x18 ]                        
        the_thread->real_priority = new_priority;                     
      if ( the_thread->current_priority != new_priority )             
4000a668:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        
4000a66c:	80 a0 40 09 	cmp  %g1, %o1                                  
4000a670:	02 80 00 04 	be  4000a680 <_Scheduler_CBS_Unblock+0x84>     
4000a674:	90 10 00 19 	mov  %i1, %o0                                  
        _Thread_Change_priority(the_thread, new_priority, true);      
4000a678:	40 00 00 ed 	call  4000aa2c <_Thread_Change_priority>       
4000a67c:	94 10 20 01 	mov  1, %o2                                    
   *  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 (                                                                
    _Scheduler_Is_priority_higher_than(                               
4000a680:	c4 01 a0 1c 	ld  [ %g6 + 0x1c ], %g2                        
  const Scheduler_Control *scheduler,                                 
  Priority_Control         p1,                                        
  Priority_Control         p2                                         
)                                                                     
{                                                                     
  return ( *scheduler->Operations.priority_compare )( p1, p2 );       
4000a684:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
4000a688:	d0 06 60 14 	ld  [ %i1 + 0x14 ], %o0                        
4000a68c:	9f c0 40 00 	call  %g1                                      
4000a690:	d2 00 a0 14 	ld  [ %g2 + 0x14 ], %o1                        
   *    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 (                                                                
4000a694:	80 a2 20 00 	cmp  %o0, 0                                    
4000a698:	04 80 00 0e 	ble  4000a6d0 <_Scheduler_CBS_Unblock+0xd4>    
4000a69c:	01 00 00 00 	nop                                            
       the_thread->current_priority,                                  
       _Thread_Heir->current_priority                                 
    )                                                                 
  ) {                                                                 
    _Thread_Heir = the_thread;                                        
    if ( _Thread_Executing->is_preemptible ||                         
4000a6a0:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
       scheduler,                                                     
       the_thread->current_priority,                                  
       _Thread_Heir->current_priority                                 
    )                                                                 
  ) {                                                                 
    _Thread_Heir = the_thread;                                        
4000a6a4:	f2 21 a0 1c 	st  %i1, [ %g6 + 0x1c ]                        
    if ( _Thread_Executing->is_preemptible ||                         
4000a6a8:	c4 08 a0 70 	ldub  [ %g2 + 0x70 ], %g2                      
4000a6ac:	80 a0 a0 00 	cmp  %g2, 0                                    
4000a6b0:	12 80 00 06 	bne  4000a6c8 <_Scheduler_CBS_Unblock+0xcc>    
4000a6b4:	82 10 00 06 	mov  %g6, %g1                                  
4000a6b8:	c4 06 60 14 	ld  [ %i1 + 0x14 ], %g2                        
4000a6bc:	80 a0 a0 00 	cmp  %g2, 0                                    
4000a6c0:	12 80 00 04 	bne  4000a6d0 <_Scheduler_CBS_Unblock+0xd4>    <== ALWAYS TAKEN
4000a6c4:	01 00 00 00 	nop                                            
         the_thread->current_priority == 0 )                          
      _Thread_Dispatch_necessary = true;                              
4000a6c8:	84 10 20 01 	mov  1, %g2	! 1 <_TLS_Alignment>               
4000a6cc:	c4 28 60 14 	stb  %g2, [ %g1 + 0x14 ]                       
4000a6d0:	81 c7 e0 08 	ret                                            
4000a6d4:	81 e8 00 00 	restore                                        
                                                                      

4000a7f8 <_Scheduler_EDF_Block>: void _Scheduler_EDF_Block( const Scheduler_Control *scheduler, Thread_Control *the_thread ) {
4000a7f8:	9d e3 bf a0 	save  %sp, -96, %sp                            
                             const Scheduler_Control *,               
                             Thread_Control *,                        
                             bool )                                   
)                                                                     
{                                                                     
  ( *extract )( scheduler, the_thread );                              
4000a7fc:	90 10 00 18 	mov  %i0, %o0                                  
4000a800:	7f ff ff f8 	call  4000a7e0 <_Scheduler_EDF_Extract>        
4000a804:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  /* TODO: flash critical section? */                                 
                                                                      
  if ( _Thread_Is_executing( the_thread ) || _Thread_Is_heir( the_thread ) ) {
4000a808:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
4000a80c:	80 a6 40 02 	cmp  %i1, %g2                                  
4000a810:	02 80 00 06 	be  4000a828 <_Scheduler_EDF_Block+0x30>       
4000a814:	01 00 00 00 	nop                                            
4000a818:	c2 01 a0 1c 	ld  [ %g6 + 0x1c ], %g1                        
4000a81c:	80 a6 40 01 	cmp  %i1, %g1                                  
4000a820:	12 80 00 04 	bne  4000a830 <_Scheduler_EDF_Block+0x38>      <== ALWAYS TAKEN
4000a824:	01 00 00 00 	nop                                            
    ( *schedule )( scheduler, the_thread, true );                     
4000a828:	7f ff ff dd 	call  4000a79c <_Scheduler_EDF_Schedule_body>  
4000a82c:	95 e8 20 01 	restore  %g0, 1, %o2                           
4000a830:	81 c7 e0 08 	ret                                            
4000a834:	81 e8 00 00 	restore                                        
                                                                      

4000a8f0 <_Scheduler_EDF_Schedule>: RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_First( const RBTree_Control *the_rbtree, RBTree_Direction dir ) { return the_rbtree->first[dir];
4000a8f0:	c2 02 00 00 	ld  [ %o0 ], %g1                               
  Scheduler_EDF_Context *context =                                    
    _Scheduler_EDF_Get_context( scheduler );                          
  RBTree_Node *first = _RBTree_First( &context->Ready, RBT_LEFT );    
  Scheduler_EDF_Node *node =                                          
    _RBTree_Container_of(first, Scheduler_EDF_Node, Node);            
  Thread_Control *heir = node->thread;                                
4000a8f4:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
4000a8f8:	c4 00 7f fc 	ld  [ %g1 + -4 ], %g2                          
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
4000a8fc:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
4000a900:	80 a0 40 02 	cmp  %g1, %g2                                  
4000a904:	02 80 00 07 	be  4000a920 <_Scheduler_EDF_Schedule+0x30>    
4000a908:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
4000a90c:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      
4000a910:	80 a0 60 00 	cmp  %g1, 0                                    
4000a914:	02 80 00 03 	be  4000a920 <_Scheduler_EDF_Schedule+0x30>    <== NEVER TAKEN
4000a918:	84 10 20 01 	mov  1, %g2                                    
    _Thread_Dispatch_necessary = true;                                
4000a91c:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       
4000a920:	81 c3 e0 08 	retl                                           
                                                                      

4000a79c <_Scheduler_EDF_Schedule_body>: RTEMS_INLINE_ROUTINE RBTree_Node *_RBTree_First( const RBTree_Control *the_rbtree, RBTree_Direction dir ) { return the_rbtree->first[dir];
4000a79c:	c2 02 00 00 	ld  [ %o0 ], %g1                               
  Scheduler_EDF_Context *context =                                    
    _Scheduler_EDF_Get_context( scheduler );                          
  RBTree_Node *first = _RBTree_First( &context->Ready, RBT_LEFT );    
  Scheduler_EDF_Node *node =                                          
    _RBTree_Container_of(first, Scheduler_EDF_Node, Node);            
  Thread_Control *heir = node->thread;                                
4000a7a0:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
4000a7a4:	c4 00 7f fc 	ld  [ %g1 + -4 ], %g2                          
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
4000a7a8:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
4000a7ac:	80 a0 40 02 	cmp  %g1, %g2                                  
4000a7b0:	02 80 00 0a 	be  4000a7d8 <_Scheduler_EDF_Schedule_body+0x3c><== NEVER TAKEN
4000a7b4:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
4000a7b8:	80 a2 a0 00 	cmp  %o2, 0                                    
4000a7bc:	12 80 00 06 	bne  4000a7d4 <_Scheduler_EDF_Schedule_body+0x38><== ALWAYS TAKEN
4000a7c0:	84 10 20 01 	mov  1, %g2                                    
4000a7c4:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      <== NOT EXECUTED
4000a7c8:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000a7cc:	02 80 00 03 	be  4000a7d8 <_Scheduler_EDF_Schedule_body+0x3c><== NOT EXECUTED
4000a7d0:	01 00 00 00 	nop                                            <== NOT EXECUTED
    _Thread_Dispatch_necessary = true;                                
4000a7d4:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       
4000a7d8:	81 c3 e0 08 	retl                                           
                                                                      

4000a814 <_Scheduler_EDF_Unblock>: void _Scheduler_EDF_Unblock( const Scheduler_Control *scheduler, Thread_Control *the_thread ) {
4000a814:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
  return (Scheduler_EDF_Context *) _Scheduler_Get_context( scheduler );
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE Scheduler_EDF_Node *_Scheduler_EDF_Node_get(     
  Thread_Control *the_thread                                          
4000a818:	fa 06 60 88 	ld  [ %i1 + 0x88 ], %i5                        
{                                                                     
  Scheduler_EDF_Context *context =                                    
    _Scheduler_EDF_Get_context( scheduler );                          
  Scheduler_EDF_Node *node = _Scheduler_EDF_Node_get( the_thread );   
                                                                      
  _RBTree_Insert( &context->Ready, &node->Node );                     
4000a81c:	d0 06 00 00 	ld  [ %i0 ], %o0                               
4000a820:	7f ff fe ce 	call  4000a358 <_RBTree_Insert>                
4000a824:	92 07 60 04 	add  %i5, 4, %o1                               
   *    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 ( _Scheduler_Is_priority_lower_than(                             
4000a828:	c4 01 a0 1c 	ld  [ %g6 + 0x1c ], %g2                        
  node->queue_state = SCHEDULER_EDF_QUEUE_STATE_YES;                  
4000a82c:	82 10 20 01 	mov  1, %g1                                    
  const Scheduler_Control *scheduler,                                 
  Priority_Control         p1,                                        
  Priority_Control         p2                                         
)                                                                     
{                                                                     
  return ( *scheduler->Operations.priority_compare )( p1, p2 );       
4000a830:	d0 00 a0 14 	ld  [ %g2 + 0x14 ], %o0                        
4000a834:	c2 27 60 14 	st  %g1, [ %i5 + 0x14 ]                        
4000a838:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
4000a83c:	9f c0 40 00 	call  %g1                                      
4000a840:	d2 06 60 14 	ld  [ %i1 + 0x14 ], %o1                        
4000a844:	80 a2 20 00 	cmp  %o0, 0                                    
4000a848:	16 80 00 0e 	bge  4000a880 <_Scheduler_EDF_Unblock+0x6c>    
4000a84c:	01 00 00 00 	nop                                            
         scheduler,                                                   
         _Thread_Heir->current_priority,                              
         the_thread->current_priority )) {                            
    _Thread_Heir = the_thread;                                        
    if ( _Thread_Executing->is_preemptible ||                         
4000a850:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
   */                                                                 
  if ( _Scheduler_Is_priority_lower_than(                             
         scheduler,                                                   
         _Thread_Heir->current_priority,                              
         the_thread->current_priority )) {                            
    _Thread_Heir = the_thread;                                        
4000a854:	f2 21 a0 1c 	st  %i1, [ %g6 + 0x1c ]                        
    if ( _Thread_Executing->is_preemptible ||                         
4000a858:	c4 08 a0 70 	ldub  [ %g2 + 0x70 ], %g2                      
4000a85c:	80 a0 a0 00 	cmp  %g2, 0                                    
4000a860:	12 80 00 06 	bne  4000a878 <_Scheduler_EDF_Unblock+0x64>    
4000a864:	82 10 00 06 	mov  %g6, %g1                                  
4000a868:	c4 06 60 14 	ld  [ %i1 + 0x14 ], %g2                        
4000a86c:	80 a0 a0 00 	cmp  %g2, 0                                    
4000a870:	12 80 00 04 	bne  4000a880 <_Scheduler_EDF_Unblock+0x6c>    <== ALWAYS TAKEN
4000a874:	01 00 00 00 	nop                                            
         the_thread->current_priority == 0 )                          
      _Thread_Dispatch_necessary = true;                              
4000a878:	84 10 20 01 	mov  1, %g2	! 1 <_TLS_Alignment>               
4000a87c:	c4 28 60 14 	stb  %g2, [ %g1 + 0x14 ]                       
4000a880:	81 c7 e0 08 	ret                                            
4000a884:	81 e8 00 00 	restore                                        
                                                                      

4000a928 <_Scheduler_EDF_Update_priority>: { return (Scheduler_EDF_Context *) _Scheduler_Get_context( scheduler ); } RTEMS_INLINE_ROUTINE Scheduler_EDF_Node *_Scheduler_EDF_Node_get( Thread_Control *the_thread
4000a928:	c4 02 60 88 	ld  [ %o1 + 0x88 ], %g2                        
  Scheduler_EDF_Node *node = _Scheduler_EDF_Node_get( the_thread );   
                                                                      
  (void) scheduler;                                                   
  (void) new_priority;                                                
                                                                      
  if (node->queue_state == SCHEDULER_EDF_QUEUE_STATE_NEVER_HAS_BEEN) {
4000a92c:	c2 00 a0 14 	ld  [ %g2 + 0x14 ], %g1                        
4000a930:	80 a0 60 02 	cmp  %g1, 2                                    
4000a934:	12 80 00 08 	bne  4000a954 <_Scheduler_EDF_Update_priority+0x2c><== NEVER TAKEN
4000a938:	03 20 00 00 	sethi  %hi(0x80000000), %g1                    
    /* Shifts the priority to the region of background tasks. */      
    the_thread->Start.initial_priority |= (SCHEDULER_EDF_PRIO_MSB);   
4000a93c:	c6 02 60 ac 	ld  [ %o1 + 0xac ], %g3                        
4000a940:	82 10 c0 01 	or  %g3, %g1, %g1                              
4000a944:	c2 22 60 ac 	st  %g1, [ %o1 + 0xac ]                        
    the_thread->real_priority    = the_thread->Start.initial_priority;
4000a948:	c2 22 60 18 	st  %g1, [ %o1 + 0x18 ]                        
    the_thread->current_priority = the_thread->Start.initial_priority;
4000a94c:	c2 22 60 14 	st  %g1, [ %o1 + 0x14 ]                        
    node->queue_state = SCHEDULER_EDF_QUEUE_STATE_NOT_PRESENTLY;      
4000a950:	c0 20 a0 14 	clr  [ %g2 + 0x14 ]                            
4000a954:	81 c3 e0 08 	retl                                           
                                                                      

4000a95c <_Scheduler_EDF_Yield>: void _Scheduler_EDF_Yield( const Scheduler_Control *scheduler, Thread_Control *the_thread ) {
4000a95c:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
  /*                                                                  
   * The RBTree has more than one node, enqueue behind the tasks      
   * with the same priority in case there are such ones.              
   */                                                                 
  _RBTree_Extract( &context->Ready, &node->Node );                    
4000a960:	fa 06 00 00 	ld  [ %i0 ], %i5                               
4000a964:	f8 06 60 88 	ld  [ %i1 + 0x88 ], %i4                        
4000a968:	90 10 00 1d 	mov  %i5, %o0                                  
4000a96c:	b8 07 20 04 	add  %i4, 4, %i4                               
4000a970:	40 00 10 7b 	call  4000eb5c <_RBTree_Extract>               
4000a974:	92 10 00 1c 	mov  %i4, %o1                                  
  _RBTree_Insert( &context->Ready, &node->Node );                     
4000a978:	90 10 00 1d 	mov  %i5, %o0                                  
4000a97c:	7f ff fe 77 	call  4000a358 <_RBTree_Insert>                
4000a980:	92 10 00 1c 	mov  %i4, %o1                                  
4000a984:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  Scheduler_EDF_Context *context =                                    
    _Scheduler_EDF_Get_context( scheduler );                          
  RBTree_Node *first = _RBTree_First( &context->Ready, RBT_LEFT );    
  Scheduler_EDF_Node *node =                                          
    _RBTree_Container_of(first, Scheduler_EDF_Node, Node);            
  Thread_Control *heir = node->thread;                                
4000a988:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
4000a98c:	c4 00 7f fc 	ld  [ %g1 + -4 ], %g2                          
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
4000a990:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
4000a994:	80 a0 40 02 	cmp  %g1, %g2                                  
4000a998:	02 80 00 07 	be  4000a9b4 <_Scheduler_EDF_Yield+0x58>       <== NEVER TAKEN
4000a99c:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
4000a9a0:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      
4000a9a4:	80 a0 60 00 	cmp  %g1, 0                                    
4000a9a8:	02 80 00 03 	be  4000a9b4 <_Scheduler_EDF_Yield+0x58>       <== ALWAYS TAKEN
4000a9ac:	84 10 20 01 	mov  1, %g2                                    
    _Thread_Dispatch_necessary = true;                                
4000a9b0:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       <== NOT EXECUTED
4000a9b4:	81 c7 e0 08 	ret                                            
4000a9b8:	81 e8 00 00 	restore                                        
                                                                      

40009418 <_Scheduler_default_Tick>: void _Scheduler_default_Tick( const Scheduler_Control *scheduler, Thread_Control *executing ) {
40009418:	9d e3 bf a0 	save  %sp, -96, %sp                            
  /*                                                                  
   *  If the thread is not preemptible or is not ready, then          
   *  just return.                                                    
   */                                                                 
                                                                      
  if ( !executing->is_preemptible )                                   
4000941c:	c2 0e 60 70 	ldub  [ %i1 + 0x70 ], %g1                      
40009420:	80 a0 60 00 	cmp  %g1, 0                                    
40009424:	02 80 00 23 	be  400094b0 <_Scheduler_default_Tick+0x98>    
40009428:	01 00 00 00 	nop                                            
    return;                                                           
                                                                      
  if ( !_States_Is_ready( executing->current_state ) )                
4000942c:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
40009430:	80 a0 60 00 	cmp  %g1, 0                                    
40009434:	12 80 00 1f 	bne  400094b0 <_Scheduler_default_Tick+0x98>   
40009438:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   *  The cpu budget algorithm determines what happens next.          
   */                                                                 
                                                                      
  switch ( executing->budget_algorithm ) {                            
4000943c:	c2 06 60 78 	ld  [ %i1 + 0x78 ], %g1                        
40009440:	80 a0 60 01 	cmp  %g1, 1                                    
40009444:	0a 80 00 06 	bcs  4000945c <_Scheduler_default_Tick+0x44>   
40009448:	80 a0 60 02 	cmp  %g1, 2                                    
4000944c:	08 80 00 06 	bleu  40009464 <_Scheduler_default_Tick+0x4c>  
40009450:	80 a0 60 03 	cmp  %g1, 3                                    
40009454:	22 80 00 10 	be,a   40009494 <_Scheduler_default_Tick+0x7c> <== ALWAYS TAKEN
40009458:	c2 06 60 74 	ld  [ %i1 + 0x74 ], %g1                        
4000945c:	81 c7 e0 08 	ret                                            
40009460:	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 ) {               
40009464:	c2 06 60 74 	ld  [ %i1 + 0x74 ], %g1                        
40009468:	82 00 7f ff 	add  %g1, -1, %g1                              
4000946c:	80 a0 60 00 	cmp  %g1, 0                                    
40009470:	14 bf ff fb 	bg  4000945c <_Scheduler_default_Tick+0x44>    
40009474:	c2 26 60 74 	st  %g1, [ %i1 + 0x74 ]                        
         *  at the priority of the currently executing thread, then the
         *  executing thread's timeslice is reset.  Otherwise, the    
         *  currently executing thread is placed at the rear of the   
         *  FIFO for this priority and a new heir is selected.        
         */                                                           
        _Thread_Yield( executing );                                   
40009478:	40 00 06 12 	call  4000acc0 <_Thread_Yield>                 
4000947c:	90 10 00 19 	mov  %i1, %o0                                  
        executing->cpu_time_budget =                                  
          rtems_configuration_get_ticks_per_timeslice();              
40009480:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
         *  executing thread's timeslice is reset.  Otherwise, the    
         *  currently executing thread is placed at the rear of the   
         *  FIFO for this priority and a new heir is selected.        
         */                                                           
        _Thread_Yield( executing );                                   
        executing->cpu_time_budget =                                  
40009484:	c2 00 61 a4 	ld  [ %g1 + 0x1a4 ], %g1	! 400155a4 <Configuration+0x1c>
40009488:	c2 26 60 74 	st  %g1, [ %i1 + 0x74 ]                        
4000948c:	81 c7 e0 08 	ret                                            
40009490:	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 )                             
40009494:	82 00 7f ff 	add  %g1, -1, %g1                              
40009498:	80 a0 60 00 	cmp  %g1, 0                                    
4000949c:	12 bf ff f0 	bne  4000945c <_Scheduler_default_Tick+0x44>   
400094a0:	c2 26 60 74 	st  %g1, [ %i1 + 0x74 ]                        
	  (*executing->budget_callout)( executing );                         
400094a4:	c2 06 60 7c 	ld  [ %i1 + 0x7c ], %g1                        
400094a8:	9f c0 40 00 	call  %g1                                      
400094ac:	90 10 00 19 	mov  %i1, %o0                                  
400094b0:	81 c7 e0 08 	ret                                            
400094b4:	81 e8 00 00 	restore                                        
                                                                      

400094d8 <_Scheduler_priority_Schedule_body>: * @addtogroup ScoreSchedulerDPS */ /**@{**/ RTEMS_INLINE_ROUTINE Scheduler_priority_Context * _Scheduler_priority_Get_context( const Scheduler_Control *scheduler )
400094d8:	c4 02 00 00 	ld  [ %o0 ], %g2                               
400094dc:	03 10 00 59 	sethi  %hi(0x40016400), %g1                    
                                                                      
  /* Avoid problems with some inline ASM statements */                
  Priority_bit_map_Word tmp;                                          
                                                                      
  tmp = bit_map->major_bit_map;                                       
  _Bitfield_Find_first_bit( tmp, major );                             
400094e0:	c6 10 80 00 	lduh  [ %g2 ], %g3                             
  bool                     force_dispatch                             
)                                                                     
{                                                                     
  Scheduler_priority_Context *context =                               
    _Scheduler_priority_Get_context( scheduler );                     
  Thread_Control *heir = _Scheduler_priority_Ready_queue_first(       
400094e4:	9a 00 a0 24 	add  %g2, 0x24, %o5                            
400094e8:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
400094ec:	89 30 e0 10 	srl  %g3, 0x10, %g4                            
400094f0:	80 a1 20 ff 	cmp  %g4, 0xff                                 
400094f4:	18 80 00 05 	bgu  40009508 <_Scheduler_priority_Schedule_body+0x30>
400094f8:	82 10 61 48 	or  %g1, 0x148, %g1                            
400094fc:	c6 08 40 04 	ldub  [ %g1 + %g4 ], %g3                       
40009500:	10 80 00 04 	b  40009510 <_Scheduler_priority_Schedule_body+0x38>
40009504:	86 00 e0 08 	add  %g3, 8, %g3                               
40009508:	87 30 e0 18 	srl  %g3, 0x18, %g3                            
4000950c:	c6 08 40 03 	ldub  [ %g1 + %g3 ], %g3                       
                                                                      
  tmp = bit_map->bit_map[ major ];                                    
40009510:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40009514:	89 30 e0 0f 	srl  %g3, 0xf, %g4                             
40009518:	84 00 80 04 	add  %g2, %g4, %g2                             
  _Bitfield_Find_first_bit( tmp, minor );                             
4000951c:	c4 10 a0 02 	lduh  [ %g2 + 2 ], %g2                         
40009520:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40009524:	89 30 a0 10 	srl  %g2, 0x10, %g4                            
40009528:	80 a1 20 ff 	cmp  %g4, 0xff                                 
4000952c:	18 80 00 05 	bgu  40009540 <_Scheduler_priority_Schedule_body+0x68>
40009530:	85 30 a0 18 	srl  %g2, 0x18, %g2                            
40009534:	c2 08 40 04 	ldub  [ %g1 + %g4 ], %g1                       
40009538:	10 80 00 03 	b  40009544 <_Scheduler_priority_Schedule_body+0x6c>
4000953c:	82 00 60 08 	add  %g1, 8, %g1                               
40009540:	c2 08 40 02 	ldub  [ %g1 + %g2 ], %g1                       
                                                                      
  return (_Priority_Bits_index( major ) << 4) +                       
          _Priority_Bits_index( minor );                              
40009544:	83 28 60 10 	sll  %g1, 0x10, %g1                            
  _Bitfield_Find_first_bit( tmp, major );                             
                                                                      
  tmp = bit_map->bit_map[ major ];                                    
  _Bitfield_Find_first_bit( tmp, minor );                             
                                                                      
  return (_Priority_Bits_index( major ) << 4) +                       
40009548:	87 30 e0 0c 	srl  %g3, 0xc, %g3                             
          _Priority_Bits_index( minor );                              
4000954c:	83 30 60 10 	srl  %g1, 0x10, %g1                            
  Chain_Control            *ready_queues                              
)                                                                     
{                                                                     
  Priority_Control index = _Priority_bit_map_Get_highest( bit_map );  
                                                                      
  return (Thread_Control *) _Chain_First( &ready_queues[ index ] );   
40009550:	82 00 40 03 	add  %g1, %g3, %g1                             
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
40009554:	85 28 60 02 	sll  %g1, 2, %g2                               
40009558:	83 28 60 04 	sll  %g1, 4, %g1                               
4000955c:	82 20 40 02 	sub  %g1, %g2, %g1                             
40009560:	c4 03 40 01 	ld  [ %o5 + %g1 ], %g2                         
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
40009564:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
40009568:	80 a0 40 02 	cmp  %g1, %g2                                  
4000956c:	02 80 00 0a 	be  40009594 <_Scheduler_priority_Schedule_body+0xbc>
40009570:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
40009574:	80 a2 a0 00 	cmp  %o2, 0                                    
40009578:	12 80 00 06 	bne  40009590 <_Scheduler_priority_Schedule_body+0xb8><== ALWAYS TAKEN
4000957c:	84 10 20 01 	mov  1, %g2                                    
40009580:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      <== NOT EXECUTED
40009584:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40009588:	02 80 00 03 	be  40009594 <_Scheduler_priority_Schedule_body+0xbc><== NOT EXECUTED
4000958c:	01 00 00 00 	nop                                            <== NOT EXECUTED
    _Thread_Dispatch_necessary = true;                                
40009590:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       
40009594:	81 c3 e0 08 	retl                                           
                                                                      

4000a1b0 <_Scheduler_simple_Block>: ) { Chain_Node *next; Chain_Node *previous; next = the_node->next;
4000a1b0:	c4 02 40 00 	ld  [ %o1 ], %g2                               
  previous       = the_node->previous;                                
4000a1b4:	c2 02 60 04 	ld  [ %o1 + 4 ], %g1                           
  next->previous = previous;                                          
4000a1b8:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4000a1bc:	c4 20 40 00 	st  %g2, [ %g1 ]                               
{                                                                     
  ( *extract )( scheduler, the_thread );                              
                                                                      
  /* TODO: flash critical section? */                                 
                                                                      
  if ( _Thread_Is_executing( the_thread ) || _Thread_Is_heir( the_thread ) ) {
4000a1c0:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
4000a1c4:	80 a2 40 02 	cmp  %o1, %g2                                  
4000a1c8:	02 80 00 06 	be  4000a1e0 <_Scheduler_simple_Block+0x30>    
4000a1cc:	94 10 20 01 	mov  1, %o2                                    
4000a1d0:	c2 01 a0 1c 	ld  [ %g6 + 0x1c ], %g1                        
4000a1d4:	80 a2 40 01 	cmp  %o1, %g1                                  
4000a1d8:	12 80 00 05 	bne  4000a1ec <_Scheduler_simple_Block+0x3c>   <== ALWAYS TAKEN
4000a1dc:	01 00 00 00 	nop                                            
    ( *schedule )( scheduler, the_thread, true );                     
4000a1e0:	82 13 c0 00 	mov  %o7, %g1                                  
4000a1e4:	7f ff ff e3 	call  4000a170 <_Scheduler_simple_Schedule_body>
4000a1e8:	9e 10 40 00 	mov  %g1, %o7                                  
4000a1ec:	81 c3 e0 08 	retl                                           
                                                                      

4000a2c4 <_Scheduler_simple_Schedule>: */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next;
4000a2c4:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000a2c8:	c4 00 40 00 	ld  [ %g1 ], %g2                               
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
4000a2cc:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
4000a2d0:	80 a0 40 02 	cmp  %g1, %g2                                  
4000a2d4:	02 80 00 07 	be  4000a2f0 <_Scheduler_simple_Schedule+0x2c> 
4000a2d8:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
4000a2dc:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      
4000a2e0:	80 a0 60 00 	cmp  %g1, 0                                    
4000a2e4:	02 80 00 03 	be  4000a2f0 <_Scheduler_simple_Schedule+0x2c> <== ALWAYS TAKEN
4000a2e8:	84 10 20 01 	mov  1, %g2                                    
    _Thread_Dispatch_necessary = true;                                
4000a2ec:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       <== NOT EXECUTED
4000a2f0:	81 c3 e0 08 	retl                                           
                                                                      

4000a170 <_Scheduler_simple_Schedule_body>: */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next;
4000a170:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000a174:	c4 00 40 00 	ld  [ %g1 ], %g2                               
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
4000a178:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
4000a17c:	80 a0 40 02 	cmp  %g1, %g2                                  
4000a180:	02 80 00 0a 	be  4000a1a8 <_Scheduler_simple_Schedule_body+0x38><== NEVER TAKEN
4000a184:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
4000a188:	80 a2 a0 00 	cmp  %o2, 0                                    
4000a18c:	12 80 00 06 	bne  4000a1a4 <_Scheduler_simple_Schedule_body+0x34><== ALWAYS TAKEN
4000a190:	84 10 20 01 	mov  1, %g2                                    
4000a194:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      <== NOT EXECUTED
4000a198:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000a19c:	02 80 00 03 	be  4000a1a8 <_Scheduler_simple_Schedule_body+0x38><== NOT EXECUTED
4000a1a0:	01 00 00 00 	nop                                            <== NOT EXECUTED
    _Thread_Dispatch_necessary = true;                                
4000a1a4:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       
4000a1a8:	81 c3 e0 08 	retl                                           
                                                                      

4000a390 <_Scheduler_simple_Yield>: { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous;
4000a390:	c2 02 60 04 	ld  [ %o1 + 4 ], %g1                           
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4000a394:	c6 02 40 00 	ld  [ %o1 ], %g3                               
4000a398:	c4 02 00 00 	ld  [ %o0 ], %g2                               
  previous       = the_node->previous;                                
  next->previous = previous;                                          
4000a39c:	c2 20 e0 04 	st  %g1, [ %g3 + 4 ]                           
  previous->next = next;                                              
4000a3a0:	c6 20 40 00 	st  %g3, [ %g1 ]                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000a3a4:	c2 00 80 00 	ld  [ %g2 ], %g1                               
  Chain_Control *chain,                                               
  Chain_Node *to_insert,                                              
  Chain_Node_order order                                              
)                                                                     
{                                                                     
  const Chain_Node *tail = _Chain_Immutable_tail( chain );            
4000a3a8:	9a 00 a0 04 	add  %g2, 4, %o5                               
  Chain_Node *next = _Chain_First( chain );                           
                                                                      
  while ( next != tail && !( *order )( to_insert, next ) ) {          
4000a3ac:	80 a0 40 0d 	cmp  %g1, %o5                                  
4000a3b0:	32 80 00 0f 	bne,a   4000a3ec <_Scheduler_simple_Yield+0x5c><== ALWAYS TAKEN
4000a3b4:	c8 02 60 14 	ld  [ %o1 + 0x14 ], %g4                        
  Chain_Node *to_insert,                                              
  Chain_Node_order order                                              
)                                                                     
{                                                                     
  const Chain_Node *tail = _Chain_Immutable_tail( chain );            
  Chain_Node *next = _Chain_First( chain );                           
4000a3b8:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *before_node;                                            
                                                                      
  the_node->previous    = after_node;                                 
  before_node           = after_node->next;                           
4000a3bc:	c6 00 40 00 	ld  [ %g1 ], %g3                               
  Chain_Node *the_node                                                
)                                                                     
{                                                                     
  Chain_Node *before_node;                                            
                                                                      
  the_node->previous    = after_node;                                 
4000a3c0:	c2 22 60 04 	st  %g1, [ %o1 + 4 ]                           
  before_node           = after_node->next;                           
  after_node->next      = the_node;                                   
4000a3c4:	d2 20 40 00 	st  %o1, [ %g1 ]                               
  the_node->next        = before_node;                                
4000a3c8:	c6 22 40 00 	st  %g3, [ %o1 ]                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000a3cc:	c4 00 80 00 	ld  [ %g2 ], %g2                               
                                                                      
  the_node->previous    = after_node;                                 
  before_node           = after_node->next;                           
  after_node->next      = the_node;                                   
  the_node->next        = before_node;                                
  before_node->previous = the_node;                                   
4000a3d0:	d2 20 e0 04 	st  %o1, [ %g3 + 4 ]                           
RTEMS_INLINE_ROUTINE void _Scheduler_Update_heir(                     
  Thread_Control *heir,                                               
  bool force_dispatch                                                 
)                                                                     
{                                                                     
  Thread_Control *executing = _Thread_Executing;                      
4000a3d4:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  _Thread_Heir = heir;                                                
                                                                      
  if ( executing != heir && ( force_dispatch || executing->is_preemptible ) )
4000a3d8:	80 a0 40 02 	cmp  %g1, %g2                                  
4000a3dc:	12 80 00 0a 	bne  4000a404 <_Scheduler_simple_Yield+0x74>   
4000a3e0:	c4 21 a0 1c 	st  %g2, [ %g6 + 0x1c ]                        
4000a3e4:	81 c3 e0 08 	retl                                           
4000a3e8:	01 00 00 00 	nop                                            
)                                                                     
{                                                                     
  const Chain_Node *tail = _Chain_Immutable_tail( chain );            
  Chain_Node *next = _Chain_First( chain );                           
                                                                      
  while ( next != tail && !( *order )( to_insert, next ) ) {          
4000a3ec:	c6 00 60 14 	ld  [ %g1 + 0x14 ], %g3                        
4000a3f0:	80 a1 00 03 	cmp  %g4, %g3                                  
4000a3f4:	2a bf ff f2 	bcs,a   4000a3bc <_Scheduler_simple_Yield+0x2c>
4000a3f8:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
  Chain_Node *to_insert,                                              
  Chain_Node_order order                                              
)                                                                     
{                                                                     
  const Chain_Node *tail = _Chain_Immutable_tail( chain );            
  Chain_Node *next = _Chain_First( chain );                           
4000a3fc:	10 bf ff ec 	b  4000a3ac <_Scheduler_simple_Yield+0x1c>     
4000a400:	c2 00 40 00 	ld  [ %g1 ], %g1                               
4000a404:	c2 08 60 70 	ldub  [ %g1 + 0x70 ], %g1                      
4000a408:	80 a0 60 00 	cmp  %g1, 0                                    
4000a40c:	02 bf ff f6 	be  4000a3e4 <_Scheduler_simple_Yield+0x54>    <== ALWAYS TAKEN
4000a410:	84 10 20 01 	mov  1, %g2                                    
    _Thread_Dispatch_necessary = true;                                
4000a414:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       <== NOT EXECUTED
4000a418:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
                                                                      

4000ef50 <_Signal_Action_handler>: Thread_Control *executing, Thread_Action *action, Per_CPU_Control *cpu, ISR_Level level ) {
4000ef50:	9d e3 bf 98 	save  %sp, -104, %sp                           
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
4000ef54:	7f ff cd 3b 	call  40002440 <sparc_enable_interrupts>       
4000ef58:	90 10 00 1b 	mov  %i3, %o0                                  
  Modes_Control      prev_mode;                                       
                                                                      
  (void) action;                                                      
  _Thread_Action_release_and_ISR_enable( cpu, level );                
                                                                      
  api = executing->API_Extensions[ THREAD_API_RTEMS ];                
4000ef5c:	fa 06 21 2c 	ld  [ %i0 + 0x12c ], %i5                       
  if ( !api )                                                         
4000ef60:	80 a7 60 00 	cmp  %i5, 0                                    
4000ef64:	02 80 00 1c 	be  4000efd4 <_Signal_Action_handler+0x84>     <== NEVER TAKEN
4000ef68:	01 00 00 00 	nop                                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
4000ef6c:	7f ff cd 32 	call  40002434 <sparc_disable_interrupts>      
4000ef70:	01 00 00 00 	nop                                            
{                                                                     
  rtems_signal_set signal_set;                                        
  ISR_lock_Context lock_context;                                      
                                                                      
  _ISR_lock_ISR_disable_and_acquire( &asr->Lock, &lock_context );     
    signal_set = asr->signals_posted;                                 
4000ef74:	f8 07 60 14 	ld  [ %i5 + 0x14 ], %i4                        
    asr->signals_posted = 0;                                          
4000ef78:	c0 27 60 14 	clr  [ %i5 + 0x14 ]                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
4000ef7c:	7f ff cd 31 	call  40002440 <sparc_enable_interrupts>       
4000ef80:	01 00 00 00 	nop                                            
   */                                                                 
                                                                      
  asr = &api->Signal;                                                 
  signal_set = _ASR_Get_posted_signals( asr );                        
                                                                      
  if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */ 
4000ef84:	80 a7 20 00 	cmp  %i4, 0                                    
4000ef88:	02 80 00 13 	be  4000efd4 <_Signal_Action_handler+0x84>     <== NEVER TAKEN
4000ef8c:	94 07 bf fc 	add  %fp, -4, %o2                              
    return;                                                           
                                                                      
  asr->nest_level += 1;                                               
4000ef90:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
  rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode ); 
4000ef94:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
  signal_set = _ASR_Get_posted_signals( asr );                        
                                                                      
  if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */ 
    return;                                                           
                                                                      
  asr->nest_level += 1;                                               
4000ef98:	82 00 60 01 	inc  %g1                                       
4000ef9c:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        
  rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode ); 
4000efa0:	37 00 00 3f 	sethi  %hi(0xfc00), %i3                        
4000efa4:	40 00 00 0e 	call  4000efdc <rtems_task_mode>               
4000efa8:	92 16 e3 ff 	or  %i3, 0x3ff, %o1	! ffff <_TLS_Alignment+0xfffe>
                                                                      
  (*asr->handler)( signal_set );                                      
4000efac:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4000efb0:	9f c0 40 00 	call  %g1                                      
4000efb4:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
  asr->nest_level -= 1;                                               
4000efb8:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
  rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );     
4000efbc:	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;                                               
4000efc0:	82 00 7f ff 	add  %g1, -1, %g1                              
  rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );     
4000efc4:	92 16 e3 ff 	or  %i3, 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;                                               
4000efc8:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        
  rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );     
4000efcc:	40 00 00 04 	call  4000efdc <rtems_task_mode>               
4000efd0:	94 07 bf fc 	add  %fp, -4, %o2                              
4000efd4:	81 c7 e0 08 	ret                                            
4000efd8:	81 e8 00 00 	restore                                        
                                                                      

40008598 <_TOD_Validate>: }; bool _TOD_Validate( const rtems_time_of_day *the_tod ) {
40008598:	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 /                    
4000859c:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
400085a0:	d2 00 61 34 	ld  [ %g1 + 0x134 ], %o1	! 40017134 <Configuration+0x14>
400085a4:	11 00 03 d0 	sethi  %hi(0xf4000), %o0                       
400085a8:	40 00 32 8f 	call  40014fe4 <.udiv>                         
400085ac:	90 12 22 40 	or  %o0, 0x240, %o0	! f4240 <_TLS_Alignment+0xf423f>
	    rtems_configuration_get_microseconds_per_tick();                 
  if ((!the_tod)                                  ||                  
400085b0:	80 a6 20 00 	cmp  %i0, 0                                    
400085b4:	02 80 00 33 	be  40008680 <_TOD_Validate+0xe8>              <== NEVER TAKEN
400085b8:	82 10 20 00 	clr  %g1                                       
400085bc:	c4 06 20 18 	ld  [ %i0 + 0x18 ], %g2                        
400085c0:	80 a0 80 08 	cmp  %g2, %o0                                  
400085c4:	3a 80 00 30 	bcc,a   40008684 <_TOD_Validate+0xec>          
400085c8:	b0 08 60 01 	and  %g1, 1, %i0                               
      (the_tod->ticks  >= ticks_per_second)       ||                  
400085cc:	c4 06 20 14 	ld  [ %i0 + 0x14 ], %g2                        
400085d0:	80 a0 a0 3b 	cmp  %g2, 0x3b                                 
400085d4:	38 80 00 2c 	bgu,a   40008684 <_TOD_Validate+0xec>          
400085d8:	b0 08 60 01 	and  %g1, 1, %i0                               
      (the_tod->second >= TOD_SECONDS_PER_MINUTE) ||                  
400085dc:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
400085e0:	80 a0 a0 3b 	cmp  %g2, 0x3b                                 
400085e4:	38 80 00 28 	bgu,a   40008684 <_TOD_Validate+0xec>          
400085e8:	b0 08 60 01 	and  %g1, 1, %i0                               
      (the_tod->minute >= TOD_MINUTES_PER_HOUR)   ||                  
400085ec:	c4 06 20 0c 	ld  [ %i0 + 0xc ], %g2                         
400085f0:	80 a0 a0 17 	cmp  %g2, 0x17                                 
400085f4:	38 80 00 24 	bgu,a   40008684 <_TOD_Validate+0xec>          
400085f8:	b0 08 60 01 	and  %g1, 1, %i0                               
      (the_tod->hour   >= TOD_HOURS_PER_DAY)      ||                  
      (the_tod->month  == 0)                      ||                  
400085fc:	f8 06 20 04 	ld  [ %i0 + 4 ], %i4                           
	    rtems_configuration_get_microseconds_per_tick();                 
  if ((!the_tod)                                  ||                  
      (the_tod->ticks  >= ticks_per_second)       ||                  
      (the_tod->second >= TOD_SECONDS_PER_MINUTE) ||                  
      (the_tod->minute >= TOD_MINUTES_PER_HOUR)   ||                  
      (the_tod->hour   >= TOD_HOURS_PER_DAY)      ||                  
40008600:	84 07 3f ff 	add  %i4, -1, %g2                              
40008604:	80 a0 a0 0b 	cmp  %g2, 0xb                                  
40008608:	38 80 00 1f 	bgu,a   40008684 <_TOD_Validate+0xec>          
4000860c:	b0 08 60 01 	and  %g1, 1, %i0                               
      (the_tod->month  == 0)                      ||                  
      (the_tod->month  >  TOD_MONTHS_PER_YEAR)    ||                  
      (the_tod->year   <  TOD_BASE_YEAR)          ||                  
40008610:	fa 06 00 00 	ld  [ %i0 ], %i5                               
      (the_tod->ticks  >= ticks_per_second)       ||                  
      (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)    ||                  
40008614:	80 a7 67 c3 	cmp  %i5, 0x7c3                                
40008618:	28 80 00 1b 	bleu,a   40008684 <_TOD_Validate+0xec>         
4000861c:	b0 08 60 01 	and  %g1, 1, %i0                               
      (the_tod->year   <  TOD_BASE_YEAR)          ||                  
      (the_tod->day    == 0) )                                        
40008620:	f6 06 20 08 	ld  [ %i0 + 8 ], %i3                           
      (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)          ||                  
40008624:	80 a6 e0 00 	cmp  %i3, 0                                    
40008628:	02 80 00 16 	be  40008680 <_TOD_Validate+0xe8>              <== NEVER TAKEN
4000862c:	35 10 00 5f 	sethi  %hi(0x40017c00), %i2                    
      (the_tod->day    == 0) )                                        
     return false;                                                    
                                                                      
  if (((the_tod->year % 4) == 0 && (the_tod->year % 100 != 0)) ||     
40008630:	80 8f 60 03 	btst  3, %i5                                   
40008634:	12 80 00 08 	bne  40008654 <_TOD_Validate+0xbc>             
40008638:	b4 16 a1 d8 	or  %i2, 0x1d8, %i2                            
4000863c:	90 10 00 1d 	mov  %i5, %o0                                  
40008640:	40 00 33 15 	call  40015294 <.urem>                         
40008644:	92 10 20 64 	mov  0x64, %o1                                 
40008648:	80 a2 20 00 	cmp  %o0, 0                                    
4000864c:	32 80 00 09 	bne,a   40008670 <_TOD_Validate+0xd8>          
40008650:	b8 07 20 0d 	add  %i4, 0xd, %i4                             
     (the_tod->year % 400 == 0))                                      
40008654:	90 10 00 1d 	mov  %i5, %o0                                  
40008658:	40 00 33 0f 	call  40015294 <.urem>                         
4000865c:	92 10 21 90 	mov  0x190, %o1                                
      (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 && (the_tod->year % 100 != 0)) ||     
40008660:	80 a2 20 00 	cmp  %o0, 0                                    
40008664:	32 80 00 04 	bne,a   40008674 <_TOD_Validate+0xdc>          
40008668:	b9 2f 20 02 	sll  %i4, 2, %i4                               
     (the_tod->year % 400 == 0))                                      
    days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ];       
4000866c:	b8 07 20 0d 	add  %i4, 0xd, %i4                             
  else                                                                
    days_in_month = _TOD_Days_per_month[ 0 ][ the_tod->month ];       
40008670:	b9 2f 20 02 	sll  %i4, 2, %i4                               
40008674:	c2 06 80 1c 	ld  [ %i2 + %i4 ], %g1                         
                                                                      
  if ( the_tod->day > days_in_month )                                 
40008678:	80 a0 40 1b 	cmp  %g1, %i3                                  
4000867c:	82 60 3f ff 	subx  %g0, -1, %g1                             
    return false;                                                     
                                                                      
  return true;                                                        
}                                                                     
40008680:	b0 08 60 01 	and  %g1, 1, %i0                               
40008684:	81 c7 e0 08 	ret                                            
40008688:	81 e8 00 00 	restore                                        
                                                                      

40008a08 <_Terminate>: void _Terminate( Internal_errors_Source the_source, bool is_internal, Internal_errors_t the_error ) {
40008a08:	9d e3 bf 90 	save  %sp, -112, %sp                           
  ISR_Level level;                                                    
                                                                      
  _ISR_Disable_without_giant( level );                                
40008a0c:	7f ff e6 8a 	call  40002434 <sparc_disable_interrupts>      
40008a10:	01 00 00 00 	nop                                            
  Internal_errors_t      error                                        
)                                                                     
{                                                                     
  User_extensions_Fatal_context ctx = { source, is_internal, error }; 
                                                                      
  _User_extensions_Iterate( &ctx, _User_extensions_Fatal_visitor );   
40008a14:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
40008a18:	90 07 bf f4 	add  %fp, -12, %o0                             
40008a1c:	92 12 61 ec 	or  %o1, 0x1ec, %o1                            
  Internal_errors_Source source,                                      
  bool                   is_internal,                                 
  Internal_errors_t      error                                        
)                                                                     
{                                                                     
  User_extensions_Fatal_context ctx = { source, is_internal, error }; 
40008a20:	f0 27 bf f4 	st  %i0, [ %fp + -12 ]                         
40008a24:	f2 2f bf f8 	stb  %i1, [ %fp + -8 ]                         
                                                                      
  _User_extensions_Iterate( &ctx, _User_extensions_Fatal_visitor );   
40008a28:	40 00 09 05 	call  4000ae3c <_User_extensions_Iterate>      
40008a2c:	f4 27 bf fc 	st  %i2, [ %fp + -4 ]                          
                                                                      
  _SMP_Request_shutdown();                                            
                                                                      
  _User_extensions_Fatal( the_source, is_internal, the_error );       
                                                                      
  _Internal_errors_What_happened.the_source  = the_source;            
40008a30:	05 10 00 62 	sethi  %hi(0x40018800), %g2                    <== NOT EXECUTED
40008a34:	82 10 a0 e8 	or  %g2, 0xe8, %g1	! 400188e8 <_Internal_errors_What_happened><== NOT EXECUTED
40008a38:	f0 20 a0 e8 	st  %i0, [ %g2 + 0xe8 ]                        <== NOT EXECUTED
  _Internal_errors_What_happened.is_internal = is_internal;           
40008a3c:	f2 28 60 04 	stb  %i1, [ %g1 + 4 ]                          <== NOT EXECUTED
  _Internal_errors_What_happened.the_error   = the_error;             
40008a40:	f4 20 60 08 	st  %i2, [ %g1 + 8 ]                           <== NOT EXECUTED
                                                                      
RTEMS_INLINE_ROUTINE void _System_state_Set (                         
  System_state_Codes state                                            
)                                                                     
{                                                                     
  _System_state_Current = state;                                      
40008a44:	84 10 20 03 	mov  3, %g2                                    <== NOT EXECUTED
40008a48:	03 10 00 62 	sethi  %hi(0x40018800), %g1                    <== NOT EXECUTED
                                                                      
  _System_state_Set( SYSTEM_STATE_TERMINATED );                       
                                                                      
  _CPU_Fatal_halt( the_error );                                       
40008a4c:	7f ff e6 7a 	call  40002434 <sparc_disable_interrupts>      <== NOT EXECUTED
40008a50:	c4 20 60 f4 	st  %g2, [ %g1 + 0xf4 ]	! 400188f4 <_System_state_Current><== NOT EXECUTED
40008a54:	82 10 00 08 	mov  %o0, %g1                                  <== NOT EXECUTED
40008a58:	30 80 00 00 	b,a   40008a58 <_Terminate+0x50>               <== NOT EXECUTED
                                                                      

40009a64 <_Thread_Change_priority>: void _Thread_Change_priority( Thread_Control *the_thread, Priority_Control new_priority, bool prepend_it ) {
40009a64:	9d e3 bf 98 	save  %sp, -104, %sp                           
  /*                                                                  
   *  Do not bother recomputing all the priority related information if
   *  we are not REALLY changing priority.                            
   */                                                                 
  if ( the_thread->current_priority != new_priority ) {               
40009a68:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
40009a6c:	80 a0 40 19 	cmp  %g1, %i1                                  
40009a70:	02 80 00 3d 	be  40009b64 <_Thread_Change_priority+0x100>   
40009a74:	01 00 00 00 	nop                                            
    ISR_Level                level;                                   
    const Scheduler_Control *scheduler;                               
                                                                      
    _ISR_Disable( level );                                            
40009a78:	7f ff e2 6f 	call  40002434 <sparc_disable_interrupts>      
40009a7c:	01 00 00 00 	nop                                            
40009a80:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    scheduler = _Scheduler_Get( the_thread );                         
    the_thread->current_priority = new_priority;                      
                                                                      
    if ( _States_Is_ready( the_thread->current_state ) ) {            
40009a84:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
    const Scheduler_Control *scheduler;                               
                                                                      
    _ISR_Disable( level );                                            
                                                                      
    scheduler = _Scheduler_Get( the_thread );                         
    the_thread->current_priority = new_priority;                      
40009a88:	f2 26 20 14 	st  %i1, [ %i0 + 0x14 ]                        
                                                                      
    if ( _States_Is_ready( the_thread->current_state ) ) {            
40009a8c:	80 a0 60 00 	cmp  %g1, 0                                    
40009a90:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
40009a94:	12 80 00 12 	bne  40009adc <_Thread_Change_priority+0x78>   
40009a98:	90 10 62 6c 	or  %g1, 0x26c, %o0	! 4001566c <_Scheduler_Table>
  Thread_Control          *the_thread,                                
  Priority_Control         new_priority,                              
  bool                     prepend_it                                 
)                                                                     
{                                                                     
  ( *scheduler->Operations.change_priority )(                         
40009a9c:	c4 02 20 18 	ld  [ %o0 + 0x18 ], %g2                        
40009aa0:	92 10 00 18 	mov  %i0, %o1                                  
40009aa4:	94 10 00 19 	mov  %i1, %o2                                  
40009aa8:	9f c0 80 00 	call  %g2                                      
40009aac:	96 10 00 1a 	mov  %i2, %o3                                  
        the_thread,                                                   
        new_priority,                                                 
        prepend_it                                                    
      );                                                              
                                                                      
      _ISR_Flash( level );                                            
40009ab0:	7f ff e2 64 	call  40002440 <sparc_enable_interrupts>       
40009ab4:	90 10 00 1d 	mov  %i5, %o0                                  
40009ab8:	7f ff e2 5f 	call  40002434 <sparc_disable_interrupts>      
40009abc:	01 00 00 00 	nop                                            
40009ac0:	ba 10 00 08 	mov  %o0, %i5                                  
RTEMS_INLINE_ROUTINE void _Scheduler_Schedule(                        
  const Scheduler_Control *scheduler,                                 
  Thread_Control          *the_thread                                 
)                                                                     
{                                                                     
  ( *scheduler->Operations.schedule )( scheduler, the_thread );       
40009ac4:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    
40009ac8:	90 12 22 6c 	or  %o0, 0x26c, %o0	! 4001566c <_Scheduler_Table>
40009acc:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           
40009ad0:	9f c0 40 00 	call  %g1                                      
40009ad4:	92 10 00 18 	mov  %i0, %o1                                  
40009ad8:	30 80 00 05 	b,a   40009aec <_Thread_Change_priority+0x88>  
  const Scheduler_Control *scheduler,                                 
  Thread_Control          *the_thread,                                
  Priority_Control         new_priority                               
)                                                                     
{                                                                     
  ( *scheduler->Operations.update_priority )(                         
40009adc:	c4 02 20 24 	ld  [ %o0 + 0x24 ], %g2                        
40009ae0:	92 10 00 18 	mov  %i0, %o1                                  
40009ae4:	9f c0 80 00 	call  %g2                                      
40009ae8:	94 10 00 19 	mov  %i1, %o2                                  
      scheduler = _Scheduler_Get( the_thread );                       
      _Scheduler_Schedule( scheduler, the_thread );                   
    } else {                                                          
      _Scheduler_Update_priority( scheduler, the_thread, new_priority );
    }                                                                 
    _ISR_Enable( level );                                             
40009aec:	7f ff e2 55 	call  40002440 <sparc_enable_interrupts>       
40009af0:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
    _Thread_queue_Requeue( the_thread->Wait.queue, the_thread );      
40009af4:	fa 06 20 44 	ld  [ %i0 + 0x44 ], %i5                        
{                                                                     
  /*                                                                  
   * Just in case the thread really wasn't blocked on a thread queue  
   * when we get here.                                                
   */                                                                 
  if ( !the_thread_queue )                                            
40009af8:	80 a7 60 00 	cmp  %i5, 0                                    
40009afc:	02 80 00 1a 	be  40009b64 <_Thread_Change_priority+0x100>   
40009b00:	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 ) {
40009b04:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
40009b08:	80 a0 60 01 	cmp  %g1, 1                                    
40009b0c:	12 80 00 16 	bne  40009b64 <_Thread_Change_priority+0x100>  
40009b10:	01 00 00 00 	nop                                            
    Thread_queue_Control *tq = the_thread_queue;                      
    ISR_Level             level;                                      
    ISR_Level             level_ignored;                              
                                                                      
    _ISR_Disable( level );                                            
40009b14:	7f ff e2 48 	call  40002434 <sparc_disable_interrupts>      
40009b18:	01 00 00 00 	nop                                            
40009b1c:	b8 10 00 08 	mov  %o0, %i4                                  
 */                                                                   
RTEMS_INLINE_ROUTINE bool _States_Is_waiting_on_thread_queue (        
  States_Control the_states                                           
)                                                                     
{                                                                     
   return (the_states & STATES_WAITING_ON_THREAD_QUEUE);              
40009b20:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
    if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
40009b24:	03 00 02 ef 	sethi  %hi(0xbbc00), %g1                       
40009b28:	82 10 62 e0 	or  %g1, 0x2e0, %g1	! bbee0 <_TLS_Alignment+0xbbedf>
40009b2c:	80 88 80 01 	btst  %g2, %g1                                 
40009b30:	02 80 00 0b 	be  40009b5c <_Thread_Change_priority+0xf8>    <== NEVER TAKEN
40009b34:	82 10 20 01 	mov  1, %g1                                    
      _Thread_queue_Enter_critical_section( tq );                     
      _Thread_queue_Extract_priority_helper(                          
40009b38:	d2 06 20 34 	ld  [ %i0 + 0x34 ], %o1                        
40009b3c:	90 10 00 18 	mov  %i0, %o0                                  
40009b40:	94 10 20 01 	mov  1, %o2                                    
40009b44:	40 00 02 76 	call  4000a51c <_Thread_queue_Extract_priority_helper>
40009b48:	c2 27 60 30 	st  %g1, [ %i5 + 0x30 ]                        
        the_thread,                                                   
        the_thread->Wait.return_code,                                 
        true                                                          
      );                                                              
      (void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored );
40009b4c:	90 10 00 1d 	mov  %i5, %o0                                  
40009b50:	92 10 00 18 	mov  %i0, %o1                                  
40009b54:	40 00 02 0f 	call  4000a390 <_Thread_queue_Enqueue_priority>
40009b58:	94 07 bf fc 	add  %fp, -4, %o2                              
    }                                                                 
    _ISR_Enable( level );                                             
40009b5c:	7f ff e2 39 	call  40002440 <sparc_enable_interrupts>       
40009b60:	90 10 00 1c 	mov  %i4, %o0                                  
40009b64:	81 c7 e0 08 	ret                                            
40009b68:	81 e8 00 00 	restore                                        
                                                                      

4000aa78 <_Thread_Close>: } } } void _Thread_Close( Thread_Control *the_thread, Thread_Control *executing ) {
4000aa78:	9d e3 bf a0 	save  %sp, -96, %sp                            
  _Assert( _Thread_Is_life_protected( executing->Life.state ) );      
                                                                      
  _Objects_Close(                                                     
4000aa7c:	d0 06 20 08 	ld  [ %i0 + 8 ], %o0                           
4000aa80:	7f ff f9 31 	call  40008f44 <_Objects_Get_information_id>   
4000aa84:	ba 10 00 18 	mov  %i0, %i5                                  
4000aa88:	7f ff f8 46 	call  40008ba0 <_Objects_Close>                
4000aa8c:	92 10 00 18 	mov  %i0, %o1                                  
 */                                                                   
RTEMS_INLINE_ROUTINE bool _States_Is_dormant (                        
  States_Control the_states                                           
)                                                                     
{                                                                     
   return (the_states & STATES_DORMANT);                              
4000aa90:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
    _Objects_Get_information_id( the_thread->Object.id ),             
    &the_thread->Object                                               
  );                                                                  
                                                                      
  if ( _States_Is_dormant( the_thread->current_state ) ) {            
4000aa94:	80 88 60 01 	btst  1, %g1                                   
4000aa98:	02 80 00 04 	be  4000aaa8 <_Thread_Close+0x30>              
4000aa9c:	80 a6 00 19 	cmp  %i0, %i1                                  
    _Thread_Make_zombie( the_thread );                                
4000aaa0:	7f ff ff 0c 	call  4000a6d0 <_Thread_Make_zombie>           
4000aaa4:	81 e8 00 00 	restore                                        
  } else {                                                            
    if (                                                              
4000aaa8:	22 80 00 0b 	be,a   4000aad4 <_Thread_Close+0x5c>           
4000aaac:	f4 06 60 14 	ld  [ %i1 + 0x14 ], %i2                        
                                                                      
RTEMS_INLINE_ROUTINE bool _Thread_Is_life_terminating(                
  Thread_Life_state life_state                                        
)                                                                     
{                                                                     
  return ( life_state & THREAD_LIFE_TERMINATING ) != 0;               
4000aab0:	c2 06 61 50 	ld  [ %i1 + 0x150 ], %g1                       
      the_thread != executing                                         
        && !_Thread_Is_life_terminating( executing->Life.state )      
4000aab4:	80 88 60 04 	btst  4, %g1                                   
4000aab8:	32 80 00 07 	bne,a   4000aad4 <_Thread_Close+0x5c>          <== NEVER TAKEN
4000aabc:	f4 06 60 14 	ld  [ %i1 + 0x14 ], %i2                        <== NOT EXECUTED
      /*                                                              
       * Wait for termination of victim thread.  If the executing thread is
       * also terminated, then do not wait.  This avoids potential cyclic
       * dependencies and thus dead lock.                             
       */                                                             
       the_thread->Life.terminator = executing;                       
4000aac0:	f2 26 21 54 	st  %i1, [ %i0 + 0x154 ]                       
       _Thread_Set_state( executing, STATES_WAITING_FOR_TERMINATION );
4000aac4:	90 10 00 19 	mov  %i1, %o0                                  
4000aac8:	40 00 00 2b 	call  4000ab74 <_Thread_Set_state>             
4000aacc:	13 00 04 00 	sethi  %hi(0x100000), %o1                      
    }                                                                 
                                                                      
    _Thread_Request_life_change(                                      
4000aad0:	f4 06 60 14 	ld  [ %i1 + 0x14 ], %i2                        
4000aad4:	b0 10 00 1d 	mov  %i5, %i0                                  
4000aad8:	7f ff ff 36 	call  4000a7b0 <_Thread_Request_life_change>   
4000aadc:	97 e8 20 04 	restore  %g0, 4, %o3                           
                                                                      

40009c68 <_Thread_Delay_ended>: void _Thread_Delay_ended( Objects_Id id, void *ignored __attribute__((unused)) ) {
40009c68:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Thread_Control    *the_thread;                                      
  Objects_Locations  location;                                        
                                                                      
  the_thread = _Thread_Get( id, &location );                          
40009c6c:	90 10 00 18 	mov  %i0, %o0                                  
40009c70:	40 00 00 75 	call  40009e44 <_Thread_Get>                   
40009c74:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
40009c78:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40009c7c:	80 a0 60 00 	cmp  %g1, 0                                    
40009c80:	12 80 00 07 	bne  40009c9c <_Thread_Delay_ended+0x34>       <== NEVER TAKEN
40009c84:	13 04 00 00 	sethi  %hi(0x10000000), %o1                    
#if defined(RTEMS_MULTIPROCESSING)                                    
    case OBJECTS_REMOTE:  /* impossible */                            
#endif                                                                
      break;                                                          
    case OBJECTS_LOCAL:                                               
      _Thread_Clear_state(                                            
40009c88:	7f ff ff b9 	call  40009b6c <_Thread_Clear_state>           
40009c8c:	92 12 60 18 	or  %o1, 0x18, %o1	! 10000018 <RAM_SIZE+0xfc00018>
   *                                                                  
   * This routine decrements the thread dispatch level.               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40009c90:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable( level );                                            
#endif                                                                
                                                                      
    --disable_level;                                                  
40009c94:	84 00 bf ff 	add  %g2, -1, %g2                              
    _Thread_Dispatch_disable_level = disable_level;                   
40009c98:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
40009c9c:	81 c7 e0 08 	ret                                            
40009ca0:	81 e8 00 00 	restore                                        
                                                                      

40009ca4 <_Thread_Dispatch>: _Thread_Action_release_and_ISR_enable( cpu_self, level ); } void _Thread_Dispatch( void ) {
40009ca4:	9d e3 bf 98 	save  %sp, -104, %sp                           
#endif                                                                
                                                                      
  cpu_self = _Per_CPU_Get();                                          
  _Assert( cpu_self->thread_dispatch_disable_level == 0 );            
  _Profiling_Thread_dispatch_disable( cpu_self, 0 );                  
  cpu_self->thread_dispatch_disable_level = 1;                        
40009ca8:	82 10 20 01 	mov  1, %g1                                    
   * to this function.                                                
   */                                                                 
  _ISR_Disable_without_giant( level );                                
#endif                                                                
                                                                      
  cpu_self = _Per_CPU_Get();                                          
40009cac:	b6 10 00 06 	mov  %g6, %i3                                  
  _Assert( cpu_self->thread_dispatch_disable_level == 0 );            
  _Profiling_Thread_dispatch_disable( cpu_self, 0 );                  
  cpu_self->thread_dispatch_disable_level = 1;                        
40009cb0:	c2 21 a0 10 	st  %g1, [ %g6 + 0x10 ]                        
   *  Now determine if we need to perform a dispatch on the current CPU.
   */                                                                 
  executing = cpu_self->executing;                                    
                                                                      
#if !defined( RTEMS_SMP )                                             
  _ISR_Disable( level );                                              
40009cb4:	7f ff e1 e0 	call  40002434 <sparc_disable_interrupts>      
40009cb8:	e6 01 a0 18 	ld  [ %g6 + 0x18 ], %l3                        
 */                                                                   
static inline void _TOD_Get_uptime(                                   
  Timestamp_Control *time                                             
)                                                                     
{                                                                     
  _TOD_Get_with_nanoseconds( time, &_TOD.uptime );                    
40009cbc:	23 10 00 61 	sethi  %hi(0x40018400), %l1                    
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40009cc0:	33 10 00 5b 	sethi  %hi(0x40016c00), %i1                    
#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 = rtems_configuration_get_ticks_per_timeslice();
40009cc4:	21 10 00 55 	sethi  %hi(0x40015400), %l0                    
40009cc8:	b2 16 60 18 	or  %i1, 0x18, %i1                             
40009ccc:	a2 14 60 08 	or  %l1, 8, %l1                                
{                                                                     
  const Chain_Control *chain = &_User_extensions_Switches_list;       
  const Chain_Node    *tail = _Chain_Immutable_tail( chain );         
  const Chain_Node    *node = _Chain_Immutable_first( chain );        
                                                                      
  if ( node != tail ) {                                               
40009cd0:	b0 06 60 04 	add  %i1, 4, %i0                               
    if ( executing->fp_context != NULL )                              
      _Context_Save_fp( &executing->fp_context );                     
#endif                                                                
#endif                                                                
                                                                      
    _Context_Switch( &executing->Registers, &heir->Registers );       
40009cd4:	a4 04 e0 d0 	add  %l3, 0xd0, %l2                            
#endif                                                                
                                                                      
#if defined( RTEMS_SMP )                                              
  if ( cpu_self->dispatch_necessary ) {                               
#else                                                                 
  while ( cpu_self->dispatch_necessary ) {                            
40009cd8:	c2 0e e0 14 	ldub  [ %i3 + 0x14 ], %g1                      
40009cdc:	80 a0 60 00 	cmp  %g1, 0                                    
40009ce0:	02 80 00 07 	be  40009cfc <_Thread_Dispatch+0x58>           
40009ce4:	01 00 00 00 	nop                                            
   * _Scheduler_SMP_Update_heir().                                    
   */                                                                 
  _Atomic_Fence( ATOMIC_ORDER_SEQ_CST );                              
#endif                                                                
                                                                      
  heir = cpu_self->heir;                                              
40009ce8:	e8 06 e0 1c 	ld  [ %i3 + 0x1c ], %l4                        
  Per_CPU_Control *cpu_self                                           
)                                                                     
{                                                                     
  Thread_Control *heir;                                               
                                                                      
  cpu_self->dispatch_necessary = false;                               
40009cec:	c0 2e e0 14 	clrb  [ %i3 + 0x14 ]                           
    /*                                                                
     *  When the heir and executing are the same, then we are being   
     *  requested to do the post switch dispatching.  This is normally
     *  done to dispatch signals.                                     
     */                                                               
    if ( heir == executing )                                          
40009cf0:	80 a5 00 13 	cmp  %l4, %l3                                  
40009cf4:	12 80 00 10 	bne  40009d34 <_Thread_Dispatch+0x90>          
40009cf8:	e8 26 e0 18 	st  %l4, [ %i3 + 0x18 ]                        
#endif                                                                
  }                                                                   
                                                                      
post_switch:                                                          
  _Assert( cpu_self->thread_dispatch_disable_level == 1 );            
  cpu_self->thread_dispatch_disable_level = 0;                        
40009cfc:	c0 26 e0 10 	clr  [ %i3 + 0x10 ]                            
  _Profiling_Thread_dispatch_enable( cpu_self, 0 );                   
                                                                      
  _ISR_Enable_without_giant( level );                                 
40009d00:	7f ff e1 d0 	call  40002440 <sparc_enable_interrupts>       
40009d04:	01 00 00 00 	nop                                            
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
40009d08:	7f ff e1 cb 	call  40002434 <sparc_disable_interrupts>      
40009d0c:	01 00 00 00 	nop                                            
40009d10:	96 10 00 08 	mov  %o0, %o3                                  
40009d14:	d2 04 e0 c4 	ld  [ %l3 + 0xc4 ], %o1                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40009d18:	ba 04 e0 c8 	add  %l3, 0xc8, %i5                            
#if defined(RTEMS_SMP)                                                
  return thread->cpu;                                                 
#else                                                                 
  (void) thread;                                                      
                                                                      
  return _Per_CPU_Get();                                              
40009d1c:	94 10 00 06 	mov  %g6, %o2                                  
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40009d20:	80 a2 40 1d 	cmp  %o1, %i5                                  
40009d24:	12 80 00 35 	bne  40009df8 <_Thread_Dispatch+0x154>         
40009d28:	b8 04 e0 c4 	add  %l3, 0xc4, %i4                            
    return _Chain_Get_first_unprotected(the_chain);                   
  else                                                                
    return NULL;                                                      
40009d2c:	10 80 00 25 	b  40009dc0 <_Thread_Dispatch+0x11c>           
40009d30:	92 10 20 00 	clr  %o1                                       
     */                                                               
#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 )
40009d34:	c2 05 20 78 	ld  [ %l4 + 0x78 ], %g1                        
40009d38:	80 a0 60 01 	cmp  %g1, 1                                    
40009d3c:	12 80 00 04 	bne  40009d4c <_Thread_Dispatch+0xa8>          
40009d40:	82 14 21 88 	or  %l0, 0x188, %g1                            
      heir->cpu_time_budget = rtems_configuration_get_ticks_per_timeslice();
40009d44:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
40009d48:	c2 25 20 74 	st  %g1, [ %l4 + 0x74 ]                        
                                                                      
#if !defined( RTEMS_SMP )                                             
    _ISR_Enable( level );                                             
40009d4c:	7f ff e1 bd 	call  40002440 <sparc_enable_interrupts>       
40009d50:	01 00 00 00 	nop                                            
40009d54:	90 07 bf f8 	add  %fp, -8, %o0                              
40009d58:	7f ff f9 da 	call  400084c0 <_TOD_Get_with_nanoseconds>     
40009d5c:	92 10 00 11 	mov  %l1, %o1                                  
{                                                                     
  Timestamp_Control uptime;                                           
  Timestamp_Control ran;                                              
                                                                      
  _TOD_Get_uptime( &uptime );                                         
  _Timestamp_Subtract(                                                
40009d60:	c4 1f bf f8 	ldd  [ %fp + -8 ], %g2                         
  const Timestamp64_Control *_start,                                  
  const Timestamp64_Control *_end,                                    
  Timestamp64_Control       *_result                                  
)                                                                     
{                                                                     
  *_result = *_end - *_start;                                         
40009d64:	f8 1e e0 20 	ldd  [ %i3 + 0x20 ], %i4                       
    time_of_last_context_switch,                                      
    &uptime,                                                          
    &ran                                                              
  );                                                                  
  *time_of_last_context_switch = uptime;                              
40009d68:	c4 3e e0 20 	std  %g2, [ %i3 + 0x20 ]                       
40009d6c:	ba a0 c0 1d 	subcc  %g3, %i5, %i5                           
40009d70:	b8 60 80 1c 	subx  %g2, %i4, %i4                            
static inline void _Timestamp64_implementation_Add_to(                
  Timestamp64_Control       *_time,                                   
  const Timestamp64_Control *_add                                     
)                                                                     
{                                                                     
  *_time += *_add;                                                    
40009d74:	c4 1c e0 80 	ldd  [ %l3 + 0x80 ], %g2                       
40009d78:	b6 80 c0 1d 	addcc  %g3, %i5, %i3                           
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40009d7c:	fa 06 40 00 	ld  [ %i1 ], %i5                               
40009d80:	b4 40 80 1c 	addx  %g2, %i4, %i2                            
40009d84:	f4 3c e0 80 	std  %i2, [ %l3 + 0x80 ]                       
40009d88:	80 a7 40 18 	cmp  %i5, %i0                                  
40009d8c:	02 80 00 08 	be  40009dac <_Thread_Dispatch+0x108>          
40009d90:	90 10 00 12 	mov  %l2, %o0                                  
                                                                      
    while ( node != tail ) {                                          
      const User_extensions_Switch_control *extension =               
        (const User_extensions_Switch_control *) node;                
                                                                      
      (*extension->thread_switch)( executing, heir );                 
40009d94:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
40009d98:	90 10 00 13 	mov  %l3, %o0                                  
40009d9c:	9f c0 40 00 	call  %g1                                      
40009da0:	92 10 00 14 	mov  %l4, %o1                                  
  Thread_Control *heir                                                
)                                                                     
{                                                                     
  const Chain_Control *chain = &_User_extensions_Switches_list;       
  const Chain_Node    *tail = _Chain_Immutable_tail( chain );         
  const Chain_Node    *node = _Chain_Immutable_first( chain );        
40009da4:	10 bf ff f9 	b  40009d88 <_Thread_Dispatch+0xe4>            
40009da8:	fa 07 40 00 	ld  [ %i5 ], %i5                               
    if ( executing->fp_context != NULL )                              
      _Context_Save_fp( &executing->fp_context );                     
#endif                                                                
#endif                                                                
                                                                      
    _Context_Switch( &executing->Registers, &heir->Registers );       
40009dac:	40 00 2a c7 	call  400148c8 <_CPU_Context_switch>           
40009db0:	92 05 20 d0 	add  %l4, 0xd0, %o1                            
    cpu_self = _Per_CPU_Get();                                        
                                                                      
    _Thread_Debug_set_real_processor( executing, cpu_self );          
                                                                      
#if !defined( RTEMS_SMP )                                             
    _ISR_Disable( level );                                            
40009db4:	7f ff e1 a0 	call  40002434 <sparc_disable_interrupts>      
40009db8:	b6 10 00 06 	mov  %g6, %i3                                  
40009dbc:	30 bf ff c7 	b,a   40009cd8 <_Thread_Dispatch+0x34>         
  Thread_Action   *action;                                            
                                                                      
  cpu_self = _Thread_Action_ISR_disable_and_acquire( executing, &level );
  action = _Thread_Get_post_switch_action( executing );               
                                                                      
  while ( action != NULL ) {                                          
40009dc0:	80 a2 60 00 	cmp  %o1, 0                                    
40009dc4:	02 80 00 11 	be  40009e08 <_Thread_Dispatch+0x164>          
40009dc8:	01 00 00 00 	nop                                            
    _Chain_Set_off_chain( &action->Node );                            
                                                                      
    ( *action->handler )( executing, action, cpu_self, level );       
40009dcc:	c2 02 60 08 	ld  [ %o1 + 8 ], %g1                           
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
40009dd0:	c0 22 40 00 	clr  [ %o1 ]                                   
40009dd4:	9f c0 40 00 	call  %g1                                      
40009dd8:	90 10 00 13 	mov  %l3, %o0                                  
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
40009ddc:	7f ff e1 96 	call  40002434 <sparc_disable_interrupts>      
40009de0:	01 00 00 00 	nop                                            
40009de4:	96 10 00 08 	mov  %o0, %o3                                  
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40009de8:	d2 04 e0 c4 	ld  [ %l3 + 0xc4 ], %o1                        
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40009dec:	80 a2 40 1d 	cmp  %o1, %i5                                  
40009df0:	02 80 00 06 	be  40009e08 <_Thread_Dispatch+0x164>          <== ALWAYS TAKEN
40009df4:	94 10 00 06 	mov  %g6, %o2                                  
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40009df8:	c2 02 40 00 	ld  [ %o1 ], %g1                               
                                                                      
  head->next = new_first;                                             
40009dfc:	c2 24 e0 c4 	st  %g1, [ %l3 + 0xc4 ]                        
  new_first->previous = head;                                         
40009e00:	10 bf ff f0 	b  40009dc0 <_Thread_Dispatch+0x11c>           
40009e04:	f8 20 60 04 	st  %i4, [ %g1 + 4 ]                           
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
40009e08:	7f ff e1 8e 	call  40002440 <sparc_enable_interrupts>       
40009e0c:	90 10 00 0b 	mov  %o3, %o0                                  
40009e10:	81 c7 e0 08 	ret                                            
40009e14:	81 e8 00 00 	restore                                        
                                                                      

4000f828 <_Thread_Handler>: return doCons; } #endif void _Thread_Handler( void ) {
4000f828:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Thread_Control *executing;                                          
  #if defined(EXECUTE_GLOBAL_CONSTRUCTORS)                            
    bool doCons;                                                      
  #endif                                                              
                                                                      
  executing = _Thread_Executing;                                      
4000f82c:	fa 01 a0 18 	ld  [ %g6 + 0x18 ], %i5                        
  /*                                                                  
   * 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();                          
4000f830:	3f 10 00 3e 	sethi  %hi(0x4000f800), %i7                    
4000f834:	be 17 e0 28 	or  %i7, 0x28, %i7	! 4000f828 <_Thread_Handler>
  #if !defined(RTEMS_SMP)                                             
    /*                                                                
     * have to put level into a register for those cpu's that use     
     * inline asm here                                                
     */                                                               
    level = executing->Start.isr_level;                               
4000f838:	d0 07 60 a8 	ld  [ %i5 + 0xa8 ], %o0                        
    _ISR_Set_level( level );                                          
4000f83c:	7f ff cb 01 	call  40002440 <sparc_enable_interrupts>       
4000f840:	91 2a 20 08 	sll  %o0, 8, %o0                               
        && _Objects_Get_API( executing->Object.id ) != OBJECTS_INTERNAL_API;
      if (doCons)                                                     
        doneConstructors = true;                                      
    #else                                                             
      (void) executing;                                               
      doCons = !doneConstructors;                                     
4000f844:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
      doneConstructors = true;                                        
4000f848:	84 10 20 01 	mov  1, %g2                                    
        && _Objects_Get_API( executing->Object.id ) != OBJECTS_INTERNAL_API;
      if (doCons)                                                     
        doneConstructors = true;                                      
    #else                                                             
      (void) executing;                                               
      doCons = !doneConstructors;                                     
4000f84c:	f8 08 62 c8 	ldub  [ %g1 + 0x2c8 ], %i4                     
  );                                                                  
}                                                                     
                                                                      
static inline void _User_extensions_Thread_begin( Thread_Control *executing )
{                                                                     
  _User_extensions_Iterate(                                           
4000f850:	90 10 00 1d 	mov  %i5, %o0                                  
4000f854:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
4000f858:	92 12 61 a4 	or  %o1, 0x1a4, %o1	! 4000ada4 <_User_extensions_Thread_begin_visitor>
4000f85c:	7f ff ed 78 	call  4000ae3c <_User_extensions_Iterate>      
4000f860:	c4 28 62 c8 	stb  %g2, [ %g1 + 0x2c8 ]                      
       * no thread dispatch necessary update.                         
       */                                                             
      _Thread_Dispatch();                                             
    }                                                                 
  #else                                                               
    _Thread_Enable_dispatch();                                        
4000f864:	7f ff e9 6d 	call  40009e18 <_Thread_Enable_dispatch>       
4000f868:	01 00 00 00 	nop                                            
    /*                                                                
     *  _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 (doCons) /* && (volatile void *)_init) */ {                    
4000f86c:	80 8f 20 ff 	btst  0xff, %i4                                
4000f870:	32 80 00 05 	bne,a   4000f884 <_Thread_Handler+0x5c>        
4000f874:	c2 07 60 90 	ld  [ %i5 + 0x90 ], %g1                        
      INIT_NAME ();                                                   
4000f878:	40 00 1c 7c 	call  40016a68 <_init>                         
4000f87c:	01 00 00 00 	nop                                            
  /*                                                                  
   *  RTEMS supports multiple APIs and each API can define a different
   *  thread/task prototype. The following code supports invoking the 
   *  user thread entry point using the prototype expected.           
   */                                                                 
  if ( executing->Start.prototype == THREAD_START_NUMERIC ) {         
4000f880:	c2 07 60 90 	ld  [ %i5 + 0x90 ], %g1                        
4000f884:	80 a0 60 00 	cmp  %g1, 0                                    
4000f888:	12 80 00 05 	bne  4000f89c <_Thread_Handler+0x74>           
4000f88c:	80 a0 60 01 	cmp  %g1, 1                                    
    executing->Wait.return_argument =                                 
      (*(Thread_Entry_numeric) executing->Start.entry_point)(         
4000f890:	c2 07 60 8c 	ld  [ %i5 + 0x8c ], %g1                        
4000f894:	10 80 00 06 	b  4000f8ac <_Thread_Handler+0x84>             
4000f898:	d0 07 60 98 	ld  [ %i5 + 0x98 ], %o0                        
        executing->Start.numeric_argument                             
      );                                                              
  }                                                                   
  #if defined(RTEMS_POSIX_API)                                        
    else if ( executing->Start.prototype == THREAD_START_POINTER ) {  
4000f89c:	12 80 00 08 	bne  4000f8bc <_Thread_Handler+0x94>           <== NEVER TAKEN
4000f8a0:	90 10 00 1d 	mov  %i5, %o0                                  
      executing->Wait.return_argument =                               
        (*(Thread_Entry_pointer) executing->Start.entry_point)(       
4000f8a4:	c2 07 60 8c 	ld  [ %i5 + 0x8c ], %g1                        
4000f8a8:	d0 07 60 94 	ld  [ %i5 + 0x94 ], %o0                        
4000f8ac:	9f c0 40 00 	call  %g1                                      
4000f8b0:	01 00 00 00 	nop                                            
        executing->Start.numeric_argument                             
      );                                                              
  }                                                                   
  #if defined(RTEMS_POSIX_API)                                        
    else if ( executing->Start.prototype == THREAD_START_POINTER ) {  
      executing->Wait.return_argument =                               
4000f8b4:	d0 27 60 28 	st  %o0, [ %i5 + 0x28 ]                        
  }                                                                   
}                                                                     
                                                                      
static inline void _User_extensions_Thread_exitted( Thread_Control *executing )
{                                                                     
  _User_extensions_Iterate(                                           
4000f8b8:	90 10 00 1d 	mov  %i5, %o0                                  
4000f8bc:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
4000f8c0:	7f ff ed 5f 	call  4000ae3c <_User_extensions_Iterate>      
4000f8c4:	92 12 61 c8 	or  %o1, 0x1c8, %o1	! 4000adc8 <_User_extensions_Thread_exitted_visitor>
   *  able to fit in a (void *).                                      
   */                                                                 
                                                                      
  _User_extensions_Thread_exitted( executing );                       
                                                                      
  _Terminate(                                                         
4000f8c8:	90 10 20 00 	clr  %o0                                       
4000f8cc:	92 10 20 01 	mov  1, %o1                                    
4000f8d0:	7f ff e4 4e 	call  40008a08 <_Terminate>                    
4000f8d4:	94 10 20 05 	mov  5, %o2                                    
                                                                      

4000a11c <_Thread_Handler_initialization>: #include <rtems/score/threadimpl.h> #include <rtems/score/interr.h> void _Thread_Handler_initialization(void) {
4000a11c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_stack_allocate_init_hook stack_allocate_init_hook =           
4000a120:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
4000a124:	82 10 61 88 	or  %g1, 0x188, %g1	! 40015588 <Configuration> 
  #if defined(RTEMS_MULTIPROCESSING)                                  
    uint32_t maximum_proxies =                                        
      _Configuration_MP_table->maximum_proxies;                       
  #endif                                                              
                                                                      
  if ( rtems_configuration_get_stack_allocate_hook() == NULL ||       
4000a128:	c6 00 60 30 	ld  [ %g1 + 0x30 ], %g3                        
4000a12c:	80 a0 e0 00 	cmp  %g3, 0                                    
4000a130:	02 80 00 06 	be  4000a148 <_Thread_Handler_initialization+0x2c><== NEVER TAKEN
4000a134:	c4 00 60 2c 	ld  [ %g1 + 0x2c ], %g2                        
4000a138:	c6 00 60 34 	ld  [ %g1 + 0x34 ], %g3                        
4000a13c:	80 a0 e0 00 	cmp  %g3, 0                                    
4000a140:	12 80 00 06 	bne  4000a158 <_Thread_Handler_initialization+0x3c>
4000a144:	80 a0 a0 00 	cmp  %g2, 0                                    
       rtems_configuration_get_stack_free_hook() == NULL)             
    _Terminate(                                                       
4000a148:	90 10 20 00 	clr  %o0                                       
4000a14c:	92 10 20 01 	mov  1, %o1                                    
4000a150:	7f ff fa 2e 	call  40008a08 <_Terminate>                    
4000a154:	94 10 20 0e 	mov  0xe, %o2                                  
      INTERNAL_ERROR_CORE,                                            
      true,                                                           
      INTERNAL_ERROR_BAD_STACK_HOOK                                   
    );                                                                
                                                                      
  if ( stack_allocate_init_hook != NULL )                             
4000a158:	22 80 00 05 	be,a   4000a16c <_Thread_Handler_initialization+0x50>
4000a15c:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
    (*stack_allocate_init_hook)( rtems_configuration_get_stack_space_size() );
4000a160:	9f c0 80 00 	call  %g2                                      
4000a164:	d0 00 60 04 	ld  [ %g1 + 4 ], %o0	! 40015404 <__EH_FRAME_BEGIN__+0x44>
  /*                                                                  
   *  Initialize the internal class of threads.  We need an IDLE thread
   *  per CPU in an SMP system.  In addition, if this is a loosely    
   *  coupled multiprocessing system, account for the MPCI Server Thread.
   */                                                                 
  _Objects_Initialize_information(                                    
4000a168:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
4000a16c:	d8 10 61 f2 	lduh  [ %g1 + 0x1f2 ], %o4	! 400155f2 <_Thread_Control_size+0x2>
4000a170:	82 10 20 08 	mov  8, %g1                                    
4000a174:	11 10 00 61 	sethi  %hi(0x40018400), %o0                    
4000a178:	c2 23 a0 5c 	st  %g1, [ %sp + 0x5c ]                        
4000a17c:	90 12 20 c8 	or  %o0, 0xc8, %o0                             
4000a180:	92 10 20 01 	mov  1, %o1                                    
4000a184:	94 10 20 01 	mov  1, %o2                                    
4000a188:	96 10 20 01 	mov  1, %o3                                    
4000a18c:	7f ff fb c8 	call  400090ac <_Objects_Initialize_information>
4000a190:	9a 10 20 00 	clr  %o5                                       
4000a194:	81 c7 e0 08 	ret                                            
4000a198:	81 e8 00 00 	restore                                        
                                                                      

40009ed4 <_Thread_Initialize>: Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
40009ed4:	9d e3 bf 98 	save  %sp, -104, %sp                           
40009ed8:	c2 07 a0 70 	ld  [ %fp + 0x70 ], %g1                        
40009edc:	fa 07 a0 5c 	ld  [ %fp + 0x5c ], %i5                        
40009ee0:	e2 00 40 00 	ld  [ %g1 ], %l1                               
40009ee4:	e0 07 a0 64 	ld  [ %fp + 0x64 ], %l0                        
{                                                                     
  /*                                                                  
   * Do not use _TLS_Size here since this will lead GCC to assume that this
   * symbol is not 0 and the tests for 0 will be optimized away.      
   */                                                                 
  return (uintptr_t) _TLS_BSS_end - (uintptr_t) _TLS_Data_begin;      
40009ee8:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
40009eec:	e4 0f a0 63 	ldub  [ %fp + 0x63 ], %l2                      
40009ef0:	82 10 62 a0 	or  %g1, 0x2a0, %g1                            
40009ef4:	27 10 00 5a 	sethi  %hi(0x40016800), %l3                    
40009ef8:	a6 14 e2 a0 	or  %l3, 0x2a0, %l3	! 40016aa0 <_RTEMS_tasks_Initialize_user_tasks_p>
40009efc:	a6 24 c0 01 	sub  %l3, %g1, %l3                             
  if ( rtems_configuration_is_smp_enabled() && !is_preemptible ) {    
    return false;                                                     
  }                                                                   
#endif                                                                
                                                                      
  for ( i = 0 ; i < _Thread_Control_add_on_count ; ++i ) {            
40009f00:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
40009f04:	84 10 20 00 	clr  %g2                                       
40009f08:	c6 00 61 cc 	ld  [ %g1 + 0x1cc ], %g3                       
40009f0c:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
40009f10:	82 10 61 d0 	or  %g1, 0x1d0, %g1	! 400155d0 <_Thread_Control_add_ons>
40009f14:	80 a0 80 03 	cmp  %g2, %g3                                  
40009f18:	02 80 00 08 	be  40009f38 <_Thread_Initialize+0x64>         
40009f1c:	84 00 a0 01 	inc  %g2                                       
    const Thread_Control_add_on *add_on = &_Thread_Control_add_ons[ i ];
                                                                      
    *(void **) ( (char *) the_thread + add_on->destination_offset ) = 
      (char *) the_thread + add_on->source_offset;                    
40009f20:	de 00 60 04 	ld  [ %g1 + 4 ], %o7                           
#endif                                                                
                                                                      
  for ( i = 0 ; i < _Thread_Control_add_on_count ; ++i ) {            
    const Thread_Control_add_on *add_on = &_Thread_Control_add_ons[ i ];
                                                                      
    *(void **) ( (char *) the_thread + add_on->destination_offset ) = 
40009f24:	c8 00 40 00 	ld  [ %g1 ], %g4                               
      (char *) the_thread + add_on->source_offset;                    
40009f28:	9e 06 40 0f 	add  %i1, %o7, %o7                             
#endif                                                                
                                                                      
  for ( i = 0 ; i < _Thread_Control_add_on_count ; ++i ) {            
    const Thread_Control_add_on *add_on = &_Thread_Control_add_ons[ i ];
                                                                      
    *(void **) ( (char *) the_thread + add_on->destination_offset ) = 
40009f2c:	de 26 40 04 	st  %o7, [ %i1 + %g4 ]                         
40009f30:	10 bf ff f9 	b  40009f14 <_Thread_Initialize+0x40>          
40009f34:	82 00 60 08 	add  %g1, 8, %g1                               
    if ( !actual_stack_size || actual_stack_size < stack_size )       
      return false;                     /* stack allocation failed */ 
                                                                      
    stack = the_thread->Start.stack;                                  
  #else                                                               
    if ( !stack_area ) {                                              
40009f38:	80 a6 e0 00 	cmp  %i3, 0                                    
40009f3c:	12 80 00 0e 	bne  40009f74 <_Thread_Initialize+0xa0>        
40009f40:	c0 26 60 c0 	clr  [ %i1 + 0xc0 ]                            
      actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
40009f44:	90 10 00 19 	mov  %i1, %o0                                  
40009f48:	40 00 03 1d 	call  4000abbc <_Thread_Stack_Allocate>        
40009f4c:	92 10 00 1c 	mov  %i4, %o1                                  
      if ( !actual_stack_size || actual_stack_size < stack_size )     
40009f50:	80 a2 00 1c 	cmp  %o0, %i4                                  
40009f54:	0a 80 00 6e 	bcs  4000a10c <_Thread_Initialize+0x238>       
40009f58:	80 a2 20 00 	cmp  %o0, 0                                    
40009f5c:	02 80 00 6c 	be  4000a10c <_Thread_Initialize+0x238>        <== NEVER TAKEN
40009f60:	82 10 20 01 	mov  1, %g1                                    
        return false;                     /* stack allocation failed */
                                                                      
      stack = the_thread->Start.stack;                                
40009f64:	f6 06 60 bc 	ld  [ %i1 + 0xbc ], %i3                        
      the_thread->Start.core_allocated_stack = true;                  
40009f68:	c2 2e 60 b0 	stb  %g1, [ %i1 + 0xb0 ]                       
40009f6c:	10 80 00 03 	b  40009f78 <_Thread_Initialize+0xa4>          
40009f70:	b8 10 00 08 	mov  %o0, %i4                                  
    } else {                                                          
      stack = stack_area;                                             
      actual_stack_size = stack_size;                                 
      the_thread->Start.core_allocated_stack = false;                 
40009f74:	c0 2e 60 b0 	clrb  [ %i1 + 0xb0 ]                           
  Stack_Control *the_stack,                                           
  void          *starting_address,                                    
  size_t         size                                                 
)                                                                     
{                                                                     
  the_stack->area = starting_address;                                 
40009f78:	f6 26 60 b8 	st  %i3, [ %i1 + 0xb8 ]                        
     stack,                                                           
     actual_stack_size                                                
  );                                                                  
                                                                      
  /* Thread-local storage (TLS) area allocation */                    
  if ( tls_size > 0 ) {                                               
40009f7c:	80 a4 e0 00 	cmp  %l3, 0                                    
40009f80:	12 80 00 0b 	bne  40009fac <_Thread_Initialize+0xd8>        
40009f84:	f8 26 60 b4 	st  %i4, [ %i1 + 0xb4 ]                        
   * create the extension long after tasks have been created          
   * so they cannot rely on the thread create user extension          
   * call.  The object index starts with one, so the first extension context is
   * unused.                                                          
   */                                                                 
  for ( i = 1 ; i <= rtems_configuration_get_maximum_extensions() ; ++i )
40009f88:	05 10 00 55 	sethi  %hi(0x40015400), %g2                    
  Watchdog_Service_routine_entry  routine,                            
  Objects_Id                      id,                                 
  void                           *user_data                           
)                                                                     
{                                                                     
  the_watchdog->state     = WATCHDOG_INACTIVE;                        
40009f8c:	c0 26 60 50 	clr  [ %i1 + 0x50 ]                            
40009f90:	84 10 a1 88 	or  %g2, 0x188, %g2                            
  the_watchdog->routine   = routine;                                  
40009f94:	c0 26 60 64 	clr  [ %i1 + 0x64 ]                            
  the_watchdog->id        = id;                                       
40009f98:	c0 26 60 68 	clr  [ %i1 + 0x68 ]                            
  the_watchdog->user_data = user_data;                                
40009f9c:	c0 26 60 6c 	clr  [ %i1 + 0x6c ]                            
40009fa0:	c6 00 a0 08 	ld  [ %g2 + 8 ], %g3                           
40009fa4:	10 80 00 13 	b  40009ff0 <_Thread_Initialize+0x11c>         
40009fa8:	82 10 20 01 	mov  1, %g1                                    
                                                                      
static inline uintptr_t _TLS_Heap_align_up( uintptr_t val )           
{                                                                     
  uintptr_t msk = CPU_HEAP_ALIGNMENT - 1;                             
                                                                      
  return (val + msk) & ~msk;                                          
40009fac:	13 00 00 00 	sethi  %hi(0), %o1                             
40009fb0:	a6 04 e0 07 	add  %l3, 7, %l3                               
40009fb4:	92 12 60 01 	or  %o1, 1, %o1                                
40009fb8:	a6 0c ff f8 	and  %l3, -8, %l3                              
40009fbc:	92 02 60 07 	add  %o1, 7, %o1                               
40009fc0:	92 0a 7f f8 	and  %o1, -8, %o1                              
                                                                      
static inline uintptr_t _TLS_Get_thread_control_block_area_size(      
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return alignment <= sizeof(TLS_Thread_control_block) ?              
40009fc4:	80 a2 60 08 	cmp  %o1, 8                                    
40009fc8:	1a 80 00 03 	bcc  40009fd4 <_Thread_Initialize+0x100>       <== ALWAYS TAKEN
40009fcc:	82 10 00 09 	mov  %o1, %g1                                  
40009fd0:	82 10 20 08 	mov  8, %g1                                    <== NOT EXECUTED
)                                                                     
{                                                                     
  uintptr_t aligned_size = _TLS_Heap_align_up( size );                
                                                                      
  return _TLS_Get_thread_control_block_area_size( alignment )         
    + aligned_size + sizeof(TLS_Dynamic_thread_vector);               
40009fd4:	90 04 c0 01 	add  %l3, %g1, %o0                             
  if ( tls_size > 0 ) {                                               
    uintptr_t tls_align = _TLS_Heap_align_up( (uintptr_t) _TLS_Alignment );
    uintptr_t tls_alloc = _TLS_Get_allocation_size( tls_size, tls_align );
                                                                      
    the_thread->Start.tls_area =                                      
      _Workspace_Allocate_aligned( tls_alloc, tls_align );            
40009fd8:	40 00 04 f0 	call  4000b398 <_Workspace_Allocate_aligned>   
40009fdc:	90 02 20 08 	add  %o0, 8, %o0                               
                                                                      
    if ( the_thread->Start.tls_area == NULL ) {                       
40009fe0:	80 a2 20 00 	cmp  %o0, 0                                    
40009fe4:	12 bf ff e9 	bne  40009f88 <_Thread_Initialize+0xb4>        <== ALWAYS TAKEN
40009fe8:	d0 26 60 c0 	st  %o0, [ %i1 + 0xc0 ]                        
40009fec:	30 80 00 44 	b,a   4000a0fc <_Thread_Initialize+0x228>      <== NOT EXECUTED
   * create the extension long after tasks have been created          
   * so they cannot rely on the thread create user extension          
   * call.  The object index starts with one, so the first extension context is
   * unused.                                                          
   */                                                                 
  for ( i = 1 ; i <= rtems_configuration_get_maximum_extensions() ; ++i )
40009ff0:	80 a0 40 03 	cmp  %g1, %g3                                  
40009ff4:	18 80 00 06 	bgu  4000a00c <_Thread_Initialize+0x138>       
40009ff8:	89 28 60 02 	sll  %g1, 2, %g4                               
40009ffc:	82 00 60 01 	inc  %g1                                       
4000a000:	88 06 40 04 	add  %i1, %g4, %g4                             
    the_thread->extensions[ i ] = NULL;                               
4000a004:	10 bf ff fb 	b  40009ff0 <_Thread_Initialize+0x11c>         
4000a008:	c0 21 21 58 	clr  [ %g4 + 0x158 ]                           
   *  General initialization                                          
   */                                                                 
                                                                      
  the_thread->Start.is_preemptible   = is_preemptible;                
  the_thread->Start.budget_algorithm = budget_algorithm;              
  the_thread->Start.budget_callout   = budget_callout;                
4000a00c:	c2 07 a0 68 	ld  [ %fp + 0x68 ], %g1                        
                                                                      
  /*                                                                  
   *  General initialization                                          
   */                                                                 
                                                                      
  the_thread->Start.is_preemptible   = is_preemptible;                
4000a010:	e4 2e 60 9c 	stb  %l2, [ %i1 + 0x9c ]                       
  the_thread->Start.budget_algorithm = budget_algorithm;              
4000a014:	e0 26 60 a0 	st  %l0, [ %i1 + 0xa0 ]                        
  the_thread->Start.budget_callout   = budget_callout;                
                                                                      
  switch ( budget_algorithm ) {                                       
4000a018:	80 a4 20 02 	cmp  %l0, 2                                    
4000a01c:	12 80 00 04 	bne  4000a02c <_Thread_Initialize+0x158>       
4000a020:	c2 26 60 a4 	st  %g1, [ %i1 + 0xa4 ]                        
    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 =                                 
4000a024:	c2 00 a0 1c 	ld  [ %g2 + 0x1c ], %g1                        
4000a028:	c2 26 60 74 	st  %g1, [ %i1 + 0x74 ]                        
      case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:                       
	break;                                                               
    #endif                                                            
  }                                                                   
                                                                      
  the_thread->Start.isr_level         = isr_level;                    
4000a02c:	c2 07 a0 6c 	ld  [ %fp + 0x6c ], %g1                        
  _Thread_Debug_set_real_processor( the_thread, cpu );                
                                                                      
  /* Initialize the CPU for the non-SMP schedulers */                 
  _Thread_Set_CPU( the_thread, cpu );                                 
                                                                      
  the_thread->current_state           = STATES_DORMANT;               
4000a030:	b8 10 20 01 	mov  1, %i4                                    
      case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:                       
	break;                                                               
    #endif                                                            
  }                                                                   
                                                                      
  the_thread->Start.isr_level         = isr_level;                    
4000a034:	c2 26 60 a8 	st  %g1, [ %i1 + 0xa8 ]                        
RTEMS_INLINE_ROUTINE void _Scheduler_Node_initialize(                 
  const Scheduler_Control *scheduler,                                 
  Thread_Control          *the_thread                                 
)                                                                     
{                                                                     
  return ( *scheduler->Operations.node_initialize )( scheduler, the_thread );
4000a038:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
4000a03c:	90 10 00 1a 	mov  %i2, %o0                                  
4000a040:	92 10 00 19 	mov  %i1, %o1                                  
  _Thread_Debug_set_real_processor( the_thread, cpu );                
                                                                      
  /* Initialize the CPU for the non-SMP schedulers */                 
  _Thread_Set_CPU( the_thread, cpu );                                 
                                                                      
  the_thread->current_state           = STATES_DORMANT;               
4000a044:	f8 26 60 10 	st  %i4, [ %i1 + 0x10 ]                        
  the_thread->Wait.queue              = NULL;                         
4000a048:	c0 26 60 44 	clr  [ %i1 + 0x44 ]                            
  the_thread->resource_count          = 0;                            
4000a04c:	c0 26 60 1c 	clr  [ %i1 + 0x1c ]                            
  the_thread->real_priority           = priority;                     
4000a050:	fa 26 60 18 	st  %i5, [ %i1 + 0x18 ]                        
4000a054:	9f c0 40 00 	call  %g1                                      
4000a058:	fa 26 60 ac 	st  %i5, [ %i1 + 0xac ]                        
  the_thread->Start.initial_priority  = priority;                     
                                                                      
  _Scheduler_Node_initialize( scheduler, the_thread );                
  scheduler_node_initialized = true;                                  
                                                                      
  _Thread_Set_priority( the_thread, priority );                       
4000a05c:	90 10 00 19 	mov  %i1, %o0                                  
4000a060:	40 00 02 bb 	call  4000ab4c <_Thread_Set_priority>          
4000a064:	92 10 00 1d 	mov  %i5, %o1                                  
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000a068:	82 06 61 38 	add  %i1, 0x138, %g1                           
4000a06c:	84 06 61 3c 	add  %i1, 0x13c, %g2                           
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000a070:	c2 26 61 40 	st  %g1, [ %i1 + 0x140 ]                       
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000a074:	82 06 60 c4 	add  %i1, 0xc4, %g1                            
                                                                      
  head->next = tail;                                                  
4000a078:	c4 26 61 38 	st  %g2, [ %i1 + 0x138 ]                       
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000a07c:	c2 26 60 cc 	st  %g1, [ %i1 + 0xcc ]                        
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000a080:	84 06 60 c8 	add  %i1, 0xc8, %g2                            
RTEMS_INLINE_ROUTINE void _Thread_Action_initialize(                  
  Thread_Action         *action,                                      
  Thread_Action_handler  handler                                      
)                                                                     
{                                                                     
  action->handler = handler;                                          
4000a084:	03 10 00 2a 	sethi  %hi(0x4000a800), %g1                    
4000a088:	82 10 61 d0 	or  %g1, 0x1d0, %g1	! 4000a9d0 <_Thread_Life_action_handler>
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
4000a08c:	c0 26 61 3c 	clr  [ %i1 + 0x13c ]                           
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000a090:	c4 26 60 c4 	st  %g2, [ %i1 + 0xc4 ]                        
  head->previous = NULL;                                              
4000a094:	c0 26 60 c8 	clr  [ %i1 + 0xc8 ]                            
4000a098:	c2 26 61 4c 	st  %g1, [ %i1 + 0x14c ]                       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
4000a09c:	c0 26 61 44 	clr  [ %i1 + 0x144 ]                           
  Objects_Name         name                                           
)                                                                     
{                                                                     
  the_object->name = name;                                            
                                                                      
  _Objects_Set_local_object(                                          
4000a0a0:	c2 16 60 0a 	lduh  [ %i1 + 0xa ], %g1                       
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
4000a0a4:	c4 06 20 1c 	ld  [ %i0 + 0x1c ], %g2                        
                                                                      
static inline void _Timestamp64_implementation_Set_to_zero(           
  Timestamp64_Control *_time                                          
)                                                                     
{                                                                     
  *_time = 0;                                                         
4000a0a8:	c0 26 60 80 	clr  [ %i1 + 0x80 ]                            
4000a0ac:	c0 26 60 84 	clr  [ %i1 + 0x84 ]                            
                                                                      
  _Thread_Action_initialize(                                          
    &the_thread->Life.Action,                                         
    _Thread_Life_action_handler                                       
  );                                                                  
  the_thread->Life.state = THREAD_LIFE_NORMAL;                        
4000a0b0:	c0 26 61 50 	clr  [ %i1 + 0x150 ]                           
  the_thread->Life.terminator = NULL;                                 
4000a0b4:	c0 26 61 54 	clr  [ %i1 + 0x154 ]                           
  Objects_Information *information,                                   
  Objects_Control     *the_object,                                    
  Objects_Name         name                                           
)                                                                     
{                                                                     
  the_object->name = name;                                            
4000a0b8:	e2 26 60 0c 	st  %l1, [ %i1 + 0xc ]                         
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
4000a0bc:	83 28 60 02 	sll  %g1, 2, %g1                               
4000a0c0:	f2 20 80 01 	st  %i1, [ %g2 + %g1 ]                         
 */                                                                   
/**@{**/                                                              
                                                                      
static inline bool _User_extensions_Thread_create( Thread_Control *created )
{                                                                     
  User_extensions_Thread_create_context ctx = { created, true };      
4000a0c4:	f2 27 bf f8 	st  %i1, [ %fp + -8 ]                          
4000a0c8:	f8 2f bf fc 	stb  %i4, [ %fp + -4 ]                         
                                                                      
  _User_extensions_Iterate( &ctx, _User_extensions_Thread_create_visitor );
4000a0cc:	90 07 bf f8 	add  %fp, -8, %o0                              
4000a0d0:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
4000a0d4:	40 00 03 5a 	call  4000ae3c <_User_extensions_Iterate>      
4000a0d8:	92 12 60 f8 	or  %o1, 0xf8, %o1	! 4000acf8 <_User_extensions_Thread_create_visitor>
                                                                      
  return ctx.ok;                                                      
4000a0dc:	f0 0f bf fc 	ldub  [ %fp + -4 ], %i0                        
   *  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 );    
  if ( extension_status )                                             
4000a0e0:	80 8e 20 ff 	btst  0xff, %i0                                
4000a0e4:	32 80 00 0c 	bne,a   4000a114 <_Thread_Initialize+0x240>    
4000a0e8:	b0 0e 20 ff 	and  %i0, 0xff, %i0                            
RTEMS_INLINE_ROUTINE void _Scheduler_Node_destroy(                    
  const Scheduler_Control *scheduler,                                 
  Thread_Control          *the_thread                                 
)                                                                     
{                                                                     
  ( *scheduler->Operations.node_destroy )( scheduler, the_thread );   
4000a0ec:	c2 06 a0 20 	ld  [ %i2 + 0x20 ], %g1                        
4000a0f0:	90 10 00 1a 	mov  %i2, %o0                                  
4000a0f4:	9f c0 40 00 	call  %g1                                      
4000a0f8:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  if ( scheduler_node_initialized ) {                                 
    _Scheduler_Node_destroy( scheduler, the_thread );                 
  }                                                                   
                                                                      
  _Workspace_Free( the_thread->Start.tls_area );                      
4000a0fc:	40 00 04 b0 	call  4000b3bc <_Workspace_Free>               
4000a100:	d0 06 60 c0 	ld  [ %i1 + 0xc0 ], %o0                        
                                                                      
  #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )      
    _Workspace_Free( fp_area );                                       
  #endif                                                              
                                                                      
   _Thread_Stack_Free( the_thread );                                  
4000a104:	40 00 02 be 	call  4000abfc <_Thread_Stack_Free>            
4000a108:	90 10 00 19 	mov  %i1, %o0                                  
    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 )     
        return false;                     /* stack allocation failed */
4000a10c:	b0 10 20 00 	clr  %i0                                       
4000a110:	b0 0e 20 ff 	and  %i0, 0xff, %i0                            
4000a114:	81 c7 e0 08 	ret                                            
4000a118:	81 e8 00 00 	restore                                        
                                                                      

4000a9d0 <_Thread_Life_action_handler>: Thread_Control *executing, Thread_Action *action, Per_CPU_Control *cpu, ISR_Level level ) {
4000a9d0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Thread_Life_state previous_life_state;                              
                                                                      
  (void) action;                                                      
                                                                      
  previous_life_state = executing->Life.state;                        
  executing->Life.state = THREAD_LIFE_PROTECTED;                      
4000a9d4:	82 10 20 01 	mov  1, %g1                                    
{                                                                     
  Thread_Life_state previous_life_state;                              
                                                                      
  (void) action;                                                      
                                                                      
  previous_life_state = executing->Life.state;                        
4000a9d8:	fa 06 21 50 	ld  [ %i0 + 0x150 ], %i5                       
  executing->Life.state = THREAD_LIFE_PROTECTED;                      
4000a9dc:	c2 26 21 50 	st  %g1, [ %i0 + 0x150 ]                       
4000a9e0:	7f ff de 98 	call  40002440 <sparc_enable_interrupts>       
4000a9e4:	90 10 00 1b 	mov  %i3, %o0                                  
                                                                      
  _Thread_Action_release_and_ISR_enable( cpu, level );                
                                                                      
  if ( _Thread_Is_life_terminating( previous_life_state ) ) {         
4000a9e8:	ba 8f 60 04 	andcc  %i5, 4, %i5                             
4000a9ec:	02 80 00 05 	be  4000aa00 <_Thread_Life_action_handler+0x30>
4000a9f0:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
static inline void _User_extensions_Thread_terminate(                 
  Thread_Control *executing                                           
)                                                                     
{                                                                     
  _User_extensions_Iterate(                                           
4000a9f4:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
4000a9f8:	10 80 00 04 	b  4000aa08 <_Thread_Life_action_handler+0x38> 
4000a9fc:	92 12 62 18 	or  %o1, 0x218, %o1	! 4000ae18 <_User_extensions_Thread_terminate_visitor>
  );                                                                  
}                                                                     
                                                                      
static inline void _User_extensions_Thread_restart( Thread_Control *restarted )
{                                                                     
  _User_extensions_Iterate(                                           
4000aa00:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
4000aa04:	92 12 61 80 	or  %o1, 0x180, %o1	! 4000ad80 <_User_extensions_Thread_restart_visitor>
4000aa08:	40 00 01 0d 	call  4000ae3c <_User_extensions_Iterate>      
4000aa0c:	01 00 00 00 	nop                                            
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4000aa10:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
4000aa14:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
4000aa18:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
    _User_extensions_Thread_restart( executing );                     
  }                                                                   
                                                                      
  _Thread_Disable_dispatch();                                         
                                                                      
  if ( _Thread_Is_life_terminating( previous_life_state ) ) {         
4000aa1c:	80 a7 60 00 	cmp  %i5, 0                                    
4000aa20:	22 80 00 0c 	be,a   4000aa50 <_Thread_Life_action_handler+0x80>
4000aa24:	c2 06 21 50 	ld  [ %i0 + 0x150 ], %g1                       
    _Thread_Make_zombie( executing );                                 
4000aa28:	7f ff ff 2a 	call  4000a6d0 <_Thread_Make_zombie>           
4000aa2c:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
    if ( executing->Life.terminator != NULL ) {                       
4000aa30:	d0 06 21 54 	ld  [ %i0 + 0x154 ], %o0                       
4000aa34:	80 a2 20 00 	cmp  %o0, 0                                    
4000aa38:	02 80 00 04 	be  4000aa48 <_Thread_Life_action_handler+0x78>
4000aa3c:	01 00 00 00 	nop                                            
      _Thread_Clear_state(                                            
4000aa40:	7f ff fc 4b 	call  40009b6c <_Thread_Clear_state>           
4000aa44:	13 00 04 00 	sethi  %hi(0x100000), %o1                      
        executing->Life.terminator,                                   
        STATES_WAITING_FOR_TERMINATION                                
      );                                                              
    }                                                                 
                                                                      
    _Thread_Enable_dispatch();                                        
4000aa48:	7f ff fc f4 	call  40009e18 <_Thread_Enable_dispatch>       
4000aa4c:	81 e8 00 00 	restore                                        
                                                                      
    _Assert_Not_reached();                                            
  } else {                                                            
    _Assert( _Thread_Is_life_restarting( previous_life_state ) );     
                                                                      
    if ( _Thread_Is_life_terminating( executing->Life.state ) ) {     
4000aa50:	80 88 60 04 	btst  4, %g1                                   
4000aa54:	22 80 00 04 	be,a   4000aa64 <_Thread_Life_action_handler+0x94><== ALWAYS TAKEN
4000aa58:	90 10 00 18 	mov  %i0, %o0                                  
      /* Someone deleted us in the mean-time */                       
      _Thread_Start_life_change_for_executing( executing );           
4000aa5c:	7f ff ff 45 	call  4000a770 <_Thread_Start_life_change_for_executing><== NOT EXECUTED
4000aa60:	81 e8 00 00 	restore                                        <== NOT EXECUTED
          || executing->current_state == STATES_SUSPENDED             
      );                                                              
                                                                      
      executing->Life.state = THREAD_LIFE_NORMAL;                     
                                                                      
      _Thread_Load_environment( executing );                          
4000aa64:	40 00 0b 79 	call  4000d848 <_Thread_Load_environment>      
4000aa68:	c0 26 21 50 	clr  [ %i0 + 0x150 ]                           
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )        
  if ( executing->fp_context != NULL )                                
    _Context_Restore_fp( &executing->fp_context );                    
#endif                                                                
                                                                      
  _CPU_Context_Restart_self( &executing->Registers );                 
4000aa6c:	40 00 27 d8 	call  400149cc <_CPU_Context_restore>          
4000aa70:	90 06 20 d0 	add  %i0, 0xd0, %o0                            
                                                                      

4000a7b0 <_Thread_Request_life_change>: Thread_Control *the_thread, Thread_Control *executing, Priority_Control priority, Thread_Life_state additional_life_state ) {
4000a7b0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
4000a7b4:	7f ff df 20 	call  40002434 <sparc_disable_interrupts>      
4000a7b8:	01 00 00 00 	nop                                            
  Per_CPU_Control *cpu;                                               
  ISR_Level level;                                                    
  const Scheduler_Control *scheduler;                                 
                                                                      
  cpu = _Thread_Action_ISR_disable_and_acquire( the_thread, &level ); 
  previous_life_state = the_thread->Life.state;                       
4000a7bc:	fa 06 21 50 	ld  [ %i0 + 0x150 ], %i5                       
  the_thread->Life.state = previous_life_state | additional_life_state;
4000a7c0:	82 16 c0 1d 	or  %i3, %i5, %g1                              
4000a7c4:	c2 26 21 50 	st  %g1, [ %i0 + 0x150 ]                       
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
4000a7c8:	7f ff df 1e 	call  40002440 <sparc_enable_interrupts>       
4000a7cc:	01 00 00 00 	nop                                            
  _Thread_Action_release_and_ISR_enable( cpu, level );                
                                                                      
  scheduler = _Scheduler_Get( the_thread );                           
  if ( the_thread == executing ) {                                    
4000a7d0:	80 a6 00 19 	cmp  %i0, %i1                                  
4000a7d4:	12 80 00 0d 	bne  4000a808 <_Thread_Request_life_change+0x58>
4000a7d8:	80 a7 60 00 	cmp  %i5, 0                                    
  Priority_Control         priority                                   
)                                                                     
{                                                                     
  Priority_Control current = the_thread->current_priority;            
                                                                      
  if ( _Scheduler_Is_priority_higher_than( scheduler, priority, current ) ) {
4000a7dc:	d2 06 20 14 	ld  [ %i0 + 0x14 ], %o1                        
    executing->real_priority = priority;                              
4000a7e0:	f4 26 20 18 	st  %i2, [ %i0 + 0x18 ]                        
4000a7e4:	7f ff ff d8 	call  4000a744 <_Scheduler_Is_priority_higher_than.constprop.19>
4000a7e8:	90 10 00 1a 	mov  %i2, %o0                                  
4000a7ec:	80 a2 20 00 	cmp  %o0, 0                                    
4000a7f0:	02 80 00 04 	be  4000a800 <_Thread_Request_life_change+0x50><== ALWAYS TAKEN
4000a7f4:	90 10 00 18 	mov  %i0, %o0                                  
    _Thread_Set_priority( the_thread, priority );                     
4000a7f8:	40 00 00 d5 	call  4000ab4c <_Thread_Set_priority>          <== NOT EXECUTED
4000a7fc:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
                                                                      
    _Scheduler_Set_priority_if_higher( scheduler, the_thread, priority );
    _Thread_Start_life_change_for_executing( executing );             
4000a800:	7f ff ff dc 	call  4000a770 <_Thread_Start_life_change_for_executing>
4000a804:	81 e8 00 00 	restore                                        
  } else if ( previous_life_state == THREAD_LIFE_NORMAL ) {           
4000a808:	12 80 00 27 	bne  4000a8a4 <_Thread_Request_life_change+0xf4>
4000a80c:	90 10 00 18 	mov  %i0, %o0                                  
  Thread_Control          *the_thread,                                
  const Scheduler_Control *scheduler,                                 
  Priority_Control         priority                                   
)                                                                     
{                                                                     
  the_thread->is_preemptible   = the_thread->Start.is_preemptible;    
4000a810:	c2 0e 20 9c 	ldub  [ %i0 + 0x9c ], %g1                      
  the_thread->budget_algorithm = the_thread->Start.budget_algorithm;  
  the_thread->budget_callout   = the_thread->Start.budget_callout;    
  the_thread->real_priority    = priority;                            
                                                                      
  _Thread_Set_state( the_thread, STATES_RESTARTING );                 
4000a814:	13 00 20 00 	sethi  %hi(0x800000), %o1                      
  Thread_Control          *the_thread,                                
  const Scheduler_Control *scheduler,                                 
  Priority_Control         priority                                   
)                                                                     
{                                                                     
  the_thread->is_preemptible   = the_thread->Start.is_preemptible;    
4000a818:	c2 2e 20 70 	stb  %g1, [ %i0 + 0x70 ]                       
  the_thread->budget_algorithm = the_thread->Start.budget_algorithm;  
4000a81c:	c2 06 20 a0 	ld  [ %i0 + 0xa0 ], %g1                        
4000a820:	c2 26 20 78 	st  %g1, [ %i0 + 0x78 ]                        
  the_thread->budget_callout   = the_thread->Start.budget_callout;    
4000a824:	c2 06 20 a4 	ld  [ %i0 + 0xa4 ], %g1                        
  the_thread->real_priority    = priority;                            
4000a828:	f4 26 20 18 	st  %i2, [ %i0 + 0x18 ]                        
                                                                      
  _Thread_Set_state( the_thread, STATES_RESTARTING );                 
4000a82c:	40 00 00 d2 	call  4000ab74 <_Thread_Set_state>             
4000a830:	c2 26 20 7c 	st  %g1, [ %i0 + 0x7c ]                        
  _Thread_queue_Extract_with_proxy( the_thread );                     
4000a834:	40 00 0c 51 	call  4000d978 <_Thread_queue_Extract_with_proxy>
4000a838:	90 10 00 18 	mov  %i0, %o0                                  
  _Watchdog_Remove( &the_thread->Timer );                             
4000a83c:	40 00 02 17 	call  4000b098 <_Watchdog_Remove>              
4000a840:	90 06 20 48 	add  %i0, 0x48, %o0                            
  Priority_Control         priority                                   
)                                                                     
{                                                                     
  Priority_Control current = the_thread->current_priority;            
                                                                      
  if ( _Scheduler_Is_priority_higher_than( scheduler, priority, current ) ) {
4000a844:	d2 06 20 14 	ld  [ %i0 + 0x14 ], %o1                        
4000a848:	7f ff ff bf 	call  4000a744 <_Scheduler_Is_priority_higher_than.constprop.19>
4000a84c:	90 10 00 1a 	mov  %i2, %o0                                  
4000a850:	80 a2 20 00 	cmp  %o0, 0                                    
4000a854:	02 80 00 04 	be  4000a864 <_Thread_Request_life_change+0xb4>
4000a858:	90 10 00 18 	mov  %i0, %o0                                  
    _Thread_Set_priority( the_thread, priority );                     
4000a85c:	40 00 00 bc 	call  4000ab4c <_Thread_Set_priority>          
4000a860:	92 10 00 1a 	mov  %i2, %o1                                  
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
4000a864:	7f ff de f4 	call  40002434 <sparc_disable_interrupts>      
4000a868:	01 00 00 00 	nop                                            
RTEMS_INLINE_ROUTINE void _Chain_Append_if_is_off_chain_unprotected(  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  if ( _Chain_Is_node_off_chain( the_node ) ) {                       
4000a86c:	c2 06 21 44 	ld  [ %i0 + 0x144 ], %g1                       
4000a870:	80 a0 60 00 	cmp  %g1, 0                                    
4000a874:	12 80 00 08 	bne  4000a894 <_Thread_Request_life_change+0xe4><== NEVER TAKEN
4000a878:	84 06 21 44 	add  %i0, 0x144, %g2                           
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000a87c:	c2 06 20 cc 	ld  [ %i0 + 0xcc ], %g1                        
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000a880:	86 06 20 c8 	add  %i0, 0xc8, %g3                            
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
  tail->previous = the_node;                                          
4000a884:	c4 26 20 cc 	st  %g2, [ %i0 + 0xcc ]                        
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4000a888:	c6 26 21 44 	st  %g3, [ %i0 + 0x144 ]                       
  tail->previous = the_node;                                          
  old_last->next = the_node;                                          
4000a88c:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000a890:	c2 26 21 48 	st  %g1, [ %i0 + 0x148 ]                       
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
4000a894:	7f ff de eb 	call  40002440 <sparc_enable_interrupts>       
4000a898:	01 00 00 00 	nop                                            
  _Scheduler_Set_priority_if_higher( scheduler, the_thread, priority );
  _Thread_Add_post_switch_action( the_thread, &the_thread->Life.Action );
  _Thread_Ready( the_thread );                                        
4000a89c:	40 00 0c 5f 	call  4000da18 <_Thread_Ready>                 
4000a8a0:	81 e8 00 00 	restore                                        
    _Scheduler_Set_priority_if_higher( scheduler, the_thread, priority );
    _Thread_Start_life_change_for_executing( executing );             
  } else if ( previous_life_state == THREAD_LIFE_NORMAL ) {           
    _Thread_Start_life_change( the_thread, scheduler, priority );     
  } else {                                                            
    _Thread_Clear_state( the_thread, STATES_SUSPENDED );              
4000a8a4:	7f ff fc b2 	call  40009b6c <_Thread_Clear_state>           
4000a8a8:	92 10 20 02 	mov  2, %o1                                    
                                                                      
    if ( _Thread_Is_life_terminating( additional_life_state ) ) {     
4000a8ac:	80 8e e0 04 	btst  4, %i3                                   
4000a8b0:	02 80 00 12 	be  4000a8f8 <_Thread_Request_life_change+0x148><== NEVER TAKEN
4000a8b4:	92 10 00 1a 	mov  %i2, %o1                                  
      the_thread->real_priority = _Scheduler_Highest_priority_of_two( 
4000a8b8:	fa 06 20 18 	ld  [ %i0 + 0x18 ], %i5                        
  const Scheduler_Control *scheduler,                                 
  Priority_Control         p1,                                        
  Priority_Control         p2                                         
)                                                                     
{                                                                     
  return _Scheduler_Is_priority_higher_than( scheduler, p1, p2 ) ? p1 : p2;
4000a8bc:	7f ff ff a2 	call  4000a744 <_Scheduler_Is_priority_higher_than.constprop.19>
4000a8c0:	90 10 00 1d 	mov  %i5, %o0                                  
4000a8c4:	80 a2 20 00 	cmp  %o0, 0                                    
4000a8c8:	02 80 00 03 	be  4000a8d4 <_Thread_Request_life_change+0x124><== ALWAYS TAKEN
4000a8cc:	82 10 00 1a 	mov  %i2, %g1                                  
4000a8d0:	82 10 00 1d 	mov  %i5, %g1                                  <== NOT EXECUTED
  bool                     prepend_it                                 
)                                                                     
{                                                                     
  Priority_Control current = the_thread->current_priority;            
                                                                      
  if ( _Scheduler_Is_priority_higher_than( scheduler, priority, current ) ) {
4000a8d4:	d2 06 20 14 	ld  [ %i0 + 0x14 ], %o1                        
4000a8d8:	c2 26 20 18 	st  %g1, [ %i0 + 0x18 ]                        
4000a8dc:	7f ff ff 9a 	call  4000a744 <_Scheduler_Is_priority_higher_than.constprop.19>
4000a8e0:	90 10 00 1a 	mov  %i2, %o0                                  
4000a8e4:	80 a2 20 00 	cmp  %o0, 0                                    
4000a8e8:	02 80 00 04 	be  4000a8f8 <_Thread_Request_life_change+0x148><== NEVER TAKEN
4000a8ec:	b2 10 00 1a 	mov  %i2, %i1                                  
    _Thread_Change_priority( the_thread, priority, prepend_it );      
4000a8f0:	7f ff fc 5d 	call  40009a64 <_Thread_Change_priority>       
4000a8f4:	95 e8 20 00 	restore  %g0, 0, %o2                           
4000a8f8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000a8fc:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000abfc <_Thread_Stack_Free>: #include <rtems/config.h> void _Thread_Stack_Free( Thread_Control *the_thread ) {
4000abfc:	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 )                    
4000ac00:	c4 0e 20 b0 	ldub  [ %i0 + 0xb0 ], %g2                      
                                                                      
void _Thread_Stack_Free(                                              
  Thread_Control *the_thread                                          
)                                                                     
{                                                                     
  rtems_stack_free_hook stack_free_hook =                             
4000ac04:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
                                                                      
  #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 )                    
4000ac08:	80 a0 a0 00 	cmp  %g2, 0                                    
4000ac0c:	02 80 00 04 	be  4000ac1c <_Thread_Stack_Free+0x20>         <== NEVER TAKEN
4000ac10:	c2 00 61 bc 	ld  [ %g1 + 0x1bc ], %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.            
   */                                                                 
                                                                      
  (*stack_free_hook)( the_thread->Start.Initial_stack.area );         
4000ac14:	9f c0 40 00 	call  %g1                                      
4000ac18:	d0 06 20 b8 	ld  [ %i0 + 0xb8 ], %o0                        
4000ac1c:	81 c7 e0 08 	ret                                            
4000ac20:	81 e8 00 00 	restore                                        
                                                                      

4000a770 <_Thread_Start_life_change_for_executing>: } static void _Thread_Start_life_change_for_executing( Thread_Control *executing ) {
4000a770:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
4000a774:	7f ff df 30 	call  40002434 <sparc_disable_interrupts>      
4000a778:	ba 10 00 18 	mov  %i0, %i5                                  
4000a77c:	b0 10 00 08 	mov  %o0, %i0                                  
RTEMS_INLINE_ROUTINE void _Chain_Append_if_is_off_chain_unprotected(  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  if ( _Chain_Is_node_off_chain( the_node ) ) {                       
4000a780:	c2 07 61 44 	ld  [ %i5 + 0x144 ], %g1                       
4000a784:	80 a0 60 00 	cmp  %g1, 0                                    
4000a788:	12 80 00 08 	bne  4000a7a8 <_Thread_Start_life_change_for_executing+0x38><== NEVER TAKEN
4000a78c:	84 07 61 44 	add  %i5, 0x144, %g2                           
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000a790:	c2 07 60 cc 	ld  [ %i5 + 0xcc ], %g1                        
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000a794:	86 07 60 c8 	add  %i5, 0xc8, %g3                            
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
  tail->previous = the_node;                                          
4000a798:	c4 27 60 cc 	st  %g2, [ %i5 + 0xcc ]                        
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4000a79c:	c6 27 61 44 	st  %g3, [ %i5 + 0x144 ]                       
  tail->previous = the_node;                                          
  old_last->next = the_node;                                          
4000a7a0:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000a7a4:	c2 27 61 48 	st  %g1, [ %i5 + 0x148 ]                       
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
4000a7a8:	7f ff df 26 	call  40002440 <sparc_enable_interrupts>       
4000a7ac:	81 e8 00 00 	restore                                        
                                                                      

4000acc0 <_Thread_Yield>: #include <rtems/score/threadimpl.h> #include <rtems/score/schedulerimpl.h> void _Thread_Yield( Thread_Control *executing ) {
4000acc0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level level;                                                    
                                                                      
  _ISR_Disable( level );                                              
4000acc4:	7f ff dd dc 	call  40002434 <sparc_disable_interrupts>      
4000acc8:	ba 10 00 18 	mov  %i0, %i5                                  
4000accc:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
  if ( _States_Is_ready( executing->current_state ) ) {               
4000acd0:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000acd4:	80 a0 60 00 	cmp  %g1, 0                                    
4000acd8:	12 80 00 06 	bne  4000acf0 <_Thread_Yield+0x30>             <== NEVER TAKEN
4000acdc:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    
RTEMS_INLINE_ROUTINE void _Scheduler_Yield(                           
  const Scheduler_Control *scheduler,                                 
  Thread_Control          *the_thread                                 
)                                                                     
{                                                                     
  ( *scheduler->Operations.yield )( scheduler, the_thread );          
4000ace0:	90 12 22 6c 	or  %o0, 0x26c, %o0	! 4001566c <_Scheduler_Table>
4000ace4:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
4000ace8:	9f c0 40 00 	call  %g1                                      
4000acec:	92 10 00 1d 	mov  %i5, %o1                                  
    _Scheduler_Yield( _Scheduler_Get( executing ), executing );       
  }                                                                   
                                                                      
  _ISR_Enable( level );                                               
4000acf0:	7f ff dd d4 	call  40002440 <sparc_enable_interrupts>       
4000acf4:	81 e8 00 00 	restore                                        
                                                                      

400143f4 <_Thread_queue_First_fifo>: */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next;
400143f4:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
400143f8:	90 02 20 04 	add  %o0, 4, %o0                               <== NOT EXECUTED
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty( &the_thread_queue->Queues.Fifo ) )           
    return (Thread_Control *) _Chain_First( &the_thread_queue->Queues.Fifo );
                                                                      
  return NULL;                                                        
400143fc:	90 18 40 08 	xor  %g1, %o0, %o0                             <== NOT EXECUTED
40014400:	80 a0 00 08 	cmp  %g0, %o0                                  <== NOT EXECUTED
40014404:	90 60 20 00 	subx  %g0, 0, %o0                              <== NOT EXECUTED
}                                                                     
40014408:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
4001440c:	90 08 40 08 	and  %g1, %o0, %o0                             <== NOT EXECUTED
                                                                      

4000a694 <_Thread_queue_Timeout>: void _Thread_queue_Timeout( Objects_Id id, void *ignored __attribute__((unused)) ) {
4000a694:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Thread_Control       *the_thread;                                   
  Objects_Locations     location;                                     
                                                                      
  the_thread = _Thread_Get( id, &location );                          
4000a698:	90 10 00 18 	mov  %i0, %o0                                  
4000a69c:	7f ff fd ea 	call  40009e44 <_Thread_Get>                   
4000a6a0:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
4000a6a4:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000a6a8:	80 a0 60 00 	cmp  %g1, 0                                    
4000a6ac:	12 80 00 07 	bne  4000a6c8 <_Thread_queue_Timeout+0x34>     <== NEVER TAKEN
4000a6b0:	01 00 00 00 	nop                                            
#if defined(RTEMS_MULTIPROCESSING)                                    
    case OBJECTS_REMOTE:  /* impossible */                            
#endif                                                                
      break;                                                          
    case OBJECTS_LOCAL:                                               
      _Thread_queue_Process_timeout( the_thread );                    
4000a6b4:	40 00 0c bb 	call  4000d9a0 <_Thread_queue_Process_timeout> 
4000a6b8:	01 00 00 00 	nop                                            
   *                                                                  
   * This routine decrements the thread dispatch level.               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_decrement_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4000a6bc:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable( level );                                            
#endif                                                                
                                                                      
    --disable_level;                                                  
4000a6c0:	84 00 bf ff 	add  %g2, -1, %g2                              
    _Thread_Dispatch_disable_level = disable_level;                   
4000a6c4:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
4000a6c8:	81 c7 e0 08 	ret                                            
4000a6cc:	81 e8 00 00 	restore                                        
                                                                      

40008d4c <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) {
40008d4c:	9d e3 bf 88 	save  %sp, -120, %sp                           
static void _Timer_server_Process_interval_watchdogs(                 
  Timer_server_Watchdogs *watchdogs,                                  
  Chain_Control *fire_chain                                           
)                                                                     
{                                                                     
  Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;            
40008d50:	2b 10 00 67 	sethi  %hi(0x40019c00), %l5                    
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40008d54:	b2 07 bf e8 	add  %fp, -24, %i1                             
40008d58:	a0 07 bf ec 	add  %fp, -20, %l0                             
40008d5c:	b8 07 bf f4 	add  %fp, -12, %i4                             
40008d60:	b6 07 bf f8 	add  %fp, -8, %i3                              
40008d64:	e0 27 bf e8 	st  %l0, [ %fp + -24 ]                         
  head->previous = NULL;                                              
40008d68:	c0 27 bf ec 	clr  [ %fp + -20 ]                             
  tail->previous = head;                                              
40008d6c:	f2 27 bf f0 	st  %i1, [ %fp + -16 ]                         
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40008d70:	f6 27 bf f4 	st  %i3, [ %fp + -12 ]                         
  head->previous = NULL;                                              
40008d74:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
  tail->previous = head;                                              
40008d78:	f8 27 bf fc 	st  %i4, [ %fp + -4 ]                          
   */                                                                 
  Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;      
                                                                      
  watchdogs->last_snapshot = snapshot;                                
                                                                      
  _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );  
40008d7c:	a2 06 20 30 	add  %i0, 0x30, %l1                            
     /*                                                               
      *  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 ); 
40008d80:	b4 06 20 68 	add  %i0, 0x68, %i2                            
#endif                                                                
                                                                      
      _Timer_server_SMP_lock_release();                               
      _Timer_server_SMP_lock_aquire();                                
                                                                      
      ts->active = true;                                              
40008d84:	a8 10 20 01 	mov  1, %l4                                    
                                                                      
static void _Timer_server_Stop_interval_system_watchdog(              
  Timer_server_Control *ts                                            
)                                                                     
{                                                                     
  _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );        
40008d88:	a6 06 20 08 	add  %i0, 8, %l3                               
                                                                      
static void _Timer_server_Stop_tod_system_watchdog(                   
  Timer_server_Control *ts                                            
)                                                                     
{                                                                     
  _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );             
40008d8c:	a4 06 20 40 	add  %i0, 0x40, %l2                            
{                                                                     
  /*                                                                  
   *  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;                                    
40008d90:	f2 26 20 78 	st  %i1, [ %i0 + 0x78 ]                        
static void _Timer_server_Process_interval_watchdogs(                 
  Timer_server_Watchdogs *watchdogs,                                  
  Chain_Control *fire_chain                                           
)                                                                     
{                                                                     
  Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;            
40008d94:	c2 05 63 60 	ld  [ %l5 + 0x360 ], %g1                       
                                                                      
  /*                                                                  
   *  We assume adequate unsigned arithmetic here.                    
   */                                                                 
  Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;      
40008d98:	d2 06 20 3c 	ld  [ %i0 + 0x3c ], %o1                        
                                                                      
  watchdogs->last_snapshot = snapshot;                                
                                                                      
  _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );  
40008d9c:	94 10 00 1c 	mov  %i4, %o2                                  
40008da0:	90 10 00 11 	mov  %l1, %o0                                  
40008da4:	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;                                
40008da8:	c2 26 20 3c 	st  %g1, [ %i0 + 0x3c ]                        
                                                                      
  _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );  
40008dac:	40 00 0e 41 	call  4000c6b0 <_Watchdog_Adjust_to_chain>     
40008db0:	01 00 00 00 	nop                                            
static void _Timer_server_Process_tod_watchdogs(                      
  Timer_server_Watchdogs *watchdogs,                                  
  Chain_Control *fire_chain                                           
)                                                                     
{                                                                     
  Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
40008db4:	40 00 03 58 	call  40009b14 <_TOD_Seconds_since_epoch>      
40008db8:	01 00 00 00 	nop                                            
  Watchdog_Interval last_snapshot = watchdogs->last_snapshot;         
40008dbc:	d4 06 20 74 	ld  [ %i0 + 0x74 ], %o2                        
  /*                                                                  
   *  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 ) {                                   
40008dc0:	80 a2 00 0a 	cmp  %o0, %o2                                  
40008dc4:	08 80 00 07 	bleu  40008de0 <_Timer_server_Body+0x94>       
40008dc8:	ba 10 00 08 	mov  %o0, %i5                                  
    /*                                                                
     *  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 );
40008dcc:	92 27 40 0a 	sub  %i5, %o2, %o1                             
40008dd0:	90 10 00 1a 	mov  %i2, %o0                                  
40008dd4:	40 00 0e 37 	call  4000c6b0 <_Watchdog_Adjust_to_chain>     
40008dd8:	94 10 00 1c 	mov  %i4, %o2                                  
40008ddc:	30 80 00 06 	b,a   40008df4 <_Timer_server_Body+0xa8>       
                                                                      
  } else if ( snapshot < last_snapshot ) {                            
40008de0:	1a 80 00 05 	bcc  40008df4 <_Timer_server_Body+0xa8>        
40008de4:	90 10 00 1a 	mov  %i2, %o0                                  
     /*                                                               
      *  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 ); 
40008de8:	92 10 20 01 	mov  1, %o1                                    
40008dec:	40 00 0e 09 	call  4000c610 <_Watchdog_Adjust>              
40008df0:	94 22 80 1d 	sub  %o2, %i5, %o2                             
  }                                                                   
                                                                      
  watchdogs->last_snapshot = snapshot;                                
40008df4:	fa 26 20 74 	st  %i5, [ %i0 + 0x74 ]                        
}                                                                     
                                                                      
static void _Timer_server_Process_insertions( Timer_server_Control *ts )
{                                                                     
  while ( true ) {                                                    
    Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
40008df8:	d0 06 20 78 	ld  [ %i0 + 0x78 ], %o0                        
40008dfc:	40 00 02 29 	call  400096a0 <_Chain_Get>                    
40008e00:	01 00 00 00 	nop                                            
                                                                      
    if ( timer == NULL ) {                                            
40008e04:	92 92 20 00 	orcc  %o0, 0, %o1                              
40008e08:	02 80 00 0c 	be  40008e38 <_Timer_server_Body+0xec>         
40008e0c:	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 ) {                 
40008e10:	c2 02 60 38 	ld  [ %o1 + 0x38 ], %g1                        
40008e14:	80 a0 60 01 	cmp  %g1, 1                                    
40008e18:	02 80 00 05 	be  40008e2c <_Timer_server_Body+0xe0>         
40008e1c:	90 10 00 11 	mov  %l1, %o0                                  
    _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
  } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {       
40008e20:	80 a0 60 03 	cmp  %g1, 3                                    
40008e24:	12 bf ff f5 	bne  40008df8 <_Timer_server_Body+0xac>        <== NEVER TAKEN
40008e28:	90 10 00 1a 	mov  %i2, %o0                                  
    _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );     
40008e2c:	40 00 0e 4b 	call  4000c758 <_Watchdog_Insert>              
40008e30:	92 02 60 10 	add  %o1, 0x10, %o1                            
40008e34:	30 bf ff f1 	b,a   40008df8 <_Timer_server_Body+0xac>       
     *  of zero it will be processed in the next iteration of the timer server
     *  body loop.                                                    
     */                                                               
    _Timer_server_Process_insertions( ts );                           
                                                                      
    _ISR_Disable( level );                                            
40008e38:	7f ff e7 df 	call  40002db4 <sparc_disable_interrupts>      
40008e3c:	01 00 00 00 	nop                                            
    if ( _Chain_Is_empty( insert_chain ) ) {                          
40008e40:	c2 07 bf e8 	ld  [ %fp + -24 ], %g1                         
40008e44:	80 a0 40 10 	cmp  %g1, %l0                                  
40008e48:	12 80 00 0a 	bne  40008e70 <_Timer_server_Body+0x124>       <== NEVER TAKEN
40008e4c:	01 00 00 00 	nop                                            
      ts->insert_chain = NULL;                                        
40008e50:	c0 26 20 78 	clr  [ %i0 + 0x78 ]                            
      _ISR_Enable( level );                                           
40008e54:	7f ff e7 db 	call  40002dc0 <sparc_enable_interrupts>       
40008e58:	01 00 00 00 	nop                                            
  _Timer_server_SMP_lock_aquire();                                    
                                                                      
  while ( true ) {                                                    
    _Timer_server_Get_watchdogs_that_fire_now( ts, &insert_chain, &fire_chain );
                                                                      
    if ( !_Chain_Is_empty( &fire_chain ) ) {                          
40008e5c:	c2 07 bf f4 	ld  [ %fp + -12 ], %g1                         
40008e60:	80 a0 40 1b 	cmp  %g1, %i3                                  
40008e64:	12 80 00 06 	bne  40008e7c <_Timer_server_Body+0x130>       
40008e68:	01 00 00 00 	nop                                            
40008e6c:	30 80 00 18 	b,a   40008ecc <_Timer_server_Body+0x180>      
      ts->insert_chain = NULL;                                        
      _ISR_Enable( level );                                           
                                                                      
      break;                                                          
    } else {                                                          
      _ISR_Enable( level );                                           
40008e70:	7f ff e7 d4 	call  40002dc0 <sparc_enable_interrupts>       <== NOT EXECUTED
40008e74:	01 00 00 00 	nop                                            <== NOT EXECUTED
40008e78:	30 bf ff c7 	b,a   40008d94 <_Timer_server_Body+0x48>       <== NOT EXECUTED
                                                                      
        /*                                                            
         *  It is essential that interrupts are disable here since an interrupt
         *  service routine may remove a watchdog from the chain.     
         */                                                           
        _ISR_Disable( level );                                        
40008e7c:	7f ff e7 ce 	call  40002db4 <sparc_disable_interrupts>      
40008e80:	01 00 00 00 	nop                                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40008e84:	fa 07 bf f4 	ld  [ %fp + -12 ], %i5                         
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40008e88:	80 a7 40 1b 	cmp  %i5, %i3                                  
40008e8c:	02 80 00 0d 	be  40008ec0 <_Timer_server_Body+0x174>        
40008e90:	01 00 00 00 	nop                                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40008e94:	c2 07 40 00 	ld  [ %i5 ], %g1                               
                                                                      
  head->next = new_first;                                             
  new_first->previous = head;                                         
40008e98:	f8 20 60 04 	st  %i4, [ %g1 + 4 ]                           
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
                                                                      
  head->next = new_first;                                             
40008e9c:	c2 27 bf f4 	st  %g1, [ %fp + -12 ]                         
        watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
        if ( watchdog != NULL ) {                                     
          watchdog->state = WATCHDOG_INACTIVE;                        
40008ea0:	c0 27 60 08 	clr  [ %i5 + 8 ]                               
          _ISR_Enable( level );                                       
40008ea4:	7f ff e7 c7 	call  40002dc0 <sparc_enable_interrupts>       
40008ea8:	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 );    
40008eac:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
40008eb0:	d0 07 60 20 	ld  [ %i5 + 0x20 ], %o0                        
40008eb4:	9f c0 40 00 	call  %g1                                      
40008eb8:	d2 07 60 24 	ld  [ %i5 + 0x24 ], %o1                        
40008ebc:	30 bf ff f0 	b,a   40008e7c <_Timer_server_Body+0x130>      
        watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
        if ( watchdog != NULL ) {                                     
          watchdog->state = WATCHDOG_INACTIVE;                        
          _ISR_Enable( level );                                       
        } else {                                                      
          _ISR_Enable( level );                                       
40008ec0:	7f ff e7 c0 	call  40002dc0 <sparc_enable_interrupts>       
40008ec4:	01 00 00 00 	nop                                            
40008ec8:	30 bf ff b2 	b,a   40008d90 <_Timer_server_Body+0x44>       
        (*watchdog->routine)( watchdog->id, watchdog->user_data );    
                                                                      
        _Timer_server_SMP_lock_aquire();                              
      }                                                               
    } else {                                                          
      ts->active = false;                                             
40008ecc:	c0 2e 20 7c 	clrb  [ %i0 + 0x7c ]                           
#if defined ( __THREAD_DO_NOT_INLINE_DISABLE_DISPATCH__ )             
void _Thread_Disable_dispatch( void );                                
#else                                                                 
RTEMS_INLINE_ROUTINE void _Thread_Disable_dispatch( void )            
{                                                                     
  _Thread_Dispatch_increment_disable_level();                         
40008ed0:	7f ff ff 72 	call  40008c98 <_Thread_Dispatch_increment_disable_level>
40008ed4:	01 00 00 00 	nop                                            
       *  Block until there is something to do.                       
       */                                                             
#if !defined( RTEMS_SMP )                                             
      _Thread_Disable_dispatch();                                     
#endif                                                                
        _Thread_Set_state( ts->thread, STATES_DELAYING );             
40008ed8:	d0 06 00 00 	ld  [ %i0 ], %o0                               
40008edc:	40 00 0c d9 	call  4000c240 <_Thread_Set_state>             
40008ee0:	92 10 20 08 	mov  8, %o1                                    
        _Timer_server_Reset_interval_system_watchdog( ts );           
40008ee4:	7f ff ff 72 	call  40008cac <_Timer_server_Reset_interval_system_watchdog>
40008ee8:	90 10 00 18 	mov  %i0, %o0                                  
        _Timer_server_Reset_tod_system_watchdog( ts );                
40008eec:	7f ff ff 84 	call  40008cfc <_Timer_server_Reset_tod_system_watchdog>
40008ef0:	90 10 00 18 	mov  %i0, %o0                                  
#if !defined( RTEMS_SMP )                                             
      _Thread_Enable_dispatch();                                      
40008ef4:	40 00 09 7c 	call  4000b4e4 <_Thread_Enable_dispatch>       
40008ef8:	01 00 00 00 	nop                                            
                                                                      
static void _Timer_server_Stop_interval_system_watchdog(              
  Timer_server_Control *ts                                            
)                                                                     
{                                                                     
  _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );        
40008efc:	90 10 00 13 	mov  %l3, %o0                                  
#endif                                                                
                                                                      
      _Timer_server_SMP_lock_release();                               
      _Timer_server_SMP_lock_aquire();                                
                                                                      
      ts->active = true;                                              
40008f00:	e8 2e 20 7c 	stb  %l4, [ %i0 + 0x7c ]                       
                                                                      
static void _Timer_server_Stop_interval_system_watchdog(              
  Timer_server_Control *ts                                            
)                                                                     
{                                                                     
  _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );        
40008f04:	40 00 0e 6a 	call  4000c8ac <_Watchdog_Remove>              
40008f08:	01 00 00 00 	nop                                            
                                                                      
static void _Timer_server_Stop_tod_system_watchdog(                   
  Timer_server_Control *ts                                            
)                                                                     
{                                                                     
  _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );             
40008f0c:	40 00 0e 68 	call  4000c8ac <_Watchdog_Remove>              
40008f10:	90 10 00 12 	mov  %l2, %o0                                  
40008f14:	30 bf ff 9f 	b,a   40008d90 <_Timer_server_Body+0x44>       
                                                                      

40008f18 <_Timer_server_Schedule_operation_method>: static void _Timer_server_Schedule_operation_method( Timer_server_Control *ts, Timer_Control *timer ) {
40008f18:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ( ts->insert_chain == NULL ) {                                   
40008f1c:	c2 06 20 78 	ld  [ %i0 + 0x78 ], %g1                        
40008f20:	80 a0 60 00 	cmp  %g1, 0                                    
40008f24:	12 80 00 4b 	bne  40009050 <_Timer_server_Schedule_operation_method+0x138>
40008f28:	ba 10 00 19 	mov  %i1, %i5                                  
40008f2c:	7f ff ff 5b 	call  40008c98 <_Thread_Dispatch_increment_disable_level>
40008f30:	01 00 00 00 	nop                                            
   *  being inserted.  This could result in an integer overflow.      
   */                                                                 
                                                                      
  _Thread_Disable_dispatch();                                         
                                                                      
  if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {                 
40008f34:	c2 06 60 38 	ld  [ %i1 + 0x38 ], %g1                        
40008f38:	80 a0 60 01 	cmp  %g1, 1                                    
40008f3c:	12 80 00 1f 	bne  40008fb8 <_Timer_server_Schedule_operation_method+0xa0>
40008f40:	80 a0 60 03 	cmp  %g1, 3                                    
    /*                                                                
     *  We have to advance the last known ticks value of the server and update
     *  the watchdog chain accordingly.                               
     */                                                               
    _ISR_Disable( level );                                            
40008f44:	7f ff e7 9c 	call  40002db4 <sparc_disable_interrupts>      
40008f48:	01 00 00 00 	nop                                            
    snapshot = _Watchdog_Ticks_since_boot;                            
40008f4c:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
40008f50:	c4 00 63 60 	ld  [ %g1 + 0x360 ], %g2	! 40019f60 <_Watchdog_Ticks_since_boot>
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40008f54:	c2 06 20 30 	ld  [ %i0 + 0x30 ], %g1                        
    last_snapshot = ts->Interval_watchdogs.last_snapshot;             
40008f58:	c8 06 20 3c 	ld  [ %i0 + 0x3c ], %g4                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40008f5c:	86 06 20 34 	add  %i0, 0x34, %g3                            
    if ( !_Chain_Is_empty( &ts->Interval_watchdogs.Chain ) ) {        
40008f60:	80 a0 40 03 	cmp  %g1, %g3                                  
40008f64:	02 80 00 08 	be  40008f84 <_Timer_server_Schedule_operation_method+0x6c>
40008f68:	88 20 80 04 	sub  %g2, %g4, %g4                             
      /*                                                              
       *  We assume adequate unsigned arithmetic here.                
       */                                                             
      delta = snapshot - last_snapshot;                               
                                                                      
      delta_interval = first_watchdog->delta_interval;                
40008f6c:	f8 00 60 10 	ld  [ %g1 + 0x10 ], %i4                        
      if (delta_interval > delta) {                                   
40008f70:	80 a7 00 04 	cmp  %i4, %g4                                  
40008f74:	08 80 00 03 	bleu  40008f80 <_Timer_server_Schedule_operation_method+0x68>
40008f78:	86 10 20 00 	clr  %g3                                       
        delta_interval -= delta;                                      
40008f7c:	86 27 00 04 	sub  %i4, %g4, %g3                             
      } else {                                                        
        delta_interval = 0;                                           
      }                                                               
      first_watchdog->delta_interval = delta_interval;                
40008f80:	c6 20 60 10 	st  %g3, [ %g1 + 0x10 ]                        
    }                                                                 
    ts->Interval_watchdogs.last_snapshot = snapshot;                  
40008f84:	c4 26 20 3c 	st  %g2, [ %i0 + 0x3c ]                        
    _ISR_Enable( level );                                             
40008f88:	7f ff e7 8e 	call  40002dc0 <sparc_enable_interrupts>       
40008f8c:	01 00 00 00 	nop                                            
                                                                      
    _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
40008f90:	90 06 20 30 	add  %i0, 0x30, %o0                            
40008f94:	40 00 0d f1 	call  4000c758 <_Watchdog_Insert>              
40008f98:	92 07 60 10 	add  %i5, 0x10, %o1                            
                                                                      
    if ( !ts->active ) {                                              
40008f9c:	c2 0e 20 7c 	ldub  [ %i0 + 0x7c ], %g1                      
40008fa0:	80 a0 60 00 	cmp  %g1, 0                                    
40008fa4:	12 80 00 29 	bne  40009048 <_Timer_server_Schedule_operation_method+0x130>
40008fa8:	01 00 00 00 	nop                                            
      _Timer_server_Reset_interval_system_watchdog( ts );             
40008fac:	7f ff ff 40 	call  40008cac <_Timer_server_Reset_interval_system_watchdog>
40008fb0:	90 10 00 18 	mov  %i0, %o0                                  
40008fb4:	30 80 00 25 	b,a   40009048 <_Timer_server_Schedule_operation_method+0x130>
    }                                                                 
  } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {       
40008fb8:	12 80 00 24 	bne  40009048 <_Timer_server_Schedule_operation_method+0x130>
40008fbc:	01 00 00 00 	nop                                            
    /*                                                                
     *  We have to advance the last known seconds value of the server and update
     *  the watchdog chain accordingly.                               
     */                                                               
    _ISR_Disable( level );                                            
40008fc0:	7f ff e7 7d 	call  40002db4 <sparc_disable_interrupts>      
40008fc4:	01 00 00 00 	nop                                            
40008fc8:	b6 10 00 08 	mov  %o0, %i3                                  
    snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();        
40008fcc:	40 00 02 d2 	call  40009b14 <_TOD_Seconds_since_epoch>      
40008fd0:	01 00 00 00 	nop                                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40008fd4:	c4 06 20 68 	ld  [ %i0 + 0x68 ], %g2                        
    last_snapshot = ts->TOD_watchdogs.last_snapshot;                  
40008fd8:	c6 06 20 74 	ld  [ %i0 + 0x74 ], %g3                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40008fdc:	88 06 20 6c 	add  %i0, 0x6c, %g4                            
    if ( !_Chain_Is_empty( &ts->TOD_watchdogs.Chain ) ) {             
40008fe0:	80 a0 80 04 	cmp  %g2, %g4                                  
40008fe4:	02 80 00 0d 	be  40009018 <_Timer_server_Schedule_operation_method+0x100>
40008fe8:	80 a2 00 03 	cmp  %o0, %g3                                  
      first_watchdog = _Watchdog_First( &ts->TOD_watchdogs.Chain );   
      delta_interval = first_watchdog->delta_interval;                
      if ( snapshot > last_snapshot ) {                               
40008fec:	08 80 00 08 	bleu  4000900c <_Timer_server_Schedule_operation_method+0xf4>
40008ff0:	c8 00 a0 10 	ld  [ %g2 + 0x10 ], %g4                        
        /*                                                            
         *  We advanced in time.                                      
         */                                                           
        delta = snapshot - last_snapshot;                             
40008ff4:	b8 22 00 03 	sub  %o0, %g3, %i4                             
        if (delta_interval > delta) {                                 
40008ff8:	80 a1 00 1c 	cmp  %g4, %i4                                  
40008ffc:	08 80 00 06 	bleu  40009014 <_Timer_server_Schedule_operation_method+0xfc><== NEVER TAKEN
40009000:	86 10 20 00 	clr  %g3                                       
          delta_interval -= delta;                                    
40009004:	10 80 00 04 	b  40009014 <_Timer_server_Schedule_operation_method+0xfc>
40009008:	86 21 00 1c 	sub  %g4, %i4, %g3                             
        }                                                             
      } else {                                                        
        /*                                                            
         *  Someone put us in the past.                               
         */                                                           
        delta = last_snapshot - snapshot;                             
4000900c:	86 01 00 03 	add  %g4, %g3, %g3                             
        delta_interval += delta;                                      
40009010:	86 20 c0 08 	sub  %g3, %o0, %g3                             
      }                                                               
      first_watchdog->delta_interval = delta_interval;                
40009014:	c6 20 a0 10 	st  %g3, [ %g2 + 0x10 ]                        
    }                                                                 
    ts->TOD_watchdogs.last_snapshot = snapshot;                       
40009018:	d0 26 20 74 	st  %o0, [ %i0 + 0x74 ]                        
    _ISR_Enable( level );                                             
4000901c:	7f ff e7 69 	call  40002dc0 <sparc_enable_interrupts>       
40009020:	90 10 00 1b 	mov  %i3, %o0                                  
                                                                      
    _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );     
40009024:	90 06 20 68 	add  %i0, 0x68, %o0                            
40009028:	40 00 0d cc 	call  4000c758 <_Watchdog_Insert>              
4000902c:	92 07 60 10 	add  %i5, 0x10, %o1                            
                                                                      
    if ( !ts->active ) {                                              
40009030:	c2 0e 20 7c 	ldub  [ %i0 + 0x7c ], %g1                      
40009034:	80 a0 60 00 	cmp  %g1, 0                                    
40009038:	12 80 00 04 	bne  40009048 <_Timer_server_Schedule_operation_method+0x130>
4000903c:	01 00 00 00 	nop                                            
      _Timer_server_Reset_tod_system_watchdog( ts );                  
40009040:	7f ff ff 2f 	call  40008cfc <_Timer_server_Reset_tod_system_watchdog>
40009044:	90 10 00 18 	mov  %i0, %o0                                  
    }                                                                 
  }                                                                   
                                                                      
  _Thread_Enable_dispatch();                                          
40009048:	40 00 09 27 	call  4000b4e4 <_Thread_Enable_dispatch>       
4000904c:	81 e8 00 00 	restore                                        
     *  server is not preemptible, so we must be in interrupt context here.  No
     *  thread dispatch will happen until the timer server finishes its
     *  critical section.  We have to use the protected chain methods because
     *  we may be interrupted by a higher priority interrupt.         
     */                                                               
    _Chain_Append( ts->insert_chain, &timer->Object.Node );           
40009050:	f0 06 20 78 	ld  [ %i0 + 0x78 ], %i0                        
40009054:	40 00 01 87 	call  40009670 <_Chain_Append>                 
40009058:	81 e8 00 00 	restore                                        
                                                                      

4000c834 <_Timestamp64_Divide>: const Timestamp64_Control *_lhs, const Timestamp64_Control *_rhs, uint32_t *_ival_percentage, uint32_t *_fval_percentage ) {
4000c834:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Timestamp64_Control answer;                                         
                                                                      
  if ( *_rhs == 0 ) {                                                 
4000c838:	d4 1e 40 00 	ldd  [ %i1 ], %o2                              
4000c83c:	80 92 80 0b 	orcc  %o2, %o3, %g0                            
4000c840:	32 80 00 06 	bne,a   4000c858 <_Timestamp64_Divide+0x24>    <== ALWAYS TAKEN
4000c844:	d8 1e 00 00 	ldd  [ %i0 ], %o4                              
    *_ival_percentage = 0;                                            
4000c848:	c0 26 80 00 	clr  [ %i2 ]                                   <== NOT EXECUTED
    *_fval_percentage = 0;                                            
4000c84c:	c0 26 c0 00 	clr  [ %i3 ]                                   <== NOT EXECUTED
    return;                                                           
4000c850:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000c854:	81 e8 00 00 	restore                                        <== NOT EXECUTED
   *  This looks odd but gives the results the proper precision.      
   *                                                                  
   *  TODO: Rounding on the last digit of the fval.                   
   */                                                                 
                                                                      
  answer = (*_lhs * 100000) / *_rhs;                                  
4000c858:	83 2b 20 02 	sll  %o4, 2, %g1                               
4000c85c:	87 2b 60 02 	sll  %o5, 2, %g3                               
4000c860:	89 33 60 1e 	srl  %o5, 0x1e, %g4                            
4000c864:	bb 28 e0 05 	sll  %g3, 5, %i5                               
4000c868:	84 11 00 01 	or  %g4, %g1, %g2                              
4000c86c:	83 30 e0 1b 	srl  %g3, 0x1b, %g1                            
4000c870:	b9 28 a0 05 	sll  %g2, 5, %i4                               
4000c874:	86 a7 40 03 	subcc  %i5, %g3, %g3                           
4000c878:	b8 10 40 1c 	or  %g1, %i4, %i4                              
4000c87c:	84 67 00 02 	subx  %i4, %g2, %g2                            
4000c880:	b2 80 c0 0d 	addcc  %g3, %o5, %i1                           
4000c884:	b0 40 80 0c 	addx  %g2, %o4, %i0                            
4000c888:	83 36 60 1e 	srl  %i1, 0x1e, %g1                            
4000c88c:	87 2e 60 02 	sll  %i1, 2, %g3                               
4000c890:	85 2e 20 02 	sll  %i0, 2, %g2                               
4000c894:	84 10 40 02 	or  %g1, %g2, %g2                              
4000c898:	ba 86 40 03 	addcc  %i1, %g3, %i5                           
4000c89c:	b8 46 00 02 	addx  %i0, %g2, %i4                            
4000c8a0:	83 37 60 1e 	srl  %i5, 0x1e, %g1                            
4000c8a4:	87 2f 60 02 	sll  %i5, 2, %g3                               
4000c8a8:	85 2f 20 02 	sll  %i4, 2, %g2                               
4000c8ac:	84 10 40 02 	or  %g1, %g2, %g2                              
4000c8b0:	92 87 40 03 	addcc  %i5, %g3, %o1                           
4000c8b4:	90 47 00 02 	addx  %i4, %g2, %o0                            
4000c8b8:	87 32 60 1b 	srl  %o1, 0x1b, %g3                            
4000c8bc:	85 2a 20 05 	sll  %o0, 5, %g2                               
4000c8c0:	83 2a 60 05 	sll  %o1, 5, %g1                               
4000c8c4:	90 10 c0 02 	or  %g3, %g2, %o0                              
4000c8c8:	40 00 23 1f 	call  40015544 <__divdi3>                      
4000c8cc:	92 10 00 01 	mov  %g1, %o1                                  
                                                                      
  *_ival_percentage = answer / 1000;                                  
4000c8d0:	94 10 20 00 	clr  %o2                                       
   *  This looks odd but gives the results the proper precision.      
   *                                                                  
   *  TODO: Rounding on the last digit of the fval.                   
   */                                                                 
                                                                      
  answer = (*_lhs * 100000) / *_rhs;                                  
4000c8d4:	b8 10 00 08 	mov  %o0, %i4                                  
4000c8d8:	ba 10 00 09 	mov  %o1, %i5                                  
                                                                      
  *_ival_percentage = answer / 1000;                                  
4000c8dc:	40 00 23 1a 	call  40015544 <__divdi3>                      
4000c8e0:	96 10 23 e8 	mov  0x3e8, %o3                                
  *_fval_percentage = answer % 1000;                                  
4000c8e4:	90 10 00 1c 	mov  %i4, %o0                                  
   *  TODO: Rounding on the last digit of the fval.                   
   */                                                                 
                                                                      
  answer = (*_lhs * 100000) / *_rhs;                                  
                                                                      
  *_ival_percentage = answer / 1000;                                  
4000c8e8:	d2 26 80 00 	st  %o1, [ %i2 ]                               
  *_fval_percentage = answer % 1000;                                  
4000c8ec:	94 10 20 00 	clr  %o2                                       
4000c8f0:	92 10 00 1d 	mov  %i5, %o1                                  
4000c8f4:	40 00 24 06 	call  4001590c <__moddi3>                      
4000c8f8:	96 10 23 e8 	mov  0x3e8, %o3                                
4000c8fc:	d2 26 c0 00 	st  %o1, [ %i3 ]                               
4000c900:	81 c7 e0 08 	ret                                            
4000c904:	81 e8 00 00 	restore                                        
                                                                      

4000af04 <_User_extensions_Handler_initialization>: } } void _User_extensions_Handler_initialization(void) {
4000af04:	9d e3 bf 98 	save  %sp, -104, %sp                           
  uint32_t number_of_initial_extensions =                             
4000af08:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
4000af0c:	c2 00 61 c4 	ld  [ %g1 + 0x1c4 ], %g1	! 400155c4 <Configuration+0x3c>
    rtems_configuration_get_number_of_initial_extensions();           
                                                                      
  if ( number_of_initial_extensions > 0 ) {                           
4000af10:	80 a0 60 00 	cmp  %g1, 0                                    
4000af14:	02 80 00 0a 	be  4000af3c <_User_extensions_Handler_initialization+0x38><== NEVER TAKEN
4000af18:	91 28 60 02 	sll  %g1, 2, %o0                               
    User_extensions_Switch_control *initial_extension_switch_controls =
      _Workspace_Allocate_or_fatal_error(                             
        number_of_initial_extensions                                  
          * sizeof( *initial_extension_switch_controls )              
4000af1c:	83 28 60 04 	sll  %g1, 4, %g1                               
{                                                                     
  uint32_t number_of_initial_extensions =                             
    rtems_configuration_get_number_of_initial_extensions();           
                                                                      
  if ( number_of_initial_extensions > 0 ) {                           
    User_extensions_Switch_control *initial_extension_switch_controls =
4000af20:	40 00 01 2d 	call  4000b3d4 <_Workspace_Allocate_or_fatal_error>
4000af24:	90 20 40 08 	sub  %g1, %o0, %o0                             
        number_of_initial_extensions                                  
          * sizeof( *initial_extension_switch_controls )              
      );                                                              
    User_extensions_Switch_context ctx = { initial_extension_switch_controls };
                                                                      
    _User_extensions_Iterate( &ctx, _User_extensions_Switch_visitor );
4000af28:	13 10 00 2b 	sethi  %hi(0x4000ac00), %o1                    
    User_extensions_Switch_control *initial_extension_switch_controls =
      _Workspace_Allocate_or_fatal_error(                             
        number_of_initial_extensions                                  
          * sizeof( *initial_extension_switch_controls )              
      );                                                              
    User_extensions_Switch_context ctx = { initial_extension_switch_controls };
4000af2c:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          
                                                                      
    _User_extensions_Iterate( &ctx, _User_extensions_Switch_visitor );
4000af30:	92 12 62 c0 	or  %o1, 0x2c0, %o1                            
4000af34:	7f ff ff c2 	call  4000ae3c <_User_extensions_Iterate>      
4000af38:	90 07 bf fc 	add  %fp, -4, %o0                              
4000af3c:	81 c7 e0 08 	ret                                            
4000af40:	81 e8 00 00 	restore                                        
                                                                      

4000acf8 <_User_extensions_Thread_create_visitor>: void _User_extensions_Thread_create_visitor( Thread_Control *executing, void *arg, const User_extensions_Table *callouts ) {
4000acf8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  User_extensions_thread_create_extension callout = callouts->thread_create;
4000acfc:	c2 06 80 00 	ld  [ %i2 ], %g1                               
                                                                      
  if ( callout != NULL ) {                                            
4000ad00:	80 a0 60 00 	cmp  %g1, 0                                    
4000ad04:	02 80 00 0b 	be  4000ad30 <_User_extensions_Thread_create_visitor+0x38>
4000ad08:	01 00 00 00 	nop                                            
    User_extensions_Thread_create_context *ctx = arg;                 
                                                                      
    ctx->ok = ctx->ok && (*callout)( executing, ctx->created );       
4000ad0c:	c4 0e 60 04 	ldub  [ %i1 + 4 ], %g2                         
4000ad10:	80 a0 a0 00 	cmp  %g2, 0                                    
4000ad14:	02 80 00 05 	be  4000ad28 <_User_extensions_Thread_create_visitor+0x30><== NEVER TAKEN
4000ad18:	90 10 20 00 	clr  %o0                                       
4000ad1c:	d2 06 40 00 	ld  [ %i1 ], %o1                               
4000ad20:	9f c0 40 00 	call  %g1                                      
4000ad24:	90 10 00 18 	mov  %i0, %o0                                  
4000ad28:	90 0a 20 01 	and  %o0, 1, %o0                               
4000ad2c:	d0 2e 60 04 	stb  %o0, [ %i1 + 4 ]                          
4000ad30:	81 c7 e0 08 	ret                                            
4000ad34:	81 e8 00 00 	restore                                        
                                                                      

4000cbb8 <_Watchdog_Adjust>: void _Watchdog_Adjust( Chain_Control *header, Watchdog_Adjust_directions direction, Watchdog_Interval units ) {
4000cbb8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level level;                                                    
                                                                      
  _ISR_Disable( level );                                              
4000cbbc:	7f ff d9 be 	call  400032b4 <sparc_disable_interrupts>      
4000cbc0:	01 00 00 00 	nop                                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000cbc4:	c2 06 00 00 	ld  [ %i0 ], %g1                               
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000cbc8:	b8 06 20 04 	add  %i0, 4, %i4                               
   *       hence the compiler must not assume *header to remain       
   *       unmodified across that call.                               
   *                                                                  
   *       Till Straumann, 7/2003                                     
   */                                                                 
  if ( !_Chain_Is_empty( header ) ) {                                 
4000cbcc:	80 a0 40 1c 	cmp  %g1, %i4                                  
4000cbd0:	02 80 00 20 	be  4000cc50 <_Watchdog_Adjust+0x98>           
4000cbd4:	80 a6 60 00 	cmp  %i1, 0                                    
    switch ( direction ) {                                            
4000cbd8:	02 80 00 07 	be  4000cbf4 <_Watchdog_Adjust+0x3c>           
4000cbdc:	80 a6 60 01 	cmp  %i1, 1                                    
4000cbe0:	12 80 00 1c 	bne  4000cc50 <_Watchdog_Adjust+0x98>          <== NEVER TAKEN
4000cbe4:	01 00 00 00 	nop                                            
      case WATCHDOG_BACKWARD:                                         
        _Watchdog_First( header )->delta_interval += units;           
4000cbe8:	c4 00 60 10 	ld  [ %g1 + 0x10 ], %g2                        
4000cbec:	10 80 00 18 	b  4000cc4c <_Watchdog_Adjust+0x94>            
4000cbf0:	b4 00 80 1a 	add  %g2, %i2, %i2                             
          if ( units < _Watchdog_First( header )->delta_interval ) {  
            _Watchdog_First( header )->delta_interval -= units;       
            break;                                                    
          } else {                                                    
            units -= _Watchdog_First( header )->delta_interval;       
            _Watchdog_First( header )->delta_interval = 1;            
4000cbf4:	10 80 00 0d 	b  4000cc28 <_Watchdog_Adjust+0x70>            
4000cbf8:	b6 10 20 01 	mov  1, %i3                                    
4000cbfc:	f6 20 60 10 	st  %i3, [ %g1 + 0x10 ]                        
                                                                      
            _ISR_Enable( level );                                     
4000cc00:	7f ff d9 b0 	call  400032c0 <sparc_enable_interrupts>       
4000cc04:	01 00 00 00 	nop                                            
                                                                      
            _Watchdog_Tickle( header );                               
4000cc08:	40 00 00 91 	call  4000ce4c <_Watchdog_Tickle>              
4000cc0c:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
            _ISR_Disable( level );                                    
4000cc10:	7f ff d9 a9 	call  400032b4 <sparc_disable_interrupts>      
4000cc14:	01 00 00 00 	nop                                            
                                                                      
            if ( _Chain_Is_empty( header ) )                          
4000cc18:	c2 06 00 00 	ld  [ %i0 ], %g1                               
4000cc1c:	80 a0 40 1c 	cmp  %g1, %i4                                  
4000cc20:	02 80 00 0c 	be  4000cc50 <_Watchdog_Adjust+0x98>           
4000cc24:	01 00 00 00 	nop                                            
    switch ( direction ) {                                            
      case WATCHDOG_BACKWARD:                                         
        _Watchdog_First( header )->delta_interval += units;           
        break;                                                        
      case WATCHDOG_FORWARD:                                          
        while ( units ) {                                             
4000cc28:	80 a6 a0 00 	cmp  %i2, 0                                    
4000cc2c:	02 80 00 09 	be  4000cc50 <_Watchdog_Adjust+0x98>           <== NEVER TAKEN
4000cc30:	01 00 00 00 	nop                                            
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000cc34:	c2 06 00 00 	ld  [ %i0 ], %g1                               
          if ( units < _Watchdog_First( header )->delta_interval ) {  
4000cc38:	c4 00 60 10 	ld  [ %g1 + 0x10 ], %g2                        
4000cc3c:	80 a6 80 02 	cmp  %i2, %g2                                  
4000cc40:	3a bf ff ef 	bcc,a   4000cbfc <_Watchdog_Adjust+0x44>       
4000cc44:	b4 26 80 02 	sub  %i2, %g2, %i2                             
            _Watchdog_First( header )->delta_interval -= units;       
4000cc48:	b4 20 80 1a 	sub  %g2, %i2, %i2                             
4000cc4c:	f4 20 60 10 	st  %i2, [ %g1 + 0x10 ]                        
        }                                                             
        break;                                                        
    }                                                                 
  }                                                                   
                                                                      
  _ISR_Enable( level );                                               
4000cc50:	7f ff d9 9c 	call  400032c0 <sparc_enable_interrupts>       
4000cc54:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000b098 <_Watchdog_Remove>: #include <rtems/score/watchdogimpl.h> Watchdog_States _Watchdog_Remove( Watchdog_Control *the_watchdog ) {
4000b098:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level         level;                                            
  Watchdog_States   previous_state;                                   
  Watchdog_Control *next_watchdog;                                    
                                                                      
  _ISR_Disable( level );                                              
4000b09c:	7f ff dc e6 	call  40002434 <sparc_disable_interrupts>      
4000b0a0:	ba 10 00 18 	mov  %i0, %i5                                  
  previous_state = the_watchdog->state;                               
4000b0a4:	f0 06 20 08 	ld  [ %i0 + 8 ], %i0                           
  switch ( previous_state ) {                                         
4000b0a8:	80 a6 20 01 	cmp  %i0, 1                                    
4000b0ac:	22 80 00 1c 	be,a   4000b11c <_Watchdog_Remove+0x84>        
4000b0b0:	c0 27 60 08 	clr  [ %i5 + 8 ]                               
4000b0b4:	0a 80 00 1a 	bcs  4000b11c <_Watchdog_Remove+0x84>          
4000b0b8:	80 a6 20 03 	cmp  %i0, 3                                    
4000b0bc:	28 80 00 04 	bleu,a   4000b0cc <_Watchdog_Remove+0x34>      <== ALWAYS TAKEN
4000b0c0:	c2 07 40 00 	ld  [ %i5 ], %g1                               
        _Watchdog_Sync_level = _ISR_Nest_level;                       
                                                                      
      _Chain_Extract_unprotected( &the_watchdog->Node );              
      break;                                                          
  }                                                                   
  the_watchdog->stop_time = _Watchdog_Ticks_since_boot;               
4000b0c4:	10 80 00 17 	b  4000b120 <_Watchdog_Remove+0x88>            <== NOT EXECUTED
4000b0c8:	03 10 00 61 	sethi  %hi(0x40018400), %g1                    <== NOT EXECUTED
      break;                                                          
                                                                      
    case WATCHDOG_ACTIVE:                                             
    case WATCHDOG_REMOVE_IT:                                          
                                                                      
      the_watchdog->state = WATCHDOG_INACTIVE;                        
4000b0cc:	c0 27 60 08 	clr  [ %i5 + 8 ]                               
      next_watchdog = _Watchdog_Next( the_watchdog );                 
                                                                      
      if ( _Watchdog_Next(next_watchdog) )                            
4000b0d0:	c4 00 40 00 	ld  [ %g1 ], %g2                               
4000b0d4:	80 a0 a0 00 	cmp  %g2, 0                                    
4000b0d8:	02 80 00 07 	be  4000b0f4 <_Watchdog_Remove+0x5c>           
4000b0dc:	05 10 00 61 	sethi  %hi(0x40018400), %g2                    
        next_watchdog->delta_interval += the_watchdog->delta_interval;
4000b0e0:	c6 00 60 10 	ld  [ %g1 + 0x10 ], %g3                        
4000b0e4:	c4 07 60 10 	ld  [ %i5 + 0x10 ], %g2                        
4000b0e8:	84 00 c0 02 	add  %g3, %g2, %g2                             
4000b0ec:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
                                                                      
      if ( _Watchdog_Sync_count )                                     
4000b0f0:	05 10 00 61 	sethi  %hi(0x40018400), %g2                    
4000b0f4:	c4 00 a0 bc 	ld  [ %g2 + 0xbc ], %g2	! 400184bc <_Watchdog_Sync_count>
4000b0f8:	80 a0 a0 00 	cmp  %g2, 0                                    
4000b0fc:	22 80 00 06 	be,a   4000b114 <_Watchdog_Remove+0x7c>        
4000b100:	c4 07 60 04 	ld  [ %i5 + 4 ], %g2                           
        _Watchdog_Sync_level = _ISR_Nest_level;                       
4000b104:	c6 01 a0 0c 	ld  [ %g6 + 0xc ], %g3                         
4000b108:	05 10 00 61 	sethi  %hi(0x40018400), %g2                    
4000b10c:	c6 20 a0 9c 	st  %g3, [ %g2 + 0x9c ]	! 4001849c <_Watchdog_Sync_level>
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
4000b110:	c4 07 60 04 	ld  [ %i5 + 4 ], %g2                           
  next->previous = previous;                                          
4000b114:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
  previous->next = next;                                              
4000b118:	c2 20 80 00 	st  %g1, [ %g2 ]                               
                                                                      
      _Chain_Extract_unprotected( &the_watchdog->Node );              
      break;                                                          
  }                                                                   
  the_watchdog->stop_time = _Watchdog_Ticks_since_boot;               
4000b11c:	03 10 00 61 	sethi  %hi(0x40018400), %g1                    
4000b120:	c2 00 60 c0 	ld  [ %g1 + 0xc0 ], %g1	! 400184c0 <_Watchdog_Ticks_since_boot>
4000b124:	c2 27 60 18 	st  %g1, [ %i5 + 0x18 ]                        
                                                                      
  _ISR_Enable( level );                                               
4000b128:	7f ff dc c6 	call  40002440 <sparc_enable_interrupts>       
4000b12c:	01 00 00 00 	nop                                            
  return( previous_state );                                           
}                                                                     
4000b130:	81 c7 e0 08 	ret                                            
4000b134:	81 e8 00 00 	restore                                        
                                                                      

4000b138 <_Watchdog_Tickle>: #include <rtems/score/watchdogimpl.h> void _Watchdog_Tickle( Chain_Control *header ) {
4000b138:	9d e3 bf a0 	save  %sp, -96, %sp                            
   * See the comment in watchdoginsert.c and watchdogadjust.c         
   * about why it's safe not to declare header a pointer to           
   * volatile data - till, 2003/7                                     
   */                                                                 
                                                                      
  _ISR_Disable( level );                                              
4000b13c:	7f ff dc be 	call  40002434 <sparc_disable_interrupts>      
4000b140:	b8 10 00 18 	mov  %i0, %i4                                  
4000b144:	b0 10 00 08 	mov  %o0, %i0                                  
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000b148:	fa 07 00 00 	ld  [ %i4 ], %i5                               
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000b14c:	b6 07 20 04 	add  %i4, 4, %i3                               
                                                                      
  if ( _Chain_Is_empty( header ) )                                    
4000b150:	80 a7 40 1b 	cmp  %i5, %i3                                  
4000b154:	02 80 00 1f 	be  4000b1d0 <_Watchdog_Tickle+0x98>           
4000b158:	01 00 00 00 	nop                                            
   * to be inserted has already had its delta_interval adjusted to 0, and
   * so is added to the head of the chain with a delta_interval of 0. 
   *                                                                  
   * Steven Johnson - 12/2005 (gcc-3.2.3 -O3 on powerpc)              
   */                                                                 
  if (the_watchdog->delta_interval != 0) {                            
4000b15c:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000b160:	80 a0 60 00 	cmp  %g1, 0                                    
4000b164:	02 80 00 06 	be  4000b17c <_Watchdog_Tickle+0x44>           <== NEVER TAKEN
4000b168:	82 00 7f ff 	add  %g1, -1, %g1                              
    the_watchdog->delta_interval--;                                   
4000b16c:	c2 27 60 10 	st  %g1, [ %i5 + 0x10 ]                        
    if ( the_watchdog->delta_interval != 0 )                          
4000b170:	80 a0 60 00 	cmp  %g1, 0                                    
4000b174:	12 80 00 17 	bne  4000b1d0 <_Watchdog_Tickle+0x98>          
4000b178:	01 00 00 00 	nop                                            
      goto leave;                                                     
  }                                                                   
                                                                      
  do {                                                                
     watchdog_state = _Watchdog_Remove( the_watchdog );               
4000b17c:	7f ff ff c7 	call  4000b098 <_Watchdog_Remove>              
4000b180:	90 10 00 1d 	mov  %i5, %o0                                  
4000b184:	b4 10 00 08 	mov  %o0, %i2                                  
                                                                      
     _ISR_Enable( level );                                            
4000b188:	7f ff dc ae 	call  40002440 <sparc_enable_interrupts>       
4000b18c:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
     switch( watchdog_state ) {                                       
4000b190:	80 a6 a0 02 	cmp  %i2, 2                                    
4000b194:	12 80 00 06 	bne  4000b1ac <_Watchdog_Tickle+0x74>          
4000b198:	01 00 00 00 	nop                                            
       case WATCHDOG_ACTIVE:                                          
         (*the_watchdog->routine)(                                    
4000b19c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
4000b1a0:	d0 07 60 20 	ld  [ %i5 + 0x20 ], %o0                        
4000b1a4:	9f c0 40 00 	call  %g1                                      
4000b1a8:	d2 07 60 24 	ld  [ %i5 + 0x24 ], %o1                        
                                                                      
       case WATCHDOG_REMOVE_IT:                                       
         break;                                                       
     }                                                                
                                                                      
     _ISR_Disable( level );                                           
4000b1ac:	7f ff dc a2 	call  40002434 <sparc_disable_interrupts>      
4000b1b0:	01 00 00 00 	nop                                            
4000b1b4:	b0 10 00 08 	mov  %o0, %i0                                  
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000b1b8:	fa 07 00 00 	ld  [ %i4 ], %i5                               
                                                                      
     the_watchdog = _Watchdog_First( header );                        
   } while ( !_Chain_Is_empty( header ) &&                            
             (the_watchdog->delta_interval == 0) );                   
4000b1bc:	80 a7 40 1b 	cmp  %i5, %i3                                  
4000b1c0:	02 80 00 04 	be  4000b1d0 <_Watchdog_Tickle+0x98>           
4000b1c4:	01 00 00 00 	nop                                            
     }                                                                
                                                                      
     _ISR_Disable( level );                                           
                                                                      
     the_watchdog = _Watchdog_First( header );                        
   } while ( !_Chain_Is_empty( header ) &&                            
4000b1c8:	10 bf ff ea 	b  4000b170 <_Watchdog_Tickle+0x38>            
4000b1cc:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
             (the_watchdog->delta_interval == 0) );                   
                                                                      
leave:                                                                
   _ISR_Enable(level);                                                
4000b1d0:	7f ff dc 9c 	call  40002440 <sparc_enable_interrupts>       
4000b1d4:	81 e8 00 00 	restore                                        
                                                                      

4000b1d8 <_Workspace_Handler_initialization>: void _Workspace_Handler_initialization( Heap_Area *areas, size_t area_count, Heap_Initialization_or_extend_handler extend ) {
4000b1d8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Heap_Initialization_or_extend_handler init_or_extend = _Heap_Initialize;
  uintptr_t remaining = rtems_configuration_get_work_space_size();    
4000b1dc:	05 10 00 55 	sethi  %hi(0x40015400), %g2                    
4000b1e0:	82 10 a1 88 	or  %g2, 0x188, %g1	! 40015588 <Configuration> 
4000b1e4:	c6 08 60 3a 	ldub  [ %g1 + 0x3a ], %g3                      
4000b1e8:	fa 00 a1 88 	ld  [ %g2 + 0x188 ], %i5                       
4000b1ec:	80 a0 e0 00 	cmp  %g3, 0                                    
4000b1f0:	12 80 00 03 	bne  4000b1fc <_Workspace_Handler_initialization+0x24>
4000b1f4:	84 10 20 00 	clr  %g2                                       
4000b1f8:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
4000b1fc:	ba 00 80 1d 	add  %g2, %i5, %i5                             
  bool do_zero = rtems_configuration_get_do_zero_of_workspace();      
4000b200:	e2 08 60 38 	ldub  [ %g1 + 0x38 ], %l1                      
  bool unified = rtems_configuration_get_unified_work_area();         
4000b204:	e4 08 60 39 	ldub  [ %g1 + 0x39 ], %l2                      
{                                                                     
  /*                                                                  
   * Do not use _TLS_Size here since this will lead GCC to assume that this
   * symbol is not 0 and the tests for 0 will be optimized away.      
   */                                                                 
  return (uintptr_t) _TLS_BSS_end - (uintptr_t) _TLS_Data_begin;      
4000b208:	05 10 00 5a 	sethi  %hi(0x40016800), %g2                    
4000b20c:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
4000b210:	84 10 a2 a0 	or  %g2, 0x2a0, %g2                            
4000b214:	82 10 62 a0 	or  %g1, 0x2a0, %g1                            
   * workspace is large enough to fulfill all requests known at configuration
   * time (so excluding the unlimited option).  It is not possible to estimate
   * the TLS size in the configuration at compile-time.  The TLS size is
   * determined at application link-time.                             
   */                                                                 
  if ( tls_size > 0 ) {                                               
4000b218:	90 a0 80 01 	subcc  %g2, %g1, %o0                           
4000b21c:	02 80 00 1a 	be  4000b284 <_Workspace_Handler_initialization+0xac>
4000b220:	03 00 00 00 	sethi  %hi(0), %g1                             
                                                                      
static inline uintptr_t _TLS_Heap_align_up( uintptr_t val )           
{                                                                     
  uintptr_t msk = CPU_HEAP_ALIGNMENT - 1;                             
                                                                      
  return (val + msk) & ~msk;                                          
4000b224:	82 10 60 01 	or  %g1, 1, %g1	! 1 <_TLS_Alignment>           
4000b228:	82 00 60 07 	add  %g1, 7, %g1                               
4000b22c:	82 08 7f f8 	and  %g1, -8, %g1                              
                                                                      
static inline uintptr_t _TLS_Get_thread_control_block_area_size(      
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return alignment <= sizeof(TLS_Thread_control_block) ?              
4000b230:	80 a0 60 08 	cmp  %g1, 8                                    
4000b234:	2a 80 00 02 	bcs,a   4000b23c <_Workspace_Handler_initialization+0x64><== NEVER TAKEN
4000b238:	82 10 20 08 	mov  8, %g1                                    <== NOT EXECUTED
{                                                                     
  uint32_t thread_count = 0;                                          
                                                                      
  thread_count += _Thread_Get_maximum_internal_threads();             
                                                                      
  thread_count += rtems_resource_maximum_per_allocation(              
4000b23c:	05 10 00 5a 	sethi  %hi(0x40016800), %g2                    
    Configuration_RTEMS_API.maximum_tasks                             
  );                                                                  
                                                                      
#if defined(RTEMS_POSIX_API)                                          
  thread_count += rtems_resource_maximum_per_allocation(              
4000b240:	07 10 00 5c 	sethi  %hi(0x40017000), %g3                    
{                                                                     
  uint32_t thread_count = 0;                                          
                                                                      
  thread_count += _Thread_Get_maximum_internal_threads();             
                                                                      
  thread_count += rtems_resource_maximum_per_allocation(              
4000b244:	d2 00 a2 ac 	ld  [ %g2 + 0x2ac ], %o1                       
    Configuration_RTEMS_API.maximum_tasks                             
  );                                                                  
                                                                      
#if defined(RTEMS_POSIX_API)                                          
  thread_count += rtems_resource_maximum_per_allocation(              
4000b248:	c6 00 e0 84 	ld  [ %g3 + 0x84 ], %g3                        
{                                                                     
  uint32_t thread_count = 0;                                          
                                                                      
  thread_count += _Thread_Get_maximum_internal_threads();             
                                                                      
  thread_count += rtems_resource_maximum_per_allocation(              
4000b24c:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
4000b250:	84 10 a3 ff 	or  %g2, 0x3ff, %g2	! ffff <_TLS_Alignment+0xfffe>
4000b254:	92 0a 40 02 	and  %o1, %g2, %o1                             
    Configuration_RTEMS_API.maximum_tasks                             
  );                                                                  
                                                                      
#if defined(RTEMS_POSIX_API)                                          
  thread_count += rtems_resource_maximum_per_allocation(              
4000b258:	84 08 c0 02 	and  %g3, %g2, %g2                             
                                                                      
static inline uintptr_t _TLS_Heap_align_up( uintptr_t val )           
{                                                                     
  uintptr_t msk = CPU_HEAP_ALIGNMENT - 1;                             
                                                                      
  return (val + msk) & ~msk;                                          
4000b25c:	90 02 20 07 	add  %o0, 7, %o0                               
{                                                                     
  uint32_t thread_count = 0;                                          
                                                                      
  thread_count += _Thread_Get_maximum_internal_threads();             
                                                                      
  thread_count += rtems_resource_maximum_per_allocation(              
4000b260:	92 02 40 02 	add  %o1, %g2, %o1                             
4000b264:	90 0a 3f f8 	and  %o0, -8, %o0                              
     * size.                                                          
     */                                                               
    remaining += _Heap_Min_block_size( page_size );                   
                                                                      
    remaining += _Get_maximum_thread_count()                          
      * _Heap_Size_with_overhead( page_size, tls_alloc, tls_align );  
4000b268:	92 02 60 01 	inc  %o1                                       
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  uintptr_t aligned_size = _TLS_Heap_align_up( size );                
                                                                      
  return _TLS_Get_thread_control_block_area_size( alignment )         
4000b26c:	90 02 00 01 	add  %o0, %g1, %o0                             
                                                                      
  if ( page_size < alignment ) {                                      
    page_size = alignment;                                            
  }                                                                   
                                                                      
  return HEAP_BLOCK_HEADER_SIZE + page_size - 1 + size;               
4000b270:	90 02 20 0f 	add  %o0, 0xf, %o0                             
4000b274:	40 00 20 5f 	call  400133f0 <.umul>                         
4000b278:	90 02 00 01 	add  %o0, %g1, %o0                             
    /*                                                                
     * Memory allocated with an alignment constraint is allocated from the end
     * of a free block.  The last allocation may need one free block of minimum
     * size.                                                          
     */                                                               
    remaining += _Heap_Min_block_size( page_size );                   
4000b27c:	90 02 20 10 	add  %o0, 0x10, %o0                            
                                                                      
    remaining += _Get_maximum_thread_count()                          
4000b280:	ba 07 40 08 	add  %i5, %o0, %i5                             
        remaining -= space_available;                                 
      } else {                                                        
        remaining = 0;                                                
      }                                                               
                                                                      
      init_or_extend = extend;                                        
4000b284:	21 10 00 21 	sethi  %hi(0x40008400), %l0                    
        } else {                                                      
          size = 0;                                                   
        }                                                             
      }                                                               
                                                                      
      space_available = (*init_or_extend)(                            
4000b288:	27 10 00 61 	sethi  %hi(0x40018400), %l3                    
        remaining -= space_available;                                 
      } else {                                                        
        remaining = 0;                                                
      }                                                               
                                                                      
      init_or_extend = extend;                                        
4000b28c:	b6 10 20 00 	clr  %i3                                       
4000b290:	a0 14 23 ac 	or  %l0, 0x3ac, %l0                            
  }                                                                   
                                                                      
  for (i = 0; i < area_count; ++i) {                                  
    Heap_Area *area = &areas [i];                                     
                                                                      
    if ( do_zero ) {                                                  
4000b294:	a2 0c 60 ff 	and  %l1, 0xff, %l1                            
                                                                      
    if ( area->size > overhead ) {                                    
      uintptr_t space_available;                                      
      uintptr_t size;                                                 
                                                                      
      if ( unified ) {                                                
4000b298:	a4 0c a0 ff 	and  %l2, 0xff, %l2                            
        } else {                                                      
          size = 0;                                                   
        }                                                             
      }                                                               
                                                                      
      space_available = (*init_or_extend)(                            
4000b29c:	a6 14 e0 3c 	or  %l3, 0x3c, %l3                             
                                                                      
    remaining += _Get_maximum_thread_count()                          
      * _Heap_Size_with_overhead( page_size, tls_alloc, tls_align );  
  }                                                                   
                                                                      
  for (i = 0; i < area_count; ++i) {                                  
4000b2a0:	80 a6 c0 19 	cmp  %i3, %i1                                  
4000b2a4:	02 80 00 2d 	be  4000b358 <_Workspace_Handler_initialization+0x180>
4000b2a8:	80 a4 60 00 	cmp  %l1, 0                                    
    Heap_Area *area = &areas [i];                                     
                                                                      
    if ( do_zero ) {                                                  
4000b2ac:	22 80 00 07 	be,a   4000b2c8 <_Workspace_Handler_initialization+0xf0>
4000b2b0:	f8 06 20 04 	ld  [ %i0 + 4 ], %i4                           
      memset( area->begin, 0, area->size );                           
4000b2b4:	d0 06 00 00 	ld  [ %i0 ], %o0                               
4000b2b8:	d4 06 20 04 	ld  [ %i0 + 4 ], %o2                           
4000b2bc:	40 00 13 fe 	call  400102b4 <memset>                        
4000b2c0:	92 10 20 00 	clr  %o1                                       
    }                                                                 
                                                                      
    if ( area->size > overhead ) {                                    
4000b2c4:	f8 06 20 04 	ld  [ %i0 + 4 ], %i4                           
4000b2c8:	80 a7 20 16 	cmp  %i4, 0x16                                 
4000b2cc:	28 80 00 21 	bleu,a   4000b350 <_Workspace_Handler_initialization+0x178>
4000b2d0:	b6 06 e0 01 	inc  %i3                                       
      uintptr_t space_available;                                      
      uintptr_t size;                                                 
                                                                      
      if ( unified ) {                                                
4000b2d4:	80 a4 a0 00 	cmp  %l2, 0                                    
4000b2d8:	32 80 00 0c 	bne,a   4000b308 <_Workspace_Handler_initialization+0x130>
4000b2dc:	d2 06 00 00 	ld  [ %i0 ], %o1                               
        size = area->size;                                            
      } else {                                                        
        if ( remaining > 0 ) {                                        
4000b2e0:	80 a7 60 00 	cmp  %i5, 0                                    
4000b2e4:	22 80 00 08 	be,a   4000b304 <_Workspace_Handler_initialization+0x12c><== NEVER TAKEN
4000b2e8:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
          size = remaining < area->size - overhead ?                  
4000b2ec:	82 07 3f ea 	add  %i4, -22, %g1                             
            remaining + overhead : area->size;                        
4000b2f0:	80 a7 40 01 	cmp  %i5, %g1                                  
4000b2f4:	2a 80 00 04 	bcs,a   4000b304 <_Workspace_Handler_initialization+0x12c><== ALWAYS TAKEN
4000b2f8:	b8 07 60 16 	add  %i5, 0x16, %i4                            
4000b2fc:	10 80 00 03 	b  4000b308 <_Workspace_Handler_initialization+0x130><== NOT EXECUTED
4000b300:	d2 06 00 00 	ld  [ %i0 ], %o1                               <== NOT EXECUTED
        } else {                                                      
          size = 0;                                                   
        }                                                             
      }                                                               
                                                                      
      space_available = (*init_or_extend)(                            
4000b304:	d2 06 00 00 	ld  [ %i0 ], %o1                               
4000b308:	94 10 00 1c 	mov  %i4, %o2                                  
4000b30c:	90 10 00 13 	mov  %l3, %o0                                  
4000b310:	9f c4 00 00 	call  %l0                                      
4000b314:	96 10 20 08 	mov  8, %o3                                    
        area->begin,                                                  
        size,                                                         
        page_size                                                     
      );                                                              
                                                                      
      area->begin = (char *) area->begin + size;                      
4000b318:	c2 06 00 00 	ld  [ %i0 ], %g1                               
      area->size -= size;                                             
                                                                      
      if ( space_available < remaining ) {                            
4000b31c:	80 a2 00 1d 	cmp  %o0, %i5                                  
        area->begin,                                                  
        size,                                                         
        page_size                                                     
      );                                                              
                                                                      
      area->begin = (char *) area->begin + size;                      
4000b320:	82 00 40 1c 	add  %g1, %i4, %g1                             
4000b324:	c2 26 00 00 	st  %g1, [ %i0 ]                               
      area->size -= size;                                             
4000b328:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
4000b32c:	b8 20 40 1c 	sub  %g1, %i4, %i4                             
                                                                      
      if ( space_available < remaining ) {                            
4000b330:	1a 80 00 05 	bcc  4000b344 <_Workspace_Handler_initialization+0x16c><== ALWAYS TAKEN
4000b334:	f8 26 20 04 	st  %i4, [ %i0 + 4 ]                           
        remaining -= space_available;                                 
4000b338:	ba 27 40 08 	sub  %i5, %o0, %i5                             <== NOT EXECUTED
4000b33c:	10 80 00 04 	b  4000b34c <_Workspace_Handler_initialization+0x174><== NOT EXECUTED
4000b340:	a0 10 00 1a 	mov  %i2, %l0                                  <== NOT EXECUTED
      } else {                                                        
        remaining = 0;                                                
      }                                                               
                                                                      
      init_or_extend = extend;                                        
4000b344:	a0 10 00 1a 	mov  %i2, %l0                                  
      area->size -= size;                                             
                                                                      
      if ( space_available < remaining ) {                            
        remaining -= space_available;                                 
      } else {                                                        
        remaining = 0;                                                
4000b348:	ba 10 20 00 	clr  %i5                                       
                                                                      
    remaining += _Get_maximum_thread_count()                          
      * _Heap_Size_with_overhead( page_size, tls_alloc, tls_align );  
  }                                                                   
                                                                      
  for (i = 0; i < area_count; ++i) {                                  
4000b34c:	b6 06 e0 01 	inc  %i3                                       
4000b350:	10 bf ff d4 	b  4000b2a0 <_Workspace_Handler_initialization+0xc8>
4000b354:	b0 06 20 08 	add  %i0, 8, %i0                               
                                                                      
      init_or_extend = extend;                                        
    }                                                                 
  }                                                                   
                                                                      
  if ( remaining > 0 ) {                                              
4000b358:	80 a7 60 00 	cmp  %i5, 0                                    
4000b35c:	02 80 00 05 	be  4000b370 <_Workspace_Handler_initialization+0x198>
4000b360:	90 10 20 00 	clr  %o0                                       
    _Terminate(                                                       
4000b364:	92 10 20 01 	mov  1, %o1                                    
4000b368:	7f ff f5 a8 	call  40008a08 <_Terminate>                    
4000b36c:	94 10 20 02 	mov  2, %o2                                    
4000b370:	81 c7 e0 08 	ret                                            
4000b374:	81 e8 00 00 	restore                                        
                                                                      

400246f0 <_calloc_r>: struct _reent *ignored __attribute__((unused)), size_t elements, size_t size ) { return calloc( elements, size );
400246f0:	90 10 00 09 	mov  %o1, %o0                                  
400246f4:	92 10 00 0a 	mov  %o2, %o1                                  
400246f8:	82 13 c0 00 	mov  %o7, %g1                                  
400246fc:	7f ff 8e 43 	call  40008008 <calloc>                        
40024700:	9e 10 40 00 	mov  %g1, %o7                                  
                                                                      

4000c094 <_close_r>: int _close_r( struct _reent *ptr __attribute__((unused)), int fd ) { return close( fd );
4000c094:	90 10 00 09 	mov  %o1, %o0                                  
4000c098:	82 13 c0 00 	mov  %o7, %g1                                  
4000c09c:	7f ff ff df 	call  4000c018 <close>                         
4000c0a0:	9e 10 40 00 	mov  %g1, %o7                                  
                                                                      

4001311c <_fat_block_read>: uint32_t start, uint32_t offset, uint32_t count, void *buff ) {
4001311c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                     rc = RC_OK;                               
    ssize_t                 cmpltd = 0;                               
40013120:	a0 10 20 00 	clr  %l0                                       
    uint32_t                sec_num = start;                          
    uint32_t                ofs = offset;                             
    uint8_t                *sec_buf;                                  
    uint32_t                c = 0;                                    
                                                                      
    while (count > 0)                                                 
40013124:	80 a6 e0 00 	cmp  %i3, 0                                    
40013128:	02 80 00 18 	be  40013188 <_fat_block_read+0x6c>            
4001312c:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_READ, &sec_buf);
40013130:	92 10 00 19 	mov  %i1, %o1                                  
40013134:	94 10 20 01 	mov  1, %o2                                    
40013138:	7f ff ff ca 	call  40013060 <fat_buf_access>                
4001313c:	96 07 bf fc 	add  %fp, -4, %o3                              
        if (rc != RC_OK)                                              
40013140:	80 a2 20 00 	cmp  %o0, 0                                    
40013144:	12 80 00 13 	bne  40013190 <_fat_block_read+0x74>           <== NEVER TAKEN
40013148:	01 00 00 00 	nop                                            
            return -1;                                                
                                                                      
        c = MIN(count, (fs_info->vol.bps - ofs));                     
4001314c:	fa 16 00 00 	lduh  [ %i0 ], %i5                             
40013150:	ba 27 40 1a 	sub  %i5, %i2, %i5                             
40013154:	80 a7 40 1b 	cmp  %i5, %i3                                  
40013158:	38 80 00 02 	bgu,a   40013160 <_fat_block_read+0x44>        
4001315c:	ba 10 00 1b 	mov  %i3, %i5                                  
        memcpy((buff + cmpltd), (sec_buf + ofs), c);                  
40013160:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
40013164:	90 07 00 10 	add  %i4, %l0, %o0                             
40013168:	92 02 40 1a 	add  %o1, %i2, %o1                             
4001316c:	94 10 00 1d 	mov  %i5, %o2                                  
40013170:	40 00 27 1c 	call  4001cde0 <memcpy>                        
40013174:	b6 26 c0 1d 	sub  %i3, %i5, %i3                             
                                                                      
        count -= c;                                                   
        cmpltd += c;                                                  
40013178:	a0 07 40 10 	add  %i5, %l0, %l0                             
        sec_num++;                                                    
4001317c:	b2 06 60 01 	inc  %i1                                       
        ofs = 0;                                                      
40013180:	10 bf ff e9 	b  40013124 <_fat_block_read+0x8>              
40013184:	b4 10 20 00 	clr  %i2                                       
40013188:	81 c7 e0 08 	ret                                            
4001318c:	91 e8 00 10 	restore  %g0, %l0, %o0                         
    }                                                                 
    return cmpltd;                                                    
}                                                                     
40013190:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013194:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      

400076dc <aio_cancel>: #include <stdlib.h> #include <rtems/system.h> #include <rtems/seterr.h> int aio_cancel(int fildes, struct aiocb *aiocbp) {
400076dc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_chain_control *idle_req_chain = &aio_request_queue.idle_req;  
  rtems_chain_control *work_req_chain = &aio_request_queue.work_req;  
  rtems_aio_request_chain *r_chain;                                   
  int result;                                                         
                                                                      
  pthread_mutex_lock (&aio_request_queue.mutex);                      
400076e0:	3b 10 00 6a 	sethi  %hi(0x4001a800), %i5                    
400076e4:	40 00 04 a7 	call  40008980 <pthread_mutex_lock>            
400076e8:	90 17 60 88 	or  %i5, 0x88, %o0	! 4001a888 <aio_request_queue>
                                                                      
  if (fcntl (fildes, F_GETFD) < 0) {                                  
400076ec:	90 10 00 18 	mov  %i0, %o0                                  
400076f0:	92 10 20 01 	mov  1, %o1                                    
400076f4:	40 00 1b b9 	call  4000e5d8 <fcntl>                         
400076f8:	b4 10 00 1d 	mov  %i5, %i2                                  
400076fc:	80 a2 20 00 	cmp  %o0, 0                                    
40007700:	16 80 00 08 	bge  40007720 <aio_cancel+0x44>                
40007704:	80 a6 60 00 	cmp  %i1, 0                                    
    pthread_mutex_unlock(&aio_request_queue.mutex);                   
40007708:	40 00 04 bd 	call  400089fc <pthread_mutex_unlock>          
4000770c:	90 17 60 88 	or  %i5, 0x88, %o0                             
    rtems_set_errno_and_return_minus_one (EBADF);                     
40007710:	40 00 2a 67 	call  400120ac <__errno>                       
40007714:	01 00 00 00 	nop                                            
40007718:	10 80 00 53 	b  40007864 <aio_cancel+0x188>                 
4000771c:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  }                                                                   
                                                                      
  /* if aiocbp is NULL remove all request for given file descriptor */
  if (aiocbp == NULL) {                                               
40007720:	32 80 00 34 	bne,a   400077f0 <aio_cancel+0x114>            
40007724:	f8 06 40 00 	ld  [ %i1 ], %i4                               
    AIO_printf ("Cancel all requests\n");                             
                                                                      
    r_chain = rtems_aio_search_fd (work_req_chain, fildes, 0);        
40007728:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    
4000772c:	92 10 00 18 	mov  %i0, %o1                                  
40007730:	90 12 20 dc 	or  %o0, 0xdc, %o0                             
40007734:	40 00 01 6d 	call  40007ce8 <rtems_aio_search_fd>           
40007738:	94 10 20 00 	clr  %o2                                       
    if (r_chain == NULL) {                                            
4000773c:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40007740:	12 80 00 1f 	bne  400077bc <aio_cancel+0xe0>                
40007744:	b6 07 20 1c 	add  %i4, 0x1c, %i3                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40007748:	ba 17 60 88 	or  %i5, 0x88, %i5                             
      AIO_printf ("Request chain not on [WQ]\n");                     
                                                                      
      if (!rtems_chain_is_empty (idle_req_chain)) {                   
4000774c:	c4 07 60 60 	ld  [ %i5 + 0x60 ], %g2                        
40007750:	82 07 60 64 	add  %i5, 0x64, %g1                            
40007754:	80 a0 80 01 	cmp  %g2, %g1                                  
40007758:	02 80 00 08 	be  40007778 <aio_cancel+0x9c>                 <== NEVER TAKEN
4000775c:	90 07 60 60 	add  %i5, 0x60, %o0                            
        r_chain = rtems_aio_search_fd (idle_req_chain, fildes, 0);    
40007760:	92 10 00 18 	mov  %i0, %o1                                  
40007764:	40 00 01 61 	call  40007ce8 <rtems_aio_search_fd>           
40007768:	94 10 20 00 	clr  %o2                                       
        if (r_chain == NULL) {                                        
4000776c:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40007770:	12 80 00 07 	bne  4000778c <aio_cancel+0xb0>                
40007774:	01 00 00 00 	nop                                            
          pthread_mutex_unlock(&aio_request_queue.mutex);             
40007778:	90 16 a0 88 	or  %i2, 0x88, %o0                             
4000777c:	40 00 04 a0 	call  400089fc <pthread_mutex_unlock>          
40007780:	b0 10 20 02 	mov  2, %i0                                    
          return AIO_ALLDONE;                                         
40007784:	81 c7 e0 08 	ret                                            
40007788:	81 e8 00 00 	restore                                        
#else                                                                 
RTEMS_INLINE_ROUTINE void rtems_chain_extract(                        
  rtems_chain_node *the_node                                          
)                                                                     
{                                                                     
  _Chain_Extract( the_node );                                         
4000778c:	40 00 0b 06 	call  4000a3a4 <_Chain_Extract>                
40007790:	b6 07 20 1c 	add  %i4, 0x1c, %i3                            
        }                                                             
                                                                      
        AIO_printf ("Request chain on [IQ]\n");                       
                                                                      
        rtems_chain_extract (&r_chain->next_fd);                      
        rtems_aio_remove_fd (r_chain);                                
40007794:	40 00 01 7d 	call  40007d88 <rtems_aio_remove_fd>           
40007798:	90 10 00 1c 	mov  %i4, %o0                                  
        pthread_mutex_destroy (&r_chain->mutex);                      
4000779c:	40 00 03 c6 	call  400086b4 <pthread_mutex_destroy>         
400077a0:	90 10 00 1b 	mov  %i3, %o0                                  
        pthread_cond_destroy (&r_chain->mutex);                       
400077a4:	40 00 02 ae 	call  4000825c <pthread_cond_destroy>          
400077a8:	90 10 00 1b 	mov  %i3, %o0                                  
        free (r_chain);                                               
400077ac:	7f ff f1 bb 	call  40003e98 <free>                          
400077b0:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
        pthread_mutex_unlock (&aio_request_queue.mutex);              
400077b4:	10 80 00 0b 	b  400077e0 <aio_cancel+0x104>                 
400077b8:	90 10 00 1d 	mov  %i5, %o0                                  
      return AIO_ALLDONE;                                             
    }                                                                 
                                                                      
    AIO_printf ("Request chain on [WQ]\n");                           
                                                                      
    pthread_mutex_lock (&r_chain->mutex);                             
400077bc:	40 00 04 71 	call  40008980 <pthread_mutex_lock>            
400077c0:	90 10 00 1b 	mov  %i3, %o0                                  
400077c4:	40 00 0a f8 	call  4000a3a4 <_Chain_Extract>                
400077c8:	90 10 00 1c 	mov  %i4, %o0                                  
    rtems_chain_extract (&r_chain->next_fd);                          
    rtems_aio_remove_fd (r_chain);                                    
400077cc:	40 00 01 6f 	call  40007d88 <rtems_aio_remove_fd>           
400077d0:	90 10 00 1c 	mov  %i4, %o0                                  
    pthread_mutex_unlock (&r_chain->mutex);                           
400077d4:	40 00 04 8a 	call  400089fc <pthread_mutex_unlock>          
400077d8:	90 10 00 1b 	mov  %i3, %o0                                  
    pthread_mutex_unlock (&aio_request_queue.mutex);                  
400077dc:	90 17 60 88 	or  %i5, 0x88, %o0                             
400077e0:	40 00 04 87 	call  400089fc <pthread_mutex_unlock>          
400077e4:	b0 10 20 00 	clr  %i0                                       
    return AIO_CANCELED;                                              
400077e8:	81 c7 e0 08 	ret                                            
400077ec:	81 e8 00 00 	restore                                        
  } else {                                                            
    AIO_printf ("Cancel request\n");                                  
                                                                      
    if (aiocbp->aio_fildes != fildes) {                               
400077f0:	80 a7 00 18 	cmp  %i4, %i0                                  
400077f4:	12 80 00 17 	bne  40007850 <aio_cancel+0x174>               
400077f8:	90 17 60 88 	or  %i5, 0x88, %o0                             
      pthread_mutex_unlock (&aio_request_queue.mutex);                
      rtems_set_errno_and_return_minus_one (EINVAL);                  
    }                                                                 
                                                                      
    r_chain = rtems_aio_search_fd (work_req_chain, fildes, 0);        
400077fc:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    
40007800:	92 10 00 1c 	mov  %i4, %o1                                  
40007804:	90 12 20 dc 	or  %o0, 0xdc, %o0                             
40007808:	40 00 01 38 	call  40007ce8 <rtems_aio_search_fd>           
4000780c:	94 10 20 00 	clr  %o2                                       
    if (r_chain == NULL) {                                            
40007810:	b6 92 20 00 	orcc  %o0, 0, %i3                              
40007814:	32 80 00 1c 	bne,a   40007884 <aio_cancel+0x1a8>            
40007818:	b8 06 e0 1c 	add  %i3, 0x1c, %i4                            
4000781c:	ba 17 60 88 	or  %i5, 0x88, %i5                             
      if (!rtems_chain_is_empty (idle_req_chain)) {                   
40007820:	c4 07 60 60 	ld  [ %i5 + 0x60 ], %g2                        
40007824:	82 07 60 64 	add  %i5, 0x64, %g1                            
40007828:	80 a0 80 01 	cmp  %g2, %g1                                  
4000782c:	02 bf ff d3 	be  40007778 <aio_cancel+0x9c>                 <== NEVER TAKEN
40007830:	90 07 60 60 	add  %i5, 0x60, %o0                            
        r_chain = rtems_aio_search_fd (idle_req_chain, fildes, 0);    
40007834:	92 10 00 1c 	mov  %i4, %o1                                  
40007838:	40 00 01 2c 	call  40007ce8 <rtems_aio_search_fd>           
4000783c:	94 10 20 00 	clr  %o2                                       
        if (r_chain == NULL) {                                        
40007840:	80 a2 20 00 	cmp  %o0, 0                                    
40007844:	12 80 00 0b 	bne  40007870 <aio_cancel+0x194>               
40007848:	90 02 20 08 	add  %o0, 8, %o0                               
          pthread_mutex_unlock (&aio_request_queue.mutex);            
4000784c:	90 10 00 1d 	mov  %i5, %o0                                  
40007850:	40 00 04 6b 	call  400089fc <pthread_mutex_unlock>          
40007854:	01 00 00 00 	nop                                            
          rtems_set_errno_and_return_minus_one (EINVAL);              
40007858:	40 00 2a 15 	call  400120ac <__errno>                       
4000785c:	01 00 00 00 	nop                                            
40007860:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
40007864:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40007868:	81 c7 e0 08 	ret                                            
4000786c:	91 e8 3f ff 	restore  %g0, -1, %o0                          
        }                                                             
                                                                      
        AIO_printf ("Request on [IQ]\n");                             
                                                                      
        result = rtems_aio_remove_req (&r_chain->perfd, aiocbp);      
40007870:	40 00 01 5b 	call  40007ddc <rtems_aio_remove_req>          
40007874:	92 10 00 19 	mov  %i1, %o1                                  
40007878:	b0 10 00 08 	mov  %o0, %i0                                  
        pthread_mutex_unlock (&aio_request_queue.mutex);              
4000787c:	10 80 00 0b 	b  400078a8 <aio_cancel+0x1cc>                 
40007880:	90 10 00 1d 	mov  %i5, %o0                                  
        return AIO_ALLDONE;                                           
      }                                                               
    }                                                                 
      AIO_printf ("Request on [WQ]\n");                               
                                                                      
      pthread_mutex_lock (&r_chain->mutex);                           
40007884:	40 00 04 3f 	call  40008980 <pthread_mutex_lock>            
40007888:	90 10 00 1c 	mov  %i4, %o0                                  
      result = rtems_aio_remove_req (&r_chain->perfd, aiocbp);        
4000788c:	92 10 00 19 	mov  %i1, %o1                                  
40007890:	40 00 01 53 	call  40007ddc <rtems_aio_remove_req>          
40007894:	90 06 e0 08 	add  %i3, 8, %o0                               
40007898:	b0 10 00 08 	mov  %o0, %i0                                  
      pthread_mutex_unlock (&r_chain->mutex);                         
4000789c:	40 00 04 58 	call  400089fc <pthread_mutex_unlock>          
400078a0:	90 10 00 1c 	mov  %i4, %o0                                  
      pthread_mutex_unlock (&aio_request_queue.mutex);                
400078a4:	90 17 60 88 	or  %i5, 0x88, %o0                             
400078a8:	40 00 04 55 	call  400089fc <pthread_mutex_unlock>          
400078ac:	01 00 00 00 	nop                                            
      return result;                                                  
  }                                                                   
  return AIO_ALLDONE;                                                 
}                                                                     
400078b0:	81 c7 e0 08 	ret                                            
400078b4:	81 e8 00 00 	restore                                        
                                                                      

400078c0 <aio_fsync>: int aio_fsync( int op, struct aiocb *aiocbp ) {
400078c0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_aio_request *req;                                             
  int mode;                                                           
                                                                      
  if (op != O_SYNC)                                                   
400078c4:	03 00 00 08 	sethi  %hi(0x2000), %g1                        
400078c8:	80 a6 00 01 	cmp  %i0, %g1                                  
400078cc:	12 80 00 10 	bne  4000790c <aio_fsync+0x4c>                 
400078d0:	ba 10 20 16 	mov  0x16, %i5                                 
    rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);            
                                                                      
  mode = fcntl (aiocbp->aio_fildes, F_GETFL);                         
400078d4:	d0 06 40 00 	ld  [ %i1 ], %o0                               
400078d8:	40 00 1b 40 	call  4000e5d8 <fcntl>                         
400078dc:	92 10 20 03 	mov  3, %o1                                    
  if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR)))
400078e0:	90 0a 20 03 	and  %o0, 3, %o0                               
400078e4:	90 02 3f ff 	add  %o0, -1, %o0                              
400078e8:	80 a2 20 01 	cmp  %o0, 1                                    
400078ec:	18 80 00 08 	bgu  4000790c <aio_fsync+0x4c>                 
400078f0:	ba 10 20 09 	mov  9, %i5                                    
    rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);             
                                                                      
  req = malloc (sizeof (rtems_aio_request));                          
400078f4:	7f ff f2 87 	call  40004310 <malloc>                        
400078f8:	90 10 20 18 	mov  0x18, %o0                                 
  if (req == NULL)                                                    
400078fc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40007900:	32 80 00 0b 	bne,a   4000792c <aio_fsync+0x6c>              <== ALWAYS TAKEN
40007904:	f2 26 20 14 	st  %i1, [ %i0 + 0x14 ]                        
    rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);            
40007908:	ba 10 20 0b 	mov  0xb, %i5                                  <== NOT EXECUTED
4000790c:	82 10 3f ff 	mov  -1, %g1                                   
40007910:	fa 26 60 34 	st  %i5, [ %i1 + 0x34 ]                        
40007914:	c2 26 60 38 	st  %g1, [ %i1 + 0x38 ]                        
40007918:	40 00 29 e5 	call  400120ac <__errno>                       
4000791c:	b0 10 3f ff 	mov  -1, %i0                                   
40007920:	fa 22 00 00 	st  %i5, [ %o0 ]                               
  req->aiocbp = aiocbp;                                               
  req->aiocbp->aio_lio_opcode = LIO_SYNC;                             
                                                                      
  return rtems_aio_enqueue (req);                                     
                                                                      
}                                                                     
40007924:	81 c7 e0 08 	ret                                            
40007928:	81 e8 00 00 	restore                                        
  req = malloc (sizeof (rtems_aio_request));                          
  if (req == NULL)                                                    
    rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);            
                                                                      
  req->aiocbp = aiocbp;                                               
  req->aiocbp->aio_lio_opcode = LIO_SYNC;                             
4000792c:	82 10 20 03 	mov  3, %g1                                    
40007930:	c2 26 60 30 	st  %g1, [ %i1 + 0x30 ]                        
                                                                      
  return rtems_aio_enqueue (req);                                     
40007934:	40 00 01 48 	call  40007e54 <rtems_aio_enqueue>             
40007938:	81 e8 00 00 	restore                                        
                                                                      

4000807c <aio_read>: * 0 - otherwise */ int aio_read (struct aiocb *aiocbp) {
4000807c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_aio_request *req;                                             
  int mode;                                                           
                                                                      
  mode = fcntl (aiocbp->aio_fildes, F_GETFL);                         
40008080:	d0 06 00 00 	ld  [ %i0 ], %o0                               
40008084:	92 10 20 03 	mov  3, %o1                                    
40008088:	40 00 19 54 	call  4000e5d8 <fcntl>                         
4000808c:	ba 10 00 18 	mov  %i0, %i5                                  
  if (!(((mode & O_ACCMODE) == O_RDONLY) || ((mode & O_ACCMODE) == O_RDWR)))
40008090:	80 8a 20 01 	btst  1, %o0                                   
40008094:	12 80 00 11 	bne  400080d8 <aio_read+0x5c>                  
40008098:	b8 10 20 09 	mov  9, %i4                                    
    rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);             
                                                                      
  if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX)
4000809c:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
400080a0:	80 a0 60 00 	cmp  %g1, 0                                    
400080a4:	22 80 00 04 	be,a   400080b4 <aio_read+0x38>                
400080a8:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
    rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);            
400080ac:	10 80 00 0b 	b  400080d8 <aio_read+0x5c>                    
400080b0:	b8 10 20 16 	mov  0x16, %i4                                 
                                                                      
  if (aiocbp->aio_offset < 0)                                         
400080b4:	80 a0 60 00 	cmp  %g1, 0                                    
400080b8:	06 80 00 08 	bl  400080d8 <aio_read+0x5c>                   
400080bc:	b8 10 20 16 	mov  0x16, %i4                                 
    rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);            
                                                                      
  req = malloc (sizeof (rtems_aio_request));                          
400080c0:	7f ff f0 94 	call  40004310 <malloc>                        
400080c4:	90 10 20 18 	mov  0x18, %o0                                 
  if (req == NULL)                                                    
400080c8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400080cc:	32 80 00 0b 	bne,a   400080f8 <aio_read+0x7c>               <== ALWAYS TAKEN
400080d0:	fa 26 20 14 	st  %i5, [ %i0 + 0x14 ]                        
    rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);            
400080d4:	b8 10 20 0b 	mov  0xb, %i4                                  <== NOT EXECUTED
400080d8:	82 10 3f ff 	mov  -1, %g1                                   
400080dc:	f8 27 60 34 	st  %i4, [ %i5 + 0x34 ]                        
400080e0:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
400080e4:	40 00 27 f2 	call  400120ac <__errno>                       
400080e8:	b0 10 3f ff 	mov  -1, %i0                                   
400080ec:	f8 22 00 00 	st  %i4, [ %o0 ]                               
                                                                      
  req->aiocbp = aiocbp;                                               
  req->aiocbp->aio_lio_opcode = LIO_READ;                             
                                                                      
  return rtems_aio_enqueue (req);                                     
}                                                                     
400080f0:	81 c7 e0 08 	ret                                            
400080f4:	81 e8 00 00 	restore                                        
  req = malloc (sizeof (rtems_aio_request));                          
  if (req == NULL)                                                    
    rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);            
                                                                      
  req->aiocbp = aiocbp;                                               
  req->aiocbp->aio_lio_opcode = LIO_READ;                             
400080f8:	82 10 20 01 	mov  1, %g1                                    
400080fc:	c2 27 60 30 	st  %g1, [ %i5 + 0x30 ]                        
                                                                      
  return rtems_aio_enqueue (req);                                     
40008100:	7f ff ff 55 	call  40007e54 <rtems_aio_enqueue>             
40008104:	81 e8 00 00 	restore                                        
                                                                      

40008110 <aio_write>: * 0 - otherwise */ int aio_write (struct aiocb *aiocbp) {
40008110:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_aio_request *req;                                             
  int mode;                                                           
                                                                      
  mode = fcntl (aiocbp->aio_fildes, F_GETFL);                         
40008114:	d0 06 00 00 	ld  [ %i0 ], %o0                               
40008118:	40 00 19 30 	call  4000e5d8 <fcntl>                         
4000811c:	92 10 20 03 	mov  3, %o1                                    
 *         0 - otherwise                                              
 */                                                                   
                                                                      
int                                                                   
aio_write (struct aiocb *aiocbp)                                      
{                                                                     
40008120:	ba 10 00 18 	mov  %i0, %i5                                  
  rtems_aio_request *req;                                             
  int mode;                                                           
                                                                      
  mode = fcntl (aiocbp->aio_fildes, F_GETFL);                         
  if (!(((mode & O_ACCMODE) == O_WRONLY) || ((mode & O_ACCMODE) == O_RDWR)))
40008124:	90 0a 20 03 	and  %o0, 3, %o0                               
40008128:	90 02 3f ff 	add  %o0, -1, %o0                              
4000812c:	80 a2 20 01 	cmp  %o0, 1                                    
40008130:	18 80 00 11 	bgu  40008174 <aio_write+0x64>                 
40008134:	b8 10 20 09 	mov  9, %i4                                    
    rtems_aio_set_errno_return_minus_one (EBADF, aiocbp);             
                                                                      
  if (aiocbp->aio_reqprio < 0 || aiocbp->aio_reqprio > AIO_PRIO_DELTA_MAX)
40008138:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
4000813c:	80 a0 60 00 	cmp  %g1, 0                                    
40008140:	22 80 00 04 	be,a   40008150 <aio_write+0x40>               
40008144:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
    rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);            
40008148:	10 80 00 0b 	b  40008174 <aio_write+0x64>                   
4000814c:	b8 10 20 16 	mov  0x16, %i4                                 
                                                                      
  if (aiocbp->aio_offset < 0)                                         
40008150:	80 a0 60 00 	cmp  %g1, 0                                    
40008154:	06 80 00 08 	bl  40008174 <aio_write+0x64>                  
40008158:	b8 10 20 16 	mov  0x16, %i4                                 
    rtems_aio_set_errno_return_minus_one (EINVAL, aiocbp);            
                                                                      
  req = malloc (sizeof (rtems_aio_request));                          
4000815c:	7f ff f0 6d 	call  40004310 <malloc>                        
40008160:	90 10 20 18 	mov  0x18, %o0                                 
  if (req == NULL)                                                    
40008164:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40008168:	32 80 00 0b 	bne,a   40008194 <aio_write+0x84>              <== ALWAYS TAKEN
4000816c:	fa 26 20 14 	st  %i5, [ %i0 + 0x14 ]                        
    rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);            
40008170:	b8 10 20 0b 	mov  0xb, %i4                                  <== NOT EXECUTED
40008174:	82 10 3f ff 	mov  -1, %g1                                   
40008178:	f8 27 60 34 	st  %i4, [ %i5 + 0x34 ]                        
4000817c:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
40008180:	40 00 27 cb 	call  400120ac <__errno>                       
40008184:	b0 10 3f ff 	mov  -1, %i0                                   
40008188:	f8 22 00 00 	st  %i4, [ %o0 ]                               
                                                                      
  req->aiocbp = aiocbp;                                               
  req->aiocbp->aio_lio_opcode = LIO_WRITE;                            
                                                                      
  return rtems_aio_enqueue (req);                                     
}                                                                     
4000818c:	81 c7 e0 08 	ret                                            
40008190:	81 e8 00 00 	restore                                        
  req = malloc (sizeof (rtems_aio_request));                          
  if (req == NULL)                                                    
    rtems_aio_set_errno_return_minus_one (EAGAIN, aiocbp);            
                                                                      
  req->aiocbp = aiocbp;                                               
  req->aiocbp->aio_lio_opcode = LIO_WRITE;                            
40008194:	82 10 20 02 	mov  2, %g1                                    
40008198:	c2 27 60 30 	st  %g1, [ %i5 + 0x30 ]                        
                                                                      
  return rtems_aio_enqueue (req);                                     
4000819c:	7f ff ff 2e 	call  40007e54 <rtems_aio_enqueue>             
400081a0:	81 e8 00 00 	restore                                        
                                                                      

400041a8 <chroot>: #include <unistd.h> #include <rtems/libio_.h> int chroot( const char *path ) {
400041a8:	9d e3 bf 48 	save  %sp, -184, %sp                           
                                                                      
  /*                                                                  
   * We use the global environment for path evaluation.  This makes it possible
   * to escape from a chroot environment referencing an unmounted file system.
   */                                                                 
  rtems_filesystem_eval_path_start_with_root_and_current(             
400041ac:	94 10 20 19 	mov  0x19, %o2                                 
400041b0:	92 10 00 18 	mov  %i0, %o1                                  
400041b4:	90 07 bf c8 	add  %fp, -56, %o0                             
400041b8:	17 10 00 4c 	sethi  %hi(0x40013000), %o3                    
400041bc:	96 12 e3 84 	or  %o3, 0x384, %o3	! 40013384 <rtems_global_user_env+0x4>
400041c0:	40 00 04 c1 	call  400054c4 <rtems_filesystem_eval_path_start_with_root_and_current>
400041c4:	98 02 ff fc 	add  %o3, -4, %o4                              
400041c8:	90 07 bf b0 	add  %fp, -80, %o0                             
400041cc:	40 00 05 de 	call  40005944 <rtems_filesystem_location_copy_and_detach>
400041d0:	92 07 bf e0 	add  %fp, -32, %o1                             
    &rtems_global_user_env.root_directory,                            
    &rtems_global_user_env.current_directory                          
  );                                                                  
                                                                      
  rtems_filesystem_eval_path_extract_currentloc( &ctx, &loc );        
  new_current_loc = rtems_filesystem_location_transform_to_global( &loc );
400041d4:	40 00 05 e6 	call  4000596c <rtems_filesystem_location_transform_to_global>
400041d8:	90 07 bf b0 	add  %fp, -80, %o0                             
  if ( !rtems_filesystem_global_location_is_null( new_current_loc ) ) {
400041dc:	c2 02 20 10 	ld  [ %o0 + 0x10 ], %g1                        
400041e0:	39 10 00 4b 	sethi  %hi(0x40012c00), %i4                    
400041e4:	b8 17 21 28 	or  %i4, 0x128, %i4	! 40012d28 <rtems_filesystem_null_handlers>
400041e8:	80 a0 40 1c 	cmp  %g1, %i4                                  
400041ec:	02 80 00 2a 	be  40004294 <chroot+0xec>                     
400041f0:	d0 27 bf ac 	st  %o0, [ %fp + -84 ]                         
    rtems_filesystem_global_location_t *new_root_loc =                
400041f4:	40 00 05 70 	call  400057b4 <rtems_filesystem_global_location_obtain>
400041f8:	90 07 bf ac 	add  %fp, -84, %o0                             
      rtems_filesystem_global_location_obtain( &new_current_loc );    
    rtems_filesystem_node_types_t type =                              
      (*new_root_loc->location.mt_entry->ops->node_type_h)(           
400041fc:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
40004200:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
  rtems_filesystem_eval_path_extract_currentloc( &ctx, &loc );        
  new_current_loc = rtems_filesystem_location_transform_to_global( &loc );
  if ( !rtems_filesystem_global_location_is_null( new_current_loc ) ) {
    rtems_filesystem_global_location_t *new_root_loc =                
      rtems_filesystem_global_location_obtain( &new_current_loc );    
    rtems_filesystem_node_types_t type =                              
40004204:	c2 00 60 14 	ld  [ %g1 + 0x14 ], %g1                        
40004208:	9f c0 40 00 	call  %g1                                      
4000420c:	ba 10 00 08 	mov  %o0, %i5                                  
      (*new_root_loc->location.mt_entry->ops->node_type_h)(           
        &new_root_loc->location                                       
      );                                                              
                                                                      
    if ( type == RTEMS_FILESYSTEM_DIRECTORY ) {                       
40004210:	80 a2 20 00 	cmp  %o0, 0                                    
40004214:	32 80 00 17 	bne,a   40004270 <chroot+0xc8>                 
40004218:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
      sc = rtems_libio_set_private_env();                             
4000421c:	40 00 03 1e 	call  40004e94 <rtems_libio_set_private_env>   
40004220:	01 00 00 00 	nop                                            
      if (sc == RTEMS_SUCCESSFUL) {                                   
40004224:	80 a2 20 00 	cmp  %o0, 0                                    
40004228:	12 80 00 0c 	bne  40004258 <chroot+0xb0>                    
4000422c:	80 a2 20 0d 	cmp  %o0, 0xd                                  
        rtems_filesystem_global_location_assign(                      
          &rtems_filesystem_root,                                     
40004230:	40 00 03 00 	call  40004e30 <rtems_current_user_env_get>    
40004234:	b0 10 20 00 	clr  %i0                                       
      );                                                              
                                                                      
    if ( type == RTEMS_FILESYSTEM_DIRECTORY ) {                       
      sc = rtems_libio_set_private_env();                             
      if (sc == RTEMS_SUCCESSFUL) {                                   
        rtems_filesystem_global_location_assign(                      
40004238:	92 10 00 1d 	mov  %i5, %o1                                  
4000423c:	40 00 05 a4 	call  400058cc <rtems_filesystem_global_location_assign>
40004240:	90 02 20 04 	add  %o0, 4, %o0                               
          &rtems_filesystem_root,                                     
          new_root_loc                                                
        );                                                            
        rtems_filesystem_global_location_assign(                      
          &rtems_filesystem_current,                                  
40004244:	40 00 02 fb 	call  40004e30 <rtems_current_user_env_get>    
40004248:	01 00 00 00 	nop                                            
      if (sc == RTEMS_SUCCESSFUL) {                                   
        rtems_filesystem_global_location_assign(                      
          &rtems_filesystem_root,                                     
          new_root_loc                                                
        );                                                            
        rtems_filesystem_global_location_assign(                      
4000424c:	40 00 05 a0 	call  400058cc <rtems_filesystem_global_location_assign>
40004250:	d2 07 bf ac 	ld  [ %fp + -84 ], %o1                         
40004254:	30 80 00 11 	b,a   40004298 <chroot+0xf0>                   
          &rtems_filesystem_current,                                  
          new_current_loc                                             
        );                                                            
      } else {                                                        
        if (sc != RTEMS_UNSATISFIED) {                                
40004258:	02 80 00 0d 	be  4000428c <chroot+0xe4>                     <== NEVER TAKEN
4000425c:	01 00 00 00 	nop                                            
          errno = ENOMEM;                                             
40004260:	40 00 22 b1 	call  4000cd24 <__errno>                       
40004264:	01 00 00 00 	nop                                            
40004268:	10 80 00 08 	b  40004288 <chroot+0xe0>                      
4000426c:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         
static inline void rtems_filesystem_location_error(                   
  const rtems_filesystem_location_info_t *loc,                        
  int eno                                                             
)                                                                     
{                                                                     
  if ( !rtems_filesystem_location_is_null( loc ) ) {                  
40004270:	80 a0 40 1c 	cmp  %g1, %i4                                  
40004274:	02 80 00 06 	be  4000428c <chroot+0xe4>                     <== NEVER TAKEN
40004278:	01 00 00 00 	nop                                            
    errno = eno;                                                      
4000427c:	40 00 22 aa 	call  4000cd24 <__errno>                       
40004280:	01 00 00 00 	nop                                            
40004284:	82 10 20 14 	mov  0x14, %g1	! 14 <_TLS_Alignment+0x13>      
40004288:	c2 22 00 00 	st  %g1, [ %o0 ]                               
      rtems_filesystem_location_error( &new_root_loc->location, ENOTDIR );
      rv = -1;                                                        
    }                                                                 
                                                                      
    if ( rv != 0 ) {                                                  
      rtems_filesystem_global_location_release( new_root_loc );       
4000428c:	40 00 05 7c 	call  4000587c <rtems_filesystem_global_location_release>
40004290:	90 10 00 1d 	mov  %i5, %o0                                  
    }                                                                 
  } else {                                                            
    rv = -1;                                                          
40004294:	b0 10 3f ff 	mov  -1, %i0                                   
  }                                                                   
                                                                      
  rtems_filesystem_eval_path_cleanup( &ctx );                         
40004298:	40 00 04 b0 	call  40005558 <rtems_filesystem_eval_path_cleanup>
4000429c:	90 07 bf c8 	add  %fp, -56, %o0                             
                                                                      
  if ( rv != 0 ) {                                                    
400042a0:	80 a6 20 00 	cmp  %i0, 0                                    
400042a4:	02 80 00 06 	be  400042bc <chroot+0x114>                    
400042a8:	01 00 00 00 	nop                                            
    rtems_filesystem_global_location_release( new_current_loc );      
400042ac:	40 00 05 74 	call  4000587c <rtems_filesystem_global_location_release>
400042b0:	d0 07 bf ac 	ld  [ %fp + -84 ], %o0                         
400042b4:	81 c7 e0 08 	ret                                            
400042b8:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
400042bc:	81 c7 e0 08 	ret                                            
400042c0:	81 e8 00 00 	restore                                        
                                                                      

40006e6c <clock_gettime>: int clock_gettime( clockid_t clock_id, struct timespec *tp ) {
40006e6c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  if ( !tp )                                                          
40006e70:	80 a6 60 00 	cmp  %i1, 0                                    
40006e74:	12 80 00 06 	bne  40006e8c <clock_gettime+0x20>             
40006e78:	80 a6 20 01 	cmp  %i0, 1                                    
    rtems_set_errno_and_return_minus_one( EINVAL );                   
40006e7c:	40 00 24 35 	call  4000ff50 <__errno>                       
40006e80:	01 00 00 00 	nop                                            
40006e84:	10 80 00 25 	b  40006f18 <clock_gettime+0xac>               
40006e88:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
                                                                      
  if ( clock_id == CLOCK_REALTIME ) {                                 
40006e8c:	12 80 00 16 	bne  40006ee4 <clock_gettime+0x78>             
40006e90:	80 a6 20 04 	cmp  %i0, 4                                    
)                                                                     
{                                                                     
  Timestamp_Control  tod_as_timestamp;                                
  Timestamp_Control *tod_as_timestamp_ptr;                            
                                                                      
  tod_as_timestamp_ptr =                                              
40006e94:	90 07 bf f8 	add  %fp, -8, %o0                              
40006e98:	13 10 00 6a 	sethi  %hi(0x4001a800), %o1                    
40006e9c:	40 00 06 65 	call  40008830 <_TOD_Get_with_nanoseconds>     
40006ea0:	92 12 61 20 	or  %o1, 0x120, %o1	! 4001a920 <_TOD>          
static inline void _TOD_Get(                                          
  struct timespec *tod_as_timespec                                    
)                                                                     
{                                                                     
  Timestamp_Control  tod_as_timestamp;                                
  Timestamp_Control *tod_as_timestamp_ptr;                            
40006ea4:	f8 1a 00 00 	ldd  [ %o0 ], %i4                              
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
40006ea8:	94 10 20 00 	clr  %o2                                       
40006eac:	90 10 00 1c 	mov  %i4, %o0                                  
40006eb0:	92 10 00 1d 	mov  %i5, %o1                                  
40006eb4:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40006eb8:	40 00 3b 45 	call  40015bcc <__divdi3>                      
40006ebc:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
40006ec0:	90 10 00 1c 	mov  %i4, %o0                                  
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
40006ec4:	d2 26 40 00 	st  %o1, [ %i1 ]                               
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
40006ec8:	94 10 20 00 	clr  %o2                                       
40006ecc:	92 10 00 1d 	mov  %i5, %o1                                  
40006ed0:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40006ed4:	40 00 3c 30 	call  40015f94 <__moddi3>                      
40006ed8:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
40006edc:	10 80 00 06 	b  40006ef4 <clock_gettime+0x88>               
40006ee0:	d2 26 60 04 	st  %o1, [ %i1 + 4 ]                           
    _TOD_Get(tp);                                                     
    return 0;                                                         
  }                                                                   
#ifdef CLOCK_MONOTONIC                                                
  if ( clock_id == CLOCK_MONOTONIC ) {                                
40006ee4:	12 80 00 06 	bne  40006efc <clock_gettime+0x90>             <== ALWAYS TAKEN
40006ee8:	80 a6 20 02 	cmp  %i0, 2                                    
    _TOD_Get_uptime_as_timespec( tp );                                
40006eec:	40 00 06 62 	call  40008874 <_TOD_Get_uptime_as_timespec>   
40006ef0:	90 10 00 19 	mov  %i1, %o0                                  
    return 0;                                                         
40006ef4:	81 c7 e0 08 	ret                                            
40006ef8:	91 e8 20 00 	restore  %g0, 0, %o0                           
  }                                                                   
#endif                                                                
                                                                      
#ifdef _POSIX_CPUTIME                                                 
  if ( clock_id == CLOCK_PROCESS_CPUTIME_ID ) {                       
40006efc:	02 bf ff fc 	be  40006eec <clock_gettime+0x80>              
40006f00:	80 a6 20 03 	cmp  %i0, 3                                    
    return 0;                                                         
  }                                                                   
#endif                                                                
                                                                      
#ifdef _POSIX_THREAD_CPUTIME                                          
  if ( clock_id == CLOCK_THREAD_CPUTIME_ID )                          
40006f04:	12 bf ff de 	bne  40006e7c <clock_gettime+0x10>             
40006f08:	01 00 00 00 	nop                                            
    rtems_set_errno_and_return_minus_one( ENOSYS );                   
40006f0c:	40 00 24 11 	call  4000ff50 <__errno>                       
40006f10:	01 00 00 00 	nop                                            
40006f14:	82 10 20 58 	mov  0x58, %g1	! 58 <_TLS_Alignment+0x57>      
40006f18:	c2 22 00 00 	st  %g1, [ %o0 ]                               
#endif                                                                
                                                                      
  rtems_set_errno_and_return_minus_one( EINVAL );                     
                                                                      
  return 0;                                                           
}                                                                     
40006f1c:	81 c7 e0 08 	ret                                            
40006f20:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      

400072e4 <clock_settime>: int clock_settime( clockid_t clock_id, const struct timespec *tp ) {
400072e4:	9d e3 bf 98 	save  %sp, -104, %sp                           
  if ( !tp )                                                          
400072e8:	82 96 60 00 	orcc  %i1, 0, %g1                              
400072ec:	12 80 00 06 	bne  40007304 <clock_settime+0x20>             <== ALWAYS TAKEN
400072f0:	80 a6 20 01 	cmp  %i0, 1                                    
    rtems_set_errno_and_return_minus_one( EINVAL );                   
400072f4:	40 00 26 31 	call  40010bb8 <__errno>                       
400072f8:	01 00 00 00 	nop                                            
400072fc:	10 80 00 4a 	b  40007424 <clock_settime+0x140>              
40007300:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
                                                                      
  if ( clock_id == CLOCK_REALTIME ) {                                 
40007304:	32 80 00 42 	bne,a   4000740c <clock_settime+0x128>         
40007308:	b0 06 3f fe 	add  %i0, -2, %i0                              
    if ( tp->tv_sec < TOD_SECONDS_1970_THROUGH_1988 )                 
4000730c:	c6 00 40 00 	ld  [ %g1 ], %g3                               
40007310:	05 08 76 b9 	sethi  %hi(0x21dae400), %g2                    
40007314:	84 10 a0 ff 	or  %g2, 0xff, %g2	! 21dae4ff <RAM_SIZE+0x219ae4ff>
40007318:	80 a0 c0 02 	cmp  %g3, %g2                                  
4000731c:	08 bf ff f6 	bleu  400072f4 <clock_settime+0x10>            
40007320:	01 00 00 00 	nop                                            
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40007324:	c6 01 a0 10 	ld  [ %g6 + 0x10 ], %g3                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40007328:	86 00 e0 01 	inc  %g3                                       
    _Thread_Dispatch_disable_level = disable_level;                   
4000732c:	c6 21 a0 10 	st  %g3, [ %g6 + 0x10 ]                        
  const struct timespec *tod_as_timespec                              
)                                                                     
{                                                                     
  Timestamp_Control tod_as_timestamp;                                 
                                                                      
  _Timestamp_Set(                                                     
40007330:	c8 00 40 00 	ld  [ %g1 ], %g4                               
40007334:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
40007338:	86 10 00 04 	mov  %g4, %g3                                  
4000733c:	85 39 20 1f 	sra  %g4, 0x1f, %g2                            
  Timestamp64_Control *_time,                                         
  Timestamp64_Control  _seconds,                                      
  Timestamp64_Control  _nanoseconds                                   
)                                                                     
{                                                                     
  *_time = _seconds * 1000000000L + _nanoseconds;                     
40007340:	b7 31 20 1d 	srl  %g4, 0x1d, %i3                            
40007344:	89 28 a0 03 	sll  %g2, 3, %g4                               
40007348:	bb 28 e0 03 	sll  %g3, 3, %i5                               
4000734c:	b8 16 c0 04 	or  %i3, %g4, %i4                              
40007350:	89 37 60 1b 	srl  %i5, 0x1b, %g4                            
40007354:	b5 2f 20 05 	sll  %i4, 5, %i2                               
40007358:	b7 2f 60 05 	sll  %i5, 5, %i3                               
4000735c:	b4 11 00 1a 	or  %g4, %i2, %i2                              
40007360:	ba a6 c0 1d 	subcc  %i3, %i5, %i5                           
40007364:	89 37 60 1a 	srl  %i5, 0x1a, %g4                            
40007368:	b8 66 80 1c 	subx  %i2, %i4, %i4                            
4000736c:	b7 2f 60 06 	sll  %i5, 6, %i3                               
40007370:	b5 2f 20 06 	sll  %i4, 6, %i2                               
40007374:	b6 a6 c0 1d 	subcc  %i3, %i5, %i3                           
40007378:	b4 11 00 1a 	or  %g4, %i2, %i2                              
4000737c:	b4 66 80 1c 	subx  %i2, %i4, %i2                            
40007380:	b2 86 c0 03 	addcc  %i3, %g3, %i1                           
40007384:	b0 46 80 02 	addx  %i2, %g2, %i0                            
40007388:	89 36 60 1e 	srl  %i1, 0x1e, %g4                            
4000738c:	85 2e 20 02 	sll  %i0, 2, %g2                               
40007390:	84 11 00 02 	or  %g4, %g2, %g2                              
40007394:	87 2e 60 02 	sll  %i1, 2, %g3                               
40007398:	ba 86 40 03 	addcc  %i1, %g3, %i5                           
4000739c:	b8 46 00 02 	addx  %i0, %g2, %i4                            
400073a0:	89 37 60 1e 	srl  %i5, 0x1e, %g4                            
400073a4:	85 2f 20 02 	sll  %i4, 2, %g2                               
400073a8:	84 11 00 02 	or  %g4, %g2, %g2                              
400073ac:	87 2f 60 02 	sll  %i5, 2, %g3                               
400073b0:	b6 87 40 03 	addcc  %i5, %g3, %i3                           
400073b4:	b4 47 00 02 	addx  %i4, %g2, %i2                            
400073b8:	85 36 e0 1e 	srl  %i3, 0x1e, %g2                            
400073bc:	bb 2e e0 02 	sll  %i3, 2, %i5                               
400073c0:	b9 2e a0 02 	sll  %i2, 2, %i4                               
400073c4:	86 86 c0 1d 	addcc  %i3, %i5, %g3                           
400073c8:	b8 10 80 1c 	or  %g2, %i4, %i4                              
400073cc:	84 46 80 1c 	addx  %i2, %i4, %g2                            
400073d0:	89 28 e0 09 	sll  %g3, 9, %g4                               
400073d4:	b9 30 e0 17 	srl  %g3, 0x17, %i4                            
400073d8:	b6 81 00 01 	addcc  %g4, %g1, %i3                           
    &tod_as_timestamp,                                                
    tod_as_timespec->tv_sec,                                          
    tod_as_timespec->tv_nsec                                          
  );                                                                  
  _TOD_Set_with_timestamp( &tod_as_timestamp );                       
400073dc:	90 07 bf f8 	add  %fp, -8, %o0                              
400073e0:	bb 28 a0 09 	sll  %g2, 9, %i5                               
400073e4:	84 17 00 1d 	or  %i4, %i5, %g2                              
    rtems_set_errno_and_return_minus_one( ENOSYS );                   
#endif                                                                
  else                                                                
    rtems_set_errno_and_return_minus_one( EINVAL );                   
                                                                      
  return 0;                                                           
400073e8:	b0 10 20 00 	clr  %i0                                       
  const struct timespec *tod_as_timespec                              
)                                                                     
{                                                                     
  Timestamp_Control tod_as_timestamp;                                 
                                                                      
  _Timestamp_Set(                                                     
400073ec:	b9 38 60 1f 	sra  %g1, 0x1f, %i4                            
400073f0:	b4 40 80 1c 	addx  %g2, %i4, %i2                            
    &tod_as_timestamp,                                                
    tod_as_timespec->tv_sec,                                          
    tod_as_timespec->tv_nsec                                          
  );                                                                  
  _TOD_Set_with_timestamp( &tod_as_timestamp );                       
400073f4:	40 00 07 e8 	call  40009394 <_TOD_Set_with_timestamp>       
400073f8:	f4 3f bf f8 	std  %i2, [ %fp + -8 ]                         
    if ( tp->tv_sec < TOD_SECONDS_1970_THROUGH_1988 )                 
      rtems_set_errno_and_return_minus_one( EINVAL );                 
                                                                      
    _Thread_Disable_dispatch();                                       
      _TOD_Set( tp );                                                 
    _Thread_Enable_dispatch();                                        
400073fc:	40 00 0e 26 	call  4000ac94 <_Thread_Enable_dispatch>       
40007400:	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;                                                           
40007404:	81 c7 e0 08 	ret                                            
40007408:	81 e8 00 00 	restore                                        
    _Thread_Disable_dispatch();                                       
      _TOD_Set( tp );                                                 
    _Thread_Enable_dispatch();                                        
  }                                                                   
#ifdef _POSIX_CPUTIME                                                 
  else if ( clock_id == CLOCK_PROCESS_CPUTIME_ID )                    
4000740c:	80 a6 20 01 	cmp  %i0, 1                                    
40007410:	18 bf ff b9 	bgu  400072f4 <clock_settime+0x10>             
40007414:	01 00 00 00 	nop                                            
    rtems_set_errno_and_return_minus_one( ENOSYS );                   
40007418:	40 00 25 e8 	call  40010bb8 <__errno>                       
4000741c:	01 00 00 00 	nop                                            
40007420:	82 10 20 58 	mov  0x58, %g1	! 58 <_TLS_Alignment+0x57>      
40007424:	c2 22 00 00 	st  %g1, [ %o0 ]                               
#endif                                                                
  else                                                                
    rtems_set_errno_and_return_minus_one( EINVAL );                   
                                                                      
  return 0;                                                           
}                                                                     
40007428:	81 c7 e0 08 	ret                                            
4000742c:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      

40003a4c <create_disk>: dev_t dev, const char *name, rtems_disk_device **dd_ptr, char **alloc_name_ptr ) {
40003a4c:	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) {                                        
40003a50:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003a54:	e0 00 62 80 	ld  [ %g1 + 0x280 ], %l0	! 4001c280 <disktab_size>
40003a58:	a6 10 00 01 	mov  %g1, %l3                                  
40003a5c:	80 a6 00 10 	cmp  %i0, %l0                                  
40003a60:	0a 80 00 13 	bcs  40003aac <create_disk+0x60>               
40003a64:	25 10 00 70 	sethi  %hi(0x4001c000), %l2                    
    rtems_disk_device_table *table = disktab;                         
    rtems_device_major_number old_size = disktab_size;                
    rtems_device_major_number new_size = 2 * old_size;                
40003a68:	bb 2c 20 01 	sll  %l0, 1, %i5                               
                                                                      
    if (major >= new_size) {                                          
40003a6c:	80 a6 00 1d 	cmp  %i0, %i5                                  
40003a70:	0a 80 00 03 	bcs  40003a7c <create_disk+0x30>               <== NEVER TAKEN
40003a74:	d0 04 a2 84 	ld  [ %l2 + 0x284 ], %o0                       
      new_size = major + 1;                                           
40003a78:	ba 06 20 01 	add  %i0, 1, %i5                               
    }                                                                 
                                                                      
    table = realloc(table, new_size * sizeof(*table));                
40003a7c:	40 00 07 3a 	call  40005764 <realloc>                       
40003a80:	93 2f 60 03 	sll  %i5, 3, %o1                               
    if (table == NULL) {                                              
40003a84:	a2 92 20 00 	orcc  %o0, 0, %l1                              
40003a88:	02 80 00 53 	be  40003bd4 <create_disk+0x188>               <== ALWAYS TAKEN
40003a8c:	94 27 40 10 	sub  %i5, %l0, %o2                             
      return NULL;                                                    
    }                                                                 
                                                                      
    memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
40003a90:	91 2c 20 03 	sll  %l0, 3, %o0                               <== NOT EXECUTED
40003a94:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
40003a98:	90 04 40 08 	add  %l1, %o0, %o0                             <== NOT EXECUTED
40003a9c:	40 00 43 03 	call  400146a8 <memset>                        <== NOT EXECUTED
40003aa0:	95 2a a0 03 	sll  %o2, 3, %o2                               <== NOT EXECUTED
    disktab = table;                                                  
40003aa4:	e2 24 a2 84 	st  %l1, [ %l2 + 0x284 ]                       <== NOT EXECUTED
    disktab_size = new_size;                                          
40003aa8:	fa 24 e2 80 	st  %i5, [ %l3 + 0x280 ]                       <== NOT EXECUTED
  }                                                                   
                                                                      
  if (disktab [major].minor == NULL || minor >= disktab[major].size) {
40003aac:	e4 04 a2 84 	ld  [ %l2 + 0x284 ], %l2                       
40003ab0:	a3 2e 20 03 	sll  %i0, 3, %l1                               
40003ab4:	d0 04 80 11 	ld  [ %l2 + %l1 ], %o0                         
40003ab8:	a8 04 80 11 	add  %l2, %l1, %l4                             
40003abc:	80 a2 20 00 	cmp  %o0, 0                                    
40003ac0:	02 80 00 05 	be  40003ad4 <create_disk+0x88>                
40003ac4:	e0 05 20 04 	ld  [ %l4 + 4 ], %l0                           
40003ac8:	80 a6 40 10 	cmp  %i1, %l0                                  
40003acc:	2a 80 00 16 	bcs,a   40003b24 <create_disk+0xd8>            
40003ad0:	e2 04 80 11 	ld  [ %l2 + %l1 ], %l1                         
    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) {                                              
40003ad4:	80 a4 20 00 	cmp  %l0, 0                                    
40003ad8:	02 80 00 03 	be  40003ae4 <create_disk+0x98>                
40003adc:	ba 10 20 08 	mov  8, %i5                                    
      new_size = DISKTAB_INITIAL_SIZE;                                
    } else {                                                          
      new_size = 2 * old_size;                                        
40003ae0:	bb 2c 20 01 	sll  %l0, 1, %i5                               
    }                                                                 
    if (minor >= new_size) {                                          
40003ae4:	80 a6 40 1d 	cmp  %i1, %i5                                  
40003ae8:	3a 80 00 02 	bcc,a   40003af0 <create_disk+0xa4>            
40003aec:	ba 06 60 01 	add  %i1, 1, %i5                               
      new_size = minor + 1;                                           
    }                                                                 
                                                                      
    table = realloc(table, new_size * sizeof(*table));                
40003af0:	40 00 07 1d 	call  40005764 <realloc>                       
40003af4:	93 2f 60 02 	sll  %i5, 2, %o1                               
    if (table == NULL) {                                              
40003af8:	a6 92 20 00 	orcc  %o0, 0, %l3                              
40003afc:	02 80 00 36 	be  40003bd4 <create_disk+0x188>               
40003b00:	94 27 40 10 	sub  %i5, %l0, %o2                             
      return NULL;                                                    
    }                                                                 
                                                                      
    memset(table + old_size, 0, (new_size - old_size) * sizeof(*table));
40003b04:	91 2c 20 02 	sll  %l0, 2, %o0                               
40003b08:	92 10 20 00 	clr  %o1                                       
40003b0c:	90 04 c0 08 	add  %l3, %o0, %o0                             
40003b10:	40 00 42 e6 	call  400146a8 <memset>                        
40003b14:	95 2a a0 02 	sll  %o2, 2, %o2                               
    disktab [major].minor = table;                                    
40003b18:	e6 24 80 11 	st  %l3, [ %l2 + %l1 ]                         
    disktab [major].size = new_size;                                  
40003b1c:	fa 25 20 04 	st  %i5, [ %l4 + 4 ]                           
  }                                                                   
                                                                      
  return disktab [major].minor + minor;                               
40003b20:	e2 04 80 11 	ld  [ %l2 + %l1 ], %l1                         
40003b24:	a1 2e 60 02 	sll  %i1, 2, %l0                               
40003b28:	82 04 40 10 	add  %l1, %l0, %g1                             
{                                                                     
  rtems_disk_device **dd_entry = create_disk_table_entry(dev);        
  rtems_disk_device *dd = NULL;                                       
  char *alloc_name = NULL;                                            
                                                                      
  if (dd_entry == NULL) {                                             
40003b2c:	80 a0 60 00 	cmp  %g1, 0                                    
40003b30:	02 80 00 2a 	be  40003bd8 <create_disk+0x18c>               <== NEVER TAKEN
40003b34:	82 10 20 1a 	mov  0x1a, %g1                                 
    return RTEMS_NO_MEMORY;                                           
  }                                                                   
                                                                      
  if (*dd_entry != NULL) {                                            
40003b38:	c4 04 40 10 	ld  [ %l1 + %l0 ], %g2                         
40003b3c:	80 a0 a0 00 	cmp  %g2, 0                                    
40003b40:	12 80 00 26 	bne  40003bd8 <create_disk+0x18c>              
40003b44:	82 10 20 0c 	mov  0xc, %g1                                  
    return RTEMS_RESOURCE_IN_USE;                                     
  }                                                                   
                                                                      
  dd = malloc(sizeof(*dd));                                           
40003b48:	40 00 04 c1 	call  40004e4c <malloc>                        
40003b4c:	90 10 20 78 	mov  0x78, %o0                                 
  if (dd == NULL) {                                                   
40003b50:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003b54:	02 80 00 20 	be  40003bd4 <create_disk+0x188>               <== NEVER TAKEN
40003b58:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_NO_MEMORY;                                           
  }                                                                   
                                                                      
  if (name != NULL) {                                                 
40003b5c:	02 80 00 0b 	be  40003b88 <create_disk+0x13c>               
40003b60:	a4 10 20 00 	clr  %l2                                       
    alloc_name = strdup(name);                                        
40003b64:	40 00 43 af 	call  40014a20 <strdup>                        
40003b68:	90 10 00 1a 	mov  %i2, %o0                                  
                                                                      
    if (alloc_name == NULL) {                                         
40003b6c:	a4 92 20 00 	orcc  %o0, 0, %l2                              
40003b70:	12 80 00 0b 	bne  40003b9c <create_disk+0x150>              <== ALWAYS TAKEN
40003b74:	b4 10 00 08 	mov  %o0, %i2                                  
      free(dd);                                                       
40003b78:	40 00 03 8c 	call  400049a8 <free>                          <== NOT EXECUTED
40003b7c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  rtems_disk_device **dd_entry = create_disk_table_entry(dev);        
  rtems_disk_device *dd = NULL;                                       
  char *alloc_name = NULL;                                            
                                                                      
  if (dd_entry == NULL) {                                             
    return RTEMS_NO_MEMORY;                                           
40003b80:	10 80 00 16 	b  40003bd8 <create_disk+0x18c>                <== NOT EXECUTED
40003b84:	82 10 20 1a 	mov  0x1a, %g1                                 <== NOT EXECUTED
      free(dd);                                                       
      return RTEMS_UNSATISFIED;                                       
    }                                                                 
  }                                                                   
                                                                      
  *dd_entry = dd;                                                     
40003b88:	fa 24 40 10 	st  %i5, [ %l1 + %l0 ]                         
  *dd_ptr = dd;                                                       
40003b8c:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
  *alloc_name_ptr = alloc_name;                                       
40003b90:	e4 27 00 00 	st  %l2, [ %i4 ]                               
                                                                      
  return RTEMS_SUCCESSFUL;                                            
40003b94:	10 80 00 11 	b  40003bd8 <create_disk+0x18c>                
40003b98:	82 10 20 00 	clr  %g1                                       
      return RTEMS_NO_MEMORY;                                         
    }                                                                 
  }                                                                   
                                                                      
  if (name != NULL) {                                                 
    if (mknod(alloc_name, 0777 | S_IFBLK, dev) < 0) {                 
40003b9c:	13 00 00 18 	sethi  %hi(0x6000), %o1                        
40003ba0:	94 10 00 18 	mov  %i0, %o2                                  
40003ba4:	92 12 61 ff 	or  %o1, 0x1ff, %o1                            
40003ba8:	40 00 05 16 	call  40005000 <mknod>                         
40003bac:	96 10 00 19 	mov  %i1, %o3                                  
40003bb0:	80 a2 20 00 	cmp  %o0, 0                                    
40003bb4:	36 bf ff f6 	bge,a   40003b8c <create_disk+0x140>           <== ALWAYS TAKEN
40003bb8:	fa 24 40 10 	st  %i5, [ %l1 + %l0 ]                         
      free(alloc_name);                                               
40003bbc:	40 00 03 7b 	call  400049a8 <free>                          <== NOT EXECUTED
40003bc0:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
      free(dd);                                                       
40003bc4:	40 00 03 79 	call  400049a8 <free>                          <== NOT EXECUTED
40003bc8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      return RTEMS_UNSATISFIED;                                       
40003bcc:	10 80 00 03 	b  40003bd8 <create_disk+0x18c>                <== NOT EXECUTED
40003bd0:	82 10 20 0d 	mov  0xd, %g1                                  <== NOT EXECUTED
  rtems_disk_device **dd_entry = create_disk_table_entry(dev);        
  rtems_disk_device *dd = NULL;                                       
  char *alloc_name = NULL;                                            
                                                                      
  if (dd_entry == NULL) {                                             
    return RTEMS_NO_MEMORY;                                           
40003bd4:	82 10 20 1a 	mov  0x1a, %g1                                 
  *dd_entry = dd;                                                     
  *dd_ptr = dd;                                                       
  *alloc_name_ptr = alloc_name;                                       
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003bd8:	81 c7 e0 08 	ret                                            
40003bdc:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40003b4c <create_logical_disk_name>: #include <rtems.h> #include <rtems/bdpart.h> static char *create_logical_disk_name( const char *disk_name, char **marker) {
40003b4c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  size_t disk_name_size = strlen( disk_name);                         
40003b50:	40 00 4b d8 	call  40016ab0 <strlen>                        
40003b54:	90 10 00 18 	mov  %i0, %o0                                  
40003b58:	b8 10 00 08 	mov  %o0, %i4                                  
  char *logical_disk_name = malloc( disk_name_size + RTEMS_BDPART_NUMBER_SIZE);
40003b5c:	40 00 0b 76 	call  40006934 <malloc>                        
40003b60:	90 02 20 04 	add  %o0, 4, %o0                               
                                                                      
  if (logical_disk_name != NULL) {                                    
40003b64:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003b68:	02 80 00 06 	be  40003b80 <create_logical_disk_name+0x34>   <== NEVER TAKEN
40003b6c:	94 10 00 1c 	mov  %i4, %o2                                  
    strncpy( logical_disk_name, disk_name, disk_name_size);           
40003b70:	92 10 00 18 	mov  %i0, %o1                                  
40003b74:	40 00 4c 4d 	call  40016ca8 <strncpy>                       
40003b78:	b8 07 40 1c 	add  %i5, %i4, %i4                             
    *marker = logical_disk_name + disk_name_size;                     
40003b7c:	f8 26 40 00 	st  %i4, [ %i1 ]                               
  }                                                                   
                                                                      
  return logical_disk_name;                                           
}                                                                     
40003b80:	81 c7 e0 08 	ret                                            
40003b84:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

40005488 <data_to_part_desc.part.1>: * RTEMS_SUCCESSFUL, if success; * RTEMS_NO_MEMOTY, if cannot allocate memory for part_desc_t strucure; * RTEMS_INTERNAL_ERROR, if other error occurs. */ static rtems_status_code data_to_part_desc(uint8_t *data, rtems_part_desc_t **new_part_desc)
40005488:	9d e3 bf 98 	save  %sp, -104, %sp                           
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    *new_part_desc = NULL;                                            
                                                                      
    if ((part_desc = calloc(1, sizeof(rtems_part_desc_t))) == NULL)   
4000548c:	90 10 20 01 	mov  1, %o0                                    
 *      RTEMS_SUCCESSFUL, if success;                                 
 *      RTEMS_NO_MEMOTY, if cannot allocate memory for part_desc_t strucure;
 *      RTEMS_INTERNAL_ERROR, if other error occurs.                  
 */                                                                   
static rtems_status_code                                              
data_to_part_desc(uint8_t *data, rtems_part_desc_t **new_part_desc)   
40005490:	b8 10 00 18 	mov  %i0, %i4                                  
    if (new_part_desc == NULL)                                        
    {                                                                 
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    *new_part_desc = NULL;                                            
40005494:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
    if ((part_desc = calloc(1, sizeof(rtems_part_desc_t))) == NULL)   
40005498:	92 10 20 28 	mov  0x28, %o1                                 
4000549c:	40 00 03 76 	call  40006274 <calloc>                        
400054a0:	b0 10 20 1a 	mov  0x1a, %i0                                 
400054a4:	80 a2 20 00 	cmp  %o0, 0                                    
400054a8:	02 80 00 27 	be  40005544 <data_to_part_desc.part.1+0xbc>   <== NEVER TAKEN
400054ac:	ba 10 00 08 	mov  %o0, %i5                                  
    {                                                                 
        return RTEMS_NO_MEMORY;                                       
    }                                                                 
                                                                      
    part_desc->bootable = *(data + RTEMS_IDE_PARTITION_BOOTABLE_OFFSET);
400054b0:	c2 0f 00 00 	ldub  [ %i4 ], %g1                             
    part_desc->sys_type = *(data + RTEMS_IDE_PARTITION_SYS_TYPE_OFFSET);
                                                                      
    /* read the offset start position and partition size in sectors */
                                                                      
    /* due to incorrect data alignment one have to align data first */
    memcpy(&temp, data + RTEMS_IDE_PARTITION_START_OFFSET, sizeof(uint32_t));
400054b4:	92 07 20 08 	add  %i4, 8, %o1                               
    if ((part_desc = calloc(1, sizeof(rtems_part_desc_t))) == NULL)   
    {                                                                 
        return RTEMS_NO_MEMORY;                                       
    }                                                                 
                                                                      
    part_desc->bootable = *(data + RTEMS_IDE_PARTITION_BOOTABLE_OFFSET);
400054b8:	c2 2a 00 00 	stb  %g1, [ %o0 ]                              
    part_desc->sys_type = *(data + RTEMS_IDE_PARTITION_SYS_TYPE_OFFSET);
400054bc:	f6 0f 20 04 	ldub  [ %i4 + 4 ], %i3                         
                                                                      
    /* read the offset start position and partition size in sectors */
                                                                      
    /* due to incorrect data alignment one have to align data first */
    memcpy(&temp, data + RTEMS_IDE_PARTITION_START_OFFSET, sizeof(uint32_t));
400054c0:	94 10 20 04 	mov  4, %o2                                    
    {                                                                 
        return RTEMS_NO_MEMORY;                                       
    }                                                                 
                                                                      
    part_desc->bootable = *(data + RTEMS_IDE_PARTITION_BOOTABLE_OFFSET);
    part_desc->sys_type = *(data + RTEMS_IDE_PARTITION_SYS_TYPE_OFFSET);
400054c4:	f6 2a 20 01 	stb  %i3, [ %o0 + 1 ]                          
                                                                      
    /* read the offset start position and partition size in sectors */
                                                                      
    /* due to incorrect data alignment one have to align data first */
    memcpy(&temp, data + RTEMS_IDE_PARTITION_START_OFFSET, sizeof(uint32_t));
400054c8:	40 00 43 67 	call  40016264 <memcpy>                        
400054cc:	90 07 bf fc 	add  %fp, -4, %o0                              
    part_desc->start = LE_TO_CPU_U32(temp);                           
400054d0:	7f ff ff ac 	call  40005380 <CPU_swap_u32>                  
400054d4:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
                                                                      
    memcpy(&temp, data + RTEMS_IDE_PARTITION_SIZE_OFFSET, sizeof(uint32_t));
400054d8:	92 07 20 0c 	add  %i4, 0xc, %o1                             
                                                                      
    /* read the offset start position and partition size in sectors */
                                                                      
    /* due to incorrect data alignment one have to align data first */
    memcpy(&temp, data + RTEMS_IDE_PARTITION_START_OFFSET, sizeof(uint32_t));
    part_desc->start = LE_TO_CPU_U32(temp);                           
400054dc:	d0 27 60 04 	st  %o0, [ %i5 + 4 ]                           
                                                                      
    memcpy(&temp, data + RTEMS_IDE_PARTITION_SIZE_OFFSET, sizeof(uint32_t));
400054e0:	94 10 20 04 	mov  4, %o2                                    
400054e4:	40 00 43 60 	call  40016264 <memcpy>                        
400054e8:	90 07 bf fc 	add  %fp, -4, %o0                              
    part_desc->size = LE_TO_CPU_U32(temp);                            
400054ec:	7f ff ff a5 	call  40005380 <CPU_swap_u32>                  
400054f0:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
400054f4:	d0 27 60 08 	st  %o0, [ %i5 + 8 ]                           
     * use partitions that are                                        
     * - extended                                                     
     * or                                                             
     * - FAT type and non-zero                                        
     */                                                               
    if (is_extended(part_desc->sys_type) ||                           
400054f8:	82 0e e0 7f 	and  %i3, 0x7f, %g1                            
400054fc:	80 a0 60 05 	cmp  %g1, 5                                    
40005500:	02 80 00 0c 	be  40005530 <data_to_part_desc.part.1+0xa8>   
40005504:	b8 10 00 08 	mov  %o0, %i4                                  
    DOS_P32MB_PARTITION,                                              
    FAT32_PARTITION    ,FAT32_LBA_PARTITION,                          
    FAT16_LBA_PARTITION                                               
  };                                                                  
                                                                      
  return (NULL != memchr(fat_part_types,type,sizeof(fat_part_types)));
40005508:	11 10 00 98 	sethi  %hi(0x40026000), %o0                    
4000550c:	92 0e e0 ff 	and  %i3, 0xff, %o1                            
40005510:	90 12 22 b8 	or  %o0, 0x2b8, %o0                            
40005514:	40 00 42 e5 	call  400160a8 <memchr>                        
40005518:	94 10 20 06 	mov  6, %o2                                    
     * use partitions that are                                        
     * - extended                                                     
     * or                                                             
     * - FAT type and non-zero                                        
     */                                                               
    if (is_extended(part_desc->sys_type) ||                           
4000551c:	80 a2 20 00 	cmp  %o0, 0                                    
40005520:	02 80 00 06 	be  40005538 <data_to_part_desc.part.1+0xb0>   
40005524:	80 a7 20 00 	cmp  %i4, 0                                    
       ((is_fat_partition(part_desc->sys_type)) && (part_desc->size != 0))) {
40005528:	02 80 00 04 	be  40005538 <data_to_part_desc.part.1+0xb0>   <== NEVER TAKEN
4000552c:	01 00 00 00 	nop                                            
      *new_part_desc = part_desc;                                     
40005530:	10 80 00 04 	b  40005540 <data_to_part_desc.part.1+0xb8>    
40005534:	fa 26 40 00 	st  %i5, [ %i1 ]                               
    }                                                                 
    else {                                                            
      /* empty partition */                                           
      free(part_desc);                                                
40005538:	40 00 03 87 	call  40006354 <free>                          
4000553c:	90 10 00 1d 	mov  %i5, %o0                                  
    }                                                                 
    return RTEMS_SUCCESSFUL;                                          
40005540:	b0 10 20 00 	clr  %i0                                       
}                                                                     
40005544:	81 c7 e0 08 	ret                                            
40005548:	81 e8 00 00 	restore                                        
                                                                      

40002ed0 <devFS_Show>: #endif #include "devfs.h" void devFS_Show(void) {
40002ed0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_filesystem_location_info_t *rootloc = &rtems_filesystem_root->location;
40002ed4:	40 00 03 6e 	call  40003c8c <rtems_current_user_env_get>    
40002ed8:	01 00 00 00 	nop                                            
                                                                      
  if (rootloc->mt_entry->ops == &devFS_ops) {                         
40002edc:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           
40002ee0:	05 10 00 4b 	sethi  %hi(0x40012c00), %g2                    
40002ee4:	c2 00 60 14 	ld  [ %g1 + 0x14 ], %g1                        
40002ee8:	84 10 a3 ec 	or  %g2, 0x3ec, %g2                            
40002eec:	c6 00 60 0c 	ld  [ %g1 + 0xc ], %g3                         
40002ef0:	80 a0 c0 02 	cmp  %g3, %g2                                  
40002ef4:	12 80 00 26 	bne  40002f8c <devFS_Show+0xbc>                <== NEVER TAKEN
40002ef8:	33 10 00 4c 	sethi  %hi(0x40013000), %i1                    
 */                                                                   
static inline const devFS_data *devFS_get_data(                       
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  return (const devFS_data *) loc->mt_entry->immutable_fs_info;       
40002efc:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
    const devFS_data *data = devFS_get_data(rootloc);                 
    size_t i = 0;                                                     
    size_t n = data->count;                                           
40002f00:	f4 00 60 04 	ld  [ %g1 + 4 ], %i2                           
40002f04:	fa 00 40 00 	ld  [ %g1 ], %i5                               
        size_t j = 0;                                                 
        size_t m = current->namelen;                                  
                                                                      
        printk("/");                                                  
        for (j = 0; j < m; ++j) {                                     
          printk("%c", current->name [j]);                            
40002f08:	31 10 00 4c 	sethi  %hi(0x40013000), %i0                    
        }                                                             
        printk(                                                       
40002f0c:	21 10 00 4c 	sethi  %hi(0x40013000), %l0                    
    const devFS_data *data = devFS_get_data(rootloc);                 
    size_t i = 0;                                                     
    size_t n = data->count;                                           
    devFS_node *nodes = data->nodes;                                  
                                                                      
    for (i = 0; i < n; ++i) {                                         
40002f10:	b6 10 20 00 	clr  %i3                                       
                                                                      
      if (current->name != NULL) {                                    
        size_t j = 0;                                                 
        size_t m = current->namelen;                                  
                                                                      
        printk("/");                                                  
40002f14:	b2 16 60 40 	or  %i1, 0x40, %i1                             
        for (j = 0; j < m; ++j) {                                     
          printk("%c", current->name [j]);                            
40002f18:	b0 16 20 48 	or  %i0, 0x48, %i0                             
        }                                                             
        printk(                                                       
40002f1c:	a0 14 20 50 	or  %l0, 0x50, %l0                             
    const devFS_data *data = devFS_get_data(rootloc);                 
    size_t i = 0;                                                     
    size_t n = data->count;                                           
    devFS_node *nodes = data->nodes;                                  
                                                                      
    for (i = 0; i < n; ++i) {                                         
40002f20:	80 a6 c0 1a 	cmp  %i3, %i2                                  
40002f24:	02 80 00 1a 	be  40002f8c <devFS_Show+0xbc>                 
40002f28:	01 00 00 00 	nop                                            
      devFS_node *current = nodes + i;                                
                                                                      
      if (current->name != NULL) {                                    
40002f2c:	c2 07 40 00 	ld  [ %i5 ], %g1                               
40002f30:	80 a0 60 00 	cmp  %g1, 0                                    
40002f34:	22 80 00 14 	be,a   40002f84 <devFS_Show+0xb4>              
40002f38:	b6 06 e0 01 	inc  %i3                                       
        size_t j = 0;                                                 
        size_t m = current->namelen;                                  
40002f3c:	e2 07 60 04 	ld  [ %i5 + 4 ], %l1                           
                                                                      
        printk("/");                                                  
40002f40:	90 10 00 19 	mov  %i1, %o0                                  
40002f44:	40 00 03 46 	call  40003c5c <printk>                        
40002f48:	b8 10 20 00 	clr  %i4                                       
        for (j = 0; j < m; ++j) {                                     
40002f4c:	80 a7 00 11 	cmp  %i4, %l1                                  
40002f50:	02 80 00 08 	be  40002f70 <devFS_Show+0xa0>                 
40002f54:	90 10 00 18 	mov  %i0, %o0                                  
          printk("%c", current->name [j]);                            
40002f58:	c2 07 40 00 	ld  [ %i5 ], %g1                               
40002f5c:	d2 48 40 1c 	ldsb  [ %g1 + %i4 ], %o1                       
40002f60:	40 00 03 3f 	call  40003c5c <printk>                        
40002f64:	b8 07 20 01 	inc  %i4                                       
      if (current->name != NULL) {                                    
        size_t j = 0;                                                 
        size_t m = current->namelen;                                  
                                                                      
        printk("/");                                                  
        for (j = 0; j < m; ++j) {                                     
40002f68:	10 bf ff fa 	b  40002f50 <devFS_Show+0x80>                  
40002f6c:	80 a7 00 11 	cmp  %i4, %l1                                  
          printk("%c", current->name [j]);                            
        }                                                             
        printk(                                                       
40002f70:	d2 07 60 08 	ld  [ %i5 + 8 ], %o1                           
40002f74:	d4 07 60 0c 	ld  [ %i5 + 0xc ], %o2                         
40002f78:	40 00 03 39 	call  40003c5c <printk>                        
40002f7c:	90 10 00 10 	mov  %l0, %o0                                  
    const devFS_data *data = devFS_get_data(rootloc);                 
    size_t i = 0;                                                     
    size_t n = data->count;                                           
    devFS_node *nodes = data->nodes;                                  
                                                                      
    for (i = 0; i < n; ++i) {                                         
40002f80:	b6 06 e0 01 	inc  %i3                                       
40002f84:	10 bf ff e7 	b  40002f20 <devFS_Show+0x50>                  
40002f88:	ba 07 60 14 	add  %i5, 0x14, %i5                            
40002f8c:	81 c7 e0 08 	ret                                            
40002f90:	81 e8 00 00 	restore                                        
                                                                      

4000cca4 <devFS_eval_path>: } void devFS_eval_path( rtems_filesystem_eval_path_context_t *ctx ) {
4000cca4:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
static inline const devFS_data *devFS_get_data(                       
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  return (const devFS_data *) loc->mt_entry->immutable_fs_info;       
4000cca8:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
                                                                      
  return node;                                                        
}                                                                     
                                                                      
void devFS_eval_path(                                                 
  rtems_filesystem_eval_path_context_t *ctx                           
4000ccac:	e0 06 00 00 	ld  [ %i0 ], %l0                               
4000ccb0:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
4000ccb4:	f4 06 20 04 	ld  [ %i0 + 4 ], %i2                           
  size_t pathlen,                                                     
  devFS_node **free_node_ptr                                          
)                                                                     
{                                                                     
  size_t i = 0;                                                       
  size_t n = data->count;                                             
4000ccb8:	e2 00 60 04 	ld  [ %g1 + 4 ], %l1                           
4000ccbc:	fa 00 40 00 	ld  [ %g1 ], %i5                               
  devFS_node *nodes = data->nodes;                                    
  devFS_node *node = NULL;                                            
  devFS_node *free_node = NULL;                                       
4000ccc0:	b8 10 20 00 	clr  %i4                                       
)                                                                     
{                                                                     
  size_t i = 0;                                                       
  size_t n = data->count;                                             
  devFS_node *nodes = data->nodes;                                    
  devFS_node *node = NULL;                                            
4000ccc4:	b6 10 20 00 	clr  %i3                                       
  devFS_node *free_node = NULL;                                       
                                                                      
  for (i = 0; (free_node == NULL || node == NULL) && i < n; ++i) {    
4000ccc8:	b2 10 20 00 	clr  %i1                                       
4000cccc:	80 a6 e0 00 	cmp  %i3, 0                                    
4000ccd0:	02 80 00 0a 	be  4000ccf8 <devFS_eval_path+0x54>            
4000ccd4:	80 a6 40 11 	cmp  %i1, %l1                                  
4000ccd8:	80 a7 20 00 	cmp  %i4, 0                                    
4000ccdc:	02 80 00 07 	be  4000ccf8 <devFS_eval_path+0x54>            <== NEVER TAKEN
4000cce0:	80 a6 40 11 	cmp  %i1, %l1                                  
    rtems_filesystem_eval_path_get_pathlen(ctx),                      
    &free_node                                                        
  );                                                                  
  int eval_flags = rtems_filesystem_eval_path_get_flags(ctx);         
                                                                      
  if (node != NULL) {                                                 
4000cce4:	80 a6 e0 00 	cmp  %i3, 0                                    
4000cce8:	12 80 00 19 	bne  4000cd4c <devFS_eval_path+0xa8>           
4000ccec:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
      rtems_filesystem_eval_path_clear_path(ctx);                     
    } else {                                                          
      rtems_filesystem_eval_path_error(ctx, EEXIST);                  
    }                                                                 
  } else {                                                            
    if ((eval_flags & RTEMS_FS_MAKE) != 0) {                          
4000ccf0:	10 80 00 1c 	b  4000cd60 <devFS_eval_path+0xbc>             
4000ccf4:	80 88 60 20 	btst  0x20, %g1                                
  size_t n = data->count;                                             
  devFS_node *nodes = data->nodes;                                    
  devFS_node *node = NULL;                                            
  devFS_node *free_node = NULL;                                       
                                                                      
  for (i = 0; (free_node == NULL || node == NULL) && i < n; ++i) {    
4000ccf8:	02 bf ff fc 	be  4000cce8 <devFS_eval_path+0x44>            
4000ccfc:	80 a6 e0 00 	cmp  %i3, 0                                    
    devFS_node *current = nodes + i;                                  
                                                                      
    if (current->name != NULL) {                                      
4000cd00:	d0 07 40 00 	ld  [ %i5 ], %o0                               
4000cd04:	80 a2 20 00 	cmp  %o0, 0                                    
4000cd08:	22 80 00 0e 	be,a   4000cd40 <devFS_eval_path+0x9c>         
4000cd0c:	b8 10 00 1d 	mov  %i5, %i4                                  
      if (                                                            
4000cd10:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
4000cd14:	80 a0 40 1a 	cmp  %g1, %i2                                  
4000cd18:	32 80 00 0b 	bne,a   4000cd44 <devFS_eval_path+0xa0>        
4000cd1c:	b2 06 60 01 	inc  %i1                                       
        current->namelen == pathlen                                   
          && memcmp(current->name, path, pathlen) == 0                
4000cd20:	92 10 00 10 	mov  %l0, %o1                                  
4000cd24:	40 00 09 d1 	call  4000f468 <memcmp>                        
4000cd28:	94 10 00 1a 	mov  %i2, %o2                                  
4000cd2c:	80 a2 20 00 	cmp  %o0, 0                                    
4000cd30:	22 80 00 04 	be,a   4000cd40 <devFS_eval_path+0x9c>         
4000cd34:	b6 10 00 1d 	mov  %i5, %i3                                  
  size_t n = data->count;                                             
  devFS_node *nodes = data->nodes;                                    
  devFS_node *node = NULL;                                            
  devFS_node *free_node = NULL;                                       
                                                                      
  for (i = 0; (free_node == NULL || node == NULL) && i < n; ++i) {    
4000cd38:	10 80 00 03 	b  4000cd44 <devFS_eval_path+0xa0>             
4000cd3c:	b2 06 60 01 	inc  %i1                                       
4000cd40:	b2 06 60 01 	inc  %i1                                       
4000cd44:	10 bf ff e2 	b  4000cccc <devFS_eval_path+0x28>             
4000cd48:	ba 07 60 14 	add  %i5, 0x14, %i5                            
    &free_node                                                        
  );                                                                  
  int eval_flags = rtems_filesystem_eval_path_get_flags(ctx);         
                                                                      
  if (node != NULL) {                                                 
    if ((eval_flags & RTEMS_FS_EXCLUSIVE) == 0) {                     
4000cd4c:	80 88 60 40 	btst  0x40, %g1                                
4000cd50:	12 80 00 12 	bne  4000cd98 <devFS_eval_path+0xf4>           
4000cd54:	b2 10 20 11 	mov  0x11, %i1                                 
      currentloc->node_access = node;                                 
4000cd58:	10 80 00 0a 	b  4000cd80 <devFS_eval_path+0xdc>             
4000cd5c:	f6 26 20 20 	st  %i3, [ %i0 + 0x20 ]                        
      rtems_filesystem_eval_path_clear_path(ctx);                     
    } else {                                                          
      rtems_filesystem_eval_path_error(ctx, EEXIST);                  
    }                                                                 
  } else {                                                            
    if ((eval_flags & RTEMS_FS_MAKE) != 0) {                          
4000cd60:	02 80 00 0d 	be  4000cd94 <devFS_eval_path+0xf0>            <== NEVER TAKEN
4000cd64:	80 a7 20 00 	cmp  %i4, 0                                    
      if (free_node != NULL) {                                        
4000cd68:	02 80 00 09 	be  4000cd8c <devFS_eval_path+0xe8>            
4000cd6c:	82 10 21 ff 	mov  0x1ff, %g1                                
        free_node->mode = S_IRWXU | S_IRWXG | S_IRWXO;                
4000cd70:	c2 27 20 10 	st  %g1, [ %i4 + 0x10 ]                        
        currentloc->node_access = free_node;                          
4000cd74:	f8 26 20 20 	st  %i4, [ %i0 + 0x20 ]                        
  rtems_filesystem_eval_path_context_t *ctx,                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  ctx->token = token;                                                 
4000cd78:	e0 26 20 08 	st  %l0, [ %i0 + 8 ]                           
  ctx->tokenlen = tokenlen;                                           
4000cd7c:	f4 26 20 0c 	st  %i2, [ %i0 + 0xc ]                         
                                                                      
static inline void rtems_filesystem_eval_path_clear_path(             
  rtems_filesystem_eval_path_context_t *ctx                           
)                                                                     
{                                                                     
  ctx->pathlen = 0;                                                   
4000cd80:	c0 26 20 04 	clr  [ %i0 + 4 ]                               
4000cd84:	81 c7 e0 08 	ret                                            
4000cd88:	81 e8 00 00 	restore                                        
          rtems_filesystem_eval_path_get_path(ctx),                   
          rtems_filesystem_eval_path_get_pathlen(ctx)                 
        );                                                            
        rtems_filesystem_eval_path_clear_path(ctx);                   
      } else {                                                        
        rtems_filesystem_eval_path_error(ctx, ENOSPC);                
4000cd8c:	10 80 00 03 	b  4000cd98 <devFS_eval_path+0xf4>             
4000cd90:	b2 10 20 1c 	mov  0x1c, %i1                                 
      }                                                               
    } else {                                                          
      rtems_filesystem_eval_path_error(ctx, ENOENT);                  
4000cd94:	b2 10 20 02 	mov  2, %i1                                    <== NOT EXECUTED
4000cd98:	7f ff e3 09 	call  400059bc <rtems_filesystem_eval_path_error>
4000cd9c:	81 e8 00 00 	restore                                        
                                                                      

400048f8 <devFS_mknod>: const char *name, size_t namelen, mode_t mode, dev_t dev ) {
400048f8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
                                                                      
  if (namelen != 3 || name [0] != 'd' || name [1] != 'e' || name [2] != 'v') {
400048fc:	80 a6 a0 03 	cmp  %i2, 3                                    
40004900:	12 80 00 0e 	bne  40004938 <devFS_mknod+0x40>               
40004904:	05 00 00 2c 	sethi  %hi(0xb000), %g2                        
40004908:	c2 4e 40 00 	ldsb  [ %i1 ], %g1                             
4000490c:	80 a0 60 64 	cmp  %g1, 0x64                                 
40004910:	12 80 00 0b 	bne  4000493c <devFS_mknod+0x44>               <== NEVER TAKEN
40004914:	03 00 00 08 	sethi  %hi(0x2000), %g1                        
40004918:	c2 4e 60 01 	ldsb  [ %i1 + 1 ], %g1                         
4000491c:	80 a0 60 65 	cmp  %g1, 0x65                                 
40004920:	12 80 00 07 	bne  4000493c <devFS_mknod+0x44>               <== NEVER TAKEN
40004924:	03 00 00 08 	sethi  %hi(0x2000), %g1                        
40004928:	c2 4e 60 02 	ldsb  [ %i1 + 2 ], %g1                         
4000492c:	80 a0 60 76 	cmp  %g1, 0x76                                 
40004930:	02 80 00 1a 	be  40004998 <devFS_mknod+0xa0>                <== ALWAYS TAKEN
40004934:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
    if (S_ISBLK(mode) || S_ISCHR(mode)) {                             
40004938:	03 00 00 08 	sethi  %hi(0x2000), %g1                        
4000493c:	84 0e c0 02 	and  %i3, %g2, %g2                             
40004940:	80 a0 80 01 	cmp  %g2, %g1                                  
40004944:	12 80 00 1a 	bne  400049ac <devFS_mknod+0xb4>               
40004948:	01 00 00 00 	nop                                            
      char *dupname = malloc(namelen);                                
4000494c:	40 00 01 32 	call  40004e14 <malloc>                        
40004950:	90 10 00 1a 	mov  %i2, %o0                                  
                                                                      
      if (dupname != NULL) {                                          
40004954:	84 92 20 00 	orcc  %o0, 0, %g2                              
40004958:	02 80 00 0c 	be  40004988 <devFS_mknod+0x90>                
4000495c:	92 10 00 19 	mov  %i1, %o1                                  
        devFS_node *node = parentloc->node_access;                    
40004960:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
                                                                      
        node->name = dupname;                                         
40004964:	c4 20 40 00 	st  %g2, [ %g1 ]                               
        node->namelen = namelen;                                      
40004968:	f4 20 60 04 	st  %i2, [ %g1 + 4 ]                           
        node->major = rtems_filesystem_dev_major_t(dev);              
4000496c:	f8 20 60 08 	st  %i4, [ %g1 + 8 ]                           
        node->minor = rtems_filesystem_dev_minor_t(dev);              
40004970:	fa 20 60 0c 	st  %i5, [ %g1 + 0xc ]                         
        node->mode = mode;                                            
40004974:	f6 20 60 10 	st  %i3, [ %g1 + 0x10 ]                        
        memcpy(dupname, name, namelen);                               
40004978:	40 00 2a e6 	call  4000f510 <memcpy>                        
4000497c:	94 10 00 1a 	mov  %i2, %o2                                  
  size_t namelen,                                                     
  mode_t mode,                                                        
  dev_t dev                                                           
)                                                                     
{                                                                     
  int rv = 0;                                                         
40004980:	81 c7 e0 08 	ret                                            
40004984:	91 e8 20 00 	restore  %g0, 0, %o0                           
        node->major = rtems_filesystem_dev_major_t(dev);              
        node->minor = rtems_filesystem_dev_minor_t(dev);              
        node->mode = mode;                                            
        memcpy(dupname, name, namelen);                               
      } else {                                                        
        errno = ENOMEM;                                               
40004988:	40 00 2a 8a 	call  4000f3b0 <__errno>                       
4000498c:	01 00 00 00 	nop                                            
40004990:	10 80 00 0a 	b  400049b8 <devFS_mknod+0xc0>                 
40004994:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         
    } else {                                                          
      errno = ENOTSUP;                                                
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    if (!S_ISDIR(mode)) {                                             
40004998:	b6 0e c0 01 	and  %i3, %g1, %i3                             
4000499c:	03 00 00 10 	sethi  %hi(0x4000), %g1                        
400049a0:	80 a6 c0 01 	cmp  %i3, %g1                                  
400049a4:	22 80 00 07 	be,a   400049c0 <devFS_mknod+0xc8>             <== ALWAYS TAKEN
400049a8:	b0 10 20 00 	clr  %i0                                       
      } else {                                                        
        errno = ENOMEM;                                               
        rv = -1;                                                      
      }                                                               
    } else {                                                          
      errno = ENOTSUP;                                                
400049ac:	40 00 2a 81 	call  4000f3b0 <__errno>                       
400049b0:	01 00 00 00 	nop                                            
400049b4:	82 10 20 86 	mov  0x86, %g1	! 86 <_TLS_Alignment+0x85>      
400049b8:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400049bc:	b0 10 3f ff 	mov  -1, %i0                                   
      rv = -1;                                                        
    }                                                                 
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
400049c0:	81 c7 e0 08 	ret                                            
400049c4:	81 e8 00 00 	restore                                        
                                                                      

40003a10 <disk_lock>: static rtems_interrupt_lock diskdevs_lock = RTEMS_INTERRUPT_LOCK_INITIALIZER("diskdevs"); static rtems_status_code disk_lock(void) {
40003a10:	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);
40003a14:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003a18:	d0 00 62 7c 	ld  [ %g1 + 0x27c ], %o0	! 4001c27c <diskdevs_mutex>
40003a1c:	92 10 20 00 	clr  %o1                                       
40003a20:	94 10 20 00 	clr  %o2                                       
40003a24:	40 00 14 57 	call  40008b80 <rtems_semaphore_obtain>        
40003a28:	b0 10 20 16 	mov  0x16, %i0                                 
  if (sc == RTEMS_SUCCESSFUL) {                                       
40003a2c:	80 a2 20 00 	cmp  %o0, 0                                    
40003a30:	12 80 00 05 	bne  40003a44 <disk_lock+0x34>                 <== NEVER TAKEN
40003a34:	84 10 20 01 	mov  1, %g2                                    
    diskdevs_protected = true;                                        
40003a38:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
                                                                      
    return RTEMS_SUCCESSFUL;                                          
40003a3c:	b0 10 20 00 	clr  %i0                                       
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  sc = rtems_semaphore_obtain(diskdevs_mutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
  if (sc == RTEMS_SUCCESSFUL) {                                       
    diskdevs_protected = true;                                        
40003a40:	c4 28 62 78 	stb  %g2, [ %g1 + 0x278 ]                      
                                                                      
    return RTEMS_SUCCESSFUL;                                          
  } else {                                                            
    return RTEMS_NOT_CONFIGURED;                                      
  }                                                                   
}                                                                     
40003a44:	81 c7 e0 08 	ret                                            
40003a48:	81 e8 00 00 	restore                                        
                                                                      

40003be0 <disk_unlock>: } } static void disk_unlock(void) {
40003be0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  diskdevs_protected = false;                                         
40003be4:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003be8:	c0 28 62 78 	clrb  [ %g1 + 0x278 ]	! 4001c278 <diskdevs_protected>
                                                                      
  sc = rtems_semaphore_release(diskdevs_mutex);                       
40003bec:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003bf0:	40 00 14 2c 	call  40008ca0 <rtems_semaphore_release>       
40003bf4:	d0 00 62 7c 	ld  [ %g1 + 0x27c ], %o0	! 4001c27c <diskdevs_mutex>
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003bf8:	80 a2 20 00 	cmp  %o0, 0                                    
40003bfc:	02 80 00 04 	be  40003c0c <disk_unlock+0x2c>                <== ALWAYS TAKEN
40003c00:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
    /* FIXME: Error number */                                         
    rtems_fatal_error_occurred(0xdeadbeef);                           
40003c04:	40 00 15 87 	call  40009220 <rtems_fatal_error_occurred>    <== NOT EXECUTED
40003c08:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
40003c0c:	81 c7 e0 08 	ret                                            
40003c10:	81 e8 00 00 	restore                                        
                                                                      

40004f58 <drainOutput.part.4>: /* * Drain output queue */ static void drainOutput (struct rtems_termios_tty *tty)
40004f58:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code sc;                                               
                                                                      
  if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {           
    rtems_termios_interrupt_lock_acquire (tty, &lock_context);        
    while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) {              
      tty->rawOutBufState = rob_wait;                                 
40004f5c:	ba 10 20 02 	mov  2, %i5                                    
{                                                                     
  rtems_interrupt_lock_context lock_context;                          
  rtems_status_code sc;                                               
                                                                      
  if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {           
    rtems_termios_interrupt_lock_acquire (tty, &lock_context);        
40004f60:	7f ff ff 5d 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
40004f64:	90 07 bf fc 	add  %fp, -4, %o0                              
    while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) {              
40004f68:	c4 06 20 84 	ld  [ %i0 + 0x84 ], %g2                        
40004f6c:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        
40004f70:	80 a0 80 01 	cmp  %g2, %g1                                  
40004f74:	02 80 00 0d 	be  40004fa8 <drainOutput.part.4+0x50>         <== ALWAYS TAKEN
40004f78:	90 07 bf fc 	add  %fp, -4, %o0                              
      tty->rawOutBufState = rob_wait;                                 
      rtems_termios_interrupt_lock_release (tty, &lock_context);      
40004f7c:	7f ff ff 5c 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3><== NOT EXECUTED
40004f80:	fa 26 20 94 	st  %i5, [ %i0 + 0x94 ]                        <== NOT EXECUTED
      sc = rtems_semaphore_obtain(                                    
40004f84:	d0 06 20 8c 	ld  [ %i0 + 0x8c ], %o0                        <== NOT EXECUTED
40004f88:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
40004f8c:	40 00 09 b5 	call  40007660 <rtems_semaphore_obtain>        <== NOT EXECUTED
40004f90:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
        tty->rawOutBuf.Semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT);      
      if (sc != RTEMS_SUCCESSFUL)                                     
40004f94:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40004f98:	02 bf ff f2 	be  40004f60 <drainOutput.part.4+0x8>          <== NOT EXECUTED
40004f9c:	01 00 00 00 	nop                                            <== NOT EXECUTED
        rtems_fatal_error_occurred (sc);                              
40004fa0:	40 00 0b 79 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
40004fa4:	01 00 00 00 	nop                                            <== NOT EXECUTED
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
    }                                                                 
    rtems_termios_interrupt_lock_release (tty, &lock_context);        
40004fa8:	7f ff ff 51 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
40004fac:	90 07 bf fc 	add  %fp, -4, %o0                              
40004fb0:	81 c7 e0 08 	ret                                            
40004fb4:	81 e8 00 00 	restore                                        
                                                                      

40004004 <dup>: int dup( int fildes ) { return fcntl( fildes, F_DUPFD, 0 );
40004004:	92 10 20 00 	clr  %o1                                       
40004008:	94 10 20 00 	clr  %o2                                       
4000400c:	82 13 c0 00 	mov  %o7, %g1                                  
40004010:	40 00 00 17 	call  4000406c <fcntl>                         
40004014:	9e 10 40 00 	mov  %g1, %o7                                  
40004018:	40 00 40 e0 	call  40014398 <__call_exitprocs+0x144>        <== NOT EXECUTED
4000401c:	40 00 42 a4 	call  40014aac <__sfvwrite_r+0x48c>            <== NOT EXECUTED
40004020:	40 00 42 b0 	call  40014ae0 <__sfvwrite_r+0x4c0>            <== NOT EXECUTED
40004024:	40 00 42 c8 	call  40014b44 <_setlocale_r+0x38>             <== NOT EXECUTED
40004028:	40 00 42 d8 	call  40014b88 <__locale_charset+0x4>          <== NOT EXECUTED
4000402c:	40 00 42 fc 	call  40014c1c <memchr+0x30>                   <== NOT EXECUTED
40004030:	40 00 42 fc 	call  40014c20 <memchr+0x34>                   <== NOT EXECUTED
40004034:	40 00 42 fc 	call  40014c24 <memchr+0x38>                   <== NOT EXECUTED
40004038:	40 00 42 fc 	call  40014c28 <memchr+0x3c>                   <== NOT EXECUTED
4000403c:	40 00 42 fc 	call  40014c2c <memchr+0x40>                   <== NOT EXECUTED
40004040:	40 00 43 0c 	call  40014c70 <memchr+0x84>                   <== NOT EXECUTED
40004044:	40 00 43 0c 	call  40014c74 <memchr+0x88>                   <== NOT EXECUTED
40004048:	40 00 43 0c 	call  40014c78 <memchr+0x8c>                   <== NOT EXECUTED
4000404c:	40 00 43 0c 	call  40014c7c <memchr+0x90>                   <== NOT EXECUTED
40004050:	40 00 43 0c 	call  40014c80 <memchr+0x94>                   <== NOT EXECUTED
40004054:	40 00 43 0c 	call  40014c84 <memchr+0x98>                   <== NOT EXECUTED
40004058:	40 00 43 0c 	call  40014c88 <memchr+0x9c>                   <== NOT EXECUTED
4000405c:	40 00 43 0c 	call  40014c8c <memchr+0xa0>                   <== NOT EXECUTED
40004060:	40 00 43 0c 	call  40014c90 <memchr+0xa4>                   <== NOT EXECUTED
40004064:	40 00 43 0c 	call  40014c94 <memchr+0xa8>                   <== NOT EXECUTED
40004068:	40 00 41 bc 	call  40014758 <__sfvwrite_r+0x138>            <== NOT EXECUTED
                                                                      

40005cd8 <echo>: /* * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) {
40005cd8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  if ((tty->termios.c_lflag & ECHOCTL) &&                             
40005cdc:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
40005ce0:	80 88 62 00 	btst  0x200, %g1                               
40005ce4:	02 80 00 19 	be  40005d48 <echo+0x70>                       <== NEVER TAKEN
40005ce8:	03 10 00 5b 	sethi  %hi(0x40016c00), %g1                    
       iscntrl(c) && (c != '\t') && (c != '\n')) {                    
40005cec:	c2 00 61 0c 	ld  [ %g1 + 0x10c ], %g1	! 40016d0c <__ctype_ptr__>
40005cf0:	82 00 40 18 	add  %g1, %i0, %g1                             
40005cf4:	c2 08 60 01 	ldub  [ %g1 + 1 ], %g1                         
 * Echo a typed character                                             
 */                                                                   
static void                                                           
echo (unsigned char c, struct rtems_termios_tty *tty)                 
{                                                                     
  if ((tty->termios.c_lflag & ECHOCTL) &&                             
40005cf8:	80 88 60 20 	btst  0x20, %g1                                
40005cfc:	02 80 00 14 	be  40005d4c <echo+0x74>                       
40005d00:	90 10 00 18 	mov  %i0, %o0                                  
       iscntrl(c) && (c != '\t') && (c != '\n')) {                    
40005d04:	82 06 3f f7 	add  %i0, -9, %g1                              
40005d08:	82 08 60 ff 	and  %g1, 0xff, %g1                            
40005d0c:	80 a0 60 01 	cmp  %g1, 1                                    
40005d10:	08 80 00 0f 	bleu  40005d4c <echo+0x74>                     
40005d14:	82 10 20 5e 	mov  0x5e, %g1                                 
    char echobuf[2];                                                  
                                                                      
    echobuf[0] = '^';                                                 
    echobuf[1] = c ^ 0x40;                                            
40005d18:	b0 1e 20 40 	xor  %i0, 0x40, %i0                            
{                                                                     
  if ((tty->termios.c_lflag & ECHOCTL) &&                             
       iscntrl(c) && (c != '\t') && (c != '\n')) {                    
    char echobuf[2];                                                  
                                                                      
    echobuf[0] = '^';                                                 
40005d1c:	c2 2f bf f8 	stb  %g1, [ %fp + -8 ]                         
    echobuf[1] = c ^ 0x40;                                            
40005d20:	f0 2f bf f9 	stb  %i0, [ %fp + -7 ]                         
    rtems_termios_puts (echobuf, 2, tty);                             
40005d24:	90 07 bf f8 	add  %fp, -8, %o0                              
40005d28:	92 10 20 02 	mov  2, %o1                                    
40005d2c:	7f ff ff 47 	call  40005a48 <rtems_termios_puts>            
40005d30:	94 10 00 19 	mov  %i1, %o2                                  
    tty->column += 2;                                                 
40005d34:	c2 06 60 28 	ld  [ %i1 + 0x28 ], %g1                        
40005d38:	82 00 60 02 	add  %g1, 2, %g1                               
40005d3c:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        
40005d40:	81 c7 e0 08 	ret                                            
40005d44:	81 e8 00 00 	restore                                        
  } else {                                                            
    oproc (c, tty);                                                   
40005d48:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40005d4c:	7f ff ff 87 	call  40005b68 <oproc>                         
40005d50:	92 10 00 19 	mov  %i1, %o1                                  
40005d54:	81 c7 e0 08 	ret                                            
40005d58:	81 e8 00 00 	restore                                        
                                                                      

40004780 <endgrent>: } void endgrent(void) { if (group_fp != NULL)
40004780:	03 10 00 65 	sethi  %hi(0x40019400), %g1                    
40004784:	d0 00 63 d8 	ld  [ %g1 + 0x3d8 ], %o0	! 400197d8 <group_fp> 
40004788:	80 a2 20 00 	cmp  %o0, 0                                    
4000478c:	02 80 00 05 	be  400047a0 <endgrent+0x20>                   <== NEVER TAKEN
40004790:	01 00 00 00 	nop                                            
    fclose(group_fp);                                                 
40004794:	82 13 c0 00 	mov  %o7, %g1                                  
40004798:	40 00 30 72 	call  40010960 <fclose>                        
4000479c:	9e 10 40 00 	mov  %g1, %o7                                  
400047a0:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
                                                                      

400045e0 <endpwent>: } void endpwent(void) { if (passwd_fp != NULL)
400045e0:	03 10 00 66 	sethi  %hi(0x40019800), %g1                    
400045e4:	d0 00 60 c0 	ld  [ %g1 + 0xc0 ], %o0	! 400198c0 <passwd_fp> 
400045e8:	80 a2 20 00 	cmp  %o0, 0                                    
400045ec:	02 80 00 05 	be  40004600 <endpwent+0x20>                   <== NEVER TAKEN
400045f0:	01 00 00 00 	nop                                            
    fclose(passwd_fp);                                                
400045f4:	82 13 c0 00 	mov  %o7, %g1                                  
400045f8:	40 00 30 da 	call  40010960 <fclose>                        
400045fc:	9e 10 40 00 	mov  %g1, %o7                                  
40004600:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
                                                                      

40005d5c <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) {
40005d5c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (tty->ccount == 0)                                               
40005d60:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
40005d64:	80 a0 60 00 	cmp  %g1, 0                                    
40005d68:	02 80 00 0f 	be  40005da4 <erase+0x48>                      
40005d6c:	ba 10 00 18 	mov  %i0, %i5                                  
    return;                                                           
  if (lineFlag) {                                                     
40005d70:	80 a6 60 00 	cmp  %i1, 0                                    
40005d74:	32 80 00 08 	bne,a   40005d94 <erase+0x38>                  
40005d78:	c2 06 20 3c 	ld  [ %i0 + 0x3c ], %g1                        
          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);                       
40005d7c:	35 10 00 57 	sethi  %hi(0x40015c00), %i2                    
                                                                      
        /*                                                            
         * Back up over the tab                                       
         */                                                           
        while (tty->column > col) {                                   
          rtems_termios_puts ("\b", 1, tty);                          
40005d80:	31 10 00 57 	sethi  %hi(0x40015c00), %i0                    
40005d84:	37 10 00 5b 	sethi  %hi(0x40016c00), %i3                    
          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);                       
40005d88:	b4 16 a0 58 	or  %i2, 0x58, %i2                             
                                                                      
        /*                                                            
         * Back up over the tab                                       
         */                                                           
        while (tty->column > col) {                                   
          rtems_termios_puts ("\b", 1, tty);                          
40005d8c:	10 80 00 15 	b  40005de0 <erase+0x84>                       
40005d90:	b0 16 20 50 	or  %i0, 0x50, %i0                             
erase (struct rtems_termios_tty *tty, int lineFlag)                   
{                                                                     
  if (tty->ccount == 0)                                               
    return;                                                           
  if (lineFlag) {                                                     
    if (!(tty->termios.c_lflag & ECHO)) {                             
40005d94:	80 88 60 08 	btst  8, %g1                                   
40005d98:	32 80 00 05 	bne,a   40005dac <erase+0x50>                  <== ALWAYS TAKEN
40005d9c:	80 88 60 10 	btst  0x10, %g1                                
      tty->ccount = 0;                                                
40005da0:	c0 26 20 20 	clr  [ %i0 + 0x20 ]                            <== NOT EXECUTED
      return;                                                         
40005da4:	81 c7 e0 08 	ret                                            
40005da8:	81 e8 00 00 	restore                                        
    }                                                                 
    if (!(tty->termios.c_lflag & ECHOE)) {                            
40005dac:	12 bf ff f5 	bne  40005d80 <erase+0x24>                     <== ALWAYS TAKEN
40005db0:	35 10 00 57 	sethi  %hi(0x40015c00), %i2                    
      tty->ccount = 0;                                                
      echo (tty->termios.c_cc[VKILL], tty);                           
40005db4:	10 80 00 11 	b  40005df8 <erase+0x9c>                       <== NOT EXECUTED
40005db8:	d0 0e 20 44 	ldub  [ %i0 + 0x44 ], %o0                      <== NOT EXECUTED
  }                                                                   
                                                                      
  while (tty->ccount) {                                               
    unsigned char c = tty->cbuf[--tty->ccount];                       
                                                                      
    if (tty->termios.c_lflag & ECHO) {                                
40005dbc:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
      return;                                                         
    }                                                                 
  }                                                                   
                                                                      
  while (tty->ccount) {                                               
    unsigned char c = tty->cbuf[--tty->ccount];                       
40005dc0:	86 00 ff ff 	add  %g3, -1, %g3                              
40005dc4:	c6 27 60 20 	st  %g3, [ %i5 + 0x20 ]                        
                                                                      
    if (tty->termios.c_lflag & ECHO) {                                
40005dc8:	80 88 60 08 	btst  8, %g1                                   
40005dcc:	12 80 00 13 	bne  40005e18 <erase+0xbc>                     <== ALWAYS TAKEN
40005dd0:	f8 09 00 03 	ldub  [ %g4 + %g3 ], %i4                       
          if (tty->column)                                            
            tty->column--;                                            
        }                                                             
      }                                                               
    }                                                                 
    if (!lineFlag)                                                    
40005dd4:	80 a6 60 00 	cmp  %i1, 0                                    
40005dd8:	02 80 00 66 	be  40005f70 <erase+0x214>                     
40005ddc:	01 00 00 00 	nop                                            
        echo ('\n', tty);                                             
      return;                                                         
    }                                                                 
  }                                                                   
                                                                      
  while (tty->ccount) {                                               
40005de0:	c6 07 60 20 	ld  [ %i5 + 0x20 ], %g3                        
40005de4:	80 a0 e0 00 	cmp  %g3, 0                                    
40005de8:	32 bf ff f5 	bne,a   40005dbc <erase+0x60>                  
40005dec:	c8 07 60 1c 	ld  [ %i5 + 0x1c ], %g4                        
40005df0:	81 c7 e0 08 	ret                                            
40005df4:	81 e8 00 00 	restore                                        
    if (!(tty->termios.c_lflag & ECHO)) {                             
      tty->ccount = 0;                                                
      return;                                                         
    }                                                                 
    if (!(tty->termios.c_lflag & ECHOE)) {                            
      tty->ccount = 0;                                                
40005df8:	c0 26 20 20 	clr  [ %i0 + 0x20 ]                            <== NOT EXECUTED
      echo (tty->termios.c_cc[VKILL], tty);                           
40005dfc:	7f ff ff b7 	call  40005cd8 <echo>                          <== NOT EXECUTED
40005e00:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
      if (tty->termios.c_lflag & ECHOK)                               
40005e04:	c2 06 20 3c 	ld  [ %i0 + 0x3c ], %g1                        <== NOT EXECUTED
40005e08:	80 88 60 20 	btst  0x20, %g1                                <== NOT EXECUTED
40005e0c:	02 bf ff e6 	be  40005da4 <erase+0x48>                      <== NOT EXECUTED
40005e10:	b0 10 20 0a 	mov  0xa, %i0                                  <== NOT EXECUTED
40005e14:	30 80 00 08 	b,a   40005e34 <erase+0xd8>                    <== 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)) {             
40005e18:	80 a6 60 00 	cmp  %i1, 0                                    
40005e1c:	32 80 00 08 	bne,a   40005e3c <erase+0xe0>                  
40005e20:	b8 0f 20 ff 	and  %i4, 0xff, %i4                            
40005e24:	80 88 60 10 	btst  0x10, %g1                                
40005e28:	32 80 00 05 	bne,a   40005e3c <erase+0xe0>                  <== ALWAYS TAKEN
40005e2c:	b8 0f 20 ff 	and  %i4, 0xff, %i4                            
        echo (tty->termios.c_cc[VERASE], tty);                        
40005e30:	f0 0f 60 43 	ldub  [ %i5 + 0x43 ], %i0                      <== NOT EXECUTED
40005e34:	7f ff ff a9 	call  40005cd8 <echo>                          <== NOT EXECUTED
40005e38:	93 e8 00 1d 	restore  %g0, %i5, %o1                         <== NOT EXECUTED
      } else if (c == '\t') {                                         
40005e3c:	80 a7 20 09 	cmp  %i4, 9                                    
40005e40:	12 80 00 26 	bne  40005ed8 <erase+0x17c>                    
40005e44:	c4 06 e1 0c 	ld  [ %i3 + 0x10c ], %g2                       
        int col = tty->read_start_column;                             
40005e48:	f8 07 60 2c 	ld  [ %i5 + 0x2c ], %i4                        
         */                                                           
        while (i != tty->ccount) {                                    
          c = tty->cbuf[i++];                                         
          if (c == '\t') {                                            
            col = (col | 7) + 1;                                      
          } else if (iscntrl (c)) {                                   
40005e4c:	da 06 e1 0c 	ld  [ %i3 + 0x10c ], %o5                       
40005e50:	84 10 20 00 	clr  %g2                                       
            if (tty->termios.c_lflag & ECHOCTL)                       
40005e54:	82 08 62 00 	and  %g1, 0x200, %g1                           
        int i = 0;                                                    
                                                                      
        /*                                                            
         * Find the character before the tab                          
         */                                                           
        while (i != tty->ccount) {                                    
40005e58:	80 a0 80 03 	cmp  %g2, %g3                                  
40005e5c:	22 80 00 15 	be,a   40005eb0 <erase+0x154>                  
40005e60:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
          c = tty->cbuf[i++];                                         
          if (c == '\t') {                                            
40005e64:	de 09 00 02 	ldub  [ %g4 + %g2 ], %o7                       
40005e68:	80 a3 e0 09 	cmp  %o7, 9                                    
40005e6c:	32 80 00 04 	bne,a   40005e7c <erase+0x120>                 
40005e70:	9e 03 40 0f 	add  %o5, %o7, %o7                             
            col = (col | 7) + 1;                                      
40005e74:	10 80 00 0b 	b  40005ea0 <erase+0x144>                      
40005e78:	b8 17 20 07 	or  %i4, 7, %i4                                
          } else if (iscntrl (c)) {                                   
40005e7c:	de 0b e0 01 	ldub  [ %o7 + 1 ], %o7                         
40005e80:	80 8b e0 20 	btst  0x20, %o7                                
40005e84:	22 80 00 08 	be,a   40005ea4 <erase+0x148>                  <== ALWAYS TAKEN
40005e88:	b8 07 20 01 	inc  %i4                                       
            if (tty->termios.c_lflag & ECHOCTL)                       
40005e8c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40005e90:	32 80 00 05 	bne,a   40005ea4 <erase+0x148>                 <== NOT EXECUTED
40005e94:	b8 07 20 02 	add  %i4, 2, %i4                               <== NOT EXECUTED
40005e98:	10 bf ff f0 	b  40005e58 <erase+0xfc>                       <== NOT EXECUTED
40005e9c:	84 00 a0 01 	inc  %g2                                       <== NOT EXECUTED
              col += 2;                                               
          } else {                                                    
            col++;                                                    
40005ea0:	b8 07 20 01 	inc  %i4                                       
40005ea4:	10 bf ff ed 	b  40005e58 <erase+0xfc>                       
40005ea8:	84 00 a0 01 	inc  %g2                                       
        }                                                             
                                                                      
        /*                                                            
         * Back up over the tab                                       
         */                                                           
        while (tty->column > col) {                                   
40005eac:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
40005eb0:	80 a0 40 1c 	cmp  %g1, %i4                                  
40005eb4:	04 bf ff c8 	ble  40005dd4 <erase+0x78>                     
40005eb8:	90 10 00 18 	mov  %i0, %o0                                  
          rtems_termios_puts ("\b", 1, tty);                          
40005ebc:	92 10 20 01 	mov  1, %o1                                    
40005ec0:	7f ff fe e2 	call  40005a48 <rtems_termios_puts>            
40005ec4:	94 10 00 1d 	mov  %i5, %o2                                  
          tty->column--;                                              
40005ec8:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
40005ecc:	82 00 7f ff 	add  %g1, -1, %g1                              
40005ed0:	10 bf ff f7 	b  40005eac <erase+0x150>                      
40005ed4:	c2 27 60 28 	st  %g1, [ %i5 + 0x28 ]                        
        }                                                             
      }                                                               
      else {                                                          
        if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {        
40005ed8:	b8 07 20 01 	inc  %i4                                       
40005edc:	c4 08 80 1c 	ldub  [ %g2 + %i4 ], %g2                       
40005ee0:	80 88 a0 20 	btst  0x20, %g2                                
40005ee4:	22 80 00 10 	be,a   40005f24 <erase+0x1c8>                  <== ALWAYS TAKEN
40005ee8:	c2 06 e1 0c 	ld  [ %i3 + 0x10c ], %g1                       
40005eec:	80 88 62 00 	btst  0x200, %g1                               <== NOT EXECUTED
40005ef0:	02 80 00 0d 	be  40005f24 <erase+0x1c8>                     <== NOT EXECUTED
40005ef4:	c2 06 e1 0c 	ld  [ %i3 + 0x10c ], %g1                       <== NOT EXECUTED
          rtems_termios_puts ("\b \b", 3, tty);                       
40005ef8:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
40005efc:	92 10 20 03 	mov  3, %o1                                    <== NOT EXECUTED
40005f00:	7f ff fe d2 	call  40005a48 <rtems_termios_puts>            <== NOT EXECUTED
40005f04:	94 10 00 1d 	mov  %i5, %o2                                  <== NOT EXECUTED
          if (tty->column)                                            
40005f08:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        <== NOT EXECUTED
40005f0c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40005f10:	22 80 00 05 	be,a   40005f24 <erase+0x1c8>                  <== NOT EXECUTED
40005f14:	c2 06 e1 0c 	ld  [ %i3 + 0x10c ], %g1                       <== NOT EXECUTED
            tty->column--;                                            
40005f18:	82 00 7f ff 	add  %g1, -1, %g1                              <== NOT EXECUTED
40005f1c:	c2 27 60 28 	st  %g1, [ %i5 + 0x28 ]                        <== NOT EXECUTED
        }                                                             
        if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) {       
40005f20:	c2 06 e1 0c 	ld  [ %i3 + 0x10c ], %g1                       <== NOT EXECUTED
40005f24:	c2 08 40 1c 	ldub  [ %g1 + %i4 ], %g1                       
40005f28:	80 88 60 20 	btst  0x20, %g1                                
40005f2c:	02 80 00 07 	be  40005f48 <erase+0x1ec>                     <== ALWAYS TAKEN
40005f30:	90 10 00 1a 	mov  %i2, %o0                                  
40005f34:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        <== NOT EXECUTED
40005f38:	80 88 62 00 	btst  0x200, %g1                               <== NOT EXECUTED
40005f3c:	02 bf ff a7 	be  40005dd8 <erase+0x7c>                      <== NOT EXECUTED
40005f40:	80 a6 60 00 	cmp  %i1, 0                                    <== NOT EXECUTED
          rtems_termios_puts ("\b \b", 3, tty);                       
40005f44:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
40005f48:	92 10 20 03 	mov  3, %o1                                    
40005f4c:	7f ff fe bf 	call  40005a48 <rtems_termios_puts>            
40005f50:	94 10 00 1d 	mov  %i5, %o2                                  
          if (tty->column)                                            
40005f54:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
40005f58:	80 a0 60 00 	cmp  %g1, 0                                    
40005f5c:	02 bf ff 9f 	be  40005dd8 <erase+0x7c>                      <== NEVER TAKEN
40005f60:	80 a6 60 00 	cmp  %i1, 0                                    
            tty->column--;                                            
40005f64:	82 00 7f ff 	add  %g1, -1, %g1                              
40005f68:	10 bf ff 9c 	b  40005dd8 <erase+0x7c>                       
40005f6c:	c2 27 60 28 	st  %g1, [ %i5 + 0x28 ]                        
40005f70:	81 c7 e0 08 	ret                                            
40005f74:	81 e8 00 00 	restore                                        
                                                                      

40013060 <fat_buf_access>: int fat_buf_access(fat_fs_info_t *fs_info, const uint32_t sec_num, const int op_type, uint8_t **sec_buf) {
40013060:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
static inline uint32_t                                                
 fat_sector_num_to_block_num (const fat_fs_info_t *fs_info,           
                              const uint32_t sector_number)           
{                                                                     
  return sector_number >> (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40013064:	c2 0e 20 02 	ldub  [ %i0 + 2 ], %g1                         
40013068:	c4 0e 20 0c 	ldub  [ %i0 + 0xc ], %g2                       
4001306c:	84 20 80 01 	sub  %g2, %g1, %g2                             
40013070:	bb 36 40 02 	srl  %i1, %g2, %i5                             
                                                                      
static inline uint32_t                                                
 fat_block_num_to_sector_num (const fat_fs_info_t *fs_info,           
                              const uint32_t block_number)            
{                                                                     
  return block_number << (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40013074:	b9 2f 40 02 	sll  %i5, %g2, %i4                             
 fat_sector_offset_to_block_offset (const fat_fs_info_t *fs_info,     
                                    const uint32_t sector,            
                                    const uint32_t sector_offset)     
{                                                                     
  return sector_offset +                                              
           ((sector -                                                 
40013078:	b8 26 40 1c 	sub  %i1, %i4, %i4                             
              fat_block_num_to_sector_num (fs_info,                   
                  fat_sector_num_to_block_num (fs_info, sector)))     
            << fs_info->vol.sec_log2);                                
4001307c:	b9 2f 00 01 	sll  %i4, %g1, %i4                             
                                                         sec_num);    
    uint32_t          blk_ofs = fat_sector_offset_to_block_offset (fs_info,
                                                                   sec_num,
                                                                   0);
                                                                      
    if (fs_info->c.state == FAT_CACHE_EMPTY || fs_info->c.blk_num != sec_num)
40013080:	c2 0e 20 89 	ldub  [ %i0 + 0x89 ], %g1                      
40013084:	80 a0 60 00 	cmp  %g1, 0                                    
40013088:	02 80 00 06 	be  400130a0 <fat_buf_access+0x40>             
4001308c:	01 00 00 00 	nop                                            
40013090:	c2 06 20 84 	ld  [ %i0 + 0x84 ], %g1                        
40013094:	80 a0 40 19 	cmp  %g1, %i1                                  
40013098:	22 80 00 1c 	be,a   40013108 <fat_buf_access+0xa8>          
4001309c:	c2 06 20 8c 	ld  [ %i0 + 0x8c ], %g1                        
    {                                                                 
        fat_buf_release(fs_info);                                     
400130a0:	7f ff ff 7f 	call  40012e9c <fat_buf_release>               
400130a4:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
        if (op_type == FAT_OP_TYPE_READ)                              
            sc = rtems_bdbuf_read(fs_info->vol.dd, blk, &fs_info->c.buf);
400130a8:	92 10 00 1d 	mov  %i5, %o1                                  
                                                                      
    if (fs_info->c.state == FAT_CACHE_EMPTY || fs_info->c.blk_num != sec_num)
    {                                                                 
        fat_buf_release(fs_info);                                     
                                                                      
        if (op_type == FAT_OP_TYPE_READ)                              
400130ac:	80 a6 a0 01 	cmp  %i2, 1                                    
400130b0:	d0 06 20 64 	ld  [ %i0 + 0x64 ], %o0                        
400130b4:	12 80 00 06 	bne  400130cc <fat_buf_access+0x6c>            
400130b8:	94 06 20 8c 	add  %i0, 0x8c, %o2                            
            sc = rtems_bdbuf_read(fs_info->vol.dd, blk, &fs_info->c.buf);
400130bc:	7f ff f6 e6 	call  40010c54 <rtems_bdbuf_read>              
400130c0:	01 00 00 00 	nop                                            
400130c4:	10 80 00 05 	b  400130d8 <fat_buf_access+0x78>              
400130c8:	80 a2 20 00 	cmp  %o0, 0                                    
        else                                                          
            sc = rtems_bdbuf_get(fs_info->vol.dd, blk, &fs_info->c.buf);
400130cc:	7f ff f6 be 	call  40010bc4 <rtems_bdbuf_get>               
400130d0:	01 00 00 00 	nop                                            
        if (sc != RTEMS_SUCCESSFUL)                                   
400130d4:	80 a2 20 00 	cmp  %o0, 0                                    
400130d8:	02 80 00 08 	be  400130f8 <fat_buf_access+0x98>             <== ALWAYS TAKEN
400130dc:	82 10 20 01 	mov  1, %g1                                    
            rtems_set_errno_and_return_minus_one(EIO);                
400130e0:	40 00 24 eb 	call  4001c48c <__errno>                       <== NOT EXECUTED
400130e4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400130e8:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
400130ec:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
400130f0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400130f4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
        fs_info->c.blk_num = sec_num;                                 
400130f8:	f2 26 20 84 	st  %i1, [ %i0 + 0x84 ]                        
        fs_info->c.modified = 0;                                      
400130fc:	c0 2e 20 88 	clrb  [ %i0 + 0x88 ]                           
        fs_info->c.state = FAT_CACHE_ACTUAL;                          
40013100:	c2 2e 20 89 	stb  %g1, [ %i0 + 0x89 ]                       
    }                                                                 
    *sec_buf = &fs_info->c.buf->buffer[blk_ofs];                      
40013104:	c2 06 20 8c 	ld  [ %i0 + 0x8c ], %g1                        
40013108:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001310c:	b8 00 40 1c 	add  %g1, %i4, %i4                             
40013110:	f8 26 c0 00 	st  %i4, [ %i3 ]                               
    return RC_OK;                                                     
}                                                                     
40013114:	81 c7 e0 08 	ret                                            
40013118:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40012e9c <fat_buf_release>: return RC_OK; } int fat_buf_release(fat_fs_info_t *fs_info) {
40012e9c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    rtems_status_code sc = RTEMS_SUCCESSFUL;                          
                                                                      
    if (fs_info->c.state == FAT_CACHE_EMPTY)                          
40012ea0:	c2 0e 20 89 	ldub  [ %i0 + 0x89 ], %g1                      
    return RC_OK;                                                     
}                                                                     
                                                                      
int                                                                   
fat_buf_release(fat_fs_info_t *fs_info)                               
{                                                                     
40012ea4:	ba 10 00 18 	mov  %i0, %i5                                  
    rtems_status_code sc = RTEMS_SUCCESSFUL;                          
                                                                      
    if (fs_info->c.state == FAT_CACHE_EMPTY)                          
40012ea8:	80 a0 60 00 	cmp  %g1, 0                                    
40012eac:	02 80 00 6b 	be  40013058 <fat_buf_release+0x1bc>           
40012eb0:	b0 10 20 00 	clr  %i0                                       
        return RC_OK;                                                 
                                                                      
    if (fs_info->c.modified)                                          
40012eb4:	c2 0f 60 88 	ldub  [ %i5 + 0x88 ], %g1                      
40012eb8:	80 a0 60 00 	cmp  %g1, 0                                    
40012ebc:	02 80 00 5a 	be  40013024 <fat_buf_release+0x188>           
40012ec0:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        
    {                                                                 
        uint32_t sec_num = fs_info->c.blk_num;                        
40012ec4:	c2 07 60 84 	ld  [ %i5 + 0x84 ], %g1                        
        bool     sec_of_fat = ((sec_num >= fs_info->vol.fat_loc) &&   
40012ec8:	c4 17 60 18 	lduh  [ %i5 + 0x18 ], %g2                      
40012ecc:	80 a0 40 02 	cmp  %g1, %g2                                  
40012ed0:	0a 80 00 05 	bcs  40012ee4 <fat_buf_release+0x48>           
40012ed4:	b8 10 20 00 	clr  %i4                                       
40012ed8:	c4 07 60 20 	ld  [ %i5 + 0x20 ], %g2                        
40012edc:	80 a0 40 02 	cmp  %g1, %g2                                  
40012ee0:	b8 40 20 00 	addx  %g0, 0, %i4                              
}                                                                     
                                                                      
static inline uint32_t                                                
 fat_sector_offset_to_block_offset (const fat_fs_info_t *fs_info,     
40012ee4:	c4 0f 60 02 	ldub  [ %i5 + 2 ], %g2                         
        uint32_t blk = fat_sector_num_to_block_num(fs_info, sec_num); 
        uint32_t blk_ofs = fat_sector_offset_to_block_offset(fs_info, 
                                                             sec_num, 
                                                             0);      
                                                                      
        if (sec_of_fat && !fs_info->vol.mirror)                       
40012ee8:	80 a7 20 00 	cmp  %i4, 0                                    
40012eec:	02 80 00 11 	be  40012f30 <fat_buf_release+0x94>            
40012ef0:	c6 0f 60 0c 	ldub  [ %i5 + 0xc ], %g3                       
40012ef4:	c8 0f 60 54 	ldub  [ %i5 + 0x54 ], %g4                      
40012ef8:	80 a1 20 00 	cmp  %g4, 0                                    
40012efc:	12 80 00 0d 	bne  40012f30 <fat_buf_release+0x94>           <== NEVER TAKEN
40012f00:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
            memcpy(fs_info->sec_buf,                                  
40012f04:	d2 02 20 1c 	ld  [ %o0 + 0x1c ], %o1                        
40012f08:	d4 17 40 00 	lduh  [ %i5 ], %o2                             
40012f0c:	d0 07 60 90 	ld  [ %i5 + 0x90 ], %o0                        
                                                                      
static inline uint32_t                                                
 fat_sector_num_to_block_num (const fat_fs_info_t *fs_info,           
                              const uint32_t sector_number)           
{                                                                     
  return sector_number >> (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40012f10:	86 08 e0 ff 	and  %g3, 0xff, %g3                            
40012f14:	86 20 c0 02 	sub  %g3, %g2, %g3                             
40012f18:	89 30 40 03 	srl  %g1, %g3, %g4                             
                                                                      
static inline uint32_t                                                
 fat_block_num_to_sector_num (const fat_fs_info_t *fs_info,           
                              const uint32_t block_number)            
{                                                                     
  return block_number << (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40012f1c:	87 29 00 03 	sll  %g4, %g3, %g3                             
 fat_sector_offset_to_block_offset (const fat_fs_info_t *fs_info,     
                                    const uint32_t sector,            
                                    const uint32_t sector_offset)     
{                                                                     
  return sector_offset +                                              
           ((sector -                                                 
40012f20:	82 20 40 03 	sub  %g1, %g3, %g1                             
              fat_block_num_to_sector_num (fs_info,                   
                  fat_sector_num_to_block_num (fs_info, sector)))     
            << fs_info->vol.sec_log2);                                
40012f24:	85 28 40 02 	sll  %g1, %g2, %g2                             
40012f28:	40 00 27 ae 	call  4001cde0 <memcpy>                        
40012f2c:	92 02 40 02 	add  %o1, %g2, %o1                             
                   fs_info->c.buf->buffer + blk_ofs,                  
                   fs_info->vol.bps);                                 
                                                                      
        sc = rtems_bdbuf_release_modified(fs_info->c.buf);            
40012f30:	7f ff f7 ed 	call  40010ee4 <rtems_bdbuf_release_modified>  
40012f34:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        
        if (sc != RTEMS_SUCCESSFUL)                                   
40012f38:	80 a2 20 00 	cmp  %o0, 0                                    
40012f3c:	12 80 00 3f 	bne  40013038 <fat_buf_release+0x19c>          <== NEVER TAKEN
40012f40:	80 a7 20 00 	cmp  %i4, 0                                    
            rtems_set_errno_and_return_minus_one(EIO);                
        fs_info->c.modified = 0;                                      
                                                                      
        if (sec_of_fat && !fs_info->vol.mirror)                       
40012f44:	02 80 00 43 	be  40013050 <fat_buf_release+0x1b4>           
40012f48:	c0 2f 60 88 	clrb  [ %i5 + 0x88 ]                           
40012f4c:	c2 0f 60 54 	ldub  [ %i5 + 0x54 ], %g1                      
40012f50:	80 a0 60 00 	cmp  %g1, 0                                    
40012f54:	32 80 00 40 	bne,a   40013054 <fat_buf_release+0x1b8>       <== NEVER TAKEN
40012f58:	c0 2f 60 89 	clrb  [ %i5 + 0x89 ]                           <== NOT EXECUTED
40012f5c:	b8 10 20 01 	mov  1, %i4                                    
        {                                                             
            uint8_t i;                                                
                                                                      
            for (i = 1; i < fs_info->vol.fats; i++)                   
40012f60:	c2 0f 60 0d 	ldub  [ %i5 + 0xd ], %g1                       
40012f64:	90 0f 20 ff 	and  %i4, 0xff, %o0                            
40012f68:	80 a2 00 01 	cmp  %o0, %g1                                  
40012f6c:	3a 80 00 3a 	bcc,a   40013054 <fat_buf_release+0x1b8>       
40012f70:	c0 2f 60 89 	clrb  [ %i5 + 0x89 ]                           
            {                                                         
                rtems_bdbuf_buffer *bd;                               
                                                                      
                sec_num = fs_info->c.blk_num + fs_info->vol.fat_length * i,
40012f74:	7f ff bd e7 	call  40002710 <.umul>                         
40012f78:	d2 07 60 1c 	ld  [ %i5 + 0x1c ], %o1                        
40012f7c:	f6 07 60 84 	ld  [ %i5 + 0x84 ], %i3                        
                                                                      
static inline uint32_t                                                
 fat_sector_num_to_block_num (const fat_fs_info_t *fs_info,           
                              const uint32_t sector_number)           
{                                                                     
  return sector_number >> (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40012f80:	c2 0f 60 02 	ldub  [ %i5 + 2 ], %g1                         
40012f84:	90 02 00 1b 	add  %o0, %i3, %o0                             
40012f88:	f6 0f 60 0c 	ldub  [ %i5 + 0xc ], %i3                       
                                                            0);       
                                                                      
                if (blk_ofs == 0                                      
                    && fs_info->vol.bps == fs_info->vol.bytes_per_block)
                {                                                     
                    sc = rtems_bdbuf_get(fs_info->vol.dd, blk, &bd);  
40012f8c:	94 07 bf fc 	add  %fp, -4, %o2                              
40012f90:	b6 26 c0 01 	sub  %i3, %g1, %i3                             
40012f94:	93 32 00 1b 	srl  %o0, %i3, %o1                             
                                                                      
static inline uint32_t                                                
 fat_block_num_to_sector_num (const fat_fs_info_t *fs_info,           
                              const uint32_t block_number)            
{                                                                     
  return block_number << (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40012f98:	b7 2a 40 1b 	sll  %o1, %i3, %i3                             
 fat_sector_offset_to_block_offset (const fat_fs_info_t *fs_info,     
                                    const uint32_t sector,            
                                    const uint32_t sector_offset)     
{                                                                     
  return sector_offset +                                              
           ((sector -                                                 
40012f9c:	b6 22 00 1b 	sub  %o0, %i3, %i3                             
              fat_block_num_to_sector_num (fs_info,                   
                  fat_sector_num_to_block_num (fs_info, sector)))     
            << fs_info->vol.sec_log2);                                
40012fa0:	b7 2e c0 01 	sll  %i3, %g1, %i3                             
                blk = fat_sector_num_to_block_num(fs_info, sec_num);  
                blk_ofs = fat_sector_offset_to_block_offset(fs_info,  
                                                            sec_num,  
                                                            0);       
                                                                      
                if (blk_ofs == 0                                      
40012fa4:	80 a6 e0 00 	cmp  %i3, 0                                    
40012fa8:	12 80 00 0b 	bne  40012fd4 <fat_buf_release+0x138>          
40012fac:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        
                    && fs_info->vol.bps == fs_info->vol.bytes_per_block)
40012fb0:	c4 17 40 00 	lduh  [ %i5 ], %g2                             
40012fb4:	c2 17 60 0a 	lduh  [ %i5 + 0xa ], %g1                       
40012fb8:	80 a0 80 01 	cmp  %g2, %g1                                  
40012fbc:	12 80 00 06 	bne  40012fd4 <fat_buf_release+0x138>          
40012fc0:	01 00 00 00 	nop                                            
                {                                                     
                    sc = rtems_bdbuf_get(fs_info->vol.dd, blk, &bd);  
40012fc4:	7f ff f7 00 	call  40010bc4 <rtems_bdbuf_get>               
40012fc8:	01 00 00 00 	nop                                            
                }                                                     
                else                                                  
                {                                                     
                    sc = rtems_bdbuf_read(fs_info->vol.dd, blk, &bd); 
                }                                                     
                if ( sc != RTEMS_SUCCESSFUL)                          
40012fcc:	10 80 00 05 	b  40012fe0 <fat_buf_release+0x144>            
40012fd0:	80 a2 20 00 	cmp  %o0, 0                                    
                {                                                     
                    sc = rtems_bdbuf_get(fs_info->vol.dd, blk, &bd);  
                }                                                     
                else                                                  
                {                                                     
                    sc = rtems_bdbuf_read(fs_info->vol.dd, blk, &bd); 
40012fd4:	7f ff f7 20 	call  40010c54 <rtems_bdbuf_read>              
40012fd8:	01 00 00 00 	nop                                            
                }                                                     
                if ( sc != RTEMS_SUCCESSFUL)                          
40012fdc:	80 a2 20 00 	cmp  %o0, 0                                    
40012fe0:	12 80 00 0d 	bne  40013014 <fat_buf_release+0x178>          <== NEVER TAKEN
40012fe4:	01 00 00 00 	nop                                            
                    rtems_set_errno_and_return_minus_one(ENOMEM);     
                memcpy(bd->buffer + blk_ofs, fs_info->sec_buf, fs_info->vol.bps);
40012fe8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40012fec:	d2 07 60 90 	ld  [ %i5 + 0x90 ], %o1                        
40012ff0:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40012ff4:	d4 17 40 00 	lduh  [ %i5 ], %o2                             
40012ff8:	40 00 27 7a 	call  4001cde0 <memcpy>                        
40012ffc:	90 02 00 1b 	add  %o0, %i3, %o0                             
                sc = rtems_bdbuf_release_modified(bd);                
40013000:	7f ff f7 b9 	call  40010ee4 <rtems_bdbuf_release_modified>  
40013004:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
                if ( sc != RTEMS_SUCCESSFUL)                          
40013008:	80 a2 20 00 	cmp  %o0, 0                                    
4001300c:	22 bf ff d5 	be,a   40012f60 <fat_buf_release+0xc4>         <== ALWAYS TAKEN
40013010:	b8 07 20 01 	inc  %i4                                       
                    rtems_set_errno_and_return_minus_one(ENOMEM);     
40013014:	40 00 25 1e 	call  4001c48c <__errno>                       <== NOT EXECUTED
40013018:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001301c:	10 80 00 0a 	b  40013044 <fat_buf_release+0x1a8>            <== NOT EXECUTED
40013020:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
            }                                                         
        }                                                             
    }                                                                 
    else                                                              
    {                                                                 
        sc = rtems_bdbuf_release(fs_info->c.buf);                     
40013024:	7f ff f7 7b 	call  40010e10 <rtems_bdbuf_release>           
40013028:	01 00 00 00 	nop                                            
        if (sc != RTEMS_SUCCESSFUL)                                   
4001302c:	80 a2 20 00 	cmp  %o0, 0                                    
40013030:	22 80 00 09 	be,a   40013054 <fat_buf_release+0x1b8>        <== ALWAYS TAKEN
40013034:	c0 2f 60 89 	clrb  [ %i5 + 0x89 ]                           
            rtems_set_errno_and_return_minus_one(EIO);                
40013038:	40 00 25 15 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001303c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40013040:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
40013044:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40013048:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001304c:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
    }                                                                 
    fs_info->c.state = FAT_CACHE_EMPTY;                               
40013050:	c0 2f 60 89 	clrb  [ %i5 + 0x89 ]                           
    return RC_OK;                                                     
40013054:	b0 10 20 00 	clr  %i0                                       
}                                                                     
40013058:	81 c7 e0 08 	ret                                            
4001305c:	81 e8 00 00 	restore                                        
                                                                      

40012e48 <fat_cluster_num_to_block_num>: fat_cluster_num_to_block_num (const fat_fs_info_t *fs_info, uint32_t cln) { uint32_t blk; if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
40012e48:	80 a2 60 00 	cmp  %o1, 0                                    
40012e4c:	12 80 00 0a 	bne  40012e74 <fat_cluster_num_to_block_num+0x2c>
40012e50:	c2 0a 20 02 	ldub  [ %o0 + 2 ], %g1                         
40012e54:	c4 0a 20 0e 	ldub  [ %o0 + 0xe ], %g2                       
40012e58:	80 88 a0 03 	btst  3, %g2                                   
40012e5c:	02 80 00 07 	be  40012e78 <fat_cluster_num_to_block_num+0x30><== NEVER TAKEN
40012e60:	c4 0a 20 0c 	ldub  [ %o0 + 0xc ], %g2                       
                                                                      
static inline uint32_t                                                
 fat_sector_num_to_block_num (const fat_fs_info_t *fs_info,           
                              const uint32_t sector_number)           
{                                                                     
  return sector_number >> (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
40012e64:	d0 02 20 20 	ld  [ %o0 + 0x20 ], %o0                        
40012e68:	82 20 80 01 	sub  %g2, %g1, %g1                             
40012e6c:	81 c3 e0 08 	retl                                           
40012e70:	91 32 00 01 	srl  %o0, %g1, %o0                             
        blk = fat_sector_num_to_block_num(fs_info, fs_info->vol.rdir_loc);
    else                                                              
    {                                                                 
        cln -= FAT_RSRVD_CLN;                                         
        blk = cln << (fs_info->vol.bpc_log2 - fs_info->vol.bytes_per_block_log2);
40012e74:	c4 0a 20 0c 	ldub  [ %o0 + 0xc ], %g2                       
40012e78:	c6 0a 20 08 	ldub  [ %o0 + 8 ], %g3                         
40012e7c:	d0 02 20 34 	ld  [ %o0 + 0x34 ], %o0                        
40012e80:	86 20 c0 02 	sub  %g3, %g2, %g3                             
40012e84:	82 20 80 01 	sub  %g2, %g1, %g1                             
                                                                      
    if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
        blk = fat_sector_num_to_block_num(fs_info, fs_info->vol.rdir_loc);
    else                                                              
    {                                                                 
        cln -= FAT_RSRVD_CLN;                                         
40012e88:	92 02 7f fe 	add  %o1, -2, %o1                              
40012e8c:	91 32 00 01 	srl  %o0, %g1, %o0                             
        blk = cln << (fs_info->vol.bpc_log2 - fs_info->vol.bytes_per_block_log2);
40012e90:	93 2a 40 03 	sll  %o1, %g3, %o1                             
        blk += fat_sector_num_to_block_num(fs_info, fs_info->vol.data_fsec);
    }                                                                 
                                                                      
    return blk;                                                       
}                                                                     
40012e94:	81 c3 e0 08 	retl                                           
40012e98:	90 02 00 09 	add  %o0, %o1, %o0                             
                                                                      

400121a0 <fat_cluster_num_to_sector_num>: fat_cluster_num_to_sector_num( const fat_fs_info_t *fs_info, uint32_t cln ) { if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
400121a0:	80 a2 60 00 	cmp  %o1, 0                                    
400121a4:	32 80 00 08 	bne,a   400121c4 <fat_cluster_num_to_sector_num+0x24>
400121a8:	c2 0a 20 05 	ldub  [ %o0 + 5 ], %g1                         
400121ac:	c2 0a 20 0e 	ldub  [ %o0 + 0xe ], %g1                       
400121b0:	80 88 60 03 	btst  3, %g1                                   
400121b4:	22 80 00 04 	be,a   400121c4 <fat_cluster_num_to_sector_num+0x24><== NEVER TAKEN
400121b8:	c2 0a 20 05 	ldub  [ %o0 + 5 ], %g1                         <== NOT EXECUTED
        return fs_info->vol.rdir_loc;                                 
400121bc:	81 c3 e0 08 	retl                                           
400121c0:	d0 02 20 20 	ld  [ %o0 + 0x20 ], %o0                        
                                                                      
    return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +        
400121c4:	92 02 7f fe 	add  %o1, -2, %o1                              
400121c8:	93 2a 40 01 	sll  %o1, %g1, %o1                             
400121cc:	c2 02 20 34 	ld  [ %o0 + 0x34 ], %g1                        
            fs_info->vol.data_fsec);                                  
}                                                                     
400121d0:	81 c3 e0 08 	retl                                           
400121d4:	90 02 40 01 	add  %o1, %g1, %o0                             
                                                                      

4001322c <fat_cluster_set>: fat_fs_info_t *fs_info, const uint32_t start_cln, const uint32_t offset, const uint32_t count, const uint8_t pattern) {
4001322c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  ssize_t             rc               = RC_OK;                       
  uint32_t            bytes_to_write   = MIN(count, (fs_info->vol.bpc - offset));
40013230:	fa 16 20 06 	lduh  [ %i0 + 6 ], %i5                         
40013234:	ba 27 40 1a 	sub  %i5, %i2, %i5                             
40013238:	80 a7 40 1b 	cmp  %i5, %i3                                  
4001323c:	38 80 00 02 	bgu,a   40013244 <fat_cluster_set+0x18>        <== NEVER TAKEN
40013240:	ba 10 00 1b 	mov  %i3, %i5                                  <== NOT EXECUTED
  uint32_t            cur_blk          = fat_cluster_num_to_block_num(fs_info, start_cln);
40013244:	90 10 00 18 	mov  %i0, %o0                                  
40013248:	7f ff ff 00 	call  40012e48 <fat_cluster_num_to_block_num>  
4001324c:	92 10 00 19 	mov  %i1, %o1                                  
  uint32_t            blocks_in_offset = offset >> fs_info->vol.bytes_per_block_log2;
40013250:	c2 0e 20 0c 	ldub  [ %i0 + 0xc ], %g1                       
  uint32_t            ofs_blk          = offset - (blocks_in_offset << fs_info->vol.bytes_per_block_log2);
  ssize_t             bytes_written    = 0;                           
40013254:	a0 10 20 00 	clr  %l0                                       
     const uint8_t                         pattern)                   
{                                                                     
  ssize_t             rc               = RC_OK;                       
  uint32_t            bytes_to_write   = MIN(count, (fs_info->vol.bpc - offset));
  uint32_t            cur_blk          = fat_cluster_num_to_block_num(fs_info, start_cln);
  uint32_t            blocks_in_offset = offset >> fs_info->vol.bytes_per_block_log2;
40013258:	a3 36 80 01 	srl  %i2, %g1, %l1                             
  uint32_t            ofs_blk          = offset - (blocks_in_offset << fs_info->vol.bytes_per_block_log2);
4001325c:	83 2c 40 01 	sll  %l1, %g1, %g1                             
40013260:	a4 10 20 01 	mov  1, %l2                                    
40013264:	b4 26 80 01 	sub  %i2, %g1, %i2                             
  ssize_t             bytes_written    = 0;                           
  ssize_t             ret;                                            
                                                                      
  cur_blk += blocks_in_offset;                                        
40013268:	a2 02 00 11 	add  %o0, %l1, %l1                             
     const uint32_t                        start_cln,                 
     const uint32_t                        offset,                    
     const uint32_t                        count,                     
     const uint8_t                         pattern)                   
{                                                                     
  ssize_t             rc               = RC_OK;                       
4001326c:	82 10 20 00 	clr  %g1                                       
  ssize_t             bytes_written    = 0;                           
  ssize_t             ret;                                            
                                                                      
  cur_blk += blocks_in_offset;                                        
                                                                      
  while (   (RC_OK == rc)                                             
40013270:	80 a7 60 00 	cmp  %i5, 0                                    
40013274:	02 80 00 2e 	be  4001332c <fat_cluster_set+0x100>           
40013278:	80 a0 60 00 	cmp  %g1, 0                                    
4001327c:	32 80 00 2f 	bne,a   40013338 <fat_cluster_set+0x10c>       <== NEVER TAKEN
40013280:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
         && (0 < bytes_to_write))                                     
  {                                                                   
    uint32_t c = MIN(bytes_to_write, (fs_info->vol.bytes_per_block - ofs_blk));
40013284:	c4 16 20 0a 	lduh  [ %i0 + 0xa ], %g2                       
40013288:	82 20 80 1a 	sub  %g2, %i2, %g1                             
4001328c:	80 a0 40 1d 	cmp  %g1, %i5                                  
40013290:	08 80 00 03 	bleu  4001329c <fat_cluster_set+0x70>          <== ALWAYS TAKEN
40013294:	b6 10 00 01 	mov  %g1, %i3                                  
40013298:	b6 10 00 1d 	mov  %i5, %i3                                  <== NOT EXECUTED
     const uint32_t                        offset,                    
     const uint32_t                        count,                     
     const uint8_t                         pattern)                   
{                                                                     
    int                 rc             = RC_OK;                       
    uint32_t            bytes_to_write = MIN(count, (fs_info->vol.bytes_per_block - offset));
4001329c:	80 a6 c0 01 	cmp  %i3, %g1                                  
400132a0:	08 80 00 03 	bleu  400132ac <fat_cluster_set+0x80>          <== ALWAYS TAKEN
400132a4:	b2 10 00 1b 	mov  %i3, %i1                                  
400132a8:	b2 10 00 01 	mov  %g1, %i1                                  <== NOT EXECUTED
    return cmpltd;                                                    
}                                                                     
                                                                      
static ssize_t                                                        
 fat_block_set (                                                      
     fat_fs_info_t                        *fs_info,                   
400132ac:	c2 0e 20 02 	ldub  [ %i0 + 2 ], %g1                         
    int                 rc             = RC_OK;                       
    uint32_t            bytes_to_write = MIN(count, (fs_info->vol.bytes_per_block - offset));
    uint8_t            *blk_buf;                                      
    uint32_t            sec_num        = fat_block_num_to_sector_num(fs_info, start_blk);
                                                                      
    if (0 < bytes_to_write)                                           
400132b0:	80 a6 60 00 	cmp  %i1, 0                                    
400132b4:	02 80 00 14 	be  40013304 <fat_cluster_set+0xd8>            <== NEVER TAKEN
400132b8:	d2 0e 20 0c 	ldub  [ %i0 + 0xc ], %o1                       
                                                                      
static inline uint32_t                                                
 fat_block_num_to_sector_num (const fat_fs_info_t *fs_info,           
                              const uint32_t block_number)            
{                                                                     
  return block_number << (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
400132bc:	92 22 40 01 	sub  %o1, %g1, %o1                             
    {                                                                 
        if (bytes_to_write == fs_info->vol.bytes_per_block)           
        {                                                             
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_GET, &blk_buf);
400132c0:	90 10 00 18 	mov  %i0, %o0                                  
400132c4:	93 2c 40 09 	sll  %l1, %o1, %o1                             
    uint8_t            *blk_buf;                                      
    uint32_t            sec_num        = fat_block_num_to_sector_num(fs_info, start_blk);
                                                                      
    if (0 < bytes_to_write)                                           
    {                                                                 
        if (bytes_to_write == fs_info->vol.bytes_per_block)           
400132c8:	80 a6 40 02 	cmp  %i1, %g2                                  
400132cc:	02 80 00 03 	be  400132d8 <fat_cluster_set+0xac>            
400132d0:	94 10 20 02 	mov  2, %o2                                    
        {                                                             
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_GET, &blk_buf);
        }                                                             
        else                                                          
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_READ, &blk_buf);
400132d4:	94 10 20 01 	mov  1, %o2                                    
400132d8:	7f ff ff 62 	call  40013060 <fat_buf_access>                
400132dc:	96 07 bf fc 	add  %fp, -4, %o3                              
                                                                      
        if (RC_OK == rc)                                              
400132e0:	80 a2 20 00 	cmp  %o0, 0                                    
400132e4:	12 80 00 0a 	bne  4001330c <fat_cluster_set+0xe0>           <== NEVER TAKEN
400132e8:	80 a6 c0 08 	cmp  %i3, %o0                                  
        {                                                             
            memset(blk_buf + offset, pattern, bytes_to_write);        
400132ec:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
400132f0:	92 10 00 1c 	mov  %i4, %o1                                  
400132f4:	90 02 00 1a 	add  %o0, %i2, %o0                             
400132f8:	40 00 26 f9 	call  4001cedc <memset>                        
400132fc:	94 10 00 19 	mov  %i1, %o2                                  
}                                                                     
                                                                      
static inline void                                                    
fat_buf_mark_modified(fat_fs_info_t *fs_info)                         
{                                                                     
    fs_info->c.modified = true;                                       
40013300:	e4 2e 20 88 	stb  %l2, [ %i0 + 0x88 ]                       
        }                                                             
    }                                                                 
    if (RC_OK != rc)                                                  
        return rc;                                                    
    else                                                              
        return bytes_to_write;                                        
40013304:	90 10 00 19 	mov  %i1, %o0                                  
        fs_info,                                                      
        cur_blk,                                                      
        ofs_blk,                                                      
        c,                                                            
        pattern);                                                     
    if (c != ret)                                                     
40013308:	80 a6 c0 08 	cmp  %i3, %o0                                  
4001330c:	12 80 00 06 	bne  40013324 <fat_cluster_set+0xf8>           <== NEVER TAKEN
40013310:	82 10 3f ff 	mov  -1, %g1                                   
      rc = -1;                                                        
    else                                                              
    {                                                                 
        bytes_to_write -= ret;                                        
40013314:	ba 27 40 1b 	sub  %i5, %i3, %i5                             
        bytes_written  += ret;                                        
40013318:	a0 04 00 1b 	add  %l0, %i3, %l0                             
        ++cur_blk;                                                    
4001331c:	a2 04 60 01 	inc  %l1                                       
40013320:	82 10 20 00 	clr  %g1                                       
40013324:	10 bf ff d3 	b  40013270 <fat_cluster_set+0x44>             
40013328:	b4 10 20 00 	clr  %i2                                       
    }                                                                 
    ofs_blk = 0;                                                      
  }                                                                   
  if (RC_OK != rc)                                                    
4001332c:	12 80 00 03 	bne  40013338 <fat_cluster_set+0x10c>          <== NEVER TAKEN
40013330:	b0 10 3f ff 	mov  -1, %i0                                   
40013334:	b0 10 00 10 	mov  %l0, %i0                                  
    return rc;                                                        
  else                                                                
    return bytes_written;                                             
}                                                                     
40013338:	81 c7 e0 08 	ret                                            
4001333c:	81 e8 00 00 	restore                                        
                                                                      

40013340 <fat_cluster_write>: const uint32_t start_cln, const uint32_t offset, const uint32_t count, const void *buff, const bool overwrite_cluster) {
40013340:	9d e3 bf 98 	save  %sp, -104, %sp                           
    ssize_t             rc               = RC_OK;                     
    uint32_t            bytes_to_write   = MIN(count, (fs_info->vol.bpc - offset));
40013344:	e0 16 20 06 	lduh  [ %i0 + 6 ], %l0                         
40013348:	a0 24 00 1a 	sub  %l0, %i2, %l0                             
4001334c:	80 a4 00 1b 	cmp  %l0, %i3                                  
40013350:	38 80 00 02 	bgu,a   40013358 <fat_cluster_write+0x18>      
40013354:	a0 10 00 1b 	mov  %i3, %l0                                  
    uint32_t            cur_blk          = fat_cluster_num_to_block_num(fs_info, start_cln);
40013358:	90 10 00 18 	mov  %i0, %o0                                  
4001335c:	7f ff fe bb 	call  40012e48 <fat_cluster_num_to_block_num>  
40013360:	92 10 00 19 	mov  %i1, %o1                                  
    uint32_t            blocks_in_offset = (offset >> fs_info->vol.bytes_per_block_log2);
40013364:	c2 0e 20 0c 	ldub  [ %i0 + 0xc ], %g1                       
    uint32_t            ofs_blk          = offset - (blocks_in_offset << fs_info->vol.bytes_per_block_log2);
    ssize_t             bytes_written    = 0;                         
40013368:	a2 10 20 00 	clr  %l1                                       
    const bool                            overwrite_cluster)          
{                                                                     
    ssize_t             rc               = RC_OK;                     
    uint32_t            bytes_to_write   = MIN(count, (fs_info->vol.bpc - offset));
    uint32_t            cur_blk          = fat_cluster_num_to_block_num(fs_info, start_cln);
    uint32_t            blocks_in_offset = (offset >> fs_info->vol.bytes_per_block_log2);
4001336c:	a5 36 80 01 	srl  %i2, %g1, %l2                             
    uint32_t            ofs_blk          = offset - (blocks_in_offset << fs_info->vol.bytes_per_block_log2);
40013370:	83 2c 80 01 	sll  %l2, %g1, %g1                             
40013374:	a6 10 20 01 	mov  1, %l3                                    
40013378:	b4 26 80 01 	sub  %i2, %g1, %i2                             
    ssize_t             bytes_written    = 0;                         
    uint8_t             *buffer          = (uint8_t*)buff;            
    ssize_t             ret;                                          
    uint32_t            c;                                            
                                                                      
    cur_blk += blocks_in_offset;                                      
4001337c:	a4 02 00 12 	add  %o0, %l2, %l2                             
    const uint32_t                        offset,                     
    const uint32_t                        count,                      
    const void                           *buff,                       
    const bool                            overwrite_cluster)          
{                                                                     
    ssize_t             rc               = RC_OK;                     
40013380:	82 10 20 00 	clr  %g1                                       
    ssize_t             ret;                                          
    uint32_t            c;                                            
                                                                      
    cur_blk += blocks_in_offset;                                      
                                                                      
    while (   (RC_OK == rc)                                           
40013384:	80 a4 20 00 	cmp  %l0, 0                                    
40013388:	02 80 00 30 	be  40013448 <fat_cluster_write+0x108>         
4001338c:	80 a0 60 00 	cmp  %g1, 0                                    
40013390:	32 80 00 31 	bne,a   40013454 <fat_cluster_write+0x114>     <== NEVER TAKEN
40013394:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
           && (0 < bytes_to_write))                                   
    {                                                                 
      c = MIN(bytes_to_write, (fs_info->vol.bytes_per_block - ofs_blk));
40013398:	c4 16 20 0a 	lduh  [ %i0 + 0xa ], %g2                       
4001339c:	82 20 80 1a 	sub  %g2, %i2, %g1                             
400133a0:	80 a0 40 10 	cmp  %g1, %l0                                  
400133a4:	08 80 00 03 	bleu  400133b0 <fat_cluster_write+0x70>        
400133a8:	b6 10 00 01 	mov  %g1, %i3                                  
400133ac:	b6 10 00 10 	mov  %l0, %i3                                  
    const uint32_t                        count,                      
    const void                           *buf,                        
    const bool                            overwrite_block)            
{                                                                     
    int                 rc             = RC_OK;                       
    uint32_t            bytes_to_write = MIN(count, (fs_info->vol.bytes_per_block - offset));
400133b0:	80 a6 c0 01 	cmp  %i3, %g1                                  
400133b4:	08 80 00 03 	bleu  400133c0 <fat_cluster_write+0x80>        <== ALWAYS TAKEN
400133b8:	b2 10 00 1b 	mov  %i3, %i1                                  
400133bc:	b2 10 00 01 	mov  %g1, %i1                                  <== NOT EXECUTED
    return cmpltd;                                                    
}                                                                     
                                                                      
static ssize_t                                                        
 fat_block_write(                                                     
    fat_fs_info_t                        *fs_info,                    
400133c0:	c2 0e 20 02 	ldub  [ %i0 + 2 ], %g1                         
    int                 rc             = RC_OK;                       
    uint32_t            bytes_to_write = MIN(count, (fs_info->vol.bytes_per_block - offset));
    uint8_t            *blk_buf;                                      
    uint32_t            sec_num        = fat_block_num_to_sector_num(fs_info, start_blk);
                                                                      
    if (0 < bytes_to_write)                                           
400133c4:	80 a6 60 00 	cmp  %i1, 0                                    
400133c8:	02 80 00 16 	be  40013420 <fat_cluster_write+0xe0>          <== NEVER TAKEN
400133cc:	d2 0e 20 0c 	ldub  [ %i0 + 0xc ], %o1                       
                                                                      
static inline uint32_t                                                
 fat_block_num_to_sector_num (const fat_fs_info_t *fs_info,           
                              const uint32_t block_number)            
{                                                                     
  return block_number << (fs_info->vol.bytes_per_block_log2 - fs_info->vol.sec_log2);
400133d0:	92 22 40 01 	sub  %o1, %g1, %o1                             
    {                                                                 
        if (   overwrite_block                                        
            || (bytes_to_write == fs_info->vol.bytes_per_block))      
        {                                                             
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_GET, &blk_buf);
400133d4:	90 10 00 18 	mov  %i0, %o0                                  
    uint8_t            *blk_buf;                                      
    uint32_t            sec_num        = fat_block_num_to_sector_num(fs_info, start_blk);
                                                                      
    if (0 < bytes_to_write)                                           
    {                                                                 
        if (   overwrite_block                                        
400133d8:	80 a7 60 00 	cmp  %i5, 0                                    
400133dc:	12 80 00 05 	bne  400133f0 <fat_cluster_write+0xb0>         
400133e0:	93 2c 80 09 	sll  %l2, %o1, %o1                             
            || (bytes_to_write == fs_info->vol.bytes_per_block))      
400133e4:	80 a6 40 02 	cmp  %i1, %g2                                  
400133e8:	12 80 00 03 	bne  400133f4 <fat_cluster_write+0xb4>         
400133ec:	94 10 20 01 	mov  1, %o2                                    
        {                                                             
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_GET, &blk_buf);
400133f0:	94 10 20 02 	mov  2, %o2                                    
        }                                                             
        else                                                          
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_READ, &blk_buf);
400133f4:	7f ff ff 1b 	call  40013060 <fat_buf_access>                
400133f8:	96 07 bf fc 	add  %fp, -4, %o3                              
                                                                      
        if (RC_OK == rc)                                              
400133fc:	80 a2 20 00 	cmp  %o0, 0                                    
40013400:	12 80 00 0a 	bne  40013428 <fat_cluster_write+0xe8>         <== NEVER TAKEN
40013404:	80 a6 c0 08 	cmp  %i3, %o0                                  
        {                                                             
            memcpy(blk_buf + offset, buf, bytes_to_write);            
40013408:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
4001340c:	92 07 00 11 	add  %i4, %l1, %o1                             
40013410:	90 02 00 1a 	add  %o0, %i2, %o0                             
40013414:	40 00 26 73 	call  4001cde0 <memcpy>                        
40013418:	94 10 00 19 	mov  %i1, %o2                                  
}                                                                     
                                                                      
static inline void                                                    
fat_buf_mark_modified(fat_fs_info_t *fs_info)                         
{                                                                     
    fs_info->c.modified = true;                                       
4001341c:	e6 2e 20 88 	stb  %l3, [ %i0 + 0x88 ]                       
        }                                                             
    }                                                                 
    if (RC_OK != rc)                                                  
        return rc;                                                    
    else                                                              
        return bytes_to_write;                                        
40013420:	90 10 00 19 	mov  %i1, %o0                                  
          cur_blk,                                                    
          ofs_blk,                                                    
          c,                                                          
          &buffer[bytes_written],                                     
          overwrite_cluster);                                         
      if (c != ret)                                                   
40013424:	80 a6 c0 08 	cmp  %i3, %o0                                  
40013428:	12 80 00 06 	bne  40013440 <fat_cluster_write+0x100>        <== NEVER TAKEN
4001342c:	82 10 3f ff 	mov  -1, %g1                                   
        rc = -1;                                                      
      else                                                            
      {                                                               
          bytes_to_write -= ret;                                      
40013430:	a0 24 00 1b 	sub  %l0, %i3, %l0                             
          bytes_written  += ret;                                      
40013434:	a2 04 40 1b 	add  %l1, %i3, %l1                             
          ++cur_blk;                                                  
40013438:	a4 04 a0 01 	inc  %l2                                       
4001343c:	82 10 20 00 	clr  %g1                                       
40013440:	10 bf ff d1 	b  40013384 <fat_cluster_write+0x44>           
40013444:	b4 10 20 00 	clr  %i2                                       
      }                                                               
      ofs_blk = 0;                                                    
    }                                                                 
    if (RC_OK != rc)                                                  
40013448:	12 80 00 03 	bne  40013454 <fat_cluster_write+0x114>        <== NEVER TAKEN
4001344c:	b0 10 3f ff 	mov  -1, %i0                                   
40013450:	b0 10 00 11 	mov  %l1, %i0                                  
      return rc;                                                      
    else                                                              
      return bytes_written;                                           
}                                                                     
40013454:	81 c7 e0 08 	ret                                            
40013458:	81 e8 00 00 	restore                                        
                                                                      

40012708 <fat_file_close>: int fat_file_close( fat_fs_info_t *fs_info, fat_file_fd_t *fat_fd ) {
40012708:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
    /*                                                                
     * if links_num field of fat-file descriptor is greater than 1    
     * decrement only the count of links                              
     */                                                               
    if (fat_fd->links_num > 1)                                        
4001270c:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
40012710:	80 a0 60 01 	cmp  %g1, 1                                    
40012714:	08 80 00 04 	bleu  40012724 <fat_file_close+0x1c>           
40012718:	82 00 7f ff 	add  %g1, -1, %g1                              
4001271c:	10 80 00 26 	b  400127b4 <fat_file_close+0xac>              
40012720:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]                           
    }                                                                 
    else                                                              
    {                                                                 
        uint32_t key = fat_construct_key(fs_info, &fat_fd->dir_pos.sname);
                                                                      
        if (fat_fd->flags & FAT_FILE_REMOVED)                         
40012724:	c2 0e 60 30 	ldub  [ %i1 + 0x30 ], %g1                      
40012728:	80 88 60 01 	btst  1, %g1                                   
4001272c:	02 80 00 16 	be  40012784 <fat_file_close+0x7c>             
40012730:	90 10 00 18 	mov  %i0, %o0                                  
        {                                                             
            rc = fat_file_truncate(fs_info, fat_fd, 0);               
40012734:	92 10 00 19 	mov  %i1, %o1                                  
40012738:	7f ff ff af 	call  400125f4 <fat_file_truncate>             
4001273c:	94 10 20 00 	clr  %o2                                       
            if (rc == RC_OK)                                          
40012740:	80 a2 20 00 	cmp  %o0, 0                                    
40012744:	12 80 00 1c 	bne  400127b4 <fat_file_close+0xac>            <== NEVER TAKEN
40012748:	01 00 00 00 	nop                                            
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4001274c:	c4 06 40 00 	ld  [ %i1 ], %g2                               
  previous       = the_node->previous;                                
40012750:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
            {                                                         
                _hash_delete(fs_info->rhash, key, fat_fd->ino, fat_fd);
                                                                      
                if (fat_ino_is_unique(fs_info, fat_fd->ino))          
40012754:	d2 06 60 0c 	ld  [ %i1 + 0xc ], %o1                         
  next->previous = previous;                                          
40012758:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4001275c:	c4 20 40 00 	st  %g2, [ %g1 ]                               
40012760:	40 00 06 00 	call  40013f60 <fat_ino_is_unique>             
40012764:	90 10 00 18 	mov  %i0, %o0                                  
40012768:	80 a2 20 00 	cmp  %o0, 0                                    
4001276c:	02 80 00 10 	be  400127ac <fat_file_close+0xa4>             <== ALWAYS TAKEN
40012770:	01 00 00 00 	nop                                            
                    fat_free_unique_ino(fs_info, fat_fd->ino);        
40012774:	d2 06 60 0c 	ld  [ %i1 + 0xc ], %o1                         <== NOT EXECUTED
40012778:	40 00 05 ef 	call  40013f34 <fat_free_unique_ino>           <== NOT EXECUTED
4001277c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40012780:	30 80 00 0b 	b,a   400127ac <fat_file_close+0xa4>           <== NOT EXECUTED
                free(fat_fd);                                         
            }                                                         
        }                                                             
        else                                                          
        {                                                             
            if (fat_ino_is_unique(fs_info, fat_fd->ino))              
40012784:	40 00 05 f7 	call  40013f60 <fat_ino_is_unique>             
40012788:	d2 06 60 0c 	ld  [ %i1 + 0xc ], %o1                         
4001278c:	80 a2 20 00 	cmp  %o0, 0                                    
40012790:	22 80 00 04 	be,a   400127a0 <fat_file_close+0x98>          
40012794:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40012798:	10 80 00 07 	b  400127b4 <fat_file_close+0xac>              
4001279c:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
400127a0:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
  next->previous = previous;                                          
400127a4:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
400127a8:	c4 20 40 00 	st  %g2, [ %g1 ]                               
                fat_fd->links_num = 0;                                
            }                                                         
            else                                                      
            {                                                         
                _hash_delete(fs_info->vhash, key, fat_fd->ino, fat_fd);
                free(fat_fd);                                         
400127ac:	7f ff c9 8a 	call  40004dd4 <free>                          
400127b0:	90 10 00 19 	mov  %i1, %o0                                  
    }                                                                 
                                                                      
    /*                                                                
     * flush any modified "cached" buffer back to disk                
     */                                                               
    rc = fat_buf_release(fs_info);                                    
400127b4:	40 00 01 ba 	call  40012e9c <fat_buf_release>               
400127b8:	81 e8 00 00 	restore                                        
                                                                      

40012890 <fat_file_extend>: fat_file_fd_t *fat_fd, bool zero_fill, uint32_t new_length, uint32_t *a_length ) {
40012890:	9d e3 bf 90 	save  %sp, -112, %sp                           
    uint32_t       last_cl = 0;                                       
    uint32_t       bytes_remain = 0;                                  
    uint32_t       cls_added;                                         
    ssize_t        bytes_written;                                     
                                                                      
    *a_length = new_length;                                           
40012894:	f6 27 00 00 	st  %i3, [ %i4 ]                               
                                                                      
    if (new_length <= fat_fd->fat_file_size)                          
40012898:	c2 06 60 18 	ld  [ %i1 + 0x18 ], %g1                        
    uint32_t                              new_length,                 
    uint32_t                             *a_length                    
    )                                                                 
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       chain = 0;                                         
4001289c:	c0 27 bf f0 	clr  [ %fp + -16 ]                             
    uint32_t       bytes2add = 0;                                     
    uint32_t       cls2add = 0;                                       
    uint32_t       old_last_cl;                                       
    uint32_t       last_cl = 0;                                       
400128a0:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
    uint32_t       cls_added;                                         
    ssize_t        bytes_written;                                     
                                                                      
    *a_length = new_length;                                           
                                                                      
    if (new_length <= fat_fd->fat_file_size)                          
400128a4:	80 a6 c0 01 	cmp  %i3, %g1                                  
400128a8:	08 80 00 86 	bleu  40012ac0 <fat_file_extend+0x230>         
400128ac:	ba 10 00 18 	mov  %i0, %i5                                  
        return RC_OK;                                                 
                                                                      
    if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                               
400128b0:	c4 06 60 20 	ld  [ %i1 + 0x20 ], %g2                        
400128b4:	80 a0 a0 01 	cmp  %g2, 1                                    
400128b8:	32 80 00 0b 	bne,a   400128e4 <fat_file_extend+0x54>        
400128bc:	e0 17 60 06 	lduh  [ %i5 + 6 ], %l0                         
400128c0:	c4 06 60 24 	ld  [ %i1 + 0x24 ], %g2                        
400128c4:	80 a0 a0 00 	cmp  %g2, 0                                    
400128c8:	32 80 00 07 	bne,a   400128e4 <fat_file_extend+0x54>        <== NEVER TAKEN
400128cc:	e0 17 60 06 	lduh  [ %i5 + 6 ], %l0                         <== NOT EXECUTED
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
400128d0:	c4 0e 20 0e 	ldub  [ %i0 + 0xe ], %g2                       
    *a_length = new_length;                                           
                                                                      
    if (new_length <= fat_fd->fat_file_size)                          
        return RC_OK;                                                 
                                                                      
    if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                               
400128d4:	80 88 a0 03 	btst  3, %g2                                   
400128d8:	12 80 00 37 	bne  400129b4 <fat_file_extend+0x124>          <== ALWAYS TAKEN
400128dc:	01 00 00 00 	nop                                            
        (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))) &
400128e0:	e0 17 60 06 	lduh  [ %i5 + 6 ], %l0                         <== NOT EXECUTED
400128e4:	84 04 3f ff 	add  %l0, -1, %g2                              
400128e8:	a4 08 80 01 	and  %g2, %g1, %l2                             
                                                                      
    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 -                                
400128ec:	a0 24 00 12 	sub  %l0, %l2, %l0                             
400128f0:	a0 0c 00 02 	and  %l0, %g2, %l0                             
                   (fat_fd->fat_file_size & (fs_info->vol.bpc - 1))) &
                   (fs_info->vol.bpc - 1);                            
                                                                      
    bytes2add = new_length - fat_fd->fat_file_size;                   
400128f4:	84 26 c0 01 	sub  %i3, %g1, %g2                             
                                                                      
    if (bytes2add > bytes_remain)                                     
400128f8:	80 a0 80 10 	cmp  %g2, %l0                                  
400128fc:	08 80 00 03 	bleu  40012908 <fat_file_extend+0x78>          
40012900:	a2 10 20 00 	clr  %l1                                       
        bytes2add -= bytes_remain;                                    
40012904:	a2 20 80 10 	sub  %g2, %l0, %l1                             
    else                                                              
        bytes2add = 0;                                                
                                                                      
    if (zero_fill && bytes_remain > 0) {                              
40012908:	80 a4 20 00 	cmp  %l0, 0                                    
4001290c:	02 80 00 17 	be  40012968 <fat_file_extend+0xd8>            
40012910:	80 a4 60 00 	cmp  %l1, 0                                    
40012914:	80 a6 a0 00 	cmp  %i2, 0                                    
40012918:	02 80 00 14 	be  40012968 <fat_file_extend+0xd8>            
4001291c:	80 a4 60 00 	cmp  %l1, 0                                    
        uint32_t start = fat_fd->fat_file_size;                       
        uint32_t cl_start = start >> fs_info->vol.bpc_log2;           
40012920:	d4 0f 60 08 	ldub  [ %i5 + 8 ], %o2                         
        uint32_t ofs = start & (fs_info->vol.bpc - 1);                
        uint32_t cur_cln;                                             
                                                                      
        rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln);     
40012924:	90 10 00 1d 	mov  %i5, %o0                                  
40012928:	92 10 00 19 	mov  %i1, %o1                                  
4001292c:	95 30 40 0a 	srl  %g1, %o2, %o2                             
40012930:	7f ff fe 3b 	call  4001221c <fat_file_lseek>                
40012934:	96 07 bf fc 	add  %fp, -4, %o3                              
        if (rc != RC_OK)                                              
40012938:	b0 92 60 00 	orcc  %o1, 0, %i0                              
4001293c:	12 80 00 22 	bne  400129c4 <fat_file_extend+0x134>          <== NEVER TAKEN
40012940:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
            return rc;                                                
                                                                      
        bytes_written = fat_cluster_set (fs_info, cur_cln, ofs, bytes_remain, 0);
40012944:	90 10 00 1d 	mov  %i5, %o0                                  
40012948:	94 10 00 12 	mov  %l2, %o2                                  
4001294c:	96 10 00 10 	mov  %l0, %o3                                  
40012950:	98 10 20 00 	clr  %o4                                       
40012954:	40 00 02 36 	call  4001322c <fat_cluster_set>               
40012958:	b0 10 3f ff 	mov  -1, %i0                                   
        if (bytes_remain != bytes_written)                            
4001295c:	80 a4 00 08 	cmp  %l0, %o0                                  
40012960:	12 80 00 19 	bne  400129c4 <fat_file_extend+0x134>          <== NEVER TAKEN
40012964:	80 a4 60 00 	cmp  %l1, 0                                    
    /*                                                                
     * 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)                                               
40012968:	02 80 00 17 	be  400129c4 <fat_file_extend+0x134>           
4001296c:	b0 10 20 00 	clr  %i0                                       
        return RC_OK;                                                 
                                                                      
    cls2add = ((bytes2add - 1) >> fs_info->vol.bpc_log2) + 1;         
40012970:	c2 0f 60 08 	ldub  [ %i5 + 8 ], %g1                         
40012974:	a4 04 7f ff 	add  %l1, -1, %l2                              
                                                                      
    rc = fat_scan_fat_for_free_clusters(fs_info, &chain, cls2add,     
40012978:	90 10 00 1d 	mov  %i5, %o0                                  
     * file ) - return                                                
     */                                                               
    if (bytes2add == 0)                                               
        return RC_OK;                                                 
                                                                      
    cls2add = ((bytes2add - 1) >> fs_info->vol.bpc_log2) + 1;         
4001297c:	a5 34 80 01 	srl  %l2, %g1, %l2                             
                                                                      
    rc = fat_scan_fat_for_free_clusters(fs_info, &chain, cls2add,     
40012980:	92 07 bf f0 	add  %fp, -16, %o1                             
     * file ) - return                                                
     */                                                               
    if (bytes2add == 0)                                               
        return RC_OK;                                                 
                                                                      
    cls2add = ((bytes2add - 1) >> fs_info->vol.bpc_log2) + 1;         
40012984:	a4 04 a0 01 	inc  %l2                                       
                                                                      
    rc = fat_scan_fat_for_free_clusters(fs_info, &chain, cls2add,     
40012988:	96 07 bf fc 	add  %fp, -4, %o3                              
4001298c:	94 10 00 12 	mov  %l2, %o2                                  
40012990:	98 07 bf f8 	add  %fp, -8, %o4                              
40012994:	7f ff fd 90 	call  40011fd4 <fat_scan_fat_for_free_clusters>
40012998:	9a 10 00 1a 	mov  %i2, %o5                                  
                                        &cls_added, &last_cl, zero_fill);
                                                                      
    /* this means that low level I/O error occured */                 
    if (rc != RC_OK)                                                  
4001299c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400129a0:	12 80 00 09 	bne  400129c4 <fat_file_extend+0x134>          <== NEVER TAKEN
400129a4:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
        return rc;                                                    
                                                                      
    /* this means that no space left on device */                     
    if ((cls_added == 0) && (bytes_remain == 0))                      
400129a8:	80 94 00 01 	orcc  %l0, %g1, %g0                            
400129ac:	12 80 00 08 	bne  400129cc <fat_file_extend+0x13c>          
400129b0:	80 a4 80 01 	cmp  %l2, %g1                                  
        rtems_set_errno_and_return_minus_one(ENOSPC);                 
400129b4:	40 00 26 b6 	call  4001c48c <__errno>                       
400129b8:	b0 10 3f ff 	mov  -1, %i0                                   
400129bc:	82 10 20 1c 	mov  0x1c, %g1                                 
400129c0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400129c4:	81 c7 e0 08 	ret                                            
400129c8:	81 e8 00 00 	restore                                        
                                                                      
    /*  check wether we satisfied request for 'cls2add' clusters */   
    if (cls2add != cls_added)                                         
400129cc:	02 80 00 08 	be  400129ec <fat_file_extend+0x15c>           
400129d0:	a4 24 80 01 	sub  %l2, %g1, %l2                             
    {                                                                 
        uint32_t missing = (cls2add - cls_added) << fs_info->vol.bpc_log2;
400129d4:	c4 0f 60 08 	ldub  [ %i5 + 8 ], %g2                         
400129d8:	a5 2c 80 02 	sll  %l2, %g2, %l2                             
                                                                      
        new_length -= bytes2add < missing ? bytes2add : missing;      
400129dc:	80 a4 80 11 	cmp  %l2, %l1                                  
400129e0:	38 80 00 02 	bgu,a   400129e8 <fat_file_extend+0x158>       <== ALWAYS TAKEN
400129e4:	a4 10 00 11 	mov  %l1, %l2                                  
400129e8:	b6 26 c0 12 	sub  %i3, %l2, %i3                             
    }                                                                 
                                                                      
    if (cls_added > 0)                                                
400129ec:	80 a0 60 00 	cmp  %g1, 0                                    
400129f0:	22 80 00 33 	be,a   40012abc <fat_file_extend+0x22c>        
400129f4:	f6 27 00 00 	st  %i3, [ %i4 ]                               
    {                                                                 
        /* add new chain to the end of existing */                    
        if ( fat_fd->fat_file_size == 0 )                             
400129f8:	d6 06 60 18 	ld  [ %i1 + 0x18 ], %o3                        
400129fc:	80 a2 e0 00 	cmp  %o3, 0                                    
40012a00:	32 80 00 07 	bne,a   40012a1c <fat_file_extend+0x18c>       
40012a04:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
        {                                                             
            fat_fd->map.disk_cln = fat_fd->cln = chain;               
40012a08:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
            fat_fd->map.file_cln = 0;                                 
40012a0c:	c0 26 60 34 	clr  [ %i1 + 0x34 ]                            
    if (cls_added > 0)                                                
    {                                                                 
        /* add new chain to the end of existing */                    
        if ( fat_fd->fat_file_size == 0 )                             
        {                                                             
            fat_fd->map.disk_cln = fat_fd->cln = chain;               
40012a10:	c2 26 60 1c 	st  %g1, [ %i1 + 0x1c ]                        
40012a14:	10 80 00 19 	b  40012a78 <fat_file_extend+0x1e8>            
40012a18:	c2 26 60 38 	st  %g1, [ %i1 + 0x38 ]                        
            fat_fd->map.file_cln = 0;                                 
        }                                                             
        else                                                          
        {                                                             
            if (fat_fd->map.last_cln != FAT_UNDEFINED_VALUE)          
40012a1c:	80 a0 7f ff 	cmp  %g1, -1                                   
40012a20:	22 80 00 04 	be,a   40012a30 <fat_file_extend+0x1a0>        <== NEVER TAKEN
40012a24:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40012a28:	10 80 00 0a 	b  40012a50 <fat_file_extend+0x1c0>            
40012a2c:	c2 27 bf f4 	st  %g1, [ %fp + -12 ]                         
            {                                                         
                old_last_cl = fat_fd->map.last_cln;                   
            }                                                         
            else                                                      
            {                                                         
                rc = fat_file_ioctl(fs_info, fat_fd, F_CLU_NUM,       
40012a30:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
40012a34:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
40012a38:	96 02 ff ff 	add  %o3, -1, %o3                              <== NOT EXECUTED
40012a3c:	7f ff ff 60 	call  400127bc <fat_file_ioctl>                <== NOT EXECUTED
40012a40:	98 07 bf f4 	add  %fp, -12, %o4                             <== NOT EXECUTED
                                    (fat_fd->fat_file_size - 1), &old_last_cl);
                if ( rc != RC_OK )                                    
40012a44:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
40012a48:	32 80 00 19 	bne,a   40012aac <fat_file_extend+0x21c>       <== NOT EXECUTED
40012a4c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                    fat_free_fat_clusters_chain(fs_info, chain);      
                    return rc;                                        
                }                                                     
            }                                                         
                                                                      
            rc = fat_set_fat_cluster(fs_info, old_last_cl, chain);    
40012a50:	d2 07 bf f4 	ld  [ %fp + -12 ], %o1                         
40012a54:	d4 07 bf f0 	ld  [ %fp + -16 ], %o2                         
40012a58:	7f ff fc 91 	call  40011c9c <fat_set_fat_cluster>           
40012a5c:	90 10 00 1d 	mov  %i5, %o0                                  
40012a60:	b0 10 00 08 	mov  %o0, %i0                                  
            if ( rc != RC_OK )                                        
40012a64:	80 a6 20 00 	cmp  %i0, 0                                    
40012a68:	12 80 00 11 	bne  40012aac <fat_file_extend+0x21c>          <== NEVER TAKEN
40012a6c:	90 10 00 1d 	mov  %i5, %o0                                  
            {                                                         
                fat_free_fat_clusters_chain(fs_info, chain);          
                return rc;                                            
            }                                                         
            fat_buf_release(fs_info);                                 
40012a70:	40 00 01 0b 	call  40012e9c <fat_buf_release>               
40012a74:	01 00 00 00 	nop                                            
        }                                                             
                                                                      
        /* update number of the last cluster of the file */           
        fat_fd->map.last_cln = last_cl;                               
40012a78:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
40012a7c:	c2 26 60 3c 	st  %g1, [ %i1 + 0x3c ]                        
                                                                      
        if (fat_fd->fat_file_type == FAT_DIRECTORY)                   
40012a80:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
40012a84:	80 a0 60 00 	cmp  %g1, 0                                    
40012a88:	32 80 00 0d 	bne,a   40012abc <fat_file_extend+0x22c>       
40012a8c:	f6 27 00 00 	st  %i3, [ %i4 ]                               
        {                                                             
            rc = fat_init_clusters_chain(fs_info, chain);             
40012a90:	d2 07 bf f0 	ld  [ %fp + -16 ], %o1                         
40012a94:	40 00 04 db 	call  40013e00 <fat_init_clusters_chain>       
40012a98:	90 10 00 1d 	mov  %i5, %o0                                  
            if ( rc != RC_OK )                                        
40012a9c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40012aa0:	22 80 00 07 	be,a   40012abc <fat_file_extend+0x22c>        <== ALWAYS TAKEN
40012aa4:	f6 27 00 00 	st  %i3, [ %i4 ]                               
            {                                                         
                fat_free_fat_clusters_chain(fs_info, chain);          
40012aa8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40012aac:	7f ff fd 1a 	call  40011f14 <fat_free_fat_clusters_chain>   <== NOT EXECUTED
40012ab0:	d2 07 bf f0 	ld  [ %fp + -16 ], %o1                         <== NOT EXECUTED
                return rc;                                            
40012ab4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012ab8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
            }                                                         
        }                                                             
    }                                                                 
                                                                      
    *a_length = new_length;                                           
    fat_fd->fat_file_size = new_length;                               
40012abc:	f6 26 60 18 	st  %i3, [ %i1 + 0x18 ]                        
                                                                      
    return RC_OK;                                                     
40012ac0:	b0 10 20 00 	clr  %i0                                       
}                                                                     
40012ac4:	81 c7 e0 08 	ret                                            
40012ac8:	81 e8 00 00 	restore                                        
                                                                      

400127bc <fat_file_ioctl>: fat_file_ioctl( fat_fs_info_t *fs_info, fat_file_fd_t *fat_fd, int cmd, ...) {
400127bc:	9d e3 bf 98 	save  %sp, -104, %sp                           
    uint32_t       cl_start = 0;                                      
    uint32_t       pos = 0;                                           
    uint32_t      *ret;                                               
    va_list        ap;                                                
                                                                      
    va_start(ap, cmd);                                                
400127c0:	82 07 a0 50 	add  %fp, 0x50, %g1                            
400127c4:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
400127c8:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        
400127cc:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        
    fat_file_fd_t                        *fat_fd,                     
    int                                   cmd,                        
    ...)                                                              
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cur_cln = 0;                                       
400127d0:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
    uint32_t      *ret;                                               
    va_list        ap;                                                
                                                                      
    va_start(ap, cmd);                                                
                                                                      
    switch (cmd)                                                      
400127d4:	80 a6 a0 01 	cmp  %i2, 1                                    
400127d8:	12 80 00 27 	bne  40012874 <fat_file_ioctl+0xb8>            <== NEVER TAKEN
400127dc:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
    {                                                                 
        case F_CLU_NUM:                                               
            pos = va_arg(ap, uint32_t);                               
            ret = va_arg(ap, uint32_t *);                             
400127e0:	82 07 a0 58 	add  %fp, 0x58, %g1                            
400127e4:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
                                                                      
            /* sanity check */                                        
            if ( pos >= fat_fd->fat_file_size ) {                     
400127e8:	c2 06 60 18 	ld  [ %i1 + 0x18 ], %g1                        
400127ec:	80 a6 c0 01 	cmp  %i3, %g1                                  
400127f0:	0a 80 00 08 	bcs  40012810 <fat_file_ioctl+0x54>            <== ALWAYS TAKEN
400127f4:	ba 10 00 1c 	mov  %i4, %i5                                  
                va_end(ap);                                           
                rtems_set_errno_and_return_minus_one( EIO );          
400127f8:	40 00 27 25 	call  4001c48c <__errno>                       <== NOT EXECUTED
400127fc:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012800:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40012804:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40012808:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001280c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
            }                                                         
                                                                      
            if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                       
40012810:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40012814:	80 a0 60 01 	cmp  %g1, 1                                    
40012818:	32 80 00 0d 	bne,a   4001284c <fat_file_ioctl+0x90>         
4001281c:	d4 0e 20 08 	ldub  [ %i0 + 8 ], %o2                         
40012820:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
40012824:	80 a0 60 00 	cmp  %g1, 0                                    
40012828:	32 80 00 09 	bne,a   4001284c <fat_file_ioctl+0x90>         <== NEVER TAKEN
4001282c:	d4 0e 20 08 	ldub  [ %i0 + 8 ], %o2                         <== NOT EXECUTED
                (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))        
40012830:	c2 0e 20 0e 	ldub  [ %i0 + 0xe ], %g1                       
            if ( pos >= fat_fd->fat_file_size ) {                     
                va_end(ap);                                           
                rtems_set_errno_and_return_minus_one( EIO );          
            }                                                         
                                                                      
            if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                       
40012834:	80 88 60 03 	btst  3, %g1                                   
40012838:	22 80 00 05 	be,a   4001284c <fat_file_ioctl+0x90>          
4001283c:	d4 0e 20 08 	ldub  [ %i0 + 8 ], %o2                         
                (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))        
            {                                                         
                /* cluster 0 (zero) reserved for root dir */          
                *ret  = 0;                                            
40012840:	c0 27 00 00 	clr  [ %i4 ]                                   
                rc = RC_OK;                                           
                break;                                                
40012844:	10 80 00 11 	b  40012888 <fat_file_ioctl+0xcc>              
40012848:	92 10 20 00 	clr  %o1                                       
            }                                                         
                                                                      
            cl_start = pos >> fs_info->vol.bpc_log2;                  
                                                                      
            rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln); 
4001284c:	90 10 00 18 	mov  %i0, %o0                                  
40012850:	92 10 00 19 	mov  %i1, %o1                                  
40012854:	95 36 c0 0a 	srl  %i3, %o2, %o2                             
40012858:	7f ff fe 71 	call  4001221c <fat_file_lseek>                
4001285c:	96 07 bf f8 	add  %fp, -8, %o3                              
            if ( rc != RC_OK )                                        
40012860:	80 a2 60 00 	cmp  %o1, 0                                    
40012864:	12 80 00 09 	bne  40012888 <fat_file_ioctl+0xcc>            <== NEVER TAKEN
40012868:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
                break;                                                
                                                                      
            *ret = cur_cln;                                           
            break;                                                    
4001286c:	10 80 00 07 	b  40012888 <fat_file_ioctl+0xcc>              
40012870:	c2 27 40 00 	st  %g1, [ %i5 ]                               
                                                                      
        default:                                                      
            errno = EINVAL;                                           
40012874:	40 00 27 06 	call  4001c48c <__errno>                       <== NOT EXECUTED
40012878:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001287c:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
            rc = -1;                                                  
40012880:	92 10 3f ff 	mov  -1, %o1                                   <== NOT EXECUTED
                                                                      
            *ret = cur_cln;                                           
            break;                                                    
                                                                      
        default:                                                      
            errno = EINVAL;                                           
40012884:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
            rc = -1;                                                  
            break;                                                    
    }                                                                 
    va_end(ap);                                                       
    return rc;                                                        
}                                                                     
40012888:	81 c7 e0 08 	ret                                            
4001288c:	91 e8 00 09 	restore  %g0, %o1, %o0                         
                                                                      

4001221c <fat_file_lseek>: fat_fs_info_t *fs_info, fat_file_fd_t *fat_fd, uint32_t file_cln, uint32_t *disk_cln ) {
4001221c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int rc = RC_OK;                                                   
                                                                      
    if (file_cln == fat_fd->map.file_cln)                             
40012220:	c2 06 60 34 	ld  [ %i1 + 0x34 ], %g1                        
40012224:	80 a6 80 01 	cmp  %i2, %g1                                  
40012228:	12 80 00 05 	bne  4001223c <fat_file_lseek+0x20>            
4001222c:	01 00 00 00 	nop                                            
        *disk_cln = fat_fd->map.disk_cln;                             
40012230:	c2 06 60 38 	ld  [ %i1 + 0x38 ], %g1                        
40012234:	10 80 00 1a 	b  4001229c <fat_file_lseek+0x80>              
40012238:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
    {                                                                 
        uint32_t   cur_cln;                                           
        uint32_t   count;                                             
        uint32_t   i;                                                 
                                                                      
        if (file_cln > fat_fd->map.file_cln)                          
4001223c:	28 80 00 06 	bleu,a   40012254 <fat_file_lseek+0x38>        
40012240:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
        {                                                             
            cur_cln = fat_fd->map.disk_cln;                           
40012244:	c4 06 60 38 	ld  [ %i1 + 0x38 ], %g2                        
            count = file_cln - fat_fd->map.file_cln;                  
40012248:	b8 26 80 01 	sub  %i2, %g1, %i4                             
4001224c:	10 80 00 04 	b  4001225c <fat_file_lseek+0x40>              
40012250:	c4 27 bf fc 	st  %g2, [ %fp + -4 ]                          
        }                                                             
        else                                                          
        {                                                             
            cur_cln = fat_fd->cln;                                    
40012254:	b8 10 00 1a 	mov  %i2, %i4                                  
40012258:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
            count = file_cln;                                         
        }                                                             
                                                                      
        /* skip over the clusters */                                  
        for (i = 0; i < count; i++)                                   
4001225c:	ba 10 20 00 	clr  %i5                                       
40012260:	80 a7 40 1c 	cmp  %i5, %i4                                  
40012264:	02 80 00 0b 	be  40012290 <fat_file_lseek+0x74>             
40012268:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
        {                                                             
            rc = fat_get_fat_cluster(fs_info, cur_cln, &cur_cln);     
4001226c:	90 10 00 18 	mov  %i0, %o0                                  
40012270:	7f ff fe 1d 	call  40011ae4 <fat_get_fat_cluster>           
40012274:	94 07 bf fc 	add  %fp, -4, %o2                              
            if ( rc != RC_OK )                                        
40012278:	80 a2 20 00 	cmp  %o0, 0                                    
4001227c:	22 bf ff f9 	be,a   40012260 <fat_file_lseek+0x44>          <== ALWAYS TAKEN
40012280:	ba 07 60 01 	inc  %i5                                       
                return rc;                                            
40012284:	b1 3a 20 1f 	sra  %o0, 0x1f, %i0                            <== NOT EXECUTED
40012288:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001228c:	93 e8 00 08 	restore  %g0, %o0, %o1                         <== NOT EXECUTED
        }                                                             
                                                                      
        /* update cache */                                            
        fat_fd->map.file_cln = file_cln;                              
40012290:	f4 26 60 34 	st  %i2, [ %i1 + 0x34 ]                        
        fat_fd->map.disk_cln = cur_cln;                               
40012294:	d2 26 60 38 	st  %o1, [ %i1 + 0x38 ]                        
                                                                      
        *disk_cln = cur_cln;                                          
40012298:	d2 26 c0 00 	st  %o1, [ %i3 ]                               
    }                                                                 
    return RC_OK;                                                     
4001229c:	b0 10 20 00 	clr  %i0                                       
}                                                                     
400122a0:	81 c7 e0 08 	ret                                            
400122a4:	93 e8 20 00 	restore  %g0, 0, %o1                           
                                                                      

400122a8 <fat_file_open>: fat_file_open( fat_fs_info_t *fs_info, fat_dir_pos_t *dir_pos, fat_file_fd_t **fat_fd ) {
400122a8:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int            rc = RC_OK;                                        
    fat_file_fd_t *lfat_fd = NULL;                                    
    uint32_t       key = 0;                                           
                                                                      
    /* construct key */                                               
    key = fat_construct_key(fs_info, &dir_pos->sname);                
400122ac:	90 10 00 18 	mov  %i0, %o0                                  
400122b0:	7f ff ff ca 	call  400121d8 <fat_construct_key>             
400122b4:	92 10 00 19 	mov  %i1, %o1                                  
    uint32_t                               key1,                      
    uint32_t                               key2,                      
    fat_file_fd_t                          **ret                      
    )                                                                 
{                                                                     
    uint32_t          mod = (key1) % FAT_HASH_MODULE;                 
400122b8:	82 0a 20 01 	and  %o0, 1, %g1                               
    rtems_chain_node *the_node = rtems_chain_first(hash + mod);       
400122bc:	85 28 60 02 	sll  %g1, 2, %g2                               
400122c0:	b7 28 60 04 	sll  %g1, 4, %i3                               
400122c4:	c2 06 20 6c 	ld  [ %i0 + 0x6c ], %g1                        
400122c8:	b6 26 c0 02 	sub  %i3, %g2, %i3                             
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
400122cc:	fa 00 40 1b 	ld  [ %g1 + %i3 ], %i5                         
400122d0:	a0 00 40 1b 	add  %g1, %i3, %l0                             
    int            rc = RC_OK;                                        
    fat_file_fd_t *lfat_fd = NULL;                                    
    uint32_t       key = 0;                                           
                                                                      
    /* construct key */                                               
    key = fat_construct_key(fs_info, &dir_pos->sname);                
400122d4:	b8 10 00 08 	mov  %o0, %i4                                  
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(                             
  const Chain_Control *the_chain,                                     
  const Chain_Node    *the_node                                       
)                                                                     
{                                                                     
  return (the_node == _Chain_Immutable_tail( the_chain ));            
400122d8:	a0 04 20 04 	add  %l0, 4, %l0                               
    )                                                                 
{                                                                     
    uint32_t          mod = (key1) % FAT_HASH_MODULE;                 
    rtems_chain_node *the_node = rtems_chain_first(hash + mod);       
                                                                      
    for ( ; !rtems_chain_is_tail((hash) + mod, the_node) ; )          
400122dc:	80 a7 40 10 	cmp  %i5, %l0                                  
400122e0:	02 80 00 0e 	be  40012318 <fat_file_open+0x70>              
400122e4:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        fat_file_fd_t *ffd = (fat_file_fd_t *)the_node;               
        uint32_t       ck =  fat_construct_key(fs_info, &ffd->dir_pos.sname);
400122e8:	7f ff ff bc 	call  400121d8 <fat_construct_key>             
400122ec:	92 07 60 20 	add  %i5, 0x20, %o1                            
                                                                      
        if ( (key1) == ck)                                            
400122f0:	80 a7 00 08 	cmp  %i4, %o0                                  
400122f4:	22 80 00 04 	be,a   40012304 <fat_file_open+0x5c>           
400122f8:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
            {                                                         
                *ret = (void *)the_node;                              
                return 0;                                             
            }                                                         
        }                                                             
        the_node = the_node->next;                                    
400122fc:	10 bf ff f8 	b  400122dc <fat_file_open+0x34>               
40012300:	fa 07 40 00 	ld  [ %i5 ], %i5                               
    /* access "valid" hash table */                                   
    rc = _hash_search(fs_info, fs_info->vhash, key, 0, &lfat_fd);     
    if ( rc == RC_OK )                                                
    {                                                                 
        /* return pointer to fat_file_descriptor allocated before */  
        (*fat_fd) = lfat_fd;                                          
40012304:	fa 26 80 00 	st  %i5, [ %i2 ]                               
        lfat_fd->links_num++;                                         
40012308:	82 00 60 01 	inc  %g1                                       
4001230c:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
        return rc;                                                    
40012310:	81 c7 e0 08 	ret                                            
40012314:	91 e8 20 00 	restore  %g0, 0, %o0                           
    uint32_t                               key2,                      
    fat_file_fd_t                          **ret                      
    )                                                                 
{                                                                     
    uint32_t          mod = (key1) % FAT_HASH_MODULE;                 
    rtems_chain_node *the_node = rtems_chain_first(hash + mod);       
40012318:	c2 06 20 70 	ld  [ %i0 + 0x70 ], %g1                        
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4001231c:	fa 00 40 1b 	ld  [ %g1 + %i3 ], %i5                         
40012320:	a0 00 40 1b 	add  %g1, %i3, %l0                             
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(                             
  const Chain_Control *the_chain,                                     
  const Chain_Node    *the_node                                       
)                                                                     
{                                                                     
  return (the_node == _Chain_Immutable_tail( the_chain ));            
40012324:	a0 04 20 04 	add  %l0, 4, %l0                               
                                                                      
    for ( ; !rtems_chain_is_tail((hash) + mod, the_node) ; )          
40012328:	80 a7 40 10 	cmp  %i5, %l0                                  
4001232c:	02 80 00 10 	be  4001236c <fat_file_open+0xc4>              <== ALWAYS TAKEN
40012330:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        fat_file_fd_t *ffd = (fat_file_fd_t *)the_node;               
        uint32_t       ck =  fat_construct_key(fs_info, &ffd->dir_pos.sname);
40012334:	7f ff ff a9 	call  400121d8 <fat_construct_key>             <== NOT EXECUTED
40012338:	92 07 60 20 	add  %i5, 0x20, %o1                            <== NOT EXECUTED
                                                                      
        if ( (key1) == ck)                                            
4001233c:	80 a7 00 08 	cmp  %i4, %o0                                  <== NOT EXECUTED
40012340:	32 bf ff fa 	bne,a   40012328 <fat_file_open+0x80>          <== NOT EXECUTED
40012344:	fa 07 40 00 	ld  [ %i5 ], %i5                               <== NOT EXECUTED
        {                                                             
            if ( ((key2) == 0) || ((key2) == ffd->ino) )              
40012348:	80 a7 20 00 	cmp  %i4, 0                                    <== NOT EXECUTED
4001234c:	22 80 00 09 	be,a   40012370 <fat_file_open+0xc8>           <== NOT EXECUTED
40012350:	a0 10 20 00 	clr  %l0                                       <== NOT EXECUTED
40012354:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         <== NOT EXECUTED
40012358:	80 a7 00 01 	cmp  %i4, %g1                                  <== NOT EXECUTED
4001235c:	22 80 00 05 	be,a   40012370 <fat_file_open+0xc8>           <== NOT EXECUTED
40012360:	a0 10 20 00 	clr  %l0                                       <== NOT EXECUTED
            {                                                         
                *ret = (void *)the_node;                              
                return 0;                                             
            }                                                         
        }                                                             
        the_node = the_node->next;                                    
40012364:	10 bf ff f1 	b  40012328 <fat_file_open+0x80>               <== NOT EXECUTED
40012368:	fa 07 40 00 	ld  [ %i5 ], %i5                               <== NOT EXECUTED
4001236c:	a0 10 3f ff 	mov  -1, %l0                                   
    }                                                                 
                                                                      
    /* access "removed-but-still-open" hash table */                  
    rc = _hash_search(fs_info, fs_info->rhash, key, key, &lfat_fd);   
                                                                      
    lfat_fd = (*fat_fd) = (fat_file_fd_t*)malloc(sizeof(fat_file_fd_t));
40012370:	7f ff cb cb 	call  4000529c <malloc>                        
40012374:	90 10 20 44 	mov  0x44, %o0                                 
40012378:	d0 26 80 00 	st  %o0, [ %i2 ]                               
    if ( lfat_fd == NULL )                                            
4001237c:	80 a2 20 00 	cmp  %o0, 0                                    
40012380:	02 80 00 1c 	be  400123f0 <fat_file_open+0x148>             <== NEVER TAKEN
40012384:	ba 10 00 08 	mov  %o0, %i5                                  
        rtems_set_errno_and_return_minus_one( ENOMEM );               
                                                                      
    memset(lfat_fd, 0, sizeof(fat_file_fd_t));                        
40012388:	92 10 20 00 	clr  %o1                                       
4001238c:	40 00 2a d4 	call  4001cedc <memset>                        
40012390:	94 10 20 44 	mov  0x44, %o2                                 
                                                                      
    lfat_fd->links_num = 1;                                           
40012394:	82 10 20 01 	mov  1, %g1                                    
40012398:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
    lfat_fd->flags &= ~FAT_FILE_REMOVED;                              
4001239c:	c2 0f 60 30 	ldub  [ %i5 + 0x30 ], %g1                      
    lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;                      
                                                                      
    lfat_fd->dir_pos = *dir_pos;                                      
400123a0:	90 07 60 20 	add  %i5, 0x20, %o0                            
        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;                              
400123a4:	82 08 7f fe 	and  %g1, -2, %g1                              
400123a8:	c2 2f 60 30 	stb  %g1, [ %i5 + 0x30 ]                       
    lfat_fd->map.last_cln = FAT_UNDEFINED_VALUE;                      
400123ac:	82 10 3f ff 	mov  -1, %g1                                   
                                                                      
    lfat_fd->dir_pos = *dir_pos;                                      
400123b0:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
    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;                      
400123b4:	c2 27 60 3c 	st  %g1, [ %i5 + 0x3c ]                        
                                                                      
    lfat_fd->dir_pos = *dir_pos;                                      
400123b8:	40 00 2a 8a 	call  4001cde0 <memcpy>                        
400123bc:	94 10 20 10 	mov  0x10, %o2                                 
                                                                      
    if ( rc != RC_OK )                                                
400123c0:	80 a4 20 00 	cmp  %l0, 0                                    
400123c4:	02 80 00 04 	be  400123d4 <fat_file_open+0x12c>             <== NEVER TAKEN
400123c8:	01 00 00 00 	nop                                            
400123cc:	10 80 00 0f 	b  40012408 <fat_file_open+0x160>              
400123d0:	f8 27 60 0c 	st  %i4, [ %i5 + 0xc ]                         
        lfat_fd->ino = key;                                           
    else                                                              
    {                                                                 
        lfat_fd->ino = fat_get_unique_ino(fs_info);                   
400123d4:	40 00 06 a8 	call  40013e74 <fat_get_unique_ino>            <== NOT EXECUTED
400123d8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
                                                                      
        if ( lfat_fd->ino == 0 )                                      
400123dc:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
400123e0:	12 80 00 0a 	bne  40012408 <fat_file_open+0x160>            <== NOT EXECUTED
400123e4:	d0 27 60 0c 	st  %o0, [ %i5 + 0xc ]                         <== NOT EXECUTED
        {                                                             
            free((*fat_fd));                                          
400123e8:	7f ff ca 7b 	call  40004dd4 <free>                          <== NOT EXECUTED
400123ec:	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 );           
400123f0:	40 00 28 27 	call  4001c48c <__errno>                       <== NOT EXECUTED
400123f4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400123f8:	82 10 20 0c 	mov  0xc, %g1                                  <== NOT EXECUTED
400123fc:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40012400:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012404:	81 e8 00 00 	restore                                        <== NOT EXECUTED
 */                                                                   
static inline void                                                    
_hash_insert(rtems_chain_control *hash, uint32_t   key1, uint32_t   key2,
             fat_file_fd_t *el)                                       
{                                                                     
    rtems_chain_append_unprotected((hash) + ((key1) % FAT_HASH_MODULE), &(el)->link);
40012408:	c2 06 20 6c 	ld  [ %i0 + 0x6c ], %g1                        
4001240c:	b6 00 40 1b 	add  %g1, %i3, %i3                             
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
40012410:	c2 06 e0 08 	ld  [ %i3 + 8 ], %g1                           
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40012414:	84 06 e0 04 	add  %i3, 4, %g2                               
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
40012418:	c4 27 40 00 	st  %g2, [ %i5 ]                               
  tail->previous = the_node;                                          
4001241c:	fa 26 e0 08 	st  %i5, [ %i3 + 8 ]                           
  old_last->next = the_node;                                          
40012420:	fa 20 40 00 	st  %i5, [ %g1 ]                               
  the_node->previous = old_last;                                      
40012424:	10 bf ff bb 	b  40012310 <fat_file_open+0x68>               
40012428:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
                                                                      

40012440 <fat_file_read>: fat_file_fd_t *fat_fd, uint32_t start, uint32_t count, uint8_t *buf ) {
40012440:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int            rc = RC_OK;                                        
    ssize_t        ret = 0;                                           
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
40012444:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    fat_file_fd_t                        *fat_fd,                     
    uint32_t                              start,                      
    uint32_t                              count,                      
    uint8_t                              *buf                         
)                                                                     
{                                                                     
40012448:	ba 10 00 18 	mov  %i0, %i5                                  
    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)                                                   
4001244c:	80 a6 e0 00 	cmp  %i3, 0                                    
40012450:	02 80 00 67 	be  400125ec <fat_file_read+0x1ac>             <== NEVER TAKEN
40012454:	90 10 20 00 	clr  %o0                                       
                                                                      
    /*                                                                
     * >= because start is offset and computed from 0 and file_size   
     * computed from 1                                                
     */                                                               
    if ( start >= fat_fd->fat_file_size )                             
40012458:	c2 06 60 18 	ld  [ %i1 + 0x18 ], %g1                        
4001245c:	80 a6 80 01 	cmp  %i2, %g1                                  
40012460:	1a 80 00 63 	bcc  400125ec <fat_file_read+0x1ac>            
40012464:	80 a6 c0 01 	cmp  %i3, %g1                                  
        return FAT_EOF;                                               
                                                                      
    if ((count > fat_fd->fat_file_size) ||                            
40012468:	38 80 00 07 	bgu,a   40012484 <fat_file_read+0x44>          
4001246c:	b6 20 40 1a 	sub  %g1, %i2, %i3                             
        (start > fat_fd->fat_file_size - count))                      
40012470:	84 20 40 1b 	sub  %g1, %i3, %g2                             
     * computed from 1                                                
     */                                                               
    if ( start >= fat_fd->fat_file_size )                             
        return FAT_EOF;                                               
                                                                      
    if ((count > fat_fd->fat_file_size) ||                            
40012474:	80 a6 80 02 	cmp  %i2, %g2                                  
40012478:	28 80 00 04 	bleu,a   40012488 <fat_file_read+0x48>         
4001247c:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
        (start > fat_fd->fat_file_size - count))                      
        count = fat_fd->fat_file_size - start;                        
40012480:	b6 20 40 1a 	sub  %g1, %i2, %i3                             
                                                                      
    if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                               
40012484:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40012488:	80 a0 60 01 	cmp  %g1, 1                                    
4001248c:	32 80 00 1c 	bne,a   400124fc <fat_file_read+0xbc>          
40012490:	e4 0f 60 08 	ldub  [ %i5 + 8 ], %l2                         
40012494:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
40012498:	80 a0 60 00 	cmp  %g1, 0                                    
4001249c:	32 80 00 18 	bne,a   400124fc <fat_file_read+0xbc>          <== NEVER TAKEN
400124a0:	e4 0f 60 08 	ldub  [ %i5 + 8 ], %l2                         <== NOT EXECUTED
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
400124a4:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       
                                                                      
    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)) &&                               
400124a8:	80 88 60 03 	btst  3, %g1                                   
400124ac:	22 80 00 14 	be,a   400124fc <fat_file_read+0xbc>           
400124b0:	e4 0f 60 08 	ldub  [ %i5 + 8 ], %l2                         
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
    {                                                                 
        sec = fat_cluster_num_to_sector_num(fs_info, fat_fd->cln);    
400124b4:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        
400124b8:	7f ff ff 3a 	call  400121a0 <fat_cluster_num_to_sector_num> 
400124bc:	90 10 00 1d 	mov  %i5, %o0                                  
        sec += (start >> fs_info->vol.sec_log2);                      
400124c0:	d2 0f 60 02 	ldub  [ %i5 + 2 ], %o1                         
        byte = start & (fs_info->vol.bps - 1);                        
400124c4:	d4 17 40 00 	lduh  [ %i5 ], %o2                             
                                                                      
    if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                               
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
    {                                                                 
        sec = fat_cluster_num_to_sector_num(fs_info, fat_fd->cln);    
        sec += (start >> fs_info->vol.sec_log2);                      
400124c8:	93 36 80 09 	srl  %i2, %o1, %o1                             
        byte = start & (fs_info->vol.bps - 1);                        
400124cc:	94 02 bf ff 	add  %o2, -1, %o2                              
                                                                      
    if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                               
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
    {                                                                 
        sec = fat_cluster_num_to_sector_num(fs_info, fat_fd->cln);    
        sec += (start >> fs_info->vol.sec_log2);                      
400124d0:	92 02 00 09 	add  %o0, %o1, %o1                             
        byte = start & (fs_info->vol.bps - 1);                        
                                                                      
        ret = _fat_block_read(fs_info, sec, byte, count, buf);        
400124d4:	94 0e 80 0a 	and  %i2, %o2, %o2                             
400124d8:	90 10 00 1d 	mov  %i5, %o0                                  
400124dc:	96 10 00 1b 	mov  %i3, %o3                                  
400124e0:	40 00 03 0f 	call  4001311c <_fat_block_read>               
400124e4:	98 10 00 1c 	mov  %i4, %o4                                  
        if ( ret < 0 )                                                
400124e8:	80 a2 20 00 	cmp  %o0, 0                                    
400124ec:	16 80 00 40 	bge  400125ec <fat_file_read+0x1ac>            <== ALWAYS TAKEN
400124f0:	01 00 00 00 	nop                                            
400124f4:	10 80 00 3e 	b  400125ec <fat_file_read+0x1ac>              <== NOT EXECUTED
400124f8:	90 10 3f ff 	mov  -1, %o0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
                                                                      
        return ret;                                                   
    }                                                                 
                                                                      
    cl_start = start >> fs_info->vol.bpc_log2;                        
    save_ofs = ofs = start & (fs_info->vol.bpc - 1);                  
400124fc:	f0 17 60 06 	lduh  [ %i5 + 6 ], %i0                         
            return -1;                                                
                                                                      
        return ret;                                                   
    }                                                                 
                                                                      
    cl_start = start >> fs_info->vol.bpc_log2;                        
40012500:	a5 36 80 12 	srl  %i2, %l2, %l2                             
    save_ofs = ofs = start & (fs_info->vol.bpc - 1);                  
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln);         
40012504:	90 10 00 1d 	mov  %i5, %o0                                  
40012508:	92 10 00 19 	mov  %i1, %o1                                  
4001250c:	94 10 00 12 	mov  %l2, %o2                                  
40012510:	7f ff ff 43 	call  4001221c <fat_file_lseek>                
40012514:	96 07 bf fc 	add  %fp, -4, %o3                              
    if (rc != RC_OK)                                                  
40012518:	90 92 60 00 	orcc  %o1, 0, %o0                              
4001251c:	12 80 00 34 	bne  400125ec <fat_file_read+0x1ac>            <== NEVER TAKEN
40012520:	a0 10 20 00 	clr  %l0                                       
                                                                      
        return ret;                                                   
    }                                                                 
                                                                      
    cl_start = start >> fs_info->vol.bpc_log2;                        
    save_ofs = ofs = start & (fs_info->vol.bpc - 1);                  
40012524:	b1 2e 20 10 	sll  %i0, 0x10, %i0                            
40012528:	b1 36 20 10 	srl  %i0, 0x10, %i0                            
4001252c:	b0 06 3f ff 	add  %i0, -1, %i0                              
40012530:	b4 0e 80 18 	and  %i2, %i0, %i2                             
40012534:	b0 10 20 00 	clr  %i0                                       
40012538:	a2 10 00 1a 	mov  %i2, %l1                                  
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln);         
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    while (count > 0)                                                 
4001253c:	80 a6 e0 00 	cmp  %i3, 0                                    
40012540:	22 80 00 22 	be,a   400125c8 <fat_file_read+0x188>          
40012544:	c2 0f 60 08 	ldub  [ %i5 + 8 ], %g1                         
    {                                                                 
        c = MIN(count, (fs_info->vol.bpc - ofs));                     
40012548:	e0 17 60 06 	lduh  [ %i5 + 6 ], %l0                         
4001254c:	a0 24 00 11 	sub  %l0, %l1, %l0                             
40012550:	80 a4 00 1b 	cmp  %l0, %i3                                  
40012554:	38 80 00 02 	bgu,a   4001255c <fat_file_read+0x11c>         
40012558:	a0 10 00 1b 	mov  %i3, %l0                                  
                                                                      
        sec = fat_cluster_num_to_sector_num(fs_info, cur_cln);        
4001255c:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
40012560:	7f ff ff 10 	call  400121a0 <fat_cluster_num_to_sector_num> 
40012564:	90 10 00 1d 	mov  %i5, %o0                                  
        sec += (ofs >> fs_info->vol.sec_log2);                        
40012568:	d2 0f 60 02 	ldub  [ %i5 + 2 ], %o1                         
        byte = ofs & (fs_info->vol.bps - 1);                          
4001256c:	d4 17 40 00 	lduh  [ %i5 ], %o2                             
    while (count > 0)                                                 
    {                                                                 
        c = MIN(count, (fs_info->vol.bpc - ofs));                     
                                                                      
        sec = fat_cluster_num_to_sector_num(fs_info, cur_cln);        
        sec += (ofs >> fs_info->vol.sec_log2);                        
40012570:	93 34 40 09 	srl  %l1, %o1, %o1                             
        byte = ofs & (fs_info->vol.bps - 1);                          
40012574:	94 02 bf ff 	add  %o2, -1, %o2                              
    while (count > 0)                                                 
    {                                                                 
        c = MIN(count, (fs_info->vol.bpc - ofs));                     
                                                                      
        sec = fat_cluster_num_to_sector_num(fs_info, cur_cln);        
        sec += (ofs >> fs_info->vol.sec_log2);                        
40012578:	92 02 00 09 	add  %o0, %o1, %o1                             
        byte = ofs & (fs_info->vol.bps - 1);                          
                                                                      
        ret = _fat_block_read(fs_info, sec, byte, c, buf + cmpltd);   
4001257c:	94 0c 40 0a 	and  %l1, %o2, %o2                             
40012580:	90 10 00 1d 	mov  %i5, %o0                                  
40012584:	96 10 00 10 	mov  %l0, %o3                                  
40012588:	40 00 02 e5 	call  4001311c <_fat_block_read>               
4001258c:	98 07 00 18 	add  %i4, %i0, %o4                             
        if ( ret < 0 )                                                
40012590:	80 a2 20 00 	cmp  %o0, 0                                    
40012594:	06 80 00 15 	bl  400125e8 <fat_file_read+0x1a8>             <== NEVER TAKEN
40012598:	b6 26 c0 10 	sub  %i3, %l0, %i3                             
            return -1;                                                
                                                                      
        count -= c;                                                   
        cmpltd += c;                                                  
4001259c:	b0 06 00 10 	add  %i0, %l0, %i0                             
        save_cln = cur_cln;                                           
400125a0:	e0 07 bf fc 	ld  [ %fp + -4 ], %l0                          
        rc = fat_get_fat_cluster(fs_info, cur_cln, &cur_cln);         
400125a4:	90 10 00 1d 	mov  %i5, %o0                                  
400125a8:	92 10 00 10 	mov  %l0, %o1                                  
400125ac:	7f ff fd 4e 	call  40011ae4 <fat_get_fat_cluster>           
400125b0:	94 07 bf fc 	add  %fp, -4, %o2                              
        if ( rc != RC_OK )                                            
400125b4:	80 a2 20 00 	cmp  %o0, 0                                    
400125b8:	12 80 00 0d 	bne  400125ec <fat_file_read+0x1ac>            <== NEVER TAKEN
400125bc:	a2 10 20 00 	clr  %l1                                       
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln);         
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    while (count > 0)                                                 
400125c0:	10 bf ff e0 	b  40012540 <fat_file_read+0x100>              
400125c4:	80 a6 e0 00 	cmp  %i3, 0                                    
    }                                                                 
                                                                      
    /* update cache */                                                
    /* XXX: check this - I'm not sure :( */                           
    fat_fd->map.file_cln = cl_start +                                 
                           ((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
400125c8:	b4 06 bf ff 	add  %i2, -1, %i2                              
    fat_fd->map.disk_cln = save_cln;                                  
400125cc:	e0 26 60 38 	st  %l0, [ %i1 + 0x38 ]                        
    }                                                                 
                                                                      
    /* update cache */                                                
    /* XXX: check this - I'm not sure :( */                           
    fat_fd->map.file_cln = cl_start +                                 
                           ((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
400125d0:	b4 06 80 18 	add  %i2, %i0, %i2                             
    fat_fd->map.disk_cln = save_cln;                                  
                                                                      
    return cmpltd;                                                    
400125d4:	90 10 00 18 	mov  %i0, %o0                                  
    }                                                                 
                                                                      
    /* update cache */                                                
    /* XXX: check this - I'm not sure :( */                           
    fat_fd->map.file_cln = cl_start +                                 
                           ((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
400125d8:	b5 36 80 01 	srl  %i2, %g1, %i2                             
        ofs = 0;                                                      
    }                                                                 
                                                                      
    /* update cache */                                                
    /* XXX: check this - I'm not sure :( */                           
    fat_fd->map.file_cln = cl_start +                                 
400125dc:	a4 06 80 12 	add  %i2, %l2, %l2                             
                           ((save_ofs + cmpltd - 1) >> fs_info->vol.bpc_log2);
    fat_fd->map.disk_cln = save_cln;                                  
                                                                      
    return cmpltd;                                                    
400125e0:	10 80 00 03 	b  400125ec <fat_file_read+0x1ac>              
400125e4:	e4 26 60 34 	st  %l2, [ %i1 + 0x34 ]                        
        sec += (ofs >> fs_info->vol.sec_log2);                        
        byte = ofs & (fs_info->vol.bps - 1);                          
                                                                      
        ret = _fat_block_read(fs_info, sec, byte, c, buf + cmpltd);   
        if ( ret < 0 )                                                
            return -1;                                                
400125e8:	90 10 3f ff 	mov  -1, %o0                                   <== 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;                                                    
}                                                                     
400125ec:	81 c7 e0 08 	ret                                            
400125f0:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40012d6c <fat_file_size>: int fat_file_size( fat_fs_info_t *fs_info, fat_file_fd_t *fat_fd ) {
40012d6c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int            rc = RC_OK;                                        
    uint32_t       cur_cln = fat_fd->cln;                             
40012d70:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
40012d74:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
    uint32_t       save_cln = 0;                                      
                                                                      
    /* Have we requested root dir size for FAT12/16? */               
    if ((FAT_FD_OF_ROOT_DIR(fat_fd)) &&                               
40012d78:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40012d7c:	80 a0 60 01 	cmp  %g1, 1                                    
40012d80:	12 80 00 0d 	bne  40012db4 <fat_file_size+0x48>             
40012d84:	ba 10 00 18 	mov  %i0, %i5                                  
40012d88:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
40012d8c:	80 a0 60 00 	cmp  %g1, 0                                    
40012d90:	32 80 00 0a 	bne,a   40012db8 <fat_file_size+0x4c>          <== NEVER TAKEN
40012d94:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            <== NOT EXECUTED
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
40012d98:	c2 0e 20 0e 	ldub  [ %i0 + 0xe ], %g1                       
    int            rc = RC_OK;                                        
    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)) &&                               
40012d9c:	80 88 60 03 	btst  3, %g1                                   
40012da0:	22 80 00 06 	be,a   40012db8 <fat_file_size+0x4c>           
40012da4:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            
        (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)))                
    {                                                                 
        fat_fd->fat_file_size = fs_info->vol.rdir_size;               
40012da8:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
40012dac:	10 80 00 18 	b  40012e0c <fat_file_size+0xa0>               
40012db0:	c2 26 60 18 	st  %g1, [ %i1 + 0x18 ]                        
        return rc;                                                    
    }                                                                 
                                                                      
    fat_fd->fat_file_size = 0;                                        
40012db4:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            
    fat_file_fd_t                        *fat_fd                      
    )                                                                 
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cur_cln = fat_fd->cln;                             
    uint32_t       save_cln = 0;                                      
40012db8:	82 10 20 00 	clr  %g1                                       
        return rc;                                                    
    }                                                                 
                                                                      
    fat_fd->fat_file_size = 0;                                        
                                                                      
    while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)      
40012dbc:	f8 07 bf fc 	ld  [ %fp + -4 ], %i4                          
40012dc0:	c6 07 60 10 	ld  [ %i5 + 0x10 ], %g3                        
40012dc4:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        
40012dc8:	86 0f 00 03 	and  %i4, %g3, %g3                             
40012dcc:	80 a0 c0 02 	cmp  %g3, %g2                                  
40012dd0:	1a 80 00 0e 	bcc  40012e08 <fat_file_size+0x9c>             
40012dd4:	90 10 00 1d 	mov  %i5, %o0                                  
    {                                                                 
        save_cln = cur_cln;                                           
        rc = fat_get_fat_cluster(fs_info, cur_cln, &cur_cln);         
40012dd8:	92 10 00 1c 	mov  %i4, %o1                                  
40012ddc:	7f ff fb 42 	call  40011ae4 <fat_get_fat_cluster>           
40012de0:	94 07 bf fc 	add  %fp, -4, %o2                              
        if ( rc != RC_OK )                                            
40012de4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40012de8:	12 80 00 0a 	bne  40012e10 <fat_file_size+0xa4>             <== NEVER TAKEN
40012dec:	01 00 00 00 	nop                                            
            return rc;                                                
                                                                      
        fat_fd->fat_file_size += fs_info->vol.bpc;                    
40012df0:	c2 17 60 06 	lduh  [ %i5 + 6 ], %g1                         
40012df4:	c4 06 60 18 	ld  [ %i1 + 0x18 ], %g2                        
40012df8:	82 00 80 01 	add  %g2, %g1, %g1                             
40012dfc:	c2 26 60 18 	st  %g1, [ %i1 + 0x18 ]                        
                                                                      
    fat_fd->fat_file_size = 0;                                        
                                                                      
    while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)      
    {                                                                 
        save_cln = cur_cln;                                           
40012e00:	10 bf ff ef 	b  40012dbc <fat_file_size+0x50>               
40012e04:	82 10 00 1c 	mov  %i4, %g1                                  
        if ( rc != RC_OK )                                            
            return rc;                                                
                                                                      
        fat_fd->fat_file_size += fs_info->vol.bpc;                    
    }                                                                 
    fat_fd->map.last_cln = save_cln;                                  
40012e08:	c2 26 60 3c 	st  %g1, [ %i1 + 0x3c ]                        
    return rc;                                                        
40012e0c:	b0 10 20 00 	clr  %i0                                       
}                                                                     
40012e10:	81 c7 e0 08 	ret                                            
40012e14:	81 e8 00 00 	restore                                        
                                                                      

400125f4 <fat_file_truncate>: fat_file_truncate( fat_fs_info_t *fs_info, fat_file_fd_t *fat_fd, uint32_t new_length ) {
400125f4:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int            rc = RC_OK;                                        
    uint32_t       cur_cln = 0;                                       
    uint32_t       cl_start = 0;                                      
    uint32_t       new_last_cln = FAT_UNDEFINED_VALUE;                
400125f8:	82 10 3f ff 	mov  -1, %g1                                   
400125fc:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
                                                                      
                                                                      
    if ( new_length >= fat_fd->fat_file_size )                        
40012600:	c2 06 60 18 	ld  [ %i1 + 0x18 ], %g1                        
40012604:	80 a6 80 01 	cmp  %i2, %g1                                  
40012608:	0a 80 00 04 	bcs  40012618 <fat_file_truncate+0x24>         
4001260c:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
        return rc;                                                    
40012610:	10 80 00 3b 	b  400126fc <fat_file_truncate+0x108>          
40012614:	92 10 20 00 	clr  %o1                                       
                                                                      
    assert(fat_fd->fat_file_size);                                    
40012618:	80 a0 60 00 	cmp  %g1, 0                                    
4001261c:	32 80 00 0a 	bne,a   40012644 <fat_file_truncate+0x50>      <== ALWAYS TAKEN
40012620:	c4 0e 20 08 	ldub  [ %i0 + 8 ], %g2                         
40012624:	11 10 00 b3 	sethi  %hi(0x4002cc00), %o0                    <== NOT EXECUTED
40012628:	15 10 00 b3 	sethi  %hi(0x4002cc00), %o2                    <== NOT EXECUTED
4001262c:	17 10 00 b3 	sethi  %hi(0x4002cc00), %o3                    <== NOT EXECUTED
40012630:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
40012634:	92 10 22 d4 	mov  0x2d4, %o1                                <== NOT EXECUTED
40012638:	94 12 a1 e8 	or  %o2, 0x1e8, %o2                            <== NOT EXECUTED
4001263c:	7f ff c9 7e 	call  40004c34 <__assert_func>                 <== NOT EXECUTED
40012640:	96 12 e1 d0 	or  %o3, 0x1d0, %o3                            <== NOT EXECUTED
                                                                      
    cl_start = (new_length + fs_info->vol.bpc - 1) >> fs_info->vol.bpc_log2;
40012644:	c6 16 20 06 	lduh  [ %i0 + 6 ], %g3                         
40012648:	86 00 ff ff 	add  %g3, -1, %g3                              
4001264c:	b4 00 c0 1a 	add  %g3, %i2, %i2                             
40012650:	b5 36 80 02 	srl  %i2, %g2, %i2                             
                                                                      
    if ((cl_start << fs_info->vol.bpc_log2) >= fat_fd->fat_file_size) 
40012654:	85 2e 80 02 	sll  %i2, %g2, %g2                             
40012658:	80 a0 80 01 	cmp  %g2, %g1                                  
4001265c:	1a bf ff ed 	bcc  40012610 <fat_file_truncate+0x1c>         
40012660:	80 a6 a0 00 	cmp  %i2, 0                                    
        return RC_OK;                                                 
                                                                      
    if (cl_start != 0)                                                
40012664:	12 80 00 0b 	bne  40012690 <fat_file_truncate+0x9c>         
40012668:	90 10 00 18 	mov  %i0, %o0                                  
        if (rc != RC_OK)                                              
            return rc;                                                
                                                                      
    }                                                                 
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln);         
4001266c:	92 10 00 19 	mov  %i1, %o1                                  
40012670:	94 10 00 1a 	mov  %i2, %o2                                  
40012674:	7f ff fe ea 	call  4001221c <fat_file_lseek>                
40012678:	96 07 bf f8 	add  %fp, -8, %o3                              
    if (rc != RC_OK)                                                  
4001267c:	80 a2 60 00 	cmp  %o1, 0                                    
40012680:	32 80 00 20 	bne,a   40012700 <fat_file_truncate+0x10c>     <== NEVER TAKEN
40012684:	b0 10 00 09 	mov  %o1, %i0                                  <== NOT EXECUTED
        return rc;                                                    
                                                                      
    rc = fat_free_fat_clusters_chain(fs_info, cur_cln);               
40012688:	10 80 00 0b 	b  400126b4 <fat_file_truncate+0xc0>           
4001268c:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
    if ((cl_start << fs_info->vol.bpc_log2) >= fat_fd->fat_file_size) 
        return RC_OK;                                                 
                                                                      
    if (cl_start != 0)                                                
    {                                                                 
        rc = fat_file_lseek(fs_info, fat_fd, cl_start - 1, &new_last_cln);
40012690:	92 10 00 19 	mov  %i1, %o1                                  
40012694:	94 06 bf ff 	add  %i2, -1, %o2                              
40012698:	7f ff fe e1 	call  4001221c <fat_file_lseek>                
4001269c:	96 07 bf fc 	add  %fp, -4, %o3                              
        if (rc != RC_OK)                                              
400126a0:	80 a2 60 00 	cmp  %o1, 0                                    
400126a4:	02 bf ff f2 	be  4001266c <fat_file_truncate+0x78>          <== ALWAYS TAKEN
400126a8:	90 10 00 18 	mov  %i0, %o0                                  
        fat_fd->map.file_cln = cl_start - 1;                          
        fat_fd->map.disk_cln = new_last_cln;                          
        fat_fd->map.last_cln = new_last_cln;                          
    }                                                                 
    return RC_OK;                                                     
}                                                                     
400126ac:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400126b0:	91 e8 00 09 	restore  %g0, %o1, %o0                         <== NOT EXECUTED
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, cl_start, &cur_cln);         
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    rc = fat_free_fat_clusters_chain(fs_info, cur_cln);               
400126b4:	7f ff fe 18 	call  40011f14 <fat_free_fat_clusters_chain>   
400126b8:	90 10 00 18 	mov  %i0, %o0                                  
    if (rc != RC_OK)                                                  
400126bc:	92 92 20 00 	orcc  %o0, 0, %o1                              
400126c0:	12 80 00 0f 	bne  400126fc <fat_file_truncate+0x108>        <== NEVER TAKEN
400126c4:	80 a6 a0 00 	cmp  %i2, 0                                    
        return rc;                                                    
                                                                      
    if (cl_start != 0)                                                
400126c8:	02 80 00 0d 	be  400126fc <fat_file_truncate+0x108>         
400126cc:	92 10 20 00 	clr  %o1                                       
    {                                                                 
        rc = fat_set_fat_cluster(fs_info, new_last_cln, FAT_GENFAT_EOC);
400126d0:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
400126d4:	90 10 00 18 	mov  %i0, %o0                                  
400126d8:	7f ff fd 71 	call  40011c9c <fat_set_fat_cluster>           
400126dc:	94 10 3f ff 	mov  -1, %o2                                   
        if ( rc != RC_OK )                                            
400126e0:	92 92 20 00 	orcc  %o0, 0, %o1                              
400126e4:	12 80 00 06 	bne  400126fc <fat_file_truncate+0x108>        <== NEVER TAKEN
400126e8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
            return rc;                                                
        fat_fd->map.file_cln = cl_start - 1;                          
400126ec:	b4 06 bf ff 	add  %i2, -1, %i2                              
        fat_fd->map.disk_cln = new_last_cln;                          
400126f0:	c2 26 60 38 	st  %g1, [ %i1 + 0x38 ]                        
    if (cl_start != 0)                                                
    {                                                                 
        rc = fat_set_fat_cluster(fs_info, new_last_cln, FAT_GENFAT_EOC);
        if ( rc != RC_OK )                                            
            return rc;                                                
        fat_fd->map.file_cln = cl_start - 1;                          
400126f4:	f4 26 60 34 	st  %i2, [ %i1 + 0x34 ]                        
        fat_fd->map.disk_cln = new_last_cln;                          
        fat_fd->map.last_cln = new_last_cln;                          
400126f8:	c2 26 60 3c 	st  %g1, [ %i1 + 0x3c ]                        
    }                                                                 
    return RC_OK;                                                     
}                                                                     
400126fc:	b0 10 00 09 	mov  %o1, %i0                                  
40012700:	81 c7 e0 08 	ret                                            
40012704:	81 e8 00 00 	restore                                        
                                                                      

40012acc <fat_file_write>: fat_file_fd_t *fat_fd, uint32_t start, uint32_t count, const uint8_t *buf ) {
40012acc:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int            rc = RC_OK;                                        
    ssize_t        ret;                                               
    uint32_t       cmpltd = 0;                                        
    uint32_t       byte;                                              
    uint32_t       c = 0;                                             
40012ad0:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
    fat_file_fd_t                        *fat_fd,                     
    uint32_t                              start,                      
    uint32_t                              count,                      
    const uint8_t                        *buf                         
    )                                                                 
{                                                                     
40012ad4:	a0 10 00 18 	mov  %i0, %l0                                  
    int            rc = RC_OK;                                        
    ssize_t        ret;                                               
    uint32_t       cmpltd = 0;                                        
    uint32_t       byte;                                              
    uint32_t       c = 0;                                             
    bool           zero_fill = start > fat_fd->fat_file_size;         
40012ad8:	c2 06 60 18 	ld  [ %i1 + 0x18 ], %g1                        
    uint32_t       file_cln_initial = fat_fd->map.file_cln;           
40012adc:	e6 06 60 34 	ld  [ %i1 + 0x34 ], %l3                        
    uint32_t       cln;                                               
                                                                      
                                                                      
    if ( count == 0 )                                                 
40012ae0:	80 a6 e0 00 	cmp  %i3, 0                                    
40012ae4:	02 80 00 0a 	be  40012b0c <fat_file_write+0x40>             <== NEVER TAKEN
40012ae8:	b0 10 20 00 	clr  %i0                                       
        return cmpltd;                                                
                                                                      
    if (start >= fat_fd->size_limit)                                  
40012aec:	fa 06 60 14 	ld  [ %i1 + 0x14 ], %i5                        
40012af0:	80 a6 80 1d 	cmp  %i2, %i5                                  
40012af4:	2a 80 00 08 	bcs,a   40012b14 <fat_file_write+0x48>         <== ALWAYS TAKEN
40012af8:	ba 27 40 1a 	sub  %i5, %i2, %i5                             
        rtems_set_errno_and_return_minus_one(EFBIG);                  
40012afc:	40 00 26 64 	call  4001c48c <__errno>                       <== NOT EXECUTED
40012b00:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012b04:	82 10 20 1b 	mov  0x1b, %g1                                 <== NOT EXECUTED
40012b08:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40012b0c:	81 c7 e0 08 	ret                                            
40012b10:	81 e8 00 00 	restore                                        
40012b14:	80 a7 40 1b 	cmp  %i5, %i3                                  
40012b18:	38 80 00 02 	bgu,a   40012b20 <fat_file_write+0x54>         <== ALWAYS TAKEN
40012b1c:	ba 10 00 1b 	mov  %i3, %i5                                  
    int            rc = RC_OK;                                        
    ssize_t        ret;                                               
    uint32_t       cmpltd = 0;                                        
    uint32_t       byte;                                              
    uint32_t       c = 0;                                             
    bool           zero_fill = start > fat_fd->fat_file_size;         
40012b20:	80 a0 40 1a 	cmp  %g1, %i2                                  
        rtems_set_errno_and_return_minus_one(EFBIG);                  
                                                                      
    if (count > fat_fd->size_limit - start)                           
        count = fat_fd->size_limit - start;                           
                                                                      
    rc = fat_file_extend(fs_info, fat_fd, zero_fill, start + count, &c);
40012b24:	b6 07 40 1a 	add  %i5, %i2, %i3                             
40012b28:	94 40 20 00 	addx  %g0, 0, %o2                              
40012b2c:	90 10 00 10 	mov  %l0, %o0                                  
40012b30:	92 10 00 19 	mov  %i1, %o1                                  
40012b34:	96 10 00 1b 	mov  %i3, %o3                                  
40012b38:	7f ff ff 56 	call  40012890 <fat_file_extend>               
40012b3c:	98 07 bf f8 	add  %fp, -8, %o4                              
    if (RC_OK == rc)                                                  
40012b40:	80 a2 20 00 	cmp  %o0, 0                                    
40012b44:	12 bf ff f2 	bne  40012b0c <fat_file_write+0x40>            
40012b48:	b0 10 00 08 	mov  %o0, %i0                                  
    {                                                                 
        /*                                                            
         * check whether there was enough room on device to locate    
         * file of 'start + count' bytes                              
         */                                                           
        if (c != (start + count))                                     
40012b4c:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
40012b50:	80 a0 40 1b 	cmp  %g1, %i3                                  
40012b54:	32 80 00 02 	bne,a   40012b5c <fat_file_write+0x90>         
40012b58:	ba 20 40 1a 	sub  %g1, %i2, %i5                             
 */                                                                   
static bool                                                           
 fat_is_fat12_or_fat16_root_dir (const fat_file_fd_t *fat_fd,         
                                 const uint8_t volume_type)           
{                                                                     
    return (FAT_FD_OF_ROOT_DIR(fat_fd)) && (volume_type & (FAT_FAT12 | FAT_FAT16));
40012b5c:	c6 06 60 20 	ld  [ %i1 + 0x20 ], %g3                        
         */                                                           
        if (c != (start + count))                                     
            count = c - start;                                        
                                                                      
        /* for the root directory of FAT12 and FAT16 we need this special handling */
        if (fat_is_fat12_or_fat16_root_dir(fat_fd, fs_info->vol.type))
40012b60:	c4 0c 20 0e 	ldub  [ %l0 + 0xe ], %g2                       
 */                                                                   
static bool                                                           
 fat_is_fat12_or_fat16_root_dir (const fat_file_fd_t *fat_fd,         
                                 const uint8_t volume_type)           
{                                                                     
    return (FAT_FD_OF_ROOT_DIR(fat_fd)) && (volume_type & (FAT_FAT12 | FAT_FAT16));
40012b64:	80 a0 e0 01 	cmp  %g3, 1                                    
40012b68:	12 80 00 09 	bne  40012b8c <fat_file_write+0xc0>            
40012b6c:	82 10 20 00 	clr  %g1                                       
40012b70:	c6 06 60 24 	ld  [ %i1 + 0x24 ], %g3                        
40012b74:	80 a0 e0 00 	cmp  %g3, 0                                    
40012b78:	12 80 00 06 	bne  40012b90 <fat_file_write+0xc4>            <== NEVER TAKEN
40012b7c:	80 a0 60 00 	cmp  %g1, 0                                    
40012b80:	82 08 a0 03 	and  %g2, 3, %g1                               
40012b84:	80 a0 00 01 	cmp  %g0, %g1                                  
40012b88:	82 40 20 00 	addx  %g0, 0, %g1                              
         */                                                           
        if (c != (start + count))                                     
            count = c - start;                                        
                                                                      
        /* for the root directory of FAT12 and FAT16 we need this special handling */
        if (fat_is_fat12_or_fat16_root_dir(fat_fd, fs_info->vol.type))
40012b8c:	80 a0 60 00 	cmp  %g1, 0                                    
40012b90:	02 80 00 12 	be  40012bd8 <fat_file_write+0x10c>            
40012b94:	f6 0c 20 08 	ldub  [ %l0 + 8 ], %i3                         
        {                                                             
            cln = fat_fd->cln;                                        
40012b98:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        
            cln += (start >> fs_info->vol.bpc_log2);                  
            byte = start & (fs_info->vol.bpc -1);                     
40012b9c:	d4 14 20 06 	lduh  [ %l0 + 6 ], %o2                         
                                                                      
        /* for the root directory of FAT12 and FAT16 we need this special handling */
        if (fat_is_fat12_or_fat16_root_dir(fat_fd, fs_info->vol.type))
        {                                                             
            cln = fat_fd->cln;                                        
            cln += (start >> fs_info->vol.bpc_log2);                  
40012ba0:	b7 36 80 1b 	srl  %i2, %i3, %i3                             
            byte = start & (fs_info->vol.bpc -1);                     
40012ba4:	94 02 bf ff 	add  %o2, -1, %o2                              
                                                                      
            ret = fat_cluster_write(fs_info,                          
40012ba8:	90 10 00 10 	mov  %l0, %o0                                  
40012bac:	92 06 c0 09 	add  %i3, %o1, %o1                             
40012bb0:	94 0e 80 0a 	and  %i2, %o2, %o2                             
40012bb4:	96 10 00 1d 	mov  %i5, %o3                                  
40012bb8:	98 10 00 1c 	mov  %i4, %o4                                  
40012bbc:	40 00 01 e1 	call  40013340 <fat_cluster_write>             
40012bc0:	9a 10 20 00 	clr  %o5                                       
                                      cln,                            
                                      byte,                           
                                      count,                          
                                      buf,                            
                                      false);                         
            if (0 > ret)                                              
40012bc4:	80 a2 20 00 	cmp  %o0, 0                                    
40012bc8:	36 bf ff d1 	bge,a   40012b0c <fat_file_write+0x40>         <== ALWAYS TAKEN
40012bcc:	b0 10 00 08 	mov  %o0, %i0                                  
              rc = -1;                                                
40012bd0:	10 80 00 4b 	b  40012cfc <fat_file_write+0x230>             <== NOT EXECUTED
40012bd4:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
     const uint8_t                        *buf,                       
     const uint32_t                        file_cln_initial)          
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
40012bd8:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    uint32_t       save_cln = 0; /* FIXME: This might be incorrect, cf. below */
    uint32_t       start_cln = start >> fs_info->vol.bpc_log2;        
40012bdc:	b6 0e e0 ff 	and  %i3, 0xff, %i3                            
    uint32_t       file_cln_cnt;                                      
    ssize_t        ret;                                               
    uint32_t       c;                                                 
    bool           overwrite_cluster = false;                         
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, start_cln, &cur_cln);        
40012be0:	90 10 00 10 	mov  %l0, %o0                                  
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
    uint32_t       save_cln = 0; /* FIXME: This might be incorrect, cf. below */
    uint32_t       start_cln = start >> fs_info->vol.bpc_log2;        
40012be4:	a3 36 80 1b 	srl  %i2, %i3, %l1                             
    uint32_t       file_cln_cnt;                                      
    ssize_t        ret;                                               
    uint32_t       c;                                                 
    bool           overwrite_cluster = false;                         
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, start_cln, &cur_cln);        
40012be8:	92 10 00 19 	mov  %i1, %o1                                  
40012bec:	94 10 00 11 	mov  %l1, %o2                                  
40012bf0:	7f ff fd 8b 	call  4001221c <fat_file_lseek>                
40012bf4:	96 07 bf fc 	add  %fp, -4, %o3                              
    if (RC_OK == rc)                                                  
40012bf8:	80 a2 60 00 	cmp  %o1, 0                                    
40012bfc:	12 80 00 2e 	bne  40012cb4 <fat_file_write+0x1e8>           <== NEVER TAKEN
40012c00:	e4 07 bf fc 	ld  [ %fp + -4 ], %l2                          
    {                                                                 
        file_cln_cnt = cur_cln - fat_fd->cln;                         
40012c04:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
    uint32_t       save_cln = 0; /* FIXME: This might be incorrect, cf. below */
    uint32_t       start_cln = start >> fs_info->vol.bpc_log2;        
    uint32_t       ofs_cln = start - (start_cln << fs_info->vol.bpc_log2);
40012c08:	b7 2c 40 1b 	sll  %l1, %i3, %i3                             
    bool           overwrite_cluster = false;                         
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, start_cln, &cur_cln);        
    if (RC_OK == rc)                                                  
    {                                                                 
        file_cln_cnt = cur_cln - fat_fd->cln;                         
40012c0c:	a4 24 80 01 	sub  %l2, %g1, %l2                             
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
    uint32_t       save_cln = 0; /* FIXME: This might be incorrect, cf. below */
    uint32_t       start_cln = start >> fs_info->vol.bpc_log2;        
    uint32_t       ofs_cln = start - (start_cln << fs_info->vol.bpc_log2);
40012c10:	b4 26 80 1b 	sub  %i2, %i3, %i2                             
    bool           overwrite_cluster = false;                         
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, start_cln, &cur_cln);        
    if (RC_OK == rc)                                                  
    {                                                                 
        file_cln_cnt = cur_cln - fat_fd->cln;                         
40012c14:	82 10 20 00 	clr  %g1                                       
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
    uint32_t       save_cln = 0; /* FIXME: This might be incorrect, cf. below */
    uint32_t       start_cln = start >> fs_info->vol.bpc_log2;        
    uint32_t       ofs_cln = start - (start_cln << fs_info->vol.bpc_log2);
40012c18:	b0 10 00 1a 	mov  %i2, %i0                                  
    uint32_t       ofs_cln_save = ofs_cln;                            
    uint32_t       bytes_to_write = count;                            
    uint32_t       file_cln_cnt;                                      
    ssize_t        ret;                                               
    uint32_t       c;                                                 
    bool           overwrite_cluster = false;                         
40012c1c:	aa 10 20 00 	clr  %l5                                       
     const uint32_t                        file_cln_initial)          
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
    uint32_t       cur_cln = 0;                                       
    uint32_t       save_cln = 0; /* FIXME: This might be incorrect, cf. below */
40012c20:	a8 10 20 00 	clr  %l4                                       
     const uint32_t                        count,                     
     const uint8_t                        *buf,                       
     const uint32_t                        file_cln_initial)          
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cmpltd = 0;                                        
40012c24:	b6 10 20 00 	clr  %i3                                       
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, start_cln, &cur_cln);        
    if (RC_OK == rc)                                                  
    {                                                                 
        file_cln_cnt = cur_cln - fat_fd->cln;                         
        while (   (RC_OK == rc)                                       
40012c28:	80 a7 60 00 	cmp  %i5, 0                                    
40012c2c:	02 80 00 17 	be  40012c88 <fat_file_write+0x1bc>            
40012c30:	80 a0 60 00 	cmp  %g1, 0                                    
40012c34:	32 80 00 16 	bne,a   40012c8c <fat_file_write+0x1c0>        <== NEVER TAKEN
40012c38:	c4 0c 20 08 	ldub  [ %l0 + 8 ], %g2                         <== NOT EXECUTED
               && (bytes_to_write > 0))                               
        {                                                             
            c = MIN(bytes_to_write, (fs_info->vol.bpc - ofs_cln));    
40012c3c:	d6 14 20 06 	lduh  [ %l0 + 6 ], %o3                         
40012c40:	96 22 c0 18 	sub  %o3, %i0, %o3                             
40012c44:	80 a2 c0 1d 	cmp  %o3, %i5                                  
40012c48:	38 80 00 02 	bgu,a   40012c50 <fat_file_write+0x184>        
40012c4c:	96 10 00 1d 	mov  %i5, %o3                                  
                                                                      
            if (file_cln_initial < file_cln_cnt)                      
40012c50:	80 a4 c0 12 	cmp  %l3, %l2                                  
40012c54:	2a 80 00 02 	bcs,a   40012c5c <fat_file_write+0x190>        
40012c58:	aa 10 20 01 	mov  1, %l5                                    
                overwrite_cluster = true;                             
                                                                      
            ret = fat_cluster_write(fs_info,                          
40012c5c:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
40012c60:	90 10 00 10 	mov  %l0, %o0                                  
40012c64:	94 10 00 18 	mov  %i0, %o2                                  
40012c68:	98 07 00 1b 	add  %i4, %i3, %o4                             
40012c6c:	40 00 01 b5 	call  40013340 <fat_cluster_write>             
40012c70:	9a 0d 60 01 	and  %l5, 1, %o5                               
                                      cur_cln,                        
                                      ofs_cln,                        
                                      c,                              
                                      &buf[cmpltd],                   
                                      overwrite_cluster);             
            if (0 > ret)                                              
40012c74:	80 a2 20 00 	cmp  %o0, 0                                    
40012c78:	16 80 00 13 	bge  40012cc4 <fat_file_write+0x1f8>           <== ALWAYS TAKEN
40012c7c:	82 10 3f ff 	mov  -1, %g1                                   
                                                                      
    rc = fat_file_lseek(fs_info, fat_fd, start_cln, &cur_cln);        
    if (RC_OK == rc)                                                  
    {                                                                 
        file_cln_cnt = cur_cln - fat_fd->cln;                         
        while (   (RC_OK == rc)                                       
40012c80:	10 bf ff eb 	b  40012c2c <fat_file_write+0x160>             <== NOT EXECUTED
40012c84:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
        }                                                             
                                                                      
        /* update cache */                                            
        /* XXX: check this - I'm not sure :( */                       
        fat_fd->map.file_cln = start_cln +                            
                               ((ofs_cln_save + cmpltd - 1) >> fs_info->vol.bpc_log2);
40012c88:	c4 0c 20 08 	ldub  [ %l0 + 8 ], %g2                         
40012c8c:	b4 06 bf ff 	add  %i2, -1, %i2                              
        fat_fd->map.disk_cln = save_cln;                              
40012c90:	e8 26 60 38 	st  %l4, [ %i1 + 0x38 ]                        
        }                                                             
                                                                      
        /* update cache */                                            
        /* XXX: check this - I'm not sure :( */                       
        fat_fd->map.file_cln = start_cln +                            
                               ((ofs_cln_save + cmpltd - 1) >> fs_info->vol.bpc_log2);
40012c94:	b4 06 80 1b 	add  %i2, %i3, %i2                             
40012c98:	b5 36 80 02 	srl  %i2, %g2, %i2                             
            }                                                         
        }                                                             
                                                                      
        /* update cache */                                            
        /* XXX: check this - I'm not sure :( */                       
        fat_fd->map.file_cln = start_cln +                            
40012c9c:	a2 06 80 11 	add  %i2, %l1, %l1                             
                               ((ofs_cln_save + cmpltd - 1) >> fs_info->vol.bpc_log2);
        fat_fd->map.disk_cln = save_cln;                              
    }                                                                 
                                                                      
    if (RC_OK != rc)                                                  
40012ca0:	92 90 60 00 	orcc  %g1, 0, %o1                              
40012ca4:	12 80 00 03 	bne  40012cb0 <fat_file_write+0x1e4>           <== NEVER TAKEN
40012ca8:	e2 26 60 34 	st  %l1, [ %i1 + 0x34 ]                        
      return rc;                                                      
    else                                                              
      return cmpltd;                                                  
40012cac:	92 10 00 1b 	mov  %i3, %o1                                  
                                                       fat_fd,        
                                                       start,         
                                                       count,         
                                                       buf,           
                                                       file_cln_initial);
            if (0 > ret)                                              
40012cb0:	80 a2 60 00 	cmp  %o1, 0                                    
40012cb4:	16 80 00 12 	bge  40012cfc <fat_file_write+0x230>           <== ALWAYS TAKEN
40012cb8:	90 10 00 09 	mov  %o1, %o0                                  
40012cbc:	10 80 00 10 	b  40012cfc <fat_file_write+0x230>             <== NOT EXECUTED
40012cc0:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
            if (0 > ret)                                              
              rc = -1;                                                
                                                                      
            if (RC_OK == rc)                                          
            {                                                         
                ++file_cln_cnt;                                       
40012cc4:	a4 04 a0 01 	inc  %l2                                       
                bytes_to_write -= ret;                                
                cmpltd += ret;                                        
40012cc8:	b6 06 c0 08 	add  %i3, %o0, %i3                             
                save_cln = cur_cln;                                   
                if (0 < bytes_to_write)                               
40012ccc:	ba a7 40 08 	subcc  %i5, %o0, %i5                           
40012cd0:	02 80 00 09 	be  40012cf4 <fat_file_write+0x228>            
40012cd4:	e8 07 bf fc 	ld  [ %fp + -4 ], %l4                          
                  rc = fat_get_fat_cluster(fs_info, cur_cln, &cur_cln);
40012cd8:	90 10 00 10 	mov  %l0, %o0                                  
40012cdc:	92 10 00 14 	mov  %l4, %o1                                  
40012ce0:	7f ff fb 81 	call  40011ae4 <fat_get_fat_cluster>           
40012ce4:	94 07 bf fc 	add  %fp, -4, %o2                              
40012ce8:	82 10 00 08 	mov  %o0, %g1                                  
                                                                      
                ofs_cln = 0;                                          
40012cec:	10 bf ff cf 	b  40012c28 <fat_file_write+0x15c>             
40012cf0:	b0 10 20 00 	clr  %i0                                       
            {                                                         
                ++file_cln_cnt;                                       
                bytes_to_write -= ret;                                
                cmpltd += ret;                                        
                save_cln = cur_cln;                                   
                if (0 < bytes_to_write)                               
40012cf4:	10 bf ff fe 	b  40012cec <fat_file_write+0x220>             
40012cf8:	82 10 20 00 	clr  %g1                                       
        }                                                             
    }                                                                 
    if (RC_OK != rc)                                                  
        return rc;                                                    
    else                                                              
        return cmpltd;                                                
40012cfc:	b0 10 00 08 	mov  %o0, %i0                                  
}                                                                     
40012d00:	81 c7 e0 08 	ret                                            
40012d04:	81 e8 00 00 	restore                                        
                                                                      

40011f14 <fat_free_fat_clusters_chain>: int fat_free_fat_clusters_chain( fat_fs_info_t *fs_info, uint32_t chain ) {
40011f14:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int            rc = RC_OK, rc1 = RC_OK;                           
    uint32_t       cur_cln = chain;                                   
    uint32_t       next_cln = 0;                                      
    uint32_t       freed_cls_cnt = 0;                                 
40011f18:	ba 10 20 00 	clr  %i5                                       
    uint32_t                              chain                       
    )                                                                 
{                                                                     
    int            rc = RC_OK, rc1 = RC_OK;                           
    uint32_t       cur_cln = chain;                                   
    uint32_t       next_cln = 0;                                      
40011f1c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    fat_fs_info_t                        *fs_info,                    
    uint32_t                              chain                       
    )                                                                 
{                                                                     
    int            rc = RC_OK, rc1 = RC_OK;                           
    uint32_t       cur_cln = chain;                                   
40011f20:	b8 10 00 19 	mov  %i1, %i4                                  
fat_free_fat_clusters_chain(                                          
    fat_fs_info_t                        *fs_info,                    
    uint32_t                              chain                       
    )                                                                 
{                                                                     
    int            rc = RC_OK, rc1 = RC_OK;                           
40011f24:	b6 10 20 00 	clr  %i3                                       
    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)      
40011f28:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
40011f2c:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
40011f30:	84 0f 00 02 	and  %i4, %g2, %g2                             
40011f34:	80 a0 80 01 	cmp  %g2, %g1                                  
40011f38:	1a 80 00 1c 	bcc  40011fa8 <fat_free_fat_clusters_chain+0x94>
40011f3c:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        rc = fat_get_fat_cluster(fs_info, cur_cln, &next_cln);        
40011f40:	92 10 00 1c 	mov  %i4, %o1                                  
40011f44:	7f ff fe e8 	call  40011ae4 <fat_get_fat_cluster>           
40011f48:	94 07 bf fc 	add  %fp, -4, %o2                              
        if ( rc != RC_OK )                                            
40011f4c:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40011f50:	02 80 00 0c 	be  40011f80 <fat_free_fat_clusters_chain+0x6c><== ALWAYS TAKEN
40011f54:	90 10 00 18 	mov  %i0, %o0                                  
        {                                                             
              if(fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)        
40011f58:	c2 06 20 44 	ld  [ %i0 + 0x44 ], %g1                        <== NOT EXECUTED
40011f5c:	80 a0 7f ff 	cmp  %g1, -1                                   <== NOT EXECUTED
40011f60:	02 80 00 04 	be  40011f70 <fat_free_fat_clusters_chain+0x5c><== NOT EXECUTED
40011f64:	ba 07 40 01 	add  %i5, %g1, %i5                             <== NOT EXECUTED
                fs_info->vol.free_cls += freed_cls_cnt;               
40011f68:	fa 26 20 44 	st  %i5, [ %i0 + 0x44 ]                        <== NOT EXECUTED
                                                                      
            fat_buf_release(fs_info);                                 
40011f6c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40011f70:	40 00 03 cb 	call  40012e9c <fat_buf_release>               <== NOT EXECUTED
40011f74:	b0 10 00 1a 	mov  %i2, %i0                                  <== NOT EXECUTED
            return rc;                                                
40011f78:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011f7c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
        }                                                             
                                                                      
        rc = fat_set_fat_cluster(fs_info, cur_cln, FAT_GENFAT_FREE);  
40011f80:	92 10 00 1c 	mov  %i4, %o1                                  
40011f84:	7f ff ff 46 	call  40011c9c <fat_set_fat_cluster>           
40011f88:	94 10 20 00 	clr  %o2                                       
        if ( rc != RC_OK )                                            
40011f8c:	80 a2 20 00 	cmp  %o0, 0                                    
40011f90:	22 80 00 02 	be,a   40011f98 <fat_free_fat_clusters_chain+0x84><== ALWAYS TAKEN
40011f94:	90 10 00 1b 	mov  %i3, %o0                                  
            rc1 = rc;                                                 
                                                                      
        freed_cls_cnt++;                                              
40011f98:	ba 07 60 01 	inc  %i5                                       
        cur_cln = next_cln;                                           
40011f9c:	f8 07 bf fc 	ld  [ %fp + -4 ], %i4                          
40011fa0:	10 bf ff e2 	b  40011f28 <fat_free_fat_clusters_chain+0x14> 
40011fa4:	b6 10 00 08 	mov  %o0, %i3                                  
    }                                                                 
                                                                      
        fs_info->vol.next_cl = chain;                                 
        if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)             
40011fa8:	c2 06 20 44 	ld  [ %i0 + 0x44 ], %g1                        
40011fac:	80 a0 7f ff 	cmp  %g1, -1                                   
40011fb0:	02 80 00 04 	be  40011fc0 <fat_free_fat_clusters_chain+0xac><== ALWAYS TAKEN
40011fb4:	f2 26 20 4c 	st  %i1, [ %i0 + 0x4c ]                        
            fs_info->vol.free_cls += freed_cls_cnt;                   
40011fb8:	ba 07 40 01 	add  %i5, %g1, %i5                             <== NOT EXECUTED
40011fbc:	fa 26 20 44 	st  %i5, [ %i0 + 0x44 ]                        <== NOT EXECUTED
                                                                      
    fat_buf_release(fs_info);                                         
40011fc0:	90 10 00 18 	mov  %i0, %o0                                  
40011fc4:	40 00 03 b6 	call  40012e9c <fat_buf_release>               
40011fc8:	b0 10 00 1b 	mov  %i3, %i0                                  
    if (rc1 != RC_OK)                                                 
        return rc1;                                                   
                                                                      
    return RC_OK;                                                     
}                                                                     
40011fcc:	81 c7 e0 08 	ret                                            
40011fd0:	81 e8 00 00 	restore                                        
                                                                      

40013f34 <fat_free_unique_ino>: fat_free_unique_ino( fat_fs_info_t *fs_info, uint32_t ino ) { FAT_SET_UNIQ_INO_FREE((ino - fs_info->uino_base), fs_info->uino);
40013f34:	c2 02 20 80 	ld  [ %o0 + 0x80 ], %g1                        <== NOT EXECUTED
40013f38:	c4 02 20 74 	ld  [ %o0 + 0x74 ], %g2                        <== NOT EXECUTED
40013f3c:	86 10 20 01 	mov  1, %g3                                    <== NOT EXECUTED
40013f40:	92 22 40 01 	sub  %o1, %g1, %o1                             <== NOT EXECUTED
40013f44:	83 32 60 03 	srl  %o1, 3, %g1                               <== NOT EXECUTED
40013f48:	92 0a 60 07 	and  %o1, 7, %o1                               <== NOT EXECUTED
40013f4c:	93 28 c0 09 	sll  %g3, %o1, %o1                             <== NOT EXECUTED
40013f50:	c6 08 80 01 	ldub  [ %g2 + %g1 ], %g3                       <== NOT EXECUTED
40013f54:	92 28 c0 09 	andn  %g3, %o1, %o1                            <== NOT EXECUTED
40013f58:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
40013f5c:	d2 28 80 01 	stb  %o1, [ %g2 + %g1 ]                        <== NOT EXECUTED
                                                                      

40011ae4 <fat_get_fat_cluster>: fat_get_fat_cluster( fat_fs_info_t *fs_info, uint32_t cln, uint32_t *ret_val ) {
40011ae4:	9d e3 bf 98 	save  %sp, -104, %sp                           
    uint8_t                *sec_buf;                                  
    uint32_t                sec = 0;                                  
    uint32_t                ofs = 0;                                  
                                                                      
    /* sanity check */                                                
    if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )           
40011ae8:	80 a6 60 01 	cmp  %i1, 1                                    
40011aec:	08 80 00 66 	bleu  40011c84 <fat_get_fat_cluster+0x1a0>     <== NEVER TAKEN
40011af0:	ba 10 00 18 	mov  %i0, %i5                                  
40011af4:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
40011af8:	82 00 60 01 	inc  %g1                                       
40011afc:	80 a6 40 01 	cmp  %i1, %g1                                  
40011b00:	18 80 00 61 	bgu  40011c84 <fat_get_fat_cluster+0x1a0>      <== NEVER TAKEN
40011b04:	01 00 00 00 	nop                                            
        rtems_set_errno_and_return_minus_one(EIO);                    
                                                                      
    sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
40011b08:	c4 0e 20 0e 	ldub  [ %i0 + 0xe ], %g2                       
40011b0c:	86 88 a0 01 	andcc  %g2, 1, %g3                             
40011b10:	02 80 00 05 	be  40011b24 <fat_get_fat_cluster+0x40>        
40011b14:	80 88 a0 02 	btst  2, %g2                                   
40011b18:	83 36 60 01 	srl  %i1, 1, %g1                               
40011b1c:	10 80 00 05 	b  40011b30 <fat_get_fat_cluster+0x4c>         
40011b20:	82 00 40 19 	add  %g1, %i1, %g1                             
40011b24:	02 80 00 03 	be  40011b30 <fat_get_fat_cluster+0x4c>        
40011b28:	83 2e 60 02 	sll  %i1, 2, %g1                               
40011b2c:	83 2e 60 01 	sll  %i1, 1, %g1                               
40011b30:	f6 0f 60 02 	ldub  [ %i5 + 2 ], %i3                         
40011b34:	c8 07 60 58 	ld  [ %i5 + 0x58 ], %g4                        
40011b38:	83 30 40 1b 	srl  %g1, %i3, %g1                             
          fs_info->vol.afat_loc;                                      
    ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
40011b3c:	80 a0 e0 00 	cmp  %g3, 0                                    
40011b40:	02 80 00 05 	be  40011b54 <fat_get_fat_cluster+0x70>        
40011b44:	b6 00 40 04 	add  %g1, %g4, %i3                             
40011b48:	b9 36 60 01 	srl  %i1, 1, %i4                               
40011b4c:	10 80 00 06 	b  40011b64 <fat_get_fat_cluster+0x80>         
40011b50:	b8 07 00 19 	add  %i4, %i1, %i4                             
40011b54:	80 88 a0 02 	btst  2, %g2                                   
40011b58:	02 80 00 03 	be  40011b64 <fat_get_fat_cluster+0x80>        
40011b5c:	b9 2e 60 02 	sll  %i1, 2, %i4                               
40011b60:	b9 2e 60 01 	sll  %i1, 1, %i4                               
40011b64:	e0 17 40 00 	lduh  [ %i5 ], %l0                             
                                                                      
    rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &sec_buf);    
40011b68:	90 10 00 1d 	mov  %i5, %o0                                  
40011b6c:	92 10 00 1b 	mov  %i3, %o1                                  
40011b70:	94 10 20 01 	mov  1, %o2                                    
40011b74:	40 00 05 3b 	call  40013060 <fat_buf_access>                
40011b78:	96 07 bf fc 	add  %fp, -4, %o3                              
    if (rc != RC_OK)                                                  
40011b7c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011b80:	12 80 00 39 	bne  40011c64 <fat_get_fat_cluster+0x180>      <== NEVER TAKEN
40011b84:	83 2c 20 10 	sll  %l0, 0x10, %g1                            
        return rc;                                                    
                                                                      
    switch ( fs_info->vol.type )                                      
40011b88:	c4 0f 60 0e 	ldub  [ %i5 + 0xe ], %g2                       
40011b8c:	80 a0 a0 02 	cmp  %g2, 2                                    
    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);
40011b90:	83 30 60 10 	srl  %g1, 0x10, %g1                            
40011b94:	82 00 7f ff 	add  %g1, -1, %g1                              
                                                                      
    rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &sec_buf);    
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    switch ( fs_info->vol.type )                                      
40011b98:	02 80 00 29 	be  40011c3c <fat_get_fat_cluster+0x158>       
40011b9c:	82 0f 00 01 	and  %i4, %g1, %g1                             
40011ba0:	80 a0 a0 04 	cmp  %g2, 4                                    
40011ba4:	02 80 00 32 	be  40011c6c <fat_get_fat_cluster+0x188>       
40011ba8:	80 a0 a0 01 	cmp  %g2, 1                                    
40011bac:	12 80 00 36 	bne  40011c84 <fat_get_fat_cluster+0x1a0>      <== NEVER TAKEN
40011bb0:	c6 07 bf fc 	ld  [ %fp + -4 ], %g3                          
            /*                                                        
             * we are enforced in complex computations for FAT12 to escape CPU
             * align problems for some architectures                  
             */                                                       
            *ret_val = (*(sec_buf + ofs));                            
            if ( ofs == (fs_info->vol.bps - 1) )                      
40011bb4:	c8 17 40 00 	lduh  [ %i5 ], %g4                             
        case FAT_FAT12:                                               
            /*                                                        
             * we are enforced in complex computations for FAT12 to escape CPU
             * align problems for some architectures                  
             */                                                       
            *ret_val = (*(sec_buf + ofs));                            
40011bb8:	c4 08 c0 01 	ldub  [ %g3 + %g1 ], %g2                       
            if ( ofs == (fs_info->vol.bps - 1) )                      
40011bbc:	88 01 3f ff 	add  %g4, -1, %g4                              
40011bc0:	80 a0 40 04 	cmp  %g1, %g4                                  
40011bc4:	12 80 00 10 	bne  40011c04 <fat_get_fat_cluster+0x120>      
40011bc8:	c4 26 80 00 	st  %g2, [ %i2 ]                               
            {                                                         
                rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
40011bcc:	90 10 00 1d 	mov  %i5, %o0                                  
40011bd0:	92 06 e0 01 	add  %i3, 1, %o1                               
40011bd4:	94 10 20 01 	mov  1, %o2                                    
40011bd8:	40 00 05 22 	call  40013060 <fat_buf_access>                
40011bdc:	96 07 bf fc 	add  %fp, -4, %o3                              
                                    &sec_buf);                        
                if (rc != RC_OK)                                      
40011be0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011be4:	12 80 00 20 	bne  40011c64 <fat_get_fat_cluster+0x180>      <== NEVER TAKEN
40011be8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                    return rc;                                        
                                                                      
                *ret_val |= *sec_buf << 8;                            
40011bec:	c4 06 80 00 	ld  [ %i2 ], %g2                               
40011bf0:	c2 08 40 00 	ldub  [ %g1 ], %g1                             
40011bf4:	83 28 60 08 	sll  %g1, 8, %g1                               
40011bf8:	82 10 80 01 	or  %g2, %g1, %g1                              
40011bfc:	10 80 00 07 	b  40011c18 <fat_get_fat_cluster+0x134>        
40011c00:	c2 26 80 00 	st  %g1, [ %i2 ]                               
            }                                                         
            else                                                      
            {                                                         
                *ret_val |= *(sec_buf + ofs + 1) << 8;                
40011c04:	82 00 c0 01 	add  %g3, %g1, %g1                             
40011c08:	c2 08 60 01 	ldub  [ %g1 + 1 ], %g1                         
40011c0c:	83 28 60 08 	sll  %g1, 8, %g1                               
40011c10:	84 10 40 02 	or  %g1, %g2, %g2                              
40011c14:	c4 26 80 00 	st  %g2, [ %i2 ]                               
            }                                                         
                                                                      
            if ( FAT_CLUSTER_IS_ODD(cln) )                            
40011c18:	80 8e 60 01 	btst  1, %i1                                   
40011c1c:	02 80 00 04 	be  40011c2c <fat_get_fat_cluster+0x148>       
40011c20:	c2 06 80 00 	ld  [ %i2 ], %g1                               
                *ret_val = (*ret_val) >> FAT12_SHIFT;                 
40011c24:	10 80 00 03 	b  40011c30 <fat_get_fat_cluster+0x14c>        
40011c28:	83 30 60 04 	srl  %g1, 4, %g1                               
            else                                                      
                *ret_val = (*ret_val) & FAT_FAT12_MASK;               
40011c2c:	82 08 6f ff 	and  %g1, 0xfff, %g1                           
40011c30:	c2 26 80 00 	st  %g1, [ %i2 ]                               
        default:                                                      
            rtems_set_errno_and_return_minus_one(EIO);                
            break;                                                    
    }                                                                 
                                                                      
    return RC_OK;                                                     
40011c34:	81 c7 e0 08 	ret                                            
40011c38:	91 e8 20 00 	restore  %g0, 0, %o0                           
            else                                                      
                *ret_val = (*ret_val) & FAT_FAT12_MASK;               
            break;                                                    
                                                                      
        case FAT_FAT16:                                               
            *ret_val = *((uint16_t   *)(sec_buf + ofs));              
40011c3c:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
40011c40:	c2 10 80 01 	lduh  [ %g2 + %g1 ], %g1                       
            *ret_val = CF_LE_W(*ret_val);                             
40011c44:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
40011c48:	83 28 60 10 	sll  %g1, 0x10, %g1                            
40011c4c:	84 10 a3 ff 	or  %g2, 0x3ff, %g2                            
40011c50:	87 30 60 08 	srl  %g1, 8, %g3                               
40011c54:	83 30 60 18 	srl  %g1, 0x18, %g1                            
40011c58:	84 08 c0 02 	and  %g3, %g2, %g2                             
40011c5c:	82 10 80 01 	or  %g2, %g1, %g1                              
40011c60:	c2 26 80 00 	st  %g1, [ %i2 ]                               
            break;                                                    
40011c64:	81 c7 e0 08 	ret                                            
40011c68:	81 e8 00 00 	restore                                        
                                                                      
        case FAT_FAT32:                                               
            *ret_val = *((uint32_t   *)(sec_buf + ofs));              
            *ret_val = CF_LE_L(*ret_val);                             
40011c6c:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
40011c70:	7f ff ff 91 	call  40011ab4 <CPU_swap_u32>                  
40011c74:	d0 00 80 01 	ld  [ %g2 + %g1 ], %o0                         
40011c78:	d0 26 80 00 	st  %o0, [ %i2 ]                               
            break;                                                    
40011c7c:	81 c7 e0 08 	ret                                            
40011c80:	81 e8 00 00 	restore                                        
                                                                      
        default:                                                      
            rtems_set_errno_and_return_minus_one(EIO);                
40011c84:	40 00 2a 02 	call  4001c48c <__errno>                       <== NOT EXECUTED
40011c88:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40011c8c:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40011c90:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
            break;                                                    
    }                                                                 
                                                                      
    return RC_OK;                                                     
}                                                                     
40011c94:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011c98:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40013e74 <fat_get_unique_ino>: * 0 means FAILED !!! * */ uint32_t fat_get_unique_ino(fat_fs_info_t *fs_info) {
40013e74:	9d e3 bf a0 	save  %sp, -96, %sp                            <== 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))
40013e78:	39 03 ff ff 	sethi  %hi(0xffffc00), %i4                     <== NOT EXECUTED
40013e7c:	b8 17 23 ff 	or  %i4, 0x3ff, %i4	! fffffff <RAM_SIZE+0xfbfffff><== NOT EXECUTED
    uint32_t                j = 0;                                    
    bool                    resrc_unsuff = false;                     
                                                                      
    while (!resrc_unsuff)                                             
    {                                                                 
        for (j = 0; j < fs_info->uino_pool_size; j++)                 
40013e80:	c8 06 20 7c 	ld  [ %i0 + 0x7c ], %g4                        <== NOT EXECUTED
40013e84:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
40013e88:	80 a2 40 04 	cmp  %o1, %g4                                  <== NOT EXECUTED
40013e8c:	22 80 00 1b 	be,a   40013ef8 <fat_get_unique_ino+0x84>      <== NOT EXECUTED
40013e90:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        <== NOT EXECUTED
        {                                                             
            if (!FAT_UNIQ_INO_IS_BUSY(fs_info->index, fs_info->uino)) 
40013e94:	c6 06 20 74 	ld  [ %i0 + 0x74 ], %g3                        <== NOT EXECUTED
40013e98:	c2 06 20 78 	ld  [ %i0 + 0x78 ], %g1                        <== NOT EXECUTED
40013e9c:	85 30 60 03 	srl  %g1, 3, %g2                               <== NOT EXECUTED
40013ea0:	b6 00 c0 02 	add  %g3, %g2, %i3                             <== NOT EXECUTED
40013ea4:	f4 08 c0 02 	ldub  [ %g3 + %g2 ], %i2                       <== NOT EXECUTED
40013ea8:	c4 48 c0 02 	ldsb  [ %g3 + %g2 ], %g2                       <== NOT EXECUTED
40013eac:	ba 08 60 07 	and  %g1, 7, %i5                               <== NOT EXECUTED
40013eb0:	85 38 80 1d 	sra  %g2, %i5, %g2                             <== NOT EXECUTED
40013eb4:	80 88 a0 01 	btst  1, %g2                                   <== NOT EXECUTED
40013eb8:	12 80 00 0a 	bne  40013ee0 <fat_get_unique_ino+0x6c>        <== NOT EXECUTED
40013ebc:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
            {                                                         
                FAT_SET_UNIQ_INO_BUSY(fs_info->index, fs_info->uino); 
40013ec0:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
40013ec4:	bb 28 40 1d 	sll  %g1, %i5, %i5                             <== NOT EXECUTED
40013ec8:	ba 17 40 1a 	or  %i5, %i2, %i5                              <== NOT EXECUTED
40013ecc:	fa 2e c0 00 	stb  %i5, [ %i3 ]                              <== NOT EXECUTED
                return (fs_info->uino_base + fs_info->index);         
40013ed0:	c4 06 20 78 	ld  [ %i0 + 0x78 ], %g2                        <== NOT EXECUTED
40013ed4:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        <== NOT EXECUTED
40013ed8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013edc:	91 e8 80 01 	restore  %g2, %g1, %o0                         <== NOT EXECUTED
            }                                                         
            fs_info->index++;                                         
            if (fs_info->index >= fs_info->uino_pool_size)            
40013ee0:	80 a0 40 04 	cmp  %g1, %g4                                  <== NOT EXECUTED
40013ee4:	3a 80 00 03 	bcc,a   40013ef0 <fat_get_unique_ino+0x7c>     <== NOT EXECUTED
40013ee8:	c0 26 20 78 	clr  [ %i0 + 0x78 ]                            <== NOT EXECUTED
40013eec:	c2 26 20 78 	st  %g1, [ %i0 + 0x78 ]                        <== NOT EXECUTED
    uint32_t                j = 0;                                    
    bool                    resrc_unsuff = false;                     
                                                                      
    while (!resrc_unsuff)                                             
    {                                                                 
        for (j = 0; j < fs_info->uino_pool_size; j++)                 
40013ef0:	10 bf ff e6 	b  40013e88 <fat_get_unique_ino+0x14>          <== NOT EXECUTED
40013ef4:	92 02 60 01 	inc  %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))
40013ef8:	93 2a 60 01 	sll  %o1, 1, %o1                               <== NOT EXECUTED
40013efc:	82 27 00 01 	sub  %i4, %g1, %g1                             <== NOT EXECUTED
40013f00:	80 a2 40 01 	cmp  %o1, %g1                                  <== NOT EXECUTED
40013f04:	2a 80 00 04 	bcs,a   40013f14 <fat_get_unique_ino+0xa0>     <== NOT EXECUTED
40013f08:	d0 06 20 74 	ld  [ %i0 + 0x74 ], %o0                        <== NOT EXECUTED
                resrc_unsuff = true;                                  
        }                                                             
        else                                                          
            resrc_unsuff = true;                                      
    }                                                                 
    return 0;                                                         
40013f0c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013f10:	91 e8 20 00 	restore  %g0, 0, %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);
40013f14:	7f ff c7 28 	call  40005bb4 <realloc>                       <== NOT EXECUTED
40013f18:	d2 26 20 7c 	st  %o1, [ %i0 + 0x7c ]                        <== NOT EXECUTED
            if (fs_info->uino != NULL)                                
40013f1c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40013f20:	02 bf ff fb 	be  40013f0c <fat_get_unique_ino+0x98>         <== NOT EXECUTED
40013f24:	d0 26 20 74 	st  %o0, [ %i0 + 0x74 ]                        <== NOT EXECUTED
                fs_info->index = fs_info->uino_pool_size;             
40013f28:	c2 06 20 7c 	ld  [ %i0 + 0x7c ], %g1                        <== NOT EXECUTED
40013f2c:	10 bf ff d5 	b  40013e80 <fat_get_unique_ino+0xc>           <== NOT EXECUTED
40013f30:	c2 26 20 78 	st  %g1, [ %i0 + 0x78 ]                        <== NOT EXECUTED
                                                                      

40013e00 <fat_init_clusters_chain>: int fat_init_clusters_chain( fat_fs_info_t *fs_info, uint32_t start_cln ) {
40013e00:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                     rc = RC_OK;                               
    ssize_t                 ret = 0;                                  
    uint32_t                cur_cln = start_cln;                      
40013e04:	f2 27 bf fc 	st  %i1, [ %fp + -4 ]                          
                                                                      
    while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)      
40013e08:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
40013e0c:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
40013e10:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
40013e14:	84 0a 40 02 	and  %o1, %g2, %g2                             
40013e18:	80 a0 80 01 	cmp  %g2, %g1                                  
40013e1c:	1a 80 00 12 	bcc  40013e64 <fat_init_clusters_chain+0x64>   
40013e20:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        ret = fat_cluster_set(fs_info, cur_cln, 0, fs_info->vol.bpc, 0);
40013e24:	d6 16 20 06 	lduh  [ %i0 + 6 ], %o3                         
40013e28:	94 10 20 00 	clr  %o2                                       
40013e2c:	7f ff fd 00 	call  4001322c <fat_cluster_set>               
40013e30:	98 10 20 00 	clr  %o4                                       
        if ( ret != fs_info->vol.bpc )                                
40013e34:	c2 16 20 06 	lduh  [ %i0 + 6 ], %g1                         
40013e38:	80 a2 00 01 	cmp  %o0, %g1                                  
40013e3c:	12 80 00 0c 	bne  40013e6c <fat_init_clusters_chain+0x6c>   <== NEVER TAKEN
40013e40:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
        {                                                             
            return -1;                                                
        }                                                             
                                                                      
        rc  = fat_get_fat_cluster(fs_info, cur_cln, &cur_cln);        
40013e44:	90 10 00 18 	mov  %i0, %o0                                  
40013e48:	7f ff f7 27 	call  40011ae4 <fat_get_fat_cluster>           
40013e4c:	94 07 bf fc 	add  %fp, -4, %o2                              
        if ( rc != RC_OK )                                            
40013e50:	80 a2 20 00 	cmp  %o0, 0                                    
40013e54:	02 bf ff ee 	be  40013e0c <fat_init_clusters_chain+0xc>     <== ALWAYS TAKEN
40013e58:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
        }                                                             
                                                                      
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
40013e5c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013e60:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
40013e64:	81 c7 e0 08 	ret                                            
40013e68:	91 e8 20 00 	restore  %g0, 0, %o0                           
    while ((cur_cln & fs_info->vol.mask) < fs_info->vol.eoc_val)      
    {                                                                 
        ret = fat_cluster_set(fs_info, cur_cln, 0, fs_info->vol.bpc, 0);
        if ( ret != fs_info->vol.bpc )                                
        {                                                             
            return -1;                                                
40013e6c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013e70:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      

4001345c <fat_init_volume_info>: * RC_OK on success, or -1 if error occured * and errno set appropriately */ int fat_init_volume_info(fat_fs_info_t *fs_info, const char *device) {
4001345c:	9d e3 bf 18 	save  %sp, -232, %sp                           
    ssize_t             ret = 0;                                      
    struct stat         stat_buf;                                     
    int                 i = 0;                                        
    rtems_bdbuf_buffer *block = NULL;                                 
                                                                      
    vol->fd = open(device, O_RDWR);                                   
40013460:	92 10 20 02 	mov  2, %o1                                    
 *     RC_OK on success, or -1 if error occured                       
 *     and errno set appropriately                                    
 */                                                                   
int                                                                   
fat_init_volume_info(fat_fs_info_t *fs_info, const char *device)      
{                                                                     
40013464:	b4 10 00 18 	mov  %i0, %i2                                  
    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;                                 
40013468:	c0 27 bf a4 	clr  [ %fp + -92 ]                             
                                                                      
    vol->fd = open(device, O_RDWR);                                   
4001346c:	7f ff c9 25 	call  40005900 <open>                          
40013470:	90 10 00 19 	mov  %i1, %o0                                  
    if (vol->fd < 0)                                                  
40013474:	80 a2 20 00 	cmp  %o0, 0                                    
40013478:	06 80 00 09 	bl  4001349c <fat_init_volume_info+0x40>       <== NEVER TAKEN
4001347c:	d0 26 a0 60 	st  %o0, [ %i2 + 0x60 ]                        
    {                                                                 
        rtems_set_errno_and_return_minus_one(ENXIO);                  
    }                                                                 
                                                                      
    rc = fstat(vol->fd, &stat_buf);                                   
40013480:	7f ff c6 7f 	call  40004e7c <fstat>                         
40013484:	92 07 bf b8 	add  %fp, -72, %o1                             
    if (rc != 0)                                                      
40013488:	80 a2 20 00 	cmp  %o0, 0                                    
4001348c:	02 80 00 0a 	be  400134b4 <fat_init_volume_info+0x58>       <== ALWAYS TAKEN
40013490:	d0 06 20 60 	ld  [ %i0 + 0x60 ], %o0                        
    {                                                                 
        close(vol->fd);                                               
40013494:	7f ff c6 2d 	call  40004d48 <close>                         <== NOT EXECUTED
40013498:	01 00 00 00 	nop                                            <== NOT EXECUTED
        rtems_set_errno_and_return_minus_one(ENXIO);                  
4001349c:	40 00 23 fc 	call  4001c48c <__errno>                       <== NOT EXECUTED
400134a0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400134a4:	82 10 20 06 	mov  6, %g1	! 6 <_TLS_Alignment+0x5>           <== NOT EXECUTED
400134a8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
400134ac:	10 80 01 d9 	b  40013c10 <fat_init_volume_info+0x7b4>       <== NOT EXECUTED
400134b0:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
    }                                                                 
                                                                      
    /* Must be a block device. */                                     
    if (!S_ISBLK(stat_buf.st_mode))                                   
400134b4:	c6 07 bf c4 	ld  [ %fp + -60 ], %g3                         
400134b8:	05 00 00 3c 	sethi  %hi(0xf000), %g2                        
400134bc:	86 08 c0 02 	and  %g3, %g2, %g3                             
400134c0:	05 00 00 18 	sethi  %hi(0x6000), %g2                        
400134c4:	80 a0 c0 02 	cmp  %g3, %g2                                  
400134c8:	12 bf ff f3 	bne  40013494 <fat_init_volume_info+0x38>      <== NEVER TAKEN
400134cc:	13 10 01 10 	sethi  %hi(0x40044000), %o1                    
static inline int rtems_disk_fd_get_disk_device(                      
  int fd,                                                             
  rtems_disk_device **dd_ptr                                          
)                                                                     
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_GETDISKDEV, dd_ptr);                   
400134d0:	94 06 20 64 	add  %i0, 0x64, %o2                            
400134d4:	40 00 05 51 	call  40014a18 <ioctl>                         
400134d8:	92 12 62 09 	or  %o1, 0x209, %o1                            
        rtems_set_errno_and_return_minus_one(ENXIO);                  
    }                                                                 
                                                                      
    /* check that device is registred as block device and lock it */  
    rc = rtems_disk_fd_get_disk_device(vol->fd, &vol->dd);            
    if (rc != 0) {                                                    
400134dc:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400134e0:	22 80 00 04 	be,a   400134f0 <fat_init_volume_info+0x94>    <== ALWAYS TAKEN
400134e4:	d0 06 20 64 	ld  [ %i0 + 0x64 ], %o0                        
        close(vol->fd);                                               
400134e8:	10 bf ff eb 	b  40013494 <fat_init_volume_info+0x38>        <== NOT EXECUTED
400134ec:	d0 06 20 60 	ld  [ %i0 + 0x60 ], %o0                        <== NOT EXECUTED
        rtems_set_errno_and_return_minus_one(ENXIO);                  
    }                                                                 
                                                                      
    /* Read boot record */                                            
    /* FIXME: Asserts FAT_MAX_BPB_SIZE < bdbuf block size */          
    sc = rtems_bdbuf_read( vol->dd, 0, &block);                       
400134f0:	92 10 20 00 	clr  %o1                                       
400134f4:	7f ff f5 d8 	call  40010c54 <rtems_bdbuf_read>              
400134f8:	94 07 bf a4 	add  %fp, -92, %o2                             
    if (sc != RTEMS_SUCCESSFUL)                                       
400134fc:	80 a2 20 00 	cmp  %o0, 0                                    
40013500:	12 80 00 31 	bne  400135c4 <fat_init_volume_info+0x168>     <== NEVER TAKEN
40013504:	01 00 00 00 	nop                                            
    {                                                                 
        close(vol->fd);                                               
        rtems_set_errno_and_return_minus_one( EIO);                   
    }                                                                 
                                                                      
    memcpy( boot_rec, block->buffer, FAT_MAX_BPB_SIZE);               
40013508:	d0 07 bf a4 	ld  [ %fp + -92 ], %o0                         
4001350c:	c8 02 20 1c 	ld  [ %o0 + 0x1c ], %g4                        
40013510:	c2 09 20 13 	ldub  [ %g4 + 0x13 ], %g1                      
40013514:	c4 09 20 0b 	ldub  [ %g4 + 0xb ], %g2                       
40013518:	c2 2f bf 98 	stb  %g1, [ %fp + -104 ]                       
4001351c:	c2 09 20 14 	ldub  [ %g4 + 0x14 ], %g1                      
40013520:	c6 09 20 0c 	ldub  [ %g4 + 0xc ], %g3                       
40013524:	c2 2f bf 87 	stb  %g1, [ %fp + -121 ]                       
40013528:	c2 09 20 20 	ldub  [ %g4 + 0x20 ], %g1                      
4001352c:	f8 09 20 0d 	ldub  [ %g4 + 0xd ], %i4                       
40013530:	c2 2f bf 86 	stb  %g1, [ %fp + -122 ]                       
40013534:	c2 09 20 21 	ldub  [ %g4 + 0x21 ], %g1                      
40013538:	ee 09 20 0e 	ldub  [ %g4 + 0xe ], %l7                       
4001353c:	c2 2f bf 85 	stb  %g1, [ %fp + -123 ]                       
40013540:	c2 09 20 22 	ldub  [ %g4 + 0x22 ], %g1                      
40013544:	f0 09 20 0f 	ldub  [ %g4 + 0xf ], %i0                       
40013548:	c2 2f bf 9b 	stb  %g1, [ %fp + -101 ]                       
4001354c:	c2 09 20 23 	ldub  [ %g4 + 0x23 ], %g1                      
40013550:	f2 09 20 10 	ldub  [ %g4 + 0x10 ], %i1                      
40013554:	c2 2f bf 8f 	stb  %g1, [ %fp + -113 ]                       
40013558:	c2 09 20 24 	ldub  [ %g4 + 0x24 ], %g1                      
4001355c:	ea 09 20 11 	ldub  [ %g4 + 0x11 ], %l5                      
40013560:	c2 2f bf 9a 	stb  %g1, [ %fp + -102 ]                       
40013564:	c2 09 20 25 	ldub  [ %g4 + 0x25 ], %g1                      
40013568:	ec 09 20 12 	ldub  [ %g4 + 0x12 ], %l6                      
4001356c:	c2 2f bf 99 	stb  %g1, [ %fp + -103 ]                       
40013570:	c2 09 20 26 	ldub  [ %g4 + 0x26 ], %g1                      
40013574:	e6 09 20 16 	ldub  [ %g4 + 0x16 ], %l3                      
40013578:	c2 2f bf 9c 	stb  %g1, [ %fp + -100 ]                       
4001357c:	c2 09 20 27 	ldub  [ %g4 + 0x27 ], %g1                      
40013580:	e8 09 20 17 	ldub  [ %g4 + 0x17 ], %l4                      
40013584:	c2 2f bf 97 	stb  %g1, [ %fp + -105 ]                       
40013588:	c2 09 20 2c 	ldub  [ %g4 + 0x2c ], %g1                      
4001358c:	f6 09 20 28 	ldub  [ %g4 + 0x28 ], %i3                      
40013590:	c2 2f bf 9f 	stb  %g1, [ %fp + -97 ]                        
40013594:	c2 09 20 2d 	ldub  [ %g4 + 0x2d ], %g1                      
40013598:	e4 09 20 2e 	ldub  [ %g4 + 0x2e ], %l2                      
4001359c:	c2 2f bf 9e 	stb  %g1, [ %fp + -98 ]                        
400135a0:	c2 09 20 30 	ldub  [ %g4 + 0x30 ], %g1                      
400135a4:	e2 09 20 2f 	ldub  [ %g4 + 0x2f ], %l1                      
400135a8:	e0 09 20 31 	ldub  [ %g4 + 0x31 ], %l0                      
400135ac:	c2 2f bf 9d 	stb  %g1, [ %fp + -99 ]                        
                                                                      
    sc = rtems_bdbuf_release( block);                                 
400135b0:	7f ff f6 18 	call  40010e10 <rtems_bdbuf_release>           
400135b4:	c4 3f bf 78 	std  %g2, [ %fp + -136 ]                       
    if (sc != RTEMS_SUCCESSFUL)                                       
400135b8:	80 a2 20 00 	cmp  %o0, 0                                    
400135bc:	02 80 00 08 	be  400135dc <fat_init_volume_info+0x180>      <== ALWAYS TAKEN
400135c0:	c4 1f bf 78 	ldd  [ %fp + -136 ], %g2                       
    {                                                                 
        close(vol->fd);                                               
400135c4:	7f ff c5 e1 	call  40004d48 <close>                         <== NOT EXECUTED
400135c8:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
        rtems_set_errno_and_return_minus_one( EIO );                  
400135cc:	40 00 23 b0 	call  4001c48c <__errno>                       <== NOT EXECUTED
400135d0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400135d4:	10 bf ff b5 	b  400134a8 <fat_init_volume_info+0x4c>        <== NOT EXECUTED
400135d8:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
    }                                                                 
                                                                      
    /* Evaluate boot record */                                        
    vol->bps = FAT_GET_BR_BYTES_PER_SECTOR(boot_rec);                 
400135dc:	86 08 e0 ff 	and  %g3, 0xff, %g3                            
400135e0:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
400135e4:	87 28 e0 08 	sll  %g3, 8, %g3                               
400135e8:	84 10 c0 02 	or  %g3, %g2, %g2                              
                                                                      
    if ( (vol->bps != 512)  &&                                        
400135ec:	87 28 a0 10 	sll  %g2, 0x10, %g3                            
400135f0:	87 30 e0 10 	srl  %g3, 0x10, %g3                            
400135f4:	80 a0 e2 00 	cmp  %g3, 0x200                                
400135f8:	02 80 00 0b 	be  40013624 <fat_init_volume_info+0x1c8>      <== ALWAYS TAKEN
400135fc:	c4 36 80 00 	sth  %g2, [ %i2 ]                              
40013600:	80 a0 e4 00 	cmp  %g3, 0x400                                <== NOT EXECUTED
40013604:	22 80 00 09 	be,a   40013628 <fat_init_volume_info+0x1cc>   <== NOT EXECUTED
40013608:	87 28 a0 10 	sll  %g2, 0x10, %g3                            <== NOT EXECUTED
         (vol->bps != 1024) &&                                        
4001360c:	80 a0 e8 00 	cmp  %g3, 0x800                                <== NOT EXECUTED
40013610:	02 80 00 05 	be  40013624 <fat_init_volume_info+0x1c8>      <== NOT EXECUTED
40013614:	09 00 00 04 	sethi  %hi(0x1000), %g4                        <== NOT EXECUTED
         (vol->bps != 2048) &&                                        
40013618:	80 a0 c0 04 	cmp  %g3, %g4                                  <== NOT EXECUTED
4001361c:	12 80 00 dc 	bne  4001398c <fat_init_volume_info+0x530>     <== NOT EXECUTED
40013620:	01 00 00 00 	nop                                            <== NOT EXECUTED
         (vol->bps != 4096))                                          
    {                                                                 
        close(vol->fd);                                               
        rtems_set_errno_and_return_minus_one( EINVAL );               
    }                                                                 
    for (vol->sec_mul = 0, i = (vol->bps >> FAT_SECTOR512_BITS); (i & 1) == 0;
40013624:	87 28 a0 10 	sll  %g2, 0x10, %g3                            
40013628:	c0 2e a0 03 	clrb  [ %i2 + 3 ]                              
4001362c:	87 30 e0 19 	srl  %g3, 0x19, %g3                            
40013630:	80 88 e0 01 	btst  1, %g3                                   
40013634:	12 80 00 06 	bne  4001364c <fat_init_volume_info+0x1f0>     <== ALWAYS TAKEN
40013638:	87 38 e0 01 	sra  %g3, 1, %g3                               
         i >>= 1, vol->sec_mul++);                                    
4001363c:	c8 0e a0 03 	ldub  [ %i2 + 3 ], %g4                         <== NOT EXECUTED
40013640:	88 01 20 01 	inc  %g4                                       <== NOT EXECUTED
40013644:	10 bf ff fb 	b  40013630 <fat_init_volume_info+0x1d4>       <== NOT EXECUTED
40013648:	c8 2e a0 03 	stb  %g4, [ %i2 + 3 ]                          <== NOT EXECUTED
    for (vol->sec_log2 = 0, i = vol->bps; (i & 1) == 0;               
4001364c:	93 28 a0 10 	sll  %g2, 0x10, %o1                            
40013650:	c0 2e a0 02 	clrb  [ %i2 + 2 ]                              
40013654:	89 32 60 10 	srl  %o1, 0x10, %g4                            
40013658:	80 89 20 01 	btst  1, %g4                                   
4001365c:	12 80 00 06 	bne  40013674 <fat_init_volume_info+0x218>     
40013660:	89 39 20 01 	sra  %g4, 1, %g4                               
         i >>= 1, vol->sec_log2++);                                   
40013664:	c6 0e a0 02 	ldub  [ %i2 + 2 ], %g3                         
40013668:	86 00 e0 01 	inc  %g3                                       
4001366c:	10 bf ff fb 	b  40013658 <fat_init_volume_info+0x1fc>       
40013670:	c6 2e a0 02 	stb  %g3, [ %i2 + 2 ]                          
                                                                      
    /* Assign the sector size as bdbuf block size for now.            
     * If possible the bdbuf block size will get increased to the cluster
     * size at the end of this method for better performance */       
    sc = rtems_bdbuf_set_block_size (vol->dd, vol->bps, true);        
40013674:	d0 06 a0 64 	ld  [ %i2 + 0x64 ], %o0                        
40013678:	93 32 60 10 	srl  %o1, 0x10, %o1                            
4001367c:	7f ff f6 51 	call  40010fc0 <rtems_bdbuf_set_block_size>    
40013680:	94 10 20 01 	mov  1, %o2                                    
    if (sc != RTEMS_SUCCESSFUL)                                       
40013684:	80 a2 20 00 	cmp  %o0, 0                                    
40013688:	12 80 00 c1 	bne  4001398c <fat_init_volume_info+0x530>     <== NEVER TAKEN
4001368c:	86 10 20 01 	mov  1, %g3                                    
    {                                                                 
      close(vol->fd);                                                 
      rtems_set_errno_and_return_minus_one( EINVAL );                 
    }                                                                 
    vol->bytes_per_block = vol->bps;                                  
40013690:	d2 16 80 00 	lduh  [ %i2 ], %o1                             
    vol->bytes_per_block_log2 = vol->sec_log2;                        
40013694:	c4 0e a0 02 	ldub  [ %i2 + 2 ], %g2                         
    if (sc != RTEMS_SUCCESSFUL)                                       
    {                                                                 
      close(vol->fd);                                                 
      rtems_set_errno_and_return_minus_one( EINVAL );                 
    }                                                                 
    vol->bytes_per_block = vol->bps;                                  
40013698:	d2 36 a0 0a 	sth  %o1, [ %i2 + 0xa ]                        
    vol->bytes_per_block_log2 = vol->sec_log2;                        
4001369c:	c4 2e a0 0c 	stb  %g2, [ %i2 + 0xc ]                        
    vol->sectors_per_block = 1;                                       
400136a0:	c6 2e a0 09 	stb  %g3, [ %i2 + 9 ]                          
    vol->spc = FAT_GET_BR_SECTORS_PER_CLUSTER(boot_rec);              
    /*                                                                
     * "sectors per cluster" of zero is invalid                       
     * (and would hang the following loop)                            
     */                                                               
    if (vol->spc == 0)                                                
400136a4:	88 8f 20 ff 	andcc  %i4, 0xff, %g4                          
400136a8:	02 80 00 b9 	be  4001398c <fat_init_volume_info+0x530>      <== NEVER TAKEN
400136ac:	f8 2e a0 04 	stb  %i4, [ %i2 + 4 ]                          
    {                                                                 
        close(vol->fd);                                               
        rtems_set_errno_and_return_minus_one(EINVAL);                 
    }                                                                 
                                                                      
    for (vol->spc_log2 = 0, i = vol->spc; (i & 1) == 0;               
400136b0:	c0 2e a0 05 	clrb  [ %i2 + 5 ]                              
400136b4:	80 89 20 01 	btst  1, %g4                                   
400136b8:	12 80 00 06 	bne  400136d0 <fat_init_volume_info+0x274>     
400136bc:	c6 0e a0 05 	ldub  [ %i2 + 5 ], %g3                         
         i >>= 1, vol->spc_log2++);                                   
400136c0:	86 00 e0 01 	inc  %g3                                       
400136c4:	89 39 20 01 	sra  %g4, 1, %g4                               
400136c8:	10 bf ff fb 	b  400136b4 <fat_init_volume_info+0x258>       
400136cc:	c6 2e a0 05 	stb  %g3, [ %i2 + 5 ]                          
                                                                      
    /*                                                                
     * "bytes per cluster" value greater than 32K is invalid          
     */                                                               
    if ((vol->bpc = vol->bps << vol->spc_log2) > MS_BYTES_PER_CLUSTER_LIMIT)
400136d0:	93 2a 60 10 	sll  %o1, 0x10, %o1                            
400136d4:	93 32 60 10 	srl  %o1, 0x10, %o1                            
400136d8:	87 2a 40 03 	sll  %o1, %g3, %g3                             
400136dc:	9f 28 e0 10 	sll  %g3, 0x10, %o7                            
400136e0:	09 20 00 00 	sethi  %hi(0x80000000), %g4                    
400136e4:	80 a3 c0 04 	cmp  %o7, %g4                                  
400136e8:	18 80 00 a9 	bgu  4001398c <fat_init_volume_info+0x530>     <== NEVER TAKEN
400136ec:	c6 36 a0 06 	sth  %g3, [ %i2 + 6 ]                          
    {                                                                 
        close(vol->fd);                                               
        rtems_set_errno_and_return_minus_one(EINVAL);                 
    }                                                                 
                                                                      
    for (vol->bpc_log2 = 0, i = vol->bpc; (i & 1) == 0;               
400136f0:	09 00 00 3f 	sethi  %hi(0xfc00), %g4                        
400136f4:	c0 2e a0 08 	clrb  [ %i2 + 8 ]                              
400136f8:	88 11 23 ff 	or  %g4, 0x3ff, %g4                            
400136fc:	86 08 c0 04 	and  %g3, %g4, %g3                             
40013700:	80 88 e0 01 	btst  1, %g3                                   
40013704:	12 80 00 06 	bne  4001371c <fat_init_volume_info+0x2c0>     
40013708:	87 38 e0 01 	sra  %g3, 1, %g3                               
         i >>= 1, vol->bpc_log2++);                                   
4001370c:	c8 0e a0 08 	ldub  [ %i2 + 8 ], %g4                         
40013710:	88 01 20 01 	inc  %g4                                       
40013714:	10 bf ff fb 	b  40013700 <fat_init_volume_info+0x2a4>       
40013718:	c8 2e a0 08 	stb  %g4, [ %i2 + 8 ]                          
    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)) /
4001371c:	86 02 7f ff 	add  %o1, -1, %g3                              
40013720:	c4 27 bf 78 	st  %g2, [ %fp + -136 ]                        
    }                                                                 
                                                                      
    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);                         
40013724:	f2 2e a0 0d 	stb  %i1, [ %i2 + 0xd ]                        
    vol->fat_loc = FAT_GET_BR_RESERVED_SECTORS_NUM(boot_rec);         
40013728:	b0 0e 20 ff 	and  %i0, 0xff, %i0                            
4001372c:	ae 0d e0 ff 	and  %l7, 0xff, %l7                            
40013730:	b1 2e 20 08 	sll  %i0, 8, %i0                               
                                                                      
    vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);        
40013734:	ac 0d a0 ff 	and  %l6, 0xff, %l6                            
                                                                      
    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);         
40013738:	ae 16 00 17 	or  %i0, %l7, %l7                              
                                                                      
    vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);        
4001373c:	ad 2d a0 08 	sll  %l6, 8, %l6                               
                                                                      
    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);         
40013740:	ee 36 a0 18 	sth  %l7, [ %i2 + 0x18 ]                       
                                                                      
    vol->rdir_entrs = FAT_GET_BR_FILES_PER_ROOT_DIR(boot_rec);        
40013744:	aa 0d 60 ff 	and  %l5, 0xff, %l5                            
40013748:	aa 15 80 15 	or  %l6, %l5, %l5                              
4001374c:	ea 36 a0 24 	sth  %l5, [ %i2 + 0x24 ]                       
                                                                      
    /* calculate the count of sectors occupied by the root directory */
    vol->rdir_secs = ((vol->rdir_entrs * FAT_DIRENTRY_SIZE) + (vol->bps - 1)) /
40013750:	ab 2d 60 10 	sll  %l5, 0x10, %l5                            
40013754:	91 35 60 0b 	srl  %l5, 0xb, %o0                             
40013758:	7f ff bc 2a 	call  40002800 <.div>                          
4001375c:	90 02 00 03 	add  %o0, %g3, %o0                             
                     vol->bps;                                        
                                                                      
    vol->rdir_size = vol->rdir_secs << vol->sec_log2;                 
40013760:	c4 07 bf 78 	ld  [ %fp + -136 ], %g2                        
    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)) /
40013764:	d0 26 a0 28 	st  %o0, [ %i2 + 0x28 ]                        
                     vol->bps;                                        
                                                                      
    vol->rdir_size = vol->rdir_secs << vol->sec_log2;                 
40013768:	85 2a 00 02 	sll  %o0, %g2, %g2                             
4001376c:	c4 26 a0 2c 	st  %g2, [ %i2 + 0x2c ]                        
                                                                      
    if ( (FAT_GET_BR_SECTORS_PER_FAT(boot_rec)) != 0)                 
40013770:	a8 0d 20 ff 	and  %l4, 0xff, %l4                            
40013774:	a6 0c e0 ff 	and  %l3, 0xff, %l3                            
40013778:	a9 2d 20 08 	sll  %l4, 8, %l4                               
4001377c:	a6 15 00 13 	or  %l4, %l3, %l3                              
40013780:	a7 2c e0 10 	sll  %l3, 0x10, %l3                            
40013784:	80 a4 e0 00 	cmp  %l3, 0                                    
40013788:	02 80 00 05 	be  4001379c <fat_init_volume_info+0x340>      
4001378c:	aa 10 00 08 	mov  %o0, %l5                                  
        vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT(boot_rec);       
40013790:	a7 34 e0 10 	srl  %l3, 0x10, %l3                            
40013794:	10 80 00 0d 	b  400137c8 <fat_init_volume_info+0x36c>       
40013798:	e6 26 a0 1c 	st  %l3, [ %i2 + 0x1c ]                        
    else                                                              
        vol->fat_length = FAT_GET_BR_SECTORS_PER_FAT32(boot_rec);     
4001379c:	c6 0f bf 99 	ldub  [ %fp + -103 ], %g3                      
400137a0:	c4 0f bf 9c 	ldub  [ %fp + -100 ], %g2                      
400137a4:	87 28 e0 08 	sll  %g3, 8, %g3                               
400137a8:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
400137ac:	c2 0f bf 97 	ldub  [ %fp + -105 ], %g1                      
400137b0:	84 10 c0 02 	or  %g3, %g2, %g2                              
400137b4:	c6 0f bf 9a 	ldub  [ %fp + -102 ], %g3                      
400137b8:	84 10 80 03 	or  %g2, %g3, %g2                              
400137bc:	87 28 60 18 	sll  %g1, 0x18, %g3                            
400137c0:	84 10 80 03 	or  %g2, %g3, %g2                              
400137c4:	c4 26 a0 1c 	st  %g2, [ %i2 + 0x1c ]                        
                                                                      
    vol->data_fsec = vol->fat_loc + vol->fats * vol->fat_length +     
400137c8:	d2 06 a0 1c 	ld  [ %i2 + 0x1c ], %o1                        
400137cc:	7f ff bb d1 	call  40002710 <.umul>                         
400137d0:	90 0e 60 ff 	and  %i1, 0xff, %o0                            
                     vol->rdir_secs;                                  
                                                                      
    /* for  FAT12/16 root dir starts at(sector) */                    
    vol->rdir_loc = vol->fat_loc + vol->fats * vol->fat_length;       
                                                                      
    if ( (FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec)) != 0)             
400137d4:	c4 0f bf 87 	ldub  [ %fp + -121 ], %g2                      
400137d8:	c6 0f bf 98 	ldub  [ %fp + -104 ], %g3                      
    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 +     
400137dc:	af 2d e0 10 	sll  %l7, 0x10, %l7                            
400137e0:	af 35 e0 10 	srl  %l7, 0x10, %l7                            
400137e4:	90 05 c0 08 	add  %l7, %o0, %o0                             
400137e8:	aa 05 40 08 	add  %l5, %o0, %l5                             
                     vol->rdir_secs;                                  
                                                                      
    /* for  FAT12/16 root dir starts at(sector) */                    
    vol->rdir_loc = vol->fat_loc + vol->fats * vol->fat_length;       
400137ec:	d0 26 a0 20 	st  %o0, [ %i2 + 0x20 ]                        
                                                                      
    if ( (FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec)) != 0)             
400137f0:	85 28 a0 08 	sll  %g2, 8, %g2                               
400137f4:	84 10 80 03 	or  %g2, %g3, %g2                              
400137f8:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
400137fc:	80 a0 a0 00 	cmp  %g2, 0                                    
40013800:	02 80 00 04 	be  40013810 <fat_init_volume_info+0x3b4>      
40013804:	ea 26 a0 34 	st  %l5, [ %i2 + 0x34 ]                        
        vol->tot_secs = FAT_GET_BR_TOTAL_SECTORS_NUM16(boot_rec);     
40013808:	10 80 00 0c 	b  40013838 <fat_init_volume_info+0x3dc>       
4001380c:	85 30 a0 10 	srl  %g2, 0x10, %g2                            
    else                                                              
        vol->tot_secs = FAT_GET_BR_TOTAL_SECTORS_NUM32(boot_rec);     
40013810:	c6 0f bf 85 	ldub  [ %fp + -123 ], %g3                      
40013814:	c4 0f bf 9b 	ldub  [ %fp + -101 ], %g2                      
40013818:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001381c:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40013820:	c2 0f bf 8f 	ldub  [ %fp + -113 ], %g1                      
40013824:	84 10 c0 02 	or  %g3, %g2, %g2                              
40013828:	c6 0f bf 86 	ldub  [ %fp + -122 ], %g3                      
4001382c:	84 10 80 03 	or  %g2, %g3, %g2                              
40013830:	87 28 60 18 	sll  %g1, 0x18, %g3                            
40013834:	84 10 80 03 	or  %g2, %g3, %g2                              
40013838:	c4 26 a0 30 	st  %g2, [ %i2 + 0x30 ]                        
                                                                      
    data_secs = vol->tot_secs - vol->data_fsec;                       
4001383c:	d0 06 a0 30 	ld  [ %i2 + 0x30 ], %o0                        
                                                                      
    vol->data_cls = data_secs / vol->spc;                             
40013840:	92 0f 20 ff 	and  %i4, 0xff, %o1                            
40013844:	7f ff bb ed 	call  400027f8 <.udiv>                         
40013848:	90 22 00 15 	sub  %o0, %l5, %o0                             
                                                                      
    /* determine FAT type at least */                                 
    if ( vol->data_cls < FAT_FAT12_MAX_CLN)                           
4001384c:	80 a2 2f f4 	cmp  %o0, 0xff4                                
40013850:	18 80 00 08 	bgu  40013870 <fat_init_volume_info+0x414>     
40013854:	d0 26 a0 38 	st  %o0, [ %i2 + 0x38 ]                        
    {                                                                 
        vol->type = FAT_FAT12;                                        
40013858:	84 10 20 01 	mov  1, %g2                                    
4001385c:	c4 2e a0 0e 	stb  %g2, [ %i2 + 0xe ]                        
        vol->mask = FAT_FAT12_MASK;                                   
40013860:	84 10 2f ff 	mov  0xfff, %g2                                
40013864:	c4 26 a0 10 	st  %g2, [ %i2 + 0x10 ]                        
        vol->eoc_val = FAT_FAT12_EOC;                                 
40013868:	10 80 00 11 	b  400138ac <fat_init_volume_info+0x450>       
4001386c:	84 10 2f f8 	mov  0xff8, %g2                                
    }                                                                 
    else                                                              
    {                                                                 
        if ( vol->data_cls < FAT_FAT16_MAX_CLN)                       
40013870:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
40013874:	86 10 a3 f4 	or  %g2, 0x3f4, %g3	! fff4 <_TLS_Alignment+0xfff3>
40013878:	80 a2 00 03 	cmp  %o0, %g3                                  
4001387c:	38 80 00 04 	bgu,a   4001388c <fat_init_volume_info+0x430>  
40013880:	05 03 ff ff 	sethi  %hi(0xffffc00), %g2                     
        {                                                             
            vol->type = FAT_FAT16;                                    
40013884:	10 80 00 06 	b  4001389c <fat_init_volume_info+0x440>       
40013888:	86 10 20 02 	mov  2, %g3                                    
            vol->mask = FAT_FAT16_MASK;                               
            vol->eoc_val = FAT_FAT16_EOC;                             
        }                                                             
        else if ( vol->data_cls < FAT_FAT32_MASK - 1 )                
4001388c:	86 10 a3 fd 	or  %g2, 0x3fd, %g3                            
40013890:	80 a2 00 03 	cmp  %o0, %g3                                  
40013894:	18 80 00 3e 	bgu  4001398c <fat_init_volume_info+0x530>     <== NEVER TAKEN
40013898:	86 10 20 04 	mov  4, %g3                                    
        {                                                             
            vol->type = FAT_FAT32;                                    
4001389c:	c6 2e a0 0e 	stb  %g3, [ %i2 + 0xe ]                        
            vol->mask = FAT_FAT32_MASK;                               
400138a0:	86 10 a3 ff 	or  %g2, 0x3ff, %g3                            
            vol->eoc_val = FAT_FAT32_EOC;                             
400138a4:	84 10 a3 f8 	or  %g2, 0x3f8, %g2                            
            vol->eoc_val = FAT_FAT16_EOC;                             
        }                                                             
        else if ( vol->data_cls < FAT_FAT32_MASK - 1 )                
        {                                                             
            vol->type = FAT_FAT32;                                    
            vol->mask = FAT_FAT32_MASK;                               
400138a8:	c6 26 a0 10 	st  %g3, [ %i2 + 0x10 ]                        
            vol->eoc_val = FAT_FAT32_EOC;                             
400138ac:	c4 26 a0 14 	st  %g2, [ %i2 + 0x14 ]                        
            close(vol->fd);                                           
            rtems_set_errno_and_return_minus_one( EINVAL );           
        }                                                             
    }                                                                 
                                                                      
    if (vol->type == FAT_FAT32)                                       
400138b0:	c4 0e a0 0e 	ldub  [ %i2 + 0xe ], %g2                       
400138b4:	80 a0 a0 04 	cmp  %g2, 4                                    
400138b8:	12 80 00 61 	bne  40013a3c <fat_init_volume_info+0x5e0>     
400138bc:	82 10 3f ff 	mov  -1, %g1                                   
    {                                                                 
        vol->rdir_cl = FAT_GET_BR_FAT32_ROOT_CLUSTER(boot_rec);       
400138c0:	c4 0f bf 9e 	ldub  [ %fp + -98 ], %g2                       
400138c4:	a4 0c a0 ff 	and  %l2, 0xff, %l2                            
400138c8:	85 28 a0 08 	sll  %g2, 8, %g2                               
400138cc:	a5 2c a0 10 	sll  %l2, 0x10, %l2                            
400138d0:	a4 10 80 12 	or  %g2, %l2, %l2                              
400138d4:	c4 0f bf 9f 	ldub  [ %fp + -97 ], %g2                       
400138d8:	a3 2c 60 18 	sll  %l1, 0x18, %l1                            
400138dc:	a4 14 80 02 	or  %l2, %g2, %l2                              
                                                                      
        vol->mirror = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_MIRROR;
400138e0:	84 0e ff 80 	and  %i3, -128, %g2                            
        }                                                             
    }                                                                 
                                                                      
    if (vol->type == FAT_FAT32)                                       
    {                                                                 
        vol->rdir_cl = FAT_GET_BR_FAT32_ROOT_CLUSTER(boot_rec);       
400138e4:	a2 14 80 11 	or  %l2, %l1, %l1                              
                                                                      
        vol->mirror = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_MIRROR;
400138e8:	c4 2e a0 54 	stb  %g2, [ %i2 + 0x54 ]                       
        if (vol->mirror)                                              
400138ec:	80 88 a0 80 	btst  0x80, %g2                                
400138f0:	02 80 00 05 	be  40013904 <fat_init_volume_info+0x4a8>      <== ALWAYS TAKEN
400138f4:	e2 26 a0 3c 	st  %l1, [ %i2 + 0x3c ]                        
            vol->afat = FAT_GET_BR_EXT_FLAGS(boot_rec) & FAT_BR_EXT_FLAGS_FAT_NUM;
400138f8:	b6 0e e0 0f 	and  %i3, 0xf, %i3                             <== NOT EXECUTED
400138fc:	10 80 00 03 	b  40013908 <fat_init_volume_info+0x4ac>       <== NOT EXECUTED
40013900:	f6 2e a0 5c 	stb  %i3, [ %i2 + 0x5c ]                       <== NOT EXECUTED
        else                                                          
            vol->afat = 0;                                            
40013904:	c0 2e a0 5c 	clrb  [ %i2 + 0x5c ]                           
                                                                      
        vol->info_sec = FAT_GET_BR_FAT32_FS_INFO_SECTOR(boot_rec);    
40013908:	f2 0f bf 9d 	ldub  [ %fp + -99 ], %i1                       
4001390c:	a0 0c 20 ff 	and  %l0, 0xff, %l0                            
40013910:	a1 2c 20 08 	sll  %l0, 8, %l0                               
40013914:	b2 14 00 19 	or  %l0, %i1, %i1                              
40013918:	f2 36 a0 40 	sth  %i1, [ %i2 + 0x40 ]                       
        if( vol->info_sec == 0 )                                      
4001391c:	b3 2e 60 10 	sll  %i1, 0x10, %i1                            
40013920:	93 36 60 10 	srl  %i1, 0x10, %o1                            
40013924:	80 a2 60 00 	cmp  %o1, 0                                    
40013928:	02 80 00 19 	be  4001398c <fat_init_volume_info+0x530>      <== NEVER TAKEN
4001392c:	94 10 20 00 	clr  %o2                                       
            close(vol->fd);                                           
            rtems_set_errno_and_return_minus_one( EINVAL );           
        }                                                             
        else                                                          
        {                                                             
            ret = _fat_block_read(fs_info, vol->info_sec , 0,         
40013930:	90 10 00 1a 	mov  %i2, %o0                                  
40013934:	96 10 20 04 	mov  4, %o3                                    
40013938:	7f ff fd f9 	call  4001311c <_fat_block_read>               
4001393c:	98 07 bf a8 	add  %fp, -88, %o4                             
                                  FAT_FSI_LEADSIG_SIZE, fs_info_sector);
            if ( ret < 0 )                                            
40013940:	80 a2 20 00 	cmp  %o0, 0                                    
40013944:	06 80 00 22 	bl  400139cc <fat_init_volume_info+0x570>      <== NEVER TAKEN
40013948:	c4 0f bf aa 	ldub  [ %fp + -86 ], %g2                       
            {                                                         
                close(vol->fd);                                       
                return -1;                                            
            }                                                         
                                                                      
            if (FAT_GET_FSINFO_LEAD_SIGNATURE(fs_info_sector) !=      
4001394c:	c6 0f bf a9 	ldub  [ %fp + -87 ], %g3                       
40013950:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40013954:	87 28 e0 08 	sll  %g3, 8, %g3                               
40013958:	86 10 c0 02 	or  %g3, %g2, %g3                              
4001395c:	c4 0f bf a8 	ldub  [ %fp + -88 ], %g2                       
40013960:	86 10 c0 02 	or  %g3, %g2, %g3                              
40013964:	c4 0f bf ab 	ldub  [ %fp + -85 ], %g2                       
40013968:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001396c:	86 10 c0 02 	or  %g3, %g2, %g3                              
40013970:	05 10 58 54 	sethi  %hi(0x41615000), %g2                    
40013974:	84 10 a2 52 	or  %g2, 0x252, %g2	! 41615252 <RAM_END+0x1215252>
40013978:	80 a0 c0 02 	cmp  %g3, %g2                                  
4001397c:	02 80 00 0a 	be  400139a4 <fat_init_volume_info+0x548>      <== ALWAYS TAKEN
40013980:	90 10 00 1a 	mov  %i2, %o0                                  
 *     0 on success, or -1 if error occured and errno set appropriately
 */                                                                   
int                                                                   
_fat_block_release(fat_fs_info_t *fs_info)                            
{                                                                     
    return fat_buf_release(fs_info);                                  
40013984:	7f ff fd 46 	call  40012e9c <fat_buf_release>               <== NOT EXECUTED
40013988:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
            if (FAT_GET_FSINFO_LEAD_SIGNATURE(fs_info_sector) !=      
                FAT_FSINFO_LEAD_SIGNATURE_VALUE)                      
            {                                                         
                _fat_block_release(fs_info);                          
                close(vol->fd);                                       
4001398c:	7f ff c4 ef 	call  40004d48 <close>                         <== NOT EXECUTED
40013990:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
                rtems_set_errno_and_return_minus_one( EINVAL );       
40013994:	40 00 22 be 	call  4001c48c <__errno>                       <== NOT EXECUTED
40013998:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001399c:	10 bf fe c3 	b  400134a8 <fat_init_volume_info+0x4c>        <== NOT EXECUTED
400139a0:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
            }                                                         
            else                                                      
            {                                                         
                ret = _fat_block_read(fs_info, vol->info_sec , FAT_FSI_INFO,
400139a4:	d2 16 a0 40 	lduh  [ %i2 + 0x40 ], %o1                      
400139a8:	94 10 21 e4 	mov  0x1e4, %o2                                
400139ac:	96 10 20 0c 	mov  0xc, %o3                                  
400139b0:	7f ff fd db 	call  4001311c <_fat_block_read>               
400139b4:	98 07 bf a8 	add  %fp, -88, %o4                             
                                      FAT_USEFUL_INFO_SIZE, fs_info_sector);
                if ( ret < 0 )                                        
400139b8:	80 a2 20 00 	cmp  %o0, 0                                    
400139bc:	16 80 00 08 	bge  400139dc <fat_init_volume_info+0x580>     <== ALWAYS TAKEN
400139c0:	c6 0f bf ad 	ldub  [ %fp + -83 ], %g3                       
 *     0 on success, or -1 if error occured and errno set appropriately
 */                                                                   
int                                                                   
_fat_block_release(fat_fs_info_t *fs_info)                            
{                                                                     
    return fat_buf_release(fs_info);                                  
400139c4:	7f ff fd 36 	call  40012e9c <fat_buf_release>               <== NOT EXECUTED
400139c8:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
                ret = _fat_block_read(fs_info, vol->info_sec , FAT_FSI_INFO,
                                      FAT_USEFUL_INFO_SIZE, fs_info_sector);
                if ( ret < 0 )                                        
                {                                                     
                    _fat_block_release(fs_info);                      
                    close(vol->fd);                                   
400139cc:	7f ff c4 df 	call  40004d48 <close>                         <== NOT EXECUTED
400139d0:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
400139d4:	10 80 00 8f 	b  40013c10 <fat_init_volume_info+0x7b4>       <== NOT EXECUTED
400139d8:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
                    return -1;                                        
                }                                                     
                                                                      
                vol->free_cls_in_fs_info =                            
                  FAT_GET_FSINFO_FREE_CLUSTER_COUNT(fs_info_sector);  
400139dc:	c4 0f bf ae 	ldub  [ %fp + -82 ], %g2                       
400139e0:	87 28 e0 08 	sll  %g3, 8, %g3                               
400139e4:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
400139e8:	84 10 c0 02 	or  %g3, %g2, %g2                              
400139ec:	c6 0f bf ac 	ldub  [ %fp + -84 ], %g3                       
400139f0:	84 10 80 03 	or  %g2, %g3, %g2                              
400139f4:	c6 0f bf af 	ldub  [ %fp + -81 ], %g3                       
400139f8:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
400139fc:	84 10 80 03 	or  %g2, %g3, %g2                              
                vol->free_cls = vol->free_cls_in_fs_info;             
                vol->next_cl_in_fs_info =                             
                  FAT_GET_FSINFO_NEXT_FREE_CLUSTER(fs_info_sector);   
40013a00:	c6 0f bf b1 	ldub  [ %fp + -79 ], %g3                       
                    _fat_block_release(fs_info);                      
                    close(vol->fd);                                   
                    return -1;                                        
                }                                                     
                                                                      
                vol->free_cls_in_fs_info =                            
40013a04:	c4 26 a0 48 	st  %g2, [ %i2 + 0x48 ]                        
                  FAT_GET_FSINFO_FREE_CLUSTER_COUNT(fs_info_sector);  
                vol->free_cls = vol->free_cls_in_fs_info;             
40013a08:	c4 26 a0 44 	st  %g2, [ %i2 + 0x44 ]                        
                vol->next_cl_in_fs_info =                             
                  FAT_GET_FSINFO_NEXT_FREE_CLUSTER(fs_info_sector);   
40013a0c:	c4 0f bf b2 	ldub  [ %fp + -78 ], %g2                       
40013a10:	87 28 e0 08 	sll  %g3, 8, %g3                               
40013a14:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40013a18:	84 10 c0 02 	or  %g3, %g2, %g2                              
40013a1c:	c6 0f bf b0 	ldub  [ %fp + -80 ], %g3                       
40013a20:	84 10 80 03 	or  %g2, %g3, %g2                              
40013a24:	c6 0f bf b3 	ldub  [ %fp + -77 ], %g3                       
40013a28:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
40013a2c:	84 10 80 03 	or  %g2, %g3, %g2                              
                }                                                     
                                                                      
                vol->free_cls_in_fs_info =                            
                  FAT_GET_FSINFO_FREE_CLUSTER_COUNT(fs_info_sector);  
                vol->free_cls = vol->free_cls_in_fs_info;             
                vol->next_cl_in_fs_info =                             
40013a30:	c4 26 a0 50 	st  %g2, [ %i2 + 0x50 ]                        
40013a34:	10 80 00 07 	b  40013a50 <fat_init_volume_info+0x5f4>       
40013a38:	c4 26 a0 4c 	st  %g2, [ %i2 + 0x4c ]                        
            }                                                         
        }                                                             
    }                                                                 
    else                                                              
    {                                                                 
        vol->rdir_cl = 0;                                             
40013a3c:	c0 26 a0 3c 	clr  [ %i2 + 0x3c ]                            
        vol->mirror = 0;                                              
40013a40:	c0 2e a0 54 	clrb  [ %i2 + 0x54 ]                           
        vol->afat = 0;                                                
40013a44:	c0 2e a0 5c 	clrb  [ %i2 + 0x5c ]                           
        vol->free_cls = FAT_UNDEFINED_VALUE;                          
40013a48:	c2 26 a0 44 	st  %g1, [ %i2 + 0x44 ]                        
        vol->next_cl = FAT_UNDEFINED_VALUE;                           
40013a4c:	c2 26 a0 4c 	st  %g1, [ %i2 + 0x4c ]                        
 *     0 on success, or -1 if error occured and errno set appropriately
 */                                                                   
int                                                                   
_fat_block_release(fat_fs_info_t *fs_info)                            
{                                                                     
    return fat_buf_release(fs_info);                                  
40013a50:	7f ff fd 13 	call  40012e9c <fat_buf_release>               
40013a54:	90 10 00 1a 	mov  %i2, %o0                                  
        vol->next_cl = FAT_UNDEFINED_VALUE;                           
    }                                                                 
                                                                      
    _fat_block_release(fs_info);                                      
                                                                      
    vol->afat_loc = vol->fat_loc + vol->fat_length * vol->afat;       
40013a58:	d2 06 a0 1c 	ld  [ %i2 + 0x1c ], %o1                        
40013a5c:	7f ff bb 2d 	call  40002710 <.umul>                         
40013a60:	d0 0e a0 5c 	ldub  [ %i2 + 0x5c ], %o0                      
40013a64:	c4 16 a0 18 	lduh  [ %i2 + 0x18 ], %g2                      
                                                                      
    /* set up collection of fat-files fd */                           
    fs_info->vhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
40013a68:	92 10 20 0c 	mov  0xc, %o1                                  
        vol->next_cl = FAT_UNDEFINED_VALUE;                           
    }                                                                 
                                                                      
    _fat_block_release(fs_info);                                      
                                                                      
    vol->afat_loc = vol->fat_loc + vol->fat_length * vol->afat;       
40013a6c:	90 02 00 02 	add  %o0, %g2, %o0                             
40013a70:	d0 26 a0 58 	st  %o0, [ %i2 + 0x58 ]                        
                                                                      
    /* set up collection of fat-files fd */                           
    fs_info->vhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
40013a74:	7f ff c4 a0 	call  40004cf4 <calloc>                        
40013a78:	90 10 20 02 	mov  2, %o0                                    
    if ( fs_info->vhash == NULL )                                     
40013a7c:	80 a2 20 00 	cmp  %o0, 0                                    
40013a80:	02 80 00 12 	be  40013ac8 <fat_init_volume_info+0x66c>      <== NEVER TAKEN
40013a84:	d0 26 a0 6c 	st  %o0, [ %i2 + 0x6c ]                        
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40013a88:	84 02 20 04 	add  %o0, 4, %g2                               
40013a8c:	86 02 20 10 	add  %o0, 0x10, %g3                            
                                                                      
  head->next = tail;                                                  
40013a90:	c4 22 00 00 	st  %g2, [ %o0 ]                               
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40013a94:	84 02 20 0c 	add  %o0, 0xc, %g2                             
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
40013a98:	c0 22 20 04 	clr  [ %o0 + 4 ]                               
  tail->previous = head;                                              
40013a9c:	d0 22 20 08 	st  %o0, [ %o0 + 8 ]                           
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40013aa0:	c6 22 20 0c 	st  %g3, [ %o0 + 0xc ]                         
  head->previous = NULL;                                              
40013aa4:	c0 22 20 10 	clr  [ %o0 + 0x10 ]                            
  tail->previous = head;                                              
40013aa8:	c4 22 20 14 	st  %g2, [ %o0 + 0x14 ]                        
    }                                                                 
                                                                      
    for (i = 0; i < FAT_HASH_SIZE; i++)                               
        rtems_chain_initialize_empty(fs_info->vhash + i);             
                                                                      
    fs_info->rhash = calloc(FAT_HASH_SIZE, sizeof(rtems_chain_control));
40013aac:	92 10 20 0c 	mov  0xc, %o1                                  
40013ab0:	7f ff c4 91 	call  40004cf4 <calloc>                        
40013ab4:	90 10 20 02 	mov  2, %o0                                    
    if ( fs_info->rhash == NULL )                                     
40013ab8:	80 a2 20 00 	cmp  %o0, 0                                    
40013abc:	12 80 00 06 	bne  40013ad4 <fat_init_volume_info+0x678>     <== ALWAYS TAKEN
40013ac0:	d0 26 a0 70 	st  %o0, [ %i2 + 0x70 ]                        
40013ac4:	30 80 00 21 	b,a   40013b48 <fat_init_volume_info+0x6ec>    <== 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 )                                     
    {                                                                 
        close(vol->fd);                                               
40013ac8:	7f ff c4 a0 	call  40004d48 <close>                         <== NOT EXECUTED
40013acc:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
40013ad0:	30 80 00 31 	b,a   40013b94 <fat_init_volume_info+0x738>    <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40013ad4:	84 02 20 04 	add  %o0, 4, %g2                               
                                                                      
  head->next = tail;                                                  
40013ad8:	c4 22 00 00 	st  %g2, [ %o0 ]                               
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40013adc:	84 02 20 0c 	add  %o0, 0xc, %g2                             
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
40013ae0:	c0 22 20 04 	clr  [ %o0 + 4 ]                               
  tail->previous = head;                                              
40013ae4:	c4 22 20 14 	st  %g2, [ %o0 + 0x14 ]                        
40013ae8:	d0 22 20 08 	st  %o0, [ %o0 + 8 ]                           
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
40013aec:	c0 22 20 10 	clr  [ %o0 + 0x10 ]                            
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
40013af0:	86 02 20 10 	add  %o0, 0x10, %g3                            
        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;                
40013af4:	84 10 21 00 	mov  0x100, %g2                                
                                                                      
  head->next = tail;                                                  
40013af8:	c6 22 20 0c 	st  %g3, [ %o0 + 0xc ]                         
40013afc:	c4 26 a0 7c 	st  %g2, [ %i2 + 0x7c ]                        
    fs_info->uino_base = (vol->tot_secs << vol->sec_mul) << 4;        
40013b00:	c6 06 a0 30 	ld  [ %i2 + 0x30 ], %g3                        
40013b04:	c4 0e a0 03 	ldub  [ %i2 + 3 ], %g2                         
    fs_info->index = 0;                                               
40013b08:	c0 26 a0 78 	clr  [ %i2 + 0x78 ]                            
    }                                                                 
    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;        
40013b0c:	85 28 c0 02 	sll  %g3, %g2, %g2                             
40013b10:	85 28 a0 04 	sll  %g2, 4, %g2                               
    fs_info->index = 0;                                               
    fs_info->uino = (char *)calloc(fs_info->uino_pool_size, sizeof(char));
40013b14:	90 10 21 00 	mov  0x100, %o0                                
    }                                                                 
    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;        
40013b18:	c4 26 a0 80 	st  %g2, [ %i2 + 0x80 ]                        
    fs_info->index = 0;                                               
    fs_info->uino = (char *)calloc(fs_info->uino_pool_size, sizeof(char));
40013b1c:	7f ff c4 76 	call  40004cf4 <calloc>                        
40013b20:	92 10 20 01 	mov  1, %o1                                    
    if ( fs_info->uino == NULL )                                      
40013b24:	80 a2 20 00 	cmp  %o0, 0                                    
40013b28:	12 80 00 0c 	bne  40013b58 <fat_init_volume_info+0x6fc>     <== ALWAYS TAKEN
40013b2c:	d0 26 a0 74 	st  %o0, [ %i2 + 0x74 ]                        
    {                                                                 
        close(vol->fd);                                               
40013b30:	7f ff c4 86 	call  40004d48 <close>                         <== NOT EXECUTED
40013b34:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
        free(fs_info->vhash);                                         
40013b38:	7f ff c4 a7 	call  40004dd4 <free>                          <== NOT EXECUTED
40013b3c:	d0 06 a0 6c 	ld  [ %i2 + 0x6c ], %o0                        <== NOT EXECUTED
        free(fs_info->rhash);                                         
40013b40:	10 80 00 13 	b  40013b8c <fat_init_volume_info+0x730>       <== NOT EXECUTED
40013b44:	d0 06 a0 70 	ld  [ %i2 + 0x70 ], %o0                        <== 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 )                                     
    {                                                                 
        close(vol->fd);                                               
40013b48:	7f ff c4 80 	call  40004d48 <close>                         <== NOT EXECUTED
40013b4c:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
        free(fs_info->vhash);                                         
40013b50:	10 80 00 0f 	b  40013b8c <fat_init_volume_info+0x730>       <== NOT EXECUTED
40013b54:	d0 06 a0 6c 	ld  [ %i2 + 0x6c ], %o0                        <== NOT EXECUTED
        close(vol->fd);                                               
        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));  
40013b58:	d0 16 80 00 	lduh  [ %i2 ], %o0                             
40013b5c:	7f ff c4 66 	call  40004cf4 <calloc>                        
40013b60:	92 10 20 01 	mov  1, %o1                                    
    if (fs_info->sec_buf == NULL)                                     
40013b64:	80 a2 20 00 	cmp  %o0, 0                                    
40013b68:	12 80 00 0f 	bne  40013ba4 <fat_init_volume_info+0x748>     <== ALWAYS TAKEN
40013b6c:	d0 26 a0 90 	st  %o0, [ %i2 + 0x90 ]                        
    {                                                                 
        close(vol->fd);                                               
40013b70:	7f ff c4 76 	call  40004d48 <close>                         <== NOT EXECUTED
40013b74:	d0 06 a0 60 	ld  [ %i2 + 0x60 ], %o0                        <== NOT EXECUTED
        free(fs_info->vhash);                                         
40013b78:	7f ff c4 97 	call  40004dd4 <free>                          <== NOT EXECUTED
40013b7c:	d0 06 a0 6c 	ld  [ %i2 + 0x6c ], %o0                        <== NOT EXECUTED
        free(fs_info->rhash);                                         
40013b80:	7f ff c4 95 	call  40004dd4 <free>                          <== NOT EXECUTED
40013b84:	d0 06 a0 70 	ld  [ %i2 + 0x70 ], %o0                        <== NOT EXECUTED
        free(fs_info->uino);                                          
40013b88:	d0 06 a0 74 	ld  [ %i2 + 0x74 ], %o0                        <== NOT EXECUTED
40013b8c:	7f ff c4 92 	call  40004dd4 <free>                          <== NOT EXECUTED
40013b90:	01 00 00 00 	nop                                            <== NOT EXECUTED
        rtems_set_errno_and_return_minus_one( ENOMEM );               
40013b94:	40 00 22 3e 	call  4001c48c <__errno>                       <== NOT EXECUTED
40013b98:	01 00 00 00 	nop                                            <== NOT EXECUTED
40013b9c:	10 bf fe 43 	b  400134a8 <fat_init_volume_info+0x4c>        <== NOT EXECUTED
40013ba0:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
      return bytes_written;                                           
}                                                                     
                                                                      
static bool is_cluster_aligned(const fat_vol_t *vol, uint32_t sec_num)
{                                                                     
    return (sec_num & (vol->spc - 1)) == 0;                           
40013ba4:	c4 0e a0 04 	ldub  [ %i2 + 4 ], %g2                         
40013ba8:	c6 06 a0 34 	ld  [ %i2 + 0x34 ], %g3                        
40013bac:	84 00 bf ff 	add  %g2, -1, %g2                              
    /*                                                                
     * If possible we will use the cluster size as bdbuf block size for faster
     * file access. This requires that certain sectors are aligned to cluster
     * borders.                                                       
     */                                                               
    if (is_cluster_aligned(vol, vol->data_fsec)                       
40013bb0:	80 88 80 03 	btst  %g2, %g3                                 
40013bb4:	12 80 00 17 	bne  40013c10 <fat_init_volume_info+0x7b4>     <== NEVER TAKEN
40013bb8:	01 00 00 00 	nop                                            
        && (FAT_FAT32 == vol->type || is_cluster_aligned(vol, vol->rdir_loc)))
40013bbc:	c6 0e a0 0e 	ldub  [ %i2 + 0xe ], %g3                       
40013bc0:	80 a0 e0 04 	cmp  %g3, 4                                    
40013bc4:	22 80 00 07 	be,a   40013be0 <fat_init_volume_info+0x784>   
40013bc8:	d0 06 a0 64 	ld  [ %i2 + 0x64 ], %o0                        
      return bytes_written;                                           
}                                                                     
                                                                      
static bool is_cluster_aligned(const fat_vol_t *vol, uint32_t sec_num)
{                                                                     
    return (sec_num & (vol->spc - 1)) == 0;                           
40013bcc:	c6 06 a0 20 	ld  [ %i2 + 0x20 ], %g3                        
     * If possible we will use the cluster size as bdbuf block size for faster
     * file access. This requires that certain sectors are aligned to cluster
     * borders.                                                       
     */                                                               
    if (is_cluster_aligned(vol, vol->data_fsec)                       
        && (FAT_FAT32 == vol->type || is_cluster_aligned(vol, vol->rdir_loc)))
40013bd0:	80 88 80 03 	btst  %g2, %g3                                 
40013bd4:	12 80 00 0f 	bne  40013c10 <fat_init_volume_info+0x7b4>     <== NEVER TAKEN
40013bd8:	01 00 00 00 	nop                                            
    {                                                                 
        sc = rtems_bdbuf_set_block_size (vol->dd, vol->bpc, true);    
40013bdc:	d0 06 a0 64 	ld  [ %i2 + 0x64 ], %o0                        
40013be0:	d2 16 a0 06 	lduh  [ %i2 + 6 ], %o1                         
40013be4:	7f ff f4 f7 	call  40010fc0 <rtems_bdbuf_set_block_size>    
40013be8:	94 10 20 01 	mov  1, %o2                                    
        if (sc == RTEMS_SUCCESSFUL)                                   
40013bec:	80 a2 20 00 	cmp  %o0, 0                                    
40013bf0:	12 80 00 08 	bne  40013c10 <fat_init_volume_info+0x7b4>     <== NEVER TAKEN
40013bf4:	01 00 00 00 	nop                                            
        {                                                             
            vol->bytes_per_block = vol->bpc;                          
40013bf8:	c4 16 a0 06 	lduh  [ %i2 + 6 ], %g2                         
40013bfc:	c4 36 a0 0a 	sth  %g2, [ %i2 + 0xa ]                        
            vol->bytes_per_block_log2 = vol->bpc_log2;                
40013c00:	c4 0e a0 08 	ldub  [ %i2 + 8 ], %g2                         
40013c04:	c4 2e a0 0c 	stb  %g2, [ %i2 + 0xc ]                        
            vol->sectors_per_block = vol->spc;                        
40013c08:	c4 0e a0 04 	ldub  [ %i2 + 4 ], %g2                         
40013c0c:	c4 2e a0 09 	stb  %g2, [ %i2 + 9 ]                          
        }                                                             
    }                                                                 
                                                                      
    return RC_OK;                                                     
}                                                                     
40013c10:	81 c7 e0 08 	ret                                            
40013c14:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

40011fd4 <fat_scan_fat_for_free_clusters>: uint32_t count, uint32_t *cls_added, uint32_t *last_cl, bool zero_fill ) {
40011fd4:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int            rc = RC_OK;                                        
    uint32_t       cl4find = 2;                                       
    uint32_t       save_cln = FAT_UNDEFINED_VALUE;                    
    uint32_t       data_cls_val = fs_info->vol.data_cls + 2;          
40011fd8:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
    uint32_t       i = 2;                                             
                                                                      
    if (fs_info->vol.next_cl - 2 < fs_info->vol.data_cls)             
40011fdc:	e2 06 20 4c 	ld  [ %i0 + 0x4c ], %l1                        
    uint32_t                              count,                      
    uint32_t                             *cls_added,                  
    uint32_t                             *last_cl,                    
    bool                                  zero_fill                   
    )                                                                 
{                                                                     
40011fe0:	a0 10 00 18 	mov  %i0, %l0                                  
    uint32_t       cl4find = 2;                                       
    uint32_t       save_cln = FAT_UNDEFINED_VALUE;                    
    uint32_t       data_cls_val = fs_info->vol.data_cls + 2;          
    uint32_t       i = 2;                                             
                                                                      
    if (fs_info->vol.next_cl - 2 < fs_info->vol.data_cls)             
40011fe4:	84 04 7f fe 	add  %l1, -2, %g2                              
40011fe8:	80 a0 80 01 	cmp  %g2, %g1                                  
40011fec:	0a 80 00 03 	bcs  40011ff8 <fat_scan_fat_for_free_clusters+0x24>
40011ff0:	a8 00 60 02 	add  %g1, 2, %l4                               
    uint32_t                             *last_cl,                    
    bool                                  zero_fill                   
    )                                                                 
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cl4find = 2;                                       
40011ff4:	a2 10 20 02 	mov  2, %l1                                    
    uint32_t       i = 2;                                             
                                                                      
    if (fs_info->vol.next_cl - 2 < fs_info->vol.data_cls)             
        cl4find = fs_info->vol.next_cl;                               
                                                                      
    *cls_added = 0;                                                   
40011ff8:	c0 26 c0 00 	clr  [ %i3 ]                                   
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cl4find = 2;                                       
    uint32_t       save_cln = FAT_UNDEFINED_VALUE;                    
    uint32_t       data_cls_val = fs_info->vol.data_cls + 2;          
    uint32_t       i = 2;                                             
40011ffc:	a6 10 20 02 	mov  2, %l3                                    
    bool                                  zero_fill                   
    )                                                                 
{                                                                     
    int            rc = RC_OK;                                        
    uint32_t       cl4find = 2;                                       
    uint32_t       save_cln = FAT_UNDEFINED_VALUE;                    
40012000:	a4 10 3f ff 	mov  -1, %l2                                   
    /*                                                                
     * 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 (*cls_added != count && i < data_cls_val)                   
40012004:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
40012008:	80 a0 40 1a 	cmp  %g1, %i2                                  
4001200c:	12 80 00 0b 	bne  40012038 <fat_scan_fat_for_free_clusters+0x64>
40012010:	80 a4 c0 14 	cmp  %l3, %l4                                  
        cl4find++;                                                    
        if (cl4find >= data_cls_val)                                  
            cl4find = 2;                                              
    }                                                                 
                                                                      
    *last_cl = save_cln;                                              
40012014:	e4 27 00 00 	st  %l2, [ %i4 ]                               
    fs_info->vol.next_cl = save_cln;                                  
                                                                      
    if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)                 
40012018:	c2 04 20 44 	ld  [ %l0 + 0x44 ], %g1                        
4001201c:	80 a0 7f ff 	cmp  %g1, -1                                   
40012020:	02 80 00 5b 	be  4001218c <fat_scan_fat_for_free_clusters+0x1b8><== ALWAYS TAKEN
40012024:	e4 24 20 4c 	st  %l2, [ %l0 + 0x4c ]                        
        fs_info->vol.free_cls -= (*cls_added);                        
40012028:	c4 06 c0 00 	ld  [ %i3 ], %g2                               <== NOT EXECUTED
4001202c:	82 20 40 02 	sub  %g1, %g2, %g1                             <== NOT EXECUTED
40012030:	10 80 00 57 	b  4001218c <fat_scan_fat_for_free_clusters+0x1b8><== NOT EXECUTED
40012034:	c2 24 20 44 	st  %g1, [ %l0 + 0x44 ]                        <== 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 (*cls_added != count && i < data_cls_val)                   
40012038:	1a bf ff f7 	bcc  40012014 <fat_scan_fat_for_free_clusters+0x40>
4001203c:	90 10 00 10 	mov  %l0, %o0                                  
    {                                                                 
        uint32_t next_cln = 0;                                        
40012040:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
        rc = fat_get_fat_cluster(fs_info, cl4find, &next_cln);        
40012044:	92 10 00 11 	mov  %l1, %o1                                  
40012048:	7f ff fe a7 	call  40011ae4 <fat_get_fat_cluster>           
4001204c:	94 07 bf fc 	add  %fp, -4, %o2                              
        if ( rc != RC_OK )                                            
40012050:	80 a2 20 00 	cmp  %o0, 0                                    
40012054:	02 80 00 07 	be  40012070 <fat_scan_fat_for_free_clusters+0x9c><== ALWAYS TAKEN
40012058:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
     */                                                               
    while (*cls_added != count && i < data_cls_val)                   
    {                                                                 
        uint32_t next_cln = 0;                                        
                                                                      
        rc = fat_get_fat_cluster(fs_info, cl4find, &next_cln);        
4001205c:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
        if ( rc != RC_OK )                                            
        {                                                             
            if (*cls_added != 0)                                      
40012060:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40012064:	02 80 00 1e 	be  400120dc <fat_scan_fat_for_free_clusters+0x108><== NOT EXECUTED
40012068:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001206c:	30 80 00 1a 	b,a   400120d4 <fat_scan_fat_for_free_clusters+0x100><== NOT EXECUTED
                fat_free_fat_clusters_chain(fs_info, (*chain));       
            return rc;                                                
        }                                                             
                                                                      
        if (next_cln == FAT_GENFAT_FREE)                              
40012070:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
40012074:	80 a0 a0 00 	cmp  %g2, 0                                    
40012078:	32 80 00 33 	bne,a   40012144 <fat_scan_fat_for_free_clusters+0x170>
4001207c:	a2 04 60 01 	inc  %l1                                       
            /*                                                        
             * 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)                                      
40012080:	80 a0 60 00 	cmp  %g1, 0                                    
40012084:	12 80 00 0d 	bne  400120b8 <fat_scan_fat_for_free_clusters+0xe4>
40012088:	90 10 00 10 	mov  %l0, %o0                                  
            {                                                         
                *chain = cl4find;                                     
4001208c:	e2 26 40 00 	st  %l1, [ %i1 ]                               
                rc = fat_set_fat_cluster(fs_info, cl4find, FAT_GENFAT_EOC);
40012090:	92 10 00 11 	mov  %l1, %o1                                  
40012094:	7f ff ff 02 	call  40011c9c <fat_set_fat_cluster>           
40012098:	94 10 3f ff 	mov  -1, %o2                                   
                if ( rc != RC_OK )                                    
4001209c:	80 a2 20 00 	cmp  %o0, 0                                    
400120a0:	12 80 00 2e 	bne  40012158 <fat_scan_fat_for_free_clusters+0x184><== NEVER TAKEN
400120a4:	80 a7 60 00 	cmp  %i5, 0                                    
                rc = fat_set_fat_cluster(fs_info, save_cln, cl4find); 
                if ( rc != RC_OK )                                    
                    goto cleanup;                                     
            }                                                         
                                                                      
            if (zero_fill)                                            
400120a8:	22 80 00 17 	be,a   40012104 <fat_scan_fat_for_free_clusters+0x130>
400120ac:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
            {                                                         
                ssize_t bytes_written =                               
400120b0:	10 80 00 19 	b  40012114 <fat_scan_fat_for_free_clusters+0x140>
400120b4:	d6 14 20 06 	lduh  [ %l0 + 6 ], %o3                         
                }                                                     
            }                                                         
            else                                                      
            {                                                         
                /* set EOC value to new allocated cluster */          
                rc = fat_set_fat_cluster(fs_info, cl4find, FAT_GENFAT_EOC);
400120b8:	92 10 00 11 	mov  %l1, %o1                                  
400120bc:	7f ff fe f8 	call  40011c9c <fat_set_fat_cluster>           
400120c0:	94 10 3f ff 	mov  -1, %o2                                   
400120c4:	b0 10 00 08 	mov  %o0, %i0                                  
                if ( rc != RC_OK )                                    
400120c8:	80 a6 20 00 	cmp  %i0, 0                                    
400120cc:	02 80 00 06 	be  400120e4 <fat_scan_fat_for_free_clusters+0x110><== ALWAYS TAKEN
400120d0:	90 10 00 10 	mov  %l0, %o0                                  
                {                                                     
                    /* cleanup activity */                            
                    fat_free_fat_clusters_chain(fs_info, (*chain));   
400120d4:	7f ff ff 90 	call  40011f14 <fat_free_fat_clusters_chain>   <== NOT EXECUTED
400120d8:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
                    return rc;                                        
400120dc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400120e0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                }                                                     
                                                                      
                rc = fat_set_fat_cluster(fs_info, save_cln, cl4find); 
400120e4:	92 10 00 12 	mov  %l2, %o1                                  
400120e8:	7f ff fe ed 	call  40011c9c <fat_set_fat_cluster>           
400120ec:	94 10 00 11 	mov  %l1, %o2                                  
                if ( rc != RC_OK )                                    
400120f0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400120f4:	02 bf ff ed 	be  400120a8 <fat_scan_fat_for_free_clusters+0xd4><== ALWAYS TAKEN
400120f8:	80 a7 60 00 	cmp  %i5, 0                                    
    return RC_OK;                                                     
                                                                      
cleanup:                                                              
                                                                      
    /* cleanup activity */                                            
    fat_free_fat_clusters_chain(fs_info, (*chain));                   
400120fc:	10 80 00 1a 	b  40012164 <fat_scan_fat_for_free_clusters+0x190><== NOT EXECUTED
40012100:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
                    goto cleanup;                                     
                }                                                     
            }                                                         
                                                                      
            save_cln = cl4find;                                       
            (*cls_added)++;                                           
40012104:	a4 10 00 11 	mov  %l1, %l2                                  
40012108:	82 00 60 01 	inc  %g1                                       
4001210c:	10 80 00 0d 	b  40012140 <fat_scan_fat_for_free_clusters+0x16c>
40012110:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
                    goto cleanup;                                     
            }                                                         
                                                                      
            if (zero_fill)                                            
            {                                                         
                ssize_t bytes_written =                               
40012114:	90 10 00 10 	mov  %l0, %o0                                  
40012118:	92 10 00 11 	mov  %l1, %o1                                  
4001211c:	94 10 20 00 	clr  %o2                                       
40012120:	40 00 04 43 	call  4001322c <fat_cluster_set>               
40012124:	98 10 20 00 	clr  %o4                                       
                    fat_cluster_set(fs_info, cl4find, 0, fs_info->vol.bpc, 0);
                                                                      
                if (fs_info->vol.bpc != bytes_written)                
40012128:	c2 14 20 06 	lduh  [ %l0 + 6 ], %g1                         
4001212c:	80 a0 40 08 	cmp  %g1, %o0                                  
40012130:	22 bf ff f5 	be,a   40012104 <fat_scan_fat_for_free_clusters+0x130><== ALWAYS TAKEN
40012134:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
                {                                                     
                    rc = -1;                                          
40012138:	10 80 00 0a 	b  40012160 <fat_scan_fat_for_free_clusters+0x18c><== NOT EXECUTED
4001213c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
                                                                      
            save_cln = cl4find;                                       
            (*cls_added)++;                                           
        }                                                             
        i++;                                                          
        cl4find++;                                                    
40012140:	a2 04 60 01 	inc  %l1                                       
        if (cl4find >= data_cls_val)                                  
40012144:	80 a4 40 14 	cmp  %l1, %l4                                  
40012148:	0a bf ff af 	bcs  40012004 <fat_scan_fat_for_free_clusters+0x30>
4001214c:	a6 04 e0 01 	inc  %l3                                       
            cl4find = 2;                                              
40012150:	10 bf ff ad 	b  40012004 <fat_scan_fat_for_free_clusters+0x30>
40012154:	a2 10 20 02 	mov  2, %l1                                    
             * wouldn't work properly                                 
             */                                                       
            if (*cls_added == 0)                                      
            {                                                         
                *chain = cl4find;                                     
                rc = fat_set_fat_cluster(fs_info, cl4find, FAT_GENFAT_EOC);
40012158:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001215c:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
    return RC_OK;                                                     
                                                                      
cleanup:                                                              
                                                                      
    /* cleanup activity */                                            
    fat_free_fat_clusters_chain(fs_info, (*chain));                   
40012160:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
40012164:	7f ff ff 6c 	call  40011f14 <fat_free_fat_clusters_chain>   <== NOT EXECUTED
40012168:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    /* trying to save last allocated cluster for future use */        
    fat_set_fat_cluster(fs_info, cl4find, FAT_GENFAT_FREE);           
4001216c:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
40012170:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
40012174:	7f ff fe ca 	call  40011c9c <fat_set_fat_cluster>           <== NOT EXECUTED
40012178:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
    fat_buf_release(fs_info);                                         
4001217c:	40 00 03 48 	call  40012e9c <fat_buf_release>               <== NOT EXECUTED
40012180:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    return rc;                                                        
40012184:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012188:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    fs_info->vol.next_cl = save_cln;                                  
                                                                      
    if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)                 
        fs_info->vol.free_cls -= (*cls_added);                        
                                                                      
    fat_buf_release(fs_info);                                         
4001218c:	90 10 00 10 	mov  %l0, %o0                                  
40012190:	40 00 03 43 	call  40012e9c <fat_buf_release>               
40012194:	b0 10 20 00 	clr  %i0                                       
    fat_free_fat_clusters_chain(fs_info, (*chain));                   
    /* trying to save last allocated cluster for future use */        
    fat_set_fat_cluster(fs_info, cl4find, FAT_GENFAT_FREE);           
    fat_buf_release(fs_info);                                         
    return rc;                                                        
}                                                                     
40012198:	81 c7 e0 08 	ret                                            
4001219c:	81 e8 00 00 	restore                                        
                                                                      

40013198 <fat_sector_write>: fat_fs_info_t *fs_info, uint32_t start, uint32_t offset, uint32_t count, const void *buff) {
40013198:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                 rc = RC_OK;                                   
    ssize_t             cmpltd = 0;                                   
4001319c:	a0 10 20 00 	clr  %l0                                       
}                                                                     
                                                                      
static inline void                                                    
fat_buf_mark_modified(fat_fs_info_t *fs_info)                         
{                                                                     
    fs_info->c.modified = true;                                       
400131a0:	a2 10 20 01 	mov  1, %l1                                    
    uint32_t            sec_num = start;                              
    uint32_t            ofs = offset;                                 
    uint8_t            *sec_buf;                                      
    uint32_t            c = 0;                                        
                                                                      
    while(count > 0)                                                  
400131a4:	80 a6 e0 00 	cmp  %i3, 0                                    
400131a8:	02 80 00 1d 	be  4001321c <fat_sector_write+0x84>           
400131ac:	01 00 00 00 	nop                                            
    {                                                                 
        c = MIN(count, (fs_info->vol.bps - ofs));                     
400131b0:	fa 16 00 00 	lduh  [ %i0 ], %i5                             
400131b4:	ba 27 40 1a 	sub  %i5, %i2, %i5                             
400131b8:	80 a7 40 1b 	cmp  %i5, %i3                                  
400131bc:	38 80 00 02 	bgu,a   400131c4 <fat_sector_write+0x2c>       
400131c0:	ba 10 00 1b 	mov  %i3, %i5                                  
                                                                      
        if (c == fs_info->vol.bytes_per_block)                        
400131c4:	c2 16 20 0a 	lduh  [ %i0 + 0xa ], %g1                       
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_GET, &sec_buf);
400131c8:	90 10 00 18 	mov  %i0, %o0                                  
400131cc:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
    while(count > 0)                                                  
    {                                                                 
        c = MIN(count, (fs_info->vol.bps - ofs));                     
                                                                      
        if (c == fs_info->vol.bytes_per_block)                        
400131d0:	80 a7 40 01 	cmp  %i5, %g1                                  
400131d4:	02 80 00 03 	be  400131e0 <fat_sector_write+0x48>           <== NEVER TAKEN
400131d8:	94 10 20 02 	mov  2, %o2                                    
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_GET, &sec_buf);
        else                                                          
            rc = fat_buf_access(fs_info, sec_num, FAT_OP_TYPE_READ, &sec_buf);
400131dc:	94 10 20 01 	mov  1, %o2                                    
400131e0:	7f ff ff a0 	call  40013060 <fat_buf_access>                
400131e4:	96 07 bf fc 	add  %fp, -4, %o3                              
        if (rc != RC_OK)                                              
400131e8:	80 a2 20 00 	cmp  %o0, 0                                    
400131ec:	12 80 00 0e 	bne  40013224 <fat_sector_write+0x8c>          <== NEVER TAKEN
400131f0:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
            return -1;                                                
                                                                      
        memcpy((sec_buf + ofs), (buff + cmpltd), c);                  
400131f4:	92 07 00 10 	add  %i4, %l0, %o1                             
400131f8:	90 02 00 1a 	add  %o0, %i2, %o0                             
400131fc:	94 10 00 1d 	mov  %i5, %o2                                  
40013200:	40 00 26 f8 	call  4001cde0 <memcpy>                        
40013204:	b6 26 c0 1d 	sub  %i3, %i5, %i3                             
                                                                      
        fat_buf_mark_modified(fs_info);                               
                                                                      
        count -= c;                                                   
        cmpltd +=c;                                                   
40013208:	a0 07 40 10 	add  %i5, %l0, %l0                             
4001320c:	e2 2e 20 88 	stb  %l1, [ %i0 + 0x88 ]                       
        sec_num++;                                                    
40013210:	b2 06 60 01 	inc  %i1                                       
        ofs = 0;                                                      
40013214:	10 bf ff e4 	b  400131a4 <fat_sector_write+0xc>             
40013218:	b4 10 20 00 	clr  %i2                                       
4001321c:	81 c7 e0 08 	ret                                            
40013220:	91 e8 00 10 	restore  %g0, %l0, %o0                         
    }                                                                 
    return cmpltd;                                                    
}                                                                     
40013224:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013228:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      

40011c9c <fat_set_fat_cluster>: fat_set_fat_cluster( fat_fs_info_t *fs_info, uint32_t cln, uint32_t in_val ) {
40011c9c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                 rc = RC_OK;                                   
    uint32_t            sec = 0;                                      
    uint32_t            ofs = 0;                                      
    uint16_t            fat16_clv = 0;                                
    uint32_t            fat32_clv = 0;                                
    uint8_t            *sec_buf = NULL;                               
40011ca0:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
    /* sanity check */                                                
    if ( (cln < 2) || (cln > (fs_info->vol.data_cls + 1)) )           
40011ca4:	80 a6 60 01 	cmp  %i1, 1                                    
40011ca8:	08 80 00 95 	bleu  40011efc <fat_set_fat_cluster+0x260>     <== NEVER TAKEN
40011cac:	ba 10 00 18 	mov  %i0, %i5                                  
40011cb0:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
40011cb4:	82 00 60 01 	inc  %g1                                       
40011cb8:	80 a6 40 01 	cmp  %i1, %g1                                  
40011cbc:	18 80 00 90 	bgu  40011efc <fat_set_fat_cluster+0x260>      <== NEVER TAKEN
40011cc0:	01 00 00 00 	nop                                            
        rtems_set_errno_and_return_minus_one(EIO);                    
                                                                      
    sec = (FAT_FAT_OFFSET(fs_info->vol.type, cln) >> fs_info->vol.sec_log2) +
40011cc4:	c2 0e 20 0e 	ldub  [ %i0 + 0xe ], %g1                       
40011cc8:	84 88 60 01 	andcc  %g1, 1, %g2                             
40011ccc:	02 80 00 05 	be  40011ce0 <fat_set_fat_cluster+0x44>        
40011cd0:	80 88 60 02 	btst  2, %g1                                   
40011cd4:	a1 36 60 01 	srl  %i1, 1, %l0                               
40011cd8:	10 80 00 05 	b  40011cec <fat_set_fat_cluster+0x50>         
40011cdc:	a0 04 00 19 	add  %l0, %i1, %l0                             
40011ce0:	02 80 00 03 	be  40011cec <fat_set_fat_cluster+0x50>        
40011ce4:	a1 2e 60 02 	sll  %i1, 2, %l0                               
40011ce8:	a1 2e 60 01 	sll  %i1, 1, %l0                               
40011cec:	c6 0f 60 02 	ldub  [ %i5 + 2 ], %g3                         
          fs_info->vol.afat_loc;                                      
    ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
40011cf0:	80 a0 a0 00 	cmp  %g2, 0                                    
                                                                      
    /* 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) +
40011cf4:	a1 34 00 03 	srl  %l0, %g3, %l0                             
40011cf8:	c6 07 60 58 	ld  [ %i5 + 0x58 ], %g3                        
          fs_info->vol.afat_loc;                                      
    ofs = FAT_FAT_OFFSET(fs_info->vol.type, cln) & (fs_info->vol.bps - 1);
40011cfc:	02 80 00 05 	be  40011d10 <fat_set_fat_cluster+0x74>        
40011d00:	a0 04 00 03 	add  %l0, %g3, %l0                             
40011d04:	b7 36 60 01 	srl  %i1, 1, %i3                               
40011d08:	10 80 00 06 	b  40011d20 <fat_set_fat_cluster+0x84>         
40011d0c:	b6 06 c0 19 	add  %i3, %i1, %i3                             
40011d10:	80 88 60 02 	btst  2, %g1                                   
40011d14:	02 80 00 03 	be  40011d20 <fat_set_fat_cluster+0x84>        
40011d18:	b7 2e 60 02 	sll  %i1, 2, %i3                               
40011d1c:	b7 2e 60 01 	sll  %i1, 1, %i3                               
40011d20:	f8 17 40 00 	lduh  [ %i5 ], %i4                             
                                                                      
    rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &sec_buf);    
40011d24:	90 10 00 1d 	mov  %i5, %o0                                  
40011d28:	92 10 00 10 	mov  %l0, %o1                                  
40011d2c:	94 10 20 01 	mov  1, %o2                                    
40011d30:	40 00 04 cc 	call  40013060 <fat_buf_access>                
40011d34:	96 07 bf fc 	add  %fp, -4, %o3                              
    if (rc != RC_OK)                                                  
40011d38:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011d3c:	12 80 00 4c 	bne  40011e6c <fat_set_fat_cluster+0x1d0>      <== NEVER TAKEN
40011d40:	b9 2f 20 10 	sll  %i4, 0x10, %i4                            
    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);
40011d44:	b9 37 20 10 	srl  %i4, 0x10, %i4                            
40011d48:	b8 07 3f ff 	add  %i4, -1, %i4                              
40011d4c:	b8 0e c0 1c 	and  %i3, %i4, %i4                             
                                                                      
    rc = fat_buf_access(fs_info, sec, FAT_OP_TYPE_READ, &sec_buf);    
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    switch ( fs_info->vol.type )                                      
40011d50:	f6 0f 60 0e 	ldub  [ %i5 + 0xe ], %i3                       
40011d54:	80 a6 e0 02 	cmp  %i3, 2                                    
40011d58:	02 80 00 53 	be  40011ea4 <fat_set_fat_cluster+0x208>       
40011d5c:	80 a6 e0 04 	cmp  %i3, 4                                    
40011d60:	02 80 00 5b 	be  40011ecc <fat_set_fat_cluster+0x230>       
40011d64:	80 a6 e0 01 	cmp  %i3, 1                                    
40011d68:	12 80 00 65 	bne  40011efc <fat_set_fat_cluster+0x260>      <== NEVER TAKEN
40011d6c:	80 8e 60 01 	btst  1, %i1                                   
    {                                                                 
        case FAT_FAT12:                                               
            if ( FAT_CLUSTER_IS_ODD(cln) )                            
40011d70:	02 80 00 23 	be  40011dfc <fat_set_fat_cluster+0x160>       
40011d74:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
            {                                                         
                fat16_clv = ((uint16_t  )in_val) << FAT_FAT12_SHIFT;  
                *(sec_buf + ofs) &= 0x0F;                             
40011d78:	c4 08 40 1c 	ldub  [ %g1 + %i4 ], %g2                       
                                                                      
                *(sec_buf + ofs) |= (uint8_t)(fat16_clv & 0x00F0);    
40011d7c:	87 2e a0 04 	sll  %i2, 4, %g3                               
    {                                                                 
        case FAT_FAT12:                                               
            if ( FAT_CLUSTER_IS_ODD(cln) )                            
            {                                                         
                fat16_clv = ((uint16_t  )in_val) << FAT_FAT12_SHIFT;  
                *(sec_buf + ofs) &= 0x0F;                             
40011d80:	84 08 a0 0f 	and  %g2, 0xf, %g2                             
40011d84:	c4 28 40 1c 	stb  %g2, [ %g1 + %i4 ]                        
                                                                      
                *(sec_buf + ofs) |= (uint8_t)(fat16_clv & 0x00F0);    
40011d88:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40011d8c:	c4 08 40 1c 	ldub  [ %g1 + %i4 ], %g2                       
40011d90:	84 10 c0 02 	or  %g3, %g2, %g2                              
40011d94:	c4 28 40 1c 	stb  %g2, [ %g1 + %i4 ]                        
                                                                      
                fat_buf_mark_modified(fs_info);                       
                                                                      
                if ( ofs == (fs_info->vol.bps - 1) )                  
40011d98:	c2 17 40 00 	lduh  [ %i5 ], %g1                             
40011d9c:	82 00 7f ff 	add  %g1, -1, %g1                              
40011da0:	80 a7 00 01 	cmp  %i4, %g1                                  
40011da4:	12 80 00 0f 	bne  40011de0 <fat_set_fat_cluster+0x144>      
40011da8:	f6 2f 60 88 	stb  %i3, [ %i5 + 0x88 ]                       
                {                                                     
                    rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
40011dac:	90 10 00 1d 	mov  %i5, %o0                                  
40011db0:	92 04 20 01 	add  %l0, 1, %o1                               
40011db4:	94 10 20 01 	mov  1, %o2                                    
40011db8:	40 00 04 aa 	call  40013060 <fat_buf_access>                
40011dbc:	96 07 bf fc 	add  %fp, -4, %o3                              
                                        &sec_buf);                    
                    if (rc != RC_OK)                                  
40011dc0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011dc4:	12 80 00 2a 	bne  40011e6c <fat_set_fat_cluster+0x1d0>      <== NEVER TAKEN
40011dc8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                        return rc;                                    
                                                                      
                     *sec_buf &= 0x00;                                
                                                                      
                     *sec_buf |= (uint8_t)((fat16_clv & 0xFF00)>>8);  
40011dcc:	b5 2e a0 14 	sll  %i2, 0x14, %i2                            
                    rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
                                        &sec_buf);                    
                    if (rc != RC_OK)                                  
                        return rc;                                    
                                                                      
                     *sec_buf &= 0x00;                                
40011dd0:	c0 28 40 00 	clrb  [ %g1 ]                                  
                                                                      
                     *sec_buf |= (uint8_t)((fat16_clv & 0xFF00)>>8);  
40011dd4:	b5 36 a0 18 	srl  %i2, 0x18, %i2                            
40011dd8:	10 80 00 21 	b  40011e5c <fat_set_fat_cluster+0x1c0>        
40011ddc:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                                                                      
                     fat_buf_mark_modified(fs_info);                  
                }                                                     
                else                                                  
                {                                                     
                    *(sec_buf + ofs + 1) &= 0x00;                     
40011de0:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40011de4:	b8 07 20 01 	inc  %i4                                       
                                                                      
                    *(sec_buf + ofs + 1) |= (uint8_t  )((fat16_clv & 0xFF00)>>8);
40011de8:	b5 2e a0 14 	sll  %i2, 0x14, %i2                            
                                                                      
                     fat_buf_mark_modified(fs_info);                  
                }                                                     
                else                                                  
                {                                                     
                    *(sec_buf + ofs + 1) &= 0x00;                     
40011dec:	c0 28 40 1c 	clrb  [ %g1 + %i4 ]                            
                                                                      
                    *(sec_buf + ofs + 1) |= (uint8_t  )((fat16_clv & 0xFF00)>>8);
40011df0:	b5 36 a0 18 	srl  %i2, 0x18, %i2                            
40011df4:	10 80 00 27 	b  40011e90 <fat_set_fat_cluster+0x1f4>        
40011df8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                }                                                     
            }                                                         
            else                                                      
            {                                                         
                fat16_clv = ((uint16_t  )in_val) & FAT_FAT12_MASK;    
                *(sec_buf + ofs) &= 0x00;                             
40011dfc:	c0 28 40 1c 	clrb  [ %g1 + %i4 ]                            
                                                                      
                *(sec_buf + ofs) |= (uint8_t)(fat16_clv & 0x00FF);    
40011e00:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                    *(sec_buf + ofs + 1) |= (uint8_t  )((fat16_clv & 0xFF00)>>8);
                }                                                     
            }                                                         
            else                                                      
            {                                                         
                fat16_clv = ((uint16_t  )in_val) & FAT_FAT12_MASK;    
40011e04:	b4 0e af ff 	and  %i2, 0xfff, %i2                           
                *(sec_buf + ofs) &= 0x00;                             
                                                                      
                *(sec_buf + ofs) |= (uint8_t)(fat16_clv & 0x00FF);    
40011e08:	c4 08 40 1c 	ldub  [ %g1 + %i4 ], %g2                       
40011e0c:	84 16 80 02 	or  %i2, %g2, %g2                              
40011e10:	c4 28 40 1c 	stb  %g2, [ %g1 + %i4 ]                        
                                                                      
                fat_buf_mark_modified(fs_info);                       
                                                                      
                if ( ofs == (fs_info->vol.bps - 1) )                  
40011e14:	c2 17 40 00 	lduh  [ %i5 ], %g1                             
40011e18:	82 00 7f ff 	add  %g1, -1, %g1                              
40011e1c:	80 a7 00 01 	cmp  %i4, %g1                                  
40011e20:	12 80 00 15 	bne  40011e74 <fat_set_fat_cluster+0x1d8>      <== ALWAYS TAKEN
40011e24:	f6 2f 60 88 	stb  %i3, [ %i5 + 0x88 ]                       
                {                                                     
                    rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
40011e28:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40011e2c:	92 04 20 01 	add  %l0, 1, %o1                               <== NOT EXECUTED
40011e30:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
40011e34:	40 00 04 8b 	call  40013060 <fat_buf_access>                <== NOT EXECUTED
40011e38:	96 07 bf fc 	add  %fp, -4, %o3                              <== NOT EXECUTED
                                        &sec_buf);                    
                    if (rc != RC_OK)                                  
40011e3c:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
40011e40:	12 80 00 0b 	bne  40011e6c <fat_set_fat_cluster+0x1d0>      <== NOT EXECUTED
40011e44:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          <== NOT EXECUTED
                        return rc;                                    
                                                                      
                    *sec_buf &= 0xF0;                                 
                                                                      
                    *sec_buf |= (uint8_t)((fat16_clv & 0xFF00)>>8);   
40011e48:	b5 36 a0 08 	srl  %i2, 8, %i2                               <== NOT EXECUTED
                    rc = fat_buf_access(fs_info, sec + 1, FAT_OP_TYPE_READ,
                                        &sec_buf);                    
                    if (rc != RC_OK)                                  
                        return rc;                                    
                                                                      
                    *sec_buf &= 0xF0;                                 
40011e4c:	c4 08 40 00 	ldub  [ %g1 ], %g2                             <== NOT EXECUTED
40011e50:	84 08 bf f0 	and  %g2, -16, %g2                             <== NOT EXECUTED
40011e54:	c4 28 40 00 	stb  %g2, [ %g1 ]                              <== NOT EXECUTED
                                                                      
                    *sec_buf |= (uint8_t)((fat16_clv & 0xFF00)>>8);   
40011e58:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          <== NOT EXECUTED
40011e5c:	c4 08 40 00 	ldub  [ %g1 ], %g2                             
40011e60:	b4 16 80 02 	or  %i2, %g2, %i2                              
40011e64:	f4 28 40 00 	stb  %i2, [ %g1 ]                              
}                                                                     
                                                                      
static inline void                                                    
fat_buf_mark_modified(fat_fs_info_t *fs_info)                         
{                                                                     
    fs_info->c.modified = true;                                       
40011e68:	f6 2f 60 88 	stb  %i3, [ %i5 + 0x88 ]                       
40011e6c:	81 c7 e0 08 	ret                                            
40011e70:	81 e8 00 00 	restore                                        
                                                                      
                    fat_buf_mark_modified(fs_info);                   
                }                                                     
                else                                                  
                {                                                     
                    *(sec_buf + ofs + 1) &= 0xF0;                     
40011e74:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40011e78:	b8 07 20 01 	inc  %i4                                       
40011e7c:	c4 08 40 1c 	ldub  [ %g1 + %i4 ], %g2                       
                                                                      
                    *(sec_buf + ofs+1) |= (uint8_t)((fat16_clv & 0xFF00)>>8);
40011e80:	b5 36 a0 08 	srl  %i2, 8, %i2                               
                                                                      
                    fat_buf_mark_modified(fs_info);                   
                }                                                     
                else                                                  
                {                                                     
                    *(sec_buf + ofs + 1) &= 0xF0;                     
40011e84:	84 08 bf f0 	and  %g2, -16, %g2                             
40011e88:	c4 28 40 1c 	stb  %g2, [ %g1 + %i4 ]                        
                                                                      
                    *(sec_buf + ofs+1) |= (uint8_t)((fat16_clv & 0xFF00)>>8);
40011e8c:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40011e90:	c4 08 40 1c 	ldub  [ %g1 + %i4 ], %g2                       
40011e94:	b4 16 80 02 	or  %i2, %g2, %i2                              
40011e98:	f4 28 40 1c 	stb  %i2, [ %g1 + %i4 ]                        
40011e9c:	81 c7 e0 08 	ret                                            
40011ea0:	81 e8 00 00 	restore                                        
40011ea4:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
40011ea8:	82 10 63 ff 	or  %g1, 0x3ff, %g1	! ffff <_TLS_Alignment+0xfffe>
40011eac:	82 0e 80 01 	and  %i2, %g1, %g1                             
            }                                                         
            break;                                                    
                                                                      
        case FAT_FAT16:                                               
            *((uint16_t   *)(sec_buf + ofs)) =                        
                    (uint16_t  )(CT_LE_W(in_val));                    
40011eb0:	83 28 60 08 	sll  %g1, 8, %g1                               
40011eb4:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            
40011eb8:	b5 36 a0 18 	srl  %i2, 0x18, %i2                            
40011ebc:	b4 10 40 1a 	or  %g1, %i2, %i2                              
                }                                                     
            }                                                         
            break;                                                    
                                                                      
        case FAT_FAT16:                                               
            *((uint16_t   *)(sec_buf + ofs)) =                        
40011ec0:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40011ec4:	10 80 00 0a 	b  40011eec <fat_set_fat_cluster+0x250>        
40011ec8:	f4 30 40 1c 	sth  %i2, [ %g1 + %i4 ]                        
                    (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));           
40011ecc:	11 3c 00 00 	sethi  %hi(0xf0000000), %o0                    
40011ed0:	7f ff fe f9 	call  40011ab4 <CPU_swap_u32>                  
40011ed4:	90 2e 80 08 	andn  %i2, %o0, %o0                            
                                                                      
            *((uint32_t *)(sec_buf + ofs)) &= CT_LE_L(0xF0000000);    
40011ed8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40011edc:	c4 00 40 1c 	ld  [ %g1 + %i4 ], %g2                         
40011ee0:	84 08 a0 f0 	and  %g2, 0xf0, %g2                            
                                                                      
            *((uint32_t *)(sec_buf + ofs)) |= fat32_clv;              
40011ee4:	90 12 00 02 	or  %o0, %g2, %o0                              
40011ee8:	d0 20 40 1c 	st  %o0, [ %g1 + %i4 ]                         
40011eec:	82 10 20 01 	mov  1, %g1                                    
40011ef0:	c2 2f 60 88 	stb  %g1, [ %i5 + 0x88 ]                       
40011ef4:	81 c7 e0 08 	ret                                            
40011ef8:	81 e8 00 00 	restore                                        
                                                                      
            fat_buf_mark_modified(fs_info);                           
            break;                                                    
                                                                      
        default:                                                      
            rtems_set_errno_and_return_minus_one(EIO);                
40011efc:	40 00 29 64 	call  4001c48c <__errno>                       <== NOT EXECUTED
40011f00:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40011f04:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40011f08:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
            break;                                                    
                                                                      
    }                                                                 
                                                                      
    return RC_OK;                                                     
}                                                                     
40011f0c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011f10:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40013cd8 <fat_shutdown_drive>: * RC_OK on success, or -1 if error occured * and errno set appropriately */ int fat_shutdown_drive(fat_fs_info_t *fs_info) {
40013cd8:	9d e3 bf a0 	save  %sp, -96, %sp                            
40013cdc:	ba 10 00 18 	mov  %i0, %i5                                  
    int            rc = RC_OK;                                        
    int            i = 0;                                             
                                                                      
    rc = fat_sync(fs_info);                                           
40013ce0:	7f ff ff ce 	call  40013c18 <fat_sync>                      
40013ce4:	90 10 00 18 	mov  %i0, %o0                                  
        rc = -1;                                                      
                                                                      
    for (i = 0; i < FAT_HASH_SIZE; i++)                               
    {                                                                 
        rtems_chain_node    *node = NULL;                             
        rtems_chain_control *the_chain = fs_info->vhash + i;          
40013ce8:	f8 07 60 6c 	ld  [ %i5 + 0x6c ], %i4                        
{                                                                     
    int            rc = RC_OK;                                        
    int            i = 0;                                             
                                                                      
    rc = fat_sync(fs_info);                                           
    if ( rc != RC_OK )                                                
40013cec:	80 a0 00 08 	cmp  %g0, %o0                                  
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40013cf0:	b6 07 20 04 	add  %i4, 4, %i3                               
40013cf4:	b0 60 20 00 	subx  %g0, 0, %i0                              
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013cf8:	d0 07 00 00 	ld  [ %i4 ], %o0                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40013cfc:	80 a2 00 1b 	cmp  %o0, %i3                                  
40013d00:	22 80 00 08 	be,a   40013d20 <fat_shutdown_drive+0x48>      
40013d04:	c2 07 60 6c 	ld  [ %i5 + 0x6c ], %g1                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40013d08:	c2 02 00 00 	ld  [ %o0 ], %g1                               
                                                                      
  head->next = new_first;                                             
40013d0c:	c2 27 00 00 	st  %g1, [ %i4 ]                               
    {                                                                 
        rtems_chain_node    *node = NULL;                             
        rtems_chain_control *the_chain = fs_info->vhash + i;          
                                                                      
        while ( (node = rtems_chain_get_unprotected(the_chain)) != NULL )
            free(node);                                               
40013d10:	7f ff c4 31 	call  40004dd4 <free>                          
40013d14:	f8 20 60 04 	st  %i4, [ %g1 + 4 ]                           
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013d18:	10 bf ff f9 	b  40013cfc <fat_shutdown_drive+0x24>          
40013d1c:	d0 07 00 00 	ld  [ %i4 ], %o0                               
        rc = -1;                                                      
                                                                      
    for (i = 0; i < FAT_HASH_SIZE; i++)                               
    {                                                                 
        rtems_chain_node    *node = NULL;                             
        rtems_chain_control *the_chain = fs_info->vhash + i;          
40013d20:	b8 00 60 0c 	add  %g1, 0xc, %i4                             
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40013d24:	b6 00 60 10 	add  %g1, 0x10, %i3                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013d28:	d0 07 00 00 	ld  [ %i4 ], %o0                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40013d2c:	80 a2 00 1b 	cmp  %o0, %i3                                  
40013d30:	22 80 00 08 	be,a   40013d50 <fat_shutdown_drive+0x78>      <== ALWAYS TAKEN
40013d34:	f8 07 60 70 	ld  [ %i5 + 0x70 ], %i4                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40013d38:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
                                                                      
  head->next = new_first;                                             
40013d3c:	c2 27 00 00 	st  %g1, [ %i4 ]                               <== NOT EXECUTED
                                                                      
        while ( (node = rtems_chain_get_unprotected(the_chain)) != NULL )
            free(node);                                               
40013d40:	7f ff c4 25 	call  40004dd4 <free>                          <== NOT EXECUTED
40013d44:	f8 20 60 04 	st  %i4, [ %g1 + 4 ]                           <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013d48:	10 bf ff f9 	b  40013d2c <fat_shutdown_drive+0x54>          <== NOT EXECUTED
40013d4c:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40013d50:	b6 07 20 04 	add  %i4, 4, %i3                               
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013d54:	d0 07 00 00 	ld  [ %i4 ], %o0                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40013d58:	80 a2 00 1b 	cmp  %o0, %i3                                  
40013d5c:	22 80 00 08 	be,a   40013d7c <fat_shutdown_drive+0xa4>      <== ALWAYS TAKEN
40013d60:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40013d64:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
                                                                      
  head->next = new_first;                                             
40013d68:	c2 27 00 00 	st  %g1, [ %i4 ]                               <== NOT EXECUTED
    {                                                                 
        rtems_chain_node    *node = NULL;                             
        rtems_chain_control *the_chain = fs_info->rhash + i;          
                                                                      
        while ( (node = rtems_chain_get_unprotected(the_chain)) != NULL )
            free(node);                                               
40013d6c:	7f ff c4 1a 	call  40004dd4 <free>                          <== NOT EXECUTED
40013d70:	f8 20 60 04 	st  %i4, [ %g1 + 4 ]                           <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013d74:	10 bf ff f9 	b  40013d58 <fat_shutdown_drive+0x80>          <== NOT EXECUTED
40013d78:	d0 07 00 00 	ld  [ %i4 ], %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;          
40013d7c:	b8 00 60 0c 	add  %g1, 0xc, %i4                             
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40013d80:	b6 00 60 10 	add  %g1, 0x10, %i3                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013d84:	d0 07 00 00 	ld  [ %i4 ], %o0                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
40013d88:	80 a2 00 1b 	cmp  %o0, %i3                                  
40013d8c:	02 80 00 08 	be  40013dac <fat_shutdown_drive+0xd4>         <== ALWAYS TAKEN
40013d90:	01 00 00 00 	nop                                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
40013d94:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
                                                                      
  head->next = new_first;                                             
40013d98:	c2 27 00 00 	st  %g1, [ %i4 ]                               <== NOT EXECUTED
                                                                      
        while ( (node = rtems_chain_get_unprotected(the_chain)) != NULL )
            free(node);                                               
40013d9c:	7f ff c4 0e 	call  40004dd4 <free>                          <== NOT EXECUTED
40013da0:	f8 20 60 04 	st  %i4, [ %g1 + 4 ]                           <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40013da4:	10 bf ff f9 	b  40013d88 <fat_shutdown_drive+0xb0>          <== NOT EXECUTED
40013da8:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
    }                                                                 
                                                                      
    free(fs_info->vhash);                                             
40013dac:	7f ff c4 0a 	call  40004dd4 <free>                          
40013db0:	d0 07 60 6c 	ld  [ %i5 + 0x6c ], %o0                        
    free(fs_info->rhash);                                             
40013db4:	7f ff c4 08 	call  40004dd4 <free>                          
40013db8:	d0 07 60 70 	ld  [ %i5 + 0x70 ], %o0                        
                                                                      
    free(fs_info->uino);                                              
40013dbc:	7f ff c4 06 	call  40004dd4 <free>                          
40013dc0:	d0 07 60 74 	ld  [ %i5 + 0x74 ], %o0                        
    free(fs_info->sec_buf);                                           
40013dc4:	7f ff c4 04 	call  40004dd4 <free>                          
40013dc8:	d0 07 60 90 	ld  [ %i5 + 0x90 ], %o0                        
    close(fs_info->vol.fd);                                           
40013dcc:	7f ff c3 df 	call  40004d48 <close>                         
40013dd0:	d0 07 60 60 	ld  [ %i5 + 0x60 ], %o0                        
                                                                      
    if (rc)                                                           
40013dd4:	80 a6 20 00 	cmp  %i0, 0                                    
40013dd8:	02 80 00 08 	be  40013df8 <fat_shutdown_drive+0x120>        <== ALWAYS TAKEN
40013ddc:	01 00 00 00 	nop                                            
        errno = EIO;                                                  
40013de0:	40 00 21 ab 	call  4001c48c <__errno>                       <== NOT EXECUTED
40013de4:	01 00 00 00 	nop                                            <== NOT EXECUTED
40013de8:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
40013dec:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40013df0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013df4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    return rc;                                                        
}                                                                     
40013df8:	81 c7 e0 08 	ret                                            
40013dfc:	81 e8 00 00 	restore                                        
                                                                      

40013c18 <fat_sync>: return RC_OK; } int fat_sync(fat_fs_info_t *fs_info) {
40013c18:	9d e3 bf 98 	save  %sp, -104, %sp                           
static int                                                            
fat_fat32_update_fsinfo_sector(fat_fs_info_t *fs_info)                
{                                                                     
    ssize_t ret1 = 0, ret2 = 0;                                       
                                                                      
    if (fs_info->vol.type == FAT_FAT32)                               
40013c1c:	c4 0e 20 0e 	ldub  [ %i0 + 0xe ], %g2                       
    return RC_OK;                                                     
}                                                                     
                                                                      
int                                                                   
fat_sync(fat_fs_info_t *fs_info)                                      
{                                                                     
40013c20:	ba 10 00 18 	mov  %i0, %i5                                  
 *     RC_OK on success, or -1 if error occured (errno set appropriately)
 */                                                                   
static int                                                            
fat_fat32_update_fsinfo_sector(fat_fs_info_t *fs_info)                
{                                                                     
    ssize_t ret1 = 0, ret2 = 0;                                       
40013c24:	90 10 20 00 	clr  %o0                                       
                                                                      
    if (fs_info->vol.type == FAT_FAT32)                               
40013c28:	80 a0 a0 04 	cmp  %g2, 4                                    
40013c2c:	12 80 00 20 	bne  40013cac <fat_sync+0x94>                  
40013c30:	b0 10 20 00 	clr  %i0                                       
    {                                                                 
        uint32_t free_count = fs_info->vol.free_cls;                  
40013c34:	f6 07 60 44 	ld  [ %i5 + 0x44 ], %i3                        
        uint32_t next_free = fs_info->vol.next_cl;                    
                                                                      
        if (free_count != fs_info->vol.free_cls_in_fs_info)           
40013c38:	c2 07 60 48 	ld  [ %i5 + 0x48 ], %g1                        
40013c3c:	80 a6 c0 01 	cmp  %i3, %g1                                  
40013c40:	02 80 00 0d 	be  40013c74 <fat_sync+0x5c>                   <== ALWAYS TAKEN
40013c44:	f8 07 60 4c 	ld  [ %i5 + 0x4c ], %i4                        
        {                                                             
            uint32_t le_free_count = CT_LE_L(free_count);             
40013c48:	7f ff fc 74 	call  40012e18 <CPU_swap_u32>                  <== NOT EXECUTED
40013c4c:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
                                                                      
            fs_info->vol.free_cls_in_fs_info = free_count;            
                                                                      
            ret1 = fat_sector_write(fs_info,                          
40013c50:	d2 17 60 40 	lduh  [ %i5 + 0x40 ], %o1                      <== NOT EXECUTED
        uint32_t free_count = fs_info->vol.free_cls;                  
        uint32_t next_free = fs_info->vol.next_cl;                    
                                                                      
        if (free_count != fs_info->vol.free_cls_in_fs_info)           
        {                                                             
            uint32_t le_free_count = CT_LE_L(free_count);             
40013c54:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          <== NOT EXECUTED
                                                                      
            fs_info->vol.free_cls_in_fs_info = free_count;            
40013c58:	f6 27 60 48 	st  %i3, [ %i5 + 0x48 ]                        <== NOT EXECUTED
                                                                      
            ret1 = fat_sector_write(fs_info,                          
40013c5c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40013c60:	94 10 21 e8 	mov  0x1e8, %o2                                <== NOT EXECUTED
40013c64:	96 10 20 04 	mov  4, %o3                                    <== NOT EXECUTED
40013c68:	7f ff fd 4c 	call  40013198 <fat_sector_write>              <== NOT EXECUTED
40013c6c:	98 07 bf fc 	add  %fp, -4, %o4                              <== NOT EXECUTED
40013c70:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
                                    FAT_FSINFO_FREE_CLUSTER_COUNT_OFFSET,
                                    sizeof(le_free_count),            
                                    &le_free_count);                  
        }                                                             
                                                                      
        if (next_free != fs_info->vol.next_cl_in_fs_info)             
40013c74:	c4 07 60 50 	ld  [ %i5 + 0x50 ], %g2                        
40013c78:	80 a7 00 02 	cmp  %i4, %g2                                  
40013c7c:	02 80 00 0c 	be  40013cac <fat_sync+0x94>                   
40013c80:	90 10 20 00 	clr  %o0                                       
        {                                                             
            uint32_t le_next_free = CT_LE_L(next_free);               
40013c84:	7f ff fc 65 	call  40012e18 <CPU_swap_u32>                  
40013c88:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
            fs_info->vol.next_cl_in_fs_info = next_free;              
                                                                      
            ret2 = fat_sector_write(fs_info,                          
40013c8c:	d2 17 60 40 	lduh  [ %i5 + 0x40 ], %o1                      
                                    &le_free_count);                  
        }                                                             
                                                                      
        if (next_free != fs_info->vol.next_cl_in_fs_info)             
        {                                                             
            uint32_t le_next_free = CT_LE_L(next_free);               
40013c90:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          
                                                                      
            fs_info->vol.next_cl_in_fs_info = next_free;              
40013c94:	f8 27 60 50 	st  %i4, [ %i5 + 0x50 ]                        
                                                                      
            ret2 = fat_sector_write(fs_info,                          
40013c98:	90 10 00 1d 	mov  %i5, %o0                                  
40013c9c:	94 10 21 ec 	mov  0x1ec, %o2                                
40013ca0:	96 10 20 04 	mov  4, %o3                                    
40013ca4:	7f ff fd 3d 	call  40013198 <fat_sector_write>              
40013ca8:	98 07 bf fc 	add  %fp, -4, %o4                              
                                    sizeof(le_next_free),             
                                    &le_next_free);                   
        }                                                             
    }                                                                 
                                                                      
    if ( (ret1 < 0) || (ret2 < 0) )                                   
40013cac:	b0 16 00 08 	or  %i0, %o0, %i0                              
                                                                      
    rc = fat_fat32_update_fsinfo_sector(fs_info);                     
    if ( rc != RC_OK )                                                
        rc = -1;                                                      
                                                                      
    fat_buf_release(fs_info);                                         
40013cb0:	7f ff fc 7b 	call  40012e9c <fat_buf_release>               
40013cb4:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
    if (rtems_bdbuf_syncdev(fs_info->vol.dd) != RTEMS_SUCCESSFUL)     
40013cb8:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        
40013cbc:	7f ff f4 a6 	call  40010f54 <rtems_bdbuf_syncdev>           
40013cc0:	b1 3e 20 1f 	sra  %i0, 0x1f, %i0                            
40013cc4:	80 a2 20 00 	cmp  %o0, 0                                    
40013cc8:	32 80 00 02 	bne,a   40013cd0 <fat_sync+0xb8>               <== NEVER TAKEN
40013ccc:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
        rc = -1;                                                      
                                                                      
    return rc;                                                        
}                                                                     
40013cd0:	81 c7 e0 08 	ret                                            
40013cd4:	81 e8 00 00 	restore                                        
                                                                      

40004458 <fchdir>: /** * compatible with SVr4, 4.4BSD and X/OPEN - Change Directory */ int fchdir( int fd ) {
40004458:	9d e3 bf 40 	save  %sp, -192, %sp                           
                                                                      
  st.st_mode = 0;                                                     
  st.st_uid = 0;                                                      
  st.st_gid = 0;                                                      
                                                                      
  rtems_libio_check_fd( fd );                                         
4000445c:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
40004460:	c2 00 62 40 	ld  [ %g1 + 0x240 ], %g1	! 40017e40 <rtems_libio_number_iops>
  int rv = 0;                                                         
  rtems_libio_t *iop;                                                 
  struct stat st;                                                     
  rtems_filesystem_location_info_t loc;                               
                                                                      
  st.st_mode = 0;                                                     
40004464:	c0 27 bf c4 	clr  [ %fp + -60 ]                             
  st.st_uid = 0;                                                      
40004468:	c0 37 bf ca 	clrh  [ %fp + -54 ]                            
  st.st_gid = 0;                                                      
                                                                      
  rtems_libio_check_fd( fd );                                         
4000446c:	80 a6 00 01 	cmp  %i0, %g1                                  
40004470:	0a 80 00 08 	bcs  40004490 <fchdir+0x38>                    
40004474:	c0 37 bf cc 	clrh  [ %fp + -52 ]                            
40004478:	40 00 31 cc 	call  40010ba8 <__errno>                       
4000447c:	01 00 00 00 	nop                                            
40004480:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
40004484:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40004488:	10 80 00 33 	b  40004554 <fchdir+0xfc>                      
4000448c:	90 10 3f ff 	mov  -1, %o0                                   
  iop = rtems_libio_iop( fd );                                        
40004490:	83 2e 20 03 	sll  %i0, 3, %g1                               
40004494:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40004498:	b0 26 00 01 	sub  %i0, %g1, %i0                             
4000449c:	03 10 00 65 	sethi  %hi(0x40019400), %g1                    
400044a0:	fa 00 62 30 	ld  [ %g1 + 0x230 ], %i5	! 40019630 <rtems_libio_iops>
400044a4:	ba 07 40 18 	add  %i5, %i0, %i5                             
  rtems_libio_check_is_open( iop );                                   
400044a8:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
400044ac:	80 88 61 00 	btst  0x100, %g1                               
400044b0:	02 bf ff f2 	be  40004478 <fchdir+0x20>                     
400044b4:	01 00 00 00 	nop                                            
                                                                      
  rtems_filesystem_instance_lock( &iop->pathinfo );                   
400044b8:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->lock_h)( mt_entry );                               
400044bc:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
400044c0:	c2 00 40 00 	ld  [ %g1 ], %g1                               
400044c4:	9f c0 40 00 	call  %g1                                      
400044c8:	b6 07 60 14 	add  %i5, 0x14, %i3                            
  rv = (*iop->pathinfo.handlers->fstat_h)( &iop->pathinfo, &st );     
400044cc:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
400044d0:	90 10 00 1b 	mov  %i3, %o0                                  
400044d4:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
400044d8:	9f c0 40 00 	call  %g1                                      
400044dc:	92 07 bf b8 	add  %fp, -72, %o1                             
  if ( rv == 0 ) {                                                    
400044e0:	b8 92 20 00 	orcc  %o0, 0, %i4                              
400044e4:	32 80 00 13 	bne,a   40004530 <fchdir+0xd8>                 <== NEVER TAKEN
400044e8:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        <== NOT EXECUTED
    bool access_ok = rtems_filesystem_check_access(                   
400044ec:	d2 07 bf c4 	ld  [ %fp + -60 ], %o1                         
400044f0:	d4 17 bf ca 	lduh  [ %fp + -54 ], %o2                       
400044f4:	d6 17 bf cc 	lduh  [ %fp + -52 ], %o3                       
400044f8:	40 00 04 4e 	call  40005630 <rtems_filesystem_check_access> 
400044fc:	90 10 20 01 	mov  1, %o0                                    
      st.st_mode,                                                     
      st.st_uid,                                                      
      st.st_gid                                                       
    );                                                                
                                                                      
    if ( access_ok ) {                                                
40004500:	80 a2 20 00 	cmp  %o0, 0                                    
40004504:	02 80 00 06 	be  4000451c <fchdir+0xc4>                     
40004508:	90 07 bf a0 	add  %fp, -96, %o0                             
      rtems_filesystem_location_clone( &loc, &iop->pathinfo );        
4000450c:	40 00 23 96 	call  4000d364 <rtems_filesystem_location_clone>
40004510:	92 10 00 1b 	mov  %i3, %o1                                  
40004514:	10 80 00 07 	b  40004530 <fchdir+0xd8>                      
40004518:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
    } else {                                                          
      errno = EACCES;                                                 
4000451c:	40 00 31 a3 	call  40010ba8 <__errno>                       
40004520:	b8 10 3f ff 	mov  -1, %i4                                   
40004524:	82 10 20 0d 	mov  0xd, %g1                                  
40004528:	c2 22 00 00 	st  %g1, [ %o0 ]                               
                                                                      
  rtems_libio_check_fd( fd );                                         
  iop = rtems_libio_iop( fd );                                        
  rtems_libio_check_is_open( iop );                                   
                                                                      
  rtems_filesystem_instance_lock( &iop->pathinfo );                   
4000452c:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->unlock_h)( mt_entry );                             
40004530:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
40004534:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
40004538:	9f c0 40 00 	call  %g1                                      
4000453c:	01 00 00 00 	nop                                            
      rv = -1;                                                        
    }                                                                 
  }                                                                   
  rtems_filesystem_instance_unlock( &iop->pathinfo );                 
                                                                      
  if ( rv == 0 ) {                                                    
40004540:	90 97 20 00 	orcc  %i4, 0, %o0                              
40004544:	12 80 00 04 	bne  40004554 <fchdir+0xfc>                    
40004548:	01 00 00 00 	nop                                            
    rv = rtems_filesystem_chdir( &loc );                              
4000454c:	40 00 23 6a 	call  4000d2f4 <rtems_filesystem_chdir>        
40004550:	90 07 bf a0 	add  %fp, -96, %o0                             
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40004554:	81 c7 e0 08 	ret                                            
40004558:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4003140c <fcntl>: int fcntl( int fd, int cmd, ... ) {
4003140c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int            fd2;                                                 
  int            flags;                                               
  int            mask;                                                
  int            ret = 0;                                             
                                                                      
  rtems_libio_check_fd( fd );                                         
40031410:	05 10 00 db 	sethi  %hi(0x40036c00), %g2                    
40031414:	c6 00 a1 5c 	ld  [ %g2 + 0x15c ], %g3	! 40036d5c <rtems_libio_number_iops>
  ...                                                                 
)                                                                     
{                                                                     
  int            ret;                                                 
  va_list        ap;                                                  
  va_start( ap, cmd );                                                
40031418:	82 07 a0 4c 	add  %fp, 0x4c, %g1                            
4003141c:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        
40031420:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
40031424:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        
40031428:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        
  int            fd2;                                                 
  int            flags;                                               
  int            mask;                                                
  int            ret = 0;                                             
                                                                      
  rtems_libio_check_fd( fd );                                         
4003142c:	80 a6 00 03 	cmp  %i0, %g3                                  
40031430:	1a 80 00 4f 	bcc  4003156c <fcntl+0x160>                    
40031434:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
  iop = rtems_libio_iop( fd );                                        
40031438:	09 10 01 21 	sethi  %hi(0x40048400), %g4                    
4003143c:	c4 01 22 98 	ld  [ %g4 + 0x298 ], %g2	! 40048698 <rtems_libio_iops>
40031440:	b9 2e 20 03 	sll  %i0, 3, %i4                               
40031444:	bb 2e 20 06 	sll  %i0, 6, %i5                               
40031448:	ba 27 40 1c 	sub  %i5, %i4, %i5                             
4003144c:	ba 00 80 1d 	add  %g2, %i5, %i5                             
  rtems_libio_check_is_open(iop);                                     
40031450:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
40031454:	80 8a 21 00 	btst  0x100, %o0                               
40031458:	02 80 00 45 	be  4003156c <fcntl+0x160>                     
4003145c:	b4 10 00 04 	mov  %g4, %i2                                  
                                                                      
  /*                                                                  
   *  This switch should contain all the cases from POSIX.            
   */                                                                 
                                                                      
  switch ( cmd ) {                                                    
40031460:	80 a6 60 14 	cmp  %i1, 0x14                                 
40031464:	18 80 00 92 	bgu  400316ac <fcntl+0x2a0>                    <== NEVER TAKEN
40031468:	89 2e 60 02 	sll  %i1, 2, %g4                               
4003146c:	39 10 00 c4 	sethi  %hi(0x40031000), %i4                    
40031470:	b8 17 23 b8 	or  %i4, 0x3b8, %i4	! 400313b8 <_calloc_r+0x14>
40031474:	c8 07 00 04 	ld  [ %i4 + %g4 ], %g4                         
40031478:	81 c1 00 00 	jmp  %g4                                       
4003147c:	01 00 00 00 	nop                                            
                                                                      
static int duplicate_iop( rtems_libio_t *iop )                        
{                                                                     
  int rv = 0;                                                         
                                                                      
  rtems_libio_t *diop = rtems_libio_allocate();                       
40031480:	7f ff 5b a9 	call  40008324 <rtems_libio_allocate>          
40031484:	01 00 00 00 	nop                                            
                                                                      
  if (diop != NULL) {                                                 
40031488:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4003148c:	02 80 00 9c 	be  400316fc <fcntl+0x2f0>                     <== NEVER TAKEN
40031490:	b0 10 3f ff 	mov  -1, %i0                                   
    int oflag = rtems_libio_to_fcntl_flags( iop->flags );             
40031494:	7f ff 5b 8e 	call  400082cc <rtems_libio_to_fcntl_flags>    
40031498:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
                                                                      
    oflag &= ~O_CREAT;                                                
    diop->flags |= rtems_libio_fcntl_flags( oflag );                  
4003149c:	f0 07 20 10 	ld  [ %i4 + 0x10 ], %i0                        
  rtems_libio_t *diop = rtems_libio_allocate();                       
                                                                      
  if (diop != NULL) {                                                 
    int oflag = rtems_libio_to_fcntl_flags( iop->flags );             
                                                                      
    oflag &= ~O_CREAT;                                                
400314a0:	b6 0a 3d ff 	and  %o0, -513, %i3                            
    diop->flags |= rtems_libio_fcntl_flags( oflag );                  
400314a4:	7f ff 5b 7d 	call  40008298 <rtems_libio_fcntl_flags>       
400314a8:	90 10 00 1b 	mov  %i3, %o0                                  
400314ac:	90 12 00 18 	or  %o0, %i0, %o0                              
400314b0:	d0 27 20 10 	st  %o0, [ %i4 + 0x10 ]                        
                                                                      
    rtems_filesystem_instance_lock( &iop->pathinfo );                 
400314b4:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->lock_h)( mt_entry );                               
400314b8:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
400314bc:	c2 00 40 00 	ld  [ %g1 ], %g1                               
400314c0:	9f c0 40 00 	call  %g1                                      
400314c4:	01 00 00 00 	nop                                            
    rtems_filesystem_location_clone( &diop->pathinfo, &iop->pathinfo );
400314c8:	92 07 60 14 	add  %i5, 0x14, %o1                            
400314cc:	7f ff 94 9c 	call  4001673c <rtems_filesystem_location_clone>
400314d0:	90 07 20 14 	add  %i4, 0x14, %o0                            
    int oflag = rtems_libio_to_fcntl_flags( iop->flags );             
                                                                      
    oflag &= ~O_CREAT;                                                
    diop->flags |= rtems_libio_fcntl_flags( oflag );                  
                                                                      
    rtems_filesystem_instance_lock( &iop->pathinfo );                 
400314d4:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->unlock_h)( mt_entry );                             
400314d8:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
400314dc:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
400314e0:	9f c0 40 00 	call  %g1                                      
400314e4:	01 00 00 00 	nop                                            
    /*                                                                
     * XXX: We call the open handler here to have a proper open and close pair.
     *                                                                
     * FIXME: What to do with the path?                               
     */                                                               
    rv = (*diop->pathinfo.handlers->open_h)( diop, NULL, oflag, 0 );  
400314e8:	c2 07 20 24 	ld  [ %i4 + 0x24 ], %g1                        
400314ec:	90 10 00 1c 	mov  %i4, %o0                                  
400314f0:	c2 00 40 00 	ld  [ %g1 ], %g1                               
400314f4:	92 10 20 00 	clr  %o1                                       
400314f8:	94 10 00 1b 	mov  %i3, %o2                                  
400314fc:	9f c0 40 00 	call  %g1                                      
40031500:	96 10 20 00 	clr  %o3                                       
    if ( rv == 0 ) {                                                  
40031504:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40031508:	12 80 00 11 	bne  4003154c <fcntl+0x140>                    <== NEVER TAKEN
4003150c:	01 00 00 00 	nop                                            
      rv = diop - rtems_libio_iops;                                   
40031510:	f0 06 a2 98 	ld  [ %i2 + 0x298 ], %i0                       
40031514:	b8 27 00 18 	sub  %i4, %i0, %i4                             
40031518:	b9 3f 20 03 	sra  %i4, 3, %i4                               
4003151c:	85 2f 20 03 	sll  %i4, 3, %g2                               
40031520:	83 2f 20 06 	sll  %i4, 6, %g1                               
40031524:	82 00 80 01 	add  %g2, %g1, %g1                             
40031528:	85 28 60 06 	sll  %g1, 6, %g2                               
4003152c:	82 00 40 02 	add  %g1, %g2, %g1                             
40031530:	82 00 40 1c 	add  %g1, %i4, %g1                             
40031534:	b1 28 60 0f 	sll  %g1, 0xf, %i0                             
40031538:	82 00 40 18 	add  %g1, %i0, %g1                             
4003153c:	83 28 60 03 	sll  %g1, 3, %g1                               
40031540:	b8 00 40 1c 	add  %g1, %i4, %i4                             
40031544:	10 80 00 5f 	b  400316c0 <fcntl+0x2b4>                      
40031548:	b0 20 00 1c 	neg  %i4, %i0                                  
    } else {                                                          
      rtems_libio_free( diop );                                       
4003154c:	7f ff 5b 8c 	call  4000837c <rtems_libio_free>              <== NOT EXECUTED
40031550:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
  /*                                                                  
   *  If we got this far successfully, then we give the optional      
   *  filesystem specific handler a chance to process this.           
   */                                                                 
                                                                      
  if (ret >= 0) {                                                     
40031554:	10 80 00 5c 	b  400316c4 <fcntl+0x2b8>                      <== NOT EXECUTED
40031558:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
    case F_DUPFD:        /* dup */                                    
      ret = duplicate_iop( iop );                                     
      break;                                                          
                                                                      
    case F_DUP2FD:       /* dup2 */                                   
      fd2 = va_arg( ap, int );                                        
4003155c:	f0 00 40 00 	ld  [ %g1 ], %i0                               
static int duplicate2_iop( rtems_libio_t *iop, int fd2 )              
{                                                                     
  rtems_libio_t *iop2;                                                
  int            rv = 0;                                              
                                                                      
  rtems_libio_check_fd( fd2 );                                        
40031560:	80 a6 00 03 	cmp  %i0, %g3                                  
40031564:	0a 80 00 06 	bcs  4003157c <fcntl+0x170>                    <== ALWAYS TAKEN
40031568:	b9 2e 20 03 	sll  %i0, 3, %i4                               
4003156c:	7f ff be 4c 	call  40020e9c <__errno>                       
40031570:	01 00 00 00 	nop                                            
40031574:	10 80 00 51 	b  400316b8 <fcntl+0x2ac>                      
40031578:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  iop2 = rtems_libio_iop( fd2 );                                      
4003157c:	83 2e 20 06 	sll  %i0, 6, %g1                               
40031580:	b8 20 40 1c 	sub  %g1, %i4, %i4                             
40031584:	b8 00 80 1c 	add  %g2, %i4, %i4                             
                                                                      
  if (iop != iop2)                                                    
40031588:	80 a7 40 1c 	cmp  %i5, %i4                                  
4003158c:	22 80 00 50 	be,a   400316cc <fcntl+0x2c0>                  <== NEVER TAKEN
40031590:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
  {                                                                   
    int oflag;                                                        
                                                                      
    if ((iop2->flags & LIBIO_FLAGS_OPEN) != 0) {                      
40031594:	c2 07 20 10 	ld  [ %i4 + 0x10 ], %g1                        
40031598:	80 88 61 00 	btst  0x100, %g1                               
4003159c:	32 80 00 23 	bne,a   40031628 <fcntl+0x21c>                 <== ALWAYS TAKEN
400315a0:	c2 07 20 24 	ld  [ %i4 + 0x24 ], %g1                        
      rv = (*iop2->pathinfo.handlers->close_h)( iop2 );               
    }                                                                 
                                                                      
    if (rv == 0) {                                                    
      oflag = rtems_libio_to_fcntl_flags( iop->flags );               
400315a4:	7f ff 5b 4a 	call  400082cc <rtems_libio_to_fcntl_flags>    
400315a8:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
      oflag &= ~O_CREAT;                                              
      iop2->flags |= rtems_libio_fcntl_flags( oflag );                
400315ac:	f4 07 20 10 	ld  [ %i4 + 0x10 ], %i2                        
      rv = (*iop2->pathinfo.handlers->close_h)( iop2 );               
    }                                                                 
                                                                      
    if (rv == 0) {                                                    
      oflag = rtems_libio_to_fcntl_flags( iop->flags );               
      oflag &= ~O_CREAT;                                              
400315b0:	b6 0a 3d ff 	and  %o0, -513, %i3                            
      iop2->flags |= rtems_libio_fcntl_flags( oflag );                
400315b4:	7f ff 5b 39 	call  40008298 <rtems_libio_fcntl_flags>       
400315b8:	90 10 00 1b 	mov  %i3, %o0                                  
400315bc:	90 12 00 1a 	or  %o0, %i2, %o0                              
400315c0:	d0 27 20 10 	st  %o0, [ %i4 + 0x10 ]                        
                                                                      
      rtems_filesystem_instance_lock( &iop->pathinfo );               
400315c4:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->lock_h)( mt_entry );                               
400315c8:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
400315cc:	c2 00 40 00 	ld  [ %g1 ], %g1                               
400315d0:	9f c0 40 00 	call  %g1                                      
400315d4:	01 00 00 00 	nop                                            
      rtems_filesystem_location_clone( &iop2->pathinfo, &iop->pathinfo );
400315d8:	92 07 60 14 	add  %i5, 0x14, %o1                            
400315dc:	7f ff 94 58 	call  4001673c <rtems_filesystem_location_clone>
400315e0:	90 07 20 14 	add  %i4, 0x14, %o0                            
    if (rv == 0) {                                                    
      oflag = rtems_libio_to_fcntl_flags( iop->flags );               
      oflag &= ~O_CREAT;                                              
      iop2->flags |= rtems_libio_fcntl_flags( oflag );                
                                                                      
      rtems_filesystem_instance_lock( &iop->pathinfo );               
400315e4:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->unlock_h)( mt_entry );                             
400315e8:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
400315ec:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
400315f0:	9f c0 40 00 	call  %g1                                      
400315f4:	01 00 00 00 	nop                                            
       * XXX: We call the open handler here to have a proper open and close
       *      pair.                                                   
       *                                                              
       * FIXME: What to do with the path?                             
       */                                                             
      rv = (*iop2->pathinfo.handlers->open_h)( iop2, NULL, oflag, 0 );
400315f8:	c2 07 20 24 	ld  [ %i4 + 0x24 ], %g1                        
400315fc:	90 10 00 1c 	mov  %i4, %o0                                  
40031600:	c2 00 40 00 	ld  [ %g1 ], %g1                               
40031604:	92 10 20 00 	clr  %o1                                       
40031608:	94 10 00 1b 	mov  %i3, %o2                                  
4003160c:	9f c0 40 00 	call  %g1                                      
40031610:	96 10 20 00 	clr  %o3                                       
      if ( rv == 0 ) {                                                
40031614:	80 a2 20 00 	cmp  %o0, 0                                    
40031618:	02 80 00 2b 	be  400316c4 <fcntl+0x2b8>                     <== ALWAYS TAKEN
4003161c:	80 a6 20 00 	cmp  %i0, 0                                    
      else                                                            
        iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;                     
      break;                                                          
                                                                      
    case F_GETFL:        /* more flags (cloexec) */                   
      ret = rtems_libio_to_fcntl_flags( iop->flags );                 
40031620:	10 80 00 28 	b  400316c0 <fcntl+0x2b4>                      <== NOT EXECUTED
40031624:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
  if (iop != iop2)                                                    
  {                                                                   
    int oflag;                                                        
                                                                      
    if ((iop2->flags & LIBIO_FLAGS_OPEN) != 0) {                      
      rv = (*iop2->pathinfo.handlers->close_h)( iop2 );               
40031628:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
4003162c:	9f c0 40 00 	call  %g1                                      
40031630:	90 10 00 1c 	mov  %i4, %o0                                  
    }                                                                 
                                                                      
    if (rv == 0) {                                                    
40031634:	80 a2 20 00 	cmp  %o0, 0                                    
40031638:	32 80 00 22 	bne,a   400316c0 <fcntl+0x2b4>                 <== NEVER TAKEN
4003163c:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
40031640:	30 bf ff d9 	b,a   400315a4 <fcntl+0x198>                   
      fd2 = va_arg( ap, int );                                        
      ret = duplicate2_iop( iop, fd2 );                               
      break;                                                          
                                                                      
    case F_GETFD:        /* get f_flags */                            
      ret = ((iop->flags & LIBIO_FLAGS_CLOSE_ON_EXEC) != 0);          
40031644:	b1 32 20 0b 	srl  %o0, 0xb, %i0                             
40031648:	10 80 00 21 	b  400316cc <fcntl+0x2c0>                      
4003164c:	b0 0e 20 01 	and  %i0, 1, %i0                               
       *  if a new process is exec()'ed.  Since RTEMS does not support
       *  processes, then we can ignore this one except to make       
       *  F_GETFD work.                                               
       */                                                             
                                                                      
      if ( va_arg( ap, int ) )                                        
40031650:	c2 00 40 00 	ld  [ %g1 ], %g1                               
40031654:	80 a0 60 00 	cmp  %g1, 0                                    
40031658:	22 80 00 0e 	be,a   40031690 <fcntl+0x284>                  
4003165c:	90 0a 37 ff 	and  %o0, -2049, %o0                           
        iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC;                      
40031660:	10 80 00 0c 	b  40031690 <fcntl+0x284>                      
40031664:	90 12 28 00 	or  %o0, 0x800, %o0                            
      else                                                            
        iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;                     
      break;                                                          
                                                                      
    case F_GETFL:        /* more flags (cloexec) */                   
      ret = rtems_libio_to_fcntl_flags( iop->flags );                 
40031668:	7f ff 5b 19 	call  400082cc <rtems_libio_to_fcntl_flags>    
4003166c:	01 00 00 00 	nop                                            
40031670:	10 80 00 14 	b  400316c0 <fcntl+0x2b4>                      
40031674:	b0 10 00 08 	mov  %o0, %i0                                  
      break;                                                          
                                                                      
    case F_SETFL:                                                     
      flags = rtems_libio_fcntl_flags( va_arg( ap, int ) );           
40031678:	7f ff 5b 08 	call  40008298 <rtems_libio_fcntl_flags>       
4003167c:	d0 00 40 00 	ld  [ %g1 ], %o0                               
                                                                      
      /*                                                              
       *  XXX If we are turning on append, should we seek to the end? 
       */                                                             
                                                                      
      iop->flags = (iop->flags & ~mask) | (flags & mask);             
40031680:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
40031684:	90 0a 22 01 	and  %o0, 0x201, %o0                           
40031688:	82 08 7d fe 	and  %g1, -514, %g1                            
4003168c:	90 12 00 01 	or  %o0, %g1, %o0                              
40031690:	d0 27 60 10 	st  %o0, [ %i5 + 0x10 ]                        
{                                                                     
  rtems_libio_t *iop;                                                 
  int            fd2;                                                 
  int            flags;                                               
  int            mask;                                                
  int            ret = 0;                                             
40031694:	10 80 00 0e 	b  400316cc <fcntl+0x2c0>                      
40031698:	b0 10 20 00 	clr  %i0                                       
      errno = ENOTSUP;                                                
      ret = -1;                                                       
      break;                                                          
                                                                      
    case F_GETOWN:       /*  for sockets. */                          
      errno = ENOTSUP;                                                
4003169c:	7f ff be 00 	call  40020e9c <__errno>                       
400316a0:	01 00 00 00 	nop                                            
400316a4:	10 80 00 05 	b  400316b8 <fcntl+0x2ac>                      
400316a8:	82 10 20 86 	mov  0x86, %g1	! 86 <_TLS_Alignment+0x85>      
      ret = -1;                                                       
      break;                                                          
                                                                      
    default:                                                          
      errno = EINVAL;                                                 
400316ac:	7f ff bd fc 	call  40020e9c <__errno>                       
400316b0:	01 00 00 00 	nop                                            
400316b4:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
400316b8:	10 80 00 10 	b  400316f8 <fcntl+0x2ec>                      
400316bc:	c2 22 00 00 	st  %g1, [ %o0 ]                               
  /*                                                                  
   *  If we got this far successfully, then we give the optional      
   *  filesystem specific handler a chance to process this.           
   */                                                                 
                                                                      
  if (ret >= 0) {                                                     
400316c0:	80 a6 20 00 	cmp  %i0, 0                                    
400316c4:	06 80 00 0e 	bl  400316fc <fcntl+0x2f0>                     <== NEVER TAKEN
400316c8:	01 00 00 00 	nop                                            
    int err = (*iop->pathinfo.handlers->fcntl_h)( iop, cmd );         
400316cc:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
400316d0:	90 10 00 1d 	mov  %i5, %o0                                  
400316d4:	c2 00 60 28 	ld  [ %g1 + 0x28 ], %g1                        
400316d8:	9f c0 40 00 	call  %g1                                      
400316dc:	92 10 00 19 	mov  %i1, %o1                                  
    if (err) {                                                        
400316e0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400316e4:	02 80 00 06 	be  400316fc <fcntl+0x2f0>                     <== ALWAYS TAKEN
400316e8:	01 00 00 00 	nop                                            
      errno = err;                                                    
400316ec:	7f ff bd ec 	call  40020e9c <__errno>                       <== NOT EXECUTED
400316f0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400316f4:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
   *  filesystem specific handler a chance to process this.           
   */                                                                 
                                                                      
  if (ret >= 0) {                                                     
    int err = (*iop->pathinfo.handlers->fcntl_h)( iop, cmd );         
    if (err) {                                                        
400316f8:	b0 10 3f ff 	mov  -1, %i0                                   
  va_list        ap;                                                  
  va_start( ap, cmd );                                                
  ret = vfcntl(fd,cmd,ap);                                            
  va_end(ap);                                                         
  return ret;                                                         
}                                                                     
400316fc:	81 c7 e0 08 	ret                                            
40031700:	81 e8 00 00 	restore                                        
                                                                      

4000487c <fdatasync>: #include <rtems/seterr.h> int fdatasync( int fd ) {
4000487c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_libio_t *iop;                                                 
                                                                      
  rtems_libio_check_fd( fd );                                         
40004880:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40004884:	c2 00 62 00 	ld  [ %g1 + 0x200 ], %g1	! 40018200 <rtems_libio_number_iops>
40004888:	80 a6 00 01 	cmp  %i0, %g1                                  
4000488c:	0a 80 00 08 	bcs  400048ac <fdatasync+0x30>                 <== ALWAYS TAKEN
40004890:	83 2e 20 03 	sll  %i0, 3, %g1                               
40004894:	40 00 32 bc 	call  40011384 <__errno>                       
40004898:	b0 10 3f ff 	mov  -1, %i0                                   
4000489c:	82 10 20 09 	mov  9, %g1                                    
400048a0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400048a4:	81 c7 e0 08 	ret                                            
400048a8:	81 e8 00 00 	restore                                        
  iop = rtems_libio_iop( fd );                                        
400048ac:	b1 2e 20 06 	sll  %i0, 6, %i0                               
400048b0:	b0 26 00 01 	sub  %i0, %g1, %i0                             
400048b4:	03 10 00 66 	sethi  %hi(0x40019800), %g1                    
400048b8:	d0 00 61 f0 	ld  [ %g1 + 0x1f0 ], %o0	! 400199f0 <rtems_libio_iops>
400048bc:	90 02 00 18 	add  %o0, %i0, %o0                             
  rtems_libio_check_is_open(iop);                                     
400048c0:	c2 02 20 10 	ld  [ %o0 + 0x10 ], %g1                        
400048c4:	80 88 61 00 	btst  0x100, %g1                               
400048c8:	02 bf ff f3 	be  40004894 <fdatasync+0x18>                  <== NEVER TAKEN
400048cc:	80 88 60 04 	btst  4, %g1                                   
  rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
400048d0:	02 bf ff f1 	be  40004894 <fdatasync+0x18>                  
400048d4:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   *  Now process the fdatasync().                                    
   */                                                                 
                                                                      
  return (*iop->pathinfo.handlers->fdatasync_h)( iop );               
400048d8:	c2 02 20 24 	ld  [ %o0 + 0x24 ], %g1                        
400048dc:	c2 00 60 24 	ld  [ %g1 + 0x24 ], %g1                        
400048e0:	9f c0 40 00 	call  %g1                                      
400048e4:	01 00 00 00 	nop                                            
}                                                                     
400048e8:	81 c7 e0 08 	ret                                            
400048ec:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000e194 <fifo_open>: int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) {
4000e194:	9d e3 bf 98 	save  %sp, -104, %sp                           
                                                                      
static int pipe_lock(void)                                            
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  if (pipe_semaphore == RTEMS_ID_NONE) {                              
4000e198:	35 10 00 92 	sethi  %hi(0x40024800), %i2                    
4000e19c:	c2 06 a1 c8 	ld  [ %i2 + 0x1c8 ], %g1	! 400249c8 <pipe_semaphore>
                                                                      
int fifo_open(                                                        
  pipe_control_t **pipep,                                             
  rtems_libio_t *iop                                                  
)                                                                     
{                                                                     
4000e1a0:	b6 10 00 18 	mov  %i0, %i3                                  
                                                                      
static int pipe_lock(void)                                            
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  if (pipe_semaphore == RTEMS_ID_NONE) {                              
4000e1a4:	80 a0 60 00 	cmp  %g1, 0                                    
4000e1a8:	02 80 00 0b 	be  4000e1d4 <fifo_open+0x40>                  
4000e1ac:	b0 16 a1 c8 	or  %i2, 0x1c8, %i0                            
                                                                      
    rtems_libio_unlock();                                             
  }                                                                   
                                                                      
  if (sc == RTEMS_SUCCESSFUL) {                                       
    sc = rtems_semaphore_obtain(pipe_semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
4000e1b0:	d0 06 a1 c8 	ld  [ %i2 + 0x1c8 ], %o0                       
4000e1b4:	92 10 20 00 	clr  %o1                                       
4000e1b8:	7f ff eb eb 	call  40009164 <rtems_semaphore_obtain>        
4000e1bc:	94 10 20 00 	clr  %o2                                       
  }                                                                   
                                                                      
  if (sc == RTEMS_SUCCESSFUL) {                                       
4000e1c0:	80 a2 20 00 	cmp  %o0, 0                                    
4000e1c4:	22 80 00 1c 	be,a   4000e234 <fifo_open+0xa0>               <== ALWAYS TAKEN
4000e1c8:	fa 06 c0 00 	ld  [ %i3 ], %i5                               
    return 0;                                                         
  } else {                                                            
    return -ENOMEM;                                                   
4000e1cc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e1d0:	91 e8 3f f4 	restore  %g0, -12, %o0                         <== NOT EXECUTED
                                                                      
extern pthread_key_t rtems_current_user_env_key;                      
                                                                      
static inline void rtems_libio_lock( void )                           
{                                                                     
  rtems_semaphore_obtain( rtems_libio_semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT );
4000e1d4:	3b 10 00 93 	sethi  %hi(0x40024c00), %i5                    
4000e1d8:	d0 07 62 3c 	ld  [ %i5 + 0x23c ], %o0	! 40024e3c <rtems_libio_semaphore>
4000e1dc:	92 10 20 00 	clr  %o1                                       
4000e1e0:	7f ff eb e1 	call  40009164 <rtems_semaphore_obtain>        
4000e1e4:	94 10 20 00 	clr  %o2                                       
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  if (pipe_semaphore == RTEMS_ID_NONE) {                              
    rtems_libio_lock();                                               
                                                                      
    if (pipe_semaphore == RTEMS_ID_NONE) {                            
4000e1e8:	c2 06 a1 c8 	ld  [ %i2 + 0x1c8 ], %g1                       
4000e1ec:	80 a0 60 00 	cmp  %g1, 0                                    
4000e1f0:	12 80 00 0a 	bne  4000e218 <fifo_open+0x84>                 <== NEVER TAKEN
4000e1f4:	b8 10 20 00 	clr  %i4                                       
      sc = rtems_semaphore_create(                                    
4000e1f8:	11 14 12 54 	sethi  %hi(0x50495000), %o0                    
4000e1fc:	92 10 20 01 	mov  1, %o1                                    
4000e200:	90 12 20 45 	or  %o0, 0x45, %o0                             
4000e204:	94 10 20 54 	mov  0x54, %o2                                 
4000e208:	96 10 20 00 	clr  %o3                                       
4000e20c:	7f ff eb 23 	call  40008e98 <rtems_semaphore_create>        
4000e210:	98 10 00 18 	mov  %i0, %o4                                  
4000e214:	b8 10 00 08 	mov  %o0, %i4                                  
}                                                                     
                                                                      
static inline void rtems_libio_unlock( void )                         
{                                                                     
  rtems_semaphore_release( rtems_libio_semaphore );                   
4000e218:	7f ff ec 1b 	call  40009284 <rtems_semaphore_release>       
4000e21c:	d0 07 62 3c 	ld  [ %i5 + 0x23c ], %o0                       
    }                                                                 
                                                                      
    rtems_libio_unlock();                                             
  }                                                                   
                                                                      
  if (sc == RTEMS_SUCCESSFUL) {                                       
4000e220:	80 a7 20 00 	cmp  %i4, 0                                    
4000e224:	02 bf ff e4 	be  4000e1b4 <fifo_open+0x20>                  
4000e228:	d0 06 a1 c8 	ld  [ %i2 + 0x1c8 ], %o0                       
  }                                                                   
                                                                      
  if (sc == RTEMS_SUCCESSFUL) {                                       
    return 0;                                                         
  } else {                                                            
    return -ENOMEM;                                                   
4000e22c:	81 c7 e0 08 	ret                                            
4000e230:	91 e8 3f f4 	restore  %g0, -12, %o0                         
  err = pipe_lock();                                                  
  if (err)                                                            
    return err;                                                       
                                                                      
  pipe = *pipep;                                                      
  if (pipe == NULL) {                                                 
4000e234:	80 a7 60 00 	cmp  %i5, 0                                    
4000e238:	32 80 00 54 	bne,a   4000e388 <fifo_open+0x1f4>             
4000e23c:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
{                                                                     
  static char c = 'a';                                                
  pipe_control_t *pipe;                                               
  int err = -ENOMEM;                                                  
                                                                      
  pipe = malloc(sizeof(pipe_control_t));                              
4000e240:	7f ff db ca 	call  40005168 <malloc>                        
4000e244:	90 10 20 34 	mov  0x34, %o0                                 
  if (pipe == NULL)                                                   
4000e248:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e24c:	02 80 00 e1 	be  4000e5d0 <fifo_open+0x43c>                 <== NEVER TAKEN
4000e250:	92 10 20 00 	clr  %o1                                       
    return err;                                                       
  memset(pipe, 0, sizeof(pipe_control_t));                            
4000e254:	40 00 11 24 	call  400126e4 <memset>                        
4000e258:	94 10 20 34 	mov  0x34, %o2                                 
                                                                      
  pipe->Size = PIPE_BUF;                                              
4000e25c:	82 10 22 00 	mov  0x200, %g1                                
  pipe->Buffer = malloc(pipe->Size);                                  
4000e260:	90 10 22 00 	mov  0x200, %o0                                
4000e264:	7f ff db c1 	call  40005168 <malloc>                        
4000e268:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
  if (! pipe->Buffer)                                                 
4000e26c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e270:	02 80 00 40 	be  4000e370 <fifo_open+0x1dc>                 <== NEVER TAKEN
4000e274:	d0 27 40 00 	st  %o0, [ %i5 ]                               
    goto err_buf;                                                     
                                                                      
  err = -ENOMEM;                                                      
                                                                      
  if (rtems_barrier_create(                                           
        rtems_build_name ('P', 'I', 'r', c),                          
4000e278:	39 10 00 8d 	sethi  %hi(0x40023400), %i4                    
4000e27c:	d0 4f 23 1c 	ldsb  [ %i4 + 0x31c ], %o0	! 4002371c <c.6780> 
  if (! pipe->Buffer)                                                 
    goto err_buf;                                                     
                                                                      
  err = -ENOMEM;                                                      
                                                                      
  if (rtems_barrier_create(                                           
4000e280:	31 14 12 5c 	sethi  %hi(0x50497000), %i0                    
4000e284:	82 16 22 00 	or  %i0, 0x200, %g1	! 50497200 <RAM_END+0x10097200>
4000e288:	92 10 20 00 	clr  %o1                                       
4000e28c:	90 12 00 01 	or  %o0, %g1, %o0                              
4000e290:	94 10 20 00 	clr  %o2                                       
4000e294:	40 00 05 b4 	call  4000f964 <rtems_barrier_create>          
4000e298:	96 07 60 2c 	add  %i5, 0x2c, %o3                            
4000e29c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e2a0:	12 80 00 32 	bne  4000e368 <fifo_open+0x1d4>                
4000e2a4:	d0 4f 23 1c 	ldsb  [ %i4 + 0x31c ], %o0                     
        rtems_build_name ('P', 'I', 'r', c),                          
        RTEMS_BARRIER_MANUAL_RELEASE, 0,                              
        &pipe->readBarrier) != RTEMS_SUCCESSFUL)                      
    goto err_rbar;                                                    
  if (rtems_barrier_create(                                           
4000e2a8:	03 14 12 5d 	sethi  %hi(0x50497400), %g1                    
4000e2ac:	82 10 63 00 	or  %g1, 0x300, %g1	! 50497700 <RAM_END+0x10097700>
4000e2b0:	92 10 20 00 	clr  %o1                                       
4000e2b4:	90 12 00 01 	or  %o0, %g1, %o0                              
4000e2b8:	94 10 20 00 	clr  %o2                                       
4000e2bc:	40 00 05 aa 	call  4000f964 <rtems_barrier_create>          
4000e2c0:	96 07 60 30 	add  %i5, 0x30, %o3                            
4000e2c4:	80 a2 20 00 	cmp  %o0, 0                                    
4000e2c8:	12 80 00 26 	bne  4000e360 <fifo_open+0x1cc>                
4000e2cc:	d0 4f 23 1c 	ldsb  [ %i4 + 0x31c ], %o0                     
        rtems_build_name ('P', 'I', 'w', c),                          
        RTEMS_BARRIER_MANUAL_RELEASE, 0,                              
        &pipe->writeBarrier) != RTEMS_SUCCESSFUL)                     
    goto err_wbar;                                                    
  if (rtems_semaphore_create(                                         
4000e2d0:	b0 16 23 00 	or  %i0, 0x300, %i0                            
4000e2d4:	92 10 20 01 	mov  1, %o1                                    
4000e2d8:	90 12 00 18 	or  %o0, %i0, %o0                              
4000e2dc:	94 10 20 10 	mov  0x10, %o2                                 
4000e2e0:	96 10 20 00 	clr  %o3                                       
4000e2e4:	7f ff ea ed 	call  40008e98 <rtems_semaphore_create>        
4000e2e8:	98 07 60 28 	add  %i5, 0x28, %o4                            
4000e2ec:	80 a2 20 00 	cmp  %o0, 0                                    
4000e2f0:	12 80 00 1a 	bne  4000e358 <fifo_open+0x1c4>                
4000e2f4:	94 07 bf fc 	add  %fp, -4, %o2                              
RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Get (                  
  Objects_Id         id,                                              
  Objects_Locations *location                                         
)                                                                     
{                                                                     
  return (Barrier_Control *)                                          
4000e2f8:	d2 07 60 2c 	ld  [ %i5 + 0x2c ], %o1                        
4000e2fc:	21 10 00 96 	sethi  %hi(0x40025800), %l0                    
4000e300:	7f ff f2 2c 	call  4000abb0 <_Objects_Get>                  
4000e304:	90 14 23 78 	or  %l0, 0x378, %o0	! 40025b78 <_Barrier_Information>
{                                                                     
  Objects_Locations  location;                                        
  Barrier_Control   *the_barrier;                                     
                                                                      
  the_barrier = _Barrier_Get(pipe->readBarrier, &location);           
  the_barrier->Barrier.Wait_queue.state |= STATES_INTERRUPTIBLE_BY_SIGNAL;
4000e308:	c2 02 20 4c 	ld  [ %o0 + 0x4c ], %g1                        
4000e30c:	31 04 00 00 	sethi  %hi(0x10000000), %i0                    
4000e310:	82 10 40 18 	or  %g1, %i0, %g1                              
RTEMS_INLINE_ROUTINE void _Objects_Put(                               
  Objects_Control *the_object                                         
)                                                                     
{                                                                     
  (void) the_object;                                                  
  _Thread_Enable_dispatch();                                          
4000e314:	7f ff f5 78 	call  4000b8f4 <_Thread_Enable_dispatch>       
4000e318:	c2 22 20 4c 	st  %g1, [ %o0 + 0x4c ]                        
4000e31c:	d2 07 60 30 	ld  [ %i5 + 0x30 ], %o1                        
4000e320:	94 07 bf fc 	add  %fp, -4, %o2                              
4000e324:	7f ff f2 23 	call  4000abb0 <_Objects_Get>                  
4000e328:	90 14 23 78 	or  %l0, 0x378, %o0                            
  _Objects_Put( &the_barrier->Object );                               
                                                                      
  the_barrier = _Barrier_Get(pipe->writeBarrier, &location);          
  the_barrier->Barrier.Wait_queue.state |= STATES_INTERRUPTIBLE_BY_SIGNAL;
4000e32c:	c2 02 20 4c 	ld  [ %o0 + 0x4c ], %g1                        
4000e330:	b0 10 40 18 	or  %g1, %i0, %i0                              
4000e334:	7f ff f5 70 	call  4000b8f4 <_Thread_Enable_dispatch>       
4000e338:	f0 22 20 4c 	st  %i0, [ %o0 + 0x4c ]                        
#ifdef RTEMS_POSIX_API                                                
  pipe_interruptible(pipe);                                           
#endif                                                                
                                                                      
  *pipep = pipe;                                                      
  if (c ++ == 'z')                                                    
4000e33c:	c2 0f 23 1c 	ldub  [ %i4 + 0x31c ], %g1                     
4000e340:	c4 4f 23 1c 	ldsb  [ %i4 + 0x31c ], %g2                     
4000e344:	80 a0 a0 7a 	cmp  %g2, 0x7a                                 
4000e348:	12 80 00 0e 	bne  4000e380 <fifo_open+0x1ec>                
4000e34c:	82 00 60 01 	inc  %g1                                       
    c = 'a';                                                          
4000e350:	10 80 00 0c 	b  4000e380 <fifo_open+0x1ec>                  
4000e354:	82 10 20 61 	mov  0x61, %g1                                 
  return 0;                                                           
                                                                      
err_sem:                                                              
  rtems_barrier_delete(pipe->writeBarrier);                           
4000e358:	40 00 05 b0 	call  4000fa18 <rtems_barrier_delete>          
4000e35c:	d0 07 60 30 	ld  [ %i5 + 0x30 ], %o0                        
err_wbar:                                                             
  rtems_barrier_delete(pipe->readBarrier);                            
4000e360:	40 00 05 ae 	call  4000fa18 <rtems_barrier_delete>          
4000e364:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        
err_rbar:                                                             
  free(pipe->Buffer);                                                 
4000e368:	7f ff da 73 	call  40004d34 <free>                          
4000e36c:	d0 07 40 00 	ld  [ %i5 ], %o0                               
err_buf:                                                              
  free(pipe);                                                         
4000e370:	7f ff da 71 	call  40004d34 <free>                          
4000e374:	90 10 00 1d 	mov  %i5, %o0                                  
    if (err)                                                          
      goto out;                                                       
  }                                                                   
                                                                      
  if (! PIPE_LOCK(pipe))                                              
    err = -EINTR;                                                     
4000e378:	10 80 00 12 	b  4000e3c0 <fifo_open+0x22c>                  
4000e37c:	b0 10 3f f4 	mov  -12, %i0                                  
#ifdef RTEMS_POSIX_API                                                
  pipe_interruptible(pipe);                                           
#endif                                                                
                                                                      
  *pipep = pipe;                                                      
  if (c ++ == 'z')                                                    
4000e380:	c2 2f 23 1c 	stb  %g1, [ %i4 + 0x31c ]                      
    err = pipe_alloc(&pipe);                                          
    if (err)                                                          
      goto out;                                                       
  }                                                                   
                                                                      
  if (! PIPE_LOCK(pipe))                                              
4000e384:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e388:	92 10 20 00 	clr  %o1                                       
4000e38c:	7f ff eb 76 	call  40009164 <rtems_semaphore_obtain>        
4000e390:	94 10 20 00 	clr  %o2                                       
    err = -EINTR;                                                     
                                                                      
  if (*pipep == NULL) {                                               
4000e394:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
    err = pipe_alloc(&pipe);                                          
    if (err)                                                          
      goto out;                                                       
  }                                                                   
                                                                      
  if (! PIPE_LOCK(pipe))                                              
4000e398:	80 a0 00 08 	cmp  %g0, %o0                                  
4000e39c:	b0 60 20 00 	subx  %g0, 0, %i0                              
    err = -EINTR;                                                     
                                                                      
  if (*pipep == NULL) {                                               
4000e3a0:	80 a0 60 00 	cmp  %g1, 0                                    
4000e3a4:	12 80 00 07 	bne  4000e3c0 <fifo_open+0x22c>                
4000e3a8:	b0 0e 3f fc 	and  %i0, -4, %i0                              
    if (err)                                                          
4000e3ac:	80 a6 20 00 	cmp  %i0, 0                                    
4000e3b0:	22 80 00 04 	be,a   4000e3c0 <fifo_open+0x22c>              <== ALWAYS TAKEN
4000e3b4:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
      pipe_free(pipe);                                                
4000e3b8:	7f ff ff 3f 	call  4000e0b4 <pipe_free>                     <== NOT EXECUTED
4000e3bc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
#ifdef RTEMS_DEBUG                                                    
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  sc =                                                                
#endif                                                                
   rtems_semaphore_release(pipe_semaphore);                           
4000e3c0:	7f ff eb b1 	call  40009284 <rtems_semaphore_release>       
4000e3c4:	d0 06 a1 c8 	ld  [ %i2 + 0x1c8 ], %o0                       
  pipe_control_t *pipe;                                               
  unsigned int prevCounter;                                           
  int err;                                                            
                                                                      
  err = pipe_new(pipep);                                              
  if (err)                                                            
4000e3c8:	80 a6 20 00 	cmp  %i0, 0                                    
4000e3cc:	12 80 00 83 	bne  4000e5d8 <fifo_open+0x444>                
4000e3d0:	01 00 00 00 	nop                                            
    return err;                                                       
  pipe = *pipep;                                                      
                                                                      
  switch (LIBIO_ACCMODE(iop)) {                                       
4000e3d4:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000e3d8:	82 08 60 06 	and  %g1, 6, %g1                               
4000e3dc:	80 a0 60 04 	cmp  %g1, 4                                    
4000e3e0:	02 80 00 2f 	be  4000e49c <fifo_open+0x308>                 
4000e3e4:	fa 06 c0 00 	ld  [ %i3 ], %i5                               
4000e3e8:	80 a0 60 06 	cmp  %g1, 6                                    
4000e3ec:	02 80 00 58 	be  4000e54c <fifo_open+0x3b8>                 
4000e3f0:	80 a0 60 02 	cmp  %g1, 2                                    
4000e3f4:	32 80 00 6d 	bne,a   4000e5a8 <fifo_open+0x414>             <== NEVER TAKEN
4000e3f8:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        <== NOT EXECUTED
    case LIBIO_FLAGS_READ:                                            
      pipe->readerCounter ++;                                         
4000e3fc:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
4000e400:	82 00 60 01 	inc  %g1                                       
4000e404:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
      if (pipe->Readers ++ == 0)                                      
4000e408:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000e40c:	84 00 60 01 	add  %g1, 1, %g2                               
4000e410:	80 a0 60 00 	cmp  %g1, 0                                    
4000e414:	12 80 00 05 	bne  4000e428 <fifo_open+0x294>                <== NEVER TAKEN
4000e418:	c4 27 60 10 	st  %g2, [ %i5 + 0x10 ]                        
        PIPE_WAKEUPWRITERS(pipe);                                     
4000e41c:	d0 07 60 30 	ld  [ %i5 + 0x30 ], %o0                        
4000e420:	40 00 05 ae 	call  4000fad8 <rtems_barrier_release>         
4000e424:	92 07 bf fc 	add  %fp, -4, %o1                              
                                                                      
      if (pipe->Writers == 0) {                                       
4000e428:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000e42c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e430:	32 80 00 5e 	bne,a   4000e5a8 <fifo_open+0x414>             
4000e434:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
        /* Not an error */                                            
        if (LIBIO_NODELAY(iop))                                       
4000e438:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000e43c:	80 88 60 01 	btst  1, %g1                                   
4000e440:	32 80 00 5a 	bne,a   4000e5a8 <fifo_open+0x414>             
4000e444:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
          break;                                                      
                                                                      
        prevCounter = pipe->writerCounter;                            
4000e448:	f8 07 60 24 	ld  [ %i5 + 0x24 ], %i4                        
        err = -EINTR;                                                 
        /* Wait until a writer opens the pipe */                      
        do {                                                          
          PIPE_UNLOCK(pipe);                                          
4000e44c:	7f ff eb 8e 	call  40009284 <rtems_semaphore_release>       
4000e450:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
          if (! PIPE_READWAIT(pipe))                                  
4000e454:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        
4000e458:	40 00 05 b6 	call  4000fb30 <rtems_barrier_wait>            
4000e45c:	92 10 20 00 	clr  %o1                                       
4000e460:	80 a2 20 00 	cmp  %o0, 0                                    
4000e464:	12 80 00 55 	bne  4000e5b8 <fifo_open+0x424>                <== NEVER TAKEN
4000e468:	92 10 20 00 	clr  %o1                                       
            goto out_error;                                           
          if (! PIPE_LOCK(pipe))                                      
4000e46c:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e470:	7f ff eb 3d 	call  40009164 <rtems_semaphore_obtain>        
4000e474:	94 10 20 00 	clr  %o2                                       
4000e478:	80 a2 20 00 	cmp  %o0, 0                                    
4000e47c:	32 80 00 50 	bne,a   4000e5bc <fifo_open+0x428>             <== NEVER TAKEN
4000e480:	b0 10 3f fc 	mov  -4, %i0                                   <== NOT EXECUTED
            goto out_error;                                           
        } while (prevCounter == pipe->writerCounter);                 
4000e484:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
4000e488:	80 a7 00 01 	cmp  %i4, %g1                                  
4000e48c:	02 bf ff f0 	be  4000e44c <fifo_open+0x2b8>                 <== NEVER TAKEN
4000e490:	01 00 00 00 	nop                                            
      if (pipe->Writers ++ == 0)                                      
        PIPE_WAKEUPREADERS(pipe);                                     
      break;                                                          
  }                                                                   
                                                                      
  PIPE_UNLOCK(pipe);                                                  
4000e494:	10 80 00 45 	b  4000e5a8 <fifo_open+0x414>                  
4000e498:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
        } while (prevCounter == pipe->writerCounter);                 
      }                                                               
      break;                                                          
                                                                      
    case LIBIO_FLAGS_WRITE:                                           
      pipe->writerCounter ++;                                         
4000e49c:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
4000e4a0:	82 00 60 01 	inc  %g1                                       
4000e4a4:	c2 27 60 24 	st  %g1, [ %i5 + 0x24 ]                        
                                                                      
      if (pipe->Writers ++ == 0)                                      
4000e4a8:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000e4ac:	84 00 60 01 	add  %g1, 1, %g2                               
4000e4b0:	80 a0 60 00 	cmp  %g1, 0                                    
4000e4b4:	12 80 00 05 	bne  4000e4c8 <fifo_open+0x334>                <== NEVER TAKEN
4000e4b8:	c4 27 60 14 	st  %g2, [ %i5 + 0x14 ]                        
        PIPE_WAKEUPREADERS(pipe);                                     
4000e4bc:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        
4000e4c0:	40 00 05 86 	call  4000fad8 <rtems_barrier_release>         
4000e4c4:	92 07 bf fc 	add  %fp, -4, %o1                              
                                                                      
      if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {                 
4000e4c8:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000e4cc:	80 a0 60 00 	cmp  %g1, 0                                    
4000e4d0:	32 80 00 36 	bne,a   4000e5a8 <fifo_open+0x414>             
4000e4d4:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e4d8:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000e4dc:	80 88 60 01 	btst  1, %g1                                   
4000e4e0:	22 80 00 07 	be,a   4000e4fc <fifo_open+0x368>              
4000e4e4:	f8 07 60 20 	ld  [ %i5 + 0x20 ], %i4                        
	PIPE_UNLOCK(pipe);                                                   
4000e4e8:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e4ec:	7f ff eb 66 	call  40009284 <rtems_semaphore_release>       
4000e4f0:	b0 10 3f fa 	mov  -6, %i0                                   
        err = -ENXIO;                                                 
        goto out_error;                                               
4000e4f4:	10 80 00 33 	b  4000e5c0 <fifo_open+0x42c>                  
4000e4f8:	90 10 00 1b 	mov  %i3, %o0                                  
                                                                      
      if (pipe->Readers == 0) {                                       
        prevCounter = pipe->readerCounter;                            
        err = -EINTR;                                                 
        do {                                                          
          PIPE_UNLOCK(pipe);                                          
4000e4fc:	7f ff eb 62 	call  40009284 <rtems_semaphore_release>       
4000e500:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
          if (! PIPE_WRITEWAIT(pipe))                                 
4000e504:	d0 07 60 30 	ld  [ %i5 + 0x30 ], %o0                        
4000e508:	40 00 05 8a 	call  4000fb30 <rtems_barrier_wait>            
4000e50c:	92 10 20 00 	clr  %o1                                       
4000e510:	80 a2 20 00 	cmp  %o0, 0                                    
4000e514:	12 80 00 29 	bne  4000e5b8 <fifo_open+0x424>                <== NEVER TAKEN
4000e518:	92 10 20 00 	clr  %o1                                       
            goto out_error;                                           
          if (! PIPE_LOCK(pipe))                                      
4000e51c:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e520:	7f ff eb 11 	call  40009164 <rtems_semaphore_obtain>        
4000e524:	94 10 20 00 	clr  %o2                                       
4000e528:	80 a2 20 00 	cmp  %o0, 0                                    
4000e52c:	12 80 00 24 	bne  4000e5bc <fifo_open+0x428>                <== NEVER TAKEN
4000e530:	b0 10 3f fc 	mov  -4, %i0                                   
            goto out_error;                                           
        } while (prevCounter == pipe->readerCounter);                 
4000e534:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
4000e538:	80 a7 00 01 	cmp  %i4, %g1                                  
4000e53c:	02 bf ff f0 	be  4000e4fc <fifo_open+0x368>                 <== NEVER TAKEN
4000e540:	01 00 00 00 	nop                                            
      if (pipe->Writers ++ == 0)                                      
        PIPE_WAKEUPREADERS(pipe);                                     
      break;                                                          
  }                                                                   
                                                                      
  PIPE_UNLOCK(pipe);                                                  
4000e544:	10 80 00 19 	b  4000e5a8 <fifo_open+0x414>                  
4000e548:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
        } while (prevCounter == pipe->readerCounter);                 
      }                                                               
      break;                                                          
                                                                      
    case LIBIO_FLAGS_READ_WRITE:                                      
      pipe->readerCounter ++;                                         
4000e54c:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
4000e550:	82 00 60 01 	inc  %g1                                       
4000e554:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
      if (pipe->Readers ++ == 0)                                      
4000e558:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000e55c:	84 00 60 01 	add  %g1, 1, %g2                               
4000e560:	80 a0 60 00 	cmp  %g1, 0                                    
4000e564:	12 80 00 05 	bne  4000e578 <fifo_open+0x3e4>                <== NEVER TAKEN
4000e568:	c4 27 60 10 	st  %g2, [ %i5 + 0x10 ]                        
        PIPE_WAKEUPWRITERS(pipe);                                     
4000e56c:	d0 07 60 30 	ld  [ %i5 + 0x30 ], %o0                        
4000e570:	40 00 05 5a 	call  4000fad8 <rtems_barrier_release>         
4000e574:	92 07 bf fc 	add  %fp, -4, %o1                              
      pipe->writerCounter ++;                                         
4000e578:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
4000e57c:	82 00 60 01 	inc  %g1                                       
4000e580:	c2 27 60 24 	st  %g1, [ %i5 + 0x24 ]                        
      if (pipe->Writers ++ == 0)                                      
4000e584:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000e588:	84 00 60 01 	add  %g1, 1, %g2                               
4000e58c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e590:	12 80 00 05 	bne  4000e5a4 <fifo_open+0x410>                <== NEVER TAKEN
4000e594:	c4 27 60 14 	st  %g2, [ %i5 + 0x14 ]                        
        PIPE_WAKEUPREADERS(pipe);                                     
4000e598:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        
4000e59c:	40 00 05 4f 	call  4000fad8 <rtems_barrier_release>         
4000e5a0:	92 07 bf fc 	add  %fp, -4, %o1                              
      break;                                                          
  }                                                                   
                                                                      
  PIPE_UNLOCK(pipe);                                                  
4000e5a4:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e5a8:	7f ff eb 37 	call  40009284 <rtems_semaphore_release>       
4000e5ac:	b0 10 20 00 	clr  %i0                                       
  return 0;                                                           
4000e5b0:	81 c7 e0 08 	ret                                            
4000e5b4:	81 e8 00 00 	restore                                        
        /* Not an error */                                            
        if (LIBIO_NODELAY(iop))                                       
          break;                                                      
                                                                      
        prevCounter = pipe->writerCounter;                            
        err = -EINTR;                                                 
4000e5b8:	b0 10 3f fc 	mov  -4, %i0                                   <== NOT EXECUTED
                                                                      
  PIPE_UNLOCK(pipe);                                                  
  return 0;                                                           
                                                                      
out_error:                                                            
  pipe_release(pipep, iop);                                           
4000e5bc:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
4000e5c0:	7f ff fe c8 	call  4000e0e0 <pipe_release>                  
4000e5c4:	92 10 00 19 	mov  %i1, %o1                                  
  return err;                                                         
4000e5c8:	81 c7 e0 08 	ret                                            
4000e5cc:	81 e8 00 00 	restore                                        
    if (err)                                                          
      goto out;                                                       
  }                                                                   
                                                                      
  if (! PIPE_LOCK(pipe))                                              
    err = -EINTR;                                                     
4000e5d0:	10 bf ff 7c 	b  4000e3c0 <fifo_open+0x22c>                  <== NOT EXECUTED
4000e5d4:	b0 10 3f f4 	mov  -12, %i0                                  <== NOT EXECUTED
  return 0;                                                           
                                                                      
out_error:                                                            
  pipe_release(pipep, iop);                                           
  return err;                                                         
}                                                                     
4000e5d8:	81 c7 e0 08 	ret                                            
4000e5dc:	81 e8 00 00 	restore                                        
                                                                      

4000a4cc <fpathconf>: */ long fpathconf( int fd, int name ) {
4000a4cc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  long                                    return_value;               
  rtems_libio_t                          *iop;                        
  const rtems_filesystem_limits_and_options_t *the_limits;            
                                                                      
  rtems_libio_check_fd(fd);                                           
4000a4d0:	03 10 00 4c 	sethi  %hi(0x40013000), %g1                    
4000a4d4:	c2 00 63 64 	ld  [ %g1 + 0x364 ], %g1	! 40013364 <rtems_libio_number_iops>
4000a4d8:	80 a6 00 01 	cmp  %i0, %g1                                  
4000a4dc:	2a 80 00 06 	bcs,a   4000a4f4 <fpathconf+0x28>              
4000a4e0:	83 2e 20 03 	sll  %i0, 3, %g1                               
4000a4e4:	40 00 0a 10 	call  4000cd24 <__errno>                       
4000a4e8:	01 00 00 00 	nop                                            
4000a4ec:	10 80 00 3b 	b  4000a5d8 <fpathconf+0x10c>                  
4000a4f0:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  iop = rtems_libio_iop(fd);                                          
4000a4f4:	b1 2e 20 06 	sll  %i0, 6, %i0                               
4000a4f8:	b0 26 00 01 	sub  %i0, %g1, %i0                             
4000a4fc:	03 10 00 52 	sethi  %hi(0x40014800), %g1                    
4000a500:	c2 00 61 dc 	ld  [ %g1 + 0x1dc ], %g1	! 400149dc <rtems_libio_iops>
4000a504:	b0 00 40 18 	add  %g1, %i0, %i0                             
  rtems_libio_check_is_open(iop);                                     
4000a508:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
4000a50c:	80 88 61 00 	btst  0x100, %g1                               
4000a510:	02 bf ff f5 	be  4000a4e4 <fpathconf+0x18>                  <== NEVER TAKEN
4000a514:	80 a6 60 0b 	cmp  %i1, 0xb                                  
                                                                      
  /*                                                                  
   *  Now process the information request.                            
   */                                                                 
                                                                      
  the_limits = iop->pathinfo.mt_entry->pathconf_limits_and_options;   
4000a518:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
                                                                      
  switch ( name ) {                                                   
4000a51c:	18 80 00 2c 	bgu  4000a5cc <fpathconf+0x100>                
4000a520:	c2 00 60 2c 	ld  [ %g1 + 0x2c ], %g1                        
4000a524:	b3 2e 60 02 	sll  %i1, 2, %i1                               
4000a528:	05 10 00 29 	sethi  %hi(0x4000a400), %g2                    
4000a52c:	84 10 a0 9c 	or  %g2, 0x9c, %g2	! 4000a49c <_close_r+0x10>  
4000a530:	c4 00 80 19 	ld  [ %g2 + %i1 ], %g2                         
4000a534:	81 c0 80 00 	jmp  %g2                                       
4000a538:	01 00 00 00 	nop                                            
    case _PC_LINK_MAX:                                                
      return_value = the_limits->link_max;                            
4000a53c:	f0 00 40 00 	ld  [ %g1 ], %i0                               
      break;                                                          
4000a540:	81 c7 e0 08 	ret                                            
4000a544:	81 e8 00 00 	restore                                        
    case _PC_MAX_CANON:                                               
      return_value = the_limits->max_canon;                           
4000a548:	f0 00 60 04 	ld  [ %g1 + 4 ], %i0                           
      break;                                                          
4000a54c:	81 c7 e0 08 	ret                                            
4000a550:	81 e8 00 00 	restore                                        
    case _PC_MAX_INPUT:                                               
      return_value = the_limits->max_input;                           
4000a554:	f0 00 60 08 	ld  [ %g1 + 8 ], %i0                           
      break;                                                          
4000a558:	81 c7 e0 08 	ret                                            
4000a55c:	81 e8 00 00 	restore                                        
    case _PC_NAME_MAX:                                                
      return_value = the_limits->name_max;                            
4000a560:	f0 00 60 0c 	ld  [ %g1 + 0xc ], %i0                         
      break;                                                          
4000a564:	81 c7 e0 08 	ret                                            
4000a568:	81 e8 00 00 	restore                                        
    case _PC_PATH_MAX:                                                
      return_value = the_limits->path_max;                            
4000a56c:	f0 00 60 10 	ld  [ %g1 + 0x10 ], %i0                        
      break;                                                          
4000a570:	81 c7 e0 08 	ret                                            
4000a574:	81 e8 00 00 	restore                                        
    case _PC_PIPE_BUF:                                                
      return_value = the_limits->pipe_buf;                            
4000a578:	f0 00 60 14 	ld  [ %g1 + 0x14 ], %i0                        
      break;                                                          
4000a57c:	81 c7 e0 08 	ret                                            
4000a580:	81 e8 00 00 	restore                                        
    case _PC_CHOWN_RESTRICTED:                                        
      return_value = the_limits->posix_chown_restrictions;            
4000a584:	f0 00 60 1c 	ld  [ %g1 + 0x1c ], %i0                        
      break;                                                          
4000a588:	81 c7 e0 08 	ret                                            
4000a58c:	81 e8 00 00 	restore                                        
    case _PC_NO_TRUNC:                                                
      return_value = the_limits->posix_no_trunc;                      
4000a590:	f0 00 60 20 	ld  [ %g1 + 0x20 ], %i0                        
      break;                                                          
4000a594:	81 c7 e0 08 	ret                                            
4000a598:	81 e8 00 00 	restore                                        
    case _PC_VDISABLE:                                                
      return_value = the_limits->posix_vdisable;                      
4000a59c:	f0 00 60 2c 	ld  [ %g1 + 0x2c ], %i0                        
      break;                                                          
4000a5a0:	81 c7 e0 08 	ret                                            
4000a5a4:	81 e8 00 00 	restore                                        
    case _PC_ASYNC_IO:                                                
      return_value = the_limits->posix_async_io;                      
4000a5a8:	f0 00 60 18 	ld  [ %g1 + 0x18 ], %i0                        
      break;                                                          
4000a5ac:	81 c7 e0 08 	ret                                            
4000a5b0:	81 e8 00 00 	restore                                        
    case _PC_PRIO_IO:                                                 
      return_value = the_limits->posix_prio_io;                       
4000a5b4:	f0 00 60 24 	ld  [ %g1 + 0x24 ], %i0                        
      break;                                                          
4000a5b8:	81 c7 e0 08 	ret                                            
4000a5bc:	81 e8 00 00 	restore                                        
    case _PC_SYNC_IO:                                                 
      return_value = the_limits->posix_sync_io;                       
4000a5c0:	f0 00 60 28 	ld  [ %g1 + 0x28 ], %i0                        
      break;                                                          
4000a5c4:	81 c7 e0 08 	ret                                            
4000a5c8:	81 e8 00 00 	restore                                        
    default:                                                          
      rtems_set_errno_and_return_minus_one( EINVAL );                 
4000a5cc:	40 00 09 d6 	call  4000cd24 <__errno>                       
4000a5d0:	01 00 00 00 	nop                                            
4000a5d4:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
4000a5d8:	c2 22 00 00 	st  %g1, [ %o0 ]                               
      break;                                                          
  }                                                                   
                                                                      
  return return_value;                                                
}                                                                     
4000a5dc:	81 c7 e0 08 	ret                                            
4000a5e0:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      

4000380c <free>: #include <rtems/score/sysstate.h> void free( void *ptr ) {
4000380c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  MSBUMP(free_calls, 1);                                              
40003810:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40003814:	82 10 63 40 	or  %g1, 0x340, %g1	! 40018340 <rtems_malloc_statistics>
40003818:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
#include <rtems/score/sysstate.h>                                     
                                                                      
void free(                                                            
  void *ptr                                                           
)                                                                     
{                                                                     
4000381c:	b2 10 00 18 	mov  %i0, %i1                                  
  MSBUMP(free_calls, 1);                                              
40003820:	84 00 a0 01 	inc  %g2                                       
                                                                      
  if ( !ptr )                                                         
40003824:	80 a6 20 00 	cmp  %i0, 0                                    
40003828:	02 80 00 21 	be  400038ac <free+0xa0>                       
4000382c:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
#endif                                                                
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE System_state_Codes _System_state_Get ( void )    
{                                                                     
  return _System_state_Current;                                       
40003830:	03 10 00 62 	sethi  %hi(0x40018800), %g1                    
    return;                                                           
                                                                      
  /*                                                                  
   *  Do not attempt to free memory if in a critical section or ISR.  
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
40003834:	c2 00 60 f4 	ld  [ %g1 + 0xf4 ], %g1	! 400188f4 <_System_state_Current>
40003838:	80 a0 60 02 	cmp  %g1, 2                                    
4000383c:	12 80 00 09 	bne  40003860 <free+0x54>                      <== NEVER TAKEN
40003840:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
       !malloc_is_system_state_OK() ) {                               
40003844:	40 00 00 82 	call  40003a4c <malloc_is_system_state_OK>     
40003848:	01 00 00 00 	nop                                            
    return;                                                           
                                                                      
  /*                                                                  
   *  Do not attempt to free memory if in a critical section or ISR.  
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
4000384c:	80 a2 20 00 	cmp  %o0, 0                                    
40003850:	12 80 00 04 	bne  40003860 <free+0x54>                      
40003854:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
       !malloc_is_system_state_OK() ) {                               
      malloc_deferred_free(ptr);                                      
40003858:	40 00 00 8e 	call  40003a90 <malloc_deferred_free>          
4000385c:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  /*                                                                  
   *  If configured, update the statistics                            
   */                                                                 
  if ( rtems_malloc_statistics_helpers )                              
40003860:	c2 00 60 bc 	ld  [ %g1 + 0xbc ], %g1                        
40003864:	80 a0 60 00 	cmp  %g1, 0                                    
40003868:	02 80 00 06 	be  40003880 <free+0x74>                       
4000386c:	3b 10 00 5a 	sethi  %hi(0x40016800), %i5                    
    (*rtems_malloc_statistics_helpers->at_free)(ptr);                 
40003870:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
40003874:	9f c0 40 00 	call  %g1                                      
40003878:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
  if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) {            
4000387c:	3b 10 00 5a 	sethi  %hi(0x40016800), %i5                    
40003880:	d0 07 63 28 	ld  [ %i5 + 0x328 ], %o0	! 40016b28 <RTEMS_Malloc_Heap>
40003884:	40 00 16 b0 	call  40009344 <_Protected_heap_Free>          
40003888:	92 10 00 19 	mov  %i1, %o1                                  
4000388c:	80 a2 20 00 	cmp  %o0, 0                                    
40003890:	12 80 00 07 	bne  400038ac <free+0xa0>                      
40003894:	c2 07 63 28 	ld  [ %i5 + 0x328 ], %g1                       
    printk( "Program heap: free of bad pointer %p -- range %p - %p \n",
40003898:	31 10 00 56 	sethi  %hi(0x40015800), %i0                    
4000389c:	f4 00 60 18 	ld  [ %g1 + 0x18 ], %i2                        
400038a0:	f6 00 60 1c 	ld  [ %g1 + 0x1c ], %i3                        
400038a4:	40 00 02 d0 	call  400043e4 <printk>                        
400038a8:	91 ee 22 20 	restore  %i0, 0x220, %o0                       
400038ac:	81 c7 e0 08 	ret                                            
400038b0:	81 e8 00 00 	restore                                        
                                                                      

40014c8c <fstat>: int fstat( int fd, struct stat *sbuf ) {
40014c8c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_libio_t *iop;                                                 
                                                                      
  /*                                                                  
   *  Check to see if we were passed a valid pointer.                 
   */                                                                 
  if ( !sbuf )                                                        
40014c90:	80 a6 60 00 	cmp  %i1, 0                                    
40014c94:	32 80 00 06 	bne,a   40014cac <fstat+0x20>                  <== ALWAYS TAKEN
40014c98:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
    rtems_set_errno_and_return_minus_one( EFAULT );                   
40014c9c:	7f ff eb 61 	call  4000fa20 <__errno>                       <== NOT EXECUTED
40014ca0:	01 00 00 00 	nop                                            <== NOT EXECUTED
40014ca4:	10 80 00 12 	b  40014cec <fstat+0x60>                       <== NOT EXECUTED
40014ca8:	82 10 20 0e 	mov  0xe, %g1	! e <_TLS_Alignment+0xd>         <== NOT EXECUTED
                                                                      
  /*                                                                  
   *  Now process the stat() request.                                 
   */                                                                 
  iop = rtems_libio_iop( fd );                                        
40014cac:	c2 00 63 30 	ld  [ %g1 + 0x330 ], %g1                       
40014cb0:	80 a6 00 01 	cmp  %i0, %g1                                  
40014cb4:	1a 80 00 0b 	bcc  40014ce0 <fstat+0x54>                     
40014cb8:	83 2e 20 03 	sll  %i0, 3, %g1                               
40014cbc:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40014cc0:	b0 26 00 01 	sub  %i0, %g1, %i0                             
40014cc4:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40014cc8:	c2 00 63 30 	ld  [ %g1 + 0x330 ], %g1	! 40018330 <rtems_libio_iops>
40014ccc:	b0 00 40 18 	add  %g1, %i0, %i0                             
  rtems_libio_check_fd( fd );                                         
  rtems_libio_check_is_open(iop);                                     
40014cd0:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
40014cd4:	80 88 61 00 	btst  0x100, %g1                               
40014cd8:	12 80 00 08 	bne  40014cf8 <fstat+0x6c>                     
40014cdc:	94 10 20 48 	mov  0x48, %o2                                 
                                                                      
  /*                                                                  
   *  Now process the stat() request.                                 
   */                                                                 
  iop = rtems_libio_iop( fd );                                        
  rtems_libio_check_fd( fd );                                         
40014ce0:	7f ff eb 50 	call  4000fa20 <__errno>                       
40014ce4:	01 00 00 00 	nop                                            
40014ce8:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
40014cec:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40014cf0:	81 c7 e0 08 	ret                                            
40014cf4:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  /*                                                                  
   *  Zero out the stat structure so the various support              
   *  versions of stat don't have to.                                 
   */                                                                 
  memset( sbuf, 0, sizeof(struct stat) );                             
40014cf8:	90 10 00 19 	mov  %i1, %o0                                  
40014cfc:	7f ff ed 6e 	call  400102b4 <memset>                        
40014d00:	92 10 20 00 	clr  %o1                                       
                                                                      
  return (*iop->pathinfo.handlers->fstat_h)( &iop->pathinfo, sbuf );  
40014d04:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
40014d08:	90 06 20 14 	add  %i0, 0x14, %o0                            
40014d0c:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
40014d10:	9f c0 40 00 	call  %g1                                      
40014d14:	92 10 00 19 	mov  %i1, %o1                                  
}                                                                     
40014d18:	81 c7 e0 08 	ret                                            
40014d1c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000396c <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) {
4000396c:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003970:	c2 00 62 80 	ld  [ %g1 + 0x280 ], %g1	! 4001c280 <disktab_size>
40003974:	80 a2 00 01 	cmp  %o0, %g1                                  
40003978:	1a 80 00 1f 	bcc  400039f4 <get_disk_entry+0x88>            <== NEVER TAKEN
4000397c:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003980:	c2 00 62 84 	ld  [ %g1 + 0x284 ], %g1	! 4001c284 <disktab>  
40003984:	80 a0 60 00 	cmp  %g1, 0                                    
40003988:	02 80 00 1b 	be  400039f4 <get_disk_entry+0x88>             <== NEVER TAKEN
4000398c:	01 00 00 00 	nop                                            
    rtems_disk_device_table *dtab = disktab + major;                  
40003990:	91 2a 20 03 	sll  %o0, 3, %o0                               
40003994:	84 00 40 08 	add  %g1, %o0, %g2                             
                                                                      
    if (minor < dtab->size && dtab->minor != NULL) {                  
40003998:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
4000399c:	80 a2 40 02 	cmp  %o1, %g2                                  
400039a0:	1a 80 00 15 	bcc  400039f4 <get_disk_entry+0x88>            <== NEVER TAKEN
400039a4:	01 00 00 00 	nop                                            
400039a8:	c2 00 40 08 	ld  [ %g1 + %o0 ], %g1                         
400039ac:	80 a0 60 00 	cmp  %g1, 0                                    
400039b0:	02 80 00 11 	be  400039f4 <get_disk_entry+0x88>             <== NEVER TAKEN
400039b4:	93 2a 60 02 	sll  %o1, 2, %o1                               
      rtems_disk_device *dd = dtab->minor [minor];                    
400039b8:	c2 00 40 09 	ld  [ %g1 + %o1 ], %g1                         
                                                                      
      if (dd != NULL && !lookup_only) {                               
400039bc:	80 a0 60 00 	cmp  %g1, 0                                    
400039c0:	02 80 00 10 	be  40003a00 <get_disk_entry+0x94>             
400039c4:	90 10 00 01 	mov  %g1, %o0                                  
400039c8:	80 a2 a0 01 	cmp  %o2, 1                                    
400039cc:	02 80 00 0d 	be  40003a00 <get_disk_entry+0x94>             
400039d0:	01 00 00 00 	nop                                            
        if (!dd->deleted) {                                           
400039d4:	c4 08 60 40 	ldub  [ %g1 + 0x40 ], %g2                      
400039d8:	80 a0 a0 00 	cmp  %g2, 0                                    
400039dc:	12 80 00 09 	bne  40003a00 <get_disk_entry+0x94>            
400039e0:	90 10 20 00 	clr  %o0                                       
          ++dd->uses;                                                 
400039e4:	c4 00 60 14 	ld  [ %g1 + 0x14 ], %g2                        
400039e8:	84 00 a0 01 	inc  %g2                                       
400039ec:	10 80 00 04 	b  400039fc <get_disk_entry+0x90>              
400039f0:	c4 20 60 14 	st  %g2, [ %g1 + 0x14 ]                        
                                                                      
      return dd;                                                      
    }                                                                 
  }                                                                   
                                                                      
  return NULL;                                                        
400039f4:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400039f8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
                                                                      
  if (major < disktab_size && disktab != NULL) {                      
    rtems_disk_device_table *dtab = disktab + major;                  
                                                                      
    if (minor < dtab->size && dtab->minor != NULL) {                  
      rtems_disk_device *dd = dtab->minor [minor];                    
400039fc:	90 10 00 01 	mov  %g1, %o0                                  
      return dd;                                                      
    }                                                                 
  }                                                                   
                                                                      
  return NULL;                                                        
}                                                                     
40003a00:	81 c3 e0 08 	retl                                           
                                                                      

40005430 <get_sector.part.0>: * NOTES: * get_sector() operates with device via bdbuf library, * and does not support devices with sector size other than 512 bytes */ static rtems_status_code get_sector(int fd,
40005430:	9d e3 bf a0 	save  %sp, -96, %sp                            
    new_off = lseek(fd, off, SEEK_SET);                               
    if (new_off != off) {                                             
        return RTEMS_IO_ERROR;                                        
    }                                                                 
                                                                      
    s = (rtems_sector_data_t *) malloc(sizeof(rtems_sector_data_t) + RTEMS_IDE_SECTOR_SIZE);
40005434:	40 00 05 40 	call  40006934 <malloc>                        
40005438:	90 10 22 04 	mov  0x204, %o0                                
    if (s == NULL)                                                    
    {                                                                 
        return RTEMS_NO_MEMORY;                                       
4000543c:	82 10 20 1a 	mov  0x1a, %g1                                 
    if (new_off != off) {                                             
        return RTEMS_IO_ERROR;                                        
    }                                                                 
                                                                      
    s = (rtems_sector_data_t *) malloc(sizeof(rtems_sector_data_t) + RTEMS_IDE_SECTOR_SIZE);
    if (s == NULL)                                                    
40005440:	80 a2 20 00 	cmp  %o0, 0                                    
40005444:	02 80 00 0f 	be  40005480 <get_sector.part.0+0x50>          <== NEVER TAKEN
40005448:	ba 10 00 08 	mov  %o0, %i5                                  
    {                                                                 
        return RTEMS_NO_MEMORY;                                       
    }                                                                 
                                                                      
    n = read(fd, s->data, RTEMS_IDE_SECTOR_SIZE);                     
4000544c:	90 10 00 18 	mov  %i0, %o0                                  
40005450:	92 07 60 04 	add  %i5, 4, %o1                               
40005454:	40 00 07 7e 	call  4000724c <read>                          
40005458:	94 10 22 00 	mov  0x200, %o2                                
    if (n != RTEMS_IDE_SECTOR_SIZE)                                   
4000545c:	80 a2 22 00 	cmp  %o0, 0x200                                
40005460:	22 80 00 06 	be,a   40005478 <get_sector.part.0+0x48>       <== ALWAYS TAKEN
40005464:	f2 27 40 00 	st  %i1, [ %i5 ]                               
    {                                                                 
        free(s);                                                      
40005468:	40 00 03 bb 	call  40006354 <free>                          <== NOT EXECUTED
4000546c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        return RTEMS_IO_ERROR;                                        
40005470:	10 80 00 04 	b  40005480 <get_sector.part.0+0x50>           <== NOT EXECUTED
40005474:	82 10 20 1b 	mov  0x1b, %g1                                 <== NOT EXECUTED
    }                                                                 
                                                                      
    s->sector_num = sector_num;                                       
                                                                      
    *sector = s;                                                      
40005478:	fa 26 80 00 	st  %i5, [ %i2 ]                               
                                                                      
    return RTEMS_SUCCESSFUL;                                          
4000547c:	82 10 20 00 	clr  %g1                                       
}                                                                     
40005480:	81 c7 e0 08 	ret                                            
40005484:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40031714 <getdents>: int getdents( int dd_fd, char *dd_buf, int dd_len ) {
40031714:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_filesystem_node_types_t type;                                 
                                                                      
  /*                                                                  
   *  Get the file control block structure associated with the file descriptor
   */                                                                 
  iop = rtems_libio_iop( dd_fd );                                     
40031718:	03 10 00 db 	sethi  %hi(0x40036c00), %g1                    
4003171c:	c2 00 61 5c 	ld  [ %g1 + 0x15c ], %g1	! 40036d5c <rtems_libio_number_iops>
40031720:	80 a6 00 01 	cmp  %i0, %g1                                  
40031724:	1a 80 00 08 	bcc  40031744 <getdents+0x30>                  <== NEVER TAKEN
40031728:	ba 10 20 00 	clr  %i5                                       
4003172c:	83 2e 20 03 	sll  %i0, 3, %g1                               
40031730:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40031734:	b0 26 00 01 	sub  %i0, %g1, %i0                             
40031738:	03 10 01 21 	sethi  %hi(0x40048400), %g1                    
4003173c:	fa 00 62 98 	ld  [ %g1 + 0x298 ], %i5	! 40048698 <rtems_libio_iops>
40031740:	ba 07 40 18 	add  %i5, %i0, %i5                             
                                                                      
  /*                                                                  
   *  Make sure we are working on a directory                         
   */                                                                 
  type = rtems_filesystem_node_type( &iop->pathinfo );                
40031744:	7f ff 61 4c 	call  40009c74 <rtems_filesystem_node_type>    
40031748:	90 07 60 14 	add  %i5, 0x14, %o0                            
  if ( type != RTEMS_FILESYSTEM_DIRECTORY )                           
4003174c:	80 a2 20 00 	cmp  %o0, 0                                    
40031750:	22 80 00 08 	be,a   40031770 <getdents+0x5c>                
40031754:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
    rtems_set_errno_and_return_minus_one( ENOTDIR );                  
40031758:	7f ff bd d1 	call  40020e9c <__errno>                       
4003175c:	b0 10 3f ff 	mov  -1, %i0                                   
40031760:	82 10 20 14 	mov  0x14, %g1                                 
40031764:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40031768:	81 c7 e0 08 	ret                                            
4003176c:	81 e8 00 00 	restore                                        
                                                                      
  /*                                                                  
   *  Return the number of bytes that were actually transfered as a result
   *  of the read attempt.                                            
   */                                                                 
  return (*iop->pathinfo.handlers->read_h)( iop, dd_buf, dd_len  );   
40031770:	90 10 00 1d 	mov  %i5, %o0                                  
40031774:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
40031778:	92 10 00 19 	mov  %i1, %o1                                  
4003177c:	9f c0 40 00 	call  %g1                                      
40031780:	94 10 00 1a 	mov  %i2, %o2                                  
}                                                                     
40031784:	81 c7 e0 08 	ret                                            
40031788:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40004064 <init_etc_passwd_group>: /** * Initialize useable but dummy databases */ void init_etc_passwd_group(void) {
40004064:	9d e3 bf a0 	save  %sp, -96, %sp                            
  FILE *fp;                                                           
  static char etc_passwd_initted = 0;                                 
                                                                      
  if (etc_passwd_initted)                                             
40004068:	03 10 00 63 	sethi  %hi(0x40018c00), %g1                    
4000406c:	c4 48 63 9c 	ldsb  [ %g1 + 0x39c ], %g2	! 40018f9c <etc_passwd_initted.7145>
40004070:	80 a0 a0 00 	cmp  %g2, 0                                    
40004074:	12 80 00 2d 	bne  40004128 <init_etc_passwd_group+0xc4>     
40004078:	84 10 20 01 	mov  1, %g2                                    
    return;                                                           
  etc_passwd_initted = 1;                                             
  mkdir("/etc", 0777);                                                
4000407c:	92 10 21 ff 	mov  0x1ff, %o1                                
  FILE *fp;                                                           
  static char etc_passwd_initted = 0;                                 
                                                                      
  if (etc_passwd_initted)                                             
    return;                                                           
  etc_passwd_initted = 1;                                             
40004080:	c4 28 63 9c 	stb  %g2, [ %g1 + 0x39c ]                      
  mkdir("/etc", 0777);                                                
40004084:	11 10 00 5b 	sethi  %hi(0x40016c00), %o0                    
40004088:	40 00 01 63 	call  40004614 <mkdir>                         
4000408c:	90 12 22 f0 	or  %o0, 0x2f0, %o0	! 40016ef0 <IMFS_node_control_enosys+0x98>
                                                                      
  /*                                                                  
   *  Initialize /etc/passwd                                          
   */                                                                 
  if ((fp = fopen("/etc/passwd", "r")) != NULL) {                     
40004090:	3b 10 00 5b 	sethi  %hi(0x40016c00), %i5                    
40004094:	39 10 00 5b 	sethi  %hi(0x40016c00), %i4                    
40004098:	90 17 62 f8 	or  %i5, 0x2f8, %o0                            
4000409c:	40 00 32 c5 	call  40010bb0 <fopen>                         
400040a0:	92 17 23 08 	or  %i4, 0x308, %o1                            
400040a4:	80 a2 20 00 	cmp  %o0, 0                                    
400040a8:	12 80 00 0c 	bne  400040d8 <init_etc_passwd_group+0x74>     
400040ac:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    
    fclose(fp);                                                       
  }                                                                   
  else if ((fp = fopen("/etc/passwd", "w")) != NULL) {                
400040b0:	90 17 62 f8 	or  %i5, 0x2f8, %o0                            
400040b4:	40 00 32 bf 	call  40010bb0 <fopen>                         
400040b8:	92 12 63 10 	or  %o1, 0x310, %o1                            
400040bc:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400040c0:	02 80 00 08 	be  400040e0 <init_etc_passwd_group+0x7c>      <== NEVER TAKEN
400040c4:	11 10 00 5b 	sethi  %hi(0x40016c00), %o0                    
    fprintf(fp, "root:*:0:0:root::/:/bin/sh\n"                        
400040c8:	92 10 00 1d 	mov  %i5, %o1                                  
400040cc:	40 00 32 e4 	call  40010c5c <fputs>                         
400040d0:	90 12 23 18 	or  %o0, 0x318, %o0                            
                 "rtems:*:1:1:RTEMS Application::/:/bin/sh\n"         
                 "tty:!:2:2:tty owner::/:/bin/false\n" );             
    fclose(fp);                                                       
400040d4:	90 10 00 1d 	mov  %i5, %o0                                  
400040d8:	40 00 30 e4 	call  40010468 <fclose>                        
400040dc:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  /*                                                                  
   *  Initialize /etc/group                                           
   */                                                                 
  if ((fp = fopen("/etc/group", "r")) != NULL) {                      
400040e0:	3b 10 00 5b 	sethi  %hi(0x40016c00), %i5                    
400040e4:	92 17 23 08 	or  %i4, 0x308, %o1                            
400040e8:	40 00 32 b2 	call  40010bb0 <fopen>                         
400040ec:	90 17 63 80 	or  %i5, 0x380, %o0                            
400040f0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400040f4:	12 80 00 0b 	bne  40004120 <init_etc_passwd_group+0xbc>     
400040f8:	90 17 63 80 	or  %i5, 0x380, %o0                            
    fclose(fp);                                                       
  }                                                                   
  else if ((fp = fopen("/etc/group", "w")) != NULL) {                 
400040fc:	13 10 00 5b 	sethi  %hi(0x40016c00), %o1                    
40004100:	40 00 32 ac 	call  40010bb0 <fopen>                         
40004104:	92 12 63 10 	or  %o1, 0x310, %o1	! 40016f10 <IMFS_node_control_enosys+0xb8>
40004108:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000410c:	02 80 00 07 	be  40004128 <init_etc_passwd_group+0xc4>      <== NEVER TAKEN
40004110:	11 10 00 5b 	sethi  %hi(0x40016c00), %o0                    
    fprintf( fp, "root:x:0:root\n"                                    
40004114:	92 10 00 18 	mov  %i0, %o1                                  
40004118:	40 00 32 d1 	call  40010c5c <fputs>                         
4000411c:	90 12 23 90 	or  %o0, 0x390, %o0                            
                 "rtems:x:1:rtems\n"                                  
                 "tty:x:2:tty\n" );                                   
    fclose(fp);                                                       
40004120:	40 00 30 d2 	call  40010468 <fclose>                        
40004124:	81 e8 00 00 	restore                                        
40004128:	81 c7 e0 08 	ret                                            
4000412c:	81 e8 00 00 	restore                                        
                                                                      

40005f78 <iproc>: /* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) {
40005f78:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (tty->termios.c_iflag & ISTRIP)                                  
40005f7c:	c4 06 60 30 	ld  [ %i1 + 0x30 ], %g2                        
40005f80:	80 88 a0 20 	btst  0x20, %g2                                
40005f84:	32 80 00 02 	bne,a   40005f8c <iproc+0x14>                  <== NEVER TAKEN
40005f88:	b0 0e 20 7f 	and  %i0, 0x7f, %i0                            <== NOT EXECUTED
    c &= 0x7f;                                                        
                                                                      
  if (tty->termios.c_iflag & IUCLC)                                   
40005f8c:	80 88 a2 00 	btst  0x200, %g2                               
40005f90:	02 80 00 0c 	be  40005fc0 <iproc+0x48>                      
40005f94:	80 a6 20 0d 	cmp  %i0, 0xd                                  
    c = tolower (c);                                                  
40005f98:	03 10 00 5b 	sethi  %hi(0x40016c00), %g1                    
40005f9c:	c2 00 61 0c 	ld  [ %g1 + 0x10c ], %g1	! 40016d0c <__ctype_ptr__>
40005fa0:	82 00 40 18 	add  %g1, %i0, %g1                             
40005fa4:	c2 08 60 01 	ldub  [ %g1 + 1 ], %g1                         
40005fa8:	82 08 60 03 	and  %g1, 3, %g1                               
40005fac:	80 a0 60 01 	cmp  %g1, 1                                    
40005fb0:	22 80 00 02 	be,a   40005fb8 <iproc+0x40>                   
40005fb4:	b0 06 20 20 	add  %i0, 0x20, %i0                            
40005fb8:	b0 0e 20 ff 	and  %i0, 0xff, %i0                            
                                                                      
  if (c == '\r') {                                                    
40005fbc:	80 a6 20 0d 	cmp  %i0, 0xd                                  
40005fc0:	12 80 00 0a 	bne  40005fe8 <iproc+0x70>                     
40005fc4:	80 a6 20 0a 	cmp  %i0, 0xa                                  
    if (tty->termios.c_iflag & IGNCR)                                 
40005fc8:	80 88 a0 80 	btst  0x80, %g2                                
40005fcc:	12 80 00 5c 	bne  4000613c <iproc+0x1c4>                    <== NEVER TAKEN
40005fd0:	82 10 20 00 	clr  %g1                                       
      return 0;                                                       
    if (tty->termios.c_iflag & ICRNL)                                 
40005fd4:	80 88 a1 00 	btst  0x100, %g2                               
40005fd8:	32 80 00 0d 	bne,a   4000600c <iproc+0x94>                  <== ALWAYS TAKEN
40005fdc:	b0 10 20 0a 	mov  0xa, %i0                                  
      c = '\n';                                                       
  } else if ((c == '\n') && (tty->termios.c_iflag & INLCR)) {         
    c = '\r';                                                         
  }                                                                   
                                                                      
  if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {               
40005fe0:	10 80 00 0c 	b  40006010 <iproc+0x98>                       <== NOT EXECUTED
40005fe4:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        <== NOT EXECUTED
  if (c == '\r') {                                                    
    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)) {         
40005fe8:	12 80 00 07 	bne  40006004 <iproc+0x8c>                     
40005fec:	80 a6 20 00 	cmp  %i0, 0                                    
40005ff0:	80 88 a0 40 	btst  0x40, %g2                                
40005ff4:	32 80 00 06 	bne,a   4000600c <iproc+0x94>                  <== NEVER TAKEN
40005ff8:	b0 10 20 0d 	mov  0xd, %i0                                  <== NOT EXECUTED
    c = '\r';                                                         
  }                                                                   
                                                                      
  if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {               
40005ffc:	10 80 00 05 	b  40006010 <iproc+0x98>                       
40006000:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
40006004:	02 80 00 3a 	be  400060ec <iproc+0x174>                     <== NEVER TAKEN
40006008:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
4000600c:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
40006010:	80 88 60 02 	btst  2, %g1                                   
40006014:	22 80 00 36 	be,a   400060ec <iproc+0x174>                  
40006018:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
    if (c == tty->termios.c_cc[VERASE]) {                             
4000601c:	c4 0e 60 43 	ldub  [ %i1 + 0x43 ], %g2                      
      erase (tty, 0);                                                 
40006020:	90 10 00 19 	mov  %i1, %o0                                  
  } 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]) {                             
40006024:	80 a0 80 18 	cmp  %g2, %i0                                  
40006028:	02 80 00 08 	be  40006048 <iproc+0xd0>                      
4000602c:	92 10 20 00 	clr  %o1                                       
      erase (tty, 0);                                                 
      return 0;                                                       
    }                                                                 
    else if (c == tty->termios.c_cc[VKILL]) {                         
40006030:	c4 0e 60 44 	ldub  [ %i1 + 0x44 ], %g2                      
40006034:	80 a0 80 18 	cmp  %g2, %i0                                  
40006038:	32 80 00 08 	bne,a   40006058 <iproc+0xe0>                  
4000603c:	c4 0e 60 45 	ldub  [ %i1 + 0x45 ], %g2                      
      erase (tty, 1);                                                 
40006040:	90 10 00 19 	mov  %i1, %o0                                  
40006044:	92 10 20 01 	mov  1, %o1                                    
40006048:	7f ff ff 45 	call  40005d5c <erase>                         
4000604c:	01 00 00 00 	nop                                            
      return 0;                                                       
40006050:	10 80 00 3b 	b  4000613c <iproc+0x1c4>                      
40006054:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
    }                                                                 
    else if (c == tty->termios.c_cc[VEOF]) {                          
40006058:	80 a0 80 18 	cmp  %g2, %i0                                  
4000605c:	02 80 00 37 	be  40006138 <iproc+0x1c0>                     <== NEVER TAKEN
40006060:	80 a6 20 0a 	cmp  %i0, 0xa                                  
      return 1;                                                       
    } else if (c == '\n') {                                           
40006064:	32 80 00 0f 	bne,a   400060a0 <iproc+0x128>                 
40006068:	c4 0e 60 4c 	ldub  [ %i1 + 0x4c ], %g2                      
      if (tty->termios.c_lflag & (ECHO | ECHONL))                     
4000606c:	80 88 60 48 	btst  0x48, %g1                                
40006070:	22 80 00 06 	be,a   40006088 <iproc+0x110>                  <== NEVER TAKEN
40006074:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        <== NOT EXECUTED
        echo (c, tty);                                                
40006078:	90 10 20 0a 	mov  0xa, %o0                                  
4000607c:	7f ff ff 17 	call  40005cd8 <echo>                          
40006080:	92 10 00 19 	mov  %i1, %o1                                  
      tty->cbuf[tty->ccount++] = c;                                   
40006084:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40006088:	c4 06 60 1c 	ld  [ %i1 + 0x1c ], %g2                        
4000608c:	86 00 60 01 	add  %g1, 1, %g3                               
40006090:	c6 26 60 20 	st  %g3, [ %i1 + 0x20 ]                        
40006094:	86 10 20 0a 	mov  0xa, %g3                                  
40006098:	10 80 00 28 	b  40006138 <iproc+0x1c0>                      
4000609c:	c6 28 80 01 	stb  %g3, [ %g2 + %g1 ]                        
      return 1;                                                       
    } else if ((c == tty->termios.c_cc[VEOL]) ||                      
400060a0:	80 a0 80 18 	cmp  %g2, %i0                                  
400060a4:	02 80 00 07 	be  400060c0 <iproc+0x148>                     <== NEVER TAKEN
400060a8:	80 88 60 08 	btst  8, %g1                                   
400060ac:	c4 0e 60 51 	ldub  [ %i1 + 0x51 ], %g2                      
400060b0:	80 a0 80 18 	cmp  %g2, %i0                                  
400060b4:	32 80 00 0e 	bne,a   400060ec <iproc+0x174>                 <== ALWAYS TAKEN
400060b8:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
               (c == tty->termios.c_cc[VEOL2])) {                     
      if (tty->termios.c_lflag & ECHO)                                
400060bc:	80 88 60 08 	btst  8, %g1                                   <== NOT EXECUTED
400060c0:	22 80 00 06 	be,a   400060d8 <iproc+0x160>                  <== NOT EXECUTED
400060c4:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        <== NOT EXECUTED
        echo (c, tty);                                                
400060c8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
400060cc:	7f ff ff 03 	call  40005cd8 <echo>                          <== NOT EXECUTED
400060d0:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
      tty->cbuf[tty->ccount++] = c;                                   
400060d4:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        <== NOT EXECUTED
400060d8:	c4 06 60 1c 	ld  [ %i1 + 0x1c ], %g2                        <== NOT EXECUTED
400060dc:	86 00 60 01 	add  %g1, 1, %g3                               <== NOT EXECUTED
400060e0:	c6 26 60 20 	st  %g3, [ %i1 + 0x20 ]                        <== NOT EXECUTED
400060e4:	10 80 00 15 	b  40006138 <iproc+0x1c0>                      <== NOT EXECUTED
400060e8:	f0 28 80 01 	stb  %i0, [ %g2 + %g1 ]                        <== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * FIXME: Should do IMAXBEL handling somehow                        
   */                                                                 
  if (tty->ccount < (CBUFSIZE-1)) {                                   
400060ec:	c6 06 60 20 	ld  [ %i1 + 0x20 ], %g3                        
400060f0:	c4 00 63 64 	ld  [ %g1 + 0x364 ], %g2                       
400060f4:	84 00 bf ff 	add  %g2, -1, %g2                              
400060f8:	80 a0 c0 02 	cmp  %g3, %g2                                  
400060fc:	1a 80 00 10 	bcc  4000613c <iproc+0x1c4>                    <== NEVER TAKEN
40006100:	82 10 20 00 	clr  %g1                                       
    if (tty->termios.c_lflag & ECHO)                                  
40006104:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
40006108:	80 88 60 08 	btst  8, %g1                                   
4000610c:	22 80 00 06 	be,a   40006124 <iproc+0x1ac>                  <== NEVER TAKEN
40006110:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        <== NOT EXECUTED
      echo (c, tty);                                                  
40006114:	90 10 00 18 	mov  %i0, %o0                                  
40006118:	7f ff fe f0 	call  40005cd8 <echo>                          
4000611c:	92 10 00 19 	mov  %i1, %o1                                  
    tty->cbuf[tty->ccount++] = c;                                     
40006120:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40006124:	c4 06 60 1c 	ld  [ %i1 + 0x1c ], %g2                        
40006128:	86 00 60 01 	add  %g1, 1, %g3                               
4000612c:	c6 26 60 20 	st  %g3, [ %i1 + 0x20 ]                        
40006130:	10 bf ff c8 	b  40006050 <iproc+0xd8>                       
40006134:	f0 28 80 01 	stb  %i0, [ %g2 + %g1 ]                        
    else if (c == tty->termios.c_cc[VKILL]) {                         
      erase (tty, 1);                                                 
      return 0;                                                       
    }                                                                 
    else if (c == tty->termios.c_cc[VEOF]) {                          
      return 1;                                                       
40006138:	82 10 20 01 	mov  1, %g1                                    
    if (tty->termios.c_lflag & ECHO)                                  
      echo (c, tty);                                                  
    tty->cbuf[tty->ccount++] = c;                                     
  }                                                                   
  return 0;                                                           
}                                                                     
4000613c:	81 c7 e0 08 	ret                                            
40006140:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40029570 <killinfo>: int killinfo( pid_t pid, int sig, const union sigval *value ) {
40029570:	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() )                                              
40029574:	7f ff ff 2c 	call  40029224 <getpid>                        
40029578:	01 00 00 00 	nop                                            
4002957c:	80 a6 00 08 	cmp  %i0, %o0                                  
40029580:	02 80 00 06 	be  40029598 <killinfo+0x28>                   
40029584:	80 a6 60 00 	cmp  %i1, 0                                    
    rtems_set_errno_and_return_minus_one( ESRCH );                    
40029588:	7f ff b9 41 	call  40017a8c <__errno>                       
4002958c:	01 00 00 00 	nop                                            
40029590:	10 80 00 07 	b  400295ac <killinfo+0x3c>                    
40029594:	82 10 20 03 	mov  3, %g1	! 3 <_TLS_Alignment+0x2>           
                                                                      
  /*                                                                  
   *  Validate the signal passed.                                     
   */                                                                 
  if ( !sig )                                                         
40029598:	12 80 00 08 	bne  400295b8 <killinfo+0x48>                  
4002959c:	ba 06 7f ff 	add  %i1, -1, %i5                              
    rtems_set_errno_and_return_minus_one( EINVAL );                   
400295a0:	7f ff b9 3b 	call  40017a8c <__errno>                       
400295a4:	01 00 00 00 	nop                                            
400295a8:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
400295ac:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400295b0:	81 c7 e0 08 	ret                                            
400295b4:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  if ( !is_valid_signo(sig) )                                         
400295b8:	80 a7 60 1f 	cmp  %i5, 0x1f                                 
400295bc:	18 bf ff f9 	bgu  400295a0 <killinfo+0x30>                  
400295c0:	23 10 00 c3 	sethi  %hi(0x40030c00), %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 )          
400295c4:	b1 2e 60 02 	sll  %i1, 2, %i0                               
400295c8:	a2 14 60 cc 	or  %l1, 0xcc, %l1                             
400295cc:	a1 2e 60 04 	sll  %i1, 4, %l0                               
400295d0:	82 24 00 18 	sub  %l0, %i0, %g1                             
400295d4:	82 04 40 01 	add  %l1, %g1, %g1                             
400295d8:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
400295dc:	80 a0 60 01 	cmp  %g1, 1                                    
400295e0:	02 80 00 92 	be  40029828 <killinfo+0x2b8>                  
400295e4:	80 a6 60 08 	cmp  %i1, 8                                    
  /*                                                                  
   *  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 ) )      
400295e8:	02 80 00 06 	be  40029600 <killinfo+0x90>                   
400295ec:	80 a6 60 04 	cmp  %i1, 4                                    
400295f0:	02 80 00 04 	be  40029600 <killinfo+0x90>                   
400295f4:	80 a6 60 0b 	cmp  %i1, 0xb                                  
400295f8:	12 80 00 08 	bne  40029618 <killinfo+0xa8>                  
400295fc:	82 10 20 01 	mov  1, %g1                                    
      return pthread_kill( pthread_self(), sig );                     
40029600:	40 00 01 1f 	call  40029a7c <pthread_self>                  
40029604:	01 00 00 00 	nop                                            
40029608:	40 00 00 f0 	call  400299c8 <pthread_kill>                  
4002960c:	92 10 00 19 	mov  %i1, %o1                                  
40029610:	81 c7 e0 08 	ret                                            
40029614:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      
  /*                                                                  
   *  Build up a siginfo structure                                    
   */                                                                 
  siginfo = &siginfo_struct;                                          
  siginfo->si_signo = sig;                                            
40029618:	f2 27 bf f4 	st  %i1, [ %fp + -12 ]                         
  siginfo->si_code = SI_USER;                                         
4002961c:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  if ( !value ) {                                                     
40029620:	80 a6 a0 00 	cmp  %i2, 0                                    
40029624:	12 80 00 04 	bne  40029634 <killinfo+0xc4>                  
40029628:	bb 28 40 1d 	sll  %g1, %i5, %i5                             
4002962c:	10 80 00 04 	b  4002963c <killinfo+0xcc>                    
40029630:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    siginfo->si_value.sival_int = 0;                                  
  } else {                                                            
    siginfo->si_value = *value;                                       
40029634:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40029638:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
4002963c:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40029640:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40029644:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
                                                                      
  /*                                                                  
   *  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;                                     
40029648:	d0 01 a0 18 	ld  [ %g6 + 0x18 ], %o0                        
                                                                      
  api = the_thread->API_Extensions[ THREAD_API_POSIX ];               
  if ( _POSIX_signals_Is_interested( api, mask ) ) {                  
4002964c:	c4 02 21 30 	ld  [ %o0 + 0x130 ], %g2                       
40029650:	c4 00 a0 dc 	ld  [ %g2 + 0xdc ], %g2                        
40029654:	80 af 40 02 	andncc  %i5, %g2, %g0                          
40029658:	12 80 00 50 	bne  40029798 <killinfo+0x228>                 
4002965c:	03 10 00 c3 	sethi  %hi(0x40030c00), %g1                    
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
40029660:	d0 00 62 58 	ld  [ %g1 + 0x258 ], %o0	! 40030e58 <_POSIX_signals_Wait_queue>
                                                                      
  /* XXX violation of visibility -- need to define thread queue support */
                                                                      
  the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo;                 
                                                                      
  for ( the_node = _Chain_First( the_chain );                         
40029664:	05 10 00 c3 	sethi  %hi(0x40030c00), %g2                    
40029668:	84 10 a2 5c 	or  %g2, 0x25c, %g2	! 40030e5c <_POSIX_signals_Wait_queue+0x4>
4002966c:	80 a2 00 02 	cmp  %o0, %g2                                  
40029670:	02 80 00 0c 	be  400296a0 <killinfo+0x130>                  
40029674:	03 10 00 b8 	sethi  %hi(0x4002e000), %g1                    
    #endif                                                            
                                                                      
    /*                                                                
     * Is this thread is actually blocked waiting for the signal?     
     */                                                               
    if (the_thread->Wait.option & mask)                               
40029678:	c8 02 20 30 	ld  [ %o0 + 0x30 ], %g4                        
4002967c:	80 8f 40 04 	btst  %i5, %g4                                 
40029680:	12 80 00 46 	bne  40029798 <killinfo+0x228>                 
40029684:	c6 02 21 30 	ld  [ %o0 + 0x130 ], %g3                       
                                                                      
    /*                                                                
     * Is this thread is blocked waiting for another signal but has   
     * not blocked this one?                                          
     */                                                               
    if (~api->signals_blocked & mask)                                 
40029688:	c6 00 e0 dc 	ld  [ %g3 + 0xdc ], %g3                        
4002968c:	80 af 40 03 	andncc  %i5, %g3, %g0                          
40029690:	12 80 00 43 	bne  4002979c <killinfo+0x22c>                 
40029694:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo;                 
                                                                      
  for ( the_node = _Chain_First( the_chain );                         
        !_Chain_Is_tail( the_chain, the_node ) ;                      
        the_node = the_node->next ) {                                 
40029698:	10 bf ff f5 	b  4002966c <killinfo+0xfc>                    
4002969c:	d0 02 00 00 	ld  [ %o0 ], %o0                               
   *  NOTES:                                                          
   *                                                                  
   *    + rtems internal threads do not receive signals.              
   */                                                                 
  interested = NULL;                                                  
  interested_priority = PRIORITY_MAXIMUM + 1;                         
400296a0:	c6 08 60 f8 	ldub  [ %g1 + 0xf8 ], %g3                      
   *                                                                  
   *  NOTES:                                                          
   *                                                                  
   *    + rtems internal threads do not receive signals.              
   */                                                                 
  interested = NULL;                                                  
400296a4:	90 10 20 00 	clr  %o0                                       
  interested_priority = PRIORITY_MAXIMUM + 1;                         
400296a8:	86 00 e0 01 	inc  %g3                                       
                                                                      
  for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) {
400296ac:	b8 10 20 02 	mov  2, %i4                                    
                                                                      
    /*                                                                
     *  This can occur when no one is interested and an API is not configured.
     */                                                               
    if ( !_Objects_Information_table[ the_api ] )                     
400296b0:	19 10 00 c0 	sethi  %hi(0x40030000), %o4                    
 */                                                                   
RTEMS_INLINE_ROUTINE bool _States_Is_interruptible_by_signal (        
  States_Control the_states                                           
)                                                                     
{                                                                     
   return (the_states & STATES_INTERRUPTIBLE_BY_SIGNAL);              
400296b4:	35 04 00 00 	sethi  %hi(0x10000000), %i2                    
400296b8:	85 2f 20 02 	sll  %i4, 2, %g2                               
400296bc:	88 13 23 60 	or  %o4, 0x360, %g4                            
400296c0:	c4 01 00 02 	ld  [ %g4 + %g2 ], %g2                         
400296c4:	80 a0 a0 00 	cmp  %g2, 0                                    
400296c8:	02 80 00 2d 	be  4002977c <killinfo+0x20c>                  <== NEVER TAKEN
400296cc:	b6 10 20 01 	mov  1, %i3                                    
      continue;                                                       
                                                                      
    the_info = _Objects_Information_table[ the_api ][ 1 ];            
400296d0:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
       */                                                             
      if ( !the_info )                                                
        continue;                                                     
    #endif                                                            
                                                                      
    maximum = the_info->maximum;                                      
400296d4:	d6 10 a0 10 	lduh  [ %g2 + 0x10 ], %o3                      
    object_table = the_info->local_table;                             
400296d8:	d4 00 a0 1c 	ld  [ %g2 + 0x1c ], %o2                        
                                                                      
    for ( index = 1 ; index <= maximum ; index++ ) {                  
400296dc:	80 a6 c0 0b 	cmp  %i3, %o3                                  
400296e0:	18 80 00 27 	bgu  4002977c <killinfo+0x20c>                 
400296e4:	85 2e e0 02 	sll  %i3, 2, %g2                               
      the_thread = (Thread_Control *) object_table[ index ];          
400296e8:	c4 02 80 02 	ld  [ %o2 + %g2 ], %g2                         
                                                                      
      if ( !the_thread )                                              
400296ec:	80 a0 a0 00 	cmp  %g2, 0                                    
400296f0:	22 bf ff fb 	be,a   400296dc <killinfo+0x16c>               
400296f4:	b6 06 e0 01 	inc  %i3                                       
                                                                      
      /*                                                              
       *  If this thread is of lower priority than the interested thread,
       *  go on to the next thread.                                   
       */                                                             
      if ( the_thread->current_priority > interested_priority )       
400296f8:	c8 00 a0 14 	ld  [ %g2 + 0x14 ], %g4                        
400296fc:	80 a1 00 03 	cmp  %g4, %g3                                  
40029700:	38 bf ff f7 	bgu,a   400296dc <killinfo+0x16c>              
40029704:	b6 06 e0 01 	inc  %i3                                       
      #if defined(RTEMS_DEBUG)                                        
        if ( !api )                                                   
          continue;                                                   
      #endif                                                          
                                                                      
      if ( !_POSIX_signals_Is_interested( api, mask ) )               
40029708:	de 00 a1 30 	ld  [ %g2 + 0x130 ], %o7                       
4002970c:	de 03 e0 dc 	ld  [ %o7 + 0xdc ], %o7                        
40029710:	80 af 40 0f 	andncc  %i5, %o7, %g0                          
40029714:	22 bf ff f2 	be,a   400296dc <killinfo+0x16c>               
40029718:	b6 06 e0 01 	inc  %i3                                       
       *                                                              
       *  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 ) {     
4002971c:	80 a1 00 03 	cmp  %g4, %g3                                  
40029720:	2a 80 00 14 	bcs,a   40029770 <killinfo+0x200>              
40029724:	86 10 00 04 	mov  %g4, %g3                                  
       *  and blocking interruptibutable by signal.                   
       *                                                              
       *  If the interested thread is ready, don't think about changing.
       */                                                             
                                                                      
      if ( interested && !_States_Is_ready( interested->current_state ) ) {
40029728:	80 a2 20 00 	cmp  %o0, 0                                    
4002972c:	22 bf ff ec 	be,a   400296dc <killinfo+0x16c>               <== NEVER TAKEN
40029730:	b6 06 e0 01 	inc  %i3                                       <== NOT EXECUTED
40029734:	da 02 20 10 	ld  [ %o0 + 0x10 ], %o5                        
40029738:	80 a3 60 00 	cmp  %o5, 0                                    
4002973c:	22 bf ff e8 	be,a   400296dc <killinfo+0x16c>               <== NEVER TAKEN
40029740:	b6 06 e0 01 	inc  %i3                                       <== NOT EXECUTED
        /* preferred ready over blocked */                            
        DEBUG_STEP("5");                                              
        if ( _States_Is_ready( the_thread->current_state ) ) {        
40029744:	de 00 a0 10 	ld  [ %g2 + 0x10 ], %o7                        
40029748:	80 a3 e0 00 	cmp  %o7, 0                                    
4002974c:	22 80 00 09 	be,a   40029770 <killinfo+0x200>               
40029750:	86 10 00 04 	mov  %g4, %g3                                  
          continue;                                                   
        }                                                             
                                                                      
        DEBUG_STEP("6");                                              
        /* prefer blocked/interruptible over blocked/not interruptible */
        if ( !_States_Is_interruptible_by_signal(interested->current_state) ) {
40029754:	80 8b 40 1a 	btst  %o5, %i2                                 
40029758:	32 bf ff e1 	bne,a   400296dc <killinfo+0x16c>              
4002975c:	b6 06 e0 01 	inc  %i3                                       
          DEBUG_STEP("7");                                            
          if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) {
40029760:	80 8b c0 1a 	btst  %o7, %i2                                 
40029764:	22 bf ff de 	be,a   400296dc <killinfo+0x16c>               
40029768:	b6 06 e0 01 	inc  %i3                                       
4002976c:	86 10 00 04 	mov  %g4, %g3                                  
40029770:	90 10 00 02 	mov  %g2, %o0                                  
    #endif                                                            
                                                                      
    maximum = the_info->maximum;                                      
    object_table = the_info->local_table;                             
                                                                      
    for ( index = 1 ; index <= maximum ; index++ ) {                  
40029774:	10 bf ff da 	b  400296dc <killinfo+0x16c>                   
40029778:	b6 06 e0 01 	inc  %i3                                       
   *    + 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++) {
4002977c:	b8 07 20 01 	inc  %i4                                       
40029780:	80 a7 20 04 	cmp  %i4, 4                                    
40029784:	12 bf ff ce 	bne  400296bc <killinfo+0x14c>                 
40029788:	85 2f 20 02 	sll  %i4, 2, %g2                               
        }                                                             
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  if ( interested ) {                                                 
4002978c:	80 a2 20 00 	cmp  %o0, 0                                    
40029790:	02 80 00 0b 	be  400297bc <killinfo+0x24c>                  
40029794:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   *  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 ) ) {  
40029798:	92 10 00 19 	mov  %i1, %o1                                  
4002979c:	40 00 00 30 	call  4002985c <_POSIX_signals_Unblock_thread> 
400297a0:	94 07 bf f4 	add  %fp, -12, %o2                             
400297a4:	80 a2 20 00 	cmp  %o0, 0                                    
400297a8:	02 80 00 05 	be  400297bc <killinfo+0x24c>                  
400297ac:	01 00 00 00 	nop                                            
    _Thread_Enable_dispatch();                                        
400297b0:	7f ff 92 83 	call  4000e1bc <_Thread_Enable_dispatch>       
400297b4:	b0 10 20 00 	clr  %i0	! 0 <_TLS_BSS_size>                   
400297b8:	30 80 00 1d 	b,a   4002982c <killinfo+0x2bc>                
                                                                      
  /*                                                                  
   *  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 );                         
400297bc:	40 00 00 1e 	call  40029834 <_POSIX_signals_Set_process_signals>
400297c0:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) {       
400297c4:	b8 24 00 18 	sub  %l0, %i0, %i4                             
400297c8:	c2 04 40 1c 	ld  [ %l1 + %i4 ], %g1                         
400297cc:	80 a0 60 02 	cmp  %g1, 2                                    
400297d0:	12 bf ff f8 	bne  400297b0 <killinfo+0x240>                 
400297d4:	11 10 00 c3 	sethi  %hi(0x40030c00), %o0                    
                                                                      
    psiginfo = (POSIX_signals_Siginfo_node *)                         
400297d8:	7f ff 8a df 	call  4000c354 <_Chain_Get>                    
400297dc:	90 12 22 4c 	or  %o0, 0x24c, %o0	! 40030e4c <_POSIX_signals_Inactive_siginfo>
               _Chain_Get( &_POSIX_signals_Inactive_siginfo );        
    if ( !psiginfo ) {                                                
400297e0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400297e4:	12 80 00 08 	bne  40029804 <killinfo+0x294>                 
400297e8:	92 07 bf f4 	add  %fp, -12, %o1                             
      _Thread_Enable_dispatch();                                      
400297ec:	7f ff 92 74 	call  4000e1bc <_Thread_Enable_dispatch>       
400297f0:	01 00 00 00 	nop                                            
      rtems_set_errno_and_return_minus_one( EAGAIN );                 
400297f4:	7f ff b8 a6 	call  40017a8c <__errno>                       
400297f8:	01 00 00 00 	nop                                            
400297fc:	10 bf ff 6c 	b  400295ac <killinfo+0x3c>                    
40029800:	82 10 20 0b 	mov  0xb, %g1	! b <_TLS_Alignment+0xa>         
    }                                                                 
                                                                      
    psiginfo->Info = *siginfo;                                        
40029804:	90 07 60 08 	add  %i5, 8, %o0                               
40029808:	7f ff bf 77 	call  400195e4 <memcpy>                        
4002980c:	94 10 20 0c 	mov  0xc, %o2                                  
                                                                      
    _Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node ); 
40029810:	11 10 00 c3 	sethi  %hi(0x40030c00), %o0                    
40029814:	92 10 00 1d 	mov  %i5, %o1                                  
40029818:	90 12 22 9c 	or  %o0, 0x29c, %o0                            
4002981c:	7f ff 8a c2 	call  4000c324 <_Chain_Append>                 
40029820:	90 02 00 1c 	add  %o0, %i4, %o0                             
40029824:	30 bf ff e3 	b,a   400297b0 <killinfo+0x240>                
                                                                      
  /*                                                                  
   *  If the signal is being ignored, then we are out of here.        
   */                                                                 
  if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN )          
    return 0;                                                         
40029828:	b0 10 20 00 	clr  %i0                                       
  }                                                                   
                                                                      
  DEBUG_STEP("\n");                                                   
  _Thread_Enable_dispatch();                                          
  return 0;                                                           
}                                                                     
4002982c:	81 c7 e0 08 	ret                                            
40029830:	81 e8 00 00 	restore                                        
                                                                      

40003b60 <malloc>: #include <rtems/score/sysstate.h> void *malloc( size_t size ) {
40003b60:	9d e3 bf a0 	save  %sp, -96, %sp                            
  void        *return_this;                                           
                                                                      
  MSBUMP(malloc_calls, 1);                                            
40003b64:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40003b68:	82 10 63 40 	or  %g1, 0x340, %g1	! 40018340 <rtems_malloc_statistics>
40003b6c:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
40003b70:	84 00 a0 01 	inc  %g2                                       
                                                                      
  /*                                                                  
   *  If some free's have been deferred, then do them now.            
   */                                                                 
  malloc_deferred_frees_process();                                    
40003b74:	7f ff ff ba 	call  40003a5c <malloc_deferred_frees_process> 
40003b78:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
                                                                      
  /*                                                                  
   * Validate the parameters                                          
   */                                                                 
  if ( !size )                                                        
40003b7c:	80 a6 20 00 	cmp  %i0, 0                                    
40003b80:	02 80 00 22 	be  40003c08 <malloc+0xa8>                     
40003b84:	03 10 00 62 	sethi  %hi(0x40018800), %g1                    
    return (void *) 0;                                                
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if not in correct system state.
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
40003b88:	c2 00 60 f4 	ld  [ %g1 + 0xf4 ], %g1	! 400188f4 <_System_state_Current>
40003b8c:	80 a0 60 02 	cmp  %g1, 2                                    
40003b90:	02 80 00 0c 	be  40003bc0 <malloc+0x60>                     
40003b94:	39 10 00 5a 	sethi  %hi(0x40016800), %i4                    
RTEMS_INLINE_ROUTINE void *_Protected_heap_Allocate(                  
  Heap_Control *heap,                                                 
  uintptr_t size                                                      
)                                                                     
{                                                                     
  return _Protected_heap_Allocate_aligned_with_boundary( heap, size, 0, 0 );
40003b98:	d0 07 23 28 	ld  [ %i4 + 0x328 ], %o0	! 40016b28 <RTEMS_Malloc_Heap>
40003b9c:	92 10 00 18 	mov  %i0, %o1                                  
40003ba0:	94 10 20 00 	clr  %o2                                       
40003ba4:	40 00 15 da 	call  4000930c <_Protected_heap_Allocate_aligned_with_boundary>
40003ba8:	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 ) {                                               
40003bac:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003bb0:	12 80 00 18 	bne  40003c10 <malloc+0xb0>                    
40003bb4:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
    return_this = (*rtems_malloc_extend_handler)( RTEMS_Malloc_Heap, size );
40003bb8:	10 80 00 09 	b  40003bdc <malloc+0x7c>                      
40003bbc:	d0 07 23 28 	ld  [ %i4 + 0x328 ], %o0                       
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if not in correct system state.
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
       !malloc_is_system_state_OK() )                                 
40003bc0:	7f ff ff a3 	call  40003a4c <malloc_is_system_state_OK>     
40003bc4:	01 00 00 00 	nop                                            
    return (void *) 0;                                                
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if not in correct system state.
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
40003bc8:	80 a2 20 00 	cmp  %o0, 0                                    
40003bcc:	12 bf ff f3 	bne  40003b98 <malloc+0x38>                    <== ALWAYS TAKEN
40003bd0:	01 00 00 00 	nop                                            
                                                                      
  if ( !return_this ) {                                               
    return_this = (*rtems_malloc_extend_handler)( RTEMS_Malloc_Heap, size );
    if ( !return_this ) {                                             
      errno = ENOMEM;                                                 
      return (void *) 0;                                              
40003bd4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003bd8:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
   */                                                                 
                                                                      
  return_this = _Protected_heap_Allocate( RTEMS_Malloc_Heap, size );  
                                                                      
  if ( !return_this ) {                                               
    return_this = (*rtems_malloc_extend_handler)( RTEMS_Malloc_Heap, size );
40003bdc:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
40003be0:	c2 00 62 64 	ld  [ %g1 + 0x264 ], %g1	! 40015664 <rtems_malloc_extend_handler>
40003be4:	9f c0 40 00 	call  %g1                                      
40003be8:	92 10 00 18 	mov  %i0, %o1                                  
    if ( !return_this ) {                                             
40003bec:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003bf0:	12 80 00 08 	bne  40003c10 <malloc+0xb0>                    
40003bf4:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
      errno = ENOMEM;                                                 
40003bf8:	40 00 2f 8a 	call  4000fa20 <__errno>                       
40003bfc:	01 00 00 00 	nop                                            
40003c00:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         
40003c04:	c2 22 00 00 	st  %g1, [ %o0 ]                               
      return (void *) 0;                                              
40003c08:	81 c7 e0 08 	ret                                            
40003c0c:	91 e8 20 00 	restore  %g0, 0, %o0                           
  }                                                                   
                                                                      
  /*                                                                  
   *  If the user wants us to dirty the allocated memory, then do it. 
   */                                                                 
  if ( rtems_malloc_dirty_helper )                                    
40003c10:	c2 00 60 b8 	ld  [ %g1 + 0xb8 ], %g1                        
40003c14:	80 a0 60 00 	cmp  %g1, 0                                    
40003c18:	02 80 00 04 	be  40003c28 <malloc+0xc8>                     
40003c1c:	90 10 00 1d 	mov  %i5, %o0                                  
    (*rtems_malloc_dirty_helper)( return_this, size );                
40003c20:	9f c0 40 00 	call  %g1                                      
40003c24:	92 10 00 18 	mov  %i0, %o1                                  
                                                                      
  /*                                                                  
   *  If configured, update the statistics                            
   */                                                                 
  if ( rtems_malloc_statistics_helpers )                              
40003c28:	03 10 00 5c 	sethi  %hi(0x40017000), %g1                    
40003c2c:	c2 00 60 bc 	ld  [ %g1 + 0xbc ], %g1	! 400170bc <rtems_malloc_statistics_helpers>
40003c30:	80 a0 60 00 	cmp  %g1, 0                                    
40003c34:	02 80 00 05 	be  40003c48 <malloc+0xe8>                     
40003c38:	b0 10 00 1d 	mov  %i5, %i0                                  
    (*rtems_malloc_statistics_helpers->at_malloc)(return_this);       
40003c3c:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
40003c40:	9f c0 40 00 	call  %g1                                      
40003c44:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  return return_this;                                                 
}                                                                     
40003c48:	81 c7 e0 08 	ret                                            
40003c4c:	81 e8 00 00 	restore                                        
                                                                      

4000e234 <memfile_ftruncate>: int memfile_ftruncate( rtems_libio_t *iop, off_t length ) {
4000e234:	9d e3 bf 98 	save  %sp, -104, %sp                           
  IMFS_jnode_t   *the_jnode;                                          
                                                                      
  the_jnode = iop->pathinfo.node_access;                              
4000e238:	fa 06 20 1c 	ld  [ %i0 + 0x1c ], %i5                        
   *  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 )                           
4000e23c:	c2 07 60 50 	ld  [ %i5 + 0x50 ], %g1                        
4000e240:	80 a0 40 19 	cmp  %g1, %i1                                  
4000e244:	06 80 00 09 	bl  4000e268 <memfile_ftruncate+0x34>          <== NEVER TAKEN
4000e248:	90 10 00 1d 	mov  %i5, %o0                                  
4000e24c:	32 80 00 0d 	bne,a   4000e280 <memfile_ftruncate+0x4c>      <== NEVER TAKEN
4000e250:	f2 27 60 50 	st  %i1, [ %i5 + 0x50 ]                        <== NOT EXECUTED
4000e254:	c2 07 60 54 	ld  [ %i5 + 0x54 ], %g1                        
4000e258:	80 a0 40 1a 	cmp  %g1, %i2                                  
4000e25c:	3a 80 00 09 	bcc,a   4000e280 <memfile_ftruncate+0x4c>      
4000e260:	f2 27 60 50 	st  %i1, [ %i5 + 0x50 ]                        
    return IMFS_memfile_extend( the_jnode, true, length );            
4000e264:	90 10 00 1d 	mov  %i5, %o0                                  
4000e268:	92 10 20 01 	mov  1, %o1                                    
4000e26c:	94 10 00 19 	mov  %i1, %o2                                  
4000e270:	7f ff ff 8b 	call  4000e09c <IMFS_memfile_extend>           
4000e274:	96 10 00 1a 	mov  %i2, %o3                                  
4000e278:	81 c7 e0 08 	ret                                            
4000e27c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
  /*                                                                  
   *  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;                                 
4000e280:	f4 27 60 54 	st  %i2, [ %i5 + 0x54 ]                        
                                                                      
static inline void IMFS_mtime_ctime_update( IMFS_jnode_t *jnode )     
{                                                                     
  struct timeval now;                                                 
                                                                      
  gettimeofday( &now, 0 );                                            
4000e284:	90 07 bf f8 	add  %fp, -8, %o0                              
4000e288:	7f ff d5 8b 	call  400038b4 <gettimeofday>                  
4000e28c:	92 10 20 00 	clr  %o1                                       
                                                                      
  jnode->stat_mtime = now.tv_sec;                                     
4000e290:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000e294:	c2 27 60 44 	st  %g1, [ %i5 + 0x44 ]                        
  jnode->stat_ctime = now.tv_sec;                                     
4000e298:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
                                                                      
  IMFS_mtime_ctime_update(the_jnode);                                 
                                                                      
  return 0;                                                           
}                                                                     
4000e29c:	81 c7 e0 08 	ret                                            
4000e2a0:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000e470 <memfile_open>: rtems_libio_t *iop, const char *pathname, int oflag, mode_t mode ) {
4000e470:	9d e3 bf a0 	save  %sp, -96, %sp                            
  the_jnode = iop->pathinfo.node_access;                              
                                                                      
  /*                                                                  
   * Perform 'copy on write' for linear files                         
   */                                                                 
  if ((iop->flags & LIBIO_FLAGS_WRITE)                                
4000e474:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
4000e478:	80 88 60 04 	btst  4, %g1                                   
4000e47c:	12 80 00 04 	bne  4000e48c <memfile_open+0x1c>              
4000e480:	d0 06 20 1c 	ld  [ %i0 + 0x1c ], %o0                        
    if ((count != 0)                                                  
     && (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1))      
        return -1;                                                    
  }                                                                   
                                                                      
  return 0;                                                           
4000e484:	81 c7 e0 08 	ret                                            
4000e488:	91 e8 20 00 	restore  %g0, 0, %o0                           
  rtems_chain_extract_unprotected( &node->Node );                     
}                                                                     
                                                                      
static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node )
{                                                                     
  return node->control->imfs_type;                                    
4000e48c:	c2 02 20 4c 	ld  [ %o0 + 0x4c ], %g1                        
                                                                      
  /*                                                                  
   * Perform 'copy on write' for linear files                         
   */                                                                 
  if ((iop->flags & LIBIO_FLAGS_WRITE)                                
   && (IMFS_type( the_jnode ) == IMFS_LINEAR_FILE)) {                 
4000e490:	c2 00 40 00 	ld  [ %g1 ], %g1                               
4000e494:	80 a0 60 05 	cmp  %g1, 5                                    
4000e498:	12 bf ff fb 	bne  4000e484 <memfile_open+0x14>              <== ALWAYS TAKEN
4000e49c:	03 10 00 58 	sethi  %hi(0x40016000), %g1                    
    uint32_t   count = the_jnode->info.linearfile.size;               
4000e4a0:	d8 02 20 54 	ld  [ %o0 + 0x54 ], %o4                        <== NOT EXECUTED
    const unsigned char *buffer = the_jnode->info.linearfile.direct;  
4000e4a4:	d6 02 20 58 	ld  [ %o0 + 0x58 ], %o3                        <== NOT EXECUTED
                                                                      
    the_jnode->control = &IMFS_node_control_memfile;                  
    the_jnode->info.file.size            = 0;                         
4000e4a8:	c0 22 20 50 	clr  [ %o0 + 0x50 ]                            <== NOT EXECUTED
  if ((iop->flags & LIBIO_FLAGS_WRITE)                                
   && (IMFS_type( the_jnode ) == IMFS_LINEAR_FILE)) {                 
    uint32_t   count = the_jnode->info.linearfile.size;               
    const unsigned char *buffer = the_jnode->info.linearfile.direct;  
                                                                      
    the_jnode->control = &IMFS_node_control_memfile;                  
4000e4ac:	82 10 62 2c 	or  %g1, 0x22c, %g1                            <== NOT EXECUTED
    the_jnode->info.file.size            = 0;                         
4000e4b0:	c0 22 20 54 	clr  [ %o0 + 0x54 ]                            <== NOT EXECUTED
  if ((iop->flags & LIBIO_FLAGS_WRITE)                                
   && (IMFS_type( the_jnode ) == IMFS_LINEAR_FILE)) {                 
    uint32_t   count = the_jnode->info.linearfile.size;               
    const unsigned char *buffer = the_jnode->info.linearfile.direct;  
                                                                      
    the_jnode->control = &IMFS_node_control_memfile;                  
4000e4b4:	c2 22 20 4c 	st  %g1, [ %o0 + 0x4c ]                        <== NOT EXECUTED
    the_jnode->info.file.size            = 0;                         
    the_jnode->info.file.indirect        = 0;                         
4000e4b8:	c0 22 20 58 	clr  [ %o0 + 0x58 ]                            <== NOT EXECUTED
    the_jnode->info.file.doubly_indirect = 0;                         
4000e4bc:	c0 22 20 5c 	clr  [ %o0 + 0x5c ]                            <== NOT EXECUTED
    the_jnode->info.file.triply_indirect = 0;                         
    if ((count != 0)                                                  
4000e4c0:	80 a3 20 00 	cmp  %o4, 0                                    <== NOT EXECUTED
4000e4c4:	02 bf ff f0 	be  4000e484 <memfile_open+0x14>               <== NOT EXECUTED
4000e4c8:	c0 22 20 60 	clr  [ %o0 + 0x60 ]                            <== NOT EXECUTED
     && (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1))      
4000e4cc:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4000e4d0:	7f ff ff 75 	call  4000e2a4 <IMFS_memfile_write>            <== NOT EXECUTED
4000e4d4:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4000e4d8:	90 38 00 08 	xnor  %g0, %o0, %o0                            <== NOT EXECUTED
4000e4dc:	80 a0 00 08 	cmp  %g0, %o0                                  <== NOT EXECUTED
4000e4e0:	b0 40 3f ff 	addx  %g0, -1, %i0                             <== NOT EXECUTED
        return -1;                                                    
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
4000e4e4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e4e8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40003d70 <mount>: const char *target, const char *filesystemtype, rtems_filesystem_options_t options, const void *data ) {
40003d70:	9d e3 bf 50 	save  %sp, -176, %sp                           
  int rv = 0;                                                         
                                                                      
  if (                                                                
40003d74:	80 a6 e0 01 	cmp  %i3, 1                                    
40003d78:	18 80 00 b3 	bgu  40004044 <mount+0x2d4>                    
40003d7c:	01 00 00 00 	nop                                            
    options == RTEMS_FILESYSTEM_READ_ONLY                             
      || options == RTEMS_FILESYSTEM_READ_WRITE                       
  ) {                                                                 
    rtems_filesystem_fsmount_me_t fsmount_me_h =                      
40003d80:	40 00 21 7d 	call  4000c374 <rtems_filesystem_get_mount_handler>
40003d84:	90 10 00 1a 	mov  %i2, %o0                                  
      rtems_filesystem_get_mount_handler( filesystemtype );           
                                                                      
    if ( fsmount_me_h != NULL ) {                                     
40003d88:	a4 92 20 00 	orcc  %o0, 0, %l2                              
40003d8c:	02 80 00 ae 	be  40004044 <mount+0x2d4>                     
40003d90:	a2 96 60 00 	orcc  %i1, 0, %l1                              
  const char *target_or_null,                                         
  const char *filesystemtype,                                         
  size_t *target_length_ptr                                           
)                                                                     
{                                                                     
  const char *target = target_or_null != NULL ? target_or_null : "/"; 
40003d94:	12 80 00 04 	bne  40003da4 <mount+0x34>                     
40003d98:	01 00 00 00 	nop                                            
40003d9c:	23 10 00 56 	sethi  %hi(0x40015800), %l1                    
40003da0:	a2 14 62 58 	or  %l1, 0x258, %l1	! 40015a58 <IMFS_node_control_enosys+0x98>
  size_t filesystemtype_size = strlen( filesystemtype ) + 1;          
40003da4:	40 00 32 7f 	call  400107a0 <strlen>                        
40003da8:	90 10 00 1a 	mov  %i2, %o0                                  
  size_t source_size = source_or_null != NULL ?                       
    strlen( source_or_null ) + 1 : 0;                                 
40003dac:	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;          
40003db0:	ba 10 00 08 	mov  %o0, %i5                                  
  size_t source_size = source_or_null != NULL ?                       
    strlen( source_or_null ) + 1 : 0;                                 
40003db4:	02 80 00 06 	be  40003dcc <mount+0x5c>                      
40003db8:	aa 02 20 01 	add  %o0, 1, %l5                               
40003dbc:	40 00 32 79 	call  400107a0 <strlen>                        
40003dc0:	90 10 00 18 	mov  %i0, %o0                                  
40003dc4:	10 80 00 03 	b  40003dd0 <mount+0x60>                       
40003dc8:	a0 02 20 01 	add  %o0, 1, %l0                               
40003dcc:	a0 10 20 00 	clr  %l0                                       
  size_t target_size = strlen( target ) + 1;                          
  size_t size = sizeof( rtems_filesystem_mount_table_entry_t )        
    + filesystemtype_size + source_size + target_size                 
40003dd0:	ba 07 60 65 	add  %i5, 0x65, %i5                            
{                                                                     
  const char *target = target_or_null != NULL ? target_or_null : "/"; 
  size_t filesystemtype_size = strlen( filesystemtype ) + 1;          
  size_t source_size = source_or_null != NULL ?                       
    strlen( source_or_null ) + 1 : 0;                                 
  size_t target_size = strlen( target ) + 1;                          
40003dd4:	40 00 32 73 	call  400107a0 <strlen>                        
40003dd8:	90 10 00 11 	mov  %l1, %o0                                  
  size_t size = sizeof( rtems_filesystem_mount_table_entry_t )        
    + filesystemtype_size + source_size + target_size                 
40003ddc:	92 07 40 10 	add  %i5, %l0, %o1                             
{                                                                     
  const char *target = target_or_null != NULL ? target_or_null : "/"; 
  size_t filesystemtype_size = strlen( filesystemtype ) + 1;          
  size_t source_size = source_or_null != NULL ?                       
    strlen( source_or_null ) + 1 : 0;                                 
  size_t target_size = strlen( target ) + 1;                          
40003de0:	a8 02 20 01 	add  %o0, 1, %l4                               
  size_t size = sizeof( rtems_filesystem_mount_table_entry_t )        
    + filesystemtype_size + source_size + target_size                 
    + sizeof( rtems_filesystem_global_location_t );                   
  rtems_filesystem_mount_table_entry_t *mt_entry = calloc( 1, size ); 
40003de4:	90 10 20 01 	mov  1, %o0                                    
40003de8:	7f ff fe 74 	call  400037b8 <calloc>                        
40003dec:	92 02 40 14 	add  %o1, %l4, %o1                             
                                                                      
  if ( mt_entry != NULL ) {                                           
40003df0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40003df4:	02 80 00 9c 	be  40004064 <mount+0x2f4>                     <== NEVER TAKEN
40003df8:	82 07 60 64 	add  %i5, 0x64, %g1                            
    rtems_filesystem_global_location_t *mt_fs_root =                  
      (rtems_filesystem_global_location_t *)                          
        ((char *) mt_entry + sizeof( *mt_entry ));                    
    char *str = (char *) mt_fs_root + sizeof( *mt_fs_root );          
                                                                      
    memcpy( str, filesystemtype, filesystemtype_size );               
40003dfc:	92 10 00 1a 	mov  %i2, %o1                                  
40003e00:	90 10 00 01 	mov  %g1, %o0                                  
40003e04:	40 00 30 ed 	call  400101b8 <memcpy>                        
40003e08:	94 10 00 15 	mov  %l5, %o2                                  
    mt_entry->type = str;                                             
40003e0c:	d0 27 60 34 	st  %o0, [ %i5 + 0x34 ]                        
    + filesystemtype_size + source_size + target_size                 
    + sizeof( rtems_filesystem_global_location_t );                   
  rtems_filesystem_mount_table_entry_t *mt_entry = calloc( 1, size ); 
                                                                      
  if ( mt_entry != NULL ) {                                           
    rtems_filesystem_global_location_t *mt_fs_root =                  
40003e10:	a6 07 60 40 	add  %i5, 0x40, %l3                            
                                                                      
    memcpy( str, filesystemtype, filesystemtype_size );               
    mt_entry->type = str;                                             
    str += filesystemtype_size;                                       
                                                                      
    if ( source_or_null != NULL ) {                                   
40003e14:	80 a6 20 00 	cmp  %i0, 0                                    
40003e18:	02 80 00 08 	be  40003e38 <mount+0xc8>                      
40003e1c:	82 02 00 15 	add  %o0, %l5, %g1                             
      memcpy( str, source_or_null, source_size );                     
40003e20:	90 10 00 01 	mov  %g1, %o0                                  
40003e24:	92 10 00 18 	mov  %i0, %o1                                  
40003e28:	40 00 30 e4 	call  400101b8 <memcpy>                        
40003e2c:	94 10 00 10 	mov  %l0, %o2                                  
      mt_entry->dev = str;                                            
40003e30:	d0 27 60 38 	st  %o0, [ %i5 + 0x38 ]                        
      str += source_size;                                             
40003e34:	82 02 00 10 	add  %o0, %l0, %g1                             
    }                                                                 
                                                                      
    memcpy( str, target, target_size );                               
40003e38:	90 10 00 01 	mov  %g1, %o0                                  
40003e3c:	92 10 00 11 	mov  %l1, %o1                                  
40003e40:	40 00 30 de 	call  400101b8 <memcpy>                        
40003e44:	94 10 00 14 	mov  %l4, %o2                                  
    mt_entry->target = str;                                           
    str += target_size;                                               
                                                                      
    mt_entry->mounted = true;                                         
40003e48:	82 10 20 01 	mov  1, %g1                                    
40003e4c:	c2 2f 60 28 	stb  %g1, [ %i5 + 0x28 ]                       
    mt_entry->mt_fs_root = mt_fs_root;                                
    mt_entry->pathconf_limits_and_options = &rtems_filesystem_default_pathconf;
40003e50:	03 10 00 56 	sethi  %hi(0x40015800), %g1                    
40003e54:	82 10 62 5c 	or  %g1, 0x25c, %g1	! 40015a5c <rtems_filesystem_default_pathconf>
40003e58:	c2 27 60 2c 	st  %g1, [ %i5 + 0x2c ]                        
                                                                      
    mt_fs_root->location.mt_entry = mt_entry;                         
    mt_fs_root->reference_count = 1;                                  
40003e5c:	82 10 20 01 	mov  1, %g1                                    
      mt_entry->dev = str;                                            
      str += source_size;                                             
    }                                                                 
                                                                      
    memcpy( str, target, target_size );                               
    mt_entry->target = str;                                           
40003e60:	d0 27 60 30 	st  %o0, [ %i5 + 0x30 ]                        
    mt_entry->mounted = true;                                         
    mt_entry->mt_fs_root = mt_fs_root;                                
    mt_entry->pathconf_limits_and_options = &rtems_filesystem_default_pathconf;
                                                                      
    mt_fs_root->location.mt_entry = mt_entry;                         
    mt_fs_root->reference_count = 1;                                  
40003e64:	c2 27 60 58 	st  %g1, [ %i5 + 0x58 ]                        
  void                *starting_address,                              
  size_t               number_nodes,                                  
  size_t               node_size                                      
)                                                                     
{                                                                     
  _Chain_Initialize(                                                  
40003e68:	90 07 60 14 	add  %i5, 0x14, %o0                            
40003e6c:	92 10 00 13 	mov  %l3, %o1                                  
40003e70:	94 10 20 01 	mov  1, %o2                                    
40003e74:	96 10 20 24 	mov  0x24, %o3                                 
    memcpy( str, target, target_size );                               
    mt_entry->target = str;                                           
    str += target_size;                                               
                                                                      
    mt_entry->mounted = true;                                         
    mt_entry->mt_fs_root = mt_fs_root;                                
40003e78:	e6 27 60 24 	st  %l3, [ %i5 + 0x24 ]                        
40003e7c:	40 00 10 a3 	call  40008108 <_Chain_Initialize>             
40003e80:	fa 27 60 54 	st  %i5, [ %i5 + 0x54 ]                        
        filesystemtype,                                               
        &target_length                                                
      );                                                              
                                                                      
      if ( mt_entry != NULL ) {                                       
        mt_entry->writeable = options == RTEMS_FILESYSTEM_READ_WRITE; 
40003e84:	b6 0e e0 01 	and  %i3, 1, %i3                               
                                                                      
        rv = (*fsmount_me_h)( mt_entry, data );                       
40003e88:	90 10 00 1d 	mov  %i5, %o0                                  
        filesystemtype,                                               
        &target_length                                                
      );                                                              
                                                                      
      if ( mt_entry != NULL ) {                                       
        mt_entry->writeable = options == RTEMS_FILESYSTEM_READ_WRITE; 
40003e8c:	f6 2f 60 29 	stb  %i3, [ %i5 + 0x29 ]                       
                                                                      
        rv = (*fsmount_me_h)( mt_entry, data );                       
40003e90:	9f c4 80 00 	call  %l2                                      
40003e94:	92 10 00 1c 	mov  %i4, %o1                                  
        if ( rv == 0 ) {                                              
40003e98:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40003e9c:	12 80 00 6e 	bne  40004054 <mount+0x2e4>                    
40003ea0:	80 a6 60 00 	cmp  %i1, 0                                    
          if ( target != NULL ) {                                     
40003ea4:	02 80 00 38 	be  40003f84 <mount+0x214>                     
40003ea8:	92 10 00 19 	mov  %i1, %o1                                  
{                                                                     
  int rv = 0;                                                         
  rtems_filesystem_eval_path_context_t ctx;                           
  int eval_flags = RTEMS_FS_PERMS_RWX                                 
    | RTEMS_FS_FOLLOW_LINK;                                           
  rtems_filesystem_location_info_t *currentloc =                      
40003eac:	94 10 20 1f 	mov  0x1f, %o2                                 
40003eb0:	40 00 02 1c 	call  40004720 <rtems_filesystem_eval_path_start>
40003eb4:	90 07 bf c8 	add  %fp, -56, %o0                             
                                                                      
static inline bool rtems_filesystem_location_is_instance_root(        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
40003eb8:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
                                                                      
  return (*mt_entry->ops->are_nodes_equal_h)(                         
40003ebc:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
40003ec0:	c4 00 a0 10 	ld  [ %g2 + 0x10 ], %g2                        
40003ec4:	9f c0 80 00 	call  %g2                                      
40003ec8:	d2 00 60 24 	ld  [ %g1 + 0x24 ], %o1                        
    rtems_filesystem_eval_path_start( &ctx, target, eval_flags );     
                                                                      
  if ( !rtems_filesystem_location_is_instance_root( currentloc ) ) {  
40003ecc:	80 a2 20 00 	cmp  %o0, 0                                    
40003ed0:	12 80 00 22 	bne  40003f58 <mount+0x1e8>                    
40003ed4:	92 07 bf e0 	add  %fp, -32, %o1                             
static inline void rtems_filesystem_eval_path_extract_currentloc(     
  rtems_filesystem_eval_path_context_t *ctx,                          
  rtems_filesystem_location_info_t *get                               
)                                                                     
{                                                                     
  rtems_filesystem_location_copy_and_detach(                          
40003ed8:	40 00 03 3f 	call  40004bd4 <rtems_filesystem_location_copy_and_detach>
40003edc:	90 07 bf b0 	add  %fp, -80, %o0                             
    rtems_filesystem_location_info_t targetloc;                       
    rtems_filesystem_global_location_t *mt_point_node;                
                                                                      
    rtems_filesystem_eval_path_extract_currentloc( &ctx, &targetloc );
    mt_point_node = rtems_filesystem_location_transform_to_global( &targetloc );
40003ee0:	40 00 03 47 	call  40004bfc <rtems_filesystem_location_transform_to_global>
40003ee4:	90 07 bf b0 	add  %fp, -80, %o0                             
    mt_entry->mt_point_node = mt_point_node;                          
    rv = (*mt_point_node->location.mt_entry->ops->mount_h)( mt_entry );
40003ee8:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
    rtems_filesystem_location_info_t targetloc;                       
    rtems_filesystem_global_location_t *mt_point_node;                
                                                                      
    rtems_filesystem_eval_path_extract_currentloc( &ctx, &targetloc );
    mt_point_node = rtems_filesystem_location_transform_to_global( &targetloc );
    mt_entry->mt_point_node = mt_point_node;                          
40003eec:	d0 27 60 20 	st  %o0, [ %i5 + 0x20 ]                        
    rv = (*mt_point_node->location.mt_entry->ops->mount_h)( mt_entry );
40003ef0:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
  if ( !rtems_filesystem_location_is_instance_root( currentloc ) ) {  
    rtems_filesystem_location_info_t targetloc;                       
    rtems_filesystem_global_location_t *mt_point_node;                
                                                                      
    rtems_filesystem_eval_path_extract_currentloc( &ctx, &targetloc );
    mt_point_node = rtems_filesystem_location_transform_to_global( &targetloc );
40003ef4:	b8 10 00 08 	mov  %o0, %i4                                  
    mt_entry->mt_point_node = mt_point_node;                          
    rv = (*mt_point_node->location.mt_entry->ops->mount_h)( mt_entry );
40003ef8:	c2 00 60 30 	ld  [ %g1 + 0x30 ], %g1                        
40003efc:	9f c0 40 00 	call  %g1                                      
40003f00:	90 10 00 1d 	mov  %i5, %o0                                  
    if ( rv == 0 ) {                                                  
40003f04:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40003f08:	12 80 00 11 	bne  40003f4c <mount+0x1dc>                    
40003f0c:	92 10 20 00 	clr  %o1                                       
                                                                      
extern pthread_key_t rtems_current_user_env_key;                      
                                                                      
static inline void rtems_libio_lock( void )                           
{                                                                     
  rtems_semaphore_obtain( rtems_libio_semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT );
40003f10:	39 10 00 60 	sethi  %hi(0x40018000), %i4                    
40003f14:	d0 07 23 38 	ld  [ %i4 + 0x338 ], %o0	! 40018338 <rtems_libio_semaphore>
40003f18:	40 00 0d d2 	call  40007660 <rtems_semaphore_obtain>        
40003f1c:	94 10 20 00 	clr  %o2                                       
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
40003f20:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
40003f24:	82 10 63 4c 	or  %g1, 0x34c, %g1	! 40016b4c <rtems_filesystem_mount_table>
40003f28:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
                                                                      
  the_node->next = tail;                                              
40003f2c:	86 00 60 04 	add  %g1, 4, %g3                               
  tail->previous = the_node;                                          
40003f30:	fa 20 60 08 	st  %i5, [ %g1 + 8 ]                           
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
40003f34:	c6 27 40 00 	st  %g3, [ %i5 ]                               
}                                                                     
                                                                      
static inline void rtems_libio_unlock( void )                         
{                                                                     
  rtems_semaphore_release( rtems_libio_semaphore );                   
40003f38:	d0 07 23 38 	ld  [ %i4 + 0x338 ], %o0                       
  tail->previous = the_node;                                          
  old_last->next = the_node;                                          
40003f3c:	fa 20 80 00 	st  %i5, [ %g2 ]                               
40003f40:	40 00 0e 10 	call  40007780 <rtems_semaphore_release>       
40003f44:	c4 27 60 04 	st  %g2, [ %i5 + 4 ]                           
40003f48:	30 80 00 08 	b,a   40003f68 <mount+0x1f8>                   
        &rtems_filesystem_mount_table,                                
        &mt_entry->mt_node                                            
      );                                                              
      rtems_filesystem_mt_unlock();                                   
    } else {                                                          
      rtems_filesystem_global_location_release( mt_point_node );      
40003f4c:	40 00 02 f0 	call  40004b0c <rtems_filesystem_global_location_release>
40003f50:	90 10 00 1c 	mov  %i4, %o0                                  
40003f54:	30 80 00 05 	b,a   40003f68 <mount+0x1f8>                   
    }                                                                 
  } else {                                                            
    rtems_filesystem_eval_path_error( &ctx, EBUSY );                  
40003f58:	90 07 bf c8 	add  %fp, -56, %o0                             
40003f5c:	92 10 20 10 	mov  0x10, %o1                                 
40003f60:	40 00 01 81 	call  40004564 <rtems_filesystem_eval_path_error>
40003f64:	b0 10 3f ff 	mov  -1, %i0                                   
    rv = -1;                                                          
  }                                                                   
                                                                      
  rtems_filesystem_eval_path_cleanup( &ctx );                         
40003f68:	40 00 01 f6 	call  40004740 <rtems_filesystem_eval_path_cleanup>
40003f6c:	90 07 bf c8 	add  %fp, -56, %o0                             
            rv = register_subordinate_file_system( mt_entry, target );
          } else {                                                    
            rv = register_root_file_system( mt_entry );               
          }                                                           
                                                                      
          if ( rv != 0 ) {                                            
40003f70:	80 a6 20 00 	cmp  %i0, 0                                    
40003f74:	02 80 00 41 	be  40004078 <mount+0x308>                     
40003f78:	01 00 00 00 	nop                                            
            (*mt_entry->ops->fsunmount_me_h)( mt_entry );             
40003f7c:	10 80 00 2e 	b  40004034 <mount+0x2c4>                      
40003f80:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
                                                                      
extern pthread_key_t rtems_current_user_env_key;                      
                                                                      
static inline void rtems_libio_lock( void )                           
{                                                                     
  rtems_semaphore_obtain( rtems_libio_semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT );
40003f84:	39 10 00 60 	sethi  %hi(0x40018000), %i4                    
40003f88:	d0 07 23 38 	ld  [ %i4 + 0x338 ], %o0	! 40018338 <rtems_libio_semaphore>
40003f8c:	92 10 20 00 	clr  %o1                                       
40003f90:	40 00 0d b4 	call  40007660 <rtems_semaphore_obtain>        
40003f94:	94 10 20 00 	clr  %o2                                       
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40003f98:	05 10 00 5a 	sethi  %hi(0x40016800), %g2                    
)                                                                     
{                                                                     
  int rv = 0;                                                         
                                                                      
  rtems_filesystem_mt_lock();                                         
  if ( rtems_chain_is_empty( &rtems_filesystem_mount_table ) ) {      
40003f9c:	c6 00 a3 4c 	ld  [ %g2 + 0x34c ], %g3	! 40016b4c <rtems_filesystem_mount_table>
40003fa0:	82 10 a3 4c 	or  %g2, 0x34c, %g1                            
40003fa4:	84 00 60 04 	add  %g1, 4, %g2                               
40003fa8:	80 a0 c0 02 	cmp  %g3, %g2                                  
40003fac:	12 80 00 08 	bne  40003fcc <mount+0x25c>                    <== NEVER TAKEN
40003fb0:	01 00 00 00 	nop                                            
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
40003fb4:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
                                                                      
  the_node->next = tail;                                              
40003fb8:	c6 27 40 00 	st  %g3, [ %i5 ]                               
  tail->previous = the_node;                                          
40003fbc:	fa 20 60 08 	st  %i5, [ %g1 + 8 ]                           
  old_last->next = the_node;                                          
40003fc0:	fa 20 80 00 	st  %i5, [ %g2 ]                               
  the_node->previous = old_last;                                      
40003fc4:	10 80 00 06 	b  40003fdc <mount+0x26c>                      
40003fc8:	c4 27 60 04 	st  %g2, [ %i5 + 4 ]                           
    rtems_chain_append_unprotected(                                   
      &rtems_filesystem_mount_table,                                  
      &mt_entry->mt_node                                              
    );                                                                
  } else {                                                            
    errno = EINVAL;                                                   
40003fcc:	40 00 2e 95 	call  4000fa20 <__errno>                       <== NOT EXECUTED
40003fd0:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40003fd4:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
40003fd8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
}                                                                     
                                                                      
static inline void rtems_libio_unlock( void )                         
{                                                                     
  rtems_semaphore_release( rtems_libio_semaphore );                   
40003fdc:	40 00 0d e9 	call  40007780 <rtems_semaphore_release>       
40003fe0:	d0 07 23 38 	ld  [ %i4 + 0x338 ], %o0                       
    rv = -1;                                                          
  }                                                                   
  rtems_filesystem_mt_unlock();                                       
                                                                      
  if ( rv == 0 ) {                                                    
40003fe4:	80 a6 20 00 	cmp  %i0, 0                                    
40003fe8:	32 80 00 13 	bne,a   40004034 <mount+0x2c4>                 <== NEVER TAKEN
40003fec:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         <== NOT EXECUTED
    rtems_filesystem_global_location_t *new_fs_root =                 
      rtems_filesystem_global_location_obtain( &mt_entry->mt_fs_root );
40003ff0:	ba 07 60 24 	add  %i5, 0x24, %i5                            
    rv = -1;                                                          
  }                                                                   
  rtems_filesystem_mt_unlock();                                       
                                                                      
  if ( rv == 0 ) {                                                    
    rtems_filesystem_global_location_t *new_fs_root =                 
40003ff4:	40 00 02 94 	call  40004a44 <rtems_filesystem_global_location_obtain>
40003ff8:	90 10 00 1d 	mov  %i5, %o0                                  
40003ffc:	b8 10 00 08 	mov  %o0, %i4                                  
      rtems_filesystem_global_location_obtain( &mt_entry->mt_fs_root );
    rtems_filesystem_global_location_t *new_fs_current =              
40004000:	40 00 02 91 	call  40004a44 <rtems_filesystem_global_location_obtain>
40004004:	90 10 00 1d 	mov  %i5, %o0                                  
      rtems_filesystem_global_location_obtain( &mt_entry->mt_fs_root );
                                                                      
    rtems_filesystem_global_location_assign(                          
      &rtems_filesystem_root,                                         
40004008:	40 00 01 03 	call  40004414 <rtems_current_user_env_get>    
4000400c:	ba 10 00 08 	mov  %o0, %i5                                  
    rtems_filesystem_global_location_t *new_fs_root =                 
      rtems_filesystem_global_location_obtain( &mt_entry->mt_fs_root );
    rtems_filesystem_global_location_t *new_fs_current =              
      rtems_filesystem_global_location_obtain( &mt_entry->mt_fs_root );
                                                                      
    rtems_filesystem_global_location_assign(                          
40004010:	92 10 00 1c 	mov  %i4, %o1                                  
40004014:	40 00 02 d2 	call  40004b5c <rtems_filesystem_global_location_assign>
40004018:	90 02 20 04 	add  %o0, 4, %o0                               
      &rtems_filesystem_root,                                         
      new_fs_root                                                     
    );                                                                
    rtems_filesystem_global_location_assign(                          
      &rtems_filesystem_current,                                      
4000401c:	40 00 00 fe 	call  40004414 <rtems_current_user_env_get>    
40004020:	01 00 00 00 	nop                                            
                                                                      
    rtems_filesystem_global_location_assign(                          
      &rtems_filesystem_root,                                         
      new_fs_root                                                     
    );                                                                
    rtems_filesystem_global_location_assign(                          
40004024:	40 00 02 ce 	call  40004b5c <rtems_filesystem_global_location_assign>
40004028:	92 10 00 1d 	mov  %i5, %o1                                  
4000402c:	81 c7 e0 08 	ret                                            
40004030:	81 e8 00 00 	restore                                        
          } else {                                                    
            rv = register_root_file_system( mt_entry );               
          }                                                           
                                                                      
          if ( rv != 0 ) {                                            
            (*mt_entry->ops->fsunmount_me_h)( mt_entry );             
40004034:	c2 00 60 3c 	ld  [ %g1 + 0x3c ], %g1                        
40004038:	9f c0 40 00 	call  %g1                                      
4000403c:	90 10 00 1d 	mov  %i5, %o0                                  
40004040:	30 80 00 05 	b,a   40004054 <mount+0x2e4>                   
    } else {                                                          
      errno = EINVAL;                                                 
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    errno = EINVAL;                                                   
40004044:	40 00 2e 77 	call  4000fa20 <__errno>                       
40004048:	01 00 00 00 	nop                                            
4000404c:	10 80 00 09 	b  40004070 <mount+0x300>                      
40004050:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
            (*mt_entry->ops->fsunmount_me_h)( mt_entry );             
          }                                                           
        }                                                             
                                                                      
        if ( rv != 0 ) {                                              
          free( mt_entry );                                           
40004054:	7f ff fd ee 	call  4000380c <free>                          
40004058:	90 10 00 1d 	mov  %i5, %o0                                  
4000405c:	81 c7 e0 08 	ret                                            
40004060:	81 e8 00 00 	restore                                        
        }                                                             
      } else {                                                        
        errno = ENOMEM;                                               
40004064:	40 00 2e 6f 	call  4000fa20 <__errno>                       <== NOT EXECUTED
40004068:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000406c:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
40004070:	c2 22 00 00 	st  %g1, [ %o0 ]                               
        rv = -1;                                                      
40004074:	b0 10 3f ff 	mov  -1, %i0                                   
    errno = EINVAL;                                                   
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40004078:	81 c7 e0 08 	ret                                            
4000407c:	81 e8 00 00 	restore                                        
                                                                      

40008774 <mount_and_make_target_path>: const char *target, const char *filesystemtype, rtems_filesystem_options_t options, const void *data ) {
40008774:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = -1;                                                        
                                                                      
  if (target != NULL) {                                               
40008778:	90 96 60 00 	orcc  %i1, 0, %o0                              
4000877c:	02 80 00 09 	be  400087a0 <mount_and_make_target_path+0x2c> 
40008780:	01 00 00 00 	nop                                            
    rv = rtems_mkdir(target, S_IRWXU | S_IRWXG | S_IRWXO);            
40008784:	40 00 02 6e 	call  4000913c <rtems_mkdir>                   
40008788:	92 10 21 ff 	mov  0x1ff, %o1	! 1ff <_TLS_Alignment+0x1fe>   
    if (rv == 0) {                                                    
4000878c:	80 a2 20 00 	cmp  %o0, 0                                    
40008790:	12 80 00 09 	bne  400087b4 <mount_and_make_target_path+0x40><== NEVER TAKEN
40008794:	01 00 00 00 	nop                                            
      rv = mount(                                                     
40008798:	40 00 00 09 	call  400087bc <mount>                         
4000879c:	81 e8 00 00 	restore                                        
        options,                                                      
        data                                                          
      );                                                              
    }                                                                 
  } else {                                                            
    errno = EINVAL;                                                   
400087a0:	40 00 61 bf 	call  40020e9c <__errno>                       
400087a4:	01 00 00 00 	nop                                            
400087a8:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
400087ac:	c2 22 00 00 	st  %g1, [ %o0 ]                               
  const char *filesystemtype,                                         
  rtems_filesystem_options_t options,                                 
  const void *data                                                    
)                                                                     
{                                                                     
  int rv = -1;                                                        
400087b0:	90 10 3f ff 	mov  -1, %o0                                   
  } else {                                                            
    errno = EINVAL;                                                   
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
400087b4:	81 c7 e0 08 	ret                                            
400087b8:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

400182dc <msdos_compare_entry_against_filename>: const uint8_t *entry, const size_t entry_size, const uint8_t *filename, const size_t filename_size_remaining, bool *is_matching) {
400182dc:	9d e3 bf 28 	save  %sp, -216, %sp                           
  ssize_t      size_remaining = filename_size_remaining;              
  int          eno            = 0;                                    
  uint8_t      entry_normalized[MSDOS_LFN_ENTRY_SIZE_UTF8];           
  size_t       bytes_in_entry_normalized = sizeof ( entry_normalized );
400182e0:	82 10 20 70 	mov  0x70, %g1                                 
400182e4:	c2 27 bf 8c 	st  %g1, [ %fp + -116 ]                        
                                                                      
  eno = (*converter->handler->utf8_normalize_and_fold) (              
400182e8:	c2 06 00 00 	ld  [ %i0 ], %g1                               
400182ec:	94 10 00 1a 	mov  %i2, %o2                                  
400182f0:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
400182f4:	90 10 00 18 	mov  %i0, %o0                                  
400182f8:	92 10 00 19 	mov  %i1, %o1                                  
400182fc:	96 07 bf 90 	add  %fp, -112, %o3                            
40018300:	9f c0 40 00 	call  %g1                                      
40018304:	98 07 bf 8c 	add  %fp, -116, %o4                            
      converter,                                                      
      &entry[0],                                                      
      entry_size,                                                     
      &entry_normalized[0],                                           
      &bytes_in_entry_normalized);                                    
  if (eno == 0) {                                                     
40018308:	b4 92 20 00 	orcc  %o0, 0, %i2                              
4001830c:	12 80 00 10 	bne  4001834c <msdos_compare_entry_against_filename+0x70><== NEVER TAKEN
40018310:	d4 07 bf 8c 	ld  [ %fp + -116 ], %o2                        
        printf ( "MSFS:[6] entry_normalized:%s"                       
                 "name:%s\n",                                         
                 entry,                                               
                 filename );                                          
#endif                                                                
        if (bytes_in_entry_normalized <= size_remaining) {            
40018314:	80 a2 80 1c 	cmp  %o2, %i4                                  
40018318:	38 80 00 10 	bgu,a   40018358 <msdos_compare_entry_against_filename+0x7c>
4001831c:	c0 2f 40 00 	clrb  [ %i5 ]                                  
            size_remaining = size_remaining - bytes_in_entry_normalized;
40018320:	b4 27 00 0a 	sub  %i4, %o2, %i2                             
            if (0 == memcmp ( &entry_normalized[0],                   
40018324:	90 07 bf 90 	add  %fp, -112, %o0                            
40018328:	40 00 12 84 	call  4001cd38 <memcmp>                        
4001832c:	92 06 c0 1a 	add  %i3, %i2, %o1                             
40018330:	80 a2 20 00 	cmp  %o0, 0                                    
40018334:	32 80 00 09 	bne,a   40018358 <msdos_compare_entry_against_filename+0x7c>
40018338:	c0 2f 40 00 	clrb  [ %i5 ]                                  
                              &filename[size_remaining],              
                              bytes_in_entry_normalized)) {           
                *is_matching = true;                                  
4001833c:	82 10 20 01 	mov  1, %g1                                    
                 "name:%s\n",                                         
                 entry,                                               
                 filename );                                          
#endif                                                                
        if (bytes_in_entry_normalized <= size_remaining) {            
            size_remaining = size_remaining - bytes_in_entry_normalized;
40018340:	b8 10 00 1a 	mov  %i2, %i4                                  
40018344:	10 80 00 05 	b  40018358 <msdos_compare_entry_against_filename+0x7c>
40018348:	c2 2f 40 00 	stb  %g1, [ %i5 ]                              
        }                                                             
    }                                                                 
                                                                      
    if (eno != 0) {                                                   
      size_remaining = -1;                                            
      errno          = eno;                                           
4001834c:	40 00 10 50 	call  4001c48c <__errno>                       <== NOT EXECUTED
40018350:	b8 10 3f ff 	mov  -1, %i4                                   <== NOT EXECUTED
40018354:	f4 22 00 00 	st  %i2, [ %o0 ]                               <== NOT EXECUTED
    }                                                                 
                                                                      
    return size_remaining;                                            
}                                                                     
40018358:	81 c7 e0 08 	ret                                            
4001835c:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
                                                                      

40017d70 <msdos_creat_node>: msdos_node_type_t type, const char *name, int name_len, mode_t mode, const fat_file_fd_t *link_fd) {
40017d70:	9d e3 bf 00 	save  %sp, -256, %sp                           
    int               rc = RC_OK;                                     
    ssize_t           ret = 0;                                        
    msdos_fs_info_t  *fs_info = parent_loc->mt_entry->fs_info;        
40017d74:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
    uint32_t          sec = 0;                                        
    uint32_t          byte = 0;                                       
                                                                      
    fat_dir_pos_init(&dir_pos);                                       
                                                                      
    memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);         
40017d78:	92 10 20 00 	clr  %o1                                       
                 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;        
40017d7c:	f8 00 60 08 	ld  [ %g1 + 8 ], %i4                           
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
40017d80:	82 10 3f ff 	mov  -1, %g1                                   
    uint32_t          sec = 0;                                        
    uint32_t          byte = 0;                                       
                                                                      
    fat_dir_pos_init(&dir_pos);                                       
                                                                      
    memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);         
40017d84:	94 10 20 20 	mov  0x20, %o2                                 
40017d88:	c2 27 bf 78 	st  %g1, [ %fp + -136 ]                        
  dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;                           
40017d8c:	c2 27 bf 7c 	st  %g1, [ %fp + -132 ]                        
                 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;        
40017d90:	e2 06 20 08 	ld  [ %i0 + 8 ], %l1                           
    fat_file_fd_t    *fat_fd = NULL;                                  
40017d94:	c0 27 bf 6c 	clr  [ %fp + -148 ]                            
    time_t            time_ret = 0;                                   
    uint16_t          time_val = 0;                                   
40017d98:	c0 37 bf 68 	clrh  [ %fp + -152 ]                           
    uint16_t          date = 0;                                       
40017d9c:	c0 37 bf 6a 	clrh  [ %fp + -150 ]                           
static inline void                                                    
fat_dir_pos_init(                                                     
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
40017da0:	c0 27 bf 70 	clr  [ %fp + -144 ]                            
  dir_pos->sname.ofs = 0;                                             
40017da4:	c0 27 bf 74 	clr  [ %fp + -140 ]                            
    uint32_t          sec = 0;                                        
    uint32_t          byte = 0;                                       
                                                                      
    fat_dir_pos_init(&dir_pos);                                       
                                                                      
    memset(short_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);         
40017da8:	a4 07 bf 80 	add  %fp, -128, %l2                            
40017dac:	40 00 14 4c 	call  4001cedc <memset>                        
40017db0:	90 10 00 12 	mov  %l2, %o0                                  
    memset(dot_dotdot, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2);     
40017db4:	90 07 bf c0 	add  %fp, -64, %o0                             
40017db8:	92 10 20 00 	clr  %o1                                       
40017dbc:	40 00 14 48 	call  4001cedc <memset>                        
40017dc0:	94 10 20 40 	mov  0x40, %o2                                 
                                                                      
    if (name_len > MSDOS_NAME_MAX_LFN_WITH_DOT) {                     
40017dc4:	80 a6 e1 04 	cmp  %i3, 0x104                                
40017dc8:	04 80 00 06 	ble  40017de0 <msdos_creat_node+0x70>          <== ALWAYS TAKEN
40017dcc:	a0 10 00 18 	mov  %i0, %l0                                  
        rtems_set_errno_and_return_minus_one(ENAMETOOLONG);           
40017dd0:	40 00 11 af 	call  4001c48c <__errno>                       <== NOT EXECUTED
40017dd4:	01 00 00 00 	nop                                            <== NOT EXECUTED
40017dd8:	10 80 00 0e 	b  40017e10 <msdos_creat_node+0xa0>            <== NOT EXECUTED
40017ddc:	82 10 20 5b 	mov  0x5b, %g1	! 5b <_TLS_Alignment+0x5a>      <== NOT EXECUTED
    }                                                                 
                                                                      
    name_type = msdos_long_to_short (fs_info->converter,              
40017de0:	d0 07 20 a4 	ld  [ %i4 + 0xa4 ], %o0                        
40017de4:	92 10 00 1a 	mov  %i2, %o1                                  
40017de8:	94 10 00 1b 	mov  %i3, %o2                                  
40017dec:	96 10 00 12 	mov  %l2, %o3                                  
40017df0:	40 00 01 87 	call  4001840c <msdos_long_to_short>           
40017df4:	98 10 20 0b 	mov  0xb, %o4                                  
                                     name, name_len,                  
                                     MSDOS_DIR_NAME(short_node),      
                                     MSDOS_NAME_MAX);                 
    if (name_type == MSDOS_NAME_INVALID) {                            
40017df8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40017dfc:	32 80 00 08 	bne,a   40017e1c <msdos_creat_node+0xac>       <== ALWAYS TAKEN
40017e00:	c0 2f bf 8c 	clrb  [ %fp + -116 ]                           
        rtems_set_errno_and_return_minus_one(EINVAL);                 
40017e04:	40 00 11 a2 	call  4001c48c <__errno>                       <== NOT EXECUTED
40017e08:	01 00 00 00 	nop                                            <== NOT EXECUTED
40017e0c:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
40017e10:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40017e14:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40017e18:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      
    /* fill reserved field */                                         
    *MSDOS_DIR_NT_RES(short_node) = MSDOS_RES_NT_VALUE;               
                                                                      
    /* set up last write date and time */                             
    time_ret = time(NULL);                                            
40017e1c:	40 00 23 3e 	call  40020b14 <time>                          
40017e20:	90 10 20 00 	clr  %o0                                       
    if ( time_ret == -1 )                                             
40017e24:	80 a2 3f ff 	cmp  %o0, -1                                   
40017e28:	02 bf ff fb 	be  40017e14 <msdos_creat_node+0xa4>           <== NEVER TAKEN
40017e2c:	92 07 bf 6a 	add  %fp, -150, %o1                            
        return -1;                                                    
                                                                      
    msdos_date_unix2dos(time_ret, &date, &time_val);                  
40017e30:	40 00 0c ea 	call  4001b1d8 <msdos_date_unix2dos>           
40017e34:	94 07 bf 68 	add  %fp, -152, %o2                            
    *MSDOS_DIR_CRT_TIME(short_node) = CT_LE_W(time_val);              
40017e38:	c2 17 bf 68 	lduh  [ %fp + -152 ], %g1                      
    *MSDOS_DIR_CRT_DATE(short_node) = CT_LE_W(date);                  
40017e3c:	c6 17 bf 6a 	lduh  [ %fp + -150 ], %g3                      
    time_ret = time(NULL);                                            
    if ( time_ret == -1 )                                             
        return -1;                                                    
                                                                      
    msdos_date_unix2dos(time_ret, &date, &time_val);                  
    *MSDOS_DIR_CRT_TIME(short_node) = CT_LE_W(time_val);              
40017e40:	83 28 60 10 	sll  %g1, 0x10, %g1                            
40017e44:	85 30 60 08 	srl  %g1, 8, %g2                               
40017e48:	83 30 60 18 	srl  %g1, 0x18, %g1                            
    *MSDOS_DIR_CRT_DATE(short_node) = CT_LE_W(date);                  
40017e4c:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
    time_ret = time(NULL);                                            
    if ( time_ret == -1 )                                             
        return -1;                                                    
                                                                      
    msdos_date_unix2dos(time_ret, &date, &time_val);                  
    *MSDOS_DIR_CRT_TIME(short_node) = CT_LE_W(time_val);              
40017e50:	84 10 80 01 	or  %g2, %g1, %g2                              
    *MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);            
    *MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);                
    *MSDOS_DIR_LAST_ACCESS_DATE(short_node) = CT_LE_W(date);          
                                                                      
    /* initialize directory/file size */                              
    *MSDOS_DIR_FILE_SIZE(short_node) = MSDOS_INIT_DIR_SIZE;           
40017e54:	c0 27 bf 9c 	clr  [ %fp + -100 ]                            
    if ( time_ret == -1 )                                             
        return -1;                                                    
                                                                      
    msdos_date_unix2dos(time_ret, &date, &time_val);                  
    *MSDOS_DIR_CRT_TIME(short_node) = CT_LE_W(time_val);              
    *MSDOS_DIR_CRT_DATE(short_node) = CT_LE_W(date);                  
40017e58:	83 30 e0 08 	srl  %g3, 8, %g1                               
    time_ret = time(NULL);                                            
    if ( time_ret == -1 )                                             
        return -1;                                                    
                                                                      
    msdos_date_unix2dos(time_ret, &date, &time_val);                  
    *MSDOS_DIR_CRT_TIME(short_node) = CT_LE_W(time_val);              
40017e5c:	c4 37 bf 8e 	sth  %g2, [ %fp + -114 ]                       
    *MSDOS_DIR_CRT_DATE(short_node) = CT_LE_W(date);                  
40017e60:	87 30 e0 18 	srl  %g3, 0x18, %g3                            
    *MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);            
40017e64:	c4 37 bf 96 	sth  %g2, [ %fp + -106 ]                       
    if ( time_ret == -1 )                                             
        return -1;                                                    
                                                                      
    msdos_date_unix2dos(time_ret, &date, &time_val);                  
    *MSDOS_DIR_CRT_TIME(short_node) = CT_LE_W(time_val);              
    *MSDOS_DIR_CRT_DATE(short_node) = CT_LE_W(date);                  
40017e68:	82 10 40 03 	or  %g1, %g3, %g1                              
40017e6c:	c2 37 bf 90 	sth  %g1, [ %fp + -112 ]                       
    *MSDOS_DIR_WRITE_TIME(short_node) = CT_LE_W(time_val);            
    *MSDOS_DIR_WRITE_DATE(short_node) = CT_LE_W(date);                
40017e70:	c2 37 bf 98 	sth  %g1, [ %fp + -104 ]                       
    *MSDOS_DIR_LAST_ACCESS_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) {                                    
40017e74:	80 a6 60 00 	cmp  %i1, 0                                    
40017e78:	12 80 00 05 	bne  40017e8c <msdos_creat_node+0x11c>         
40017e7c:	c2 37 bf 92 	sth  %g1, [ %fp + -110 ]                       
      *MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_DIRECTORY;            
40017e80:	c2 0f bf 8b 	ldub  [ %fp + -117 ], %g1                      
40017e84:	10 80 00 2e 	b  40017f3c <msdos_creat_node+0x1cc>           
40017e88:	82 10 60 10 	or  %g1, 0x10, %g1                             
    }                                                                 
    else if (type == MSDOS_HARD_LINK) {                               
40017e8c:	80 a6 60 02 	cmp  %i1, 2                                    
40017e90:	12 80 00 2a 	bne  40017f38 <msdos_creat_node+0x1c8>         <== ALWAYS TAKEN
40017e94:	c2 0f bf 8b 	ldub  [ %fp + -117 ], %g1                      
       * node to the newly created                                    
       */                                                             
      /*                                                              
       * read the original directory entry                            
       */                                                             
      sec = fat_cluster_num_to_sector_num(&fs_info->fat,              
40017e98:	c4 07 60 20 	ld  [ %i5 + 0x20 ], %g2                        <== NOT EXECUTED
fat_cluster_num_to_sector_num(                                        
    const fat_fs_info_t *fs_info,                                     
    uint32_t             cln                                          
    )                                                                 
{                                                                     
    if ( (cln == 0) && (fs_info->vol.type & (FAT_FAT12 | FAT_FAT16)) )
40017e9c:	80 a0 a0 00 	cmp  %g2, 0                                    <== NOT EXECUTED
40017ea0:	32 80 00 08 	bne,a   40017ec0 <msdos_creat_node+0x150>      <== NOT EXECUTED
40017ea4:	c2 0f 20 05 	ldub  [ %i4 + 5 ], %g1                         <== NOT EXECUTED
40017ea8:	c2 0f 20 0e 	ldub  [ %i4 + 0xe ], %g1                       <== NOT EXECUTED
40017eac:	80 88 60 03 	btst  3, %g1                                   <== NOT EXECUTED
40017eb0:	22 80 00 04 	be,a   40017ec0 <msdos_creat_node+0x150>       <== NOT EXECUTED
40017eb4:	c2 0f 20 05 	ldub  [ %i4 + 5 ], %g1                         <== NOT EXECUTED
        return fs_info->vol.rdir_loc;                                 
40017eb8:	10 80 00 06 	b  40017ed0 <msdos_creat_node+0x160>           <== NOT EXECUTED
40017ebc:	c4 07 20 20 	ld  [ %i4 + 0x20 ], %g2                        <== NOT EXECUTED
                                                                      
    return (((cln - FAT_RSRVD_CLN) << fs_info->vol.spc_log2) +        
40017ec0:	84 00 bf fe 	add  %g2, -2, %g2                              <== NOT EXECUTED
40017ec4:	85 28 80 01 	sll  %g2, %g1, %g2                             <== NOT EXECUTED
40017ec8:	c2 07 20 34 	ld  [ %i4 + 0x34 ], %g1                        <== NOT EXECUTED
40017ecc:	84 00 80 01 	add  %g2, %g1, %g2                             <== NOT EXECUTED
                                          link_fd->dir_pos.sname.cln);
      sec += (link_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
40017ed0:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        <== NOT EXECUTED
40017ed4:	d2 0f 20 02 	ldub  [ %i4 + 2 ], %o1                         <== NOT EXECUTED
      byte = (link_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
40017ed8:	d4 17 00 00 	lduh  [ %i4 ], %o2                             <== NOT EXECUTED
      /*                                                              
       * read the original directory entry                            
       */                                                             
      sec = fat_cluster_num_to_sector_num(&fs_info->fat,              
                                          link_fd->dir_pos.sname.cln);
      sec += (link_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);
40017edc:	93 30 40 09 	srl  %g1, %o1, %o1                             <== NOT EXECUTED
      byte = (link_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1));
40017ee0:	94 02 bf ff 	add  %o2, -1, %o2                              <== NOT EXECUTED
                                                                      
      ret = _fat_block_read(&fs_info->fat,                            
40017ee4:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
40017ee8:	92 00 80 09 	add  %g2, %o1, %o1                             <== NOT EXECUTED
40017eec:	94 0a 80 01 	and  %o2, %g1, %o2                             <== NOT EXECUTED
40017ef0:	96 10 20 20 	mov  0x20, %o3                                 <== NOT EXECUTED
40017ef4:	7f ff ec 8a 	call  4001311c <_fat_block_read>               <== NOT EXECUTED
40017ef8:	98 07 bf a0 	add  %fp, -96, %o4                             <== NOT EXECUTED
                            sec, byte, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE,
                            link_node);                               
      if (ret < 0) {                                                  
40017efc:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40017f00:	06 bf ff c5 	bl  40017e14 <msdos_creat_node+0xa4>           <== NOT EXECUTED
40017f04:	c4 0f bf ad 	ldub  [ %fp + -83 ], %g2                       <== NOT EXECUTED
          return -1;                                                  
      }                                                               
      /*                                                              
       * copy various attributes                                      
       */                                                             
      *MSDOS_DIR_ATTR(short_node)          =*MSDOS_DIR_ATTR(link_node);
40017f08:	c2 0f bf ab 	ldub  [ %fp + -85 ], %g1                       <== NOT EXECUTED
      *MSDOS_DIR_CRT_TIME_TENTH(short_node)=*MSDOS_DIR_CRT_TIME_TENTH(link_node);
40017f0c:	c4 2f bf 8d 	stb  %g2, [ %fp + -115 ]                       <== NOT EXECUTED
      *MSDOS_DIR_CRT_TIME(short_node)      =*MSDOS_DIR_CRT_TIME(link_node);
40017f10:	c4 17 bf ae 	lduh  [ %fp + -82 ], %g2                       <== NOT EXECUTED
40017f14:	c4 37 bf 8e 	sth  %g2, [ %fp + -114 ]                       <== NOT EXECUTED
      *MSDOS_DIR_CRT_DATE(short_node)      =*MSDOS_DIR_CRT_DATE(link_node);
40017f18:	c4 17 bf b0 	lduh  [ %fp + -80 ], %g2                       <== NOT EXECUTED
40017f1c:	c4 37 bf 90 	sth  %g2, [ %fp + -112 ]                       <== NOT EXECUTED
                                                                      
      /*                                                              
       * copy/set "file size", "first cluster"                        
       */                                                             
      *MSDOS_DIR_FILE_SIZE(short_node)     =*MSDOS_DIR_FILE_SIZE(link_node);
40017f20:	c4 07 bf bc 	ld  [ %fp + -68 ], %g2                         <== NOT EXECUTED
40017f24:	c4 27 bf 9c 	st  %g2, [ %fp + -100 ]                        <== NOT EXECUTED
                                                                      
      *MSDOS_DIR_FIRST_CLUSTER_LOW(short_node) =                      
40017f28:	c4 17 bf ba 	lduh  [ %fp + -70 ], %g2                       <== NOT EXECUTED
40017f2c:	c4 37 bf 9a 	sth  %g2, [ %fp + -102 ]                       <== NOT EXECUTED
           *MSDOS_DIR_FIRST_CLUSTER_LOW(link_node);                   
      *MSDOS_DIR_FIRST_CLUSTER_HI(short_node) =                       
40017f30:	c4 17 bf b4 	lduh  [ %fp + -76 ], %g2                       <== NOT EXECUTED
40017f34:	c4 37 bf 94 	sth  %g2, [ %fp + -108 ]                       <== NOT EXECUTED
       * set "archive bit" due to changes                             
       */                                                             
      *MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;              
    }                                                                 
    else { /* regular file... */                                      
        *MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;            
40017f38:	82 10 60 20 	or  %g1, 0x20, %g1                             
                                                                      
    /*                                                                
     * 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,        
40017f3c:	98 10 00 18 	mov  %i0, %o4                                  
       * set "archive bit" due to changes                             
       */                                                             
      *MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;              
    }                                                                 
    else { /* regular file... */                                      
        *MSDOS_DIR_ATTR(short_node) |= MSDOS_ATTR_ARCHIVE;            
40017f40:	c2 2f bf 8b 	stb  %g1, [ %fp + -117 ]                       
                                                                      
    /*                                                                
     * 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,        
40017f44:	e4 23 a0 5c 	st  %l2, [ %sp + 0x5c ]                        
40017f48:	90 10 00 10 	mov  %l0, %o0                                  
40017f4c:	92 10 20 01 	mov  1, %o1                                    
40017f50:	94 10 00 1a 	mov  %i2, %o2                                  
40017f54:	96 10 00 1b 	mov  %i3, %o3                                  
40017f58:	40 00 07 54 	call  40019ca8 <msdos_get_name_node>           
40017f5c:	9a 07 bf 70 	add  %fp, -144, %o5                            
                             name_type, &dir_pos, short_node);        
    if ( rc != RC_OK )                                                
40017f60:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40017f64:	12 80 00 62 	bne  400180ec <msdos_creat_node+0x37c>         
40017f68:	80 a6 60 00 	cmp  %i1, 0                                    
                                                                      
    /*                                                                
     * if we create a new file we are done, if directory there are more steps
     * to do                                                          
     */                                                               
    if (type == MSDOS_DIRECTORY)                                      
40017f6c:	12 80 00 60 	bne  400180ec <msdos_creat_node+0x37c>         
40017f70:	90 10 00 1c 	mov  %i4, %o0                                  
    {                                                                 
        /* open new directory as fat-file */                          
        rc = fat_file_open(&fs_info->fat, &dir_pos, &fat_fd);         
40017f74:	92 07 bf 70 	add  %fp, -144, %o1                            
40017f78:	7f ff e8 cc 	call  400122a8 <fat_file_open>                 
40017f7c:	94 07 bf 6c 	add  %fp, -148, %o2                            
        if (rc != RC_OK)                                              
40017f80:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40017f84:	32 80 00 61 	bne,a   40018108 <msdos_creat_node+0x398>      <== NEVER TAKEN
40017f88:	d0 04 20 14 	ld  [ %l0 + 0x14 ], %o0                        <== NOT EXECUTED
                                                                      
        /*                                                            
         * we opened fat-file for node we just created, so initialize fat-file
         * descritor                                                  
         */                                                           
        fat_fd->fat_file_size = 0;                                    
40017f8c:	fa 07 bf 6c 	ld  [ %fp + -148 ], %i5                        
        fat_fd->fat_file_type = FAT_DIRECTORY;                        
        fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                    
40017f90:	03 00 08 00 	sethi  %hi(0x200000), %g1                      
                                                                      
        /*                                                            
         * dot and dotdot entries are identical to new node except the
         * names                                                      
         */                                                           
        memcpy(DOT_NODE_P(dot_dotdot), short_node,                    
40017f94:	92 10 00 12 	mov  %l2, %o1                                  
         * 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;                        
        fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                    
40017f98:	c2 27 60 14 	st  %g1, [ %i5 + 0x14 ]                        
                                                                      
        /*                                                            
         * dot and dotdot entries are identical to new node except the
         * names                                                      
         */                                                           
        memcpy(DOT_NODE_P(dot_dotdot), short_node,                    
40017f9c:	94 10 20 20 	mov  0x20, %o2                                 
                                                                      
        /*                                                            
         * we opened fat-file for node we just created, so initialize fat-file
         * descritor                                                  
         */                                                           
        fat_fd->fat_file_size = 0;                                    
40017fa0:	c0 27 60 18 	clr  [ %i5 + 0x18 ]                            
        fat_fd->fat_file_type = FAT_DIRECTORY;                        
40017fa4:	c0 27 60 10 	clr  [ %i5 + 0x10 ]                            
                                                                      
        /*                                                            
         * dot and dotdot entries are identical to new node except the
         * names                                                      
         */                                                           
        memcpy(DOT_NODE_P(dot_dotdot), short_node,                    
40017fa8:	40 00 13 8e 	call  4001cde0 <memcpy>                        
40017fac:	90 07 bf c0 	add  %fp, -64, %o0                             
               MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);                    
        memcpy(DOTDOT_NODE_P(dot_dotdot), short_node,                 
40017fb0:	92 10 00 12 	mov  %l2, %o1                                  
40017fb4:	94 10 20 20 	mov  0x20, %o2                                 
40017fb8:	40 00 13 8a 	call  4001cde0 <memcpy>                        
40017fbc:	90 07 bf e0 	add  %fp, -32, %o0                             
               MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);                    
        memcpy(MSDOS_DIR_NAME(DOT_NODE_P(dot_dotdot)), MSDOS_DOT_NAME,
40017fc0:	03 10 00 b5 	sethi  %hi(0x4002d400), %g1                    
40017fc4:	d2 00 60 7c 	ld  [ %g1 + 0x7c ], %o1	! 4002d47c <MSDOS_DOT_NAME>
40017fc8:	94 10 20 0b 	mov  0xb, %o2                                  
40017fcc:	40 00 13 85 	call  4001cde0 <memcpy>                        
40017fd0:	90 07 bf c0 	add  %fp, -64, %o0                             
               MSDOS_NAME_MAX);                                       
        memcpy(MSDOS_DIR_NAME(DOTDOT_NODE_P(dot_dotdot)), MSDOS_DOTDOT_NAME,
40017fd4:	03 10 00 b5 	sethi  %hi(0x4002d400), %g1                    
40017fd8:	d2 00 60 78 	ld  [ %g1 + 0x78 ], %o1	! 4002d478 <MSDOS_DOTDOT_NAME>
40017fdc:	90 07 bf e0 	add  %fp, -32, %o0                             
40017fe0:	40 00 13 80 	call  4001cde0 <memcpy>                        
40017fe4:	94 10 20 0b 	mov  0xb, %o2                                  
        /*                                                            
         * 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)) &&                    
40017fe8:	c2 04 60 20 	ld  [ %l1 + 0x20 ], %g1                        
40017fec:	80 a0 60 01 	cmp  %g1, 1                                    
40017ff0:	32 80 00 0d 	bne,a   40018024 <msdos_creat_node+0x2b4>      
40017ff4:	c4 14 60 1e 	lduh  [ %l1 + 0x1e ], %g2                      
40017ff8:	c2 04 60 24 	ld  [ %l1 + 0x24 ], %g1                        
40017ffc:	80 a0 60 00 	cmp  %g1, 0                                    
40018000:	32 80 00 09 	bne,a   40018024 <msdos_creat_node+0x2b4>      <== NEVER TAKEN
40018004:	c4 14 60 1e 	lduh  [ %l1 + 0x1e ], %g2                      <== NOT EXECUTED
            (fs_info->fat.vol.type & FAT_FAT32))                      
40018008:	c2 0f 20 0e 	ldub  [ %i4 + 0xe ], %g1                       
        /*                                                            
         * 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)) &&                    
4001800c:	80 88 60 04 	btst  4, %g1                                   
40018010:	22 80 00 05 	be,a   40018024 <msdos_creat_node+0x2b4>       <== ALWAYS TAKEN
40018014:	c4 14 60 1e 	lduh  [ %l1 + 0x1e ], %g2                      
            (fs_info->fat.vol.type & FAT_FAT32))                      
        {                                                             
            *MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
40018018:	c0 37 bf fa 	clrh  [ %fp + -6 ]                             <== NOT EXECUTED
            *MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) = 0x0000;
4001801c:	10 80 00 0c 	b  4001804c <msdos_creat_node+0x2dc>           <== NOT EXECUTED
40018020:	c0 37 bf f4 	clrh  [ %fp + -12 ]                            <== NOT EXECUTED
        }                                                             
        else                                                          
        {                                                             
            *MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 
40018024:	c6 0c 60 1e 	ldub  [ %l1 + 0x1e ], %g3                      
40018028:	c2 04 60 1c 	ld  [ %l1 + 0x1c ], %g1                        
                CT_LE_W((uint16_t  )((parent_fat_fd->cln) & 0x0000FFFF));
4001802c:	85 28 a0 08 	sll  %g2, 8, %g2                               
            *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)) = 
40018030:	84 10 80 03 	or  %g2, %g3, %g2                              
                CT_LE_W((uint16_t  )((parent_fat_fd->cln) & 0x0000FFFF));
            *MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =  
                CT_LE_W((uint16_t  )(((parent_fat_fd->cln) & 0xFFFF0000)>>16));
40018034:	83 30 60 10 	srl  %g1, 0x10, %g1                            
            *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)) = 
40018038:	c4 37 bf fa 	sth  %g2, [ %fp + -6 ]                         
                CT_LE_W((uint16_t  )((parent_fat_fd->cln) & 0x0000FFFF));
            *MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =  
4001803c:	85 30 60 08 	srl  %g1, 8, %g2                               
                CT_LE_W((uint16_t  )(((parent_fat_fd->cln) & 0xFFFF0000)>>16));
40018040:	83 28 60 08 	sll  %g1, 8, %g1                               
        }                                                             
        else                                                          
        {                                                             
            *MSDOS_DIR_FIRST_CLUSTER_LOW(DOTDOT_NODE_P(dot_dotdot)) = 
                CT_LE_W((uint16_t  )((parent_fat_fd->cln) & 0x0000FFFF));
            *MSDOS_DIR_FIRST_CLUSTER_HI(DOTDOT_NODE_P(dot_dotdot)) =  
40018044:	82 10 80 01 	or  %g2, %g1, %g1                              
40018048:	c2 37 bf f4 	sth  %g1, [ %fp + -12 ]                        
        /*                                                            
         * 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(&fs_info->fat, fat_fd, 0,                
4001804c:	90 10 00 1c 	mov  %i4, %o0                                  
40018050:	92 10 00 1d 	mov  %i5, %o1                                  
40018054:	94 10 20 00 	clr  %o2                                       
40018058:	96 10 20 40 	mov  0x40, %o3                                 
4001805c:	7f ff ea 9c 	call  40012acc <fat_file_write>                
40018060:	98 07 bf c0 	add  %fp, -64, %o4                             
                             MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2,   
                             (uint8_t *)dot_dotdot);                  
        if (ret < 0)                                                  
40018064:	80 a2 20 00 	cmp  %o0, 0                                    
40018068:	06 80 00 23 	bl  400180f4 <msdos_creat_node+0x384>          <== NEVER TAKEN
4001806c:	d2 07 bf 6c 	ld  [ %fp + -148 ], %o1                        
            rc = -1;                                                  
            goto error;                                               
        }                                                             
                                                                      
        /* increment fat-file size by cluster size */                 
        fat_fd->fat_file_size += fs_info->fat.vol.bpc;                
40018070:	c2 17 20 06 	lduh  [ %i4 + 6 ], %g1                         
40018074:	c4 02 60 18 	ld  [ %o1 + 0x18 ], %g2                        
                                                                      
        /* set up cluster num for dot entry */                        
        *MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =        
40018078:	c6 0a 60 1e 	ldub  [ %o1 + 0x1e ], %g3                      
            rc = -1;                                                  
            goto error;                                               
        }                                                             
                                                                      
        /* increment fat-file size by cluster size */                 
        fat_fd->fat_file_size += fs_info->fat.vol.bpc;                
4001807c:	82 00 80 01 	add  %g2, %g1, %g1                             
40018080:	c4 12 60 1e 	lduh  [ %o1 + 0x1e ], %g2                      
40018084:	c2 22 60 18 	st  %g1, [ %o1 + 0x18 ]                        
                                                                      
        /* set up cluster num for dot entry */                        
        *MSDOS_DIR_FIRST_CLUSTER_LOW(DOT_NODE_P(dot_dotdot)) =        
40018088:	c2 02 60 1c 	ld  [ %o1 + 0x1c ], %g1                        
                CT_LE_W((uint16_t  )((fat_fd->cln) & 0x0000FFFF));    
4001808c:	85 28 a0 08 	sll  %g2, 8, %g2                               
                                                                      
        /* 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)) =        
40018090:	84 10 80 03 	or  %g2, %g3, %g2                              
                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));
40018094:	83 30 60 10 	srl  %g1, 0x10, %g1                            
                                                                      
        /* 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)) =        
40018098:	c4 37 bf da 	sth  %g2, [ %fp + -38 ]                        
                CT_LE_W((uint16_t  )((fat_fd->cln) & 0x0000FFFF));    
        *MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =         
4001809c:	85 30 60 08 	srl  %g1, 8, %g2                               
                CT_LE_W((uint16_t  )(((fat_fd->cln) & 0xFFFF0000) >> 16));
400180a0:	83 28 60 08 	sll  %g1, 8, %g1                               
        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)) =        
                CT_LE_W((uint16_t  )((fat_fd->cln) & 0x0000FFFF));    
        *MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =         
400180a4:	82 10 80 01 	or  %g2, %g1, %g1                              
                CT_LE_W((uint16_t  )(((fat_fd->cln) & 0xFFFF0000) >> 16));
                                                                      
        /* rewrite dot entry */                                       
        ret = fat_file_write(&fs_info->fat, fat_fd, 0,                
400180a8:	90 10 00 1c 	mov  %i4, %o0                                  
        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)) =        
                CT_LE_W((uint16_t  )((fat_fd->cln) & 0x0000FFFF));    
        *MSDOS_DIR_FIRST_CLUSTER_HI(DOT_NODE_P(dot_dotdot)) =         
400180ac:	c2 37 bf d4 	sth  %g1, [ %fp + -44 ]                        
                CT_LE_W((uint16_t  )(((fat_fd->cln) & 0xFFFF0000) >> 16));
                                                                      
        /* rewrite dot entry */                                       
        ret = fat_file_write(&fs_info->fat, fat_fd, 0,                
400180b0:	94 10 20 00 	clr  %o2                                       
400180b4:	96 10 20 20 	mov  0x20, %o3                                 
400180b8:	7f ff ea 85 	call  40012acc <fat_file_write>                
400180bc:	98 07 bf c0 	add  %fp, -64, %o4                             
                             MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE,       
                             (uint8_t *)DOT_NODE_P(dot_dotdot));      
        if (ret < 0)                                                  
400180c0:	80 a2 20 00 	cmp  %o0, 0                                    
400180c4:	06 80 00 0d 	bl  400180f8 <msdos_creat_node+0x388>          <== NEVER TAKEN
400180c8:	b0 10 3f ff 	mov  -1, %i0                                   
            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);
400180cc:	d0 04 20 14 	ld  [ %l0 + 0x14 ], %o0                        
400180d0:	40 00 01 a6 	call  40018768 <msdos_set_first_cluster_num>   
400180d4:	d2 07 bf 6c 	ld  [ %fp + -148 ], %o1                        
        if (rc != RC_OK)                                              
400180d8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400180dc:	12 80 00 08 	bne  400180fc <msdos_creat_node+0x38c>         <== NEVER TAKEN
400180e0:	d2 07 bf 6c 	ld  [ %fp + -148 ], %o1                        
            goto error;                                               
                                                                      
        fat_file_close(&fs_info->fat, fat_fd);                        
400180e4:	7f ff e9 89 	call  40012708 <fat_file_close>                
400180e8:	90 10 00 1c 	mov  %i4, %o0                                  
400180ec:	81 c7 e0 08 	ret                                            
400180f0:	81 e8 00 00 	restore                                        
        ret = fat_file_write(&fs_info->fat, fat_fd, 0,                
                             MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE * 2,   
                             (uint8_t *)dot_dotdot);                  
        if (ret < 0)                                                  
        {                                                             
            rc = -1;                                                  
400180f4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
        fat_file_close(&fs_info->fat, fat_fd);                        
    }                                                                 
    return RC_OK;                                                     
                                                                      
error:                                                                
    fat_file_close(&fs_info->fat, fat_fd);                            
400180f8:	d2 07 bf 6c 	ld  [ %fp + -148 ], %o1                        <== NOT EXECUTED
400180fc:	7f ff e9 83 	call  40012708 <fat_file_close>                <== NOT EXECUTED
40018100:	90 10 00 1c 	mov  %i4, %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);
40018104:	d0 04 20 14 	ld  [ %l0 + 0x14 ], %o0                        <== NOT EXECUTED
40018108:	92 07 bf 70 	add  %fp, -144, %o1                            <== NOT EXECUTED
4001810c:	40 00 01 dd 	call  40018880 <msdos_set_first_char4file_name><== NOT EXECUTED
40018110:	94 10 20 e5 	mov  0xe5, %o2                                 <== NOT EXECUTED
    return rc;                                                        
}                                                                     
40018114:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40018118:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001b320 <msdos_date_dos2unix>: uint32_t days; uint16_t *months; seconds = 2 * ((dt & MSDOS_DT_2SECONDS_MASK) >> MSDOS_DT_2SECONDS_SHIFT) + ((dt & MSDOS_DT_MINUTES_MASK) >> MSDOS_DT_MINUTES_SHIFT) * 60 + ((dt & MSDOS_DT_HOURS_MASK) >> MSDOS_DT_HOURS_SHIFT) * 3600;
4001b320:	85 32 60 0b 	srl  %o1, 0xb, %g2                             
4001b324:	84 08 a0 1f 	and  %g2, 0x1f, %g2                            
4001b328:	87 28 a0 03 	sll  %g2, 3, %g3                               
4001b32c:	83 28 a0 07 	sll  %g2, 7, %g1                               
4001b330:	82 20 40 03 	sub  %g1, %g3, %g1                             
4001b334:	85 28 60 04 	sll  %g1, 4, %g2                               
4001b338:	84 20 80 01 	sub  %g2, %g1, %g2                             
	uint32_t y, year;                                                    
	uint32_t days;                                                       
	uint16_t *months;                                                    
                                                                      
	seconds = 2 * ((dt & MSDOS_DT_2SECONDS_MASK) >> MSDOS_DT_2SECONDS_SHIFT)
	    + ((dt & MSDOS_DT_MINUTES_MASK) >> MSDOS_DT_MINUTES_SHIFT) * 60  
4001b33c:	82 0a 67 e0 	and  %o1, 0x7e0, %g1                           
4001b340:	87 30 60 04 	srl  %g1, 4, %g3                               
4001b344:	82 20 40 03 	sub  %g1, %g3, %g1                             
	    + ((dt & MSDOS_DT_HOURS_MASK) >> MSDOS_DT_HOURS_SHIFT) * 3600;   
4001b348:	82 00 80 01 	add  %g2, %g1, %g1                             
	uint32_t m, month;                                                   
	uint32_t y, year;                                                    
	uint32_t days;                                                       
	uint16_t *months;                                                    
                                                                      
	seconds = 2 * ((dt & MSDOS_DT_2SECONDS_MASK) >> MSDOS_DT_2SECONDS_SHIFT)
4001b34c:	92 0a 60 1f 	and  %o1, 0x1f, %o1                            
	    + ((dt & MSDOS_DT_MINUTES_MASK) >> MSDOS_DT_MINUTES_SHIFT) * 60  
	    + ((dt & MSDOS_DT_HOURS_MASK) >> MSDOS_DT_HOURS_SHIFT) * 3600;   
4001b350:	92 00 40 09 	add  %g1, %o1, %o1                             
	/*                                                                   
	 * If the year, month, and day from the last conversion are the      
	 * same then use the saved value.                                    
	 */                                                                  
	if (lastdosdate != dd) {                                             
4001b354:	03 10 00 bc 	sethi  %hi(0x4002f000), %g1                    
4001b358:	c4 10 60 4c 	lduh  [ %g1 + 0x4c ], %g2	! 4002f04c <lastdosdate>
4001b35c:	80 a0 80 08 	cmp  %g2, %o0                                  
4001b360:	02 80 00 34 	be  4001b430 <msdos_date_dos2unix+0x110>       
4001b364:	93 2a 60 01 	sll  %o1, 1, %o1                               
		lastdosdate = dd;                                                   
4001b368:	d0 30 60 4c 	sth  %o0, [ %g1 + 0x4c ]                       
		days = 0;                                                           
		year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;            
4001b36c:	89 32 20 09 	srl  %o0, 9, %g4                               
	 * If the year, month, and day from the last conversion are the      
	 * same then use the saved value.                                    
	 */                                                                  
	if (lastdosdate != dd) {                                             
		lastdosdate = dd;                                                   
		days = 0;                                                           
4001b370:	82 10 20 00 	clr  %g1                                       
		year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;            
4001b374:	88 09 20 7f 	and  %g4, 0x7f, %g4                            
		for (y = 0; y < year; y++)                                          
4001b378:	84 10 20 00 	clr  %g2                                       
4001b37c:	80 a0 80 04 	cmp  %g2, %g4                                  
4001b380:	02 80 00 08 	be  4001b3a0 <msdos_date_dos2unix+0x80>        
4001b384:	86 08 a0 03 	and  %g2, 3, %g3                               
			days += y & 0x03 ? 365 : 366;                                      
4001b388:	80 a0 00 03 	cmp  %g0, %g3                                  
	 */                                                                  
	if (lastdosdate != dd) {                                             
		lastdosdate = dd;                                                   
		days = 0;                                                           
		year = (dd & MSDOS_DD_YEAR_MASK) >> MSDOS_DD_YEAR_SHIFT;            
		for (y = 0; y < year; y++)                                          
4001b38c:	84 00 a0 01 	inc  %g2                                       
			days += y & 0x03 ? 365 : 366;                                      
4001b390:	86 60 3f ff 	subx  %g0, -1, %g3                             
4001b394:	86 00 e1 6d 	add  %g3, 0x16d, %g3                           
4001b398:	10 bf ff f9 	b  4001b37c <msdos_date_dos2unix+0x5c>         
4001b39c:	82 00 40 03 	add  %g1, %g3, %g1                             
		months = year & 0x03 ? regyear : leapyear;                          
4001b3a0:	80 a0 e0 00 	cmp  %g3, 0                                    
4001b3a4:	22 80 00 05 	be,a   4001b3b8 <msdos_date_dos2unix+0x98>     
4001b3a8:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
4001b3ac:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
4001b3b0:	10 80 00 03 	b  4001b3bc <msdos_date_dos2unix+0x9c>         
4001b3b4:	88 11 21 f4 	or  %g4, 0x1f4, %g4	! 4002ddf4 <regyear>       
4001b3b8:	88 11 21 dc 	or  %g4, 0x1dc, %g4                            
		/*                                                                  
		 * Prevent going from 0 to 0xffffffff in the following              
		 * loop.                                                            
		 */                                                                 
		month = (dd & MSDOS_DD_MONTH_MASK) >> MSDOS_DD_MONTH_SHIFT;         
4001b3bc:	86 0a 21 e0 	and  %o0, 0x1e0, %g3                           
4001b3c0:	87 30 e0 05 	srl  %g3, 5, %g3                               
		if (month == 0) {                                                   
4001b3c4:	80 a0 e0 00 	cmp  %g3, 0                                    
4001b3c8:	22 80 00 02 	be,a   4001b3d0 <msdos_date_dos2unix+0xb0>     <== NEVER TAKEN
4001b3cc:	86 10 20 01 	mov  1, %g3                                    <== NOT EXECUTED
			month = 1;                                                         
		}                                                                   
		for (m = 0; m < month - 1; m++)                                     
4001b3d0:	84 10 20 00 	clr  %g2                                       
4001b3d4:	86 00 ff ff 	add  %g3, -1, %g3                              
4001b3d8:	80 a0 80 03 	cmp  %g2, %g3                                  
4001b3dc:	1a 80 00 06 	bcc  4001b3f4 <msdos_date_dos2unix+0xd4>       
4001b3e0:	9b 28 a0 01 	sll  %g2, 1, %o5                               
			days += months[m];                                                 
4001b3e4:	da 11 00 0d 	lduh  [ %g4 + %o5 ], %o5                       
		 */                                                                 
		month = (dd & MSDOS_DD_MONTH_MASK) >> MSDOS_DD_MONTH_SHIFT;         
		if (month == 0) {                                                   
			month = 1;                                                         
		}                                                                   
		for (m = 0; m < month - 1; m++)                                     
4001b3e8:	84 00 a0 01 	inc  %g2                                       
			days += months[m];                                                 
4001b3ec:	10 bf ff fb 	b  4001b3d8 <msdos_date_dos2unix+0xb8>         
4001b3f0:	82 00 40 0d 	add  %g1, %o5, %g1                             
		days += ((dd & MSDOS_DD_DAY_MASK) >> MSDOS_DD_DAY_SHIFT) - 1;       
4001b3f4:	90 0a 20 1f 	and  %o0, 0x1f, %o0                            
4001b3f8:	90 02 3f ff 	add  %o0, -1, %o0                              
4001b3fc:	82 02 00 01 	add  %o0, %g1, %g1                             
		lastseconds = (days + DAYSTO1980) * SECONDSPERDAY;                  
4001b400:	85 28 60 07 	sll  %g1, 7, %g2                               
4001b404:	83 28 60 09 	sll  %g1, 9, %g1                               
4001b408:	82 20 40 02 	sub  %g1, %g2, %g1                             
4001b40c:	85 28 60 04 	sll  %g1, 4, %g2                               
4001b410:	82 20 80 01 	sub  %g2, %g1, %g1                             
4001b414:	85 28 60 04 	sll  %g1, 4, %g2                               
4001b418:	82 20 80 01 	sub  %g2, %g1, %g1                             
4001b41c:	05 04 b3 a9 	sethi  %hi(0x12cea400), %g2                    
4001b420:	84 10 a2 00 	or  %g2, 0x200, %g2	! 12cea600 <RAM_SIZE+0x128ea600>
4001b424:	82 00 40 02 	add  %g1, %g2, %g1                             
4001b428:	05 10 00 bc 	sethi  %hi(0x4002f000), %g2                    
4001b42c:	c2 20 a0 48 	st  %g1, [ %g2 + 0x48 ]	! 4002f048 <lastseconds>
	}                                                                    
	return seconds + lastseconds;                                        
4001b430:	03 10 00 bc 	sethi  %hi(0x4002f000), %g1                    
4001b434:	d0 00 60 48 	ld  [ %g1 + 0x48 ], %o0	! 4002f048 <lastseconds>
}                                                                     
4001b438:	81 c3 e0 08 	retl                                           
4001b43c:	90 02 40 08 	add  %o1, %o0, %o0                             
                                                                      

4001b1d8 <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) {
4001b1d8:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
	/*                                                                   
	 * If the time from the last conversion is the same as now, then     
	 * skip the computations and use the saved result.                   
	 */                                                                  
	if (lasttime != t) {                                                 
4001b1dc:	03 10 00 bc 	sethi  %hi(0x4002f000), %g1                    
4001b1e0:	c4 00 60 58 	ld  [ %g1 + 0x58 ], %g2	! 4002f058 <lasttime>  
4001b1e4:	80 a0 80 18 	cmp  %g2, %i0                                  
4001b1e8:	02 80 00 47 	be  4001b304 <msdos_date_unix2dos+0x12c>       
4001b1ec:	3b 10 00 bc 	sethi  %hi(0x4002f000), %i5                    
		lasttime = t;                                                       
4001b1f0:	f0 20 60 58 	st  %i0, [ %g1 + 0x58 ]                        
		lastdtime = (((t % 60) >> 1) << MSDOS_DT_2SECONDS_SHIFT)            
		    + (((t / 60) % 60) << MSDOS_DT_MINUTES_SHIFT)                   
4001b1f4:	92 10 20 3c 	mov  0x3c, %o1                                 
4001b1f8:	7f ff 9d 80 	call  400027f8 <.udiv>                         
4001b1fc:	90 10 00 18 	mov  %i0, %o0                                  
4001b200:	40 00 39 9e 	call  40029878 <.urem>                         
4001b204:	92 10 20 3c 	mov  0x3c, %o1                                 
		    + (((t / 3600) % 24) << MSDOS_DT_HOURS_SHIFT);                  
4001b208:	92 10 2e 10 	mov  0xe10, %o1                                
	 * 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)            
4001b20c:	b9 2a 20 05 	sll  %o0, 5, %i4                               
		    + (((t / 60) % 60) << MSDOS_DT_MINUTES_SHIFT)                   
		    + (((t / 3600) % 24) << MSDOS_DT_HOURS_SHIFT);                  
4001b210:	7f ff 9d 7a 	call  400027f8 <.udiv>                         
4001b214:	90 10 00 18 	mov  %i0, %o0                                  
4001b218:	40 00 39 98 	call  40029878 <.urem>                         
4001b21c:	92 10 20 18 	mov  0x18, %o1                                 
	 * 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)            
4001b220:	91 2a 20 0b 	sll  %o0, 0xb, %o0                             
4001b224:	92 10 20 3c 	mov  0x3c, %o1                                 
4001b228:	b8 07 00 08 	add  %i4, %o0, %i4                             
4001b22c:	40 00 39 93 	call  40029878 <.urem>                         
4001b230:	90 10 00 18 	mov  %i0, %o0                                  
4001b234:	91 32 20 01 	srl  %o0, 1, %o0                               
		/*                                                                  
		 * 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);                                         
4001b238:	13 00 00 54 	sethi  %hi(0x15000), %o1                       
	 * 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)            
4001b23c:	b8 07 00 08 	add  %i4, %o0, %i4                             
		/*                                                                  
		 * 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);                                         
4001b240:	92 12 61 80 	or  %o1, 0x180, %o1                            
	 * 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)            
4001b244:	f8 37 60 4e 	sth  %i4, [ %i5 + 0x4e ]                       
		/*                                                                  
		 * 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);                                         
4001b248:	7f ff 9d 6c 	call  400027f8 <.udiv>                         
4001b24c:	90 10 00 18 	mov  %i0, %o0                                  
		if (days != lastday) {                                              
4001b250:	03 10 00 bc 	sethi  %hi(0x4002f000), %g1                    
4001b254:	c4 00 60 54 	ld  [ %g1 + 0x54 ], %g2	! 4002f054 <lastday>   
4001b258:	80 a2 00 02 	cmp  %o0, %g2                                  
4001b25c:	22 80 00 2b 	be,a   4001b308 <msdos_date_unix2dos+0x130>    
4001b260:	c2 17 60 4e 	lduh  [ %i5 + 0x4e ], %g1                      
			lastday = days;                                                    
4001b264:	d0 20 60 54 	st  %o0, [ %g1 + 0x54 ]                        
			for (year = 1970;; year++) {                                       
4001b268:	82 10 27 b2 	mov  0x7b2, %g1                                
				inc = year & 0x03 ? 365 : 366;                                    
4001b26c:	84 08 60 03 	and  %g1, 3, %g2                               
4001b270:	80 a0 00 02 	cmp  %g0, %g2                                  
4001b274:	86 60 3f ff 	subx  %g0, -1, %g3                             
4001b278:	86 00 e1 6d 	add  %g3, 0x16d, %g3                           
				if (days < inc)                                                   
4001b27c:	80 a2 00 03 	cmp  %o0, %g3                                  
4001b280:	0a 80 00 05 	bcs  4001b294 <msdos_date_unix2dos+0xbc>       
4001b284:	80 a0 a0 00 	cmp  %g2, 0                                    
					break;                                                           
				days -= inc;                                                      
4001b288:	90 22 00 03 	sub  %o0, %g3, %o0                             
			}                                                                  
4001b28c:	10 bf ff f8 	b  4001b26c <msdos_date_unix2dos+0x94>         
4001b290:	82 00 60 01 	inc  %g1                                       
			months = year & 0x03 ? regyear : leapyear;                         
4001b294:	22 80 00 05 	be,a   4001b2a8 <msdos_date_unix2dos+0xd0>     
4001b298:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
4001b29c:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
4001b2a0:	10 80 00 03 	b  4001b2ac <msdos_date_unix2dos+0xd4>         
4001b2a4:	88 11 21 f4 	or  %g4, 0x1f4, %g4	! 4002ddf4 <regyear>       
4001b2a8:	88 11 21 dc 	or  %g4, 0x1dc, %g4                            
			for (month = 0; month < 12; month++) {                             
4001b2ac:	84 10 20 00 	clr  %g2                                       
4001b2b0:	87 28 a0 01 	sll  %g2, 1, %g3                               
				if (days < months[month])                                         
4001b2b4:	c6 11 00 03 	lduh  [ %g4 + %g3 ], %g3                       
4001b2b8:	80 a2 00 03 	cmp  %o0, %g3                                  
4001b2bc:	2a 80 00 07 	bcs,a   4001b2d8 <msdos_date_unix2dos+0x100>   
4001b2c0:	90 02 20 01 	inc  %o0                                       
				if (days < inc)                                                   
					break;                                                           
				days -= inc;                                                      
			}                                                                  
			months = year & 0x03 ? regyear : leapyear;                         
			for (month = 0; month < 12; month++) {                             
4001b2c4:	84 00 a0 01 	inc  %g2                                       
4001b2c8:	80 a0 a0 0c 	cmp  %g2, 0xc                                  
4001b2cc:	12 bf ff f9 	bne  4001b2b0 <msdos_date_unix2dos+0xd8>       <== ALWAYS TAKEN
4001b2d0:	90 22 00 03 	sub  %o0, %g3, %o0                             
				if (days < months[month])                                         
					break;                                                           
				days -= months[month];                                            
			}                                                                  
			lastddate = ((days + 1) << MSDOS_DD_DAY_SHIFT)                     
4001b2d4:	90 02 20 01 	inc  %o0                                       <== NOT EXECUTED
4001b2d8:	84 00 a0 01 	inc  %g2                                       
4001b2dc:	07 10 00 bc 	sethi  %hi(0x4002f000), %g3                    
4001b2e0:	85 28 a0 05 	sll  %g2, 5, %g2                               
4001b2e4:	90 02 00 02 	add  %o0, %g2, %o0                             
			 * 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)                                                   
4001b2e8:	80 a0 67 bc 	cmp  %g1, 0x7bc                                
4001b2ec:	08 80 00 06 	bleu  4001b304 <msdos_date_unix2dos+0x12c>     <== NEVER TAKEN
4001b2f0:	d0 30 e0 50 	sth  %o0, [ %g3 + 0x50 ]                       
				lastddate += (year - 1980) <<                                     
4001b2f4:	82 00 78 44 	add  %g1, -1980, %g1                           
4001b2f8:	83 28 60 09 	sll  %g1, 9, %g1                               
4001b2fc:	90 02 00 01 	add  %o0, %g1, %o0                             
4001b300:	d0 30 e0 50 	sth  %o0, [ %g3 + 0x50 ]                       
				             MSDOS_DD_YEAR_SHIFT;                                 
		}                                                                   
	}                                                                    
	*dtp = lastdtime;                                                    
4001b304:	c2 17 60 4e 	lduh  [ %i5 + 0x4e ], %g1                      
4001b308:	c2 36 80 00 	sth  %g1, [ %i2 ]                              
	*ddp = lastddate;                                                    
4001b30c:	03 10 00 bc 	sethi  %hi(0x4002f000), %g1                    
4001b310:	c2 10 60 50 	lduh  [ %g1 + 0x50 ], %g1	! 4002f050 <lastddate>
4001b314:	c2 36 40 00 	sth  %g1, [ %i1 ]                              
4001b318:	81 c7 e0 08 	ret                                            
4001b31c:	81 e8 00 00 	restore                                        
                                                                      

40017c00 <msdos_default_utf16_to_utf8>: uint8_t *dst, size_t *dst_size ) { int eno = 0; size_t bytes_to_copy = MIN( src_size / 2, *dst_size );
40017c00:	c4 03 00 00 	ld  [ %o4 ], %g2                               
40017c04:	95 32 a0 01 	srl  %o2, 1, %o2                               
40017c08:	80 a0 80 0a 	cmp  %g2, %o2                                  
40017c0c:	38 80 00 02 	bgu,a   40017c14 <msdos_default_utf16_to_utf8+0x14><== ALWAYS TAKEN
40017c10:	84 10 00 0a 	mov  %o2, %g2                                  
  size_t i;                                                           
                                                                      
  (void) super;                                                       
                                                                      
  *dst_size = bytes_to_copy;                                          
40017c14:	c4 23 00 00 	st  %g2, [ %o4 ]                               
                                                                      
  for ( i = 0; eno == 0 && i < bytes_to_copy; ++i ) {                 
40017c18:	82 10 20 00 	clr  %g1                                       
  const size_t                 src_size,                              
  uint8_t                     *dst,                                   
  size_t                      *dst_size                               
)                                                                     
{                                                                     
  int    eno = 0;                                                     
40017c1c:	90 10 20 00 	clr  %o0                                       
                                                                      
  (void) super;                                                       
                                                                      
  *dst_size = bytes_to_copy;                                          
                                                                      
  for ( i = 0; eno == 0 && i < bytes_to_copy; ++i ) {                 
40017c20:	80 a0 40 02 	cmp  %g1, %g2                                  
40017c24:	1a 80 00 12 	bcc  40017c6c <msdos_default_utf16_to_utf8+0x6c>
40017c28:	80 a2 20 00 	cmp  %o0, 0                                    
40017c2c:	12 80 00 10 	bne  40017c6c <msdos_default_utf16_to_utf8+0x6c>
40017c30:	87 28 60 01 	sll  %g1, 1, %g3                               
    uint16_t utf16_le = src[i];                                       
40017c34:	c8 12 40 03 	lduh  [ %o1 + %g3 ], %g4                       
    uint16_t utf16_native  = CF_LE_W( utf16_le );                     
40017c38:	89 29 20 10 	sll  %g4, 0x10, %g4                            
40017c3c:	87 31 20 08 	srl  %g4, 8, %g3                               
40017c40:	89 31 20 18 	srl  %g4, 0x18, %g4                            
40017c44:	86 10 c0 04 	or  %g3, %g4, %g3                              
                                                                      
    if ( utf16_native <= 127 ) {                                      
40017c48:	89 28 e0 10 	sll  %g3, 0x10, %g4                            
40017c4c:	89 31 20 10 	srl  %g4, 0x10, %g4                            
40017c50:	80 a1 20 7f 	cmp  %g4, 0x7f                                 
40017c54:	18 80 00 04 	bgu  40017c64 <msdos_default_utf16_to_utf8+0x64>
40017c58:	90 10 20 16 	mov  0x16, %o0                                 
      dst[i] = (uint8_t) utf16_native;                                
40017c5c:	c6 2a c0 01 	stb  %g3, [ %o3 + %g1 ]                        
40017c60:	90 10 20 00 	clr  %o0                                       
                                                                      
  (void) super;                                                       
                                                                      
  *dst_size = bytes_to_copy;                                          
                                                                      
  for ( i = 0; eno == 0 && i < bytes_to_copy; ++i ) {                 
40017c64:	10 bf ff ef 	b  40017c20 <msdos_default_utf16_to_utf8+0x20> 
40017c68:	82 00 60 01 	inc  %g1                                       
      eno = EINVAL;                                                   
    }                                                                 
  }                                                                   
                                                                      
  return eno;                                                         
}                                                                     
40017c6c:	81 c3 e0 08 	retl                                           
                                                                      

40017b98 <msdos_default_utf8_to_utf16>: uint16_t *dst, size_t *dst_size ) { int eno = 0; size_t bytes_to_copy = MIN( src_size, *dst_size / 2);
40017b98:	c4 03 00 00 	ld  [ %o4 ], %g2                               
40017b9c:	85 30 a0 01 	srl  %g2, 1, %g2                               
40017ba0:	80 a0 80 0a 	cmp  %g2, %o2                                  
40017ba4:	38 80 00 02 	bgu,a   40017bac <msdos_default_utf8_to_utf16+0x14><== ALWAYS TAKEN
40017ba8:	84 10 00 0a 	mov  %o2, %g2                                  
  size_t i;                                                           
                                                                      
  (void) super;                                                       
                                                                      
  *dst_size = 2 * bytes_to_copy;                                      
40017bac:	83 28 a0 01 	sll  %g2, 1, %g1                               
  const size_t                 src_size,                              
  uint16_t                    *dst,                                   
  size_t                      *dst_size                               
)                                                                     
{                                                                     
  int    eno = 0;                                                     
40017bb0:	90 10 20 00 	clr  %o0                                       
  size_t bytes_to_copy = MIN( src_size, *dst_size / 2);               
  size_t i;                                                           
                                                                      
  (void) super;                                                       
                                                                      
  *dst_size = 2 * bytes_to_copy;                                      
40017bb4:	c2 23 00 00 	st  %g1, [ %o4 ]                               
                                                                      
  for ( i = 0; eno == 0 && i < bytes_to_copy; ++i ) {                 
40017bb8:	82 10 20 00 	clr  %g1                                       
40017bbc:	80 a0 40 02 	cmp  %g1, %g2                                  
40017bc0:	1a 80 00 0e 	bcc  40017bf8 <msdos_default_utf8_to_utf16+0x60>
40017bc4:	80 a2 20 00 	cmp  %o0, 0                                    
40017bc8:	12 80 00 0c 	bne  40017bf8 <msdos_default_utf8_to_utf16+0x60><== NEVER TAKEN
40017bcc:	01 00 00 00 	nop                                            
    uint16_t utf16_native = src[i];                                   
40017bd0:	c6 0a 40 01 	ldub  [ %o1 + %g1 ], %g3                       
                                                                      
    if ( utf16_native <= 127 ) {                                      
40017bd4:	80 88 e0 80 	btst  0x80, %g3                                
40017bd8:	12 80 00 06 	bne  40017bf0 <msdos_default_utf8_to_utf16+0x58><== NEVER TAKEN
40017bdc:	90 10 20 16 	mov  0x16, %o0                                 
40017be0:	89 28 60 01 	sll  %g1, 1, %g4                               
      dst[i] = CT_LE_W( utf16_native );                               
40017be4:	87 28 e0 08 	sll  %g3, 8, %g3                               
40017be8:	90 10 20 00 	clr  %o0                                       
40017bec:	c6 32 c0 04 	sth  %g3, [ %o3 + %g4 ]                        
                                                                      
  (void) super;                                                       
                                                                      
  *dst_size = 2 * bytes_to_copy;                                      
                                                                      
  for ( i = 0; eno == 0 && i < bytes_to_copy; ++i ) {                 
40017bf0:	10 bf ff f3 	b  40017bbc <msdos_default_utf8_to_utf16+0x24> 
40017bf4:	82 00 60 01 	inc  %g1                                       
      eno = EINVAL;                                                   
    }                                                                 
  }                                                                   
                                                                      
  return eno;                                                         
}                                                                     
40017bf8:	81 c3 e0 08 	retl                                           
                                                                      

400189ac <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 ) {
400189ac:	9d e3 bf a0 	save  %sp, -96, %sp                            
             */                                                       
            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,     
400189b0:	23 10 00 b4 	sethi  %hi(0x4002d000), %l1                    
    fat_file_fd_t                        *fat_fd,                     
    bool                                 *ret_val                     
    )                                                                 
{                                                                     
    ssize_t          ret = 0;                                         
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
400189b4:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
                 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)),                     
400189b8:	25 10 00 b4 	sethi  %hi(0x4002d000), %l2                    
    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;                                                 
400189bc:	c0 2e 80 00 	clrb  [ %i2 ]                                  
    bool                                 *ret_val                     
    )                                                                 
{                                                                     
    ssize_t          ret = 0;                                         
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
    uint32_t         j = 0, i = 0;                                    
400189c0:	b6 10 20 00 	clr  %i3                                       
             */                                                       
            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,     
400189c4:	a2 14 63 90 	or  %l1, 0x390, %l1                            
                         MSDOS_SHORT_NAME_LEN) == 0) ||               
                (strncmp(MSDOS_DIR_NAME((entry)),                     
400189c8:	a4 14 a3 a0 	or  %l2, 0x3a0, %l2                            
    uint32_t         j = 0, i = 0;                                    
                                                                      
    /* dir is not empty */                                            
    *ret_val = false;                                                 
                                                                      
    while ((ret = fat_file_read(&fs_info->fat, fat_fd, j * fs_info->fat.vol.bps,
400189cc:	f8 17 40 00 	lduh  [ %i5 ], %i4                             
400189d0:	90 10 00 1b 	mov  %i3, %o0                                  
400189d4:	7f ff a7 4f 	call  40002710 <.umul>                         
400189d8:	92 10 00 1c 	mov  %i4, %o1                                  
400189dc:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
400189e0:	94 10 00 08 	mov  %o0, %o2                                  
400189e4:	92 10 00 19 	mov  %i1, %o1                                  
400189e8:	90 10 00 1d 	mov  %i5, %o0                                  
400189ec:	7f ff e6 95 	call  40012440 <fat_file_read>                 
400189f0:	96 10 00 1c 	mov  %i4, %o3                                  
400189f4:	80 a2 20 00 	cmp  %o0, 0                                    
400189f8:	02 80 00 2e 	be  40018ab0 <msdos_dir_is_empty+0x104>        <== NEVER TAKEN
400189fc:	80 a2 20 1f 	cmp  %o0, 0x1f                                 
                                  fs_info->fat.vol.bps,               
                                  fs_info->cl_buf)) != FAT_EOF)       
    {                                                                 
        if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)                  
40018a00:	04 80 00 32 	ble  40018ac8 <msdos_dir_is_empty+0x11c>       <== NEVER TAKEN
40018a04:	b0 10 3f ff 	mov  -1, %i0                                   
            return -1;                                                
                                                                      
        assert(ret == fs_info->fat.vol.bps);                          
40018a08:	c2 17 40 00 	lduh  [ %i5 ], %g1                             
40018a0c:	80 a2 00 01 	cmp  %o0, %g1                                  
40018a10:	22 80 00 2c 	be,a   40018ac0 <msdos_dir_is_empty+0x114>     <== ALWAYS TAKEN
40018a14:	b8 10 20 00 	clr  %i4                                       
40018a18:	11 10 00 b4 	sethi  %hi(0x4002d000), %o0                    <== NOT EXECUTED
40018a1c:	15 10 00 b5 	sethi  %hi(0x4002d400), %o2                    <== NOT EXECUTED
40018a20:	17 10 00 b4 	sethi  %hi(0x4002d000), %o3                    <== NOT EXECUTED
40018a24:	90 12 23 18 	or  %o0, 0x318, %o0                            <== NOT EXECUTED
40018a28:	92 10 23 99 	mov  0x399, %o1                                <== NOT EXECUTED
40018a2c:	94 12 a0 60 	or  %o2, 0x60, %o2                             <== NOT EXECUTED
40018a30:	7f ff b0 81 	call  40004c34 <__assert_func>                 <== NOT EXECUTED
40018a34:	96 12 e3 70 	or  %o3, 0x370, %o3                            <== NOT EXECUTED
                                                                      
        /* 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)                  
40018a38:	b8 07 20 20 	add  %i4, 0x20, %i4                            
            return -1;                                                
                                                                      
        assert(ret == fs_info->fat.vol.bps);                          
                                                                      
        /* have to look at the DIR_NAME as "raw" 8-bit data */        
        for (i = 0;                                                   
40018a3c:	80 a7 00 13 	cmp  %i4, %l3                                  
40018a40:	3a bf ff e3 	bcc,a   400189cc <msdos_dir_is_empty+0x20>     
40018a44:	b6 06 e0 01 	inc  %i3                                       
             i < fs_info->fat.vol.bps;                                
             i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)                  
        {                                                             
            char* entry = (char*) fs_info->cl_buf + i;                
40018a48:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
             * 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)) ==                    
40018a4c:	e0 08 40 1c 	ldub  [ %g1 + %i4 ], %l0                       
40018a50:	80 a4 20 e5 	cmp  %l0, 0xe5                                 
40018a54:	02 bf ff f9 	be  40018a38 <msdos_dir_is_empty+0x8c>         
40018a58:	b0 00 40 1c 	add  %g1, %i4, %i0                             
                 MSDOS_THIS_DIR_ENTRY_EMPTY) ||                       
                ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==    
40018a5c:	c2 0e 20 0b 	ldub  [ %i0 + 0xb ], %g1                       
             *                                                        
             * Just ignore long file name entries. They must have a short entry to
             * be valid.                                              
             */                                                       
            if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==                    
                 MSDOS_THIS_DIR_ENTRY_EMPTY) ||                       
40018a60:	82 08 60 3f 	and  %g1, 0x3f, %g1                            
40018a64:	80 a0 60 0f 	cmp  %g1, 0xf                                  
40018a68:	02 bf ff f4 	be  40018a38 <msdos_dir_is_empty+0x8c>         
40018a6c:	90 10 00 18 	mov  %i0, %o0                                  
                ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==    
                 MSDOS_ATTR_LFN) ||                                   
                (strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,     
40018a70:	92 10 00 11 	mov  %l1, %o1                                  
40018a74:	40 00 15 c2 	call  4001e17c <strncmp>                       
40018a78:	94 10 20 0b 	mov  0xb, %o2                                  
             * be valid.                                              
             */                                                       
            if (((*MSDOS_DIR_ENTRY_TYPE(entry)) ==                    
                 MSDOS_THIS_DIR_ENTRY_EMPTY) ||                       
                ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==    
                 MSDOS_ATTR_LFN) ||                                   
40018a7c:	80 a2 20 00 	cmp  %o0, 0                                    
40018a80:	22 bf ff ef 	be,a   40018a3c <msdos_dir_is_empty+0x90>      
40018a84:	b8 07 20 20 	add  %i4, 0x20, %i4                            
                (strncmp(MSDOS_DIR_NAME((entry)), MSDOS_DOT_NAME,     
                         MSDOS_SHORT_NAME_LEN) == 0) ||               
                (strncmp(MSDOS_DIR_NAME((entry)),                     
40018a88:	90 10 00 18 	mov  %i0, %o0                                  
40018a8c:	92 10 00 12 	mov  %l2, %o1                                  
40018a90:	40 00 15 bb 	call  4001e17c <strncmp>                       
40018a94:	94 10 20 0b 	mov  0xb, %o2                                  
            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,     
                         MSDOS_SHORT_NAME_LEN) == 0) ||               
40018a98:	80 a2 20 00 	cmp  %o0, 0                                    
40018a9c:	22 bf ff e8 	be,a   40018a3c <msdos_dir_is_empty+0x90>      
40018aa0:	b8 07 20 20 	add  %i4, 0x20, %i4                            
                continue;                                             
                                                                      
            /*                                                        
             * Nothing more to look at.                               
             */                                                       
            if ((*MSDOS_DIR_NAME(entry)) ==                           
40018aa4:	80 a4 20 00 	cmp  %l0, 0                                    
40018aa8:	12 80 00 08 	bne  40018ac8 <msdos_dir_is_empty+0x11c>       
40018aac:	b0 10 20 00 	clr  %i0                                       
                MSDOS_THIS_DIR_ENTRY_AND_REST_EMPTY)                  
            {                                                         
                *ret_val = true;                                      
40018ab0:	82 10 20 01 	mov  1, %g1                                    
40018ab4:	c2 2e 80 00 	stb  %g1, [ %i2 ]                              
                return RC_OK;                                         
40018ab8:	81 c7 e0 08 	ret                                            
40018abc:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      
        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;                                
40018ac0:	10 bf ff df 	b  40018a3c <msdos_dir_is_empty+0x90>          
40018ac4:	a6 10 00 08 	mov  %o0, %l3                                  
        }                                                             
        j++;                                                          
    }                                                                 
    *ret_val = true;                                                  
    return RC_OK;                                                     
}                                                                     
40018ac8:	81 c7 e0 08 	ret                                            
40018acc:	81 e8 00 00 	restore                                        
                                                                      

4001b9a0 <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) {
4001b9a0:	9d e3 be 48 	save  %sp, -440, %sp                           
    int                rc = RC_OK;                                    
    int                eno = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001b9a4:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
    /*                                                                
     * 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);                      
4001b9a8:	d0 1e 20 08 	ldd  [ %i0 + 8 ], %o0                          
msdos_dir_read(rtems_libio_t *iop, void *buffer, size_t count)        
{                                                                     
    int                rc = RC_OK;                                    
    int                eno = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001b9ac:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    /*                                                                
     * 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);                      
4001b9b0:	94 10 20 00 	clr  %o2                                       
{                                                                     
    int                rc = RC_OK;                                    
    int                eno = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
    rtems_dosfs_convert_control *converter = fs_info->converter;      
4001b9b4:	e0 07 60 a4 	ld  [ %i5 + 0xa4 ], %l0                        
    /*                                                                
     * 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);                      
4001b9b8:	96 10 21 18 	mov  0x118, %o3                                
    fat_file_fd_t     *tmp_fat_fd = NULL;                             
    struct dirent      tmp_dirent;                                    
    size_t             tmp_lfn_len = 0;                               
    uint16_t          *lfn_buf = converter->buffer.data;              
    char              *sfn_buf = converter->buffer.data;              
    const size_t       buf_size = converter->buffer.size;             
4001b9bc:	c2 04 20 08 	ld  [ %l0 + 8 ], %g1                           
    int                rc = RC_OK;                                    
    int                eno = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
    rtems_dosfs_convert_control *converter = fs_info->converter;      
    const rtems_dosfs_convert_handler *convert_handler = converter->handler;
4001b9c0:	ee 04 00 00 	ld  [ %l0 ], %l7                               
    fat_file_fd_t     *tmp_fat_fd = NULL;                             
    struct dirent      tmp_dirent;                                    
    size_t             tmp_lfn_len = 0;                               
    uint16_t          *lfn_buf = converter->buffer.data;              
    char              *sfn_buf = converter->buffer.data;              
    const size_t       buf_size = converter->buffer.size;             
4001b9c4:	c2 27 be b0 	st  %g1, [ %fp + -336 ]                        
    uint32_t           bts2rd = 0;                                    
    uint32_t           cur_cln = 0;                                   
    uint32_t           lfn_start = FAT_FILE_SHORT_NAME;               
    uint8_t            lfn_checksum = 0;                              
    int                lfn_entries = 0;                               
    size_t             string_size = sizeof(tmp_dirent.d_name);       
4001b9c8:	82 10 21 00 	mov  0x100, %g1                                
 *     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)        
{                                                                     
4001b9cc:	f2 27 a0 48 	st  %i1, [ %fp + 0x48 ]                        
    uint32_t           bts2rd = 0;                                    
    uint32_t           cur_cln = 0;                                   
    uint32_t           lfn_start = FAT_FILE_SHORT_NAME;               
    uint8_t            lfn_checksum = 0;                              
    int                lfn_entries = 0;                               
    size_t             string_size = sizeof(tmp_dirent.d_name);       
4001b9d0:	c2 27 be d4 	st  %g1, [ %fp + -300 ]                        
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
    rtems_dosfs_convert_control *converter = fs_info->converter;      
    const rtems_dosfs_convert_handler *convert_handler = converter->handler;
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
    fat_file_fd_t     *tmp_fat_fd = NULL;                             
4001b9d4:	c0 27 be cc 	clr  [ %fp + -308 ]                            
    /*                                                                
     * 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);                      
4001b9d8:	7f ff 9a 5c 	call  40002348 <__divdi3>                      
4001b9dc:	c0 27 be d0 	clr  [ %fp + -304 ]                            
    int                eno = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
    rtems_dosfs_convert_control *converter = fs_info->converter;      
    const rtems_dosfs_convert_handler *convert_handler = converter->handler;
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
4001b9e0:	e2 06 20 1c 	ld  [ %i0 + 0x1c ], %l1                        
    /*                                                                
     * 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);                      
4001b9e4:	d2 27 be c4 	st  %o1, [ %fp + -316 ]                        
    count = (count / sizeof(struct dirent)) * sizeof(struct dirent);  
4001b9e8:	90 10 00 1a 	mov  %i2, %o0                                  
4001b9ec:	7f ff 9b 83 	call  400027f8 <.udiv>                         
4001b9f0:	92 10 21 18 	mov  0x118, %o1                                
4001b9f4:	a7 2a 20 03 	sll  %o0, 3, %l3                               
4001b9f8:	91 2a 20 05 	sll  %o0, 5, %o0                               
4001b9fc:	a6 04 c0 08 	add  %l3, %o0, %l3                             
4001ba00:	83 2c e0 03 	sll  %l3, 3, %g1                               
4001ba04:	a6 20 40 13 	sub  %g1, %l3, %l3                             
     * too, so read such set of sectors is quick operation for low-level IO
     * layer.                                                         
     */                                                               
    bts2rd = (FAT_FD_OF_ROOT_DIR(fat_fd) &&                           
             (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16))) ?     
             fat_fd->fat_file_size                              :     
4001ba08:	c2 04 60 20 	ld  [ %l1 + 0x20 ], %g1                        
4001ba0c:	80 a0 60 01 	cmp  %g1, 1                                    
4001ba10:	12 80 00 0d 	bne  4001ba44 <msdos_dir_read+0xa4>            
4001ba14:	ea 04 20 04 	ld  [ %l0 + 4 ], %l5                           
     * 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) &&                           
4001ba18:	c2 04 60 24 	ld  [ %l1 + 0x24 ], %g1                        
4001ba1c:	80 a0 60 00 	cmp  %g1, 0                                    
4001ba20:	32 80 00 0a 	bne,a   4001ba48 <msdos_dir_read+0xa8>         <== NEVER TAKEN
4001ba24:	c2 17 60 06 	lduh  [ %i5 + 6 ], %g1                         <== NOT EXECUTED
             (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16))) ?     
4001ba28:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       
     * 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) &&                           
4001ba2c:	80 88 60 03 	btst  3, %g1                                   
4001ba30:	22 80 00 06 	be,a   4001ba48 <msdos_dir_read+0xa8>          <== NEVER TAKEN
4001ba34:	c2 17 60 06 	lduh  [ %i5 + 6 ], %g1                         <== NOT EXECUTED
             (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16))) ?     
             fat_fd->fat_file_size                              :     
4001ba38:	c4 04 60 18 	ld  [ %l1 + 0x18 ], %g2                        
4001ba3c:	10 80 00 04 	b  4001ba4c <msdos_dir_read+0xac>              
4001ba40:	c4 27 be c0 	st  %g2, [ %fp + -320 ]                        
4001ba44:	c2 17 60 06 	lduh  [ %i5 + 6 ], %g1                         
4001ba48:	c2 27 be c0 	st  %g1, [ %fp + -320 ]                        
             fs_info->fat.vol.bpc;                                    
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001ba4c:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001ba50:	92 10 20 00 	clr  %o1                                       
4001ba54:	7f ff b5 f2 	call  4000921c <rtems_semaphore_obtain>        
4001ba58:	94 10 20 00 	clr  %o2                                       
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001ba5c:	80 a2 20 00 	cmp  %o0, 0                                    
4001ba60:	12 80 00 0a 	bne  4001ba88 <msdos_dir_read+0xe8>            <== NEVER TAKEN
4001ba64:	a4 10 20 00 	clr  %l2                                       
4001ba68:	b4 10 20 00 	clr  %i2                                       
4001ba6c:	c0 2f be bf 	clrb  [ %fp + -321 ]                           
4001ba70:	b6 10 3f ff 	mov  -1, %i3                                   
4001ba74:	b8 10 20 00 	clr  %i4                                       
4001ba78:	10 80 00 49 	b  4001bb9c <msdos_dir_read+0x1fc>             
4001ba7c:	a8 10 20 00 	clr  %l4                                       
         */                                                           
        ret = fat_file_read(&fs_info->fat, fat_fd, (j * bts2rd),      
                            bts2rd, fs_info->cl_buf);                 
        if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)                  
        {                                                             
            rtems_semaphore_release(fs_info->vol_sema);               
4001ba80:	7f ff b6 2f 	call  4000933c <rtems_semaphore_release>       <== NOT EXECUTED
4001ba84:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        <== NOT EXECUTED
            rtems_set_errno_and_return_minus_one(EIO);                
4001ba88:	40 00 02 81 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001ba8c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001ba90:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001ba94:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001ba98:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001ba9c:	81 e8 00 00 	restore                                        <== 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 && cmpltd >= 0)                                  
4001baa0:	02 80 00 cc 	be  4001bdd0 <msdos_dir_read+0x430>            
4001baa4:	d6 07 be c0 	ld  [ %fp + -320 ], %o3                        
         * 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(&fs_info->fat, fat_fd, (j * bts2rd),      
4001baa8:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
4001baac:	90 10 00 1d 	mov  %i5, %o0                                  
4001bab0:	92 10 00 11 	mov  %l1, %o1                                  
4001bab4:	7f ff da 63 	call  40012440 <fat_file_read>                 
4001bab8:	94 10 00 12 	mov  %l2, %o2                                  
                            bts2rd, fs_info->cl_buf);                 
        if (ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)                  
4001babc:	80 a2 20 1f 	cmp  %o0, 0x1f                                 
4001bac0:	04 bf ff f0 	ble  4001ba80 <msdos_dir_read+0xe0>            <== NEVER TAKEN
4001bac4:	d0 27 be b4 	st  %o0, [ %fp + -332 ]                        
4001bac8:	b2 10 20 00 	clr  %i1                                       
        {                                                             
            rtems_semaphore_release(fs_info->vol_sema);               
            rtems_set_errno_and_return_minus_one(EIO);                
        }                                                             
                                                                      
        for (i = 0; i < ret && cmpltd >= 0; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
4001bacc:	80 a7 20 00 	cmp  %i4, 0                                    
4001bad0:	06 80 00 31 	bl  4001bb94 <msdos_dir_read+0x1f4>            <== NEVER TAKEN
4001bad4:	c2 07 be b4 	ld  [ %fp + -332 ], %g1                        
4001bad8:	80 a6 40 01 	cmp  %i1, %g1                                  
4001badc:	1a 80 00 2f 	bcc  4001bb98 <msdos_dir_read+0x1f8>           
4001bae0:	c4 07 be c0 	ld  [ %fp + -320 ], %g2                        
        {                                                             
            char* entry = (char*) fs_info->cl_buf + i;                
4001bae4:	c4 07 60 a0 	ld  [ %i5 + 0xa0 ], %g2                        
4001bae8:	ac 00 80 19 	add  %g2, %i1, %l6                             
                                                                      
            /*                                                        
             * Is this directory from here on empty ?                 
             */                                                       
            if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==                     
4001baec:	c4 08 80 19 	ldub  [ %g2 + %i1 ], %g2                       
4001baf0:	86 88 a0 ff 	andcc  %g2, 0xff, %g3                          
4001baf4:	02 80 00 b7 	be  4001bdd0 <msdos_dir_read+0x430>            
4001baf8:	80 a0 e0 e5 	cmp  %g3, 0xe5                                 
                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)
4001bafc:	22 bf ff f4 	be,a   4001bacc <msdos_dir_read+0x12c>         
4001bb00:	b2 06 60 20 	add  %i1, 0x20, %i1                            
                continue;                                             
                                                                      
            /* Is the directory entry empty a volume label */         
            if (((*MSDOS_DIR_ATTR(entry)) & MSDOS_ATTR_VOLUME_ID) &&  
4001bb04:	c6 0d a0 0b 	ldub  [ %l6 + 0xb ], %g3                       
4001bb08:	80 88 e0 08 	btst  8, %g3                                   
4001bb0c:	12 80 00 29 	bne  4001bbb0 <msdos_dir_read+0x210>           
4001bb10:	86 08 e0 3f 	and  %g3, 0x3f, %g3                            
                                                                      
            /*                                                        
             * Check the attribute to see if the entry is for a long file
             * name.                                                  
             */                                                       
            if ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) ==     
4001bb14:	80 a0 e0 0f 	cmp  %g3, 0xf                                  
4001bb18:	32 80 00 39 	bne,a   4001bbfc <msdos_dir_read+0x25c>        
4001bb1c:	c4 07 be c4 	ld  [ %fp + -316 ], %g2                        
                int offset_lfn;                                       
                                                                      
                /*                                                    
                 * Is this is the first entry of a LFN ?              
                 */                                                   
                if (lfn_start == FAT_FILE_SHORT_NAME)                 
4001bb20:	80 a6 ff ff 	cmp  %i3, -1                                   
4001bb24:	02 80 00 27 	be  4001bbc0 <msdos_dir_read+0x220>            
4001bb28:	96 10 20 00 	clr  %o3                                       
                 * 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) &   
4001bb2c:	c4 0d 80 00 	ldub  [ %l6 ], %g2                             
4001bb30:	84 08 a0 3f 	and  %g2, 0x3f, %g2                            
4001bb34:	80 a6 80 02 	cmp  %i2, %g2                                  
4001bb38:	32 80 00 a4 	bne,a   4001bdc8 <msdos_dir_read+0x428>        
4001bb3c:	b6 10 3f ff 	mov  -1, %i3                                   
                                     MSDOS_LAST_LONG_ENTRY_MASK)) ||  
4001bb40:	c6 0f be bf 	ldub  [ %fp + -321 ], %g3                      
4001bb44:	c4 0d a0 0d 	ldub  [ %l6 + 0xd ], %g2                       
4001bb48:	80 a0 c0 02 	cmp  %g3, %g2                                  
4001bb4c:	32 80 00 9f 	bne,a   4001bdc8 <msdos_dir_read+0x428>        <== NEVER TAKEN
4001bb50:	b6 10 3f ff 	mov  -1, %i3                                   <== NOT EXECUTED
                 * fit in the directory entry name field.             
                 */                                                   
                                                                      
                lfn_entries--;                                        
                offset_lfn = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;   
                tmp_lfn_len += msdos_get_utf16_string_from_long_entry (
4001bb54:	c2 07 be b0 	ld  [ %fp + -336 ], %g1                        
                 * The DOS maximum length is 255 characters without the
                 * trailing nul character. We need to range check the length to
                 * fit in the directory entry name field.             
                 */                                                   
                                                                      
                lfn_entries--;                                        
4001bb58:	b4 06 bf ff 	add  %i2, -1, %i2                              
                offset_lfn = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;   
4001bb5c:	85 2e a0 02 	sll  %i2, 2, %g2                               
4001bb60:	95 2e a0 04 	sll  %i2, 4, %o2                               
                tmp_lfn_len += msdos_get_utf16_string_from_long_entry (
4001bb64:	90 10 00 16 	mov  %l6, %o0                                  
                 * trailing nul character. We need to range check the length to
                 * fit in the directory entry name field.             
                 */                                                   
                                                                      
                lfn_entries--;                                        
                offset_lfn = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;   
4001bb68:	94 22 80 02 	sub  %o2, %g2, %o2                             
                tmp_lfn_len += msdos_get_utf16_string_from_long_entry (
4001bb6c:	96 0a e0 01 	and  %o3, 1, %o3                               
                 * trailing nul character. We need to range check the length to
                 * fit in the directory entry name field.             
                 */                                                   
                                                                      
                lfn_entries--;                                        
                offset_lfn = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;   
4001bb70:	94 02 80 1a 	add  %o2, %i2, %o2                             
                tmp_lfn_len += msdos_get_utf16_string_from_long_entry (
                  entry,                                              
                  &lfn_buf[offset_lfn],                               
4001bb74:	93 2a a0 01 	sll  %o2, 1, %o1                               
                 * fit in the directory entry name field.             
                 */                                                   
                                                                      
                lfn_entries--;                                        
                offset_lfn = lfn_entries * MSDOS_LFN_LEN_PER_ENTRY;   
                tmp_lfn_len += msdos_get_utf16_string_from_long_entry (
4001bb78:	94 20 40 0a 	sub  %g1, %o2, %o2                             
4001bb7c:	7f ff f3 d5 	call  40018ad0 <msdos_get_utf16_string_from_long_entry>
4001bb80:	92 05 40 09 	add  %l5, %o1, %o1                             
4001bb84:	a8 05 00 08 	add  %l4, %o0, %l4                             
                        return rc;                                    
                    }                                                 
                }                                                     
            }                                                         
                                                                      
            if (count <= 0)                                           
4001bb88:	80 a4 e0 00 	cmp  %l3, 0                                    
4001bb8c:	32 bf ff d0 	bne,a   4001bacc <msdos_dir_read+0x12c>        
4001bb90:	b2 06 60 20 	add  %i1, 0x20, %i1                            
4001bb94:	c4 07 be c0 	ld  [ %fp + -320 ], %g2                        
4001bb98:	a4 04 80 02 	add  %l2, %g2, %l2                             
    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 && cmpltd >= 0)                                  
4001bb9c:	80 a7 20 00 	cmp  %i4, 0                                    
4001bba0:	16 bf ff c0 	bge  4001baa0 <msdos_dir_read+0x100>           <== ALWAYS TAKEN
4001bba4:	80 a4 e0 00 	cmp  %l3, 0                                    
                break;                                                
        }                                                             
        j++;                                                          
    }                                                                 
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001bba8:	10 80 00 8b 	b  4001bdd4 <msdos_dir_read+0x434>             <== NOT EXECUTED
4001bbac:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        <== 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) &&  
4001bbb0:	80 a0 e0 0f 	cmp  %g3, 0xf                                  
4001bbb4:	32 bf ff c6 	bne,a   4001bacc <msdos_dir_read+0x12c>        
4001bbb8:	b2 06 60 20 	add  %i1, 0x20, %i1                            
4001bbbc:	30 bf ff d7 	b,a   4001bb18 <msdos_dir_read+0x178>          
                {                                                     
                    is_first_entry = true;                            
                    /*                                                
                     * The first entry must have the last long entry flag set.
                     */                                               
                    if ((*MSDOS_DIR_ENTRY_TYPE(entry) &               
4001bbc0:	80 88 a0 40 	btst  0x40, %g2                                
4001bbc4:	22 bf ff c2 	be,a   4001bacc <msdos_dir_read+0x12c>         
4001bbc8:	b2 06 60 20 	add  %i1, 0x20, %i1                            
                                                                      
                    /*                                                
                     * 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) &     
4001bbcc:	b4 08 a0 3f 	and  %g2, 0x3f, %i2                            
                                   MSDOS_LAST_LONG_ENTRY_MASK);       
                    tmp_lfn_len = 0;                                  
                    lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);    
4001bbd0:	c4 0d a0 0d 	ldub  [ %l6 + 0xd ], %g2                       
                    memset (tmp_dirent.d_name, 0, sizeof(tmp_dirent.d_name));
4001bbd4:	90 07 be fc 	add  %fp, -260, %o0                            
                     * also the checksum of the short entry.          
                     */                                               
                    lfn_entries = (*MSDOS_DIR_ENTRY_TYPE(entry) &     
                                   MSDOS_LAST_LONG_ENTRY_MASK);       
                    tmp_lfn_len = 0;                                  
                    lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);    
4001bbd8:	c4 2f be bf 	stb  %g2, [ %fp + -321 ]                       
                    memset (tmp_dirent.d_name, 0, sizeof(tmp_dirent.d_name));
4001bbdc:	92 10 20 00 	clr  %o1                                       
4001bbe0:	40 00 04 bf 	call  4001cedc <memset>                        
4001bbe4:	94 10 21 00 	mov  0x100, %o2                                
4001bbe8:	b6 06 40 12 	add  %i1, %l2, %i3                             
                /*                                                    
                 * Is this is the first entry of a LFN ?              
                 */                                                   
                if (lfn_start == FAT_FILE_SHORT_NAME)                 
                {                                                     
                    is_first_entry = true;                            
4001bbec:	96 10 20 01 	mov  1, %o3                                    
                        continue;                                     
                                                                      
                    /*                                                
                     * Remember the start location of the long file name.
                     */                                               
                    lfn_start =                                       
4001bbf0:	b7 36 e0 05 	srl  %i3, 5, %i3                               
4001bbf4:	10 bf ff ce 	b  4001bb2c <msdos_dir_read+0x18c>             
4001bbf8:	a8 10 20 00 	clr  %l4                                       
                fat_dir_pos_t dir_pos;                                
                                                                      
                /*                                                    
                 * Skip active entries until get the entry to start from.
                 */                                                   
                if (start)                                            
4001bbfc:	80 a0 a0 00 	cmp  %g2, 0                                    
4001bc00:	02 80 00 04 	be  4001bc10 <msdos_dir_read+0x270>            
4001bc04:	84 00 bf ff 	add  %g2, -1, %g2                              
                {                                                     
                    lfn_start = FAT_FILE_SHORT_NAME;                  
                    start--;                                          
4001bc08:	10 80 00 6f 	b  4001bdc4 <msdos_dir_read+0x424>             
4001bc0c:	c4 27 be c4 	st  %g2, [ %fp + -316 ]                        
                 * 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(&fs_info->fat, fat_fd, F_CLU_NUM, 
4001bc10:	90 10 00 1d 	mov  %i5, %o0                                  
4001bc14:	92 10 00 11 	mov  %l1, %o1                                  
4001bc18:	94 10 20 01 	mov  1, %o2                                    
4001bc1c:	96 10 00 12 	mov  %l2, %o3                                  
4001bc20:	7f ff da e7 	call  400127bc <fat_file_ioctl>                
4001bc24:	98 07 be d0 	add  %fp, -304, %o4                            
                                    j * bts2rd, &cur_cln);            
                if (rc != RC_OK)                                      
4001bc28:	84 92 20 00 	orcc  %o0, 0, %g2                              
4001bc2c:	12 80 00 0e 	bne  4001bc64 <msdos_dir_read+0x2c4>           <== NEVER TAKEN
4001bc30:	82 10 3f ff 	mov  -1, %g1                                   
                    rtems_semaphore_release(fs_info->vol_sema);       
                    return rc;                                        
                }                                                     
                                                                      
                fat_dir_pos_init(&dir_pos);                           
                dir_pos.sname.cln = cur_cln;                          
4001bc34:	c4 07 be d0 	ld  [ %fp + -304 ], %g2                        
4001bc38:	c4 27 be d8 	st  %g2, [ %fp + -296 ]                        
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
4001bc3c:	c2 27 be e0 	st  %g1, [ %fp + -288 ]                        
  dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;                           
4001bc40:	c2 27 be e4 	st  %g1, [ %fp + -284 ]                        
                dir_pos.sname.ofs = i;                                
4001bc44:	f2 27 be dc 	st  %i1, [ %fp + -292 ]                        
                rc = fat_file_open(&fs_info->fat, &dir_pos, &tmp_fat_fd);
4001bc48:	90 10 00 1d 	mov  %i5, %o0                                  
4001bc4c:	92 07 be d8 	add  %fp, -296, %o1                            
4001bc50:	7f ff d9 96 	call  400122a8 <fat_file_open>                 
4001bc54:	94 07 be cc 	add  %fp, -308, %o2                            
                if (rc != RC_OK)                                      
4001bc58:	84 92 20 00 	orcc  %o0, 0, %g2                              
4001bc5c:	22 80 00 08 	be,a   4001bc7c <msdos_dir_read+0x2dc>         <== ALWAYS TAKEN
4001bc60:	85 3f 20 1f 	sra  %i4, 0x1f, %g2                            
                {                                                     
                    rtems_semaphore_release(fs_info->vol_sema);       
4001bc64:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        <== NOT EXECUTED
4001bc68:	7f ff b5 b5 	call  4000933c <rtems_semaphore_release>       <== NOT EXECUTED
4001bc6c:	c4 27 be a8 	st  %g2, [ %fp + -344 ]                        <== NOT EXECUTED
                }                                                     
                                                                      
                fat_dir_pos_init(&dir_pos);                           
                dir_pos.sname.cln = cur_cln;                          
                dir_pos.sname.ofs = i;                                
                rc = fat_file_open(&fs_info->fat, &dir_pos, &tmp_fat_fd);
4001bc70:	c4 07 be a8 	ld  [ %fp + -344 ], %g2                        <== NOT EXECUTED
                if (rc != RC_OK)                                      
                {                                                     
                    rtems_semaphore_release(fs_info->vol_sema);       
                    return rc;                                        
4001bc74:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001bc78:	91 e8 00 02 	restore  %g0, %g2, %o0                         <== NOT EXECUTED
                }                                                     
                                                                      
                /* fill in dirent structure */                        
                /* XXX: from what and in what d_off should be computed ?! */
                tmp_dirent.d_off = start + cmpltd;                    
4001bc7c:	c4 27 be f0 	st  %g2, [ %fp + -272 ]                        
                tmp_dirent.d_reclen = sizeof(struct dirent);          
4001bc80:	84 10 21 18 	mov  0x118, %g2                                
4001bc84:	c4 37 be f8 	sth  %g2, [ %fp + -264 ]                       
                tmp_dirent.d_ino = tmp_fat_fd->ino;                   
4001bc88:	c4 07 be cc 	ld  [ %fp + -308 ], %g2                        
                    return rc;                                        
                }                                                     
                                                                      
                /* fill in dirent structure */                        
                /* XXX: from what and in what d_off should be computed ?! */
                tmp_dirent.d_off = start + cmpltd;                    
4001bc8c:	f8 27 be f4 	st  %i4, [ %fp + -268 ]                        
                tmp_dirent.d_reclen = sizeof(struct dirent);          
                tmp_dirent.d_ino = tmp_fat_fd->ino;                   
4001bc90:	c4 00 a0 0c 	ld  [ %g2 + 0xc ], %g2                         
                 * If a long file name check if the correct number of entries
                 * have been found and if the checksum is correct and if it is
                 * convertable to utf8 string.  If not return the short file
                 * name.                                              
                 */                                                   
                if (lfn_start != FAT_FILE_SHORT_NAME)                 
4001bc94:	80 a6 ff ff 	cmp  %i3, -1                                   
4001bc98:	02 80 00 2d 	be  4001bd4c <msdos_dir_read+0x3ac>            
4001bc9c:	c4 27 be e8 	st  %g2, [ %fp + -280 ]                        
4001bca0:	86 10 20 00 	clr  %g3                                       
4001bca4:	84 10 20 00 	clr  %g2                                       
                    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;  
4001bca8:	de 0d 80 03 	ldub  [ %l6 + %g3 ], %o7                       
4001bcac:	88 08 a0 01 	and  %g2, 1, %g4                               
4001bcb0:	80 a0 00 04 	cmp  %g0, %g4                                  
4001bcb4:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
4001bcb8:	88 40 3f ff 	addx  %g0, -1, %g4                             
4001bcbc:	85 30 a0 01 	srl  %g2, 1, %g2                               
4001bcc0:	88 09 20 80 	and  %g4, 0x80, %g4                            
4001bcc4:	84 00 80 0f 	add  %g2, %o7, %g2                             
4001bcc8:	88 01 3f 80 	add  %g4, -128, %g4                            
                {                                                     
                    uint8_t  cs = 0;                                  
                    uint8_t* p = (uint8_t*) entry;                    
                    int      i;                                       
                                                                      
                    for (i = 0; i < 11; i++, p++)                     
4001bccc:	86 00 e0 01 	inc  %g3                                       
4001bcd0:	80 a0 e0 0b 	cmp  %g3, 0xb                                  
4001bcd4:	12 bf ff f5 	bne  4001bca8 <msdos_dir_read+0x308>           
4001bcd8:	84 00 80 04 	add  %g2, %g4, %g2                             
                        cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;  
                                                                      
                    if (lfn_entries || (lfn_checksum != cs))          
4001bcdc:	c2 0f be bf 	ldub  [ %fp + -321 ], %g1                      
4001bce0:	84 18 80 01 	xor  %g2, %g1, %g2                             
4001bce4:	80 88 a0 ff 	btst  0xff, %g2                                
4001bce8:	32 80 00 06 	bne,a   4001bd00 <msdos_dir_read+0x360>        <== NEVER TAKEN
4001bcec:	b6 10 3f ff 	mov  -1, %i3                                   <== NOT EXECUTED
4001bcf0:	80 a6 a0 00 	cmp  %i2, 0                                    
4001bcf4:	22 80 00 04 	be,a   4001bd04 <msdos_dir_read+0x364>         <== ALWAYS TAKEN
4001bcf8:	c4 05 e0 0c 	ld  [ %l7 + 0xc ], %g2                         
                        lfn_start = FAT_FILE_SHORT_NAME;              
4001bcfc:	b6 10 3f ff 	mov  -1, %i3                                   <== NOT EXECUTED
                                                                      
                    eno = (*convert_handler->utf16_to_utf8) (         
4001bd00:	c4 05 e0 0c 	ld  [ %l7 + 0xc ], %g2                         <== NOT EXECUTED
4001bd04:	90 10 00 10 	mov  %l0, %o0                                  
4001bd08:	92 10 00 15 	mov  %l5, %o1                                  
4001bd0c:	94 10 00 14 	mov  %l4, %o2                                  
4001bd10:	96 07 be fc 	add  %fp, -260, %o3                            
4001bd14:	9f c0 80 00 	call  %g2                                      
4001bd18:	98 07 be d4 	add  %fp, -300, %o4                            
                        converter,                                    
                        lfn_buf,                                      
                        tmp_lfn_len,                                  
                        (uint8_t*)(&tmp_dirent.d_name[0]),            
                        &string_size);                                
                    if (eno == 0) {                                   
4001bd1c:	80 a2 20 00 	cmp  %o0, 0                                    
4001bd20:	12 80 00 0c 	bne  4001bd50 <msdos_dir_read+0x3b0>           
4001bd24:	92 10 00 16 	mov  %l6, %o1                                  
                      tmp_dirent.d_namlen                    = string_size;
4001bd28:	c4 07 be d4 	ld  [ %fp + -300 ], %g2                        
4001bd2c:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
4001bd30:	c4 37 be fa 	sth  %g2, [ %fp + -262 ]                       
4001bd34:	82 10 63 ff 	or  %g1, 0x3ff, %g1                            
4001bd38:	84 08 80 01 	and  %g2, %g1, %g2                             
                      tmp_dirent.d_name[tmp_dirent.d_namlen] = '\0';  
4001bd3c:	84 07 80 02 	add  %fp, %g2, %g2                             
                    else {                                            
                        lfn_start = FAT_FILE_SHORT_NAME;              
                    }                                                 
                }                                                     
                                                                      
                if (lfn_start == FAT_FILE_SHORT_NAME)                 
4001bd40:	80 a6 ff ff 	cmp  %i3, -1                                   
4001bd44:	12 80 00 28 	bne  4001bde4 <msdos_dir_read+0x444>           <== ALWAYS TAKEN
4001bd48:	c0 28 be fc 	clrb  [ %g2 + -260 ]                           
                {                                                     
                    /*                                                
                     * 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(
4001bd4c:	92 10 00 16 	mov  %l6, %o1                                  
4001bd50:	7f ff f3 81 	call  40018b54 <msdos_format_dirent_with_dot>  
4001bd54:	90 10 00 15 	mov  %l5, %o0                                  
                        sfn_buf, entry); /* src text */               
                    eno = (*convert_handler->codepage_to_utf8) (      
4001bd58:	c2 05 e0 04 	ld  [ %l7 + 4 ], %g1                           
4001bd5c:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
4001bd60:	84 10 a3 ff 	or  %g2, 0x3ff, %g2	! ffff <_TLS_Alignment+0xfffe>
                {                                                     
                    /*                                                
                     * 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(
4001bd64:	94 10 00 08 	mov  %o0, %o2                                  
4001bd68:	d0 37 be fa 	sth  %o0, [ %fp + -262 ]                       
                        sfn_buf, entry); /* src text */               
                    eno = (*convert_handler->codepage_to_utf8) (      
4001bd6c:	92 10 00 15 	mov  %l5, %o1                                  
4001bd70:	90 10 00 10 	mov  %l0, %o0                                  
4001bd74:	94 0a 80 02 	and  %o2, %g2, %o2                             
4001bd78:	96 07 be fc 	add  %fp, -260, %o3                            
4001bd7c:	9f c0 40 00 	call  %g1                                      
4001bd80:	98 07 be d4 	add  %fp, -300, %o4                            
                        converter,                                    
                        sfn_buf,                                      
                        tmp_dirent.d_namlen,                          
                        (uint8_t*)(&tmp_dirent.d_name[0]),            
                        &string_size);                                
                    if ( 0 == eno ) {                                 
4001bd84:	b6 92 20 00 	orcc  %o0, 0, %i3                              
4001bd88:	12 80 00 0a 	bne  4001bdb0 <msdos_dir_read+0x410>           <== NEVER TAKEN
4001bd8c:	c2 07 be d4 	ld  [ %fp + -300 ], %g1                        
4001bd90:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
                      tmp_dirent.d_namlen                    = string_size;
4001bd94:	c2 37 be fa 	sth  %g1, [ %fp + -262 ]                       
4001bd98:	84 10 a3 ff 	or  %g2, 0x3ff, %g2                            
4001bd9c:	b6 10 3f ff 	mov  -1, %i3                                   
4001bda0:	82 08 40 02 	and  %g1, %g2, %g1                             
                      tmp_dirent.d_name[tmp_dirent.d_namlen] = '\0';  
4001bda4:	82 07 80 01 	add  %fp, %g1, %g1                             
4001bda8:	10 80 00 0f 	b  4001bde4 <msdos_dir_read+0x444>             
4001bdac:	c0 28 7e fc 	clrb  [ %g1 + -260 ]                           
                    }                                                 
                    else {                                            
                        cmpltd = -1;                                  
                        errno  = eno;                                 
4001bdb0:	40 00 01 b7 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001bdb4:	b8 10 3f ff 	mov  -1, %i4                                   <== NOT EXECUTED
4001bdb8:	f6 22 00 00 	st  %i3, [ %o0 ]                               <== NOT EXECUTED
4001bdbc:	10 bf ff 73 	b  4001bb88 <msdos_dir_read+0x1e8>             <== NOT EXECUTED
4001bdc0:	b6 10 3f ff 	mov  -1, %i3                                   <== NOT EXECUTED
                 */                                                   
                if ((lfn_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &   
                                     MSDOS_LAST_LONG_ENTRY_MASK)) ||  
                    (lfn_checksum != *MSDOS_DIR_LFN_CHECKSUM(entry))) 
                {                                                     
                    lfn_start = FAT_FILE_SHORT_NAME;                  
4001bdc4:	b6 10 3f ff 	mov  -1, %i3                                   
        {                                                             
            rtems_semaphore_release(fs_info->vol_sema);               
            rtems_set_errno_and_return_minus_one(EIO);                
        }                                                             
                                                                      
        for (i = 0; i < ret && cmpltd >= 0; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
4001bdc8:	10 bf ff 41 	b  4001bacc <msdos_dir_read+0x12c>             
4001bdcc:	b2 06 60 20 	add  %i1, 0x20, %i1                            
                break;                                                
        }                                                             
        j++;                                                          
    }                                                                 
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001bdd0:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001bdd4:	7f ff b5 5a 	call  4000933c <rtems_semaphore_release>       
4001bdd8:	b0 10 00 1c 	mov  %i4, %i0                                  
    return cmpltd;                                                    
4001bddc:	81 c7 e0 08 	ret                                            
4001bde0:	81 e8 00 00 	restore                                        
                        errno  = eno;                                 
                    }                                                 
                }                                                     
                                                                      
                if ( cmpltd >= 0 ) {                                  
                    memcpy(buffer + cmpltd, &tmp_dirent, sizeof(struct dirent));
4001bde4:	c2 07 a0 48 	ld  [ %fp + 0x48 ], %g1                        
4001bde8:	92 07 be e8 	add  %fp, -280, %o1                            
4001bdec:	90 00 40 1c 	add  %g1, %i4, %o0                             
4001bdf0:	40 00 03 fc 	call  4001cde0 <memcpy>                        
4001bdf4:	94 10 21 18 	mov  0x118, %o2                                
                                                                      
                    iop->offset = iop->offset + sizeof(struct dirent);
4001bdf8:	c4 1e 20 08 	ldd  [ %i0 + 8 ], %g2                          
                    cmpltd += (sizeof(struct dirent));                
                    count -= (sizeof(struct dirent));                 
                                                                      
                    /* inode number extracted, close fat-file */      
                    rc = fat_file_close(&fs_info->fat, tmp_fat_fd);   
4001bdfc:	d2 07 be cc 	ld  [ %fp + -308 ], %o1                        
                }                                                     
                                                                      
                if ( cmpltd >= 0 ) {                                  
                    memcpy(buffer + cmpltd, &tmp_dirent, sizeof(struct dirent));
                                                                      
                    iop->offset = iop->offset + sizeof(struct dirent);
4001be00:	9a 80 e1 18 	addcc  %g3, 0x118, %o5                         
4001be04:	98 40 a0 00 	addx  %g2, 0, %o4                              
                    cmpltd += (sizeof(struct dirent));                
                    count -= (sizeof(struct dirent));                 
                                                                      
                    /* inode number extracted, close fat-file */      
                    rc = fat_file_close(&fs_info->fat, tmp_fat_fd);   
4001be08:	90 10 00 1d 	mov  %i5, %o0                                  
                }                                                     
                                                                      
                if ( cmpltd >= 0 ) {                                  
                    memcpy(buffer + cmpltd, &tmp_dirent, sizeof(struct dirent));
                                                                      
                    iop->offset = iop->offset + sizeof(struct dirent);
4001be0c:	d8 3e 20 08 	std  %o4, [ %i0 + 8 ]                          
                    cmpltd += (sizeof(struct dirent));                
                    count -= (sizeof(struct dirent));                 
                                                                      
                    /* inode number extracted, close fat-file */      
                    rc = fat_file_close(&fs_info->fat, tmp_fat_fd);   
4001be10:	7f ff da 3e 	call  40012708 <fat_file_close>                
4001be14:	b8 07 21 18 	add  %i4, 0x118, %i4                           
                    if (rc != RC_OK)                                  
4001be18:	82 92 20 00 	orcc  %o0, 0, %g1                              
4001be1c:	02 bf ff 5b 	be  4001bb88 <msdos_dir_read+0x1e8>            <== ALWAYS TAKEN
4001be20:	a6 04 fe e8 	add  %l3, -280, %l3                            
                    {                                                 
                        rtems_semaphore_release(fs_info->vol_sema);   
4001be24:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        <== NOT EXECUTED
4001be28:	7f ff b5 45 	call  4000933c <rtems_semaphore_release>       <== NOT EXECUTED
4001be2c:	c2 27 be ac 	st  %g1, [ %fp + -340 ]                        <== NOT EXECUTED
                    iop->offset = iop->offset + sizeof(struct dirent);
                    cmpltd += (sizeof(struct dirent));                
                    count -= (sizeof(struct dirent));                 
                                                                      
                    /* inode number extracted, close fat-file */      
                    rc = fat_file_close(&fs_info->fat, tmp_fat_fd);   
4001be30:	c2 07 be ac 	ld  [ %fp + -340 ], %g1                        <== NOT EXECUTED
                    if (rc != RC_OK)                                  
                    {                                                 
                        rtems_semaphore_release(fs_info->vol_sema);   
                        return rc;                                    
4001be34:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001be38:	91 e8 00 01 	restore  %g0, %g1, %o0                         <== NOT EXECUTED
                                                                      

4001be3c <msdos_dir_stat>: int msdos_dir_stat( const rtems_filesystem_location_info_t *loc, struct stat *buf ) {
4001be3c:	9d e3 bf a0 	save  %sp, -96, %sp                            
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = loc->mt_entry->fs_info;              
4001be40:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
    fat_file_fd_t     *fat_fd = loc->node_access;                     
4001be44:	f8 06 20 08 	ld  [ %i0 + 8 ], %i4                           
    const 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;              
4001be48:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    fat_file_fd_t     *fat_fd = loc->node_access;                     
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001be4c:	92 10 20 00 	clr  %o1                                       
4001be50:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001be54:	7f ff b4 f2 	call  4000921c <rtems_semaphore_obtain>        
4001be58:	94 10 20 00 	clr  %o2                                       
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001be5c:	80 a2 20 00 	cmp  %o0, 0                                    
4001be60:	22 80 00 08 	be,a   4001be80 <msdos_dir_stat+0x44>          <== ALWAYS TAKEN
4001be64:	c2 07 60 64 	ld  [ %i5 + 0x64 ], %g1                        
        rtems_set_errno_and_return_minus_one(EIO);                    
4001be68:	40 00 01 89 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001be6c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001be70:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001be74:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001be78:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001be7c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    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;                                    
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001be80:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
    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 = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
4001be84:	c4 18 40 00 	ldd  [ %g1 ], %g2                              
    buf->st_ino = fat_fd->ino;                                        
4001be88:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
    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 = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
4001be8c:	c4 3e 40 00 	std  %g2, [ %i1 ]                              
    buf->st_ino = fat_fd->ino;                                        
4001be90:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]                           
    buf->st_mode  = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;            
4001be94:	03 00 00 10 	sethi  %hi(0x4000), %g1                        
4001be98:	82 10 61 ff 	or  %g1, 0x1ff, %g1	! 41ff <_TLS_Alignment+0x41fe>
4001be9c:	c2 26 60 0c 	st  %g1, [ %i1 + 0xc ]                         
    buf->st_rdev = 0ll;                                               
    buf->st_size = fat_fd->fat_file_size;                             
4001bea0:	c2 07 20 18 	ld  [ %i4 + 0x18 ], %g1                        
        rtems_set_errno_and_return_minus_one(EIO);                    
                                                                      
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    buf->st_ino = fat_fd->ino;                                        
    buf->st_mode  = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;            
    buf->st_rdev = 0ll;                                               
4001bea4:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            
    buf->st_size = fat_fd->fat_file_size;                             
4001bea8:	c2 26 60 24 	st  %g1, [ %i1 + 0x24 ]                        
    buf->st_blocks = fat_fd->fat_file_size >> FAT_SECTOR512_BITS;     
4001beac:	83 30 60 09 	srl  %g1, 9, %g1                               
4001beb0:	c2 26 60 44 	st  %g1, [ %i1 + 0x44 ]                        
    buf->st_blksize = fs_info->fat.vol.bps;                           
4001beb4:	c2 17 40 00 	lduh  [ %i5 ], %g1                             
        rtems_set_errno_and_return_minus_one(EIO);                    
                                                                      
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    buf->st_ino = fat_fd->ino;                                        
    buf->st_mode  = S_IFDIR | S_IRWXU | S_IRWXG | S_IRWXO;            
    buf->st_rdev = 0ll;                                               
4001beb8:	c0 26 60 1c 	clr  [ %i1 + 0x1c ]                            
    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;                           
4001bebc:	c2 26 60 40 	st  %g1, [ %i1 + 0x40 ]                        
    buf->st_mtime = fat_fd->mtime;                                    
4001bec0:	c2 07 20 40 	ld  [ %i4 + 0x40 ], %g1                        
                                                                      
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    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;                             
4001bec4:	c0 26 60 20 	clr  [ %i1 + 0x20 ]                            
    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;                                    
4001bec8:	c2 26 60 30 	st  %g1, [ %i1 + 0x30 ]                        
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001becc:	7f ff b5 1c 	call  4000933c <rtems_semaphore_release>       
4001bed0:	b0 10 20 00 	clr  %i0                                       
    return RC_OK;                                                     
}                                                                     
4001bed4:	81 c7 e0 08 	ret                                            
4001bed8:	81 e8 00 00 	restore                                        
                                                                      

4001bf38 <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) {
4001bf38:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int                rc = RC_OK;                                    
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001bf3c:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001bf40:	92 10 20 00 	clr  %o1                                       
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;     
4001bf44:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001bf48:	94 10 20 00 	clr  %o2                                       
4001bf4c:	7f ff b4 b4 	call  4000921c <rtems_semaphore_obtain>        
4001bf50:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001bf54:	80 a2 20 00 	cmp  %o0, 0                                    
4001bf58:	02 80 00 08 	be  4001bf78 <msdos_file_close+0x40>           <== ALWAYS TAKEN
4001bf5c:	01 00 00 00 	nop                                            
        rtems_set_errno_and_return_minus_one(EIO);                    
4001bf60:	40 00 01 4b 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001bf64:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
4001bf68:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001bf6c:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001bf70:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001bf74:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    rc = msdos_file_update(iop);                                      
4001bf78:	7f ff ff d9 	call  4001bedc <msdos_file_update>             
4001bf7c:	90 10 00 18 	mov  %i0, %o0                                  
4001bf80:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001bf84:	7f ff b4 ee 	call  4000933c <rtems_semaphore_release>       
4001bf88:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
    return rc;                                                        
}                                                                     
4001bf8c:	81 c7 e0 08 	ret                                            
4001bf90:	81 e8 00 00 	restore                                        
                                                                      

4001c1a4 <msdos_file_ftruncate>: * RETURNS: * RC_OK on success, or -1 if error occured (errno set appropriately). */ int msdos_file_ftruncate(rtems_libio_t *iop, off_t length) {
4001c1a4:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                rc = RC_OK;                                    
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001c1a8:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
4001c1ac:	f8 06 20 1c 	ld  [ %i0 + 0x1c ], %i4                        
int                                                                   
msdos_file_ftruncate(rtems_libio_t *iop, off_t length)                
{                                                                     
    int                rc = RC_OK;                                    
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001c1b0:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
    uint32_t old_length;                                              
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001c1b4:	92 10 20 00 	clr  %o1                                       
4001c1b8:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001c1bc:	7f ff b4 18 	call  4000921c <rtems_semaphore_obtain>        
4001c1c0:	94 10 20 00 	clr  %o2                                       
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001c1c4:	80 a2 20 00 	cmp  %o0, 0                                    
4001c1c8:	02 80 00 08 	be  4001c1e8 <msdos_file_ftruncate+0x44>       <== ALWAYS TAKEN
4001c1cc:	80 a2 00 19 	cmp  %o0, %i1                                  
        rtems_set_errno_and_return_minus_one(EIO);                    
4001c1d0:	40 00 00 af 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001c1d4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001c1d8:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001c1dc:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001c1e0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c1e4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    old_length = fat_fd->fat_file_size;                               
    if (length < old_length) {                                        
4001c1e8:	14 80 00 08 	bg  4001c208 <msdos_file_ftruncate+0x64>       <== NEVER TAKEN
4001c1ec:	f6 07 20 18 	ld  [ %i4 + 0x18 ], %i3                        
4001c1f0:	80 a2 00 19 	cmp  %o0, %i1                                  
4001c1f4:	12 80 00 0d 	bne  4001c228 <msdos_file_ftruncate+0x84>      <== NEVER TAKEN
4001c1f8:	90 10 00 1d 	mov  %i5, %o0                                  
4001c1fc:	80 a6 c0 1a 	cmp  %i3, %i2                                  
4001c200:	08 80 00 0b 	bleu  4001c22c <msdos_file_ftruncate+0x88>     
4001c204:	92 10 00 1c 	mov  %i4, %o1                                  
        rc = fat_file_truncate(&fs_info->fat, fat_fd, length);        
4001c208:	90 10 00 1d 	mov  %i5, %o0                                  
4001c20c:	92 10 00 1c 	mov  %i4, %o1                                  
4001c210:	7f ff d8 f9 	call  400125f4 <fat_file_truncate>             
4001c214:	94 10 00 1a 	mov  %i2, %o2                                  
            errno = ENOSPC;                                           
            rc = -1;                                                  
        }                                                             
    }                                                                 
                                                                      
    if (rc == RC_OK) {                                                
4001c218:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c21c:	22 80 00 18 	be,a   4001c27c <msdos_file_ftruncate+0xd8>    <== ALWAYS TAKEN
4001c220:	f4 27 20 18 	st  %i2, [ %i4 + 0x18 ]                        
4001c224:	30 80 00 16 	b,a   4001c27c <msdos_file_ftruncate+0xd8>     <== NOT EXECUTED
    if (length < old_length) {                                        
        rc = fat_file_truncate(&fs_info->fat, fat_fd, length);        
    } else {                                                          
        uint32_t new_length;                                          
                                                                      
        rc = fat_file_extend(&fs_info->fat,                           
4001c228:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001c22c:	94 10 20 01 	mov  1, %o2                                    
4001c230:	96 10 00 1a 	mov  %i2, %o3                                  
4001c234:	7f ff d9 97 	call  40012890 <fat_file_extend>               
4001c238:	98 07 bf fc 	add  %fp, -4, %o4                              
                             fat_fd,                                  
                             true,                                    
                             length,                                  
                             &new_length);                            
        if (rc == RC_OK && length != new_length) {                    
4001c23c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c240:	12 80 00 0f 	bne  4001c27c <msdos_file_ftruncate+0xd8>      <== NEVER TAKEN
4001c244:	80 a6 60 00 	cmp  %i1, 0                                    
4001c248:	12 80 00 05 	bne  4001c25c <msdos_file_ftruncate+0xb8>      <== NEVER TAKEN
4001c24c:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4001c250:	80 a6 80 01 	cmp  %i2, %g1                                  
4001c254:	22 80 00 0a 	be,a   4001c27c <msdos_file_ftruncate+0xd8>    <== ALWAYS TAKEN
4001c258:	f4 27 20 18 	st  %i2, [ %i4 + 0x18 ]                        
            fat_file_truncate(&fs_info->fat, fat_fd, old_length);     
4001c25c:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001c260:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
4001c264:	7f ff d8 e4 	call  400125f4 <fat_file_truncate>             <== NOT EXECUTED
4001c268:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
            errno = ENOSPC;                                           
4001c26c:	40 00 00 88 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001c270:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001c274:	82 10 20 1c 	mov  0x1c, %g1                                 <== NOT EXECUTED
4001c278:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
                                                                      
    if (rc == RC_OK) {                                                
        fat_fd->fat_file_size = length;                               
    }                                                                 
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001c27c:	7f ff b4 30 	call  4000933c <rtems_semaphore_release>       
4001c280:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
                                                                      
    return rc;                                                        
}                                                                     
4001c284:	81 c7 e0 08 	ret                                            
4001c288:	81 e8 00 00 	restore                                        
                                                                      

4001bf94 <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) {
4001bf94:	9d e3 bf a0 	save  %sp, -96, %sp                            
    ssize_t            ret = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001bf98:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
4001bf9c:	fa 06 20 1c 	ld  [ %i0 + 0x1c ], %i5                        
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;     
4001bfa0:	e0 00 60 08 	ld  [ %g1 + 8 ], %l0                           
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001bfa4:	92 10 20 00 	clr  %o1                                       
4001bfa8:	d0 04 20 9c 	ld  [ %l0 + 0x9c ], %o0                        
4001bfac:	7f ff b4 9c 	call  4000921c <rtems_semaphore_obtain>        
4001bfb0:	94 10 20 00 	clr  %o2                                       
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001bfb4:	80 a2 20 00 	cmp  %o0, 0                                    
4001bfb8:	22 80 00 08 	be,a   4001bfd8 <msdos_file_read+0x44>         <== ALWAYS TAKEN
4001bfbc:	d4 06 20 0c 	ld  [ %i0 + 0xc ], %o2                         
        rtems_set_errno_and_return_minus_one(EIO);                    
4001bfc0:	40 00 01 33 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001bfc4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001bfc8:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001bfcc:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001bfd0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001bfd4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    ret = fat_file_read(&fs_info->fat, fat_fd, iop->offset, count,    
4001bfd8:	98 10 00 19 	mov  %i1, %o4                                  
4001bfdc:	90 10 00 10 	mov  %l0, %o0                                  
4001bfe0:	92 10 00 1d 	mov  %i5, %o1                                  
4001bfe4:	7f ff d9 17 	call  40012440 <fat_file_read>                 
4001bfe8:	96 10 00 1a 	mov  %i2, %o3                                  
                        buffer);                                      
    if (ret > 0)                                                      
4001bfec:	b2 92 20 00 	orcc  %o0, 0, %i1                              
4001bff0:	04 80 00 06 	ble  4001c008 <msdos_file_read+0x74>           
4001bff4:	85 3e 60 1f 	sra  %i1, 0x1f, %g2                            
        iop->offset += ret;                                           
4001bff8:	f8 1e 20 08 	ldd  [ %i0 + 8 ], %i4                          
4001bffc:	b6 87 40 19 	addcc  %i5, %i1, %i3                           
4001c000:	b4 47 00 02 	addx  %i4, %g2, %i2                            
4001c004:	f4 3e 20 08 	std  %i2, [ %i0 + 8 ]                          
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001c008:	d0 04 20 9c 	ld  [ %l0 + 0x9c ], %o0                        
4001c00c:	7f ff b4 cc 	call  4000933c <rtems_semaphore_release>       
4001c010:	b0 10 00 19 	mov  %i1, %i0                                  
    return ret;                                                       
}                                                                     
4001c014:	81 c7 e0 08 	ret                                            
4001c018:	81 e8 00 00 	restore                                        
                                                                      

4001c0f4 <msdos_file_stat>: int msdos_file_stat( const rtems_filesystem_location_info_t *loc, struct stat *buf ) {
4001c0f4:	9d e3 bf a0 	save  %sp, -96, %sp                            
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = loc->mt_entry->fs_info;              
4001c0f8:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
    fat_file_fd_t     *fat_fd = loc->node_access;                     
4001c0fc:	f8 06 20 08 	ld  [ %i0 + 8 ], %i4                           
    const 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;              
4001c100:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    fat_file_fd_t     *fat_fd = loc->node_access;                     
    uint32_t           cl_mask = fs_info->fat.vol.bpc - 1;            
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001c104:	92 10 20 00 	clr  %o1                                       
)                                                                     
{                                                                     
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = loc->mt_entry->fs_info;              
    fat_file_fd_t     *fat_fd = loc->node_access;                     
    uint32_t           cl_mask = fs_info->fat.vol.bpc - 1;            
4001c108:	f6 17 60 06 	lduh  [ %i5 + 6 ], %i3                         
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001c10c:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001c110:	94 10 20 00 	clr  %o2                                       
4001c114:	7f ff b4 42 	call  4000921c <rtems_semaphore_obtain>        
4001c118:	b6 06 ff ff 	add  %i3, -1, %i3                              
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001c11c:	80 a2 20 00 	cmp  %o0, 0                                    
4001c120:	22 80 00 08 	be,a   4001c140 <msdos_file_stat+0x4c>         <== ALWAYS TAKEN
4001c124:	c2 07 60 64 	ld  [ %i5 + 0x64 ], %g1                        
        rtems_set_errno_and_return_minus_one(EIO);                    
4001c128:	40 00 00 d9 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001c12c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001c130:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001c134:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001c138:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c13c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    buf->st_blocks = ((fat_fd->fat_file_size + cl_mask) & ~cl_mask)   
      >> FAT_SECTOR512_BITS;                                          
    buf->st_blksize = fs_info->fat.vol.bpc;                           
    buf->st_mtime = fat_fd->mtime;                                    
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001c140:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
    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 = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
4001c144:	c4 18 40 00 	ldd  [ %g1 ], %g2                              
    buf->st_ino = fat_fd->ino;                                        
4001c148:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
    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 = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
4001c14c:	c4 3e 40 00 	std  %g2, [ %i1 ]                              
    buf->st_ino = fat_fd->ino;                                        
4001c150:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]                           
    buf->st_mode  = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;            
4001c154:	03 00 00 20 	sethi  %hi(0x8000), %g1                        
4001c158:	82 10 61 ff 	or  %g1, 0x1ff, %g1	! 81ff <_TLS_Alignment+0x81fe>
4001c15c:	c2 26 60 0c 	st  %g1, [ %i1 + 0xc ]                         
    buf->st_rdev = 0ll;                                               
    buf->st_size = fat_fd->fat_file_size;                             
4001c160:	c2 07 20 18 	ld  [ %i4 + 0x18 ], %g1                        
        rtems_set_errno_and_return_minus_one(EIO);                    
                                                                      
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    buf->st_ino = fat_fd->ino;                                        
    buf->st_mode  = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;            
    buf->st_rdev = 0ll;                                               
4001c164:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            
    buf->st_size = fat_fd->fat_file_size;                             
4001c168:	c2 26 60 24 	st  %g1, [ %i1 + 0x24 ]                        
    buf->st_blocks = ((fat_fd->fat_file_size + cl_mask) & ~cl_mask)   
4001c16c:	82 06 c0 01 	add  %i3, %g1, %g1                             
4001c170:	b6 28 40 1b 	andn  %g1, %i3, %i3                            
      >> FAT_SECTOR512_BITS;                                          
    buf->st_blksize = fs_info->fat.vol.bpc;                           
4001c174:	c2 17 60 06 	lduh  [ %i5 + 6 ], %g1                         
        rtems_set_errno_and_return_minus_one(EIO);                    
                                                                      
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    buf->st_ino = fat_fd->ino;                                        
    buf->st_mode  = S_IFREG | S_IRWXU | S_IRWXG | S_IRWXO;            
    buf->st_rdev = 0ll;                                               
4001c178:	c0 26 60 1c 	clr  [ %i1 + 0x1c ]                            
    buf->st_size = fat_fd->fat_file_size;                             
    buf->st_blocks = ((fat_fd->fat_file_size + cl_mask) & ~cl_mask)   
      >> FAT_SECTOR512_BITS;                                          
    buf->st_blksize = fs_info->fat.vol.bpc;                           
4001c17c:	c2 26 60 40 	st  %g1, [ %i1 + 0x40 ]                        
    buf->st_mtime = fat_fd->mtime;                                    
4001c180:	c2 07 20 40 	ld  [ %i4 + 0x40 ], %g1                        
                                                                      
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    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;                             
4001c184:	c0 26 60 20 	clr  [ %i1 + 0x20 ]                            
    buf->st_blocks = ((fat_fd->fat_file_size + cl_mask) & ~cl_mask)   
      >> FAT_SECTOR512_BITS;                                          
4001c188:	b7 36 e0 09 	srl  %i3, 9, %i3                               
    buf->st_blksize = fs_info->fat.vol.bpc;                           
    buf->st_mtime = fat_fd->mtime;                                    
4001c18c:	c2 26 60 30 	st  %g1, [ %i1 + 0x30 ]                        
    buf->st_dev = rtems_disk_get_device_identifier(fs_info->fat.vol.dd);
    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 + cl_mask) & ~cl_mask)   
4001c190:	f6 26 60 44 	st  %i3, [ %i1 + 0x44 ]                        
      >> FAT_SECTOR512_BITS;                                          
    buf->st_blksize = fs_info->fat.vol.bpc;                           
    buf->st_mtime = fat_fd->mtime;                                    
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001c194:	7f ff b4 6a 	call  4000933c <rtems_semaphore_release>       
4001c198:	b0 10 20 00 	clr  %i0                                       
    return RC_OK;                                                     
}                                                                     
4001c19c:	81 c7 e0 08 	ret                                            
4001c1a0:	81 e8 00 00 	restore                                        
                                                                      

4001c28c <msdos_file_sync>: * RETURNS: * RC_OK on success, or -1 if error occured (errno set appropriately) */ int msdos_file_sync(rtems_libio_t *iop) {
4001c28c:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int                rc = RC_OK;                                    
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001c290:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001c294:	92 10 20 00 	clr  %o1                                       
int                                                                   
msdos_file_sync(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;     
4001c298:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001c29c:	94 10 20 00 	clr  %o2                                       
4001c2a0:	7f ff b3 df 	call  4000921c <rtems_semaphore_obtain>        
4001c2a4:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001c2a8:	80 a2 20 00 	cmp  %o0, 0                                    
4001c2ac:	02 80 00 08 	be  4001c2cc <msdos_file_sync+0x40>            <== ALWAYS TAKEN
4001c2b0:	01 00 00 00 	nop                                            
        rtems_set_errno_and_return_minus_one(EIO);                    
4001c2b4:	40 00 00 76 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001c2b8:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
4001c2bc:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001c2c0:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001c2c4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c2c8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    rc = msdos_file_update(iop);                                      
4001c2cc:	7f ff ff 04 	call  4001bedc <msdos_file_update>             
4001c2d0:	90 10 00 18 	mov  %i0, %o0                                  
    if (rc != RC_OK)                                                  
4001c2d4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c2d8:	02 80 00 06 	be  4001c2f0 <msdos_file_sync+0x64>            <== ALWAYS TAKEN
4001c2dc:	01 00 00 00 	nop                                            
    {                                                                 
        rtems_semaphore_release(fs_info->vol_sema);                   
4001c2e0:	7f ff b4 17 	call  4000933c <rtems_semaphore_release>       <== NOT EXECUTED
4001c2e4:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        <== NOT EXECUTED
        return rc;                                                    
4001c2e8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c2ec:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    }                                                                 
                                                                      
    rc = fat_sync(&fs_info->fat);                                     
4001c2f0:	7f ff de 4a 	call  40013c18 <fat_sync>                      
4001c2f4:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001c2f8:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001c2fc:	7f ff b4 10 	call  4000933c <rtems_semaphore_release>       
4001c300:	b0 10 20 00 	clr  %i0                                       
    return RC_OK;                                                     
}                                                                     
4001c304:	81 c7 e0 08 	ret                                            
4001c308:	81 e8 00 00 	restore                                        
                                                                      

4001bedc <msdos_file_update>: #include "msdos.h" static int msdos_file_update(rtems_libio_t *iop) {
4001bedc:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int              rc = RC_OK;                                      
    fat_file_fd_t   *fat_fd = iop->pathinfo.node_access;              
4001bee0:	f2 06 20 1c 	ld  [ %i0 + 0x1c ], %i1                        
                                                                      
    /*                                                                
     * 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))                                 
4001bee4:	c2 0e 60 30 	ldub  [ %i1 + 0x30 ], %g1                      
4001bee8:	80 88 60 01 	btst  1, %g1                                   
4001beec:	12 80 00 11 	bne  4001bf30 <msdos_file_update+0x54>         <== NEVER TAKEN
4001bef0:	90 10 20 00 	clr  %o0                                       
    {                                                                 
        rc = msdos_set_first_cluster_num(iop->pathinfo.mt_entry, fat_fd);
4001bef4:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
4001bef8:	7f ff f2 1c 	call  40018768 <msdos_set_first_cluster_num>   
4001befc:	92 10 00 19 	mov  %i1, %o1                                  
        if (rc != RC_OK)                                              
4001bf00:	80 a2 20 00 	cmp  %o0, 0                                    
4001bf04:	12 80 00 0b 	bne  4001bf30 <msdos_file_update+0x54>         <== NEVER TAKEN
4001bf08:	01 00 00 00 	nop                                            
        {                                                             
            return rc;                                                
        }                                                             
                                                                      
        rc = msdos_set_file_size(iop->pathinfo.mt_entry, fat_fd);     
4001bf0c:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
4001bf10:	7f ff f2 43 	call  4001881c <msdos_set_file_size>           
4001bf14:	92 10 00 19 	mov  %i1, %o1                                  
        if (rc != RC_OK)                                              
4001bf18:	80 a2 20 00 	cmp  %o0, 0                                    
4001bf1c:	12 80 00 05 	bne  4001bf30 <msdos_file_update+0x54>         <== NEVER TAKEN
4001bf20:	01 00 00 00 	nop                                            
        {                                                             
            return rc;                                                
        }                                                             
                                                                      
        rc = msdos_set_dir_wrt_time_and_date(iop->pathinfo.mt_entry, fat_fd);
4001bf24:	f0 06 20 28 	ld  [ %i0 + 0x28 ], %i0                        
4001bf28:	7f ff f1 d6 	call  40018680 <msdos_set_dir_wrt_time_and_date>
4001bf2c:	81 e8 00 00 	restore                                        
            return rc;                                                
        }                                                             
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
4001bf30:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001bf34:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

4001c01c <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) {
4001c01c:	9d e3 bf a0 	save  %sp, -96, %sp                            
    ssize_t            ret = 0;                                       
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
4001c020:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
4001c024:	e0 06 20 1c 	ld  [ %i0 + 0x1c ], %l0                        
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;     
4001c028:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    fat_file_fd_t     *fat_fd = iop->pathinfo.node_access;            
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
4001c02c:	92 10 20 00 	clr  %o1                                       
4001c030:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
4001c034:	7f ff b4 7a 	call  4000921c <rtems_semaphore_obtain>        
4001c038:	94 10 20 00 	clr  %o2                                       
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4001c03c:	80 a2 20 00 	cmp  %o0, 0                                    
4001c040:	22 80 00 08 	be,a   4001c060 <msdos_file_write+0x44>        <== ALWAYS TAKEN
4001c044:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
        rtems_set_errno_and_return_minus_one(EIO);                    
4001c048:	40 00 01 11 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001c04c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001c050:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001c054:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001c058:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c05c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    if ((iop->flags & LIBIO_FLAGS_APPEND) != 0)                       
4001c060:	80 88 62 00 	btst  0x200, %g1                               
4001c064:	22 80 00 06 	be,a   4001c07c <msdos_file_write+0x60>        
4001c068:	d4 06 20 0c 	ld  [ %i0 + 0xc ], %o2                         
        iop->offset = fat_fd->fat_file_size;                          
4001c06c:	c2 04 20 18 	ld  [ %l0 + 0x18 ], %g1                        
4001c070:	c0 26 20 08 	clr  [ %i0 + 8 ]                               
4001c074:	c2 26 20 0c 	st  %g1, [ %i0 + 0xc ]                         
                                                                      
    ret = fat_file_write(&fs_info->fat, fat_fd, iop->offset, count,   
4001c078:	d4 06 20 0c 	ld  [ %i0 + 0xc ], %o2                         
4001c07c:	98 10 00 19 	mov  %i1, %o4                                  
4001c080:	90 10 00 1d 	mov  %i5, %o0                                  
4001c084:	92 10 00 10 	mov  %l0, %o1                                  
4001c088:	7f ff da 91 	call  40012acc <fat_file_write>                
4001c08c:	96 10 00 1a 	mov  %i2, %o3                                  
                         buffer);                                     
    if (ret < 0)                                                      
4001c090:	b2 92 20 00 	orcc  %o0, 0, %i1                              
4001c094:	16 80 00 06 	bge  4001c0ac <msdos_file_write+0x90>          
4001c098:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
    {                                                                 
        rtems_semaphore_release(fs_info->vol_sema);                   
4001c09c:	7f ff b4 a8 	call  4000933c <rtems_semaphore_release>       
4001c0a0:	b0 10 3f ff 	mov  -1, %i0                                   
        return -1;                                                    
4001c0a4:	81 c7 e0 08 	ret                                            
4001c0a8:	81 e8 00 00 	restore                                        
                                                                      
    /*                                                                
     * update file size in both fat-file descriptor and file control block if
     * file was extended                                              
     */                                                               
    iop->offset += ret;                                               
4001c0ac:	f4 1e 20 08 	ldd  [ %i0 + 8 ], %i2                          
4001c0b0:	b9 3e 60 1f 	sra  %i1, 0x1f, %i4                            
4001c0b4:	86 86 40 1b 	addcc  %i1, %i3, %g3                           
4001c0b8:	84 47 00 1a 	addx  %i4, %i2, %g2                            
4001c0bc:	c4 3e 20 08 	std  %g2, [ %i0 + 8 ]                          
    if (iop->offset > fat_fd->fat_file_size)                          
4001c0c0:	80 a0 a0 00 	cmp  %g2, 0                                    
4001c0c4:	14 80 00 07 	bg  4001c0e0 <msdos_file_write+0xc4>           <== NEVER TAKEN
4001c0c8:	c2 04 20 18 	ld  [ %l0 + 0x18 ], %g1                        
4001c0cc:	80 a0 a0 00 	cmp  %g2, 0                                    
4001c0d0:	12 80 00 05 	bne  4001c0e4 <msdos_file_write+0xc8>          <== NEVER TAKEN
4001c0d4:	80 a0 c0 01 	cmp  %g3, %g1                                  
4001c0d8:	08 80 00 03 	bleu  4001c0e4 <msdos_file_write+0xc8>         
4001c0dc:	01 00 00 00 	nop                                            
        fat_fd->fat_file_size = iop->offset;                          
4001c0e0:	c6 24 20 18 	st  %g3, [ %l0 + 0x18 ]                        
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001c0e4:	7f ff b4 96 	call  4000933c <rtems_semaphore_release>       
4001c0e8:	b0 10 00 19 	mov  %i1, %i0                                  
    return ret;                                                       
}                                                                     
4001c0ec:	81 c7 e0 08 	ret                                            
4001c0f0:	81 e8 00 00 	restore                                        
                                                                      

4001b160 <msdos_filename_process_dot_names>: static ssize_t msdos_filename_process_dot_names (const uint8_t *src_name, const size_t src_size, uint8_t *dest_name, const size_t dest_size) {
4001b160:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int     eno           = 0;                                          
  /*                                                                  
    * The filenames "." and ".." are handled specially, since they    
    * don't follow dos filename rules.                                
    */                                                                
   if (    src_name[0] == UTF8_FULL_STOP                              
4001b164:	c4 0e 00 00 	ldub  [ %i0 ], %g2                             
4001b168:	80 a0 a0 2e 	cmp  %g2, 0x2e                                 
4001b16c:	12 80 00 19 	bne  4001b1d0 <msdos_filename_process_dot_names+0x70>
4001b170:	82 10 20 00 	clr  %g1                                       
        && src_size    == UTF8_FULL_STOP_SIZE) {                      
4001b174:	80 a6 60 01 	cmp  %i1, 1                                    
4001b178:	32 80 00 07 	bne,a   4001b194 <msdos_filename_process_dot_names+0x34>
4001b17c:	c4 0e 20 01 	ldub  [ %i0 + 1 ], %g2                         
     if (dest_size >= UTF8_FULL_STOP_SIZE) {                          
4001b180:	80 a6 e0 00 	cmp  %i3, 0                                    
4001b184:	02 80 00 0e 	be  4001b1bc <msdos_filename_process_dot_names+0x5c><== NEVER TAKEN
4001b188:	82 10 20 01 	mov  1, %g1                                    
4001b18c:	10 80 00 11 	b  4001b1d0 <msdos_filename_process_dot_names+0x70>
4001b190:	c4 2e 80 00 	stb  %g2, [ %i2 ]                              
     else                                                             
       eno = ENAMETOOLONG;                                            
   }                                                                  
   else if (    eno           == 0                                    
             && src_name[0]   == UTF8_FULL_STOP                       
             && src_name[1]   == UTF8_FULL_STOP                       
4001b194:	80 a0 a0 2e 	cmp  %g2, 0x2e                                 
4001b198:	12 80 00 0e 	bne  4001b1d0 <msdos_filename_process_dot_names+0x70><== NEVER TAKEN
4001b19c:	80 a6 60 02 	cmp  %i1, 2                                    
             && src_size      == ( 2 * UTF8_FULL_STOP_SIZE ) ) {      
4001b1a0:	12 80 00 0c 	bne  4001b1d0 <msdos_filename_process_dot_names+0x70><== NEVER TAKEN
4001b1a4:	80 a6 e0 01 	cmp  %i3, 1                                    
     if (dest_size >= 2 * UTF8_FULL_STOP_SIZE) {                      
4001b1a8:	08 80 00 05 	bleu  4001b1bc <msdos_filename_process_dot_names+0x5c><== NEVER TAKEN
4001b1ac:	82 10 20 02 	mov  2, %g1                                    
       dest_name[0]  = UTF8_FULL_STOP;                                
4001b1b0:	c4 2e 80 00 	stb  %g2, [ %i2 ]                              
4001b1b4:	10 80 00 07 	b  4001b1d0 <msdos_filename_process_dot_names+0x70>
4001b1b8:	c4 2e a0 01 	stb  %g2, [ %i2 + 1 ]                          
     else                                                             
       eno = ENAMETOOLONG;                                            
   }                                                                  
                                                                      
   if (eno != 0) {                                                    
     errno         = eno;                                             
4001b1bc:	40 00 04 b4 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001b1c0:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001b1c4:	82 10 20 5b 	mov  0x5b, %g1	! 5b <_TLS_Alignment+0x5a>      <== NOT EXECUTED
4001b1c8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
     returned_size = -1;                                              
4001b1cc:	82 10 3f ff 	mov  -1, %g1                                   <== NOT EXECUTED
   }                                                                  
                                                                      
   return returned_size;                                              
}                                                                     
4001b1d0:	81 c7 e0 08 	ret                                            
4001b1d4:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4001b440 <msdos_filename_utf8_to_long_name_for_compare>: rtems_dosfs_convert_control *converter, const uint8_t *utf8_name, const size_t utf8_name_size, uint8_t *long_name, const size_t long_name_size) {
4001b440:	9d e3 bf 98 	save  %sp, -104, %sp                           
    ssize_t        returned_size = 0;                                 
    int            eno           = 0;                                 
    size_t         name_size;                                         
    size_t         dest_size     = long_name_size;                    
                                                                      
    returned_size = msdos_filename_process_dot_names (                
4001b444:	94 10 00 1b 	mov  %i3, %o2                                  
    const size_t                     long_name_size)                  
  {                                                                   
    ssize_t        returned_size = 0;                                 
    int            eno           = 0;                                 
    size_t         name_size;                                         
    size_t         dest_size     = long_name_size;                    
4001b448:	f8 27 bf fc 	st  %i4, [ %fp + -4 ]                          
                                                                      
    returned_size = msdos_filename_process_dot_names (                
4001b44c:	90 10 00 19 	mov  %i1, %o0                                  
4001b450:	92 10 00 1a 	mov  %i2, %o1                                  
4001b454:	7f ff ff 43 	call  4001b160 <msdos_filename_process_dot_names>
4001b458:	96 10 00 1c 	mov  %i4, %o3                                  
      utf8_name,                                                      
      utf8_name_size,                                                 
      long_name,                                                      
      long_name_size);                                                
                                                                      
    if (returned_size == 0) {                                         
4001b45c:	80 a2 20 00 	cmp  %o0, 0                                    
4001b460:	12 80 00 1d 	bne  4001b4d4 <msdos_filename_utf8_to_long_name_for_compare+0x94><== NEVER TAKEN
4001b464:	94 10 00 1a 	mov  %i2, %o2                                  
  unsigned int i;                                                     
                                                                      
  /*                                                                  
   * Remove any dots from the end of a file name.                     
   */                                                                 
  for ( i = size_returned - UTF8_FULL_STOP_SIZE;                      
4001b468:	80 a2 a0 00 	cmp  %o2, 0                                    
4001b46c:	14 80 00 07 	bg  4001b488 <msdos_filename_utf8_to_long_name_for_compare+0x48><== ALWAYS TAKEN
4001b470:	82 06 40 0a 	add  %i1, %o2, %g1                             
                                                                      
    if (returned_size == 0) {                                         
      name_size = msdos_filename_delete_trailing_dots (               
        &utf8_name[0],                                                
        utf8_name_size);                                              
      if (name_size > 0) {                                            
4001b474:	80 a2 a0 00 	cmp  %o2, 0                                    <== NOT EXECUTED
4001b478:	02 80 00 13 	be  4001b4c4 <msdos_filename_utf8_to_long_name_for_compare+0x84><== NEVER TAKEN
4001b47c:	ba 10 20 16 	mov  0x16, %i5                                 
        eno = (*converter->handler->utf8_normalize_and_fold) (        
4001b480:	10 80 00 08 	b  4001b4a0 <msdos_filename_utf8_to_long_name_for_compare+0x60>
4001b484:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  /*                                                                  
   * Remove any dots from the end of a file name.                     
   */                                                                 
  for ( i = size_returned - UTF8_FULL_STOP_SIZE;                      
           size_returned >= UTF8_FULL_STOP_SIZE                       
        && filename_utf8[i] == UTF8_FULL_STOP;) {                     
4001b488:	c2 08 7f ff 	ldub  [ %g1 + -1 ], %g1                        
4001b48c:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b490:	12 bf ff fa 	bne  4001b478 <msdos_filename_utf8_to_long_name_for_compare+0x38>
4001b494:	80 a2 a0 00 	cmp  %o2, 0                                    
    size_returned -= UTF8_FULL_STOP_SIZE;                             
4001b498:	10 bf ff f4 	b  4001b468 <msdos_filename_utf8_to_long_name_for_compare+0x28>
4001b49c:	94 02 bf ff 	add  %o2, -1, %o2                              
    if (returned_size == 0) {                                         
      name_size = msdos_filename_delete_trailing_dots (               
        &utf8_name[0],                                                
        utf8_name_size);                                              
      if (name_size > 0) {                                            
        eno = (*converter->handler->utf8_normalize_and_fold) (        
4001b4a0:	90 10 00 18 	mov  %i0, %o0                                  
4001b4a4:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
4001b4a8:	92 10 00 19 	mov  %i1, %o1                                  
4001b4ac:	96 10 00 1b 	mov  %i3, %o3                                  
4001b4b0:	9f c0 40 00 	call  %g1                                      
4001b4b4:	98 07 bf fc 	add  %fp, -4, %o4                              
          converter,                                                  
          utf8_name,                                                  
          name_size,                                                  
          long_name,                                                  
          &dest_size);                                                
        if (eno == 0) {                                               
4001b4b8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001b4bc:	02 80 00 06 	be  4001b4d4 <msdos_filename_utf8_to_long_name_for_compare+0x94><== ALWAYS TAKEN
4001b4c0:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
        eno = EINVAL;                                                 
      }                                                               
    }                                                                 
                                                                      
    if ( eno != 0 ) {                                                 
      errno         = eno;                                            
4001b4c4:	40 00 03 f2 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001b4c8:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001b4cc:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
      returned_size = -1;                                             
4001b4d0:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
    }                                                                 
                                                                      
    return returned_size;                                             
  }                                                                   
4001b4d4:	81 c7 e0 08 	ret                                            
4001b4d8:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001b4dc <msdos_filename_utf8_to_long_name_for_save>: rtems_dosfs_convert_control *converter, const uint8_t *utf8_name, const size_t utf8_name_size, uint16_t *long_name, const size_t long_name_size) {
4001b4dc:	9d e3 bf 98 	save  %sp, -104, %sp                           
    size_t       name_size_tmp = long_name_size / MSDOS_NAME_LFN_BYTES_PER_CHAR;
    int          i;                                                   
    uint16_t     c;                                                   
    unsigned int chars_written;                                       
                                                                      
    name_size_tmp = long_name_size;                                   
4001b4e0:	f8 27 bf fc 	st  %i4, [ %fp + -4 ]                          
  unsigned int i;                                                     
                                                                      
  /*                                                                  
   * Remove any dots from the end of a file name.                     
   */                                                                 
  for ( i = size_returned - UTF8_FULL_STOP_SIZE;                      
4001b4e4:	80 a6 a0 00 	cmp  %i2, 0                                    
4001b4e8:	14 80 00 07 	bg  4001b504 <msdos_filename_utf8_to_long_name_for_save+0x28><== ALWAYS TAKEN
4001b4ec:	82 06 40 1a 	add  %i1, %i2, %g1                             
                                                                      
    name_size_tmp = long_name_size;                                   
    name_size = msdos_filename_delete_trailing_dots (                 
      &utf8_name[0],                                                  
      utf8_name_size);                                                
    if (name_size > 0) {                                              
4001b4f0:	80 a6 a0 00 	cmp  %i2, 0                                    <== NOT EXECUTED
4001b4f4:	02 80 00 69 	be  4001b698 <msdos_filename_utf8_to_long_name_for_save+0x1bc><== NEVER TAKEN
4001b4f8:	ba 10 20 16 	mov  0x16, %i5                                 
      /*                                                              
       * Finally convert from UTF-8 to UTF-16                         
       */                                                             
      eno = (*converter->handler->utf8_to_utf16) (                    
4001b4fc:	10 80 00 08 	b  4001b51c <msdos_filename_utf8_to_long_name_for_save+0x40>
4001b500:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  /*                                                                  
   * Remove any dots from the end of a file name.                     
   */                                                                 
  for ( i = size_returned - UTF8_FULL_STOP_SIZE;                      
           size_returned >= UTF8_FULL_STOP_SIZE                       
        && filename_utf8[i] == UTF8_FULL_STOP;) {                     
4001b504:	c2 08 7f ff 	ldub  [ %g1 + -1 ], %g1                        
4001b508:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b50c:	12 bf ff fa 	bne  4001b4f4 <msdos_filename_utf8_to_long_name_for_save+0x18>
4001b510:	80 a6 a0 00 	cmp  %i2, 0                                    
    size_returned -= UTF8_FULL_STOP_SIZE;                             
4001b514:	10 bf ff f4 	b  4001b4e4 <msdos_filename_utf8_to_long_name_for_save+0x8>
4001b518:	b4 06 bf ff 	add  %i2, -1, %i2                              
      utf8_name_size);                                                
    if (name_size > 0) {                                              
      /*                                                              
       * Finally convert from UTF-8 to UTF-16                         
       */                                                             
      eno = (*converter->handler->utf8_to_utf16) (                    
4001b51c:	90 10 00 18 	mov  %i0, %o0                                  
4001b520:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
4001b524:	92 10 00 19 	mov  %i1, %o1                                  
4001b528:	94 10 00 1a 	mov  %i2, %o2                                  
4001b52c:	96 10 00 1b 	mov  %i3, %o3                                  
4001b530:	9f c0 40 00 	call  %g1                                      
4001b534:	98 07 bf fc 	add  %fp, -4, %o4                              
          converter,                                                  
          utf8_name,                                                  
          name_size,                                                  
          &long_name[0],                                              
          &name_size_tmp);                                            
      if (eno == 0) {                                                 
4001b538:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001b53c:	12 80 00 57 	bne  4001b698 <msdos_filename_utf8_to_long_name_for_save+0x1bc><== NEVER TAKEN
4001b540:	c6 07 bf fc 	ld  [ %fp + -4 ], %g3                          
        if (name_size_tmp <= (MSDOS_NAME_MAX_LNF_LEN * MSDOS_NAME_LFN_BYTES_PER_CHAR))
4001b544:	80 a0 e1 fe 	cmp  %g3, 0x1fe                                
4001b548:	38 80 00 54 	bgu,a   4001b698 <msdos_filename_utf8_to_long_name_for_save+0x1bc>
4001b54c:	ba 10 20 5b 	mov  0x5b, %i5                                 
4001b550:	84 10 20 00 	clr  %g2                                       
4001b554:	b0 10 20 00 	clr  %i0                                       
      case 0x0079: /* 'y' */                                          
      case 0x007a: /* 'z' */                                          
        retval = char_num;                                            
      break;                                                          
      default:                                                        
        retval = codepage_valid_char_map[char_num];                   
4001b558:	1f 10 00 b5 	sethi  %hi(0x4002d400), %o7                    
      if ( eno == 0 )                                                 
      {                                                               
        /*                                                            
         * Validate the characters and assign them to the UTF-16 file name
         */                                                           
        for ( i = 0;                                                  
4001b55c:	88 a0 c0 18 	subcc  %g3, %i0, %g4                           
4001b560:	22 80 00 34 	be,a   4001b630 <msdos_filename_utf8_to_long_name_for_save+0x154>
4001b564:	a1 2c 20 10 	sll  %l0, 0x10, %l0                            
                 name_size                                            
              && (c = msdos_get_valid_utf16_filename_character ( long_name[i]) );
4001b568:	c2 16 c0 18 	lduh  [ %i3 + %i0 ], %g1                       
                                                                      
static uint16_t                                                       
msdos_get_valid_utf16_filename_character (const uint16_t utf16_character)
{                                                                     
  uint16_t retval    = 0x0000;                                        
  uint16_t char_num  = CF_LE_W( utf16_character );                    
4001b56c:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001b570:	b3 30 60 08 	srl  %g1, 8, %i1                               
4001b574:	83 30 60 18 	srl  %g1, 0x18, %g1                            
4001b578:	b2 16 40 01 	or  %i1, %g1, %i1                              
4001b57c:	b4 10 00 19 	mov  %i1, %i2                                  
                                                                      
  if ( char_num <= 0x00ff ) {                                         
4001b580:	b3 2e 60 10 	sll  %i1, 0x10, %i1                            
4001b584:	83 36 60 10 	srl  %i1, 0x10, %g1                            
4001b588:	80 a0 60 ff 	cmp  %g1, 0xff                                 
4001b58c:	18 80 00 1c 	bgu  4001b5fc <msdos_filename_utf8_to_long_name_for_save+0x120>
4001b590:	80 a0 60 3d 	cmp  %g1, 0x3d                                 
    switch ( char_num )                                               
4001b594:	22 80 00 1b 	be,a   4001b600 <msdos_filename_utf8_to_long_name_for_save+0x124>
4001b598:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            
4001b59c:	18 80 00 0a 	bgu  4001b5c4 <msdos_filename_utf8_to_long_name_for_save+0xe8>
4001b5a0:	80 a0 60 5d 	cmp  %g1, 0x5d                                 
4001b5a4:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b5a8:	22 80 00 16 	be,a   4001b600 <msdos_filename_utf8_to_long_name_for_save+0x124>
4001b5ac:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            
4001b5b0:	38 80 00 0a 	bgu,a   4001b5d8 <msdos_filename_utf8_to_long_name_for_save+0xfc>
4001b5b4:	80 a0 60 3b 	cmp  %g1, 0x3b                                 
4001b5b8:	82 00 7f d5 	add  %g1, -43, %g1                             
4001b5bc:	10 80 00 0c 	b  4001b5ec <msdos_filename_utf8_to_long_name_for_save+0x110>
4001b5c0:	80 a0 60 01 	cmp  %g1, 1                                    
4001b5c4:	02 80 00 0e 	be  4001b5fc <msdos_filename_utf8_to_long_name_for_save+0x120>
4001b5c8:	80 a0 60 5d 	cmp  %g1, 0x5d                                 
4001b5cc:	38 80 00 07 	bgu,a   4001b5e8 <msdos_filename_utf8_to_long_name_for_save+0x10c>
4001b5d0:	82 00 7f 9f 	add  %g1, -97, %g1                             
4001b5d4:	80 a0 60 5b 	cmp  %g1, 0x5b                                 
4001b5d8:	32 80 00 07 	bne,a   4001b5f4 <msdos_filename_utf8_to_long_name_for_save+0x118>
4001b5dc:	b3 36 60 10 	srl  %i1, 0x10, %i1                            
    }                                                                 
  }                                                                   
  else                                                                
    retval = char_num;                                                
                                                                      
  return CT_LE_W( retval );                                           
4001b5e0:	10 80 00 08 	b  4001b600 <msdos_filename_utf8_to_long_name_for_save+0x124>
4001b5e4:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            
{                                                                     
  uint16_t retval    = 0x0000;                                        
  uint16_t char_num  = CF_LE_W( utf16_character );                    
                                                                      
  if ( char_num <= 0x00ff ) {                                         
    switch ( char_num )                                               
4001b5e8:	80 a0 60 19 	cmp  %g1, 0x19                                 
4001b5ec:	08 80 00 04 	bleu  4001b5fc <msdos_filename_utf8_to_long_name_for_save+0x120>
4001b5f0:	b3 36 60 10 	srl  %i1, 0x10, %i1                            
      case 0x0079: /* 'y' */                                          
      case 0x007a: /* 'z' */                                          
        retval = char_num;                                            
      break;                                                          
      default:                                                        
        retval = codepage_valid_char_map[char_num];                   
4001b5f4:	82 13 e1 00 	or  %o7, 0x100, %g1                            
4001b5f8:	f4 08 40 19 	ldub  [ %g1 + %i1 ], %i2                       
    }                                                                 
  }                                                                   
  else                                                                
    retval = char_num;                                                
                                                                      
  return CT_LE_W( retval );                                           
4001b5fc:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            
4001b600:	83 36 a0 08 	srl  %i2, 8, %g1                               
4001b604:	b5 36 a0 18 	srl  %i2, 0x18, %i2                            
4001b608:	82 10 40 1a 	or  %g1, %i2, %g1                              
        /*                                                            
         * Validate the characters and assign them to the UTF-16 file name
         */                                                           
        for ( i = 0;                                                  
                 name_size                                            
              && (c = msdos_get_valid_utf16_filename_character ( long_name[i]) );
4001b60c:	b5 28 60 10 	sll  %g1, 0x10, %i2                            
4001b610:	80 a6 a0 00 	cmp  %i2, 0                                    
4001b614:	02 80 00 06 	be  4001b62c <msdos_filename_utf8_to_long_name_for_save+0x150>
4001b618:	a0 10 00 01 	mov  %g1, %l0                                  
              ++i ) {                                                 
          long_name[i]   = c;                                         
4001b61c:	c2 36 c0 18 	sth  %g1, [ %i3 + %i0 ]                        
         * Validate the characters and assign them to the UTF-16 file name
         */                                                           
        for ( i = 0;                                                  
                 name_size                                            
              && (c = msdos_get_valid_utf16_filename_character ( long_name[i]) );
              ++i ) {                                                 
4001b620:	84 00 a0 01 	inc  %g2                                       
          long_name[i]   = c;                                         
          returned_size += MSDOS_NAME_LFN_BYTES_PER_CHAR;             
4001b624:	10 bf ff ce 	b  4001b55c <msdos_filename_utf8_to_long_name_for_save+0x80>
4001b628:	b0 06 20 02 	add  %i0, 2, %i0                               
          name_size     -= MSDOS_NAME_LFN_BYTES_PER_CHAR;             
        }                                                             
        if ( name_size == UTF16_NULL_SIZE && c == UTF16_NULL ) {      
4001b62c:	a1 2c 20 10 	sll  %l0, 0x10, %l0                            
4001b630:	80 a4 20 00 	cmp  %l0, 0                                    
4001b634:	12 80 00 09 	bne  4001b658 <msdos_filename_utf8_to_long_name_for_save+0x17c>
4001b638:	80 a1 20 00 	cmp  %g4, 0                                    
4001b63c:	80 a1 20 02 	cmp  %g4, 2                                    
4001b640:	12 80 00 06 	bne  4001b658 <msdos_filename_utf8_to_long_name_for_save+0x17c><== ALWAYS TAKEN
4001b644:	80 a1 20 00 	cmp  %g4, 0                                    
          long_name[i]   = c;                                         
4001b648:	85 28 a0 01 	sll  %g2, 1, %g2                               <== NOT EXECUTED
          returned_size += MSDOS_NAME_LFN_BYTES_PER_CHAR;             
4001b64c:	b0 06 20 02 	add  %i0, 2, %i0                               <== NOT EXECUTED
4001b650:	10 80 00 04 	b  4001b660 <msdos_filename_utf8_to_long_name_for_save+0x184><== NOT EXECUTED
4001b654:	c0 36 c0 02 	clrh  [ %i3 + %g2 ]                            <== NOT EXECUTED
          name_size     -= MSDOS_NAME_LFN_BYTES_PER_CHAR;             
        }                                                             
        else if ( name_size != 0 )                                    
4001b658:	32 80 00 02 	bne,a   4001b660 <msdos_filename_utf8_to_long_name_for_save+0x184>
4001b65c:	ba 10 20 16 	mov  0x16, %i5                                 
          eno = EINVAL;                                               
        chars_written = returned_size / MSDOS_NAME_LFN_BYTES_PER_CHAR;
        if (   long_name [chars_written - 1] != UTF16_NULL            
4001b660:	82 0e 3f fe 	and  %i0, -2, %g1                              
4001b664:	82 00 7f fe 	add  %g1, -2, %g1                              
4001b668:	c4 16 c0 01 	lduh  [ %i3 + %g1 ], %g2                       
4001b66c:	80 a0 a0 00 	cmp  %g2, 0                                    
4001b670:	02 80 00 08 	be  4001b690 <msdos_filename_utf8_to_long_name_for_save+0x1b4><== NEVER TAKEN
4001b674:	80 a7 60 00 	cmp  %i5, 0                                    
            && (returned_size + UTF16_NULL_SIZE ) <= long_name_size ) {
4001b678:	84 06 20 02 	add  %i0, 2, %g2                               
4001b67c:	80 a0 80 1c 	cmp  %g2, %i4                                  
4001b680:	18 80 00 04 	bgu  4001b690 <msdos_filename_utf8_to_long_name_for_save+0x1b4><== NEVER TAKEN
4001b684:	80 a7 60 00 	cmp  %i5, 0                                    
          long_name[chars_written] = UTF16_NULL;                      
4001b688:	b6 06 c0 01 	add  %i3, %g1, %i3                             
4001b68c:	c0 36 e0 02 	clrh  [ %i3 + 2 ]                              
      }                                                               
    }                                                                 
    else                                                              
      eno = EINVAL;                                                   
                                                                      
    if ( eno != 0 ) {                                                 
4001b690:	02 80 00 07 	be  4001b6ac <msdos_filename_utf8_to_long_name_for_save+0x1d0>
4001b694:	01 00 00 00 	nop                                            
      errno         = eno;                                            
4001b698:	40 00 03 7d 	call  4001c48c <__errno>                       
4001b69c:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   
4001b6a0:	fa 22 00 00 	st  %i5, [ %o0 ]                               
4001b6a4:	81 c7 e0 08 	ret                                            
4001b6a8:	81 e8 00 00 	restore                                        
      returned_size = -1;                                             
    }                                                                 
                                                                      
    return returned_size;                                             
  }                                                                   
4001b6ac:	81 c7 e0 08 	ret                                            
4001b6b0:	81 e8 00 00 	restore                                        
                                                                      

4001b6b4 <msdos_filename_utf8_to_short_name_for_compare>: rtems_dosfs_convert_control *converter, const uint8_t *utf8_name, const size_t utf8_name_size, void *short_name, const size_t short_name_size) {
4001b6b4:	9d e3 bf 68 	save  %sp, -152, %sp                           
  int            eno                     = 0;                         
  const uint8_t *name_ptr                = utf8_name;                 
  char          *dest_ptr                = (char*)short_name;         
  size_t         name_size               = utf8_name_size;            
  uint8_t        name_normalized_buf[(MSDOS_SHORT_NAME_LEN +1) * MSDOS_NAME_MAX_UTF8_BYTES_PER_CHAR];
  size_t         name_size_tmp           = sizeof(name_normalized_buf);
4001b6b8:	82 10 20 30 	mov  0x30, %g1                                 
                                                                      
  returned_size = msdos_filename_process_dot_names (                  
4001b6bc:	94 10 00 1b 	mov  %i3, %o2                                  
  int            eno                     = 0;                         
  const uint8_t *name_ptr                = utf8_name;                 
  char          *dest_ptr                = (char*)short_name;         
  size_t         name_size               = utf8_name_size;            
  uint8_t        name_normalized_buf[(MSDOS_SHORT_NAME_LEN +1) * MSDOS_NAME_MAX_UTF8_BYTES_PER_CHAR];
  size_t         name_size_tmp           = sizeof(name_normalized_buf);
4001b6c0:	c2 27 bf cc 	st  %g1, [ %fp + -52 ]                         
                                                                      
  returned_size = msdos_filename_process_dot_names (                  
4001b6c4:	90 10 00 19 	mov  %i1, %o0                                  
4001b6c8:	92 10 00 1a 	mov  %i2, %o1                                  
4001b6cc:	7f ff fe a5 	call  4001b160 <msdos_filename_process_dot_names>
4001b6d0:	96 10 00 1c 	mov  %i4, %o3                                  
    rtems_dosfs_convert_control     *converter,                       
    const uint8_t                   *utf8_name,                       
    const size_t                     utf8_name_size,                  
    void                            *short_name,                      
    const size_t                     short_name_size)                 
{                                                                     
4001b6d4:	ba 10 00 18 	mov  %i0, %i5                                  
    utf8_name,                                                        
    utf8_name_size,                                                   
    short_name,                                                       
    short_name_size);                                                 
                                                                      
  if (returned_size == 0) {                                           
4001b6d8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001b6dc:	12 80 00 0f 	bne  4001b718 <msdos_filename_utf8_to_short_name_for_compare+0x64>
4001b6e0:	94 10 00 1a 	mov  %i2, %o2                                  
 * Remove any dots from the start of a file name.                     
 */                                                                   
static void msdos_filename_remove_prepended_dots (const uint8_t **name_utf8,
                                                  size_t         *name_size)
{                                                                     
  while (    *name_size >= UTF8_FULL_STOP_SIZE                        
4001b6e4:	80 a2 a0 00 	cmp  %o2, 0                                    
4001b6e8:	22 80 00 09 	be,a   4001b70c <msdos_filename_utf8_to_short_name_for_compare+0x58><== NEVER TAKEN
4001b6ec:	ba 10 20 16 	mov  0x16, %i5                                 <== NOT EXECUTED
         && **name_utf8 == UTF8_FULL_STOP) {                          
4001b6f0:	c2 0e 40 00 	ldub  [ %i1 ], %g1                             
4001b6f4:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b6f8:	32 80 00 0a 	bne,a   4001b720 <msdos_filename_utf8_to_short_name_for_compare+0x6c><== ALWAYS TAKEN
4001b6fc:	c2 07 40 00 	ld  [ %i5 ], %g1                               
4001b700:	b2 06 60 01 	inc  %i1                                       <== NOT EXECUTED
    *name_utf8  += UTF8_FULL_STOP_SIZE;                               
    *name_size  -= UTF8_FULL_STOP_SIZE;                               
4001b704:	10 bf ff f8 	b  4001b6e4 <msdos_filename_utf8_to_short_name_for_compare+0x30><== NOT EXECUTED
4001b708:	94 02 bf ff 	add  %o2, -1, %o2                              <== NOT EXECUTED
    } else                                                            
      eno = EINVAL;                                                   
  }                                                                   
                                                                      
  if ( eno != 0 ) {                                                   
    errno         = eno;                                              
4001b70c:	40 00 03 60 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001b710:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001b714:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
4001b718:	81 c7 e0 08 	ret                                            
4001b71c:	81 e8 00 00 	restore                                        
                                          &name_size);                
    if (name_size > 0) {                                              
      /*                                                              
       * Normalize the name and convert to lower case                 
       */                                                             
      eno = (*converter->handler->utf8_normalize_and_fold) (          
4001b720:	90 10 00 1d 	mov  %i5, %o0                                  
4001b724:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
4001b728:	92 10 00 19 	mov  %i1, %o1                                  
4001b72c:	96 07 bf d0 	add  %fp, -48, %o3                             
4001b730:	9f c0 40 00 	call  %g1                                      
4001b734:	98 07 bf cc 	add  %fp, -52, %o4                             
        name_ptr,                                                     
        name_size,                                                    
        &name_normalized_buf[0],                                      
        &name_size_tmp);                                              
      name_ptr  = &name_normalized_buf[0];                            
      name_size = name_size_tmp;                                      
4001b738:	f0 07 bf cc 	ld  [ %fp + -52 ], %i0                         
      if ( eno == ENOMEM ) {                                          
4001b73c:	80 a2 20 0c 	cmp  %o0, 0xc                                  
4001b740:	02 80 00 05 	be  4001b754 <msdos_filename_utf8_to_short_name_for_compare+0xa0><== NEVER TAKEN
4001b744:	ba 10 00 08 	mov  %o0, %i5                                  
        eno = 0;                                                      
      }                                                               
      if ( eno == 0 ) {                                               
4001b748:	80 a7 60 00 	cmp  %i5, 0                                    
4001b74c:	12 bf ff f0 	bne  4001b70c <msdos_filename_utf8_to_short_name_for_compare+0x58><== NEVER TAKEN
4001b750:	01 00 00 00 	nop                                            
        memcpy (&dest_ptr[0], &name_ptr[0], name_size);               
4001b754:	90 10 00 1b 	mov  %i3, %o0                                  
4001b758:	92 07 bf d0 	add  %fp, -48, %o1                             
4001b75c:	40 00 05 a1 	call  4001cde0 <memcpy>                        
4001b760:	94 10 00 18 	mov  %i0, %o2                                  
4001b764:	81 c7 e0 08 	ret                                            
4001b768:	81 e8 00 00 	restore                                        
                                                                      

4001b76c <msdos_filename_utf8_to_short_name_for_save>: rtems_dosfs_convert_control *converter, const uint8_t *utf8_name, const size_t utf8_name_size, void *short_name, const size_t short_name_size) {
4001b76c:	9d e3 bf 88 	save  %sp, -120, %sp                           
  unsigned int   i;                                                   
  char           c;                                                   
  size_t         name_size_tmp;                                       
  char           name_to_format_buf[MSDOS_SHORT_NAME_LEN +1];         
                                                                      
  returned_size = msdos_filename_process_dot_names (                  
4001b770:	94 10 00 1b 	mov  %i3, %o2                                  
4001b774:	90 10 00 19 	mov  %i1, %o0                                  
4001b778:	92 10 00 1a 	mov  %i2, %o1                                  
4001b77c:	7f ff fe 79 	call  4001b160 <msdos_filename_process_dot_names>
4001b780:	96 10 00 1c 	mov  %i4, %o3                                  
    utf8_name,                                                        
    utf8_name_size,                                                   
    short_name,                                                       
    short_name_size);                                                 
                                                                      
  if (returned_size == 0) {                                           
4001b784:	a0 92 20 00 	orcc  %o0, 0, %l0                              
4001b788:	12 80 00 1a 	bne  4001b7f0 <msdos_filename_utf8_to_short_name_for_save+0x84><== NEVER TAKEN
4001b78c:	94 10 00 1a 	mov  %i2, %o2                                  
 * Remove any dots from the start of a file name.                     
 */                                                                   
static void msdos_filename_remove_prepended_dots (const uint8_t **name_utf8,
                                                  size_t         *name_size)
{                                                                     
  while (    *name_size >= UTF8_FULL_STOP_SIZE                        
4001b790:	80 a2 a0 00 	cmp  %o2, 0                                    
4001b794:	02 80 00 7d 	be  4001b988 <msdos_filename_utf8_to_short_name_for_save+0x21c><== NEVER TAKEN
4001b798:	01 00 00 00 	nop                                            
         && **name_utf8 == UTF8_FULL_STOP) {                          
4001b79c:	c2 0e 40 00 	ldub  [ %i1 ], %g1                             
4001b7a0:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b7a4:	12 80 00 15 	bne  4001b7f8 <msdos_filename_utf8_to_short_name_for_save+0x8c><== ALWAYS TAKEN
4001b7a8:	82 10 20 0c 	mov  0xc, %g1                                  
4001b7ac:	b2 06 60 01 	inc  %i1                                       <== NOT EXECUTED
    *name_utf8  += UTF8_FULL_STOP_SIZE;                               
    *name_size  -= UTF8_FULL_STOP_SIZE;                               
4001b7b0:	10 bf ff f8 	b  4001b790 <msdos_filename_utf8_to_short_name_for_save+0x24><== NOT EXECUTED
4001b7b4:	94 02 bf ff 	add  %o2, -1, %o2                              <== NOT EXECUTED
        eno = 0;                                                      
      }                                                               
      name_ptr  = (const uint8_t *)(&name_to_format_buf[0]);          
      name_size = name_size_tmp;                                      
      for (i = 0; i < name_size; ++i)                                 
        name_to_format_buf[i] = toupper ( (unsigned char)(name_to_format_buf[i]) );
4001b7b8:	b4 00 c0 02 	add  %g3, %g2, %i2                             
4001b7bc:	f4 0e a0 01 	ldub  [ %i2 + 1 ], %i2                         
4001b7c0:	b4 0e a0 03 	and  %i2, 3, %i2                               
4001b7c4:	80 a6 a0 02 	cmp  %i2, 2                                    
4001b7c8:	22 80 00 02 	be,a   4001b7d0 <msdos_filename_utf8_to_short_name_for_save+0x64>
4001b7cc:	84 00 bf e0 	add  %g2, -32, %g2                             
4001b7d0:	c4 2f 40 01 	stb  %g2, [ %i5 + %g1 ]                        
         */                                                           
        eno = 0;                                                      
      }                                                               
      name_ptr  = (const uint8_t *)(&name_to_format_buf[0]);          
      name_size = name_size_tmp;                                      
      for (i = 0; i < name_size; ++i)                                 
4001b7d4:	82 00 60 01 	inc  %g1                                       
4001b7d8:	80 a0 40 04 	cmp  %g1, %g4                                  
4001b7dc:	32 bf ff f7 	bne,a   4001b7b8 <msdos_filename_utf8_to_short_name_for_save+0x4c>
4001b7e0:	c4 0f 40 01 	ldub  [ %i5 + %g1 ], %g2                       
        name_to_format_buf[i] = toupper ( (unsigned char)(name_to_format_buf[i]) );
      /*                                                              
       * Validate the characters and assign them to the codepage file name
       */                                                             
      if ( name_size > 0 ) {                                          
4001b7e4:	80 a1 20 00 	cmp  %g4, 0                                    
4001b7e8:	12 80 00 12 	bne  4001b830 <msdos_filename_utf8_to_short_name_for_save+0xc4><== ALWAYS TAKEN
4001b7ec:	c2 0f bf f0 	ldub  [ %fp + -16 ], %g1                       
      eno = EINVAL;                                                   
  }                                                                   
                                                                      
  if ( eno != 0 ) {                                                   
    errno = eno;                                                      
    return -1;                                                        
4001b7f0:	81 c7 e0 08 	ret                                            
4001b7f4:	91 e8 00 10 	restore  %g0, %l0, %o0                         
                                                                      
    if (name_size > 0) {                                              
      /*                                                              
       * Finally convert from UTF-8 to codepage                       
       */                                                             
      name_size_tmp = sizeof ( name_to_format_buf );                  
4001b7f8:	c2 27 bf ec 	st  %g1, [ %fp + -20 ]                         
      eno = (*converter->handler->utf8_to_codepage) (                 
4001b7fc:	c2 06 00 00 	ld  [ %i0 ], %g1                               
4001b800:	ba 07 bf f0 	add  %fp, -16, %i5                             
4001b804:	c2 00 40 00 	ld  [ %g1 ], %g1                               
4001b808:	90 10 00 18 	mov  %i0, %o0                                  
4001b80c:	92 10 00 19 	mov  %i1, %o1                                  
4001b810:	96 10 00 1d 	mov  %i5, %o3                                  
4001b814:	9f c0 40 00 	call  %g1                                      
4001b818:	98 07 bf ec 	add  %fp, -20, %o4                             
        eno = 0;                                                      
      }                                                               
      name_ptr  = (const uint8_t *)(&name_to_format_buf[0]);          
      name_size = name_size_tmp;                                      
      for (i = 0; i < name_size; ++i)                                 
        name_to_format_buf[i] = toupper ( (unsigned char)(name_to_format_buf[i]) );
4001b81c:	03 10 00 b7 	sethi  %hi(0x4002dc00), %g1                    
         * characters. Later in this method they will get replaced by underline characters.
         */                                                           
        eno = 0;                                                      
      }                                                               
      name_ptr  = (const uint8_t *)(&name_to_format_buf[0]);          
      name_size = name_size_tmp;                                      
4001b820:	c8 07 bf ec 	ld  [ %fp + -20 ], %g4                         
      for (i = 0; i < name_size; ++i)                                 
        name_to_format_buf[i] = toupper ( (unsigned char)(name_to_format_buf[i]) );
4001b824:	c6 00 62 0c 	ld  [ %g1 + 0x20c ], %g3                       
         */                                                           
        eno = 0;                                                      
      }                                                               
      name_ptr  = (const uint8_t *)(&name_to_format_buf[0]);          
      name_size = name_size_tmp;                                      
      for (i = 0; i < name_size; ++i)                                 
4001b828:	10 bf ff ec 	b  4001b7d8 <msdos_filename_utf8_to_short_name_for_save+0x6c>
4001b82c:	82 10 20 00 	clr  %g1                                       
       */                                                             
      if ( name_size > 0 ) {                                          
        /*                                                            
         * The first character needs some special treatment           
         */                                                           
        if ( 0x20 == *name_ptr )                                      
4001b830:	80 a0 60 20 	cmp  %g1, 0x20                                 
4001b834:	12 80 00 04 	bne  4001b844 <msdos_filename_utf8_to_short_name_for_save+0xd8>
4001b838:	80 a0 60 e5 	cmp  %g1, 0xe5                                 
          dest_ptr[0] = '_';                                          
4001b83c:	10 80 00 05 	b  4001b850 <msdos_filename_utf8_to_short_name_for_save+0xe4>
4001b840:	82 10 20 5f 	mov  0x5f, %g1                                 
        else if ( 0xE5 == *name_ptr )                                 
4001b844:	12 80 00 05 	bne  4001b858 <msdos_filename_utf8_to_short_name_for_save+0xec><== ALWAYS TAKEN
4001b848:	05 10 00 b5 	sethi  %hi(0x4002d400), %g2                    
          dest_ptr[0] = 0x05;                                         
4001b84c:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4001b850:	10 80 00 09 	b  4001b874 <msdos_filename_utf8_to_short_name_for_save+0x108>
4001b854:	c2 2e c0 00 	stb  %g1, [ %i3 ]                              
}                                                                     
                                                                      
static char                                                           
msdos_get_valid_codepage_filename_character (const uint8_t character) 
{                                                                     
  return codepage_valid_char_map[(unsigned int)character];            
4001b858:	84 10 a1 00 	or  %g2, 0x100, %g2                            
         */                                                           
        if ( 0x20 == *name_ptr )                                      
          dest_ptr[0] = '_';                                          
        else if ( 0xE5 == *name_ptr )                                 
          dest_ptr[0] = 0x05;                                         
        else if (0 != (c = msdos_get_valid_codepage_filename_character( *name_ptr ) ) )
4001b85c:	c6 08 80 01 	ldub  [ %g2 + %g1 ], %g3                       
4001b860:	c2 48 80 01 	ldsb  [ %g2 + %g1 ], %g1                       
4001b864:	80 a0 60 00 	cmp  %g1, 0                                    
4001b868:	02 bf ff fa 	be  4001b850 <msdos_filename_utf8_to_short_name_for_save+0xe4>
4001b86c:	82 10 20 5f 	mov  0x5f, %g1                                 
          dest_ptr[0] = c;                                            
4001b870:	c6 2e c0 00 	stb  %g3, [ %i3 ]                              
        else                                                          
          dest_ptr[0] = '_';                                          
        ++name_ptr;                                                   
        ++returned_size;                                              
        --name_size;                                                  
4001b874:	88 01 3f ff 	add  %g4, -1, %g4                              
          dest_ptr[0] = 0x05;                                         
        else if (0 != (c = msdos_get_valid_codepage_filename_character( *name_ptr ) ) )
          dest_ptr[0] = c;                                            
        else                                                          
          dest_ptr[0] = '_';                                          
        ++name_ptr;                                                   
4001b878:	86 07 bf f1 	add  %fp, -15, %g3                             
        ++returned_size;                                              
4001b87c:	84 10 20 01 	mov  1, %g2                                    
}                                                                     
                                                                      
static char                                                           
msdos_get_valid_codepage_filename_character (const uint8_t character) 
{                                                                     
  return codepage_valid_char_map[(unsigned int)character];            
4001b880:	35 10 00 b5 	sethi  %hi(0x4002d400), %i2                    
        for (i = 1; i <= 7 && name_size && *name_ptr != '.'; ++i) {   
          c = msdos_get_valid_codepage_filename_character ( *name_ptr );
          if (c != 0)                                                 
            dest_ptr[i] = c;                                          
          else                                                        
            dest_ptr[i] = '_';                                        
4001b884:	b2 10 20 5f 	mov  0x5f, %i1                                 
        ++returned_size;                                              
        --name_size;                                                  
        /*                                                            
         * Validate and assign all other characters of the name part  
         */                                                           
        for (i = 1; i <= 7 && name_size && *name_ptr != '.'; ++i) {   
4001b888:	80 a1 20 00 	cmp  %g4, 0                                    
4001b88c:	02 80 00 1c 	be  4001b8fc <msdos_filename_utf8_to_short_name_for_save+0x190>
4001b890:	ba 10 00 02 	mov  %g2, %i5                                  
4001b894:	c2 08 c0 00 	ldub  [ %g3 ], %g1                             
4001b898:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b89c:	02 80 00 14 	be  4001b8ec <msdos_filename_utf8_to_short_name_for_save+0x180>
4001b8a0:	01 00 00 00 	nop                                            
}                                                                     
                                                                      
static char                                                           
msdos_get_valid_codepage_filename_character (const uint8_t character) 
{                                                                     
  return codepage_valid_char_map[(unsigned int)character];            
4001b8a4:	ba 16 a1 00 	or  %i2, 0x100, %i5                            
        /*                                                            
         * Validate and assign all other characters of the name part  
         */                                                           
        for (i = 1; i <= 7 && name_size && *name_ptr != '.'; ++i) {   
          c = msdos_get_valid_codepage_filename_character ( *name_ptr );
          if (c != 0)                                                 
4001b8a8:	f0 0f 40 01 	ldub  [ %i5 + %g1 ], %i0                       
4001b8ac:	c2 4f 40 01 	ldsb  [ %i5 + %g1 ], %g1                       
4001b8b0:	80 a0 60 00 	cmp  %g1, 0                                    
4001b8b4:	22 80 00 03 	be,a   4001b8c0 <msdos_filename_utf8_to_short_name_for_save+0x154>
4001b8b8:	f2 2e c0 02 	stb  %i1, [ %i3 + %g2 ]                        
4001b8bc:	f0 2e c0 02 	stb  %i0, [ %i3 + %g2 ]                        
            dest_ptr[i] = c;                                          
          else                                                        
            dest_ptr[i] = '_';                                        
          ++name_ptr;                                                 
          ++returned_size;                                            
4001b8c0:	84 00 a0 01 	inc  %g2                                       
4001b8c4:	86 00 e0 01 	inc  %g3                                       
        ++returned_size;                                              
        --name_size;                                                  
        /*                                                            
         * Validate and assign all other characters of the name part  
         */                                                           
        for (i = 1; i <= 7 && name_size && *name_ptr != '.'; ++i) {   
4001b8c8:	80 a0 a0 08 	cmp  %g2, 8                                    
4001b8cc:	12 bf ff ef 	bne  4001b888 <msdos_filename_utf8_to_short_name_for_save+0x11c>
4001b8d0:	88 01 3f ff 	add  %g4, -1, %g4                              
        }                                                             
        /*                                                            
         * Strip any further characters up to a '.' or the end of the 
         * string.                                                    
         */                                                           
        if ( name_size > 0 && *name_ptr == '.' ) {                    
4001b8d4:	80 a1 20 00 	cmp  %g4, 0                                    
4001b8d8:	02 80 00 09 	be  4001b8fc <msdos_filename_utf8_to_short_name_for_save+0x190>
4001b8dc:	ba 10 20 08 	mov  8, %i5                                    
4001b8e0:	ba 10 00 02 	mov  %g2, %i5                                  
4001b8e4:	c2 08 c0 00 	ldub  [ %g3 ], %g1                             
4001b8e8:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
4001b8ec:	12 80 00 05 	bne  4001b900 <msdos_filename_utf8_to_short_name_for_save+0x194>
4001b8f0:	82 10 00 1d 	mov  %i5, %g1                                  
          ++name_ptr;                                                 
4001b8f4:	86 00 e0 01 	inc  %g3                                       
          --name_size;                                                
4001b8f8:	88 01 3f ff 	add  %g4, -1, %g4                              
4001b8fc:	82 10 00 1d 	mov  %i5, %g1                                  
        }                                                             
                                                                      
        for (; i < 8; ++i) {                                          
          dest_ptr[i] = ' ';                                          
4001b900:	b4 10 20 20 	mov  0x20, %i2                                 
        if ( name_size > 0 && *name_ptr == '.' ) {                    
          ++name_ptr;                                                 
          --name_size;                                                
        }                                                             
                                                                      
        for (; i < 8; ++i) {                                          
4001b904:	80 a0 60 08 	cmp  %g1, 8                                    
4001b908:	22 80 00 05 	be,a   4001b91c <msdos_filename_utf8_to_short_name_for_save+0x1b0>
4001b90c:	84 20 80 1d 	sub  %g2, %i5, %g2                             
          dest_ptr[i] = ' ';                                          
4001b910:	f4 2e c0 01 	stb  %i2, [ %i3 + %g1 ]                        
        if ( name_size > 0 && *name_ptr == '.' ) {                    
          ++name_ptr;                                                 
          --name_size;                                                
        }                                                             
                                                                      
        for (; i < 8; ++i) {                                          
4001b914:	10 bf ff fc 	b  4001b904 <msdos_filename_utf8_to_short_name_for_save+0x198>
4001b918:	82 00 60 01 	inc  %g1                                       
4001b91c:	88 01 20 08 	add  %g4, 8, %g4                               
4001b920:	84 00 a0 08 	add  %g2, 8, %g2                               
}                                                                     
                                                                      
static char                                                           
msdos_get_valid_codepage_filename_character (const uint8_t character) 
{                                                                     
  return codepage_valid_char_map[(unsigned int)character];            
4001b924:	33 10 00 b5 	sethi  %hi(0x4002d400), %i1                    
        for (; i <= 10 && name_size ; i++) {                          
          c = msdos_get_valid_codepage_filename_character ( *name_ptr);
          if (c != 0)                                                 
            dest_ptr[i] = c;                                          
          else                                                        
            dest_ptr[i] = '_';                                        
4001b928:	b0 10 20 5f 	mov  0x5f, %i0                                 
        }                                                             
                                                                      
        /*                                                            
         * Copy in the extension part of the name, if any.            
         */                                                           
        for (; i <= 10 && name_size ; i++) {                          
4001b92c:	80 a0 40 04 	cmp  %g1, %g4                                  
4001b930:	02 80 00 0e 	be  4001b968 <msdos_filename_utf8_to_short_name_for_save+0x1fc>
4001b934:	ba 00 c0 01 	add  %g3, %g1, %i5                             
}                                                                     
                                                                      
static char                                                           
msdos_get_valid_codepage_filename_character (const uint8_t character) 
{                                                                     
  return codepage_valid_char_map[(unsigned int)character];            
4001b938:	fa 0f 7f f8 	ldub  [ %i5 + -8 ], %i5                        
4001b93c:	b4 16 61 00 	or  %i1, 0x100, %i2                            
        /*                                                            
         * Copy in the extension part of the name, if any.            
         */                                                           
        for (; i <= 10 && name_size ; i++) {                          
          c = msdos_get_valid_codepage_filename_character ( *name_ptr);
          if (c != 0)                                                 
4001b940:	de 0e 80 1d 	ldub  [ %i2 + %i5 ], %o7                       
4001b944:	fa 4e 80 1d 	ldsb  [ %i2 + %i5 ], %i5                       
4001b948:	80 a7 60 00 	cmp  %i5, 0                                    
4001b94c:	22 80 00 03 	be,a   4001b958 <msdos_filename_utf8_to_short_name_for_save+0x1ec>
4001b950:	f0 2e c0 01 	stb  %i0, [ %i3 + %g1 ]                        
4001b954:	de 2e c0 01 	stb  %o7, [ %i3 + %g1 ]                        
        }                                                             
                                                                      
        /*                                                            
         * Copy in the extension part of the name, if any.            
         */                                                           
        for (; i <= 10 && name_size ; i++) {                          
4001b958:	82 00 60 01 	inc  %g1                                       
4001b95c:	80 a0 60 0b 	cmp  %g1, 0xb                                  
4001b960:	12 bf ff f3 	bne  4001b92c <msdos_filename_utf8_to_short_name_for_save+0x1c0>
4001b964:	84 00 a0 01 	inc  %g2                                       
4001b968:	84 20 80 01 	sub  %g2, %g1, %g2                             
        }                                                             
        /*                                                            
         * Fill up with blanks. These are DOS's pad characters.       
         */                                                           
        for ( ; i < short_name_size; ++i ) {                          
          dest_ptr[i] = ' ';                                          
4001b96c:	86 10 20 20 	mov  0x20, %g3                                 
          name_size--;                                                
        }                                                             
        /*                                                            
         * Fill up with blanks. These are DOS's pad characters.       
         */                                                           
        for ( ; i < short_name_size; ++i ) {                          
4001b970:	80 a0 40 1c 	cmp  %g1, %i4                                  
4001b974:	1a bf ff 9f 	bcc  4001b7f0 <msdos_filename_utf8_to_short_name_for_save+0x84>
4001b978:	a0 00 80 01 	add  %g2, %g1, %l0                             
          dest_ptr[i] = ' ';                                          
4001b97c:	c6 2e c0 01 	stb  %g3, [ %i3 + %g1 ]                        
          name_size--;                                                
        }                                                             
        /*                                                            
         * Fill up with blanks. These are DOS's pad characters.       
         */                                                           
        for ( ; i < short_name_size; ++i ) {                          
4001b980:	10 bf ff fc 	b  4001b970 <msdos_filename_utf8_to_short_name_for_save+0x204>
4001b984:	82 00 60 01 	inc  %g1                                       
    else                                                              
      eno = EINVAL;                                                   
  }                                                                   
                                                                      
  if ( eno != 0 ) {                                                   
    errno = eno;                                                      
4001b988:	40 00 02 c1 	call  4001c48c <__errno>                       <== NOT EXECUTED
4001b98c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001b990:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
4001b994:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    return -1;                                                        
  }                                                                   
                                                                      
  return returned_size;                                               
}                                                                     
4001b998:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001b99c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40019da8 <msdos_find_name>: msdos_find_name( rtems_filesystem_location_info_t *parent_loc, const char *name, int name_len ) {
40019da8:	9d e3 bf 60 	save  %sp, -160, %sp                           
    int                rc = RC_OK;                                    
    msdos_fs_info_t   *fs_info = parent_loc->mt_entry->fs_info;       
40019dac:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
    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);         
40019db0:	b8 07 bf e0 	add  %fp, -32, %i4                             
    const char                       *name,                           
    int                               name_len                        
    )                                                                 
{                                                                     
    int                rc = RC_OK;                                    
    msdos_fs_info_t   *fs_info = parent_loc->mt_entry->fs_info;       
40019db4:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    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);         
40019db8:	92 10 20 00 	clr  %o1                                       
40019dbc:	94 10 20 20 	mov  0x20, %o2                                 
    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;                                 
40019dc0:	c0 27 bf cc 	clr  [ %fp + -52 ]                             
    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);         
40019dc4:	40 00 0c 46 	call  4001cedc <memset>                        
40019dc8:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
    name_type = msdos_long_to_short (                                 
40019dcc:	d0 07 60 a4 	ld  [ %i5 + 0xa4 ], %o0                        
40019dd0:	92 10 00 19 	mov  %i1, %o1                                  
40019dd4:	94 10 00 1a 	mov  %i2, %o2                                  
40019dd8:	96 10 00 1c 	mov  %i4, %o3                                  
40019ddc:	7f ff f9 8c 	call  4001840c <msdos_long_to_short>           
40019de0:	98 10 20 0b 	mov  0xb, %o4                                  
                                                                      
    /*                                                                
     * find the node which corresponds to the name in the directory pointed by
     * 'parent_loc'                                                   
     */                                                               
    rc = msdos_get_name_node(parent_loc, false, name, name_len, name_type,
40019de4:	92 10 20 00 	clr  %o1                                       
    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 (                                 
40019de8:	98 10 00 08 	mov  %o0, %o4                                  
                                                                      
    /*                                                                
     * find the node which corresponds to the name in the directory pointed by
     * 'parent_loc'                                                   
     */                                                               
    rc = msdos_get_name_node(parent_loc, false, name, name_len, name_type,
40019dec:	f8 23 a0 5c 	st  %i4, [ %sp + 0x5c ]                        
40019df0:	90 10 00 18 	mov  %i0, %o0                                  
40019df4:	94 10 00 19 	mov  %i1, %o2                                  
40019df8:	96 10 00 1a 	mov  %i2, %o3                                  
40019dfc:	9a 07 bf d0 	add  %fp, -48, %o5                             
40019e00:	7f ff ff aa 	call  40019ca8 <msdos_get_name_node>           
40019e04:	b6 10 00 18 	mov  %i0, %i3                                  
                             &dir_pos, node_entry);                   
    if (rc != RC_OK)                                                  
40019e08:	80 a2 20 00 	cmp  %o0, 0                                    
40019e0c:	12 80 00 68 	bne  40019fac <msdos_find_name+0x204>          
40019e10:	c2 0f bf eb 	ldub  [ %fp + -21 ], %g1                       
        return rc;                                                    
                                                                      
    if (((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_VOLUME_ID) ||     
        ((*MSDOS_DIR_ATTR(node_entry) & MSDOS_ATTR_LFN_MASK) == MSDOS_ATTR_LFN))
        return MSDOS_NAME_NOT_FOUND_ERR;                              
40019e14:	31 00 00 1f 	sethi  %hi(0x7c00), %i0                        
    rc = msdos_get_name_node(parent_loc, false, name, name_len, name_type,
                             &dir_pos, node_entry);                   
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    if (((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_VOLUME_ID) ||     
40019e18:	80 88 60 08 	btst  8, %g1                                   
40019e1c:	12 80 00 64 	bne  40019fac <msdos_find_name+0x204>          <== NEVER TAKEN
40019e20:	90 16 21 01 	or  %i0, 0x101, %o0                            
40019e24:	82 08 60 3f 	and  %g1, 0x3f, %g1                            
40019e28:	80 a0 60 0f 	cmp  %g1, 0xf                                  
40019e2c:	02 80 00 60 	be  40019fac <msdos_find_name+0x204>           <== NEVER TAKEN
40019e30:	92 07 bf d0 	add  %fp, -48, %o1                             
        ((*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(&fs_info->fat, &dir_pos, &fat_fd);             
40019e34:	90 10 00 1d 	mov  %i5, %o0                                  
40019e38:	7f ff e1 1c 	call  400122a8 <fat_file_open>                 
40019e3c:	94 07 bf cc 	add  %fp, -52, %o2                             
    if (rc != RC_OK)                                                  
40019e40:	80 a2 20 00 	cmp  %o0, 0                                    
40019e44:	12 80 00 5a 	bne  40019fac <msdos_find_name+0x204>          <== NEVER TAKEN
40019e48:	f8 07 bf cc 	ld  [ %fp + -52 ], %i4                         
        return rc;                                                    
                                                                      
    fat_fd->dir_pos = dir_pos;                                        
40019e4c:	92 07 bf d0 	add  %fp, -48, %o1                             
40019e50:	90 07 20 20 	add  %i4, 0x20, %o0                            
40019e54:	40 00 0b e3 	call  4001cde0 <memcpy>                        
40019e58:	94 10 20 10 	mov  0x10, %o2                                 
     * 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)                                       
40019e5c:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           
40019e60:	80 a0 60 01 	cmp  %g1, 1                                    
40019e64:	32 80 00 46 	bne,a   40019f7c <msdos_find_name+0x1d4>       
40019e68:	d2 06 e0 08 	ld  [ %i3 + 8 ], %o1                           
    {                                                                 
        fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);          
40019e6c:	c6 17 bf f4 	lduh  [ %fp + -12 ], %g3                       
40019e70:	c4 17 bf fa 	lduh  [ %fp + -6 ], %g2                        
40019e74:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40019e78:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
40019e7c:	89 30 e0 08 	srl  %g3, 8, %g4                               
40019e80:	82 10 63 ff 	or  %g1, 0x3ff, %g1                            
40019e84:	88 09 00 01 	and  %g4, %g1, %g4                             
40019e88:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40019e8c:	87 30 e0 18 	srl  %g3, 0x18, %g3                            
40019e90:	86 11 00 03 	or  %g4, %g3, %g3                              
40019e94:	89 30 a0 08 	srl  %g2, 8, %g4                               
40019e98:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40019e9c:	88 09 00 01 	and  %g4, %g1, %g4                             
40019ea0:	85 30 a0 18 	srl  %g2, 0x18, %g2                            
40019ea4:	84 11 00 02 	or  %g4, %g2, %g2                              
40019ea8:	84 10 c0 02 	or  %g3, %g2, %g2                              
                                                                      
        time_val = *MSDOS_DIR_WRITE_TIME(node_entry);                 
        date = *MSDOS_DIR_WRITE_DATE(node_entry);                     
40019eac:	c6 17 bf f8 	lduh  [ %fp + -8 ], %g3                        
     * 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);          
40019eb0:	c4 27 20 1c 	st  %g2, [ %i4 + 0x1c ]                        
                                                                      
        time_val = *MSDOS_DIR_WRITE_TIME(node_entry);                 
40019eb4:	c4 17 bf f6 	lduh  [ %fp + -10 ], %g2                       
        date = *MSDOS_DIR_WRITE_DATE(node_entry);                     
                                                                      
        fat_fd->mtime = msdos_date_dos2unix(CF_LE_W(date), CF_LE_W(time_val));
40019eb8:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40019ebc:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40019ec0:	91 30 e0 08 	srl  %g3, 8, %o0                               
40019ec4:	89 30 a0 08 	srl  %g2, 8, %g4                               
40019ec8:	90 0a 00 01 	and  %o0, %g1, %o0                             
40019ecc:	87 30 e0 18 	srl  %g3, 0x18, %g3                            
40019ed0:	82 09 00 01 	and  %g4, %g1, %g1                             
40019ed4:	93 30 a0 18 	srl  %g2, 0x18, %o1                            
40019ed8:	90 12 00 03 	or  %o0, %g3, %o0                              
40019edc:	40 00 05 11 	call  4001b320 <msdos_date_dos2unix>           
40019ee0:	92 10 40 09 	or  %g1, %o1, %o1                              
                                                                      
        if ((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_DIRECTORY)     
40019ee4:	c2 0f bf eb 	ldub  [ %fp + -21 ], %g1                       
        fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(node_entry);          
                                                                      
        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));
40019ee8:	d0 27 20 40 	st  %o0, [ %i4 + 0x40 ]                        
                                                                      
        if ((*MSDOS_DIR_ATTR(node_entry)) & MSDOS_ATTR_DIRECTORY)     
40019eec:	80 88 60 10 	btst  0x10, %g1                                
40019ef0:	02 80 00 0e 	be  40019f28 <msdos_find_name+0x180>           
40019ef4:	f8 07 bf cc 	ld  [ %fp + -52 ], %i4                         
        {                                                             
            fat_fd->fat_file_type = FAT_DIRECTORY;                    
            fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                
40019ef8:	03 00 08 00 	sethi  %hi(0x200000), %g1                      
                                                                      
        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;                    
40019efc:	c0 27 20 10 	clr  [ %i4 + 0x10 ]                            
            fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                
40019f00:	c2 27 20 14 	st  %g1, [ %i4 + 0x14 ]                        
                                                                      
            rc = fat_file_size(&fs_info->fat, fat_fd);                
40019f04:	90 10 00 1d 	mov  %i5, %o0                                  
40019f08:	7f ff e3 99 	call  40012d6c <fat_file_size>                 
40019f0c:	92 10 00 1c 	mov  %i4, %o1                                  
            if (rc != RC_OK)                                          
40019f10:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019f14:	02 80 00 0d 	be  40019f48 <msdos_find_name+0x1a0>           <== ALWAYS TAKEN
40019f18:	c2 07 bf cc 	ld  [ %fp + -52 ], %g1                         
            {                                                         
                fat_file_close(&fs_info->fat, fat_fd);                
40019f1c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40019f20:	10 80 00 1d 	b  40019f94 <msdos_find_name+0x1ec>            <== NOT EXECUTED
40019f24:	d2 07 bf cc 	ld  [ %fp + -52 ], %o1                         <== NOT EXECUTED
                return rc;                                            
            }                                                         
        }                                                             
        else                                                          
        {                                                             
            fat_fd->fat_file_size = CF_LE_L(*MSDOS_DIR_FILE_SIZE(node_entry));
40019f28:	7f ff f8 d3 	call  40018274 <CPU_swap_u32>                  
40019f2c:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
            fat_fd->fat_file_type = FAT_FILE;                         
40019f30:	82 10 20 04 	mov  4, %g1                                    
                return rc;                                            
            }                                                         
        }                                                             
        else                                                          
        {                                                             
            fat_fd->fat_file_size = CF_LE_L(*MSDOS_DIR_FILE_SIZE(node_entry));
40019f34:	d0 27 20 18 	st  %o0, [ %i4 + 0x18 ]                        
            fat_fd->fat_file_type = FAT_FILE;                         
40019f38:	c2 27 20 10 	st  %g1, [ %i4 + 0x10 ]                        
            fat_fd->size_limit = MSDOS_MAX_FILE_SIZE;                 
40019f3c:	82 10 3f ff 	mov  -1, %g1                                   
40019f40:	c2 27 20 14 	st  %g1, [ %i4 + 0x14 ]                        
        }                                                             
                                                                      
        /* these data is not actual for zero-length fat-file */       
        fat_fd->map.file_cln = 0;                                     
40019f44:	c2 07 bf cc 	ld  [ %fp + -52 ], %g1                         
        fat_fd->map.disk_cln = fat_fd->cln;                           
40019f48:	c4 00 60 1c 	ld  [ %g1 + 0x1c ], %g2                        
                                                                      
        if ((fat_fd->fat_file_size != 0) &&                           
40019f4c:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
            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;                                     
40019f50:	c0 20 60 34 	clr  [ %g1 + 0x34 ]                            
        fat_fd->map.disk_cln = fat_fd->cln;                           
                                                                      
        if ((fat_fd->fat_file_size != 0) &&                           
40019f54:	80 a0 e0 00 	cmp  %g3, 0                                    
40019f58:	02 80 00 06 	be  40019f70 <msdos_find_name+0x1c8>           
40019f5c:	c4 20 60 38 	st  %g2, [ %g1 + 0x38 ]                        
            (fat_fd->fat_file_size <= fs_info->fat.vol.bpc))          
40019f60:	c8 17 60 06 	lduh  [ %i5 + 6 ], %g4                         
                                                                      
        /* 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) &&                           
40019f64:	80 a0 c0 04 	cmp  %g3, %g4                                  
40019f68:	28 80 00 04 	bleu,a   40019f78 <msdos_find_name+0x1d0>      
40019f6c:	c4 20 60 3c 	st  %g2, [ %g1 + 0x3c ]                        
        {                                                             
            fat_fd->map.last_cln = fat_fd->cln;                       
        }                                                             
        else                                                          
        {                                                             
            fat_fd->map.last_cln = FAT_UNDEFINED_VALUE;               
40019f70:	84 10 3f ff 	mov  -1, %g2                                   
40019f74:	c4 20 60 3c 	st  %g2, [ %g1 + 0x3c ]                        
        }                                                             
    }                                                                 
                                                                      
    /* close fat-file corresponded to the node we searched in */      
    rc = fat_file_close(&fs_info->fat, parent_loc->node_access);      
40019f78:	d2 06 e0 08 	ld  [ %i3 + 8 ], %o1                           
40019f7c:	7f ff e1 e3 	call  40012708 <fat_file_close>                
40019f80:	90 10 00 1d 	mov  %i5, %o0                                  
    if (rc != RC_OK)                                                  
40019f84:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019f88:	02 80 00 07 	be  40019fa4 <msdos_find_name+0x1fc>           <== ALWAYS TAKEN
40019f8c:	d2 07 bf cc 	ld  [ %fp + -52 ], %o1                         
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
40019f90:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40019f94:	7f ff e1 dd 	call  40012708 <fat_file_close>                <== NOT EXECUTED
40019f98:	01 00 00 00 	nop                                            <== NOT EXECUTED
        return rc;                                                    
40019f9c:	10 80 00 04 	b  40019fac <msdos_find_name+0x204>            <== NOT EXECUTED
40019fa0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
    }                                                                 
                                                                      
    /* update node_info_ptr field */                                  
    parent_loc->node_access = fat_fd;                                 
40019fa4:	d2 26 e0 08 	st  %o1, [ %i3 + 8 ]                           
                                                                      
    return rc;                                                        
40019fa8:	90 10 20 00 	clr  %o0                                       
}                                                                     
40019fac:	81 c7 e0 08 	ret                                            
40019fb0:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40018c68 <msdos_find_name_in_fat_file>: const uint8_t *name_utf8, int name_utf8_len, msdos_name_type_t name_type, fat_dir_pos_t *dir_pos, char *name_dir_entry) {
40018c68:	9d e3 be a8 	save  %sp, -344, %sp                           
40018c6c:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        
    int                                retval                     = 0;
    msdos_fs_info_t                   *fs_info                    = mt_entry->fs_info;
40018c70:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
    const uint8_t                        *name_utf8,                  
    int                                   name_utf8_len,              
    msdos_name_type_t                     name_type,                  
    fat_dir_pos_t                        *dir_pos,                    
    char                                 *name_dir_entry)             
{                                                                     
40018c74:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
    unsigned int                       fat_entries;                   
    rtems_dosfs_convert_control       *converter = fs_info->converter;
40018c78:	c2 07 60 a4 	ld  [ %i5 + 0xa4 ], %g1                        
    const uint8_t                        *name_utf8,                  
    int                                   name_utf8_len,              
    msdos_name_type_t                     name_type,                  
    fat_dir_pos_t                        *dir_pos,                    
    char                                 *name_dir_entry)             
{                                                                     
40018c7c:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
    unsigned int                       fat_entries;                   
    rtems_dosfs_convert_control       *converter = fs_info->converter;
    void                              *buffer = converter->buffer.data;
    size_t                             buffer_size = converter->buffer.size;
40018c80:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
    const uint8_t                        *name_utf8,                  
    int                                   name_utf8_len,              
    msdos_name_type_t                     name_type,                  
    fat_dir_pos_t                        *dir_pos,                    
    char                                 *name_dir_entry)             
{                                                                     
40018c84:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
    unsigned int                       fat_entries;                   
    rtems_dosfs_convert_control       *converter = fs_info->converter;
40018c88:	c2 27 bf 58 	st  %g1, [ %fp + -168 ]                        
    void                              *buffer = converter->buffer.data;
    size_t                             buffer_size = converter->buffer.size;
40018c8c:	c4 27 bf 40 	st  %g2, [ %fp + -192 ]                        
    const uint8_t                        *name_utf8,                  
    int                                   name_utf8_len,              
    msdos_name_type_t                     name_type,                  
    fat_dir_pos_t                        *dir_pos,                    
    char                                 *name_dir_entry)             
{                                                                     
40018c90:	f4 07 a0 60 	ld  [ %fp + 0x60 ], %i2                        
    unsigned int                       fat_entries;                   
    rtems_dosfs_convert_control       *converter = fs_info->converter;
    void                              *buffer = converter->buffer.data;
    size_t                             buffer_size = converter->buffer.size;
                                                                      
    assert(name_utf8_len > 0);                                        
40018c94:	80 a7 20 00 	cmp  %i4, 0                                    
40018c98:	14 80 00 0a 	bg  40018cc0 <msdos_find_name_in_fat_file+0x58><== ALWAYS TAKEN
40018c9c:	ee 00 60 04 	ld  [ %g1 + 4 ], %l7                           
40018ca0:	11 10 00 b4 	sethi  %hi(0x4002d000), %o0                    <== NOT EXECUTED
40018ca4:	15 10 00 b5 	sethi  %hi(0x4002d400), %o2                    <== NOT EXECUTED
40018ca8:	17 10 00 b4 	sethi  %hi(0x4002d000), %o3                    <== NOT EXECUTED
40018cac:	90 12 23 18 	or  %o0, 0x318, %o0                            <== NOT EXECUTED
40018cb0:	92 10 27 67 	mov  0x767, %o1                                <== NOT EXECUTED
40018cb4:	94 12 a0 40 	or  %o2, 0x40, %o2                             <== NOT EXECUTED
40018cb8:	10 80 00 4a 	b  40018de0 <msdos_find_name_in_fat_file+0x178><== NOT EXECUTED
40018cbc:	96 12 e3 b0 	or  %o3, 0x3b0, %o3                            <== NOT EXECUTED
static inline void                                                    
fat_dir_pos_init(                                                     
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
40018cc0:	c6 07 a0 5c 	ld  [ %fp + 0x5c ], %g3                        
  dir_pos->sname.ofs = 0;                                             
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
40018cc4:	82 10 3f ff 	mov  -1, %g1                                   
static inline void                                                    
fat_dir_pos_init(                                                     
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
40018cc8:	c0 20 c0 00 	clr  [ %g3 ]                                   
  dir_pos->sname.ofs = 0;                                             
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
40018ccc:	c2 20 e0 08 	st  %g1, [ %g3 + 8 ]                           
  dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;                           
40018cd0:	c2 20 e0 0c 	st  %g1, [ %g3 + 0xc ]                         
                                                                      
    fat_dir_pos_init(dir_pos);                                        
                                                                      
                                                                      
                                                                      
    if (FAT_FD_OF_ROOT_DIR(fat_fd) &&                                 
40018cd4:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40018cd8:	80 a0 60 01 	cmp  %g1, 1                                    
40018cdc:	12 80 00 0c 	bne  40018d0c <msdos_find_name_in_fat_file+0xa4>
40018ce0:	c0 20 e0 04 	clr  [ %g3 + 4 ]                               
40018ce4:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
40018ce8:	80 a0 60 00 	cmp  %g1, 0                                    
40018cec:	32 80 00 09 	bne,a   40018d10 <msdos_find_name_in_fat_file+0xa8><== NEVER TAKEN
40018cf0:	f6 17 60 06 	lduh  [ %i5 + 6 ], %i3                         <== NOT EXECUTED
        (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))            
40018cf4:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       
                                                                      
    fat_dir_pos_init(dir_pos);                                        
                                                                      
                                                                      
                                                                      
    if (FAT_FD_OF_ROOT_DIR(fat_fd) &&                                 
40018cf8:	80 88 60 03 	btst  3, %g1                                   
40018cfc:	22 80 00 05 	be,a   40018d10 <msdos_find_name_in_fat_file+0xa8>
40018d00:	f6 17 60 06 	lduh  [ %i5 + 6 ], %i3                         
        (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))            
        bts2rd = fat_fd->fat_file_size;                               
40018d04:	10 80 00 03 	b  40018d10 <msdos_find_name_in_fat_file+0xa8> 
40018d08:	f6 06 60 18 	ld  [ %i1 + 0x18 ], %i3                        
    else                                                              
        bts2rd = fs_info->fat.vol.bpc;                                
40018d0c:	f6 17 60 06 	lduh  [ %i5 + 6 ], %i3                         
                                                                      
    switch ( name_type ) {                                            
40018d10:	c4 07 a0 58 	ld  [ %fp + 0x58 ], %g2                        
40018d14:	80 a0 a0 01 	cmp  %g2, 1                                    
40018d18:	02 80 00 05 	be  40018d2c <msdos_find_name_in_fat_file+0xc4>
40018d1c:	80 a0 a0 02 	cmp  %g2, 2                                    
40018d20:	02 80 00 0e 	be  40018d58 <msdos_find_name_in_fat_file+0xf0>
40018d24:	d0 07 bf 58 	ld  [ %fp + -168 ], %o0                        
40018d28:	30 80 00 22 	b,a   40018db0 <msdos_find_name_in_fat_file+0x148>
        case MSDOS_NAME_SHORT:                                        
            name_len_for_compare = msdos_filename_utf8_to_short_name_for_compare (
40018d2c:	d0 07 bf 58 	ld  [ %fp + -168 ], %o0                        
40018d30:	d2 07 a0 50 	ld  [ %fp + 0x50 ], %o1                        
40018d34:	d4 07 a0 54 	ld  [ %fp + 0x54 ], %o2                        
40018d38:	96 10 00 17 	mov  %l7, %o3                                  
40018d3c:	40 00 0a 5e 	call  4001b6b4 <msdos_filename_utf8_to_short_name_for_compare>
40018d40:	98 10 20 0b 	mov  0xb, %o4                                  
                converter,                                            
                name_utf8,                                            
                name_utf8_len,                                        
                buffer,                                               
                MSDOS_SHORT_NAME_LEN);                                
            if (name_len_for_compare > 0) {                           
40018d44:	aa 92 20 00 	orcc  %o0, 0, %l5                              
40018d48:	34 80 01 6b 	bg,a   400192f4 <msdos_find_name_in_fat_file+0x68c><== ALWAYS TAKEN
40018d4c:	a0 10 20 00 	clr  %l0                                       
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
40018d50:	10 80 00 27 	b  40018dec <msdos_find_name_in_fat_file+0x184><== NOT EXECUTED
40018d54:	a8 10 20 00 	clr  %l4                                       <== NOT EXECUTED
            }                                                         
            else                                                      
                retval = -1;                                          
        break;                                                        
        case MSDOS_NAME_LONG:                                         
            name_len_for_save = msdos_filename_utf8_to_long_name_for_save (
40018d58:	d2 07 a0 50 	ld  [ %fp + 0x50 ], %o1                        
40018d5c:	d4 07 a0 54 	ld  [ %fp + 0x54 ], %o2                        
40018d60:	d8 07 bf 40 	ld  [ %fp + -192 ], %o4                        
40018d64:	40 00 09 de 	call  4001b4dc <msdos_filename_utf8_to_long_name_for_save>
40018d68:	96 10 00 17 	mov  %l7, %o3                                  
                converter,                                            
                name_utf8,                                            
                name_utf8_len,                                        
                buffer,                                               
                buffer_size);                                         
            if (name_len_for_save > 0) {                              
40018d6c:	80 a2 20 00 	cmp  %o0, 0                                    
40018d70:	04 80 00 1e 	ble  40018de8 <msdos_find_name_in_fat_file+0x180>
40018d74:	92 10 20 1a 	mov  0x1a, %o1                                 
                fat_entries = (name_len_for_save + MSDOS_LFN_ENTRY_SIZE - 1)
                    / MSDOS_LFN_ENTRY_SIZE;                           
40018d78:	7f ff a6 a2 	call  40002800 <.div>                          
40018d7c:	90 02 20 19 	add  %o0, 0x19, %o0                            
                name_len_for_compare = msdos_filename_utf8_to_long_name_for_compare (
40018d80:	d2 07 a0 50 	ld  [ %fp + 0x50 ], %o1                        
                name_utf8_len,                                        
                buffer,                                               
                buffer_size);                                         
            if (name_len_for_save > 0) {                              
                fat_entries = (name_len_for_save + MSDOS_LFN_ENTRY_SIZE - 1)
                    / MSDOS_LFN_ENTRY_SIZE;                           
40018d84:	a0 10 00 08 	mov  %o0, %l0                                  
                name_len_for_compare = msdos_filename_utf8_to_long_name_for_compare (
40018d88:	d4 07 a0 54 	ld  [ %fp + 0x54 ], %o2                        
40018d8c:	d0 07 bf 58 	ld  [ %fp + -168 ], %o0                        
40018d90:	d8 07 bf 40 	ld  [ %fp + -192 ], %o4                        
40018d94:	40 00 09 ab 	call  4001b440 <msdos_filename_utf8_to_long_name_for_compare>
40018d98:	96 10 00 17 	mov  %l7, %o3                                  
                  converter,                                          
                  name_utf8,                                          
                  name_utf8_len,                                      
                  buffer,                                             
                  buffer_size);                                       
                if (0 >= name_len_for_compare) {                      
40018d9c:	aa 92 20 00 	orcc  %o0, 0, %l5                              
40018da0:	14 80 01 56 	bg  400192f8 <msdos_find_name_in_fat_file+0x690><== ALWAYS TAKEN
40018da4:	82 10 3f ff 	mov  -1, %g1                                   
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
40018da8:	10 80 00 11 	b  40018dec <msdos_find_name_in_fat_file+0x184><== NOT EXECUTED
40018dac:	a8 10 20 00 	clr  %l4                                       <== NOT EXECUTED
            }                                                         
            else                                                      
                retval = -1;                                          
        break;                                                        
        default:                                                      
            errno = EINVAL;                                           
40018db0:	40 00 0d b7 	call  4001c48c <__errno>                       
40018db4:	a8 10 20 00 	clr  %l4                                       
40018db8:	82 10 20 16 	mov  0x16, %g1                                 
            retval = -1;                                              
        break;                                                        
40018dbc:	10 80 00 0c 	b  40018dec <msdos_find_name_in_fat_file+0x184>
40018dc0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
#endif                                                                
                                                                      
        if (bytes_read < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)           
            rtems_set_errno_and_return_minus_one(EIO);                
                                                                      
        assert(bytes_read == bts2rd);                                 
40018dc4:	11 10 00 b4 	sethi  %hi(0x4002d000), %o0                    <== NOT EXECUTED
40018dc8:	15 10 00 b5 	sethi  %hi(0x4002d400), %o2                    <== NOT EXECUTED
40018dcc:	17 10 00 b4 	sethi  %hi(0x4002d000), %o3                    <== NOT EXECUTED
40018dd0:	90 12 23 18 	or  %o0, 0x318, %o0                            <== NOT EXECUTED
40018dd4:	92 10 25 13 	mov  0x513, %o1                                <== NOT EXECUTED
40018dd8:	94 12 a0 20 	or  %o2, 0x20, %o2                             <== NOT EXECUTED
40018ddc:	96 12 e3 c8 	or  %o3, 0x3c8, %o3                            <== NOT EXECUTED
40018de0:	7f ff af 95 	call  40004c34 <__assert_func>                 <== NOT EXECUTED
40018de4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
40018de8:	a8 10 20 00 	clr  %l4	! 0 <_TLS_BSS_size>                   
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
40018dec:	a6 10 20 00 	clr  %l3                                       
    msdos_fs_info_t                   *fs_info                    = mt_entry->fs_info;
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
40018df0:	a4 10 20 00 	clr  %l2                                       
    int                                retval                     = 0;
    msdos_fs_info_t                   *fs_info                    = mt_entry->fs_info;
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
40018df4:	c0 27 bf 5c 	clr  [ %fp + -164 ]                            
40018df8:	b0 10 3f ff 	mov  -1, %i0                                   
          &empty_space_offset,                                        
          &empty_space_entry,                                         
          &empty_space_count);                                        
    }                                                                 
    /* Create a non-existing file/directory if requested */           
    if (   retval == RC_OK                                            
40018dfc:	80 a6 20 00 	cmp  %i0, 0                                    
40018e00:	12 80 02 9a 	bne  40019868 <msdos_find_name_in_fat_file+0xc00>
40018e04:	c2 07 a0 4c 	ld  [ %fp + 0x4c ], %g1                        
40018e08:	80 a0 60 00 	cmp  %g1, 0                                    
40018e0c:	02 80 02 97 	be  40019868 <msdos_find_name_in_fat_file+0xc00>
40018e10:	c4 07 a0 58 	ld  [ %fp + 0x58 ], %g2                        
        && create_node) {                                             
        switch (name_type) {                                          
40018e14:	80 a0 a0 01 	cmp  %g2, 1                                    
40018e18:	02 80 00 05 	be  40018e2c <msdos_find_name_in_fat_file+0x1c4>
40018e1c:	80 a0 a0 02 	cmp  %g2, 2                                    
40018e20:	02 80 00 0e 	be  40018e58 <msdos_find_name_in_fat_file+0x1f0><== ALWAYS TAKEN
40018e24:	d0 07 bf 58 	ld  [ %fp + -168 ], %o0                        
40018e28:	30 80 00 18 	b,a   40018e88 <msdos_find_name_in_fat_file+0x220><== NOT EXECUTED
          case MSDOS_NAME_SHORT:                                      
              name_len_for_save = msdos_filename_utf8_to_short_name_for_save (
40018e2c:	d0 07 bf 58 	ld  [ %fp + -168 ], %o0                        
40018e30:	d2 07 a0 50 	ld  [ %fp + 0x50 ], %o1                        
40018e34:	d4 07 a0 54 	ld  [ %fp + 0x54 ], %o2                        
40018e38:	96 10 00 17 	mov  %l7, %o3                                  
40018e3c:	40 00 0a 4c 	call  4001b76c <msdos_filename_utf8_to_short_name_for_save>
40018e40:	98 10 20 0b 	mov  0xb, %o4                                  
                  converter,                                          
                  name_utf8,                                          
                  name_utf8_len,                                      
                  buffer,                                             
                  MSDOS_SHORT_NAME_LEN);                              
              if (name_len_for_save > 0 ) {                           
40018e44:	80 a2 20 00 	cmp  %o0, 0                                    
40018e48:	34 80 00 52 	bg,a   40018f90 <msdos_find_name_in_fat_file+0x328><== ALWAYS TAKEN
40018e4c:	a0 10 20 00 	clr  %l0                                       
        int      slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
                        MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + fat_entries + 1;
        msdos_short_name_hex(MSDOS_DIR_NAME(name_dir_entry), slot);   
    }                                                                 
                                                                      
    if (fat_entries)                                                  
40018e50:	10 80 00 3e 	b  40018f48 <msdos_find_name_in_fat_file+0x2e0><== NOT EXECUTED
40018e54:	80 a4 20 00 	cmp  %l0, 0                                    <== NOT EXECUTED
              }                                                       
              else                                                    
                  retval = -1;                                        
          break;                                                      
          case MSDOS_NAME_LONG:                                       
              name_len_for_save = msdos_filename_utf8_to_long_name_for_save (
40018e58:	d2 07 a0 50 	ld  [ %fp + 0x50 ], %o1                        
40018e5c:	d4 07 a0 54 	ld  [ %fp + 0x54 ], %o2                        
40018e60:	d8 07 bf 40 	ld  [ %fp + -192 ], %o4                        
40018e64:	40 00 09 9e 	call  4001b4dc <msdos_filename_utf8_to_long_name_for_save>
40018e68:	96 10 00 17 	mov  %l7, %o3                                  
                  converter,                                          
                  name_utf8,                                          
                  name_utf8_len,                                      
                  buffer,                                             
                  buffer_size);                                       
              if (name_len_for_save > 0) {                            
40018e6c:	80 a2 20 00 	cmp  %o0, 0                                    
40018e70:	04 80 00 0b 	ble  40018e9c <msdos_find_name_in_fat_file+0x234><== NEVER TAKEN
40018e74:	90 02 20 19 	add  %o0, 0x19, %o0                            
                  fat_entries = (name_len_for_save + MSDOS_LFN_ENTRY_SIZE - 1)
                    / MSDOS_LFN_ENTRY_SIZE;                           
40018e78:	7f ff a6 62 	call  40002800 <.div>                          
40018e7c:	92 10 20 1a 	mov  0x1a, %o1                                 
40018e80:	10 80 00 07 	b  40018e9c <msdos_find_name_in_fat_file+0x234>
40018e84:	a0 10 00 08 	mov  %o0, %l0                                  
              }                                                       
              else                                                    
                  retval = -1;                                        
          break;                                                      
          default:                                                    
              errno = EINVAL;                                         
40018e88:	40 00 0d 81 	call  4001c48c <__errno>                       <== NOT EXECUTED
40018e8c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40018e90:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
40018e94:	10 80 00 2c 	b  40018f44 <msdos_find_name_in_fat_file+0x2dc><== NOT EXECUTED
40018e98:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
     * file name to the slot of the SFN entry. This will mean no clashes
     * in this directory.                                             
     */                                                               
    if (name_type == MSDOS_NAME_LONG)                                 
    {                                                                 
        int      slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
40018e9c:	d0 07 bf 5c 	ld  [ %fp + -164 ], %o0                        
40018ea0:	7f ff a6 1c 	call  40002710 <.umul>                         
40018ea4:	92 10 00 1b 	mov  %i3, %o1                                  
{                                                                     
    static const char* hex = "0123456789ABCDEF";                      
    char* c = MSDOS_DIR_NAME(sfn);                                    
    int   i;                                                          
    for (i = 0; i < 2; i++, c++)                                      
      if ((*c == ' ') || (*c == '.'))                                 
40018ea8:	c2 4e 80 00 	ldsb  [ %i2 ], %g1                             
     * file name to the slot of the SFN entry. This will mean no clashes
     * in this directory.                                             
     */                                                               
    if (name_type == MSDOS_NAME_LONG)                                 
    {                                                                 
        int      slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
40018eac:	90 02 00 12 	add  %o0, %l2, %o0                             
{                                                                     
    static const char* hex = "0123456789ABCDEF";                      
    char* c = MSDOS_DIR_NAME(sfn);                                    
    int   i;                                                          
    for (i = 0; i < 2; i++, c++)                                      
      if ((*c == ' ') || (*c == '.'))                                 
40018eb0:	80 a0 60 20 	cmp  %g1, 0x20                                 
     * file name to the slot of the SFN entry. This will mean no clashes
     * in this directory.                                             
     */                                                               
    if (name_type == MSDOS_NAME_LONG)                                 
    {                                                                 
        int      slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
40018eb4:	b1 32 20 05 	srl  %o0, 5, %i0                               
                        MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + fat_entries + 1;
40018eb8:	b0 06 20 01 	inc  %i0                                       
{                                                                     
    static const char* hex = "0123456789ABCDEF";                      
    char* c = MSDOS_DIR_NAME(sfn);                                    
    int   i;                                                          
    for (i = 0; i < 2; i++, c++)                                      
      if ((*c == ' ') || (*c == '.'))                                 
40018ebc:	02 80 00 05 	be  40018ed0 <msdos_find_name_in_fat_file+0x268><== NEVER TAKEN
40018ec0:	b0 06 00 10 	add  %i0, %l0, %i0                             
40018ec4:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
40018ec8:	32 80 00 05 	bne,a   40018edc <msdos_find_name_in_fat_file+0x274><== ALWAYS TAKEN
40018ecc:	c2 4e a0 01 	ldsb  [ %i2 + 1 ], %g1                         
        *c = '_';                                                     
40018ed0:	82 10 20 5f 	mov  0x5f, %g1                                 <== NOT EXECUTED
40018ed4:	c2 2e 80 00 	stb  %g1, [ %i2 ]                              <== NOT EXECUTED
{                                                                     
    static const char* hex = "0123456789ABCDEF";                      
    char* c = MSDOS_DIR_NAME(sfn);                                    
    int   i;                                                          
    for (i = 0; i < 2; i++, c++)                                      
      if ((*c == ' ') || (*c == '.'))                                 
40018ed8:	c2 4e a0 01 	ldsb  [ %i2 + 1 ], %g1                         <== NOT EXECUTED
40018edc:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
40018ee0:	22 80 00 06 	be,a   40018ef8 <msdos_find_name_in_fat_file+0x290><== NEVER TAKEN
40018ee4:	82 10 20 5f 	mov  0x5f, %g1                                 <== NOT EXECUTED
40018ee8:	80 a0 60 20 	cmp  %g1, 0x20                                 
40018eec:	12 80 00 05 	bne  40018f00 <msdos_find_name_in_fat_file+0x298>
40018ef0:	82 10 20 00 	clr  %g1                                       
        *c = '_';                                                     
40018ef4:	82 10 20 5f 	mov  0x5f, %g1                                 
40018ef8:	c2 2e a0 01 	stb  %g1, [ %i2 + 1 ]                          
    int                                retval                     = 0;
    msdos_fs_info_t                   *fs_info                    = mt_entry->fs_info;
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
40018efc:	82 10 20 00 	clr  %g1                                       
    int   i;                                                          
    for (i = 0; i < 2; i++, c++)                                      
      if ((*c == ' ') || (*c == '.'))                                 
        *c = '_';                                                     
    for (i = 0; i < 4; i++, c++)                                      
      *c = hex[(num >> ((3 - i) * 4)) & 0xf];                         
40018f00:	39 10 00 b2 	sethi  %hi(0x4002c800), %i4                    
40018f04:	86 20 00 01 	neg  %g1, %g3                                  
40018f08:	88 17 22 90 	or  %i4, 0x290, %g4                            
40018f0c:	87 28 e0 02 	sll  %g3, 2, %g3                               
40018f10:	86 00 e0 0c 	add  %g3, 0xc, %g3                             
40018f14:	87 3e 00 03 	sra  %i0, %g3, %g3                             
40018f18:	86 08 e0 0f 	and  %g3, 0xf, %g3                             
40018f1c:	c6 09 00 03 	ldub  [ %g4 + %g3 ], %g3                       
40018f20:	84 06 80 01 	add  %i2, %g1, %g2                             
    char* c = MSDOS_DIR_NAME(sfn);                                    
    int   i;                                                          
    for (i = 0; i < 2; i++, c++)                                      
      if ((*c == ' ') || (*c == '.'))                                 
        *c = '_';                                                     
    for (i = 0; i < 4; i++, c++)                                      
40018f24:	82 00 60 01 	inc  %g1                                       
40018f28:	80 a0 60 04 	cmp  %g1, 4                                    
40018f2c:	12 bf ff f6 	bne  40018f04 <msdos_find_name_in_fat_file+0x29c>
40018f30:	c6 28 a0 02 	stb  %g3, [ %g2 + 2 ]                          
      *c = hex[(num >> ((3 - i) * 4)) & 0xf];                         
    *c++ = '~';                                                       
40018f34:	82 10 20 7e 	mov  0x7e, %g1                                 
40018f38:	c2 2e a0 06 	stb  %g1, [ %i2 + 6 ]                          
    *c++ = '1';                                                       
40018f3c:	82 10 20 31 	mov  0x31, %g1                                 
40018f40:	c2 2e a0 07 	stb  %g1, [ %i2 + 7 ]                          
        int      slot = (((empty_space_offset * bts2rd) + empty_space_entry) /
                        MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE) + fat_entries + 1;
        msdos_short_name_hex(MSDOS_DIR_NAME(name_dir_entry), slot);   
    }                                                                 
                                                                      
    if (fat_entries)                                                  
40018f44:	80 a4 20 00 	cmp  %l0, 0                                    
40018f48:	02 80 00 13 	be  40018f94 <msdos_find_name_in_fat_file+0x32c><== NEVER TAKEN
40018f4c:	a2 10 20 00 	clr  %l1                                       
40018f50:	82 10 20 00 	clr  %g1                                       
    {                                                                 
        uint8_t* p = (uint8_t*) MSDOS_DIR_NAME(name_dir_entry);       
        int      i;                                                   
        for (i = 0; i < 11; i++, p++)                                 
            lfn_checksum =                                            
40018f54:	c6 0e 80 01 	ldub  [ %i2 + %g1 ], %g3                       
40018f58:	84 0c 60 01 	and  %l1, 1, %g2                               
40018f5c:	80 a0 00 02 	cmp  %g0, %g2                                  
40018f60:	a2 0c 60 ff 	and  %l1, 0xff, %l1                            
40018f64:	84 40 3f ff 	addx  %g0, -1, %g2                             
40018f68:	a3 34 60 01 	srl  %l1, 1, %l1                               
40018f6c:	84 08 a0 80 	and  %g2, 0x80, %g2                            
40018f70:	a2 04 40 03 	add  %l1, %g3, %l1                             
40018f74:	84 00 bf 80 	add  %g2, -128, %g2                            
                                                                      
    if (fat_entries)                                                  
    {                                                                 
        uint8_t* p = (uint8_t*) MSDOS_DIR_NAME(name_dir_entry);       
        int      i;                                                   
        for (i = 0; i < 11; i++, p++)                                 
40018f78:	82 00 60 01 	inc  %g1                                       
40018f7c:	80 a0 60 0b 	cmp  %g1, 0xb                                  
40018f80:	12 bf ff f5 	bne  40018f54 <msdos_find_name_in_fat_file+0x2ec>
40018f84:	a2 04 40 02 	add  %l1, %g2, %l1                             
     * 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)                                       
40018f88:	10 80 00 04 	b  40018f98 <msdos_find_name_in_fat_file+0x330>
40018f8c:	80 a4 e0 00 	cmp  %l3, 0                                    
                                                                      
)                                                                     
{                                                                     
    int              ret                = 0;                          
    ssize_t          bytes_written      = 0;                          
    uint8_t          lfn_checksum       = 0;                          
40018f90:	a2 10 20 00 	clr  %l1                                       
     * 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)                                       
40018f94:	80 a4 e0 00 	cmp  %l3, 0                                    
40018f98:	22 80 00 07 	be,a   40018fb4 <msdos_find_name_in_fat_file+0x34c>
40018f9c:	e8 27 bf 5c 	st  %l4, [ %fp + -164 ]                        
    int              ret                = 0;                          
    ssize_t          bytes_written      = 0;                          
    uint8_t          lfn_checksum       = 0;                          
    uint32_t         empty_space_offset = empty_space_offset_param;   
    uint32_t         empty_space_entry  = empty_space_entry_param;    
    bool             read_cluster       = false;                      
40018fa0:	c6 07 bf 5c 	ld  [ %fp + -164 ], %g3                        
40018fa4:	a8 1d 00 03 	xor  %l4, %g3, %l4                             
40018fa8:	80 a0 00 14 	cmp  %g0, %l4                                  
40018fac:	10 80 00 04 	b  40018fbc <msdos_find_name_in_fat_file+0x354>
40018fb0:	a8 40 20 00 	addx  %g0, 0, %l4                              
     */                                                               
    if (empty_space_count == 0)                                       
    {                                                                 
        read_cluster = true;                                          
        empty_space_offset = dir_offset;                              
        empty_space_entry = 0;                                        
40018fb4:	a4 10 20 00 	clr  %l2                                       
     * be at the next cluster so we can just make empty_space_offset  
     * that value.                                                    
     */                                                               
    if (empty_space_count == 0)                                       
    {                                                                 
        read_cluster = true;                                          
40018fb8:	a8 10 20 01 	mov  1, %l4                                    
40018fbc:	d0 07 bf 5c 	ld  [ %fp + -164 ], %o0                        
        read_cluster = true;                                          
                                                                      
    /*                                                                
     * Handle the entry writes.                                       
     */                                                               
    lfn_start.cln = lfn_start.ofs = FAT_FILE_SHORT_NAME;              
40018fc0:	82 10 3f ff 	mov  -1, %g1                                   
40018fc4:	92 10 00 1b 	mov  %i3, %o1                                  
40018fc8:	c2 27 bf 94 	st  %g1, [ %fp + -108 ]                        
40018fcc:	7f ff a5 d1 	call  40002710 <.umul>                         
40018fd0:	c2 27 bf 90 	st  %g1, [ %fp + -112 ]                        
40018fd4:	83 2c 20 02 	sll  %l0, 2, %g1                               
40018fd8:	ab 2c 20 04 	sll  %l0, 4, %l5                               
40018fdc:	b8 10 00 08 	mov  %o0, %i4                                  
40018fe0:	aa 25 40 01 	sub  %l5, %g1, %l5                             
    lfn_entry = 0;                                                    
40018fe4:	a6 10 20 00 	clr  %l3                                       
40018fe8:	aa 05 40 10 	add  %l5, %l0, %l5                             
    const uint32_t                        empty_space_entry_param,    
    const uint32_t                        empty_space_count           
                                                                      
)                                                                     
{                                                                     
    int              ret                = 0;                          
40018fec:	b0 10 20 00 	clr  %i0                                       
40018ff0:	ab 2d 60 01 	sll  %l5, 1, %l5                               
#endif                                                                
                                                                      
    /*                                                                
     * The one more is the short entry.                               
     */                                                               
    while (lfn_entry < (fat_entries + 1))                             
40018ff4:	a0 04 20 01 	inc  %l0                                       
40018ff8:	aa 05 c0 15 	add  %l7, %l5, %l5                             
40018ffc:	ea 27 bf 58 	st  %l5, [ %fp + -168 ]                        
40019000:	80 a4 c0 10 	cmp  %l3, %l0                                  
40019004:	1a 80 02 19 	bcc  40019868 <msdos_find_name_in_fat_file+0xc00>
40019008:	80 8d 20 ff 	btst  0xff, %l4                                
    {                                                                 
        int length = 0;                                               
                                                                      
        if (read_cluster)                                             
4001900c:	02 80 00 28 	be  400190ac <msdos_find_name_in_fat_file+0x444>
40019010:	c4 07 bf 58 	ld  [ %fp + -168 ], %g2                        
        {                                                             
            uint32_t new_length;                                      
#if MSDOS_FIND_PRINT                                                  
            printf ("MSFS:[9.1] eso:%li\n", empty_space_offset);      
#endif                                                                
            ret = fat_file_read(&fs_info->fat, fat_fd,                
40019014:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
40019018:	90 10 00 1d 	mov  %i5, %o0                                  
4001901c:	92 10 00 19 	mov  %i1, %o1                                  
40019020:	94 10 00 1c 	mov  %i4, %o2                                  
40019024:	7f ff e5 07 	call  40012440 <fat_file_read>                 
40019028:	96 10 00 1b 	mov  %i3, %o3                                  
                                (empty_space_offset * bts2rd), bts2rd,
                                fs_info->cl_buf);                     
                                                                      
            if (ret != bts2rd)                                        
4001902c:	80 a2 00 1b 	cmp  %o0, %i3                                  
40019030:	02 80 00 1e 	be  400190a8 <msdos_find_name_in_fat_file+0x440><== NEVER TAKEN
40019034:	b0 10 00 08 	mov  %o0, %i0                                  
            {                                                         
                if (ret != FAT_EOF)                                   
40019038:	80 a2 20 00 	cmp  %o0, 0                                    
4001903c:	12 80 00 9e 	bne  400192b4 <msdos_find_name_in_fat_file+0x64c><== NEVER TAKEN
40019040:	90 10 00 1d 	mov  %i5, %o0                                  
                    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 (&fs_info->fat, fat_fd, false,  
40019044:	92 10 00 19 	mov  %i1, %o1                                  
40019048:	94 10 20 00 	clr  %o2                                       
4001904c:	96 10 00 1c 	mov  %i4, %o3                                  
40019050:	7f ff e6 10 	call  40012890 <fat_file_extend>               
40019054:	98 07 bf 70 	add  %fp, -144, %o4                            
                                       empty_space_offset * bts2rd, &new_length);
                                                                      
                if (ret != RC_OK)                                     
40019058:	80 a2 20 00 	cmp  %o0, 0                                    
4001905c:	12 80 00 a2 	bne  400192e4 <msdos_find_name_in_fat_file+0x67c><== NEVER TAKEN
40019060:	c2 07 bf 70 	ld  [ %fp + -144 ], %g1                        
                    return ret;                                       
                                                                      
#if MSDOS_FIND_PRINT                                                  
                printf ("MSFS:[9.3] extended: %"PRIu32" <-> %"PRIu32"\n", new_length, empty_space_offset * bts2rd);
#endif                                                                
                if (new_length != (empty_space_offset * bts2rd))      
40019064:	80 a0 40 1c 	cmp  %g1, %i4                                  
40019068:	12 80 00 93 	bne  400192b4 <msdos_find_name_in_fat_file+0x64c><== NEVER TAKEN
4001906c:	92 10 20 00 	clr  %o1                                       
                    rtems_set_errno_and_return_minus_one(EIO);        
                                                                      
                memset(fs_info->cl_buf, 0, bts2rd);                   
40019070:	d0 07 60 a0 	ld  [ %i5 + 0xa0 ], %o0                        
40019074:	40 00 0f 9a 	call  4001cedc <memset>                        
40019078:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
                bytes_written = fat_file_write(&fs_info->fat, fat_fd, 
4001907c:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
40019080:	90 10 00 1d 	mov  %i5, %o0                                  
40019084:	92 10 00 19 	mov  %i1, %o1                                  
40019088:	94 10 00 1c 	mov  %i4, %o2                                  
4001908c:	7f ff e6 90 	call  40012acc <fat_file_write>                
40019090:	96 10 00 1b 	mov  %i3, %o3                                  
                                               empty_space_offset * bts2rd,
                                               bts2rd, fs_info->cl_buf);
#if MSDOS_FIND_PRINT                                                  
                printf ("MSFS:[9.4] clear write: %d\n", ret);         
#endif                                                                
                if (bytes_written == -1)                              
40019094:	80 a2 3f ff 	cmp  %o0, -1                                   
40019098:	02 80 00 95 	be  400192ec <msdos_find_name_in_fat_file+0x684>
4001909c:	80 a2 00 1b 	cmp  %o0, %i3                                  
                    return -1;                                        
                else if (bytes_written != bts2rd)                     
400190a0:	12 80 00 85 	bne  400192b4 <msdos_find_name_in_fat_file+0x64c><== NEVER TAKEN
400190a4:	01 00 00 00 	nop                                            
400190a8:	c4 07 bf 58 	ld  [ %fp + -168 ], %g2                        
400190ac:	83 2c e0 02 	sll  %l3, 2, %g1                               
400190b0:	9b 2c e0 04 	sll  %l3, 4, %o5                               
400190b4:	ac 04 e0 01 	add  %l3, 1, %l6                               
400190b8:	9a 23 40 01 	sub  %o5, %g1, %o5                             
                }                                                     
                else                                                  
                {                                                     
                    p [0] = fill;                                     
                    p [1] = fill;                                     
                    fill = 0xff;                                      
400190bc:	86 10 20 00 	clr  %g3                                       
400190c0:	9a 03 40 13 	add  %o5, %l3, %o5                             
    /*                                                                
     * The one more is the short entry.                               
     */                                                               
    while (lfn_entry < (fat_entries + 1))                             
    {                                                                 
        int length = 0;                                               
400190c4:	a8 10 20 00 	clr  %l4                                       
400190c8:	9b 2b 60 01 	sll  %o5, 1, %o5                               
400190cc:	9a 20 80 0d 	sub  %g2, %o5, %o5                             
400190d0:	9a 03 7f e6 	add  %o5, -26, %o5                             
400190d4:	ae 05 00 12 	add  %l4, %l2, %l7                             
                                                                      
#if MSDOS_FIND_PRINT                                                  
        printf ("MSFS:[10] eso:%li\n", empty_space_offset);           
#endif                                                                
                                                                      
        for (dir_entry = empty_space_entry;                           
400190d8:	80 a5 c0 1b 	cmp  %l7, %i3                                  
400190dc:	1a 80 00 6a 	bcc  40019284 <msdos_find_name_in_fat_file+0x61c>
400190e0:	a6 05 bf ff 	add  %l6, -1, %l3                              
             dir_entry < bts2rd;                                      
             dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)          
        {                                                             
            char*       entry = (char*) fs_info->cl_buf + dir_entry;  
400190e4:	c8 07 60 a0 	ld  [ %i5 + 0xa0 ], %g4                        
            char*       p;                                            
            const char* n;                                            
            int         i;                                            
            char        fill = 0;                                     
                                                                      
            length += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;              
400190e8:	a8 05 20 20 	add  %l4, 0x20, %l4                            
                                                                      
        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;  
400190ec:	aa 01 00 17 	add  %g4, %l7, %l5                             
                    length, lfn_entry);                               
#endif                                                                
            /*                                                        
             * Time to write the short file name entry.               
             */                                                       
            if (lfn_entry == (fat_entries + 1))                       
400190f0:	80 a5 80 10 	cmp  %l6, %l0                                  
400190f4:	12 80 00 27 	bne  40019190 <msdos_find_name_in_fat_file+0x528>
400190f8:	a6 10 00 16 	mov  %l6, %l3                                  
            {                                                         
                /* get current cluster number */                      
                ret = fat_file_ioctl(&fs_info->fat, fat_fd, F_CLU_NUM,
400190fc:	d8 07 a0 5c 	ld  [ %fp + 0x5c ], %o4                        
40019100:	90 10 00 1d 	mov  %i5, %o0                                  
40019104:	92 10 00 19 	mov  %i1, %o1                                  
40019108:	94 10 20 01 	mov  1, %o2                                    
4001910c:	7f ff e5 ac 	call  400127bc <fat_file_ioctl>                
40019110:	96 10 00 1c 	mov  %i4, %o3                                  
                                    empty_space_offset * bts2rd,      
                                    &dir_pos->sname.cln);             
                if (ret != RC_OK)                                     
40019114:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019118:	12 80 01 d4 	bne  40019868 <msdos_find_name_in_fat_file+0xc00><== NEVER TAKEN
4001911c:	c6 07 a0 5c 	ld  [ %fp + 0x5c ], %g3                        
                    return ret;                                       
                                                                      
                dir_pos->sname.ofs = dir_entry;                       
                                                                      
                if (lfn_start.cln != FAT_FILE_SHORT_NAME)             
40019120:	d2 07 bf 90 	ld  [ %fp + -112 ], %o1                        
40019124:	80 a2 7f ff 	cmp  %o1, -1                                   
40019128:	12 80 00 0d 	bne  4001915c <msdos_find_name_in_fat_file+0x4f4>
4001912c:	ee 20 e0 04 	st  %l7, [ %g3 + 4 ]                           
                                        &lfn_start.cln);              
                    if (ret != RC_OK)                                 
                        return ret;                                   
                }                                                     
                                                                      
                dir_pos->lname.cln = lfn_start.cln;                   
40019130:	c2 07 bf 90 	ld  [ %fp + -112 ], %g1                        
40019134:	c4 07 a0 5c 	ld  [ %fp + 0x5c ], %g2                        
                dir_pos->lname.ofs = lfn_start.ofs;                   
                                                                      
                /* write new node entry */                            
                memcpy (entry, (uint8_t *) name_dir_entry,            
40019138:	90 10 00 15 	mov  %l5, %o0                                  
                                        &lfn_start.cln);              
                    if (ret != RC_OK)                                 
                        return ret;                                   
                }                                                     
                                                                      
                dir_pos->lname.cln = lfn_start.cln;                   
4001913c:	c2 20 a0 08 	st  %g1, [ %g2 + 8 ]                           
                dir_pos->lname.ofs = lfn_start.ofs;                   
40019140:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
                                                                      
                /* write new node entry */                            
                memcpy (entry, (uint8_t *) name_dir_entry,            
40019144:	92 10 00 1a 	mov  %i2, %o1                                  
                    if (ret != RC_OK)                                 
                        return ret;                                   
                }                                                     
                                                                      
                dir_pos->lname.cln = lfn_start.cln;                   
                dir_pos->lname.ofs = lfn_start.ofs;                   
40019148:	c2 20 a0 0c 	st  %g1, [ %g2 + 0xc ]                         
                                                                      
                /* write new node entry */                            
                memcpy (entry, (uint8_t *) name_dir_entry,            
4001914c:	40 00 0f 25 	call  4001cde0 <memcpy>                        
40019150:	94 10 20 20 	mov  0x20, %o2                                 
            if (lfn_entry == 1)                                       
                *MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
            *MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;                 
        }                                                             
                                                                      
        bytes_written = fat_file_write(&fs_info->fat, fat_fd,         
40019154:	10 80 00 4d 	b  40019288 <msdos_find_name_in_fat_file+0x620>
40019158:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
                                                                      
                dir_pos->sname.ofs = dir_entry;                       
                                                                      
                if (lfn_start.cln != FAT_FILE_SHORT_NAME)             
                {                                                     
                    ret = fat_file_ioctl(&fs_info->fat, fat_fd, F_CLU_NUM,
4001915c:	7f ff a5 6d 	call  40002710 <.umul>                         
40019160:	90 10 00 1b 	mov  %i3, %o0                                  
40019164:	92 10 00 19 	mov  %i1, %o1                                  
40019168:	96 10 00 08 	mov  %o0, %o3                                  
4001916c:	94 10 20 01 	mov  1, %o2                                    
40019170:	90 10 00 1d 	mov  %i5, %o0                                  
40019174:	7f ff e5 92 	call  400127bc <fat_file_ioctl>                
40019178:	98 07 bf 90 	add  %fp, -112, %o4                            
                                        lfn_start.cln * bts2rd,       
                                        &lfn_start.cln);              
                    if (ret != RC_OK)                                 
4001917c:	80 a2 20 00 	cmp  %o0, 0                                    
40019180:	02 bf ff ed 	be  40019134 <msdos_find_name_in_fat_file+0x4cc><== ALWAYS TAKEN
40019184:	c2 07 bf 90 	ld  [ %fp + -112 ], %g1                        
                                                                      
                dir_pos->sname.ofs = dir_entry;                       
                                                                      
                if (lfn_start.cln != FAT_FILE_SHORT_NAME)             
                {                                                     
                    ret = fat_file_ioctl(&fs_info->fat, fat_fd, F_CLU_NUM,
40019188:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001918c:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== 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)                 
40019190:	c2 07 bf 90 	ld  [ %fp + -112 ], %g1                        
40019194:	80 a0 7f ff 	cmp  %g1, -1                                   
40019198:	32 80 00 06 	bne,a   400191b0 <msdos_find_name_in_fat_file+0x548>
4001919c:	c6 27 bf 20 	st  %g3, [ %fp + -224 ]                        
            {                                                         
                lfn_start.cln = empty_space_offset;                   
400191a0:	c2 07 bf 5c 	ld  [ %fp + -164 ], %g1                        
                lfn_start.ofs = dir_entry;                            
400191a4:	ee 27 bf 94 	st  %l7, [ %fp + -108 ]                        
             * first entry written and if so remember the             
             * the location of the long file name.                    
             */                                                       
            if (lfn_start.cln == FAT_FILE_SHORT_NAME)                 
            {                                                         
                lfn_start.cln = empty_space_offset;                   
400191a8:	c2 27 bf 90 	st  %g1, [ %fp + -112 ]                        
            }                                                         
                                                                      
            /*                                                        
             * Clear the entry before loading the data.               
             */                                                       
            memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);     
400191ac:	c6 27 bf 20 	st  %g3, [ %fp + -224 ]                        
400191b0:	c8 27 bf 1c 	st  %g4, [ %fp + -228 ]                        
400191b4:	da 27 bf 18 	st  %o5, [ %fp + -232 ]                        
400191b8:	90 10 00 15 	mov  %l5, %o0                                  
400191bc:	92 10 20 00 	clr  %o1                                       
400191c0:	40 00 0f 47 	call  4001cedc <memset>                        
400191c4:	94 10 20 20 	mov  0x20, %o2                                 
                                                                      
            *MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;            
400191c8:	e2 2d 60 0d 	stb  %l1, [ %l5 + 0xd ]                        
400191cc:	c6 07 bf 20 	ld  [ %fp + -224 ], %g3                        
400191d0:	da 07 bf 18 	ld  [ %fp + -232 ], %o5                        
        {                                                             
            char*       entry = (char*) fs_info->cl_buf + dir_entry;  
            char*       p;                                            
            const char* n;                                            
            int         i;                                            
            char        fill = 0;                                     
400191d4:	c8 07 bf 1c 	ld  [ %fp + -228 ], %g4                        
             */                                                       
            memset (entry, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);     
                                                                      
            *MSDOS_DIR_LFN_CHECKSUM(entry) = lfn_checksum;            
                                                                      
            p = entry + 1;                                            
400191d8:	82 05 60 01 	add  %l5, 1, %g1                               
400191dc:	9e 03 40 03 	add  %o5, %g3, %o7                             
            n = name_converted + (fat_entries - lfn_entry) * MSDOS_LFN_ENTRY_SIZE;
                                                                      
#if MSDOS_FIND_PRINT                                                  
            printf ("MSFS:[11] ");                                    
#endif                                                                
            for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; ++i)             
400191e0:	98 10 20 00 	clr  %o4                                       
        {                                                             
            char*       entry = (char*) fs_info->cl_buf + dir_entry;  
            char*       p;                                            
            const char* n;                                            
            int         i;                                            
            char        fill = 0;                                     
400191e4:	96 10 20 00 	clr  %o3                                       
#if MSDOS_FIND_PRINT                                                  
            printf ("MSFS:[11] ");                                    
#endif                                                                
            for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; ++i)             
            {                                                         
                if (!(*n == 0 && *(n+1) == 0))                        
400191e8:	d2 4b c0 00 	ldsb  [ %o7 ], %o1                             
400191ec:	80 a2 60 00 	cmp  %o1, 0                                    
400191f0:	12 80 00 06 	bne  40019208 <msdos_find_name_in_fat_file+0x5a0>
400191f4:	d4 0b c0 00 	ldub  [ %o7 ], %o2                             
400191f8:	d2 4b e0 01 	ldsb  [ %o7 + 1 ], %o1                         
400191fc:	80 a2 60 00 	cmp  %o1, 0                                    
40019200:	22 80 00 06 	be,a   40019218 <msdos_find_name_in_fat_file+0x5b0>
40019204:	d6 28 40 00 	stb  %o3, [ %g1 ]                              
                {                                                     
                    *p = *n;                                          
40019208:	d4 28 40 00 	stb  %o2, [ %g1 ]                              
                    *(p+1) = *(n+1);                                  
4001920c:	d4 0b e0 01 	ldub  [ %o7 + 1 ], %o2                         
40019210:	10 80 00 04 	b  40019220 <msdos_find_name_in_fat_file+0x5b8>
40019214:	d4 28 60 01 	stb  %o2, [ %g1 + 1 ]                          
                }                                                     
                else                                                  
                {                                                     
                    p [0] = fill;                                     
                    p [1] = fill;                                     
40019218:	d6 28 60 01 	stb  %o3, [ %g1 + 1 ]                          
                    fill = 0xff;                                      
4001921c:	96 10 3f ff 	mov  -1, %o3                                   
                n += MSDOS_NAME_LFN_BYTES_PER_CHAR;                   
#if MSDOS_FIND_PRINT                                                  
                printf ( "'%c''%c'", *p, *(p+1) );                    
#endif                                                                
                                                                      
                switch (i)                                            
40019220:	80 a3 20 04 	cmp  %o4, 4                                    
40019224:	02 80 00 07 	be  40019240 <msdos_find_name_in_fat_file+0x5d8>
40019228:	9e 03 e0 02 	add  %o7, 2, %o7                               
4001922c:	80 a3 20 0a 	cmp  %o4, 0xa                                  
40019230:	32 80 00 05 	bne,a   40019244 <msdos_find_name_in_fat_file+0x5dc>
40019234:	82 00 60 02 	add  %g1, 2, %g1                               
                {                                                     
                    case 4:                                           
                        p += 5;                                       
                        break;                                        
                    case 10:                                          
                        p += 4;                                       
40019238:	10 80 00 03 	b  40019244 <msdos_find_name_in_fat_file+0x5dc>
4001923c:	82 00 60 04 	add  %g1, 4, %g1                               
40019240:	82 00 60 05 	add  %g1, 5, %g1                               
            n = name_converted + (fat_entries - lfn_entry) * MSDOS_LFN_ENTRY_SIZE;
                                                                      
#if MSDOS_FIND_PRINT                                                  
            printf ("MSFS:[11] ");                                    
#endif                                                                
            for (i = 0; i < MSDOS_LFN_LEN_PER_ENTRY; ++i)             
40019244:	98 03 20 01 	inc  %o4                                       
40019248:	80 a3 20 0d 	cmp  %o4, 0xd                                  
4001924c:	32 bf ff e8 	bne,a   400191ec <msdos_find_name_in_fat_file+0x584>
40019250:	d2 4b c0 00 	ldsb  [ %o7 ], %o1                             
40019254:	82 24 00 16 	sub  %l0, %l6, %g1                             
            }                                                         
#if MSDOS_FIND_PRINT                                                  
            printf ( "\n" );                                          
#endif                                                                
            *MSDOS_DIR_ENTRY_TYPE(entry) = (fat_entries - lfn_entry) + 1;
            if (lfn_entry == 1)                                       
40019258:	80 a5 a0 01 	cmp  %l6, 1                                    
4001925c:	12 80 00 04 	bne  4001926c <msdos_find_name_in_fat_file+0x604>
40019260:	c2 29 00 17 	stb  %g1, [ %g4 + %l7 ]                        
                *MSDOS_DIR_ENTRY_TYPE(entry) |= MSDOS_LAST_LONG_ENTRY;
40019264:	82 10 60 40 	or  %g1, 0x40, %g1                             
40019268:	c2 29 00 17 	stb  %g1, [ %g4 + %l7 ]                        
            *MSDOS_DIR_ATTR(entry) |= MSDOS_ATTR_LFN;                 
4001926c:	c2 0d 60 0b 	ldub  [ %l5 + 0xb ], %g1                       
40019270:	ac 05 a0 01 	inc  %l6                                       
40019274:	82 10 60 0f 	or  %g1, 0xf, %g1                              
40019278:	86 00 ff e6 	add  %g3, -26, %g3                             
4001927c:	10 bf ff 96 	b  400190d4 <msdos_find_name_in_fat_file+0x46c>
40019280:	c2 2d 60 0b 	stb  %g1, [ %l5 + 0xb ]                        
        }                                                             
                                                                      
        bytes_written = fat_file_write(&fs_info->fat, fat_fd,         
40019284:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
40019288:	90 10 00 1d 	mov  %i5, %o0                                  
4001928c:	92 10 00 19 	mov  %i1, %o1                                  
40019290:	94 07 00 12 	add  %i4, %l2, %o2                             
40019294:	96 10 00 14 	mov  %l4, %o3                                  
40019298:	7f ff e6 0d 	call  40012acc <fat_file_write>                
4001929c:	98 03 00 12 	add  %o4, %l2, %o4                             
                                       (empty_space_offset * bts2rd) + empty_space_entry,
                                       length, fs_info->cl_buf + empty_space_entry);
        if (bytes_written == -1)                                      
400192a0:	80 a2 3f ff 	cmp  %o0, -1                                   
400192a4:	02 80 00 12 	be  400192ec <msdos_find_name_in_fat_file+0x684><== NEVER TAKEN
400192a8:	80 a2 00 14 	cmp  %o0, %l4                                  
            return -1;                                                
        else if (bytes_written != length)                             
400192ac:	02 80 00 08 	be  400192cc <msdos_find_name_in_fat_file+0x664><== ALWAYS TAKEN
400192b0:	b8 07 00 1b 	add  %i4, %i3, %i4                             
            rtems_set_errno_and_return_minus_one(EIO);                
400192b4:	40 00 0c 76 	call  4001c48c <__errno>                       <== NOT EXECUTED
400192b8:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400192bc:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
400192c0:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
400192c4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400192c8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
        empty_space_offset++;                                         
400192cc:	c4 07 bf 5c 	ld  [ %fp + -164 ], %g2                        
        empty_space_entry = 0;                                        
400192d0:	a4 10 20 00 	clr  %l2                                       
        if (bytes_written == -1)                                      
            return -1;                                                
        else if (bytes_written != length)                             
            rtems_set_errno_and_return_minus_one(EIO);                
                                                                      
        empty_space_offset++;                                         
400192d4:	84 00 a0 01 	inc  %g2                                       
        empty_space_entry = 0;                                        
        read_cluster = true;                                          
400192d8:	a8 10 20 01 	mov  1, %l4                                    
        if (bytes_written == -1)                                      
            return -1;                                                
        else if (bytes_written != length)                             
            rtems_set_errno_and_return_minus_one(EIO);                
                                                                      
        empty_space_offset++;                                         
400192dc:	10 bf ff 49 	b  40019000 <msdos_find_name_in_fat_file+0x398>
400192e0:	c4 27 bf 5c 	st  %g2, [ %fp + -164 ]                        
                                                                      
                dir_pos->sname.ofs = dir_entry;                       
                                                                      
                if (lfn_start.cln != FAT_FILE_SHORT_NAME)             
                {                                                     
                    ret = fat_file_ioctl(&fs_info->fat, fat_fd, F_CLU_NUM,
400192e4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400192e8:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      
        bytes_written = fat_file_write(&fs_info->fat, fat_fd,         
                                       (empty_space_offset * bts2rd) + empty_space_entry,
                                       length, fs_info->cl_buf + empty_space_entry);
        if (bytes_written == -1)                                      
            return -1;                                                
400192ec:	81 c7 e0 08 	ret                                            
400192f0:	91 e8 3f ff 	restore  %g0, -1, %o0                          
     * 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.                     
     */                                                               
                                                                      
    lfn_start.cln = lfn_start.ofs = FAT_FILE_SHORT_NAME;              
400192f4:	82 10 3f ff 	mov  -1, %g1                                   
    uint32_t          dir_entry;                                      
    fat_pos_t         lfn_start;                                      
    uint8_t           lfn_checksum      = 0;                          
    bool              entry_matched       = false;                    
    bool              empty_space_found = false;                      
    uint32_t          entries_per_block = bts2rd / MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
400192f8:	87 36 e0 05 	srl  %i3, 5, %g3                               
400192fc:	c4 07 a0 4c 	ld  [ %fp + 0x4c ], %g2                        
40019300:	c6 27 bf 30 	st  %g3, [ %fp + -208 ]                        
     * 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.                     
     */                                                               
                                                                      
    lfn_start.cln = lfn_start.ofs = FAT_FILE_SHORT_NAME;              
40019304:	c2 27 bf 6c 	st  %g1, [ %fp + -148 ]                        
40019308:	c2 27 bf 68 	st  %g1, [ %fp + -152 ]                        
    int               lfn_entry         = 0;                          
    uint8_t           entry_utf8_normalized[MSDOS_LFN_ENTRY_SIZE_UTF8];
    size_t            bytes_in_entry;                                 
    bool              filename_matched  = false;                      
    ssize_t           filename_size_remaining = name_len_for_compare; 
    rtems_dosfs_convert_control *converter = fs_info->converter;      
4001930c:	f8 07 60 a4 	ld  [ %i5 + 0xa4 ], %i4                        
40019310:	03 00 00 1f 	sethi  %hi(0x7c00), %g1                        
40019314:	82 10 61 01 	or  %g1, 0x101, %g1	! 7d01 <_TLS_Alignment+0x7d00>
40019318:	c2 27 bf 44 	st  %g1, [ %fp + -188 ]                        
4001931c:	c6 07 bf 44 	ld  [ %fp + -188 ], %g3                        
40019320:	80 a0 00 02 	cmp  %g0, %g2                                  
40019324:	82 40 3f ff 	addx  %g0, -1, %g1                             
    int               rc                = RC_OK;                      
    ssize_t           bytes_read;                                     
    uint32_t          dir_entry;                                      
    fat_pos_t         lfn_start;                                      
    uint8_t           lfn_checksum      = 0;                          
    bool              entry_matched       = false;                    
40019328:	c0 2f bf 63 	clrb  [ %fp + -157 ]                           
4001932c:	86 08 c0 01 	and  %g3, %g1, %g3                             
                 * 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                             
                    && rc == RC_OK )                                  
40019330:	ac 10 00 15 	mov  %l5, %l6                                  
                    /*                                                
                     * Remainder is not empty so is this entry empty ?
                     */                                               
                    (*empty_space_count)++;                           
                                                                      
                    if (*empty_space_count == (fat_entries + 1))      
40019334:	82 04 20 01 	add  %l0, 1, %g1                               
                 * 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                             
40019338:	80 a0 00 03 	cmp  %g0, %g3                                  
4001933c:	c6 27 bf 44 	st  %g3, [ %fp + -188 ]                        
40019340:	84 60 3f ff 	subx  %g0, -1, %g2                             
                    && rc == RC_OK )                                  
40019344:	c0 27 bf 34 	clr  [ %fp + -204 ]                            
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
    uint32_t                           dir_offset                 = 0;
40019348:	a8 10 20 00 	clr  %l4                                       
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
    uint32_t                           empty_space_count          = 0;
4001934c:	a6 10 20 00 	clr  %l3                                       
    msdos_fs_info_t                   *fs_info                    = mt_entry->fs_info;
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
    uint32_t                           empty_space_entry          = 0;
40019350:	a4 10 20 00 	clr  %l2                                       
    int                                retval                     = 0;
    msdos_fs_info_t                   *fs_info                    = mt_entry->fs_info;
    ssize_t                            name_len_for_save;             
    ssize_t                            name_len_for_compare;          
    uint32_t                           bts2rd                     = 0;
    uint32_t                           empty_space_offset         = 0;
40019354:	c0 27 bf 5c 	clr  [ %fp + -164 ]                            
    fat_pos_t         lfn_start;                                      
    uint8_t           lfn_checksum      = 0;                          
    bool              entry_matched       = false;                    
    bool              empty_space_found = false;                      
    uint32_t          entries_per_block = bts2rd / MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;
    int               lfn_entry         = 0;                          
40019358:	c0 27 bf 50 	clr  [ %fp + -176 ]                            
    ssize_t           bytes_read;                                     
    uint32_t          dir_entry;                                      
    fat_pos_t         lfn_start;                                      
    uint8_t           lfn_checksum      = 0;                          
    bool              entry_matched       = false;                    
    bool              empty_space_found = false;                      
4001935c:	c0 2f bf 4f 	clrb  [ %fp + -177 ]                           
{                                                                     
    int               rc                = RC_OK;                      
    ssize_t           bytes_read;                                     
    uint32_t          dir_entry;                                      
    fat_pos_t         lfn_start;                                      
    uint8_t           lfn_checksum      = 0;                          
40019360:	c0 2f bf 3f 	clrb  [ %fp + -193 ]                           
    uint32_t                             *dir_offset,                 
    uint32_t                             *empty_space_offset,         
    uint32_t                             *empty_space_entry,          
    uint32_t                             *empty_space_count)          
{                                                                     
    int               rc                = RC_OK;                      
40019364:	b0 10 20 00 	clr  %i0                                       
                    /*                                                
                     * Remainder is not empty so is this entry empty ?
                     */                                               
                    (*empty_space_count)++;                           
                                                                      
                    if (*empty_space_count == (fat_entries + 1))      
40019368:	c2 27 bf 2c 	st  %g1, [ %fp + -212 ]                        
                 * 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                             
4001936c:	c4 27 bf 28 	st  %g2, [ %fp + -216 ]                        
     * create the entry if the name is not found.                     
     */                                                               
                                                                      
    lfn_start.cln = lfn_start.ofs = FAT_FILE_SHORT_NAME;              
                                                                      
    while (   (bytes_read = fat_file_read (&fs_info->fat, fat_fd, (*dir_offset * bts2rd),
40019370:	d4 07 bf 34 	ld  [ %fp + -204 ], %o2                        
40019374:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
40019378:	90 10 00 1d 	mov  %i5, %o0                                  
4001937c:	92 10 00 19 	mov  %i1, %o1                                  
40019380:	7f ff e4 30 	call  40012440 <fat_file_read>                 
40019384:	96 10 00 1b 	mov  %i3, %o3                                  
40019388:	80 a2 20 00 	cmp  %o0, 0                                    
4001938c:	02 80 01 23 	be  40019818 <msdos_find_name_in_fat_file+0xbb0>
40019390:	80 a6 20 00 	cmp  %i0, 0                                    
                                             bts2rd, fs_info->cl_buf)) != FAT_EOF
           && rc == RC_OK)                                            
40019394:	12 80 01 21 	bne  40019818 <msdos_find_name_in_fat_file+0xbb0><== NEVER TAKEN
40019398:	80 a2 20 1f 	cmp  %o0, 0x1f                                 
        bool remainder_empty = false;                                 
#if MSDOS_FIND_PRINT                                                  
        printf ("MSFS:[2] dir_offset:%li\n", *dir_offset);            
#endif                                                                
                                                                      
        if (bytes_read < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)           
4001939c:	14 80 00 07 	bg  400193b8 <msdos_find_name_in_fat_file+0x750><== ALWAYS TAKEN
400193a0:	80 a2 00 1b 	cmp  %o0, %i3                                  
            rtems_set_errno_and_return_minus_one(EIO);                
400193a4:	40 00 0c 3a 	call  4001c48c <__errno>                       <== NOT EXECUTED
400193a8:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400193ac:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
400193b0:	10 bf fe 93 	b  40018dfc <msdos_find_name_in_fat_file+0x194><== NOT EXECUTED
400193b4:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
                                                                      
        assert(bytes_read == bts2rd);                                 
400193b8:	12 bf fe 83 	bne  40018dc4 <msdos_find_name_in_fat_file+0x15c><== NEVER TAKEN
400193bc:	90 10 20 00 	clr  %o0                                       
400193c0:	c0 2f bf 57 	clrb  [ %fp + -169 ]                           
400193c4:	10 80 00 17 	b  40019420 <msdos_find_name_in_fat_file+0x7b8>
400193c8:	a2 10 20 00 	clr  %l1                                       
                                                                      
        /* have to look at the DIR_NAME as "raw" 8-bit data */        
        for (dir_entry = 0;                                           
400193cc:	1a 80 01 03 	bcc  400197d8 <msdos_find_name_in_fat_file+0xb70>
400193d0:	c6 0f bf 57 	ldub  [ %fp + -169 ], %g3                      
             dir_entry < bts2rd && rc == RC_OK && (! filename_matched);
400193d4:	80 88 e0 ff 	btst  0xff, %g3                                
400193d8:	12 80 01 01 	bne  400197dc <msdos_find_name_in_fat_file+0xb74>
400193dc:	80 a4 e0 00 	cmp  %l3, 0                                    
             dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)          
        {                                                             
            char* entry = (char*) fs_info->cl_buf + dir_entry;        
400193e0:	c4 07 60 a0 	ld  [ %i5 + 0xa0 ], %g2                        
400193e4:	82 00 80 11 	add  %g2, %l1, %g1                             
             * 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)                              
400193e8:	12 80 00 04 	bne  400193f8 <msdos_find_name_in_fat_file+0x790>
400193ec:	c4 08 80 11 	ldub  [ %g2 + %l1 ], %g2                       
400193f0:	a4 10 00 11 	mov  %l1, %l2                                  
400193f4:	e8 27 bf 5c 	st  %l4, [ %fp + -164 ]                        
            {                                                         
                *empty_space_entry = dir_entry;                       
                *empty_space_offset = *dir_offset;                    
            }                                                         
                                                                      
            if (remainder_empty)                                      
400193f8:	84 88 a0 ff 	andcc  %g2, 0xff, %g2                          
400193fc:	02 80 00 0e 	be  40019434 <msdos_find_name_in_fat_file+0x7cc>
40019400:	80 a0 a0 e5 	cmp  %g2, 0xe5                                 
                    printf ( "MSFS:[3.2] esf:%i esc%"PRIu32"\n", empty_space_found, *empty_space_count );
#endif                                                                
                }                                                     
                break;                                                
            }                                                         
            else if (entry_empty)                                     
40019404:	12 80 00 24 	bne  40019494 <msdos_find_name_in_fat_file+0x82c>
40019408:	c6 0f bf 4f 	ldub  [ %fp + -177 ], %g3                      
            {                                                         
                if (create_node)                                      
4001940c:	c2 07 a0 4c 	ld  [ %fp + 0x4c ], %g1                        
40019410:	80 a0 60 00 	cmp  %g1, 0                                    
40019414:	12 80 00 18 	bne  40019474 <msdos_find_name_in_fat_file+0x80c>
40019418:	90 10 20 00 	clr  %o0                                       
        assert(bytes_read == bts2rd);                                 
                                                                      
        /* have to look at the DIR_NAME as "raw" 8-bit data */        
        for (dir_entry = 0;                                           
             dir_entry < bts2rd && rc == RC_OK && (! filename_matched);
             dir_entry += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)          
4001941c:	a2 04 60 20 	add  %l1, 0x20, %l1                            
            rtems_set_errno_and_return_minus_one(EIO);                
                                                                      
        assert(bytes_read == bts2rd);                                 
                                                                      
        /* have to look at the DIR_NAME as "raw" 8-bit data */        
        for (dir_entry = 0;                                           
40019420:	80 a2 20 00 	cmp  %o0, 0                                    
40019424:	02 bf ff ea 	be  400193cc <msdos_find_name_in_fat_file+0x764><== ALWAYS TAKEN
40019428:	80 a4 40 1b 	cmp  %l1, %i3                                  
4001942c:	10 80 00 ec 	b  400197dc <msdos_find_name_in_fat_file+0xb74><== NOT EXECUTED
40019430:	b0 10 00 08 	mov  %o0, %i0                                  <== 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                             
40019434:	c6 0f bf 4f 	ldub  [ %fp + -177 ], %g3                      
40019438:	80 88 e0 ff 	btst  0xff, %g3                                
4001943c:	32 80 00 e5 	bne,a   400197d0 <msdos_find_name_in_fat_file+0xb68>
40019440:	f0 07 bf 44 	ld  [ %fp + -188 ], %i0                        
40019444:	c2 07 bf 28 	ld  [ %fp + -216 ], %g1                        
40019448:	80 a0 60 00 	cmp  %g1, 0                                    
4001944c:	22 80 00 e1 	be,a   400197d0 <msdos_find_name_in_fat_file+0xb68>
40019450:	f0 07 bf 44 	ld  [ %fp + -188 ], %i0                        
                    && rc == RC_OK )                                  
                {                                                     
                    *empty_space_count +=                             
                    entries_per_block - (dir_entry / MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
40019454:	c4 07 bf 30 	ld  [ %fp + -208 ], %g2                        
40019458:	a3 34 60 05 	srl  %l1, 5, %l1                               
4001945c:	a6 04 c0 02 	add  %l3, %g2, %l3                             
                    empty_space_found = true;                         
40019460:	86 10 20 01 	mov  1, %g3                                    
                 * are needed FAT_EOF is returned by the read and we extend the file.
                 */                                                   
                if (   !empty_space_found                             
                    && rc == RC_OK )                                  
                {                                                     
                    *empty_space_count +=                             
40019464:	a6 24 c0 11 	sub  %l3, %l1, %l3                             
             * See if the entry is empty or the remainder of the directory is
             * empty ? Localize to make the code read better.         
             */                                                       
            bool entry_empty = (*MSDOS_DIR_ENTRY_TYPE(entry) ==       
                                MSDOS_THIS_DIR_ENTRY_EMPTY);          
            remainder_empty = (*MSDOS_DIR_ENTRY_TYPE(entry) ==        
40019468:	82 10 20 01 	mov  1, %g1                                    
                if (   !empty_space_found                             
                    && rc == RC_OK )                                  
                {                                                     
                    *empty_space_count +=                             
                    entries_per_block - (dir_entry / MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);
                    empty_space_found = true;                         
4001946c:	10 80 00 dd 	b  400197e0 <msdos_find_name_in_fat_file+0xb78>
40019470:	c6 2f bf 4f 	stb  %g3, [ %fp + -177 ]                       
                    /*                                                
                     * Remainder is not empty so is this entry empty ?
                     */                                               
                    (*empty_space_count)++;                           
                                                                      
                    if (*empty_space_count == (fat_entries + 1))      
40019474:	c4 07 bf 2c 	ld  [ %fp + -212 ], %g2                        
                if (create_node)                                      
                {                                                     
                    /*                                                
                     * Remainder is not empty so is this entry empty ?
                     */                                               
                    (*empty_space_count)++;                           
40019478:	a6 04 e0 01 	inc  %l3                                       
                                                                      
                    if (*empty_space_count == (fat_entries + 1))      
4001947c:	80 a4 c0 02 	cmp  %l3, %g2                                  
40019480:	32 bf ff e8 	bne,a   40019420 <msdos_find_name_in_fat_file+0x7b8>
40019484:	a2 04 60 20 	add  %l1, 0x20, %l1                            
                        empty_space_found = true;                     
40019488:	84 10 20 01 	mov  1, %g2                                    
4001948c:	10 bf ff e4 	b  4001941c <msdos_find_name_in_fat_file+0x7b4>
40019490:	c4 2f bf 4f 	stb  %g2, [ %fp + -177 ]                       
                 * 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)                
40019494:	84 18 e0 01 	xor  %g3, 1, %g2                               
40019498:	80 88 a0 ff 	btst  0xff, %g2                                
4001949c:	22 80 00 08 	be,a   400194bc <msdos_find_name_in_fat_file+0x854><== NEVER TAKEN
400194a0:	c4 08 60 0b 	ldub  [ %g1 + 0xb ], %g2                       <== NOT EXECUTED
400194a4:	c4 07 a0 4c 	ld  [ %fp + 0x4c ], %g2                        
400194a8:	80 a0 a0 00 	cmp  %g2, 0                                    
400194ac:	02 80 00 04 	be  400194bc <msdos_find_name_in_fat_file+0x854>
400194b0:	c4 08 60 0b 	ldub  [ %g1 + 0xb ], %g2                       
                {                                                     
                    *empty_space_entry = 0;                           
                    *empty_space_count = 0;                           
400194b4:	a6 10 20 00 	clr  %l3                                       
                 * If empty space has not been found we need to start the
                 * count again.                                       
                 */                                                   
                if (create_node && !empty_space_found)                
                {                                                     
                    *empty_space_entry = 0;                           
400194b8:	a4 10 20 00 	clr  %l2                                       
                                                                      
                /*                                                    
                 * Check the attribute to see if the entry is for a long
                 * file name.                                         
                 */                                                   
                if ((*MSDOS_DIR_ATTR(entry) & MSDOS_ATTR_LFN_MASK) == 
400194bc:	84 08 a0 3f 	and  %g2, 0x3f, %g2                            
400194c0:	80 a0 a0 0f 	cmp  %g2, 0xf                                  
400194c4:	12 80 00 4d 	bne  400195f8 <msdos_find_name_in_fat_file+0x990>
400194c8:	c4 0f bf 63 	ldub  [ %fp + -157 ], %g2                      
#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)         
400194cc:	c6 07 bf 68 	ld  [ %fp + -152 ], %g3                        
400194d0:	80 a0 ff ff 	cmp  %g3, -1                                   
400194d4:	12 80 00 10 	bne  40019514 <msdos_find_name_in_fat_file+0x8ac>
400194d8:	c4 07 bf 50 	ld  [ %fp + -176 ], %g2                        
                    {                                                 
                        entry_matched = false;                        
400194dc:	c0 2f bf 63 	clrb  [ %fp + -157 ]                           
                                                                      
                        /*                                            
                         * The first entry must have the last long entry
                         * flag set.                                  
                         */                                           
                        if ((*MSDOS_DIR_ENTRY_TYPE(entry) &           
400194e0:	c4 08 40 00 	ldub  [ %g1 ], %g2                             
400194e4:	80 88 a0 40 	btst  0x40, %g2                                
400194e8:	02 bf ff cd 	be  4001941c <msdos_find_name_in_fat_file+0x7b4>
400194ec:	90 10 20 00 	clr  %o0                                       
                         * 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 (fat_entries != (*MSDOS_DIR_ENTRY_TYPE(entry) &
400194f0:	84 08 a0 3f 	and  %g2, 0x3f, %g2                            
400194f4:	80 a4 00 02 	cmp  %l0, %g2                                  
400194f8:	32 bf ff ca 	bne,a   40019420 <msdos_find_name_in_fat_file+0x7b8>
400194fc:	a2 04 60 20 	add  %l1, 0x20, %l1                            
                         * Get the checksum of the short entry.       
                         */                                           
                        lfn_start.cln = *dir_offset;                  
                        lfn_start.ofs = dir_entry;                    
                        lfn_entry = fat_entries;                      
                        lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);
40019500:	c6 08 60 0d 	ldub  [ %g1 + 0xd ], %g3                       
                            continue;                                 
                                                                      
                        /*                                            
                         * Get the checksum of the short entry.       
                         */                                           
                        lfn_start.cln = *dir_offset;                  
40019504:	e8 27 bf 68 	st  %l4, [ %fp + -152 ]                        
                        lfn_start.ofs = dir_entry;                    
40019508:	e2 27 bf 6c 	st  %l1, [ %fp + -148 ]                        
                        lfn_entry = fat_entries;                      
4001950c:	84 10 00 10 	mov  %l0, %g2                                  
                        lfn_checksum = *MSDOS_DIR_LFN_CHECKSUM(entry);
40019510:	c6 2f bf 3f 	stb  %g3, [ %fp + -193 ]                       
                     * 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) & 
40019514:	c6 08 40 00 	ldub  [ %g1 ], %g3                             
40019518:	86 08 e0 3f 	and  %g3, 0x3f, %g3                            
4001951c:	80 a0 80 03 	cmp  %g2, %g3                                  
40019520:	32 80 00 08 	bne,a   40019540 <msdos_find_name_in_fat_file+0x8d8><== NEVER TAKEN
40019524:	82 10 3f ff 	mov  -1, %g1                                   <== NOT EXECUTED
                                       MSDOS_LAST_LONG_ENTRY_MASK)) ||
40019528:	c8 0f bf 3f 	ldub  [ %fp + -193 ], %g4                      
4001952c:	c6 08 60 0d 	ldub  [ %g1 + 0xd ], %g3                       
40019530:	80 a1 00 03 	cmp  %g4, %g3                                  
40019534:	02 80 00 06 	be  4001954c <msdos_find_name_in_fat_file+0x8e4><== ALWAYS TAKEN
40019538:	86 00 bf ff 	add  %g2, -1, %g3                              
                        (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;          
4001953c:	82 10 3f ff 	mov  -1, %g1                                   <== NOT EXECUTED
40019540:	c4 27 bf 50 	st  %g2, [ %fp + -176 ]                        <== NOT EXECUTED
40019544:	10 80 00 a1 	b  400197c8 <msdos_find_name_in_fat_file+0xb60><== NOT EXECUTED
40019548:	c2 27 bf 68 	st  %g1, [ %fp + -152 ]                        <== NOT EXECUTED
    int          eno            = 0;                                  
    size_t       bytes_in_utf8  = buf_size;                           
    size_t       bytes_in_buf;                                        
    uint16_t     entry_string[MSDOS_LFN_LEN_PER_ENTRY];               
                                                                      
    retval = msdos_get_utf16_string_from_long_entry (                 
4001954c:	94 10 20 1a 	mov  0x1a, %o2                                 
                        continue;                                     
                    }                                                 
#if MSDOS_FIND_PRINT                                                  
                    printf ("MSFS:[5] lfne:%i\n", lfn_entry);         
#endif                                                                
                    lfn_entry--;                                      
40019550:	c6 27 bf 50 	st  %g3, [ %fp + -176 ]                        
                                                                      
                    bytes_in_entry = msdos_long_entry_to_utf8_name (  
40019554:	84 18 80 10 	xor  %g2, %l0, %g2                             
    uint8_t                     *entry_utf8_buf,                      
    const size_t                 buf_size)                            
{                                                                     
    ssize_t      retval         = 0;                                  
    int          eno            = 0;                                  
    size_t       bytes_in_utf8  = buf_size;                           
40019558:	86 10 20 70 	mov  0x70, %g3                                 
    size_t       bytes_in_buf;                                        
    uint16_t     entry_string[MSDOS_LFN_LEN_PER_ENTRY];               
                                                                      
    retval = msdos_get_utf16_string_from_long_entry (                 
4001955c:	80 a0 00 02 	cmp  %g0, %g2                                  
    uint8_t                     *entry_utf8_buf,                      
    const size_t                 buf_size)                            
{                                                                     
    ssize_t      retval         = 0;                                  
    int          eno            = 0;                                  
    size_t       bytes_in_utf8  = buf_size;                           
40019560:	c6 27 bf 64 	st  %g3, [ %fp + -156 ]                        
    size_t       bytes_in_buf;                                        
    uint16_t     entry_string[MSDOS_LFN_LEN_PER_ENTRY];               
                                                                      
    retval = msdos_get_utf16_string_from_long_entry (                 
40019564:	96 60 3f ff 	subx  %g0, -1, %o3                             
40019568:	90 10 00 01 	mov  %g1, %o0                                  
4001956c:	7f ff fd 59 	call  40018ad0 <msdos_get_utf16_string_from_long_entry>
40019570:	92 07 bf 70 	add  %fp, -144, %o1                            
        entry_string,                                                 
        sizeof (entry_string),                                        
        is_first_entry                                                
    );                                                                
                                                                      
    if (retval >= 0) {                                                
40019574:	94 92 20 00 	orcc  %o0, 0, %o2                              
40019578:	06 80 00 0c 	bl  400195a8 <msdos_find_name_in_fat_file+0x940><== NEVER TAKEN
4001957c:	90 10 00 1c 	mov  %i4, %o0                                  
        bytes_in_buf = retval;                                        
        eno = (*converter->handler->utf16_to_utf8) (                  
40019580:	c2 07 00 00 	ld  [ %i4 ], %g1                               
40019584:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
40019588:	92 07 bf 70 	add  %fp, -144, %o1                            
4001958c:	96 07 bf 90 	add  %fp, -112, %o3                            
40019590:	9f c0 40 00 	call  %g1                                      
40019594:	98 07 bf 64 	add  %fp, -156, %o4                            
            converter,                                                
            &entry_string[0],                                         
            bytes_in_buf,                                             
            &entry_utf8_buf[0],                                       
            &bytes_in_utf8);                                          
        if ( eno == 0 ) {                                             
40019598:	82 92 20 00 	orcc  %o0, 0, %g1                              
4001959c:	12 80 00 a6 	bne  40019834 <msdos_find_name_in_fat_file+0xbcc>
400195a0:	01 00 00 00 	nop                                            
            retval = bytes_in_utf8;                                   
400195a4:	d4 07 bf 64 	ld  [ %fp + -156 ], %o2                        
                        converter,                                    
                        entry,                                        
                        (lfn_entry + 1) == fat_entries,               
                        &entry_utf8_normalized[0],                    
                        sizeof (entry_utf8_normalized));              
                    if (bytes_in_entry > 0) {                         
400195a8:	80 a2 a0 00 	cmp  %o2, 0                                    
400195ac:	02 80 00 11 	be  400195f0 <msdos_find_name_in_fat_file+0x988><== NEVER TAKEN
400195b0:	84 10 3f ff 	mov  -1, %g2                                   
                        filename_size_remaining = msdos_compare_entry_against_filename (
400195b4:	98 10 00 16 	mov  %l6, %o4                                  
400195b8:	90 10 00 1c 	mov  %i4, %o0                                  
400195bc:	92 07 bf 90 	add  %fp, -112, %o1                            
400195c0:	96 10 00 17 	mov  %l7, %o3                                  
400195c4:	7f ff fb 46 	call  400182dc <msdos_compare_entry_against_filename>
400195c8:	9a 07 bf 63 	add  %fp, -157, %o5                            
                            bytes_in_entry,                           
                            &filename_converted[0],                   
                            filename_size_remaining,                  
                            &entry_matched);                          
                                                                      
                        if (filename_size_remaining < 0               
400195cc:	ac 92 20 00 	orcc  %o0, 0, %l6                              
400195d0:	06 80 00 05 	bl  400195e4 <msdos_find_name_in_fat_file+0x97c><== NEVER TAKEN
400195d4:	c2 0f bf 63 	ldub  [ %fp + -157 ], %g1                      
                            || (! entry_matched)) {                   
400195d8:	80 a0 60 00 	cmp  %g1, 0                                    
400195dc:	12 bf ff 90 	bne  4001941c <msdos_find_name_in_fat_file+0x7b4>
400195e0:	90 10 20 00 	clr  %o0                                       
                            filename_size_remaining = name_len_for_compare;
                            lfn_start.cln = FAT_FILE_SHORT_NAME;      
400195e4:	82 10 3f ff 	mov  -1, %g1                                   
400195e8:	10 80 00 77 	b  400197c4 <msdos_find_name_in_fat_file+0xb5c>
400195ec:	c2 27 bf 68 	st  %g1, [ %fp + -152 ]                        
                        }                                             
                    } else {                                          
                      lfn_start.cln = FAT_FILE_SHORT_NAME;            
400195f0:	10 80 00 1c 	b  40019660 <msdos_find_name_in_fat_file+0x9f8><== NOT EXECUTED
400195f4:	c4 27 bf 68 	st  %g2, [ %fp + -152 ]                        <== 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 (entry_matched)                                
400195f8:	80 a0 a0 00 	cmp  %g2, 0                                    
400195fc:	02 80 00 29 	be  400196a0 <msdos_find_name_in_fat_file+0xa38>
40019600:	86 10 20 00 	clr  %g3                                       
40019604:	84 10 20 00 	clr  %g2                                       
                        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;
40019608:	de 08 40 03 	ldub  [ %g1 + %g3 ], %o7                       
4001960c:	88 08 a0 01 	and  %g2, 1, %g4                               
40019610:	80 a0 00 04 	cmp  %g0, %g4                                  
40019614:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
40019618:	88 40 3f ff 	addx  %g0, -1, %g4                             
4001961c:	85 30 a0 01 	srl  %g2, 1, %g2                               
40019620:	88 09 20 80 	and  %g4, 0x80, %g4                            
40019624:	84 00 80 0f 	add  %g2, %o7, %g2                             
40019628:	88 01 3f 80 	add  %g4, -128, %g4                            
                    {                                                 
                        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++)
4001962c:	86 00 e0 01 	inc  %g3                                       
40019630:	80 a0 e0 0b 	cmp  %g3, 0xb                                  
40019634:	12 bf ff f5 	bne  40019608 <msdos_find_name_in_fat_file+0x9a0>
40019638:	84 00 80 04 	add  %g2, %g4, %g2                             
                            cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
                                                                      
                        if (lfn_entry || (lfn_checksum != cs))        
4001963c:	c6 0f bf 3f 	ldub  [ %fp + -193 ], %g3                      
40019640:	84 18 80 03 	xor  %g2, %g3, %g2                             
40019644:	80 88 a0 ff 	btst  0xff, %g2                                
40019648:	32 80 00 60 	bne,a   400197c8 <msdos_find_name_in_fat_file+0xb60><== NEVER TAKEN
4001964c:	c0 2f bf 63 	clrb  [ %fp + -157 ]                           <== NOT EXECUTED
40019650:	c4 07 bf 50 	ld  [ %fp + -176 ], %g2                        
40019654:	80 a0 a0 00 	cmp  %g2, 0                                    
40019658:	02 80 00 04 	be  40019668 <msdos_find_name_in_fat_file+0xa00><== ALWAYS TAKEN
4001965c:	da 07 a0 5c 	ld  [ %fp + 0x5c ], %o5                        
                            entry_matched = false;                    
40019660:	10 80 00 5a 	b  400197c8 <msdos_find_name_in_fat_file+0xb60><== NOT EXECUTED
40019664:	c0 2f bf 63 	clrb  [ %fp + -157 ]                           <== NOT EXECUTED
                        else {                                        
                            filename_matched = true;                  
                            rc = msdos_on_entry_found (               
40019668:	86 07 bf 68 	add  %fp, -152, %g3                            
4001966c:	98 10 00 01 	mov  %g1, %o4                                  
40019670:	e8 23 a0 5c 	st  %l4, [ %sp + 0x5c ]                        
40019674:	e2 23 a0 60 	st  %l1, [ %sp + 0x60 ]                        
40019678:	c6 23 a0 64 	st  %g3, [ %sp + 0x64 ]                        
4001967c:	90 10 00 1d 	mov  %i5, %o0                                  
40019680:	92 10 00 19 	mov  %i1, %o1                                  
40019684:	94 10 00 1b 	mov  %i3, %o2                                  
40019688:	7f ff fb 36 	call  40018360 <msdos_on_entry_found.isra.0>   
4001968c:	96 10 00 1a 	mov  %i2, %o3                                  
                            cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
                                                                      
                        if (lfn_entry || (lfn_checksum != cs))        
                            entry_matched = false;                    
                        else {                                        
                            filename_matched = true;                  
40019690:	82 10 20 01 	mov  1, %g1                                    
                            rc = msdos_on_entry_found (               
40019694:	c0 27 bf 50 	clr  [ %fp + -176 ]                            
                            cs = ((cs & 1) ? 0x80 : 0) + (cs >> 1) + *p;
                                                                      
                        if (lfn_entry || (lfn_checksum != cs))        
                            entry_matched = false;                    
                        else {                                        
                            filename_matched = true;                  
40019698:	10 bf ff 61 	b  4001941c <msdos_find_name_in_fat_file+0x7b4>
4001969c:	c2 2f bf 57 	stb  %g1, [ %fp + -169 ]                       
  uint8_t                         *buf,                               
  const size_t                     buf_size)                          
{                                                                     
  char         char_buf[MSDOS_NAME_MAX_WITH_DOT];                     
  int          eno             = 0;                                   
  size_t       bytes_converted = buf_size;                            
400196a0:	84 10 20 0c 	mov  0xc, %g2                                  
  ssize_t      bytes_written   = msdos_format_dirent_with_dot(char_buf, entry);
400196a4:	92 10 00 01 	mov  %g1, %o1                                  
400196a8:	c2 27 bf 24 	st  %g1, [ %fp + -220 ]                        
  uint8_t                         *buf,                               
  const size_t                     buf_size)                          
{                                                                     
  char         char_buf[MSDOS_NAME_MAX_WITH_DOT];                     
  int          eno             = 0;                                   
  size_t       bytes_converted = buf_size;                            
400196ac:	c4 27 bf 64 	st  %g2, [ %fp + -156 ]                        
  ssize_t      bytes_written   = msdos_format_dirent_with_dot(char_buf, entry);
400196b0:	7f ff fd 29 	call  40018b54 <msdos_format_dirent_with_dot>  
400196b4:	90 07 bf 70 	add  %fp, -144, %o0                            
                                                                      
  if (bytes_written > 0) {                                            
400196b8:	94 92 20 00 	orcc  %o0, 0, %o2                              
400196bc:	04 80 00 64 	ble  4001984c <msdos_find_name_in_fat_file+0xbe4><== NEVER TAKEN
400196c0:	c2 07 bf 24 	ld  [ %fp + -220 ], %g1                        
    if (char_buf[0] == 0x05)                                          
400196c4:	c4 4f bf 70 	ldsb  [ %fp + -144 ], %g2                      
400196c8:	80 a0 a0 05 	cmp  %g2, 5                                    
400196cc:	32 80 00 05 	bne,a   400196e0 <msdos_find_name_in_fat_file+0xa78><== ALWAYS TAKEN
400196d0:	c4 07 00 00 	ld  [ %i4 ], %g2                               
      char_buf[0] = 0xE5;                                             
400196d4:	86 10 3f e5 	mov  -27, %g3                                  <== NOT EXECUTED
400196d8:	c6 2f bf 70 	stb  %g3, [ %fp + -144 ]                       <== NOT EXECUTED
                                                                      
    eno = (*converter->handler->codepage_to_utf8) (                   
400196dc:	c4 07 00 00 	ld  [ %i4 ], %g2                               <== NOT EXECUTED
400196e0:	90 10 00 1c 	mov  %i4, %o0                                  
400196e4:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
400196e8:	92 07 bf 70 	add  %fp, -144, %o1                            
400196ec:	c2 27 bf 24 	st  %g1, [ %fp + -220 ]                        
400196f0:	96 07 bf 90 	add  %fp, -112, %o3                            
400196f4:	9f c0 80 00 	call  %g2                                      
400196f8:	98 07 bf 64 	add  %fp, -156, %o4                            
        converter,                                                    
        char_buf,                                                     
        bytes_written,                                                
        buf,                                                          
        &bytes_converted);                                            
    if (eno == 0)                                                     
400196fc:	ac 92 20 00 	orcc  %o0, 0, %l6                              
40019700:	12 80 00 54 	bne  40019850 <msdos_find_name_in_fat_file+0xbe8><== NEVER TAKEN
40019704:	c2 07 bf 24 	ld  [ %fp + -220 ], %g1                        
        bytes_written = bytes_converted;                              
40019708:	d4 07 bf 64 	ld  [ %fp + -156 ], %o2                        
                        bytes_in_entry = msdos_short_entry_to_utf8_name (
                            converter,                                
                            MSDOS_DIR_NAME (entry),                   
                            &entry_utf8_normalized[0],                
                            bytes_in_entry);                          
                        if (bytes_in_entry > 0) {                     
4001970c:	80 a2 a0 00 	cmp  %o2, 0                                    
40019710:	22 80 00 2b 	be,a   400197bc <msdos_find_name_in_fat_file+0xb54><== NEVER TAKEN
40019714:	82 10 3f ff 	mov  -1, %g1                                   <== NOT EXECUTED
                            filename_size_remaining = msdos_compare_entry_against_filename (
40019718:	c2 27 bf 24 	st  %g1, [ %fp + -220 ]                        
4001971c:	90 10 00 1c 	mov  %i4, %o0                                  
40019720:	92 07 bf 90 	add  %fp, -112, %o1                            
40019724:	96 10 00 17 	mov  %l7, %o3                                  
40019728:	98 10 00 15 	mov  %l5, %o4                                  
4001972c:	7f ff fa ec 	call  400182dc <msdos_compare_entry_against_filename>
40019730:	9a 07 bf 63 	add  %fp, -157, %o5                            
                                &entry_utf8_normalized[0],            
                                bytes_in_entry,                       
                                &filename_converted[0],               
                                name_len_for_compare,                 
                                &entry_matched);                      
                            if (entry_matched && filename_size_remaining == 0) {
40019734:	c4 0f bf 63 	ldub  [ %fp + -157 ], %g2                      
                            converter,                                
                            MSDOS_DIR_NAME (entry),                   
                            &entry_utf8_normalized[0],                
                            bytes_in_entry);                          
                        if (bytes_in_entry > 0) {                     
                            filename_size_remaining = msdos_compare_entry_against_filename (
40019738:	ac 10 00 08 	mov  %o0, %l6                                  
                                &entry_utf8_normalized[0],            
                                bytes_in_entry,                       
                                &filename_converted[0],               
                                name_len_for_compare,                 
                                &entry_matched);                      
                            if (entry_matched && filename_size_remaining == 0) {
4001973c:	80 a0 a0 00 	cmp  %g2, 0                                    
40019740:	c2 07 bf 24 	ld  [ %fp + -220 ], %g1                        
40019744:	c4 0f bf 57 	ldub  [ %fp + -169 ], %g2                      
40019748:	02 80 00 11 	be  4001978c <msdos_find_name_in_fat_file+0xb24>
4001974c:	90 10 20 00 	clr  %o0                                       
40019750:	80 a5 a0 00 	cmp  %l6, 0                                    
40019754:	32 80 00 0f 	bne,a   40019790 <msdos_find_name_in_fat_file+0xb28>
40019758:	82 18 a0 01 	xor  %g2, 1, %g1                               
                                filename_matched = true;              
                                rc = msdos_on_entry_found (           
4001975c:	da 07 a0 5c 	ld  [ %fp + 0x5c ], %o5                        
40019760:	84 07 bf 68 	add  %fp, -152, %g2                            
40019764:	e8 23 a0 5c 	st  %l4, [ %sp + 0x5c ]                        
40019768:	c4 23 a0 64 	st  %g2, [ %sp + 0x64 ]                        
4001976c:	e2 23 a0 60 	st  %l1, [ %sp + 0x60 ]                        
40019770:	90 10 00 1d 	mov  %i5, %o0                                  
40019774:	92 10 00 19 	mov  %i1, %o1                                  
40019778:	94 10 00 1b 	mov  %i3, %o2                                  
4001977c:	96 10 00 1a 	mov  %i2, %o3                                  
40019780:	7f ff fa f8 	call  40018360 <msdos_on_entry_found.isra.0>   
40019784:	98 10 00 01 	mov  %g1, %o4                                  
                                bytes_in_entry,                       
                                &filename_converted[0],               
                                name_len_for_compare,                 
                                &entry_matched);                      
                            if (entry_matched && filename_size_remaining == 0) {
                                filename_matched = true;              
40019788:	84 10 20 01 	mov  1, %g2                                    
                                    dir_offset,                       
                                    dir_entry,                        
                                    &lfn_start                        
                                );                                    
                            }                                         
                            if (rc == RC_OK && (! filename_matched)) {
4001978c:	82 18 a0 01 	xor  %g2, 1, %g1                               
40019790:	80 88 60 ff 	btst  0xff, %g1                                
40019794:	22 bf ff 22 	be,a   4001941c <msdos_find_name_in_fat_file+0x7b4>
40019798:	c4 2f bf 57 	stb  %g2, [ %fp + -169 ]                       
4001979c:	80 a2 20 00 	cmp  %o0, 0                                    
400197a0:	32 bf ff 1f 	bne,a   4001941c <msdos_find_name_in_fat_file+0x7b4><== NEVER TAKEN
400197a4:	c4 2f bf 57 	stb  %g2, [ %fp + -169 ]                       <== NOT EXECUTED
                                lfn_start.cln           = FAT_FILE_SHORT_NAME;
400197a8:	86 10 3f ff 	mov  -1, %g3                                   
                                entry_matched           = false;      
400197ac:	c0 2f bf 63 	clrb  [ %fp + -157 ]                           
                                    dir_entry,                        
                                    &lfn_start                        
                                );                                    
                            }                                         
                            if (rc == RC_OK && (! filename_matched)) {
                                lfn_start.cln           = FAT_FILE_SHORT_NAME;
400197b0:	c6 27 bf 68 	st  %g3, [ %fp + -152 ]                        
                                entry_matched           = false;      
400197b4:	10 bf ff 1a 	b  4001941c <msdos_find_name_in_fat_file+0x7b4>
400197b8:	ac 10 00 15 	mov  %l5, %l6                                  
                                filename_size_remaining = name_len_for_compare;
                            }                                         
                        } else {                                      
                          lfn_start.cln           = FAT_FILE_SHORT_NAME;
                          entry_matched           = false;            
400197bc:	c0 2f bf 63 	clrb  [ %fp + -157 ]                           <== NOT EXECUTED
                                lfn_start.cln           = FAT_FILE_SHORT_NAME;
                                entry_matched           = false;      
                                filename_size_remaining = name_len_for_compare;
                            }                                         
                        } else {                                      
                          lfn_start.cln           = FAT_FILE_SHORT_NAME;
400197c0:	c2 27 bf 68 	st  %g1, [ %fp + -152 ]                        <== NOT EXECUTED
                          entry_matched           = false;            
400197c4:	ac 10 00 15 	mov  %l5, %l6                                  
400197c8:	10 bf ff 15 	b  4001941c <msdos_find_name_in_fat_file+0x7b4>
400197cc:	90 10 20 00 	clr  %o0                                       
             * See if the entry is empty or the remainder of the directory is
             * empty ? Localize to make the code read better.         
             */                                                       
            bool entry_empty = (*MSDOS_DIR_ENTRY_TYPE(entry) ==       
                                MSDOS_THIS_DIR_ENTRY_EMPTY);          
            remainder_empty = (*MSDOS_DIR_ENTRY_TYPE(entry) ==        
400197d0:	10 80 00 04 	b  400197e0 <msdos_find_name_in_fat_file+0xb78>
400197d4:	82 10 20 01 	mov  1, %g1                                    
            rtems_set_errno_and_return_minus_one(EIO);                
                                                                      
        assert(bytes_read == bts2rd);                                 
                                                                      
        /* have to look at the DIR_NAME as "raw" 8-bit data */        
        for (dir_entry = 0;                                           
400197d8:	b0 10 00 08 	mov  %o0, %i0                                  
400197dc:	82 10 20 00 	clr  %g1                                       
400197e0:	c4 07 bf 34 	ld  [ %fp + -204 ], %g2                        
                    }                                                 
                }                                                     
            }                                                         
        }                                                             
                                                                      
        if (filename_matched || remainder_empty)                      
400197e4:	80 88 60 ff 	btst  0xff, %g1                                
400197e8:	84 00 80 1b 	add  %g2, %i3, %g2                             
400197ec:	c4 27 bf 34 	st  %g2, [ %fp + -204 ]                        
400197f0:	12 80 00 07 	bne  4001980c <msdos_find_name_in_fat_file+0xba4>
400197f4:	c2 0f bf 57 	ldub  [ %fp + -169 ], %g1                      
400197f8:	80 a0 60 00 	cmp  %g1, 0                                    
400197fc:	12 bf fd 81 	bne  40018e00 <msdos_find_name_in_fat_file+0x198>
40019800:	80 a6 20 00 	cmp  %i0, 0                                    
            break;                                                    
                                                                      
        (*dir_offset)++;                                              
40019804:	10 bf fe db 	b  40019370 <msdos_find_name_in_fat_file+0x708>
40019808:	a8 05 20 01 	inc  %l4                                       
    }                                                                 
    if ( ! filename_matched ) {                                       
4001980c:	80 a0 60 00 	cmp  %g1, 0                                    
40019810:	12 bf fd 7c 	bne  40018e00 <msdos_find_name_in_fat_file+0x198><== NEVER TAKEN
40019814:	80 a6 20 00 	cmp  %i0, 0                                    
        /*                                                            
         * If we are not to create the entry return a not found error.
         */                                                           
        if (!create_node)                                             
40019818:	c6 07 a0 4c 	ld  [ %fp + 0x4c ], %g3                        
4001981c:	80 a0 e0 00 	cmp  %g3, 0                                    
40019820:	12 bf fd 78 	bne  40018e00 <msdos_find_name_in_fat_file+0x198>
40019824:	80 a6 20 00 	cmp  %i0, 0                                    
            rc = MSDOS_NAME_NOT_FOUND_ERR;                            
40019828:	31 00 00 1f 	sethi  %hi(0x7c00), %i0                        
4001982c:	10 bf fd 74 	b  40018dfc <msdos_find_name_in_fat_file+0x194>
40019830:	b0 16 21 01 	or  %i0, 0x101, %i0	! 7d01 <_TLS_Alignment+0x7d00>
        }                                                             
    }                                                                 
                                                                      
    if (eno != 0) {                                                   
        retval = -1;                                                  
        errno  = eno;                                                 
40019834:	40 00 0b 16 	call  4001c48c <__errno>                       
40019838:	c2 27 bf 24 	st  %g1, [ %fp + -220 ]                        
4001983c:	c2 07 bf 24 	ld  [ %fp + -220 ], %g1                        
            retval = bytes_in_utf8;                                   
        }                                                             
    }                                                                 
                                                                      
    if (eno != 0) {                                                   
        retval = -1;                                                  
40019840:	94 10 3f ff 	mov  -1, %o2                                   
        errno  = eno;                                                 
40019844:	10 bf ff 5c 	b  400195b4 <msdos_find_name_in_fat_file+0x94c>
40019848:	c2 22 00 00 	st  %g1, [ %o0 ]                               
        buf,                                                          
        &bytes_converted);                                            
    if (eno == 0)                                                     
        bytes_written = bytes_converted;                              
  } else {                                                            
      eno = EINVAL;                                                   
4001984c:	ac 10 20 16 	mov  0x16, %l6                                 <== NOT EXECUTED
  }                                                                   
                                                                      
  if (eno != 0) {                                                     
      bytes_written = -1;                                             
      errno         = eno;                                            
40019850:	40 00 0b 0f 	call  4001c48c <__errno>                       <== NOT EXECUTED
40019854:	c2 27 bf 24 	st  %g1, [ %fp + -220 ]                        <== NOT EXECUTED
  } else {                                                            
      eno = EINVAL;                                                   
  }                                                                   
                                                                      
  if (eno != 0) {                                                     
      bytes_written = -1;                                             
40019858:	94 10 3f ff 	mov  -1, %o2                                   <== NOT EXECUTED
      errno         = eno;                                            
4001985c:	ec 22 00 00 	st  %l6, [ %o0 ]                               <== NOT EXECUTED
40019860:	10 bf ff ae 	b  40019718 <msdos_find_name_in_fat_file+0xab0><== NOT EXECUTED
40019864:	c2 07 bf 24 	ld  [ %fp + -220 ], %g1                        <== NOT EXECUTED
            empty_space_count                                         
        );                                                            
    }                                                                 
                                                                      
    return retval;                                                    
}                                                                     
40019868:	81 c7 e0 08 	ret                                            
4001986c:	81 e8 00 00 	restore                                        
                                                                      

40019870 <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 ) {
40019870:	9d e3 bf a0 	save  %sp, -96, %sp                            
    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) &&                                 
40019874:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40019878:	80 a0 60 01 	cmp  %g1, 1                                    
4001987c:	12 80 00 0f 	bne  400198b8 <msdos_find_node_by_cluster_num_in_fat_file+0x48>
40019880:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
40019884:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
40019888:	80 a0 60 00 	cmp  %g1, 0                                    
4001988c:	32 80 00 07 	bne,a   400198a8 <msdos_find_node_by_cluster_num_in_fat_file+0x38><== NEVER TAKEN
40019890:	f0 17 60 06 	lduh  [ %i5 + 6 ], %i0                         <== NOT EXECUTED
       (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))             
40019894:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       
    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) &&                                 
40019898:	80 88 60 03 	btst  3, %g1                                   
4001989c:	22 80 00 03 	be,a   400198a8 <msdos_find_node_by_cluster_num_in_fat_file+0x38><== NEVER TAKEN
400198a0:	f0 17 60 06 	lduh  [ %i5 + 6 ], %i0                         <== NOT EXECUTED
       (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))             
        bts2rd = fat_fd->fat_file_size;                               
400198a4:	f0 06 60 18 	ld  [ %i1 + 0x18 ], %i0                        
            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)          
400198a8:	27 00 00 3f 	sethi  %hi(0xfc00), %l3                        
       (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(&fs_info->fat, fat_fd, j * bts2rd, bts2rd,
400198ac:	a2 10 20 00 	clr  %l1                                       
            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)          
400198b0:	10 80 00 10 	b  400198f0 <msdos_find_node_by_cluster_num_in_fat_file+0x80>
400198b4:	a6 14 e3 ff 	or  %l3, 0x3ff, %l3                            
                                                                      
    if (FAT_FD_OF_ROOT_DIR(fat_fd) &&                                 
       (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))             
        bts2rd = fat_fd->fat_file_size;                               
    else                                                              
        bts2rd = fs_info->fat.vol.bpc;                                
400198b8:	10 bf ff fc 	b  400198a8 <msdos_find_node_by_cluster_num_in_fat_file+0x38>
400198bc:	f0 17 60 06 	lduh  [ %i5 + 6 ], %i0                         
                                                                      
        assert(ret == bts2rd);                                        
                                                                      
        for (i = 0; i < bts2rd; i += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE)
        {                                                             
            char* entry = (char*) fs_info->cl_buf + i;                
400198c0:	a4 10 20 00 	clr  %l2                                       
                                                                      
            /* if this and all rest entries are empty - return not-found */
            if ((*MSDOS_DIR_ENTRY_TYPE(entry)) ==                     
400198c4:	c2 0c 00 00 	ldub  [ %l0 ], %g1                             
400198c8:	80 a0 60 00 	cmp  %g1, 0                                    
400198cc:	02 80 00 46 	be  400199e4 <msdos_find_node_by_cluster_num_in_fat_file+0x174><== NEVER TAKEN
400198d0:	80 a0 60 e5 	cmp  %g1, 0xe5                                 
                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)) ==                     
400198d4:	32 80 00 22 	bne,a   4001995c <msdos_find_node_by_cluster_num_in_fat_file+0xec><== ALWAYS TAKEN
400198d8:	c4 14 20 14 	lduh  [ %l0 + 0x14 ], %g2                      
        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)
400198dc:	a4 04 a0 20 	add  %l2, 0x20, %l2                            <== NOT EXECUTED
400198e0:	80 a4 80 18 	cmp  %l2, %i0                                  
400198e4:	0a bf ff f8 	bcs  400198c4 <msdos_find_node_by_cluster_num_in_fat_file+0x54><== ALWAYS TAKEN
400198e8:	a0 04 20 20 	add  %l0, 0x20, %l0                            
400198ec:	a2 04 40 18 	add  %l1, %i0, %l1                             <== 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(&fs_info->fat, fat_fd, j * bts2rd, bts2rd,
400198f0:	d8 07 60 a0 	ld  [ %i5 + 0xa0 ], %o4                        
400198f4:	90 10 00 1d 	mov  %i5, %o0                                  
400198f8:	92 10 00 19 	mov  %i1, %o1                                  
400198fc:	94 10 00 11 	mov  %l1, %o2                                  
40019900:	7f ff e2 d0 	call  40012440 <fat_file_read>                 
40019904:	96 10 00 18 	mov  %i0, %o3                                  
40019908:	80 a2 20 00 	cmp  %o0, 0                                    
4001990c:	02 80 00 36 	be  400199e4 <msdos_find_node_by_cluster_num_in_fat_file+0x174><== NEVER TAKEN
40019910:	80 a2 20 1f 	cmp  %o0, 0x1f                                 
                                  fs_info->cl_buf)) != FAT_EOF)       
    {                                                                 
        if ( ret < MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE )                
40019914:	14 80 00 08 	bg  40019934 <msdos_find_node_by_cluster_num_in_fat_file+0xc4><== ALWAYS TAKEN
40019918:	80 a2 00 18 	cmp  %o0, %i0                                  
            rtems_set_errno_and_return_minus_one( EIO );              
4001991c:	40 00 0a dc 	call  4001c48c <__errno>                       <== NOT EXECUTED
40019920:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40019924:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40019928:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001992c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40019930:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
        assert(ret == bts2rd);                                        
40019934:	22 bf ff e3 	be,a   400198c0 <msdos_find_node_by_cluster_num_in_fat_file+0x50><== ALWAYS TAKEN
40019938:	e0 07 60 a0 	ld  [ %i5 + 0xa0 ], %l0                        
4001993c:	11 10 00 b4 	sethi  %hi(0x4002d000), %o0                    <== NOT EXECUTED
40019940:	15 10 00 b4 	sethi  %hi(0x4002d000), %o2                    <== NOT EXECUTED
40019944:	17 10 00 b4 	sethi  %hi(0x4002d000), %o3                    <== NOT EXECUTED
40019948:	90 12 23 18 	or  %o0, 0x318, %o0                            <== NOT EXECUTED
4001994c:	92 10 28 14 	mov  0x814, %o1                                <== NOT EXECUTED
40019950:	94 12 a3 f0 	or  %o2, 0x3f0, %o2                            <== NOT EXECUTED
40019954:	7f ff ac b8 	call  40004c34 <__assert_func>                 <== NOT EXECUTED
40019958:	96 12 e3 e0 	or  %o3, 0x3e0, %o3                            <== 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)          
4001995c:	c2 14 20 1a 	lduh  [ %l0 + 0x1a ], %g1                      
40019960:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40019964:	87 30 a0 08 	srl  %g2, 8, %g3                               
40019968:	86 08 c0 13 	and  %g3, %l3, %g3                             
4001996c:	83 28 60 10 	sll  %g1, 0x10, %g1                            
40019970:	85 30 a0 18 	srl  %g2, 0x18, %g2                            
40019974:	84 10 c0 02 	or  %g3, %g2, %g2                              
40019978:	87 30 60 08 	srl  %g1, 8, %g3                               
4001997c:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40019980:	86 08 c0 13 	and  %g3, %l3, %g3                             
40019984:	83 30 60 18 	srl  %g1, 0x18, %g1                            
40019988:	82 10 c0 01 	or  %g3, %g1, %g1                              
4001998c:	82 10 80 01 	or  %g2, %g1, %g1                              
40019990:	80 a0 40 1a 	cmp  %g1, %i2                                  
40019994:	32 bf ff d3 	bne,a   400198e0 <msdos_find_node_by_cluster_num_in_fat_file+0x70>
40019998:	a4 04 a0 20 	add  %l2, 0x20, %l2                            
            {                                                         
                /* on success fill aux structure and copy all 32 bytes */
                rc = fat_file_ioctl(&fs_info->fat, fat_fd, F_CLU_NUM, j * bts2rd,
4001999c:	90 10 00 1d 	mov  %i5, %o0                                  
400199a0:	92 10 00 19 	mov  %i1, %o1                                  
400199a4:	94 10 20 01 	mov  1, %o2                                    
400199a8:	96 10 00 11 	mov  %l1, %o3                                  
400199ac:	7f ff e3 84 	call  400127bc <fat_file_ioctl>                
400199b0:	98 10 00 1b 	mov  %i3, %o4                                  
                                    &dir_pos->sname.cln);             
                if (rc != RC_OK)                                      
400199b4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400199b8:	12 bf ff dd 	bne  4001992c <msdos_find_node_by_cluster_num_in_fat_file+0xbc><== NEVER TAKEN
400199bc:	82 10 3f ff 	mov  -1, %g1                                   
                    return rc;                                        
                                                                      
                dir_pos->sname.ofs = i;                               
400199c0:	e4 26 e0 04 	st  %l2, [ %i3 + 4 ]                           
                dir_pos->lname.cln = FAT_FILE_SHORT_NAME;             
400199c4:	c2 26 e0 08 	st  %g1, [ %i3 + 8 ]                           
                dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;             
400199c8:	c2 26 e0 0c 	st  %g1, [ %i3 + 0xc ]                         
                                                                      
                memcpy(dir_entry, entry,                              
400199cc:	90 10 00 1c 	mov  %i4, %o0                                  
400199d0:	92 10 00 10 	mov  %l0, %o1                                  
400199d4:	40 00 0d 03 	call  4001cde0 <memcpy>                        
400199d8:	94 10 20 20 	mov  0x20, %o2                                 
                       MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);            
                return RC_OK;                                         
400199dc:	81 c7 e0 08 	ret                                            
400199e0:	81 e8 00 00 	restore                                        
            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)) ==                     
                MSDOS_THIS_DIR_ENTRY_AND_REST_EMPTY)                  
                return MSDOS_NAME_NOT_FOUND_ERR;                      
400199e4:	31 00 00 1f 	sethi  %hi(0x7c00), %i0                        <== NOT EXECUTED
400199e8:	b0 16 21 01 	or  %i0, 0x101, %i0	! 7d01 <_TLS_Alignment+0x7d00><== NOT EXECUTED
            }                                                         
        }                                                             
        j++;                                                          
    }                                                                 
    return MSDOS_NAME_NOT_FOUND_ERR;                                  
}                                                                     
400199ec:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400199f0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000d418 <msdos_format>: ) /*-------------------------------------------------------------------------*\ | Return Value: | | 0, if success, -1 and errno if failed | \*=========================================================================*/ {
4000d418:	9d e3 bc d0 	save  %sp, -816, %sp                           
  msdos_format_param_t fmt_params;                                    
                                                                      
  /*                                                                  
   * open device for writing                                          
   */                                                                 
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, "open device\n");
4000d41c:	92 10 20 02 	mov  2, %o1                                    
4000d420:	90 10 00 19 	mov  %i1, %o0                                  
4000d424:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
4000d428:	7f ff ff 58 	call  4000d188 <msdos_format_printf>           
4000d42c:	94 12 a3 68 	or  %o2, 0x368, %o2	! 4002cb68 <_Semaphore_Translate_core_mutex_return_code_+0xb0>
  fd = open(devname, O_RDWR);                                         
4000d430:	92 10 20 02 	mov  2, %o1                                    
4000d434:	7f ff e1 33 	call  40005900 <open>                          
4000d438:	90 10 00 18 	mov  %i0, %o0                                  
  }                                                                   
                                                                      
  /*                                                                  
   * sanity check on device                                           
   */                                                                 
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,           
4000d43c:	92 10 20 02 	mov  2, %o1                                    
                                                                      
  /*                                                                  
   * open device for writing                                          
   */                                                                 
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, "open device\n");
  fd = open(devname, O_RDWR);                                         
4000d440:	b8 10 00 08 	mov  %o0, %i4                                  
  }                                                                   
                                                                      
  /*                                                                  
   * sanity check on device                                           
   */                                                                 
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,           
4000d444:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
4000d448:	90 10 00 19 	mov  %i1, %o0                                  
4000d44c:	94 12 a3 78 	or  %o2, 0x378, %o2                            
4000d450:	7f ff ff 4e 	call  4000d188 <msdos_format_printf>           
4000d454:	96 10 00 18 	mov  %i0, %o3                                  
                       "stat check: %s\n", devname);                  
  if (ret_val == 0) {                                                 
4000d458:	80 a7 3f ff 	cmp  %i4, -1                                   
4000d45c:	02 80 00 06 	be  4000d474 <msdos_format+0x5c>               <== NEVER TAKEN
4000d460:	ba 10 3f ff 	mov  -1, %i5                                   
    ret_val = fstat(fd, &stat_buf);                                   
4000d464:	90 10 00 1c 	mov  %i4, %o0                                  
4000d468:	7f ff de 85 	call  40004e7c <fstat>                         
4000d46c:	92 07 bd 60 	add  %fp, -672, %o1                            
4000d470:	ba 10 00 08 	mov  %o0, %i5                                  
  }                                                                   
                                                                      
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_INFO,             
4000d474:	90 10 00 19 	mov  %i1, %o0                                  
4000d478:	92 10 20 01 	mov  1, %o1                                    
4000d47c:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
4000d480:	96 10 00 18 	mov  %i0, %o3                                  
4000d484:	7f ff ff 41 	call  4000d188 <msdos_format_printf>           
4000d488:	94 12 a3 88 	or  %o2, 0x388, %o2                            
                       "formating: %s\n", devname);                   
  /* rtems feature: no block devices, all are character devices */    
  if ((ret_val == 0) && (!S_ISBLK(stat_buf.st_mode))) {               
4000d48c:	80 a7 60 00 	cmp  %i5, 0                                    
4000d490:	12 80 00 36 	bne  4000d568 <msdos_format+0x150>             <== NEVER TAKEN
4000d494:	80 a0 00 19 	cmp  %g0, %i1                                  
4000d498:	c4 07 bd 6c 	ld  [ %fp + -660 ], %g2                        
4000d49c:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
4000d4a0:	84 08 80 01 	and  %g2, %g1, %g2                             
4000d4a4:	03 00 00 18 	sethi  %hi(0x6000), %g1                        
4000d4a8:	80 a0 80 01 	cmp  %g2, %g1                                  
4000d4ac:	02 80 00 07 	be  4000d4c8 <msdos_format+0xb0>               <== ALWAYS TAKEN
4000d4b0:	92 10 20 00 	clr  %o1                                       
    errno = ENOTTY;                                                   
4000d4b4:	40 00 3b f6 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000d4b8:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
4000d4bc:	82 10 20 19 	mov  0x19, %g1                                 <== NOT EXECUTED
4000d4c0:	10 80 00 29 	b  4000d564 <msdos_format+0x14c>               <== NOT EXECUTED
4000d4c4:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
  uint64_t total_size = 0;                                            
  uint32_t data_clusters_cnt;                                         
  uint8_t  iteration_cnt = 0;                                         
  uint8_t  fat_type = UINT8_MAX;                                      
                                                                      
  memset(fmt_params,0,sizeof(*fmt_params));                           
4000d4c8:	94 10 20 54 	mov  0x54, %o2                                 
4000d4cc:	40 00 3e 84 	call  4001cedc <memset>                        
4000d4d0:	90 07 bd ac 	add  %fp, -596, %o0                            
static inline int rtems_disk_fd_get_media_block_size(                 
  int fd,                                                             
  uint32_t *media_block_size                                          
)                                                                     
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_GETMEDIABLKSIZE, media_block_size);    
4000d4d4:	90 10 00 1c 	mov  %i4, %o0                                  
4000d4d8:	37 10 01 10 	sethi  %hi(0x40044000), %i3                    
4000d4dc:	94 07 bd ac 	add  %fp, -596, %o2                            
4000d4e0:	40 00 1d 4e 	call  40014a18 <ioctl>                         
4000d4e4:	92 16 e2 02 	or  %i3, 0x202, %o1                            
   * At least one thing we don't have to magically guess...           
   */                                                                 
  if (ret_val == 0) {                                                 
    ret_val = rtems_disk_fd_get_media_block_size(fd, &fmt_params->bytes_per_sector);
  }                                                                   
  if (ret_val == 0) {                                                 
4000d4e8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000d4ec:	12 80 00 0a 	bne  4000d514 <msdos_format+0xfc>              <== NEVER TAKEN
4000d4f0:	c2 07 bd b0 	ld  [ %fp + -592 ], %g1                        
static inline int rtems_disk_fd_get_block_count(                      
  int fd,                                                             
  rtems_blkdev_bnum *block_count                                      
)                                                                     
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_GETSIZE, block_count);                 
4000d4f4:	90 10 00 1c 	mov  %i4, %o0                                  
4000d4f8:	92 16 e2 05 	or  %i3, 0x205, %o1                            
4000d4fc:	40 00 1d 47 	call  40014a18 <ioctl>                         
4000d500:	94 07 bd b0 	add  %fp, -592, %o2                            
    ret_val = rtems_disk_fd_get_block_count(fd, &fmt_params->totl_sector_cnt);
  }                                                                   
  if (ret_val == 0) {                                                 
4000d504:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000d508:	02 80 00 46 	be  4000d620 <msdos_format+0x208>              <== ALWAYS TAKEN
4000d50c:	f0 07 bd ac 	ld  [ %fp + -596 ], %i0                        
      }                                                               
                                                                      
      ++iteration_cnt;                                                
    }                                                                 
  }                                                                   
  if ( fmt_params->totl_sector_cnt == 0 )                             
4000d510:	c2 07 bd b0 	ld  [ %fp + -592 ], %g1                        
4000d514:	80 a0 60 00 	cmp  %g1, 0                                    
4000d518:	02 80 01 d2 	be  4000dc60 <msdos_format+0x848>              <== NEVER TAKEN
4000d51c:	80 a7 60 00 	cmp  %i5, 0                                    
  {                                                                   
    errno = EINVAL;                                                   
    ret_val = -1;                                                     
  }                                                                   
                                                                      
  if (0 == ret_val)                                                   
4000d520:	02 80 01 a7 	be  4000dbbc <msdos_format+0x7a4>              
4000d524:	c2 0f bd de 	ldub  [ %fp + -546 ], %g1                      
  }                                                                   
  /*                                                                  
   * determine location and size of root directory                    
   * for formatting                                                   
   */                                                                 
  if (fmt_params->root_dir_sectors > 0) {                             
4000d528:	f4 07 bd c8 	ld  [ %fp + -568 ], %i2                        
4000d52c:	d0 0f bd dc 	ldub  [ %fp + -548 ], %o0                      
4000d530:	80 a6 a0 00 	cmp  %i2, 0                                    
4000d534:	f6 07 bd b4 	ld  [ %fp + -588 ], %i3                        
    fmt_params->root_dir_start_sec =                                  
      fmt_params->rsvd_sector_cnt                                     
      + (fmt_params-> fat_num*fmt_params->sectors_per_fat);           
4000d538:	90 0a 20 ff 	and  %o0, 0xff, %o0                            
  }                                                                   
  /*                                                                  
   * determine location and size of root directory                    
   * for formatting                                                   
   */                                                                 
  if (fmt_params->root_dir_sectors > 0) {                             
4000d53c:	02 80 01 d1 	be  4000dc80 <msdos_format+0x868>              
4000d540:	d2 07 bd bc 	ld  [ %fp + -580 ], %o1                        
    fmt_params->root_dir_start_sec =                                  
      fmt_params->rsvd_sector_cnt                                     
      + (fmt_params-> fat_num*fmt_params->sectors_per_fat);           
4000d544:	7f ff d4 73 	call  40002710 <.umul>                         
4000d548:	01 00 00 00 	nop                                            
    fmt_params->root_dir_fmt_sec_cnt = fmt_params->root_dir_sectors;  
4000d54c:	f4 27 bd d0 	st  %i2, [ %fp + -560 ]                        
   * for formatting                                                   
   */                                                                 
  if (fmt_params->root_dir_sectors > 0) {                             
    fmt_params->root_dir_start_sec =                                  
      fmt_params->rsvd_sector_cnt                                     
      + (fmt_params-> fat_num*fmt_params->sectors_per_fat);           
4000d550:	90 02 00 1b 	add  %o0, %i3, %o0                             
  /*                                                                  
   * determine location and size of root directory                    
   * for formatting                                                   
   */                                                                 
  if (fmt_params->root_dir_sectors > 0) {                             
    fmt_params->root_dir_start_sec =                                  
4000d554:	d0 27 bd cc 	st  %o0, [ %fp + -564 ]                        
    fmt_params->root_dir_fmt_sec_cnt = fmt_params->sectors_per_cluster;
  }                                                                   
  /*                                                                  
   * determine usable OEMName                                         
   */                                                                 
  if (ret_val == 0) {                                                 
4000d558:	80 a7 60 00 	cmp  %i5, 0                                    
4000d55c:	02 80 01 d0 	be  4000dc9c <msdos_format+0x884>              
4000d560:	80 a6 60 00 	cmp  %i1, 0                                    
  }                                                                   
  /*                                                                  
   * if requested, write whole disk/partition with 0xe5               
   */                                                                 
  if ((ret_val == 0) &&                                               
      (rqdata != NULL) &&                                             
4000d564:	80 a0 00 19 	cmp  %g0, %i1                                  
4000d568:	b4 40 20 00 	addx  %g0, 0, %i2                              
    ret_val = msdos_format_determine_fmt_params(fd,rqdata,&fmt_params);
  }                                                                   
  /*                                                                  
   * if requested, write whole disk/partition with 0xe5               
   */                                                                 
  if ((ret_val == 0) &&                                               
4000d56c:	80 a7 60 00 	cmp  %i5, 0                                    
4000d570:	12 80 03 5c 	bne  4000e2e0 <msdos_format+0xec8>             
4000d574:	b0 10 00 1d 	mov  %i5, %i0                                  
4000d578:	80 a6 a0 00 	cmp  %i2, 0                                    
4000d57c:	02 80 00 1d 	be  4000d5f0 <msdos_format+0x1d8>              
4000d580:	80 a7 60 00 	cmp  %i5, 0                                    
      (rqdata != NULL) &&                                             
4000d584:	c2 0e 60 15 	ldub  [ %i1 + 0x15 ], %g1                      
4000d588:	80 a0 60 00 	cmp  %g1, 0                                    
4000d58c:	02 80 00 11 	be  4000d5d0 <msdos_format+0x1b8>              <== NEVER TAKEN
4000d590:	90 10 00 19 	mov  %i1, %o0                                  
   */                                                                 
  if (ret_val == 0) {                                                 
    /*                                                                
     * Read the current MBR to obtain the partition table.            
     */                                                               
    msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,         
4000d594:	92 10 20 02 	mov  2, %o1                                    
4000d598:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
4000d59c:	7f ff fe fb 	call  4000d188 <msdos_format_printf>           
4000d5a0:	94 12 a3 f8 	or  %o2, 0x3f8, %o2	! 4002cbf8 <_Semaphore_Translate_core_mutex_return_code_+0x140>
|    0, if success, -1 and errno if failed                                  |
\*=========================================================================*/
{                                                                     
  int ret_val = 0;                                                    
                                                                      
  if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {     
4000d5a4:	90 10 00 1c 	mov  %i4, %o0                                  
    /*                                                                
     * 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,                               
4000d5a8:	fa 07 bd ac 	ld  [ %fp + -596 ], %i5                        
|    0, if success, -1 and errno if failed                                  |
\*=========================================================================*/
{                                                                     
  int ret_val = 0;                                                    
                                                                      
  if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {     
4000d5ac:	92 10 20 00 	clr  %o1                                       
4000d5b0:	94 10 20 00 	clr  %o2                                       
4000d5b4:	40 00 1d 3a 	call  40014a9c <lseek>                         
4000d5b8:	96 10 20 00 	clr  %o3                                       
4000d5bc:	80 a2 20 00 	cmp  %o0, 0                                    
4000d5c0:	16 80 00 10 	bge  4000d600 <msdos_format+0x1e8>             <== ALWAYS TAKEN
4000d5c4:	90 10 00 1c 	mov  %i4, %o0                                  
    }                                                                 
  }                                                                   
  if ( fmt_params->totl_sector_cnt == 0 )                             
  {                                                                   
    errno = EINVAL;                                                   
    ret_val = -1;                                                     
4000d5c8:	10 80 03 45 	b  4000e2dc <msdos_format+0xec4>               <== NOT EXECUTED
4000d5cc:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
   * if requested, write whole disk/partition with 0xe5               
   */                                                                 
  if ((ret_val == 0) &&                                               
      (rqdata != NULL) &&                                             
      !(rqdata->quick_format)) {                                      
    ret_val = msdos_format_fill_sectors                               
4000d5d0:	d6 07 bd b0 	ld  [ %fp + -592 ], %o3                        <== NOT EXECUTED
4000d5d4:	d8 07 bd ac 	ld  [ %fp + -596 ], %o4                        <== NOT EXECUTED
4000d5d8:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4000d5dc:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4000d5e0:	7f ff ff 1a 	call  4000d248 <msdos_format_fill_sectors>     <== NOT EXECUTED
4000d5e4:	9a 10 3f e5 	mov  -27, %o5                                  <== NOT EXECUTED
4000d5e8:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * create master boot record                                        
   */                                                                 
  if (ret_val == 0) {                                                 
4000d5ec:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
4000d5f0:	12 80 03 3c 	bne  4000e2e0 <msdos_format+0xec8>             <== NEVER TAKEN
4000d5f4:	b0 10 00 1d 	mov  %i5, %i0                                  
    /*                                                                
     * Read the current MBR to obtain the partition table.            
     */                                                               
    msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,         
4000d5f8:	10 bf ff e7 	b  4000d594 <msdos_format+0x17c>               
4000d5fc:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
  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)) {                            
4000d600:	92 07 be 00 	add  %fp, -512, %o1                            
4000d604:	40 00 1d 97 	call  40014c60 <read>                          
4000d608:	94 10 00 1d 	mov  %i5, %o2                                  
                         "read MRB sector\n");                        
    ret_val = msdos_format_read_sec(fd,                               
                                    0,                                
                                    fmt_params.bytes_per_sector,      
                                    tmp_sec);                         
    if (ret_val == 0) {                                               
4000d60c:	80 a2 20 00 	cmp  %o0, 0                                    
4000d610:	16 80 01 ed 	bge  4000ddc4 <msdos_format+0x9ac>             <== ALWAYS TAKEN
4000d614:	ba 10 3f ff 	mov  -1, %i5                                   
    }                                                                 
                                                                      
    start_sector = loc_align_object (fmt_params.rsvd_sector_cnt,      
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
4000d618:	10 80 03 32 	b  4000e2e0 <msdos_format+0xec8>               <== NOT EXECUTED
4000d61c:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
  }                                                                   
  if (ret_val == 0) {                                                 
    ret_val = rtems_disk_fd_get_block_count(fd, &fmt_params->totl_sector_cnt);
  }                                                                   
  if (ret_val == 0) {                                                 
    total_size = (uint64_t)fmt_params->bytes_per_sector * fmt_params->totl_sector_cnt;
4000d620:	fa 07 bd b0 	ld  [ %fp + -592 ], %i5                        
4000d624:	94 10 20 00 	clr  %o2                                       
4000d628:	96 10 00 18 	mov  %i0, %o3                                  
4000d62c:	7f ff d3 15 	call  40002280 <__muldi3>                      
4000d630:	92 10 00 1d 	mov  %i5, %o1                                  
    msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,         
4000d634:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
  }                                                                   
  if (ret_val == 0) {                                                 
    ret_val = rtems_disk_fd_get_block_count(fd, &fmt_params->totl_sector_cnt);
  }                                                                   
  if (ret_val == 0) {                                                 
    total_size = (uint64_t)fmt_params->bytes_per_sector * fmt_params->totl_sector_cnt;
4000d638:	b4 10 00 08 	mov  %o0, %i2                                  
4000d63c:	b6 10 00 09 	mov  %o1, %i3                                  
    msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,         
4000d640:	d2 23 a0 5c 	st  %o1, [ %sp + 0x5c ]                        
4000d644:	f4 3f bd 58 	std  %i2, [ %fp + -680 ]                       
4000d648:	9a 10 00 1a 	mov  %i2, %o5                                  
4000d64c:	90 10 00 19 	mov  %i1, %o0                                  
4000d650:	92 10 20 02 	mov  2, %o1                                    
4000d654:	94 12 a3 98 	or  %o2, 0x398, %o2                            
4000d658:	96 10 00 18 	mov  %i0, %o3                                  
4000d65c:	7f ff fe cb 	call  4000d188 <msdos_format_printf>           
4000d660:	98 10 00 1d 	mov  %i5, %o4                                  
                                                                      
  /*                                                                  
   * determine number of FATs                                         
   */                                                                 
  if (ret_val == 0) {                                                 
    if ((rqdata == NULL) ||                                           
4000d664:	80 a6 60 00 	cmp  %i1, 0                                    
4000d668:	02 80 00 0a 	be  4000d690 <msdos_format+0x278>              
4000d66c:	82 10 20 02 	mov  2, %g1                                    
	(rqdata->fat_num == 0)) {                                            
4000d670:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
                                                                      
  /*                                                                  
   * determine number of FATs                                         
   */                                                                 
  if (ret_val == 0) {                                                 
    if ((rqdata == NULL) ||                                           
4000d674:	80 a0 60 00 	cmp  %g1, 0                                    
4000d678:	12 80 00 04 	bne  4000d688 <msdos_format+0x270>             
4000d67c:	80 a0 60 06 	cmp  %g1, 6                                    
	(rqdata->fat_num == 0)) {                                            
      fmt_params->fat_num = 2;                                        
4000d680:	10 80 00 04 	b  4000d690 <msdos_format+0x278>               
4000d684:	82 10 20 02 	mov  2, %g1                                    
    }                                                                 
    else if (rqdata->fat_num <= 6) {                                  
4000d688:	18 80 00 0e 	bgu  4000d6c0 <msdos_format+0x2a8>             
4000d68c:	01 00 00 00 	nop                                            
      fmt_params->fat_num = rqdata->fat_num;                          
4000d690:	c2 2f bd dc 	stb  %g1, [ %fp + -548 ]                       
      ret_val = -1;                                                   
    }                                                                 
  }                                                                   
                                                                      
  if (ret_val == 0)                                                   
    msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,         
4000d694:	d6 0f bd dc 	ldub  [ %fp + -548 ], %o3                      
4000d698:	90 10 00 19 	mov  %i1, %o0                                  
4000d69c:	92 10 20 02 	mov  2, %o1                                    
4000d6a0:	15 10 00 b3 	sethi  %hi(0x4002cc00), %o2                    
4000d6a4:	7f ff fe b9 	call  4000d188 <msdos_format_printf>           
4000d6a8:	94 12 a0 70 	or  %o2, 0x70, %o2	! 4002cc70 <_Semaphore_Translate_core_mutex_return_code_+0x1b8>
     * are a compromise concerning capacity and efficency             
     */                                                               
    uint32_t fat12_sect_per_clust = 8;                                
    uint32_t fat16_sect_per_clust = 32;                               
                                                                      
    if (rqdata != NULL && rqdata->sectors_per_cluster != 0) {         
4000d6ac:	80 a6 60 00 	cmp  %i1, 0                                    
4000d6b0:	32 80 00 09 	bne,a   4000d6d4 <msdos_format+0x2bc>          
4000d6b4:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
     * 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             
     */                                                               
    uint32_t fat12_sect_per_clust = 8;                                
    uint32_t fat16_sect_per_clust = 32;                               
4000d6b8:	10 80 00 0b 	b  4000d6e4 <msdos_format+0x2cc>               
4000d6bc:	84 10 20 20 	mov  0x20, %g2                                 
    }                                                                 
    else if (rqdata->fat_num <= 6) {                                  
      fmt_params->fat_num = rqdata->fat_num;                          
    }                                                                 
    else {                                                            
      errno = EINVAL;                                                 
4000d6c0:	40 00 3b 73 	call  4001c48c <__errno>                       
4000d6c4:	ba 10 3f ff 	mov  -1, %i5                                   
4000d6c8:	82 10 20 16 	mov  0x16, %g1                                 
4000d6cc:	10 bf ff 91 	b  4000d510 <msdos_format+0xf8>                
4000d6d0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
     * are a compromise concerning capacity and efficency             
     */                                                               
    uint32_t fat12_sect_per_clust = 8;                                
    uint32_t fat16_sect_per_clust = 32;                               
                                                                      
    if (rqdata != NULL && rqdata->sectors_per_cluster != 0) {         
4000d6d4:	84 90 60 00 	orcc  %g1, 0, %g2                              
4000d6d8:	12 80 00 05 	bne  4000d6ec <msdos_format+0x2d4>             
4000d6dc:	c6 07 bd b0 	ld  [ %fp + -592 ], %g3                        
     * 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             
     */                                                               
    uint32_t fat12_sect_per_clust = 8;                                
    uint32_t fat16_sect_per_clust = 32;                               
4000d6e0:	84 10 20 20 	mov  0x20, %g2                                 
    /*                                                                
     * 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             
     */                                                               
    uint32_t fat12_sect_per_clust = 8;                                
4000d6e4:	82 10 20 08 	mov  8, %g1                                    
    if (rqdata != NULL && rqdata->sectors_per_cluster != 0) {         
      fat12_sect_per_clust = rqdata->sectors_per_cluster;             
      fat16_sect_per_clust = rqdata->sectors_per_cluster;             
    }                                                                 
                                                                      
    if (fmt_params->totl_sector_cnt < FAT_FAT12_MAX_CLN * fat12_sect_per_clust) {
4000d6e8:	c6 07 bd b0 	ld  [ %fp + -592 ], %g3                        
4000d6ec:	89 28 60 02 	sll  %g1, 2, %g4                               
4000d6f0:	bb 28 60 0a 	sll  %g1, 0xa, %i5                             
4000d6f4:	88 27 40 04 	sub  %i5, %g4, %g4                             
4000d6f8:	88 01 00 01 	add  %g4, %g1, %g4                             
4000d6fc:	89 29 20 02 	sll  %g4, 2, %g4                               
4000d700:	82 01 00 01 	add  %g4, %g1, %g1                             
4000d704:	80 a0 c0 01 	cmp  %g3, %g1                                  
4000d708:	3a 80 00 04 	bcc,a   4000d718 <msdos_format+0x300>          
4000d70c:	83 28 a0 02 	sll  %g2, 2, %g1                               
      fmt_params->fattype = FAT_FAT12;                                
4000d710:	10 80 00 0b 	b  4000d73c <msdos_format+0x324>               
4000d714:	82 10 20 01 	mov  1, %g1                                    
      /* start trying with small clusters */                          
      fmt_params->sectors_per_cluster = 2;                            
    }                                                                 
    else if (fmt_params->totl_sector_cnt < FAT_FAT16_MAX_CLN * fat16_sect_per_clust) {
4000d718:	89 28 a0 0e 	sll  %g2, 0xe, %g4                             
4000d71c:	82 21 00 01 	sub  %g4, %g1, %g1                             
4000d720:	82 00 40 02 	add  %g1, %g2, %g1                             
4000d724:	83 28 60 02 	sll  %g1, 2, %g1                               
4000d728:	84 00 40 02 	add  %g1, %g2, %g2                             
4000d72c:	80 a0 c0 02 	cmp  %g3, %g2                                  
4000d730:	1a 80 00 06 	bcc  4000d748 <msdos_format+0x330>             
4000d734:	1b 10 00 00 	sethi  %hi(0x40000000), %o5                    
      fmt_params->fattype = FAT_FAT16;                                
4000d738:	82 10 20 02 	mov  2, %g1                                    
4000d73c:	c2 2f bd de 	stb  %g1, [ %fp + -546 ]                       
      /* start trying with small clusters */                          
      fmt_params->sectors_per_cluster = 2;                            
4000d740:	10 80 00 15 	b  4000d794 <msdos_format+0x37c>               
4000d744:	82 10 20 02 	mov  2, %g1                                    
    }                                                                 
    else {                                                            
      uint32_t gigs = (total_size + ONE_GB) / ONE_GB;                 
4000d748:	86 86 c0 0d 	addcc  %i3, %o5, %g3                           
4000d74c:	83 30 e0 1e 	srl  %g3, 0x1e, %g1                            
4000d750:	98 10 20 00 	clr  %o4                                       
4000d754:	84 46 80 0c 	addx  %i2, %o4, %g2                            
4000d758:	85 28 a0 02 	sll  %g2, 2, %g2                               
4000d75c:	84 10 80 01 	or  %g2, %g1, %g2                              
      int b;                                                          
      fmt_params->fattype = FAT_FAT32;                                
4000d760:	82 10 20 04 	mov  4, %g1                                    
      /* scale with the size of disk... */                            
      for (b = 31; b > 0; b--)                                        
        if ((gigs & (1 << b)) != 0)                                   
4000d764:	86 10 20 01 	mov  1, %g3                                    
      fmt_params->sectors_per_cluster = 2;                            
    }                                                                 
    else {                                                            
      uint32_t gigs = (total_size + ONE_GB) / ONE_GB;                 
      int b;                                                          
      fmt_params->fattype = FAT_FAT32;                                
4000d768:	c2 2f bd de 	stb  %g1, [ %fp + -546 ]                       
      /* scale with the size of disk... */                            
      for (b = 31; b > 0; b--)                                        
4000d76c:	82 10 20 1f 	mov  0x1f, %g1                                 
        if ((gigs & (1 << b)) != 0)                                   
4000d770:	89 28 c0 01 	sll  %g3, %g1, %g4                             
4000d774:	80 89 00 02 	btst  %g4, %g2                                 
4000d778:	32 80 00 06 	bne,a   4000d790 <msdos_format+0x378>          
4000d77c:	84 10 20 01 	mov  1, %g2                                    
    else {                                                            
      uint32_t gigs = (total_size + ONE_GB) / ONE_GB;                 
      int b;                                                          
      fmt_params->fattype = FAT_FAT32;                                
      /* scale with the size of disk... */                            
      for (b = 31; b > 0; b--)                                        
4000d780:	82 80 7f ff 	addcc  %g1, -1, %g1                            
4000d784:	12 bf ff fc 	bne  4000d774 <msdos_format+0x35c>             
4000d788:	89 28 c0 01 	sll  %g3, %g1, %g4                             
        if ((gigs & (1 << b)) != 0)                                   
          break;                                                      
      fmt_params->sectors_per_cluster = 1 << b;                       
4000d78c:	84 10 20 01 	mov  1, %g2                                    
4000d790:	83 28 80 01 	sll  %g2, %g1, %g1                             
4000d794:	c2 27 bd b8 	st  %g1, [ %fp + -584 ]                        
    }                                                                 
                                                                      
    ret_val = msdos_set_sectors_per_cluster_from_request( rqdata, fmt_params );
4000d798:	90 10 00 19 	mov  %i1, %o0                                  
4000d79c:	7f ff fe fb 	call  4000d388 <msdos_set_sectors_per_cluster_from_request>
4000d7a0:	92 07 bd ac 	add  %fp, -596, %o1                            
      || fmt_params->fattype == FAT_FAT16 ) {                         
    /* start trying with small clusters */                            
    fmt_params->sectors_per_cluster = 2;                              
  }                                                                   
  else {                                                              
    uint32_t gigs = ( total_size + ONE_GB ) / ONE_GB;                 
4000d7a4:	98 10 20 00 	clr  %o4                                       
4000d7a8:	1b 10 00 00 	sethi  %hi(0x40000000), %o5                    
4000d7ac:	86 86 c0 0d 	addcc  %i3, %o5, %g3                           
4000d7b0:	84 46 80 0c 	addx  %i2, %o4, %g2                            
4000d7b4:	83 30 e0 1e 	srl  %g3, 0x1e, %g1                            
4000d7b8:	85 28 a0 02 	sll  %g2, 2, %g2                               
4000d7bc:	82 10 80 01 	or  %g2, %g1, %g1                              
          && fmt_params->fattype != fat_type                          
          && fmt_params->totl_sector_cnt > 0 ) {                      
      /*                                                              
       * Skip aligning structures or d align them                     
       */                                                             
      if (ret_val == 0 && rqdata != NULL)                             
4000d7c0:	80 a0 00 19 	cmp  %g0, %i1                                  
      || fmt_params->fattype == FAT_FAT16 ) {                         
    /* start trying with small clusters */                            
    fmt_params->sectors_per_cluster = 2;                              
  }                                                                   
  else {                                                              
    uint32_t gigs = ( total_size + ONE_GB ) / ONE_GB;                 
4000d7c4:	c2 27 bd 40 	st  %g1, [ %fp + -704 ]                        
        if ((gigs & (1 << b)) != 0)                                   
          break;                                                      
      fmt_params->sectors_per_cluster = 1 << b;                       
    }                                                                 
                                                                      
    ret_val = msdos_set_sectors_per_cluster_from_request( rqdata, fmt_params );
4000d7c8:	ba 10 00 08 	mov  %o0, %i5                                  
          && fmt_params->fattype != fat_type                          
          && fmt_params->totl_sector_cnt > 0 ) {                      
      /*                                                              
       * Skip aligning structures or d align them                     
       */                                                             
      if (ret_val == 0 && rqdata != NULL)                             
4000d7cc:	82 40 20 00 	addx  %g0, 0, %g1                              
      || fmt_params->fattype == FAT_FAT16 ) {                         
    /* start trying with small clusters */                            
    fmt_params->sectors_per_cluster = 2;                              
  }                                                                   
  else {                                                              
    uint32_t gigs = ( total_size + ONE_GB ) / ONE_GB;                 
4000d7d0:	a8 10 3f ff 	mov  -1, %l4                                   
4000d7d4:	a6 10 20 00 	clr  %l3                                       
          && fmt_params->fattype != fat_type                          
          && fmt_params->totl_sector_cnt > 0 ) {                      
      /*                                                              
       * Skip aligning structures or d align them                     
       */                                                             
      if (ret_val == 0 && rqdata != NULL)                             
4000d7d8:	c2 27 bd 48 	st  %g1, [ %fp + -696 ]                        
    if (ret_val == 0) {                                               
      data_clusters_cnt =                                             
        fmt_params->totl_sector_cnt / fmt_params->sectors_per_cluster;
    }                                                                 
                                                                      
    while(   ret_val == 0                                             
4000d7dc:	80 a7 60 00 	cmp  %i5, 0                                    
4000d7e0:	12 bf ff 4c 	bne  4000d510 <msdos_format+0xf8>              <== NEVER TAKEN
4000d7e4:	c2 0f bd de 	ldub  [ %fp + -546 ], %g1                      
          && fmt_params->fattype != fat_type                          
4000d7e8:	a8 0d 20 ff 	and  %l4, 0xff, %l4                            
4000d7ec:	80 a0 40 14 	cmp  %g1, %l4                                  
4000d7f0:	02 bf ff 48 	be  4000d510 <msdos_format+0xf8>               
4000d7f4:	c2 07 bd b0 	ld  [ %fp + -592 ], %g1                        
          && fmt_params->totl_sector_cnt > 0 ) {                      
4000d7f8:	80 a0 60 00 	cmp  %g1, 0                                    
4000d7fc:	02 bf ff 46 	be  4000d514 <msdos_format+0xfc>               <== NEVER TAKEN
4000d800:	c8 07 bd 48 	ld  [ %fp + -696 ], %g4                        
      /*                                                              
       * Skip aligning structures or d align them                     
       */                                                             
      if (ret_val == 0 && rqdata != NULL)                             
4000d804:	80 a1 20 00 	cmp  %g4, 0                                    
4000d808:	02 80 00 05 	be  4000d81c <msdos_format+0x404>              
4000d80c:	d6 07 bd b8 	ld  [ %fp + -584 ], %o3                        
        fmt_params->skip_alignment = rqdata->skip_alignment;          
4000d810:	c2 0e 60 16 	ldub  [ %i1 + 0x16 ], %g1                      
4000d814:	c2 2f bd fc 	stb  %g1, [ %fp + -516 ]                       
                                                                      
      if (ret_val == 0) {                                             
        msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,     
4000d818:	d6 07 bd b8 	ld  [ %fp + -584 ], %o3                        
4000d81c:	90 10 00 19 	mov  %i1, %o0                                  
4000d820:	92 10 20 02 	mov  2, %o1                                    
4000d824:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
4000d828:	7f ff fe 58 	call  4000d188 <msdos_format_printf>           
4000d82c:	94 12 a3 d8 	or  %o2, 0x3d8, %o2	! 4002cbd8 <_Semaphore_Translate_core_mutex_return_code_+0x120>
                             "sectors per cluster: %d\n", fmt_params->sectors_per_cluster);
                                                                      
        if (fmt_params->fattype == FAT_FAT32) {                       
4000d830:	e8 0f bd de 	ldub  [ %fp + -546 ], %l4                      
4000d834:	b6 0d 20 ff 	and  %l4, 0xff, %i3                            
4000d838:	80 a6 e0 04 	cmp  %i3, 4                                    
4000d83c:	12 80 00 0a 	bne  4000d864 <msdos_format+0x44c>             
4000d840:	f4 07 bd ac 	ld  [ %fp + -596 ], %i2                        
          /* recommended: for FAT32, always set reserved sector count to 32 */
          fmt_params->rsvd_sector_cnt = 32;                           
4000d844:	82 10 20 20 	mov  0x20, %g1                                 
4000d848:	c2 27 bd b4 	st  %g1, [ %fp + -588 ]                        
          /* 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;                               
4000d84c:	82 10 20 06 	mov  6, %g1                                    
                                                                      
        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;                         
4000d850:	c0 27 bd c4 	clr  [ %fp + -572 ]                            
          /* location of copy of MBR */                               
          fmt_params->mbr_copy_sec = 6;                               
4000d854:	c2 27 bd d4 	st  %g1, [ %fp + -556 ]                        
          /* location of fsinfo sector */                             
          fmt_params->fsinfo_sec = 1;                                 
4000d858:	82 10 20 01 	mov  1, %g1                                    
4000d85c:	10 80 00 1a 	b  4000d8c4 <msdos_format+0x4ac>               
4000d860:	c2 27 bd d8 	st  %g1, [ %fp + -552 ]                        
                                                                      
        }                                                             
        else {                                                        
          /* recommended: for FAT12/FAT16, always set reserved sector count to 1 */
          fmt_params->rsvd_sector_cnt = 1;                            
4000d864:	82 10 20 01 	mov  1, %g1                                    
4000d868:	c2 27 bd b4 	st  %g1, [ %fp + -588 ]                        
          /* 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) &&                                     
4000d86c:	c2 07 bd 48 	ld  [ %fp + -696 ], %g1                        
4000d870:	80 a0 60 00 	cmp  %g1, 0                                    
4000d874:	02 80 00 07 	be  4000d890 <msdos_format+0x478>              
4000d878:	80 a6 e0 02 	cmp  %i3, 2                                    
              (rqdata->files_per_root_dir > 0)) {                     
4000d87c:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
          /* 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) &&                                     
4000d880:	80 a0 60 00 	cmp  %g1, 0                                    
4000d884:	32 80 00 07 	bne,a   4000d8a0 <msdos_format+0x488>          
4000d888:	c2 27 bd c4 	st  %g1, [ %fp + -572 ]                        
              (rqdata->files_per_root_dir > 0)) {                     
            fmt_params->files_per_root_dir = rqdata->files_per_root_dir;
          }                                                           
          else {                                                      
            if (fmt_params->fattype == FAT_FAT16) {                   
4000d88c:	80 a6 e0 02 	cmp  %i3, 2                                    
4000d890:	02 80 00 03 	be  4000d89c <msdos_format+0x484>              
4000d894:	82 10 22 00 	mov  0x200, %g1                                
              fmt_params->files_per_root_dir = 512;                   
            }                                                         
            else {                                                    
              fmt_params->files_per_root_dir = 64;                    
4000d898:	82 10 20 40 	mov  0x40, %g1                                 
4000d89c:	c2 27 bd c4 	st  %g1, [ %fp + -572 ]                        
            }                                                         
          }                                                           
          fmt_params->files_per_root_dir = (fmt_params->files_per_root_dir +
4000d8a0:	f0 07 bd c4 	ld  [ %fp + -572 ], %i0                        
                                           (2*fmt_params->bytes_per_sector/
4000d8a4:	93 2e a0 01 	sll  %i2, 1, %o1                               
            }                                                         
            else {                                                    
              fmt_params->files_per_root_dir = 64;                    
            }                                                         
          }                                                           
          fmt_params->files_per_root_dir = (fmt_params->files_per_root_dir +
4000d8a8:	b0 06 3f ff 	add  %i0, -1, %i0                              
                                           (2*fmt_params->bytes_per_sector/
4000d8ac:	93 32 60 05 	srl  %o1, 5, %o1                               
            }                                                         
            else {                                                    
              fmt_params->files_per_root_dir = 64;                    
            }                                                         
          }                                                           
          fmt_params->files_per_root_dir = (fmt_params->files_per_root_dir +
4000d8b0:	b0 06 00 09 	add  %i0, %o1, %i0                             
                                           (2*fmt_params->bytes_per_sector/
                                           FAT_DIRENTRY_SIZE-1));     
          fmt_params->files_per_root_dir -= (fmt_params->files_per_root_dir %
4000d8b4:	40 00 6f f1 	call  40029878 <.urem>                         
4000d8b8:	90 10 00 18 	mov  %i0, %o0                                  
4000d8bc:	90 26 00 08 	sub  %i0, %o0, %o0                             
4000d8c0:	d0 27 bd c4 	st  %o0, [ %fp + -572 ]                        
                                            (2*fmt_params->bytes_per_sector
                                            /FAT_DIRENTRY_SIZE));     
                                                                      
        }                                                             
        fmt_params->root_dir_sectors =                                
          (((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)      
4000d8c4:	d0 07 bd c4 	ld  [ %fp + -572 ], %o0                        
            + fmt_params->bytes_per_sector - 1)                       
4000d8c8:	88 06 bf ff 	add  %i2, -1, %g4                              
           / fmt_params->bytes_per_sector);                           
4000d8cc:	92 10 00 1a 	mov  %i2, %o1                                  
                                            /FAT_DIRENTRY_SIZE));     
                                                                      
        }                                                             
        fmt_params->root_dir_sectors =                                
          (((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)      
            + fmt_params->bytes_per_sector - 1)                       
4000d8d0:	c8 27 bd 54 	st  %g4, [ %fp + -684 ]                        
                                            (2*fmt_params->bytes_per_sector
                                            /FAT_DIRENTRY_SIZE));     
                                                                      
        }                                                             
        fmt_params->root_dir_sectors =                                
          (((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)      
4000d8d4:	91 2a 20 05 	sll  %o0, 5, %o0                               
            + fmt_params->bytes_per_sector - 1)                       
           / fmt_params->bytes_per_sector);                           
4000d8d8:	7f ff d3 c8 	call  400027f8 <.udiv>                         
4000d8dc:	90 01 00 08 	add  %g4, %o0, %o0                             
      if (ret_val == 0) {                                             
        /*                                                            
         * check values to get legal arrangement of FAT type and cluster count
         */                                                           
                                                                      
        ret_val = msdos_format_eval_sectors_per_cluster(fmt_params->fattype,
4000d8e0:	c2 07 bd b0 	ld  [ %fp + -592 ], %g1                        
4000d8e4:	c8 07 bd b4 	ld  [ %fp + -588 ], %g4                        
                                                                      
        }                                                             
        fmt_params->root_dir_sectors =                                
          (((fmt_params->files_per_root_dir * FAT_DIRENTRY_SIZE)      
            + fmt_params->bytes_per_sector - 1)                       
           / fmt_params->bytes_per_sector);                           
4000d8e8:	a2 10 00 08 	mov  %o0, %l1                                  
          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 =                                
4000d8ec:	d0 27 bd c8 	st  %o0, [ %fp + -568 ]                        
      if (ret_val == 0) {                                             
        /*                                                            
         * check values to get legal arrangement of FAT type and cluster count
         */                                                           
                                                                      
        ret_val = msdos_format_eval_sectors_per_cluster(fmt_params->fattype,
4000d8f0:	c2 27 bd 44 	st  %g1, [ %fp + -700 ]                        
4000d8f4:	c8 27 bd 50 	st  %g4, [ %fp + -688 ]                        
4000d8f8:	ea 0f bd dc 	ldub  [ %fp + -548 ], %l5                      
4000d8fc:	ec 07 bd b8 	ld  [ %fp + -584 ], %l6                        
4000d900:	e4 0f bd fc 	ldub  [ %fp + -516 ], %l2                      
  uint32_t fatdata_sect_cnt;                                          
  uint32_t fat_sectors_cnt;                                           
  /*                                                                  
   * ensure, that maximum cluster size (32KByte) is not exceeded      
   */                                                                 
  while (MS_BYTES_PER_CLUSTER_LIMIT / bytes_per_sector < sectors_per_cluster) {
4000d904:	11 00 00 20 	sethi  %hi(0x8000), %o0                        
4000d908:	7f ff d3 bc 	call  400027f8 <.udiv>                         
4000d90c:	92 10 00 1a 	mov  %i2, %o1                                  
4000d910:	80 a2 00 16 	cmp  %o0, %l6                                  
4000d914:	1a 80 00 04 	bcc  4000d924 <msdos_format+0x50c>             <== ALWAYS TAKEN
4000d918:	c2 07 bd 50 	ld  [ %fp + -688 ], %g1                        
    sectors_per_cluster /= 2;                                         
4000d91c:	10 bf ff fd 	b  4000d910 <msdos_format+0x4f8>               <== NOT EXECUTED
4000d920:	ad 35 a0 01 	srl  %l6, 1, %l6                               <== NOT EXECUTED
                                                                      
    sectors_per_fat = ((fat_capacity                                  
			+ (bytes_per_sector - 1))                                          
		       / bytes_per_sector);                                         
                                                                      
    fat_sectors_cnt = loc_align_object (sectors_per_fat * fat_num,    
4000d924:	aa 0d 60 ff 	and  %l5, 0xff, %l5                            
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000d928:	82 00 7f ff 	add  %g1, -1, %g1                              
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000d92c:	a4 0c a0 ff 	and  %l2, 0xff, %l2                            
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000d930:	c2 27 bd 3c 	st  %g1, [ %fp + -708 ]                        
4000d934:	ae 04 7f ff 	add  %l1, -1, %l7                              
                                                                      
    sectors_per_fat = ((fat_capacity                                  
			+ (bytes_per_sector - 1))                                          
		       / bytes_per_sector);                                         
                                                                      
    fat_sectors_cnt = loc_align_object (sectors_per_fat * fat_num,    
4000d938:	ea 27 bd 4c 	st  %l5, [ %fp + -692 ]                        
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000d93c:	80 a4 a0 00 	cmp  %l2, 0                                    
4000d940:	12 80 00 06 	bne  4000d958 <msdos_format+0x540>             
4000d944:	d0 07 bd 50 	ld  [ %fp + -688 ], %o0                        
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000d948:	c8 07 bd 3c 	ld  [ %fp + -708 ], %g4                        
4000d94c:	90 20 00 16 	neg  %l6, %o0                                  
4000d950:	84 01 00 16 	add  %g4, %l6, %g2                             
4000d954:	90 0a 00 02 	and  %o0, %g2, %o0                             
     * 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_sect_cnt = total_sector_cnt                               
4000d958:	c2 07 bd 44 	ld  [ %fp + -700 ], %g1                        
      - loc_align_object (rsvd_sector_cnt, sectors_per_cluster, skip_alignment);
    if (fattype == FAT_FAT12) {                                       
4000d95c:	80 a6 e0 01 	cmp  %i3, 1                                    
4000d960:	12 80 00 10 	bne  4000d9a0 <msdos_format+0x588>             
4000d964:	90 20 40 08 	sub  %g1, %o0, %o0                             
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000d968:	80 a4 a0 00 	cmp  %l2, 0                                    
4000d96c:	12 80 00 05 	bne  4000d980 <msdos_format+0x568>             
4000d970:	84 10 00 11 	mov  %l1, %g2                                  
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000d974:	84 20 00 16 	neg  %l6, %g2                                  
4000d978:	86 05 c0 16 	add  %l7, %l6, %g3                             
4000d97c:	84 08 80 03 	and  %g2, %g3, %g2                             
    fatdata_sect_cnt = total_sector_cnt                               
      - loc_align_object (rsvd_sector_cnt, sectors_per_cluster, skip_alignment);
    if (fattype == FAT_FAT12) {                                       
      fatdata_sect_cnt    = fatdata_sect_cnt                          
        - loc_align_object (root_dir_sector_cnt, sectors_per_cluster, skip_alignment);
      fatdata_cluster_cnt = fatdata_sect_cnt/sectors_per_cluster;     
4000d980:	90 22 00 02 	sub  %o0, %g2, %o0                             
4000d984:	7f ff d3 9d 	call  400027f8 <.udiv>                         
4000d988:	92 10 00 16 	mov  %l6, %o1                                  
4000d98c:	b0 10 00 08 	mov  %o0, %i0                                  
      fat_capacity        = fatdata_cluster_cnt * 3 / 2;              
4000d990:	91 2a 20 01 	sll  %o0, 1, %o0                               
4000d994:	90 02 00 18 	add  %o0, %i0, %o0                             
4000d998:	10 80 00 14 	b  4000d9e8 <msdos_format+0x5d0>               
4000d99c:	91 32 20 01 	srl  %o0, 1, %o0                               
    }                                                                 
    else if (fattype == FAT_FAT16) {                                  
4000d9a0:	80 a6 e0 02 	cmp  %i3, 2                                    
4000d9a4:	12 80 00 0d 	bne  4000d9d8 <msdos_format+0x5c0>             
4000d9a8:	80 a4 a0 00 	cmp  %l2, 0                                    
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000d9ac:	12 80 00 05 	bne  4000d9c0 <msdos_format+0x5a8>             
4000d9b0:	84 10 00 11 	mov  %l1, %g2                                  
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000d9b4:	84 20 00 16 	neg  %l6, %g2                                  
4000d9b8:	86 05 c0 16 	add  %l7, %l6, %g3                             
4000d9bc:	84 08 80 03 	and  %g2, %g3, %g2                             
      fat_capacity        = fatdata_cluster_cnt * 3 / 2;              
    }                                                                 
    else if (fattype == FAT_FAT16) {                                  
      fatdata_sect_cnt    = fatdata_sect_cnt                          
        - loc_align_object (root_dir_sector_cnt, sectors_per_cluster, skip_alignment);
      fatdata_cluster_cnt = fatdata_sect_cnt/sectors_per_cluster;     
4000d9c0:	90 22 00 02 	sub  %o0, %g2, %o0                             
4000d9c4:	7f ff d3 8d 	call  400027f8 <.udiv>                         
4000d9c8:	92 10 00 16 	mov  %l6, %o1                                  
4000d9cc:	b0 10 00 08 	mov  %o0, %i0                                  
      fat_capacity        = fatdata_cluster_cnt * 2;                  
4000d9d0:	10 80 00 06 	b  4000d9e8 <msdos_format+0x5d0>               
4000d9d4:	91 2a 20 01 	sll  %o0, 1, %o0                               
    }                                                                 
    else { /* FAT32 */                                                
      fatdata_cluster_cnt = fatdata_sect_cnt/sectors_per_cluster;     
4000d9d8:	7f ff d3 88 	call  400027f8 <.udiv>                         
4000d9dc:	92 10 00 16 	mov  %l6, %o1                                  
4000d9e0:	b0 10 00 08 	mov  %o0, %i0                                  
      fat_capacity        = fatdata_cluster_cnt * 4;                  
4000d9e4:	91 2a 20 02 	sll  %o0, 2, %o0                               
    }                                                                 
                                                                      
    sectors_per_fat = ((fat_capacity                                  
4000d9e8:	c8 07 bd 54 	ld  [ %fp + -684 ], %g4                        
4000d9ec:	92 10 00 1a 	mov  %i2, %o1                                  
4000d9f0:	7f ff d3 82 	call  400027f8 <.udiv>                         
4000d9f4:	90 02 00 04 	add  %o0, %g4, %o0                             
			+ (bytes_per_sector - 1))                                          
		       / bytes_per_sector);                                         
                                                                      
    fat_sectors_cnt = loc_align_object (sectors_per_fat * fat_num,    
4000d9f8:	7f ff d3 46 	call  40002710 <.umul>                         
4000d9fc:	d2 07 bd 4c 	ld  [ %fp + -692 ], %o1                        
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000da00:	80 a4 a0 00 	cmp  %l2, 0                                    
                                                                      
    sectors_per_fat = ((fat_capacity                                  
			+ (bytes_per_sector - 1))                                          
		       / bytes_per_sector);                                         
                                                                      
    fat_sectors_cnt = loc_align_object (sectors_per_fat * fat_num,    
4000da04:	a0 10 00 08 	mov  %o0, %l0                                  
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000da08:	12 80 00 05 	bne  4000da1c <msdos_format+0x604>             
4000da0c:	90 05 bf ff 	add  %l6, -1, %o0                              
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000da10:	a0 02 00 10 	add  %o0, %l0, %l0                             
4000da14:	84 20 00 16 	neg  %l6, %g2                                  
4000da18:	a0 0c 00 02 	and  %l0, %g2, %l0                             
                                        skip_alignment);              
                                                                      
    *data_cluster_cnt = (fatdata_cluster_cnt -                        
			((fat_sectors_cnt                                                  
			  + (sectors_per_cluster - 1))                                     
			 / sectors_per_cluster));                                          
4000da1c:	90 02 00 10 	add  %o0, %l0, %o0                             
4000da20:	7f ff d3 76 	call  400027f8 <.udiv>                         
4000da24:	92 10 00 16 	mov  %l6, %o1                                  
    /*                                                                
     * data cluster count too big? Then make clusters bigger          
     */                                                               
    if (((fattype == FAT_FAT12) && (*data_cluster_cnt > FAT_FAT12_MAX_CLN)) ||
4000da28:	80 a6 e0 01 	cmp  %i3, 1                                    
4000da2c:	12 80 00 07 	bne  4000da48 <msdos_format+0x630>             
4000da30:	b0 26 00 08 	sub  %i0, %o0, %i0                             
4000da34:	80 a6 2f f5 	cmp  %i0, 0xff5                                
4000da38:	08 80 00 10 	bleu  4000da78 <msdos_format+0x660>            
4000da3c:	aa 10 20 01 	mov  1, %l5                                    
        ((fattype == FAT_FAT16) && (*data_cluster_cnt > FAT_FAT16_MAX_CLN))) {
      sectors_per_cluster *= 2;                                       
4000da40:	10 80 00 0b 	b  4000da6c <msdos_format+0x654>               
4000da44:	ad 2d a0 01 	sll  %l6, 1, %l6                               
			  + (sectors_per_cluster - 1))                                     
			 / sectors_per_cluster));                                          
    /*                                                                
     * data cluster count too big? Then make clusters bigger          
     */                                                               
    if (((fattype == FAT_FAT12) && (*data_cluster_cnt > FAT_FAT12_MAX_CLN)) ||
4000da48:	80 a6 e0 02 	cmp  %i3, 2                                    
4000da4c:	12 80 00 11 	bne  4000da90 <msdos_format+0x678>             
4000da50:	aa 10 20 01 	mov  1, %l5                                    
        ((fattype == FAT_FAT16) && (*data_cluster_cnt > FAT_FAT16_MAX_CLN))) {
4000da54:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
4000da58:	82 10 63 f5 	or  %g1, 0x3f5, %g1	! fff5 <_TLS_Alignment+0xfff4>
4000da5c:	80 a6 00 01 	cmp  %i0, %g1                                  
4000da60:	08 80 00 0d 	bleu  4000da94 <msdos_format+0x67c>            
4000da64:	90 10 00 16 	mov  %l6, %o0                                  
      sectors_per_cluster *= 2;                                       
4000da68:	ad 2d a0 01 	sll  %l6, 1, %l6                               
      finished = true;                                                
    }                                                                 
    /*                                                                
     * when maximum cluster size is exceeded, we have invalid data, abort...
     */                                                               
    if (fattype == FAT_FAT12) {                                       
4000da6c:	80 a6 e0 01 	cmp  %i3, 1                                    
4000da70:	12 80 00 08 	bne  4000da90 <msdos_format+0x678>             
4000da74:	aa 10 20 00 	clr  %l5                                       
      if (MS_BYTES_PER_CLUSTER_LIMIT_FAT12 < (sectors_per_cluster * bytes_per_sector)) {
4000da78:	90 10 00 16 	mov  %l6, %o0                                  
4000da7c:	7f ff d3 25 	call  40002710 <.umul>                         
4000da80:	92 10 00 1a 	mov  %i2, %o1                                  
4000da84:	09 00 00 04 	sethi  %hi(0x1000), %g4                        
4000da88:	10 80 00 07 	b  4000daa4 <msdos_format+0x68c>               
4000da8c:	80 a2 00 04 	cmp  %o0, %g4                                  
        finished = true;                                              
      }                                                               
    } else if ((sectors_per_cluster * bytes_per_sector)               
4000da90:	90 10 00 16 	mov  %l6, %o0                                  
4000da94:	7f ff d3 1f 	call  40002710 <.umul>                         
4000da98:	92 10 00 1a 	mov  %i2, %o1                                  
4000da9c:	03 00 00 20 	sethi  %hi(0x8000), %g1                        
4000daa0:	80 a2 00 01 	cmp  %o0, %g1                                  
4000daa4:	38 80 00 06 	bgu,a   4000dabc <msdos_format+0x6a4>          
4000daa8:	d2 07 bd 4c 	ld  [ %fp + -692 ], %o1                        
	> MS_BYTES_PER_CLUSTER_LIMIT) {                                      
      finished = true;                                                
    }                                                                 
  } while (!finished);                                                
4000daac:	80 8d 60 ff 	btst  0xff, %l5                                
4000dab0:	02 bf ff a4 	be  4000d940 <msdos_format+0x528>              
4000dab4:	80 a4 a0 00 	cmp  %l2, 0                                    
                                                                      
  *sectors_per_cluster_adj = sectors_per_cluster;                     
  *sectors_per_fat_ptr     = fat_sectors_cnt / fat_num;               
4000dab8:	d2 07 bd 4c 	ld  [ %fp + -692 ], %o1                        
4000dabc:	7f ff d3 4f 	call  400027f8 <.udiv>                         
4000dac0:	90 10 00 10 	mov  %l0, %o0                                  
static uint8_t                                                        
msdos_get_fat_type( const uint32_t bytes_per_sector,                  
                    const uint32_t sectors_per_cluster,               
                    const uint32_t number_of_clusters )               
{                                                                     
  uint32_t ms_sectors_per_cluster_limit_FAT12 =                       
4000dac4:	09 10 00 b3 	sethi  %hi(0x4002cc00), %g4                    
      finished = true;                                                
    }                                                                 
  } while (!finished);                                                
                                                                      
  *sectors_per_cluster_adj = sectors_per_cluster;                     
  *sectors_per_fat_ptr     = fat_sectors_cnt / fat_num;               
4000dac8:	d0 27 bd bc 	st  %o0, [ %fp + -580 ]                        
static uint8_t                                                        
msdos_get_fat_type( const uint32_t bytes_per_sector,                  
                    const uint32_t sectors_per_cluster,               
                    const uint32_t number_of_clusters )               
{                                                                     
  uint32_t ms_sectors_per_cluster_limit_FAT12 =                       
4000dacc:	d0 01 20 98 	ld  [ %g4 + 0x98 ], %o0                        
                                                        fmt_params->sectors_per_cluster,
                                                        fmt_params->skip_alignment,
                                                        §ors_per_cluster_adj,
                                                        &fmt_params->sectors_per_fat,
                                                        &data_clusters_cnt);
        fmt_params->sectors_per_cluster = sectors_per_cluster_adj;    
4000dad0:	ec 27 bd b8 	st  %l6, [ %fp + -584 ]                        
static uint8_t                                                        
msdos_get_fat_type( const uint32_t bytes_per_sector,                  
                    const uint32_t sectors_per_cluster,               
                    const uint32_t number_of_clusters )               
{                                                                     
  uint32_t ms_sectors_per_cluster_limit_FAT12 =                       
4000dad4:	7f ff d3 49 	call  400027f8 <.udiv>                         
4000dad8:	92 10 00 1a 	mov  %i2, %o1                                  
    ( MS_BYTES_PER_CLUSTER_LIMIT_FAT12 +1 ) / bytes_per_sector;       
  uint32_t ms_sectors_per_cluster_limit_FAT16 =                       
    ( MS_BYTES_PER_CLUSTER_LIMIT +1 ) / bytes_per_sector;             
  uint8_t fattype = FAT_FAT32;                                        
                                                                      
  if (   number_of_clusters < FAT_FAT12_MAX_CLN                       
4000dadc:	80 a2 00 16 	cmp  %o0, %l6                                  
4000dae0:	2a 80 00 06 	bcs,a   4000daf8 <msdos_format+0x6e0>          
4000dae4:	11 00 00 20 	sethi  %hi(0x8000), %o0                        
4000dae8:	80 a6 2f f4 	cmp  %i0, 0xff4                                
4000daec:	08 80 00 0f 	bleu  4000db28 <msdos_format+0x710>            
4000daf0:	84 10 20 01 	mov  1, %g2                                    
                    const uint32_t sectors_per_cluster,               
                    const uint32_t number_of_clusters )               
{                                                                     
  uint32_t ms_sectors_per_cluster_limit_FAT12 =                       
    ( MS_BYTES_PER_CLUSTER_LIMIT_FAT12 +1 ) / bytes_per_sector;       
  uint32_t ms_sectors_per_cluster_limit_FAT16 =                       
4000daf4:	11 00 00 20 	sethi  %hi(0x8000), %o0                        
4000daf8:	92 10 00 1a 	mov  %i2, %o1                                  
4000dafc:	7f ff d3 3f 	call  400027f8 <.udiv>                         
4000db00:	90 12 20 01 	or  %o0, 1, %o0                                
                                                                      
  if (   number_of_clusters < FAT_FAT12_MAX_CLN                       
      && sectors_per_cluster <= ms_sectors_per_cluster_limit_FAT12 ) {
    fattype = FAT_FAT12;                                              
  }                                                                   
  else if (   number_of_clusters < FAT_FAT16_MAX_CLN                  
4000db04:	80 a2 00 16 	cmp  %o0, %l6                                  
4000db08:	2a 80 00 08 	bcs,a   4000db28 <msdos_format+0x710>          
4000db0c:	84 10 20 04 	mov  4, %g2                                    
4000db10:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
4000db14:	82 10 63 f4 	or  %g1, 0x3f4, %g1	! fff4 <_TLS_Alignment+0xfff3>
4000db18:	80 a0 40 18 	cmp  %g1, %i0                                  
4000db1c:	1a 80 00 03 	bcc  4000db28 <msdos_format+0x710>             
4000db20:	84 10 20 02 	mov  2, %g2                                    
{                                                                     
  uint32_t ms_sectors_per_cluster_limit_FAT12 =                       
    ( MS_BYTES_PER_CLUSTER_LIMIT_FAT12 +1 ) / bytes_per_sector;       
  uint32_t ms_sectors_per_cluster_limit_FAT16 =                       
    ( MS_BYTES_PER_CLUSTER_LIMIT +1 ) / bytes_per_sector;             
  uint8_t fattype = FAT_FAT32;                                        
4000db24:	84 10 20 04 	mov  4, %g2                                    
          fmt_params->fattype = msdos_get_fat_type(                   
            fmt_params->bytes_per_sector,                             
            fmt_params->sectors_per_cluster,                          
            data_clusters_cnt );                                      
          /* Correct sectors per cluster to the fat type specific default value */
          if (fat_type != fmt_params->fattype) {                      
4000db28:	82 08 a0 ff 	and  %g2, 0xff, %g1                            
4000db2c:	80 a6 c0 01 	cmp  %i3, %g1                                  
4000db30:	02 80 00 18 	be  4000db90 <msdos_format+0x778>              
4000db34:	c4 2f bd de 	stb  %g2, [ %fp + -546 ]                       
msdos_set_default_sectors_per_cluster_for_fattype(                    
  msdos_format_param_t *fmt_params,                                   
  const uint64_t        total_size )                                  
{                                                                     
  if (   fmt_params->fattype == FAT_FAT12                             
      || fmt_params->fattype == FAT_FAT16 ) {                         
4000db38:	84 00 bf ff 	add  %g2, -1, %g2                              
  }                                                                   
  else {                                                              
    uint32_t gigs = ( total_size + ONE_GB ) / ONE_GB;                 
    int b;                                                            
    /* scale with the size of disk... */                              
    for ( b = 31; b > 0; b-- ) {                                      
4000db3c:	82 10 20 1f 	mov  0x1f, %g1                                 
static void                                                           
msdos_set_default_sectors_per_cluster_for_fattype(                    
  msdos_format_param_t *fmt_params,                                   
  const uint64_t        total_size )                                  
{                                                                     
  if (   fmt_params->fattype == FAT_FAT12                             
4000db40:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
4000db44:	80 a0 a0 01 	cmp  %g2, 1                                    
4000db48:	18 80 00 06 	bgu  4000db60 <msdos_format+0x748>             
4000db4c:	86 10 20 01 	mov  1, %g3                                    
      || fmt_params->fattype == FAT_FAT16 ) {                         
    /* start trying with small clusters */                            
    fmt_params->sectors_per_cluster = 2;                              
4000db50:	10 80 00 0b 	b  4000db7c <msdos_format+0x764>               
4000db54:	82 10 20 02 	mov  2, %g1                                    
  }                                                                   
  else {                                                              
    uint32_t gigs = ( total_size + ONE_GB ) / ONE_GB;                 
    int b;                                                            
    /* scale with the size of disk... */                              
    for ( b = 31; b > 0; b-- ) {                                      
4000db58:	02 80 00 08 	be  4000db78 <msdos_format+0x760>              <== NEVER TAKEN
4000db5c:	84 10 20 01 	mov  1, %g2                                    
      if ( (gigs & ( 1 << b) ) != 0 )                                 
4000db60:	c8 07 bd 40 	ld  [ %fp + -704 ], %g4                        
4000db64:	85 28 c0 01 	sll  %g3, %g1, %g2                             
4000db68:	80 88 80 04 	btst  %g2, %g4                                 
4000db6c:	22 bf ff fb 	be,a   4000db58 <msdos_format+0x740>           
4000db70:	82 80 7f ff 	addcc  %g1, -1, %g1                            
        break;                                                        
    }                                                                 
    fmt_params->sectors_per_cluster = 1 << b;                         
4000db74:	84 10 20 01 	mov  1, %g2                                    
4000db78:	83 28 80 01 	sll  %g2, %g1, %g1                             
4000db7c:	c2 27 bd b8 	st  %g1, [ %fp + -584 ]                        
            data_clusters_cnt );                                      
          /* Correct sectors per cluster to the fat type specific default value */
          if (fat_type != fmt_params->fattype) {                      
            msdos_set_default_sectors_per_cluster_for_fattype( fmt_params,
                                                               total_size );
            ret_val = msdos_set_sectors_per_cluster_from_request( rqdata,
4000db80:	90 10 00 19 	mov  %i1, %o0                                  
4000db84:	7f ff fe 01 	call  4000d388 <msdos_set_sectors_per_cluster_from_request>
4000db88:	92 07 bd ac 	add  %fp, -596, %o1                            
4000db8c:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                  fmt_params );
          }                                                           
        }                                                             
        if (fat_type != fmt_params->fattype && 1 < iteration_cnt) {   
4000db90:	c2 0f bd de 	ldub  [ %fp + -546 ], %g1                      
4000db94:	80 a6 c0 01 	cmp  %i3, %g1                                  
4000db98:	02 80 00 07 	be  4000dbb4 <msdos_format+0x79c>              
4000db9c:	82 0c e0 ff 	and  %l3, 0xff, %g1                            
4000dba0:	80 a0 60 01 	cmp  %g1, 1                                    
4000dba4:	08 80 00 04 	bleu  4000dbb4 <msdos_format+0x79c>            
4000dba8:	c2 07 bd b0 	ld  [ %fp + -592 ], %g1                        
          --fmt_params->totl_sector_cnt;                              
4000dbac:	82 00 7f ff 	add  %g1, -1, %g1                              
4000dbb0:	c2 27 bd b0 	st  %g1, [ %fp + -592 ]                        
        }                                                             
                                                                      
      }                                                               
                                                                      
      ++iteration_cnt;                                                
4000dbb4:	10 bf ff 0a 	b  4000d7dc <msdos_format+0x3c4>               
4000dbb8:	a6 04 e0 01 	inc  %l3                                       
4000dbbc:	f6 07 bd b8 	ld  [ %fp + -584 ], %i3                        
    ret_val = -1;                                                     
  }                                                                   
                                                                      
  if (0 == ret_val)                                                   
  {                                                                   
    if (FAT_FAT32 != fmt_params->fattype)                             
4000dbc0:	80 a0 60 04 	cmp  %g1, 4                                    
4000dbc4:	02 80 00 0d 	be  4000dbf8 <msdos_format+0x7e0>              
4000dbc8:	f4 0f bd fc 	ldub  [ %fp + -516 ], %i2                      
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000dbcc:	80 8e a0 ff 	btst  0xff, %i2                                
4000dbd0:	12 80 00 06 	bne  4000dbe8 <msdos_format+0x7d0>             
4000dbd4:	d0 07 bd c8 	ld  [ %fp + -568 ], %o0                        
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000dbd8:	90 02 00 1b 	add  %o0, %i3, %o0                             
4000dbdc:	82 20 00 1b 	neg  %i3, %g1                                  
4000dbe0:	90 02 3f ff 	add  %o0, -1, %o0                              
4000dbe4:	90 0a 00 01 	and  %o0, %g1, %o0                             
    if (FAT_FAT32 != fmt_params->fattype)                             
    {                                                                 
      fmt_params->files_per_root_dir = loc_align_object (fmt_params->root_dir_sectors,
                                                         fmt_params->sectors_per_cluster,
                                                         fmt_params->skip_alignment)
                                       * (fmt_params->bytes_per_sector / FAT_DIRENTRY_SIZE);
4000dbe8:	d2 07 bd ac 	ld  [ %fp + -596 ], %o1                        
4000dbec:	7f ff d2 c9 	call  40002710 <.umul>                         
4000dbf0:	93 32 60 05 	srl  %o1, 5, %o1                               
                                                                      
  if (0 == ret_val)                                                   
  {                                                                   
    if (FAT_FAT32 != fmt_params->fattype)                             
    {                                                                 
      fmt_params->files_per_root_dir = loc_align_object (fmt_params->root_dir_sectors,
4000dbf4:	d0 27 bd c4 	st  %o0, [ %fp + -572 ]                        
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000dbf8:	80 8e a0 ff 	btst  0xff, %i2                                
4000dbfc:	12 80 00 06 	bne  4000dc14 <msdos_format+0x7fc>             
4000dc00:	c2 07 bd b4 	ld  [ %fp + -588 ], %g1                        
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000dc04:	82 00 40 1b 	add  %g1, %i3, %g1                             
4000dc08:	b6 20 00 1b 	neg  %i3                                       
4000dc0c:	82 00 7f ff 	add  %g1, -1, %g1                              
4000dc10:	82 08 40 1b 	and  %g1, %i3, %g1                             
                                                                      
  /*                                                                  
   * determine media code                                             
   */                                                                 
  if (ret_val == 0) {                                                 
    if ((rqdata != NULL) &&                                           
4000dc14:	80 a6 60 00 	cmp  %i1, 0                                    
4000dc18:	02 80 00 17 	be  4000dc74 <msdos_format+0x85c>              
4000dc1c:	c2 27 bd b4 	st  %g1, [ %fp + -588 ]                        
	(rqdata->media != 0)) {                                              
4000dc20:	f6 0e 60 14 	ldub  [ %i1 + 0x14 ], %i3                      
                                                                      
  /*                                                                  
   * determine media code                                             
   */                                                                 
  if (ret_val == 0) {                                                 
    if ((rqdata != NULL) &&                                           
4000dc24:	b4 8e e0 ff 	andcc  %i3, 0xff, %i2                          
4000dc28:	02 80 00 14 	be  4000dc78 <msdos_format+0x860>              
4000dc2c:	82 10 3f f8 	mov  -8, %g1                                   
	(rqdata->media != 0)) {                                              
      const char valid_media_codes[] =                                
4000dc30:	94 10 20 09 	mov  9, %o2                                    
4000dc34:	90 07 be 00 	add  %fp, -512, %o0                            
4000dc38:	13 10 00 b3 	sethi  %hi(0x4002cc00), %o1                    
4000dc3c:	40 00 3c 69 	call  4001cde0 <memcpy>                        
4000dc40:	92 12 60 88 	or  %o1, 0x88, %o1	! 4002cc88 <_Semaphore_Translate_core_mutex_return_code_+0x1d0>
	{0xF0,0xF8,0xF9,0xFA,0xFB,0xFC,0xFD,0xFE,0xFF};                      
      if (NULL==memchr(valid_media_codes,                             
4000dc44:	90 07 be 00 	add  %fp, -512, %o0                            
4000dc48:	92 10 00 1a 	mov  %i2, %o1                                  
4000dc4c:	40 00 3b f6 	call  4001cc24 <memchr>                        
4000dc50:	94 10 20 09 	mov  9, %o2                                    
4000dc54:	80 a2 20 00 	cmp  %o0, 0                                    
4000dc58:	32 bf fe 34 	bne,a   4000d528 <msdos_format+0x110>          <== NEVER TAKEN
4000dc5c:	f6 2f bd dd 	stb  %i3, [ %fp + -547 ]                       <== NOT EXECUTED
		       rqdata->media,                                               
		       sizeof(valid_media_codes))) {                                
	ret_val = -1;                                                        
	errno = EINVAL;                                                      
4000dc60:	40 00 3a 0b 	call  4001c48c <__errno>                       
4000dc64:	ba 10 3f ff 	mov  -1, %i5                                   
4000dc68:	82 10 20 16 	mov  0x16, %g1                                 
4000dc6c:	10 bf fe 2f 	b  4000d528 <msdos_format+0x110>               
4000dc70:	c2 22 00 00 	st  %g1, [ %o0 ]                               
      else {                                                          
	fmt_params->media_code = rqdata->media;                              
      }                                                               
    }                                                                 
    else {                                                            
      fmt_params->media_code = FAT_BR_MEDIA_FIXED;                    
4000dc74:	82 10 3f f8 	mov  -8, %g1                                   
4000dc78:	10 bf fe 2c 	b  4000d528 <msdos_format+0x110>               
4000dc7c:	c2 2f bd dd 	stb  %g1, [ %fp + -547 ]                       
    /*                                                                
     * for FAT32: root directory is in cluster 2                      
     */                                                               
    fmt_params->root_dir_start_sec =                                  
      fmt_params->rsvd_sector_cnt                                     
      + (fmt_params-> fat_num*fmt_params->sectors_per_fat);           
4000dc80:	7f ff d2 a4 	call  40002710 <.umul>                         
4000dc84:	01 00 00 00 	nop                                            
    fmt_params->root_dir_fmt_sec_cnt = fmt_params->sectors_per_cluster;
4000dc88:	c2 07 bd b8 	ld  [ %fp + -584 ], %g1                        
    /*                                                                
     * for FAT32: root directory is in cluster 2                      
     */                                                               
    fmt_params->root_dir_start_sec =                                  
      fmt_params->rsvd_sector_cnt                                     
      + (fmt_params-> fat_num*fmt_params->sectors_per_fat);           
4000dc8c:	90 02 00 1b 	add  %o0, %i3, %o0                             
    fmt_params->root_dir_fmt_sec_cnt = fmt_params->sectors_per_cluster;
4000dc90:	c2 27 bd d0 	st  %g1, [ %fp + -560 ]                        
  }                                                                   
  else {                                                              
    /*                                                                
     * for FAT32: root directory is in cluster 2                      
     */                                                               
    fmt_params->root_dir_start_sec =                                  
4000dc94:	10 bf fe 31 	b  4000d558 <msdos_format+0x140>               
4000dc98:	d0 27 bd cc 	st  %o0, [ %fp + -564 ]                        
  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) &&                                           
4000dc9c:	02 80 00 07 	be  4000dcb8 <msdos_format+0x8a0>              
4000dca0:	03 10 00 b2 	sethi  %hi(0x4002c800), %g1                    
	(rqdata->OEMName != NULL)) {                                         
4000dca4:	c2 06 40 00 	ld  [ %i1 ], %g1                               
  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) &&                                           
4000dca8:	80 a0 60 00 	cmp  %g1, 0                                    
4000dcac:	12 80 00 05 	bne  4000dcc0 <msdos_format+0x8a8>             
4000dcb0:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
   */                                                                 
  if (ret_val == 0) {                                                 
      const char *from;                                               
      char        *to = fmt_params->OEMName;                          
      int          cnt;                                               
      from = "RTEMS"; /* default: make "from" point to OS Name */     
4000dcb4:	03 10 00 b2 	sethi  %hi(0x4002c800), %g1                    
4000dcb8:	82 10 63 40 	or  %g1, 0x340, %g1	! 4002cb40 <_Semaphore_Translate_core_mutex_return_code_+0x88>
      from = rqdata->OEMName;                                         
    }                                                                 
    for (cnt = 0;                                                     
	 cnt < (sizeof(fmt_params->OEMName)-1);                              
	 cnt++) {                                                            
      if (isprint((unsigned char)*from)) {                            
4000dcbc:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
4000dcc0:	f0 01 22 0c 	ld  [ %g4 + 0x20c ], %i0	! 4002de0c <__ctype_ptr__>
4000dcc4:	86 10 20 09 	mov  9, %g3                                    
4000dcc8:	84 07 bd df 	add  %fp, -545, %g2                            
4000dccc:	b4 10 00 04 	mov  %g4, %i2                                  
	/*                                                                   
	 * non-printable character in given name, so keep stuck              
	 * at that character and replace all following characters            
	 * with a ' '                                                        
	 */                                                                  
	*to++=' ';                                                           
4000dcd0:	9e 10 20 20 	mov  0x20, %o7                                 
      from = "RTEMS"; /* default: make "from" point to OS Name */     
    if ((rqdata != NULL) &&                                           
	(rqdata->OEMName != NULL)) {                                         
      from = rqdata->OEMName;                                         
    }                                                                 
    for (cnt = 0;                                                     
4000dcd4:	86 80 ff ff 	addcc  %g3, -1, %g3                            
4000dcd8:	02 80 00 10 	be  4000dd18 <msdos_format+0x900>              
4000dcdc:	80 a6 60 00 	cmp  %i1, 0                                    
	 cnt < (sizeof(fmt_params->OEMName)-1);                              
	 cnt++) {                                                            
      if (isprint((unsigned char)*from)) {                            
4000dce0:	f6 08 40 00 	ldub  [ %g1 ], %i3                             
4000dce4:	88 0e e0 ff 	and  %i3, 0xff, %g4                            
4000dce8:	88 06 00 04 	add  %i0, %g4, %g4                             
4000dcec:	c8 49 20 01 	ldsb  [ %g4 + 1 ], %g4                         
4000dcf0:	80 89 20 97 	btst  0x97, %g4                                
4000dcf4:	02 80 00 05 	be  4000dd08 <msdos_format+0x8f0>              
4000dcf8:	88 00 a0 01 	add  %g2, 1, %g4                               
	*to++ = *from++;                                                     
4000dcfc:	82 00 60 01 	inc  %g1                                       
4000dd00:	10 80 00 03 	b  4000dd0c <msdos_format+0x8f4>               
4000dd04:	f6 28 80 00 	stb  %i3, [ %g2 ]                              
	/*                                                                   
	 * non-printable character in given name, so keep stuck              
	 * at that character and replace all following characters            
	 * with a ' '                                                        
	 */                                                                  
	*to++=' ';                                                           
4000dd08:	de 28 80 00 	stb  %o7, [ %g2 ]                              
4000dd0c:	84 10 00 04 	mov  %g4, %g2                                  
      }                                                               
      *to = '\0';                                                     
4000dd10:	10 bf ff f1 	b  4000dcd4 <msdos_format+0x8bc>               
4000dd14:	c0 29 00 00 	clrb  [ %g4 ]                                  
  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) &&                                           
4000dd18:	02 80 00 09 	be  4000dd3c <msdos_format+0x924>              
4000dd1c:	03 10 00 b2 	sethi  %hi(0x4002c800), %g1                    
	(rqdata->VolLabel != NULL)) {                                        
4000dd20:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
  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) &&                                           
4000dd24:	80 a0 60 00 	cmp  %g1, 0                                    
4000dd28:	02 80 00 04 	be  4000dd38 <msdos_format+0x920>              
4000dd2c:	84 10 20 01 	mov  1, %g2                                    
	(rqdata->VolLabel != NULL)) {                                        
      from = rqdata->VolLabel;                                        
      fmt_params->VolLabel_present = true;                            
4000dd30:	10 80 00 04 	b  4000dd40 <msdos_format+0x928>               
4000dd34:	c4 2f bd f4 	stb  %g2, [ %fp + -524 ]                       
   */                                                                 
  if (ret_val == 0) {                                                 
      const char *from;                                               
      char        *to = fmt_params->VolLabel;                         
      int          cnt;                                               
      from = ""; /* default: make "from" point to empty string */     
4000dd38:	03 10 00 b2 	sethi  %hi(0x4002c800), %g1                    
4000dd3c:	82 10 63 f0 	or  %g1, 0x3f0, %g1	! 4002cbf0 <_Semaphore_Translate_core_mutex_return_code_+0x138>
      fmt_params->VolLabel_present = true;                            
    }                                                                 
    for (cnt = 0;                                                     
	 cnt < (sizeof(fmt_params->VolLabel)-1);                             
	 cnt++) {                                                            
      if (isprint((unsigned char)*from)) {                            
4000dd40:	f4 06 a2 0c 	ld  [ %i2 + 0x20c ], %i2                       
4000dd44:	86 10 20 0c 	mov  0xc, %g3                                  
4000dd48:	84 07 bd e8 	add  %fp, -536, %g2                            
	/*                                                                   
	 * non-printable character in given name, so keep stuck              
	 * at that character and replace all following characters            
	 * with a ' '                                                        
	 */                                                                  
	*to++=' ';                                                           
4000dd4c:	b0 10 20 20 	mov  0x20, %i0                                 
    if ((rqdata != NULL) &&                                           
	(rqdata->VolLabel != NULL)) {                                        
      from = rqdata->VolLabel;                                        
      fmt_params->VolLabel_present = true;                            
    }                                                                 
    for (cnt = 0;                                                     
4000dd50:	86 80 ff ff 	addcc  %g3, -1, %g3                            
4000dd54:	02 80 00 10 	be  4000dd94 <msdos_format+0x97c>              
4000dd58:	01 00 00 00 	nop                                            
	 cnt < (sizeof(fmt_params->VolLabel)-1);                             
	 cnt++) {                                                            
      if (isprint((unsigned char)*from)) {                            
4000dd5c:	f6 08 40 00 	ldub  [ %g1 ], %i3                             
4000dd60:	88 0e e0 ff 	and  %i3, 0xff, %g4                            
4000dd64:	88 06 80 04 	add  %i2, %g4, %g4                             
4000dd68:	c8 49 20 01 	ldsb  [ %g4 + 1 ], %g4                         
4000dd6c:	80 89 20 97 	btst  0x97, %g4                                
4000dd70:	02 80 00 05 	be  4000dd84 <msdos_format+0x96c>              
4000dd74:	88 00 a0 01 	add  %g2, 1, %g4                               
	*to++ = *from++;                                                     
4000dd78:	82 00 60 01 	inc  %g1                                       
4000dd7c:	10 80 00 03 	b  4000dd88 <msdos_format+0x970>               
4000dd80:	f6 28 80 00 	stb  %i3, [ %g2 ]                              
	/*                                                                   
	 * non-printable character in given name, so keep stuck              
	 * at that character and replace all following characters            
	 * with a ' '                                                        
	 */                                                                  
	*to++=' ';                                                           
4000dd84:	f0 28 80 00 	stb  %i0, [ %g2 ]                              
4000dd88:	84 10 00 04 	mov  %g4, %g2                                  
      }                                                               
      *to = '\0';                                                     
4000dd8c:	10 bf ff f1 	b  4000dd50 <msdos_format+0x938>               
4000dd90:	c0 29 00 00 	clrb  [ %g4 ]                                  
{                                                                     
  int ret_val = 0;                                                    
  int rc;                                                             
  struct timeval time_value;                                          
                                                                      
  rc = rtems_clock_get_tod_timeval(&time_value);                      
4000dd94:	40 00 20 e2 	call  4001611c <rtems_clock_get_tod_timeval>   
4000dd98:	90 07 be 00 	add  %fp, -512, %o0                            
  if (rc == RTEMS_SUCCESSFUL) {                                       
4000dd9c:	80 a2 20 00 	cmp  %o0, 0                                    
4000dda0:	12 80 00 05 	bne  4000ddb4 <msdos_format+0x99c>             <== ALWAYS TAKEN
4000dda4:	c2 07 be 00 	ld  [ %fp + -512 ], %g1                        
    *volid_ptr = time_value.tv_sec + time_value.tv_sec;               
4000dda8:	83 28 60 01 	sll  %g1, 1, %g1                               <== NOT EXECUTED
4000ddac:	10 bf fd ee 	b  4000d564 <msdos_format+0x14c>               <== NOT EXECUTED
4000ddb0:	c2 27 bd f8 	st  %g1, [ %fp + -520 ]                        <== NOT EXECUTED
  }                                                                   
  else {                                                              
    *volid_ptr = rand();                                              
4000ddb4:	40 00 3e dd 	call  4001d928 <rand>                          
4000ddb8:	01 00 00 00 	nop                                            
4000ddbc:	10 bf fd ea 	b  4000d564 <msdos_format+0x14c>               
4000ddc0:	d0 27 bd f8 	st  %o0, [ %fp + -520 ]                        
    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,       
4000ddc4:	90 10 00 19 	mov  %i1, %o0                                  
4000ddc8:	92 10 20 02 	mov  2, %o1                                    
4000ddcc:	15 10 00 b3 	sethi  %hi(0x4002cc00), %o2                    
4000ddd0:	7f ff fc ee 	call  4000d188 <msdos_format_printf>           
4000ddd4:	94 12 a0 10 	or  %o2, 0x10, %o2	! 4002cc10 <_Semaphore_Translate_core_mutex_return_code_+0x158>
{                                                                     
  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) {                        
4000ddd8:	fa 07 bd b0 	ld  [ %fp + -592 ], %i5                        
4000dddc:	03 00 00 3f 	sethi  %hi(0xfc00), %g1                        
4000dde0:	82 10 63 ff 	or  %g1, 0x3ff, %g1	! ffff <_TLS_Alignment+0xfffe>
4000dde4:	80 a7 40 01 	cmp  %i5, %g1                                  
4000dde8:	18 80 00 04 	bgu  4000ddf8 <msdos_format+0x9e0>             
4000ddec:	b6 10 20 00 	clr  %i3                                       
4000ddf0:	b6 10 00 1d 	mov  %i5, %i3                                  
| Return Value:                                                             |
|    0, if success, -1 and errno if failed                                  |
\*=========================================================================*/
{                                                                     
  uint32_t  total_sectors_num16 = 0;                                  
  uint32_t  total_sectors_num32 = 0;                                  
4000ddf4:	ba 10 20 00 	clr  %i5                                       
   * 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);                     
4000ddf8:	92 10 20 00 	clr  %o1                                       
4000ddfc:	94 10 21 be 	mov  0x1be, %o2                                
4000de00:	40 00 3c 37 	call  4001cedc <memset>                        
4000de04:	90 07 be 00 	add  %fp, -512, %o0                            
   * with 0xEB,....                                                   
   */                                                                 
  /*                                                                  
   * fill OEMName                                                     
   */                                                                 
  memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),                                
4000de08:	90 07 be 03 	add  %fp, -509, %o0                            
   * 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,
4000de0c:	c0 37 bf fe 	clrh  [ %fp + -2 ]                             
   * with 0xEB,....                                                   
   */                                                                 
  /*                                                                  
   * fill OEMName                                                     
   */                                                                 
  memcpy(FAT_GET_ADDR_BR_OEMNAME(mbr),                                
4000de10:	92 07 bd df 	add  %fp, -545, %o1                            
4000de14:	40 00 3b f3 	call  4001cde0 <memcpy>                        
4000de18:	94 10 20 08 	mov  8, %o2                                    
	 fmt_params->OEMName,                                                
	 FAT_BR_OEMNAME_SIZE);                                               
  FAT_SET_BR_BYTES_PER_SECTOR(mbr    , fmt_params->bytes_per_sector); 
4000de1c:	c2 07 bd ac 	ld  [ %fp + -596 ], %g1                        
                                                                      
  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);          
4000de20:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
   * 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); 
4000de24:	c2 2f be 0b 	stb  %g1, [ %fp + -501 ]                       
4000de28:	83 30 60 08 	srl  %g1, 8, %g1                               
4000de2c:	c2 2f be 0c 	stb  %g1, [ %fp + -500 ]                       
  FAT_SET_BR_SECTORS_PER_CLUSTER(mbr , fmt_params->sectors_per_cluster);
4000de30:	c2 07 bd b8 	ld  [ %fp + -584 ], %g1                        
                                                                      
  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);          
4000de34:	84 10 a3 ff 	or  %g2, 0x3ff, %g2                            
   */                                                                 
  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);
4000de38:	c2 2f be 0d 	stb  %g1, [ %fp + -499 ]                       
  FAT_SET_BR_RESERVED_SECTORS_NUM(mbr, fmt_params->rsvd_sector_cnt);  
4000de3c:	c2 07 bd b4 	ld  [ %fp + -588 ], %g1                        
                                                                      
  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);          
4000de40:	fa 2f be 20 	stb  %i5, [ %fp + -480 ]                       
  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);  
4000de44:	c2 2f be 0e 	stb  %g1, [ %fp + -498 ]                       
4000de48:	83 30 60 08 	srl  %g1, 8, %g1                               
4000de4c:	c2 2f be 0f 	stb  %g1, [ %fp + -497 ]                       
                                                                      
  /* 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);
4000de50:	c2 07 bd c4 	ld  [ %fp + -572 ], %g1                        
  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 */
4000de54:	88 10 20 02 	mov  2, %g4                                    
  FAT_SET_BR_FILES_PER_ROOT_DIR(mbr  , fmt_params->files_per_root_dir);
4000de58:	c2 2f be 11 	stb  %g1, [ %fp + -495 ]                       
4000de5c:	83 30 60 08 	srl  %g1, 8, %g1                               
4000de60:	c2 2f be 12 	stb  %g1, [ %fp + -494 ]                       
  FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);          
  FAT_SET_BR_MEDIA(mbr               , fmt_params->media_code);       
4000de64:	c2 0f bd dd 	ldub  [ %fp + -547 ], %g1                      
  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);          
4000de68:	f6 2f be 13 	stb  %i3, [ %fp + -493 ]                       
  FAT_SET_BR_MEDIA(mbr               , fmt_params->media_code);       
4000de6c:	c2 2f be 15 	stb  %g1, [ %fp + -491 ]                       
                                                                      
  FAT_SET_BR_SECTORS_PER_TRACK(mbr   , 255); /* only needed for INT13... */
4000de70:	82 10 3f ff 	mov  -1, %g1                                   
4000de74:	c2 2f be 18 	stb  %g1, [ %fp + -488 ]                       
  FAT_SET_BR_NUMBER_OF_HEADS(mbr     , 6);   /* only needed for INT13... */
4000de78:	82 10 20 06 	mov  6, %g1                                    
4000de7c:	c2 2f be 1a 	stb  %g1, [ %fp + -486 ]                       
  FAT_SET_BR_HIDDEN_SECTORS(mbr      , 1);   /* only needed for INT13... */
                                                                      
  FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);          
4000de80:	82 0f 40 02 	and  %i5, %g2, %g1                             
4000de84:	83 30 60 08 	srl  %g1, 8, %g1                               
4000de88:	c2 2f be 21 	stb  %g1, [ %fp + -479 ]                       
4000de8c:	83 37 60 10 	srl  %i5, 0x10, %g1                            
4000de90:	bb 37 60 18 	srl  %i5, 0x18, %i5                            
4000de94:	fa 2f be 23 	stb  %i5, [ %fp + -477 ]                       
  if (fmt_params->fattype != FAT_FAT32) {                             
4000de98:	fa 0f bd de 	ldub  [ %fp + -546 ], %i5                      
  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);          
4000de9c:	b7 36 e0 08 	srl  %i3, 8, %i3                               
  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... */
4000dea0:	86 10 20 01 	mov  1, %g3                                    
                                                                      
  FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);          
4000dea4:	c2 2f be 22 	stb  %g1, [ %fp + -478 ]                       
  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 */
4000dea8:	c8 2f be 10 	stb  %g4, [ %fp + -496 ]                       
  FAT_SET_BR_FILES_PER_ROOT_DIR(mbr  , fmt_params->files_per_root_dir);
  FAT_SET_BR_TOTAL_SECTORS_NUM16(mbr , total_sectors_num16);          
4000deac:	f6 2f be 14 	stb  %i3, [ %fp + -492 ]                       
  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... */
4000deb0:	c6 2f be 1c 	stb  %g3, [ %fp + -484 ]                       
                                                                      
  FAT_SET_BR_TOTAL_SECTORS_NUM32(mbr , total_sectors_num32);          
  if (fmt_params->fattype != FAT_FAT32) {                             
4000deb4:	80 a7 60 04 	cmp  %i5, 4                                    
4000deb8:	02 80 00 1c 	be  4000df28 <msdos_format+0xb10>              
4000debc:	c2 07 bd bc 	ld  [ %fp + -580 ], %g1                        
    FAT_SET_BR_SECTORS_PER_FAT(mbr   ,fmt_params->sectors_per_fat);   
4000dec0:	c2 2f be 16 	stb  %g1, [ %fp + -490 ]                       
4000dec4:	83 30 60 08 	srl  %g1, 8, %g1                               
4000dec8:	c2 2f be 17 	stb  %g1, [ %fp + -489 ]                       
    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);           
4000decc:	82 10 20 29 	mov  0x29, %g1                                 
4000ded0:	c2 2f be 26 	stb  %g1, [ %fp + -474 ]                       
    FAT_SET_BR_VOLID(mbr             , fmt_params->vol_id); /* volume id */
4000ded4:	c2 07 bd f8 	ld  [ %fp + -520 ], %g1                        
  memcpy(FAT_GET_ADDR_BR_VOLLAB(mbr),                                 
4000ded8:	92 07 bd e8 	add  %fp, -536, %o1                            
  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 */
4000dedc:	84 08 40 02 	and  %g1, %g2, %g2                             
4000dee0:	85 30 a0 08 	srl  %g2, 8, %g2                               
4000dee4:	c2 2f be 27 	stb  %g1, [ %fp + -473 ]                       
4000dee8:	c4 2f be 28 	stb  %g2, [ %fp + -472 ]                       
4000deec:	85 30 60 10 	srl  %g1, 0x10, %g2                            
4000def0:	83 30 60 18 	srl  %g1, 0x18, %g1                            
4000def4:	c4 2f be 29 	stb  %g2, [ %fp + -471 ]                       
4000def8:	c2 2f be 2a 	stb  %g1, [ %fp + -470 ]                       
  memcpy(FAT_GET_ADDR_BR_VOLLAB(mbr),                                 
4000defc:	90 07 be 2b 	add  %fp, -469, %o0                            
4000df00:	40 00 3b b8 	call  4001cde0 <memcpy>                        
4000df04:	94 10 20 0b 	mov  0xb, %o2                                  
	 fmt_params->VolLabel,                                               
	 FAT_BR_VOLLAB_SIZE);                                                
    memcpy(FAT_GET_ADDR_BR_FILSYSTYPE(mbr),                           
4000df08:	13 10 00 b2 	sethi  %hi(0x4002c800), %o1                    
4000df0c:	80 a7 60 01 	cmp  %i5, 1                                    
4000df10:	12 80 00 04 	bne  4000df20 <msdos_format+0xb08>             
4000df14:	92 12 63 58 	or  %o1, 0x358, %o1                            
4000df18:	13 10 00 b2 	sethi  %hi(0x4002c800), %o1                    
4000df1c:	92 12 63 48 	or  %o1, 0x348, %o1	! 4002cb48 <_Semaphore_Translate_core_mutex_return_code_+0x90>
4000df20:	10 80 00 1d 	b  4000df94 <msdos_format+0xb7c>               
4000df24:	90 07 be 36 	add  %fp, -458, %o0                            
	   ? "FAT12   "                                                      
	   : "FAT16   ",                                                     
	   FAT_BR_FILSYSTYPE_SIZE);                                          
  }                                                                   
  else {                                                              
    FAT_SET_BR_SECTORS_PER_FAT32(mbr   ,fmt_params->sectors_per_fat); 
4000df28:	84 08 40 02 	and  %g1, %g2, %g2                             
4000df2c:	85 30 a0 08 	srl  %g2, 8, %g2                               
4000df30:	c2 2f be 24 	stb  %g1, [ %fp + -476 ]                       
4000df34:	c4 2f be 25 	stb  %g2, [ %fp + -475 ]                       
4000df38:	85 30 60 10 	srl  %g1, 0x10, %g2                            
4000df3c:	83 30 60 18 	srl  %g1, 0x18, %g1                            
4000df40:	c2 2f be 27 	stb  %g1, [ %fp + -473 ]                       
    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 */
4000df44:	c2 07 bd d4 	ld  [ %fp + -556 ], %g1                        
	   ? "FAT12   "                                                      
	   : "FAT16   ",                                                     
	   FAT_BR_FILSYSTYPE_SIZE);                                          
  }                                                                   
  else {                                                              
    FAT_SET_BR_SECTORS_PER_FAT32(mbr   ,fmt_params->sectors_per_fat); 
4000df48:	c4 2f be 26 	stb  %g2, [ %fp + -474 ]                       
    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 */
4000df4c:	c2 2f be 32 	stb  %g1, [ %fp + -462 ]                       
4000df50:	83 30 60 08 	srl  %g1, 8, %g1                               
  }                                                                   
  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 */
4000df54:	c8 2f be 2c 	stb  %g4, [ %fp + -468 ]                       
    FAT_SET_BR_FAT32_FS_INFO_SECTOR(mbr, 1); /* Put fsinfo  to rsrvd sec 1*/
4000df58:	c6 2f be 30 	stb  %g3, [ %fp + -464 ]                       
    FAT_SET_BR_FAT32_BK_BOOT_SECTOR(mbr, fmt_params->mbr_copy_sec ); /* Put MBR copy to rsrvd sec */
4000df5c:	c2 2f be 33 	stb  %g1, [ %fp + -461 ]                       
    memset(FAT_GET_ADDR_BR_FAT32_RESERVED(mbr),0,FAT_BR_FAT32_RESERVED_SIZE);
4000df60:	92 10 20 00 	clr  %o1                                       
4000df64:	94 10 20 0c 	mov  0xc, %o2                                  
4000df68:	40 00 3b dd 	call  4001cedc <memset>                        
4000df6c:	90 07 be 34 	add  %fp, -460, %o0                            
                                                                      
    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);      
4000df70:	82 10 20 29 	mov  0x29, %g1                                 
    FAT_SET_BR_FAT32_VOLID(mbr       , 0); /* not set */              
    memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr)   ,0,FAT_BR_VOLLAB_SIZE);
4000df74:	92 10 20 00 	clr  %o1                                       
    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);      
4000df78:	c2 2f be 42 	stb  %g1, [ %fp + -446 ]                       
    FAT_SET_BR_FAT32_VOLID(mbr       , 0); /* not set */              
    memset(FAT_GET_ADDR_BR_FAT32_VOLLAB(mbr)   ,0,FAT_BR_VOLLAB_SIZE);
4000df7c:	90 07 be 47 	add  %fp, -441, %o0                            
4000df80:	40 00 3b d7 	call  4001cedc <memset>                        
4000df84:	94 10 20 0b 	mov  0xb, %o2                                  
    memcpy(FAT_GET_ADDR_BR_FAT32_FILSYSTYPE(mbr),                     
4000df88:	13 10 00 b3 	sethi  %hi(0x4002cc00), %o1                    
4000df8c:	90 07 be 52 	add  %fp, -430, %o0                            
4000df90:	92 12 60 28 	or  %o1, 0x28, %o1                             
4000df94:	40 00 3b 93 	call  4001cde0 <memcpy>                        
4000df98:	94 10 20 08 	mov  8, %o2                                    
	   FAT_BR_FILSYSTYPE_SIZE);                                          
  }                                                                   
  /*                                                                  
   * add boot record signature                                        
   */                                                                 
  FAT_SET_BR_SIGNATURE(mbr,      FAT_BR_SIGNATURE_VAL);               
4000df9c:	82 10 20 55 	mov  0x55, %g1                                 
4000dfa0:	c2 2f bf fe 	stb  %g1, [ %fp + -2 ]                         
4000dfa4:	82 10 3f aa 	mov  -86, %g1                                  
4000dfa8:	c2 2f bf ff 	stb  %g1, [ %fp + -1 ]                         
                                                                      
  /*                                                                  
   * add jump to boot loader at start of sector                       
   */                                                                 
  FAT_SET_VAL8(mbr,0,0xeb);                                           
4000dfac:	82 10 3f eb 	mov  -21, %g1                                  
4000dfb0:	c2 2f be 00 	stb  %g1, [ %fp + -512 ]                       
  FAT_SET_VAL8(mbr,1,0x3c);                                           
4000dfb4:	82 10 20 3c 	mov  0x3c, %g1                                 
4000dfb8:	c2 2f be 01 	stb  %g1, [ %fp + -511 ]                       
  FAT_SET_VAL8(mbr,2,0x90);                                           
4000dfbc:	82 10 3f 90 	mov  -112, %g1                                 
    /*                                                                
     * 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,       
4000dfc0:	90 10 00 19 	mov  %i1, %o0                                  
  /*                                                                  
   * 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);                                           
4000dfc4:	c2 2f be 02 	stb  %g1, [ %fp + -510 ]                       
    /*                                                                
     * 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,       
4000dfc8:	92 10 20 02 	mov  2, %o1                                    
4000dfcc:	15 10 00 b3 	sethi  %hi(0x4002cc00), %o2                    
4000dfd0:	7f ff fc 6e 	call  4000d188 <msdos_format_printf>           
4000dfd4:	94 12 a0 38 	or  %o2, 0x38, %o2	! 4002cc38 <_Semaphore_Translate_core_mutex_return_code_+0x180>
                           "write MRB sector\n");                     
      ret_val = msdos_format_write_sec(fd,                            
4000dfd8:	d4 07 bd ac 	ld  [ %fp + -596 ], %o2                        
4000dfdc:	90 10 00 1c 	mov  %i4, %o0                                  
4000dfe0:	92 10 20 00 	clr  %o1                                       
4000dfe4:	7f ff fc 81 	call  4000d1e8 <msdos_format_write_sec>        
4000dfe8:	96 07 be 00 	add  %fp, -512, %o3                            
                                       0,                             
                                       fmt_params.bytes_per_sector,   
                                       tmp_sec);                      
    }                                                                 
    if ((ret_val == 0) &&                                             
4000dfec:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000dff0:	12 80 00 bb 	bne  4000e2dc <msdos_format+0xec4>             <== NEVER TAKEN
4000dff4:	c2 07 bd d4 	ld  [ %fp + -556 ], %g1                        
4000dff8:	80 a0 60 00 	cmp  %g1, 0                                    
4000dffc:	12 80 00 08 	bne  4000e01c <msdos_format+0xc04>             
4000e000:	90 10 00 19 	mov  %i1, %o0                                  
  }                                                                   
  /*                                                                  
   * for FAT32: initialize info sector on disk                        
   */                                                                 
  if ((ret_val == 0) &&                                               
      (fmt_params.fsinfo_sec != 0)) {                                 
4000e004:	fa 07 bd d8 	ld  [ %fp + -552 ], %i5                        
    }                                                                 
  }                                                                   
  /*                                                                  
   * for FAT32: initialize info sector on disk                        
   */                                                                 
  if ((ret_val == 0) &&                                               
4000e008:	80 a7 60 00 	cmp  %i5, 0                                    
4000e00c:	22 80 00 37 	be,a   4000e0e8 <msdos_format+0xcd0>           
4000e010:	d2 07 bd bc 	ld  [ %fp + -580 ], %o1                        
\*=========================================================================*/
{                                                                     
  /*                                                                  
   * clear fsinfo sector data                                         
   */                                                                 
  memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);                             
4000e014:	10 80 00 10 	b  4000e054 <msdos_format+0xc3c>               
4000e018:	92 10 20 00 	clr  %o1                                       
    if ((ret_val == 0) &&                                             
        (fmt_params.mbr_copy_sec != 0)) {                             
      /*                                                              
       * write copy of MBR                                            
       */                                                             
      msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,       
4000e01c:	92 10 20 02 	mov  2, %o1                                    
4000e020:	15 10 00 b3 	sethi  %hi(0x4002cc00), %o2                    
4000e024:	7f ff fc 59 	call  4000d188 <msdos_format_printf>           
4000e028:	94 12 a0 50 	or  %o2, 0x50, %o2	! 4002cc50 <_Semaphore_Translate_core_mutex_return_code_+0x198>
                           "write back up MRB sector\n");             
      ret_val = msdos_format_write_sec(fd,                            
4000e02c:	d2 07 bd d4 	ld  [ %fp + -556 ], %o1                        
4000e030:	d4 07 bd ac 	ld  [ %fp + -596 ], %o2                        
4000e034:	90 10 00 1c 	mov  %i4, %o0                                  
4000e038:	7f ff fc 6c 	call  4000d1e8 <msdos_format_write_sec>        
4000e03c:	96 07 be 00 	add  %fp, -512, %o3                            
    }                                                                 
  }                                                                   
  /*                                                                  
   * for FAT32: initialize info sector on disk                        
   */                                                                 
  if ((ret_val == 0) &&                                               
4000e040:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e044:	22 bf ff f1 	be,a   4000e008 <msdos_format+0xbf0>           <== ALWAYS TAKEN
4000e048:	fa 07 bd d8 	ld  [ %fp + -552 ], %i5                        
    }                                                                 
                                                                      
    start_sector = loc_align_object (fmt_params.rsvd_sector_cnt,      
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
4000e04c:	10 80 00 a5 	b  4000e2e0 <msdos_format+0xec8>               <== NOT EXECUTED
4000e050:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
\*=========================================================================*/
{                                                                     
  /*                                                                  
   * clear fsinfo sector data                                         
   */                                                                 
  memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);                             
4000e054:	94 10 22 00 	mov  0x200, %o2                                
4000e058:	40 00 3b a1 	call  4001cedc <memset>                        
4000e05c:	90 07 be 00 	add  %fp, -512, %o0                            
  /*                                                                  
   * write LEADSIG, STRUCTSIG, TRAILSIG                               
   */                                                                 
  FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
4000e060:	82 10 20 52 	mov  0x52, %g1                                 
4000e064:	c2 2f be 00 	stb  %g1, [ %fp + -512 ]                       
4000e068:	c2 2f be 01 	stb  %g1, [ %fp + -511 ]                       
4000e06c:	82 10 20 61 	mov  0x61, %g1                                 
4000e070:	c2 2f be 02 	stb  %g1, [ %fp + -510 ]                       
  FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
4000e074:	c2 2f bf e7 	stb  %g1, [ %fp + -25 ]                        
  FAT_SET_FSINFO_TRAIL_SIGNATURE(fsinfo,FAT_FSINFO_TRAIL_SIGNATURE_VALUE);
4000e078:	82 10 20 55 	mov  0x55, %g1                                 
  /*                                                                  
   * write fsinfo sector                                              
   */                                                                 
  if ((ret_val == 0) &&                                               
      (fmt_params.fsinfo_sec != 0)) {                                 
    ret_val = msdos_format_write_sec(fd,                              
4000e07c:	d4 07 bd ac 	ld  [ %fp + -596 ], %o2                        
  /*                                                                  
   * write LEADSIG, STRUCTSIG, TRAILSIG                               
   */                                                                 
  FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
  FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
  FAT_SET_FSINFO_TRAIL_SIGNATURE(fsinfo,FAT_FSINFO_TRAIL_SIGNATURE_VALUE);
4000e080:	c2 2f bf fe 	stb  %g1, [ %fp + -2 ]                         
4000e084:	82 10 3f aa 	mov  -86, %g1                                  
   */                                                                 
  memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);                             
  /*                                                                  
   * write LEADSIG, STRUCTSIG, TRAILSIG                               
   */                                                                 
  FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
4000e088:	84 10 20 41 	mov  0x41, %g2                                 
  FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
4000e08c:	86 10 20 72 	mov  0x72, %g3                                 
  FAT_SET_FSINFO_TRAIL_SIGNATURE(fsinfo,FAT_FSINFO_TRAIL_SIGNATURE_VALUE);
4000e090:	c2 2f bf ff 	stb  %g1, [ %fp + -1 ]                         
  /*                                                                  
   * write "empty" values for free cluster count and next cluster number
   */                                                                 
  FAT_SET_FSINFO_FREE_CLUSTER_COUNT(fsinfo+FAT_FSI_INFO,              
4000e094:	82 10 3f ff 	mov  -1, %g1                                   
  /*                                                                  
   * write fsinfo sector                                              
   */                                                                 
  if ((ret_val == 0) &&                                               
      (fmt_params.fsinfo_sec != 0)) {                                 
    ret_val = msdos_format_write_sec(fd,                              
4000e098:	92 10 00 1d 	mov  %i5, %o1                                  
   */                                                                 
  memset(fsinfo,0,FAT_TOTAL_FSINFO_SIZE);                             
  /*                                                                  
   * write LEADSIG, STRUCTSIG, TRAILSIG                               
   */                                                                 
  FAT_SET_FSINFO_LEAD_SIGNATURE (fsinfo,FAT_FSINFO_LEAD_SIGNATURE_VALUE );
4000e09c:	c4 2f be 03 	stb  %g2, [ %fp + -509 ]                       
  FAT_SET_FSINFO_STRUC_SIGNATURE(fsinfo,FAT_FSINFO_STRUC_SIGNATURE_VALUE);
4000e0a0:	c6 2f bf e4 	stb  %g3, [ %fp + -28 ]                        
4000e0a4:	c6 2f bf e5 	stb  %g3, [ %fp + -27 ]                        
4000e0a8:	c4 2f bf e6 	stb  %g2, [ %fp + -26 ]                        
  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,              
4000e0ac:	c2 2f bf e8 	stb  %g1, [ %fp + -24 ]                        
4000e0b0:	c2 2f bf e9 	stb  %g1, [ %fp + -23 ]                        
4000e0b4:	c2 2f bf ea 	stb  %g1, [ %fp + -22 ]                        
4000e0b8:	c2 2f bf eb 	stb  %g1, [ %fp + -21 ]                        
				    0xffffffff);                                                  
  FAT_SET_FSINFO_NEXT_FREE_CLUSTER (fsinfo+FAT_FSI_INFO,              
4000e0bc:	c2 2f bf ec 	stb  %g1, [ %fp + -20 ]                        
4000e0c0:	c2 2f bf ed 	stb  %g1, [ %fp + -19 ]                        
4000e0c4:	c2 2f bf ee 	stb  %g1, [ %fp + -18 ]                        
4000e0c8:	c2 2f bf ef 	stb  %g1, [ %fp + -17 ]                        
  /*                                                                  
   * write fsinfo sector                                              
   */                                                                 
  if ((ret_val == 0) &&                                               
      (fmt_params.fsinfo_sec != 0)) {                                 
    ret_val = msdos_format_write_sec(fd,                              
4000e0cc:	90 10 00 1c 	mov  %i4, %o0                                  
4000e0d0:	7f ff fc 46 	call  4000d1e8 <msdos_format_write_sec>        
4000e0d4:	96 07 be 00 	add  %fp, -512, %o3                            
  }                                                                   
  /*                                                                  
   * write FAT as all empty                                           
   * -> write all FAT sectors as zero                                 
   */                                                                 
  if (ret_val == 0) {                                                 
4000e0d8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e0dc:	12 80 00 81 	bne  4000e2e0 <msdos_format+0xec8>             <== NEVER TAKEN
4000e0e0:	b0 10 00 1d 	mov  %i5, %i0                                  
    ret_val = msdos_format_fill_sectors                               
      (rqdata,                                                        
4000e0e4:	d2 07 bd bc 	ld  [ %fp + -580 ], %o1                        
4000e0e8:	d0 0f bd dc 	ldub  [ %fp + -548 ], %o0                      
4000e0ec:	7f ff d1 89 	call  40002710 <.umul>                         
4000e0f0:	fa 07 bd b4 	ld  [ %fp + -588 ], %i5                        
  /*                                                                  
   * write FAT as all empty                                           
   * -> write all FAT sectors as zero                                 
   */                                                                 
  if (ret_val == 0) {                                                 
    ret_val = msdos_format_fill_sectors                               
4000e0f4:	d8 07 bd ac 	ld  [ %fp + -596 ], %o4                        
      (rqdata,                                                        
4000e0f8:	96 10 00 08 	mov  %o0, %o3                                  
  /*                                                                  
   * write FAT as all empty                                           
   * -> write all FAT sectors as zero                                 
   */                                                                 
  if (ret_val == 0) {                                                 
    ret_val = msdos_format_fill_sectors                               
4000e0fc:	94 10 00 1d 	mov  %i5, %o2                                  
4000e100:	90 10 00 19 	mov  %i1, %o0                                  
4000e104:	92 10 00 1c 	mov  %i4, %o1                                  
4000e108:	7f ff fc 50 	call  4000d248 <msdos_format_fill_sectors>     
4000e10c:	9a 10 20 00 	clr  %o5                                       
  }                                                                   
  /*                                                                  
   * clear/init root directory                                        
   * -> write all directory sectors as 0x00                           
   */                                                                 
  if (ret_val == 0) {                                                 
4000e110:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e114:	12 80 00 72 	bne  4000e2dc <msdos_format+0xec4>             <== NEVER TAKEN
4000e118:	d4 07 bd cc 	ld  [ %fp + -564 ], %o2                        
    ret_val = msdos_format_fill_sectors                               
4000e11c:	d6 07 bd d0 	ld  [ %fp + -560 ], %o3                        
4000e120:	d8 07 bd ac 	ld  [ %fp + -596 ], %o4                        
4000e124:	90 10 00 19 	mov  %i1, %o0                                  
4000e128:	92 10 00 1c 	mov  %i4, %o1                                  
4000e12c:	7f ff fc 47 	call  4000d248 <msdos_format_fill_sectors>     
4000e130:	9a 10 20 00 	clr  %o5                                       
       0x00);                                                         
  }                                                                   
  /*                                                                  
   * write volume label to first entry of directory                   
   */                                                                 
  if ((ret_val == 0) && fmt_params.VolLabel_present) {                
4000e134:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e138:	12 80 00 69 	bne  4000e2dc <msdos_format+0xec4>             <== NEVER TAKEN
4000e13c:	c2 0f bd f4 	ldub  [ %fp + -524 ], %g1                      
4000e140:	80 a0 60 00 	cmp  %g1, 0                                    
4000e144:	12 80 00 13 	bne  4000e190 <msdos_format+0xd78>             
4000e148:	90 07 be 00 	add  %fp, -512, %o0                            
    uint32_t start_sector;                                            
                                                                      
    /*                                                                
     * empty sector: all clusters are free/do not link further on     
     */                                                               
    memset(tmp_sec,0,sizeof(tmp_sec));                                
4000e14c:	92 10 20 00 	clr  %o1                                       
4000e150:	40 00 3b 63 	call  4001cedc <memset>                        
4000e154:	94 10 22 00 	mov  0x200, %o2                                
                                                                      
    switch(fmt_params.fattype) {                                      
4000e158:	c2 0f bd de 	ldub  [ %fp + -546 ], %g1                      
4000e15c:	80 a0 60 02 	cmp  %g1, 2                                    
4000e160:	02 80 00 20 	be  4000e1e0 <msdos_format+0xdc8>              
4000e164:	80 a0 60 04 	cmp  %g1, 4                                    
4000e168:	02 80 00 26 	be  4000e200 <msdos_format+0xde8>              
4000e16c:	80 a0 60 01 	cmp  %g1, 1                                    
4000e170:	12 80 00 31 	bne  4000e234 <msdos_format+0xe1c>             <== NEVER TAKEN
4000e174:	c2 0f bd dd 	ldub  [ %fp + -547 ], %g1                      
    case FAT_FAT12:                                                   
      /* LSBits of FAT entry 0: media_type */                         
      FAT_SET_VAL8(tmp_sec,0,(fmt_params.media_code));                
4000e178:	c2 2f be 00 	stb  %g1, [ %fp + -512 ]                       
      /* 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)));          
4000e17c:	82 10 3f 8f 	mov  -113, %g1                                 
4000e180:	c2 2f be 01 	stb  %g1, [ %fp + -511 ]                       
      /* MSBits of FAT entry 1: MSBits of EOC */                      
      FAT_SET_VAL8(tmp_sec,2,(FAT_FAT12_EOC >> 4));                   
4000e184:	82 10 3f ff 	mov  -1, %g1                                   
      break;                                                          
4000e188:	10 80 00 2f 	b  4000e244 <msdos_format+0xe2c>               
4000e18c:	c2 2f be 02 	stb  %g1, [ %fp + -510 ]                       
  }                                                                   
  /*                                                                  
   * write volume label to first entry of directory                   
   */                                                                 
  if ((ret_val == 0) && fmt_params.VolLabel_present) {                
    memset(tmp_sec,0,sizeof(tmp_sec));                                
4000e190:	92 10 20 00 	clr  %o1                                       
4000e194:	94 10 22 00 	mov  0x200, %o2                                
4000e198:	40 00 3b 51 	call  4001cedc <memset>                        
4000e19c:	90 07 be 00 	add  %fp, -512, %o0                            
    memcpy(MSDOS_DIR_NAME(tmp_sec),fmt_params.VolLabel,MSDOS_SHORT_NAME_LEN);
4000e1a0:	92 07 bd e8 	add  %fp, -536, %o1                            
4000e1a4:	94 10 20 0b 	mov  0xb, %o2                                  
4000e1a8:	40 00 3b 0e 	call  4001cde0 <memcpy>                        
4000e1ac:	90 07 be 00 	add  %fp, -512, %o0                            
    *MSDOS_DIR_ATTR(tmp_sec) = MSDOS_ATTR_VOLUME_ID;                  
    ret_val = msdos_format_write_sec                                  
4000e1b0:	d2 07 bd cc 	ld  [ %fp + -564 ], %o1                        
4000e1b4:	d4 07 bd ac 	ld  [ %fp + -596 ], %o2                        
   * 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);
    *MSDOS_DIR_ATTR(tmp_sec) = MSDOS_ATTR_VOLUME_ID;                  
4000e1b8:	82 10 20 08 	mov  8, %g1                                    
    ret_val = msdos_format_write_sec                                  
4000e1bc:	90 10 00 1c 	mov  %i4, %o0                                  
   * 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);
    *MSDOS_DIR_ATTR(tmp_sec) = MSDOS_ATTR_VOLUME_ID;                  
4000e1c0:	c2 2f be 0b 	stb  %g1, [ %fp + -501 ]                       
    ret_val = msdos_format_write_sec                                  
4000e1c4:	7f ff fc 09 	call  4000d1e8 <msdos_format_write_sec>        
4000e1c8:	96 07 be 00 	add  %fp, -512, %o3                            
  /*                                                                  
   * 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) {                                                 
4000e1cc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e1d0:	12 80 00 45 	bne  4000e2e4 <msdos_format+0xecc>             <== NEVER TAKEN
4000e1d4:	80 a6 20 00 	cmp  %i0, 0                                    
    uint32_t start_sector;                                            
                                                                      
    /*                                                                
     * empty sector: all clusters are free/do not link further on     
     */                                                               
    memset(tmp_sec,0,sizeof(tmp_sec));                                
4000e1d8:	10 bf ff dd 	b  4000e14c <msdos_format+0xd34>               
4000e1dc:	90 07 be 00 	add  %fp, -512, %o0                            
      FAT_SET_VAL8(tmp_sec,2,(FAT_FAT12_EOC >> 4));                   
      break;                                                          
                                                                      
    case FAT_FAT16:                                                   
      /* FAT entry 0: 0xff00|media_type */                            
      FAT_SET_VAL8(tmp_sec,0,fmt_params.media_code);                  
4000e1e0:	c2 0f bd dd 	ldub  [ %fp + -547 ], %g1                      
      FAT_SET_VAL8(tmp_sec,1,0xff);                                   
      /* FAT entry 1: EOC */                                          
      FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);                         
4000e1e4:	84 10 3f f8 	mov  -8, %g2                                   
      FAT_SET_VAL8(tmp_sec,2,(FAT_FAT12_EOC >> 4));                   
      break;                                                          
                                                                      
    case FAT_FAT16:                                                   
      /* FAT entry 0: 0xff00|media_type */                            
      FAT_SET_VAL8(tmp_sec,0,fmt_params.media_code);                  
4000e1e8:	c2 2f be 00 	stb  %g1, [ %fp + -512 ]                       
      FAT_SET_VAL8(tmp_sec,1,0xff);                                   
      /* FAT entry 1: EOC */                                          
      FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);                         
4000e1ec:	c4 2f be 02 	stb  %g2, [ %fp + -510 ]                       
      break;                                                          
                                                                      
    case FAT_FAT16:                                                   
      /* FAT entry 0: 0xff00|media_type */                            
      FAT_SET_VAL8(tmp_sec,0,fmt_params.media_code);                  
      FAT_SET_VAL8(tmp_sec,1,0xff);                                   
4000e1f0:	82 10 3f ff 	mov  -1, %g1                                   
4000e1f4:	c2 2f be 01 	stb  %g1, [ %fp + -511 ]                       
      /* FAT entry 1: EOC */                                          
      FAT_SET_VAL16(tmp_sec,2,FAT_FAT16_EOC);                         
      break;                                                          
4000e1f8:	10 80 00 13 	b  4000e244 <msdos_format+0xe2c>               
4000e1fc:	c2 2f be 03 	stb  %g1, [ %fp + -509 ]                       
                                                                      
    case FAT_FAT32:                                                   
      /* FAT entry 0: 0xffffff00|media_type */                        
      FAT_SET_VAL32(tmp_sec,0,0xffffff00|fmt_params.media_code);      
4000e200:	c2 0f bd dd 	ldub  [ %fp + -547 ], %g1                      
      /* FAT entry 1: EOC */                                          
      FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);                         
4000e204:	84 10 3f f8 	mov  -8, %g2                                   
      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);      
4000e208:	c2 2f be 00 	stb  %g1, [ %fp + -512 ]                       
4000e20c:	82 10 3f ff 	mov  -1, %g1                                   
      /* FAT entry 1: EOC */                                          
      FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);                         
4000e210:	c4 2f be 04 	stb  %g2, [ %fp + -508 ]                       
      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);      
4000e214:	c2 2f be 01 	stb  %g1, [ %fp + -511 ]                       
4000e218:	c2 2f be 02 	stb  %g1, [ %fp + -510 ]                       
4000e21c:	c2 2f be 03 	stb  %g1, [ %fp + -509 ]                       
      /* FAT entry 1: EOC */                                          
      FAT_SET_VAL32(tmp_sec,4,FAT_FAT32_EOC);                         
4000e220:	c2 2f be 05 	stb  %g1, [ %fp + -507 ]                       
4000e224:	c2 2f be 06 	stb  %g1, [ %fp + -506 ]                       
4000e228:	82 10 20 0f 	mov  0xf, %g1                                  
      break;                                                          
4000e22c:	10 80 00 06 	b  4000e244 <msdos_format+0xe2c>               
4000e230:	c2 2f be 07 	stb  %g1, [ %fp + -505 ]                       
                                                                      
    default:                                                          
      ret_val = -1;                                                   
      errno = EINVAL;                                                 
4000e234:	40 00 38 96 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e238:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
4000e23c:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
4000e240:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    }                                                                 
    if (fmt_params.fattype == FAT_FAT32) {                            
4000e244:	c2 0f bd de 	ldub  [ %fp + -546 ], %g1                      
4000e248:	80 a0 60 04 	cmp  %g1, 4                                    
4000e24c:	12 80 00 0a 	bne  4000e274 <msdos_format+0xe5c>             
4000e250:	c4 0f bd fc 	ldub  [ %fp + -516 ], %g2                      
      /*                                                              
       * 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);                         
4000e254:	82 10 3f f8 	mov  -8, %g1                                   
4000e258:	c2 2f be 08 	stb  %g1, [ %fp + -504 ]                       
4000e25c:	82 10 3f ff 	mov  -1, %g1                                   
4000e260:	c2 2f be 09 	stb  %g1, [ %fp + -503 ]                       
4000e264:	c2 2f be 0a 	stb  %g1, [ %fp + -502 ]                       
4000e268:	82 10 20 0f 	mov  0xf, %g1                                  
4000e26c:	c2 2f be 0b 	stb  %g1, [ %fp + -501 ]                       
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000e270:	c4 0f bd fc 	ldub  [ %fp + -516 ], %g2                      
       * mark this in every copy of the FAT                           
       */                                                             
      FAT_SET_VAL32(tmp_sec,8,FAT_FAT32_EOC);                         
    }                                                                 
                                                                      
    start_sector = loc_align_object (fmt_params.rsvd_sector_cnt,      
4000e274:	c2 07 bd b8 	ld  [ %fp + -584 ], %g1                        
static uint32_t                                                       
 loc_align_object (const uint32_t sectors,                            
                   const uint32_t clustersize,                        
                   const bool     skip_alignment)                     
{                                                                     
  if (! skip_alignment)                                               
4000e278:	80 a0 a0 00 	cmp  %g2, 0                                    
4000e27c:	12 80 00 06 	bne  4000e294 <msdos_format+0xe7c>             
4000e280:	f6 07 bd b4 	ld  [ %fp + -588 ], %i3                        
    return (sectors + clustersize - 1) & ~(clustersize - 1);          
4000e284:	b6 06 c0 01 	add  %i3, %g1, %i3                             
4000e288:	82 20 00 01 	neg  %g1                                       
4000e28c:	b6 06 ff ff 	add  %i3, -1, %i3                              
4000e290:	b6 0e c0 01 	and  %i3, %g1, %i3                             
    }                                                                 
                                                                      
    start_sector = loc_align_object (fmt_params.rsvd_sector_cnt,      
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
4000e294:	b0 10 00 1d 	mov  %i5, %i0                                  
4000e298:	ba 10 20 00 	clr  %i5                                       
	 (i < fmt_params.fat_num) && (ret_val == 0);                         
4000e29c:	c2 0f bd dc 	ldub  [ %fp + -548 ], %g1                      
    }                                                                 
                                                                      
    start_sector = loc_align_object (fmt_params.rsvd_sector_cnt,      
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
4000e2a0:	80 a7 40 01 	cmp  %i5, %g1                                  
4000e2a4:	16 80 00 0f 	bge  4000e2e0 <msdos_format+0xec8>             
4000e2a8:	80 a6 20 00 	cmp  %i0, 0                                    
	 (i < fmt_params.fat_num) && (ret_val == 0);                         
4000e2ac:	12 80 00 0e 	bne  4000e2e4 <msdos_format+0xecc>             <== NEVER TAKEN
4000e2b0:	d2 07 bd bc 	ld  [ %fp + -580 ], %o1                        
	 i++) {                                                              
      ret_val = msdos_format_write_sec                                
        (fd,                                                          
         start_sector                                                 
         + (i * fmt_params.sectors_per_fat),                          
4000e2b4:	7f ff d1 17 	call  40002710 <.umul>                         
4000e2b8:	90 10 00 1d 	mov  %i5, %o0                                  
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
	 (i < fmt_params.fat_num) && (ret_val == 0);                         
	 i++) {                                                              
      ret_val = msdos_format_write_sec                                
4000e2bc:	d4 07 bd ac 	ld  [ %fp + -596 ], %o2                        
        (fd,                                                          
4000e2c0:	92 02 00 1b 	add  %o0, %i3, %o1                             
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
	 (i < fmt_params.fat_num) && (ret_val == 0);                         
	 i++) {                                                              
      ret_val = msdos_format_write_sec                                
4000e2c4:	96 07 be 00 	add  %fp, -512, %o3                            
4000e2c8:	90 10 00 1c 	mov  %i4, %o0                                  
4000e2cc:	7f ff fb c7 	call  4000d1e8 <msdos_format_write_sec>        
4000e2d0:	ba 07 60 01 	inc  %i5                                       
4000e2d4:	10 bf ff f2 	b  4000e29c <msdos_format+0xe84>               
4000e2d8:	b0 10 00 08 	mov  %o0, %i0                                  
    }                                                                 
                                                                      
    start_sector = loc_align_object (fmt_params.rsvd_sector_cnt,      
                                     fmt_params.sectors_per_cluster,  
                                     fmt_params.skip_alignment);      
    for (i = 0;                                                       
4000e2dc:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
         fmt_params.bytes_per_sector,                                 
         tmp_sec);                                                    
    }                                                                 
  }                                                                   
                                                                      
  if (ret_val == 0 && rqdata != NULL && rqdata->sync_device) {        
4000e2e0:	80 a6 20 00 	cmp  %i0, 0                                    
4000e2e4:	12 80 00 0f 	bne  4000e320 <msdos_format+0xf08>             
4000e2e8:	80 a7 3f ff 	cmp  %i4, -1                                   
4000e2ec:	80 a6 a0 00 	cmp  %i2, 0                                    
4000e2f0:	02 80 00 0c 	be  4000e320 <msdos_format+0xf08>              
4000e2f4:	80 a7 3f ff 	cmp  %i4, -1                                   
4000e2f8:	c2 0e 60 17 	ldub  [ %i1 + 0x17 ], %g1                      
4000e2fc:	80 a0 60 00 	cmp  %g1, 0                                    
4000e300:	02 80 00 08 	be  4000e320 <msdos_format+0xf08>              
4000e304:	80 a7 3f ff 	cmp  %i4, -1                                   
  return ioctl(fd, RTEMS_BLKIO_GETDISKDEV, dd_ptr);                   
}                                                                     
                                                                      
static inline int rtems_disk_fd_sync(int fd)                          
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_SYNCDEV);                              
4000e308:	90 10 00 1c 	mov  %i4, %o0                                  
4000e30c:	13 08 00 10 	sethi  %hi(0x20004000), %o1                    
4000e310:	40 00 19 c2 	call  40014a18 <ioctl>                         
4000e314:	92 12 62 06 	or  %o1, 0x206, %o1	! 20004206 <RAM_SIZE+0x1fc04206>
4000e318:	b0 10 00 08 	mov  %o0, %i0                                  
  /*                                                                  
   * cleanup:                                                         
   * sync and unlock disk                                             
   * free any data structures (not needed now)                        
   */                                                                 
  if (fd != -1) {                                                     
4000e31c:	80 a7 3f ff 	cmp  %i4, -1                                   
4000e320:	02 80 00 06 	be  4000e338 <msdos_format+0xf20>              <== NEVER TAKEN
4000e324:	01 00 00 00 	nop                                            
    close(fd);                                                        
4000e328:	7f ff da 88 	call  40004d48 <close>                         
4000e32c:	90 10 00 1c 	mov  %i4, %o0                                  
4000e330:	81 c7 e0 08 	ret                                            
4000e334:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return ret_val;                                                     
}                                                                     
4000e338:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e33c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40018b54 <msdos_format_dirent_with_dot>: const char *src_tmp; /* * find last non-blank character of base name */ for (i = MSDOS_SHORT_BASE_LEN, src_tmp = src + MSDOS_SHORT_BASE_LEN - 1;
40018b54:	82 10 20 08 	mov  8, %g1                                    
40018b58:	84 02 40 01 	add  %o1, %g1, %g2                             
       i > 0 && *src_tmp == ' ';                                      
40018b5c:	c4 48 bf ff 	ldsb  [ %g2 + -1 ], %g2                        
40018b60:	80 a0 a0 20 	cmp  %g2, 0x20                                 
40018b64:	12 80 00 06 	bne  40018b7c <msdos_format_dirent_with_dot+0x28>
40018b68:	84 10 20 00 	clr  %g2                                       
  const char *src_tmp;                                                
                                                                      
  /*                                                                  
   * find last non-blank character of base name                       
   */                                                                 
  for (i = MSDOS_SHORT_BASE_LEN, src_tmp = src + MSDOS_SHORT_BASE_LEN - 1;
40018b6c:	82 80 7f ff 	addcc  %g1, -1, %g1                            
40018b70:	12 bf ff fb 	bne  40018b5c <msdos_format_dirent_with_dot+0x8><== ALWAYS TAKEN
40018b74:	84 02 40 01 	add  %o1, %g1, %g2                             
40018b78:	84 10 20 00 	clr  %g2                                       <== NOT EXECUTED
   * copy base name to destination                                    
   */                                                                 
  src_tmp = src;                                                      
  len = i;                                                            
  while (i-- > 0) {                                                   
    *dst++ = tolower((unsigned char)(*src_tmp++));                    
40018b7c:	09 10 00 b7 	sethi  %hi(0x4002dc00), %g4                    
40018b80:	86 20 40 02 	sub  %g1, %g2, %g3                             
  /*                                                                  
   * copy base name to destination                                    
   */                                                                 
  src_tmp = src;                                                      
  len = i;                                                            
  while (i-- > 0) {                                                   
40018b84:	80 a0 e0 00 	cmp  %g3, 0                                    
40018b88:	04 80 00 0c 	ble  40018bb8 <msdos_format_dirent_with_dot+0x64>
40018b8c:	da 01 22 0c 	ld  [ %g4 + 0x20c ], %o5                       
    *dst++ = tolower((unsigned char)(*src_tmp++));                    
40018b90:	c6 0a 40 02 	ldub  [ %o1 + %g2 ], %g3                       
40018b94:	9a 03 40 03 	add  %o5, %g3, %o5                             
40018b98:	da 0b 60 01 	ldub  [ %o5 + 1 ], %o5                         
40018b9c:	9a 0b 60 03 	and  %o5, 3, %o5                               
40018ba0:	80 a3 60 01 	cmp  %o5, 1                                    
40018ba4:	22 80 00 02 	be,a   40018bac <msdos_format_dirent_with_dot+0x58>
40018ba8:	86 00 e0 20 	add  %g3, 0x20, %g3                            
40018bac:	c6 2a 00 02 	stb  %g3, [ %o0 + %g2 ]                        
40018bb0:	10 bf ff f4 	b  40018b80 <msdos_format_dirent_with_dot+0x2c>
40018bb4:	84 00 a0 01 	inc  %g2                                       
40018bb8:	84 38 00 01 	xnor  %g0, %g1, %g2                            
40018bbc:	85 38 a0 1f 	sra  %g2, 0x1f, %g2                            
40018bc0:	84 08 40 02 	and  %g1, %g2, %g2                             
40018bc4:	90 02 00 02 	add  %o0, %g2, %o0                             
  }                                                                   
  /*                                                                  
   * find last non-blank character of extension                       
   */                                                                 
  for (i = MSDOS_SHORT_EXT_LEN,                                       
40018bc8:	84 10 20 03 	mov  3, %g2                                    
40018bcc:	86 02 40 02 	add  %o1, %g2, %g3                             
        src_tmp = src + MSDOS_SHORT_BASE_LEN+MSDOS_SHORT_EXT_LEN-1;   
       i > 0 && *src_tmp == ' ';                                      
40018bd0:	c6 48 e0 07 	ldsb  [ %g3 + 7 ], %g3                         
40018bd4:	80 a0 e0 20 	cmp  %g3, 0x20                                 
40018bd8:	32 80 00 07 	bne,a   40018bf4 <msdos_format_dirent_with_dot+0xa0>
40018bdc:	86 10 20 2e 	mov  0x2e, %g3                                 
    *dst++ = tolower((unsigned char)(*src_tmp++));                    
  }                                                                   
  /*                                                                  
   * find last non-blank character of extension                       
   */                                                                 
  for (i = MSDOS_SHORT_EXT_LEN,                                       
40018be0:	84 80 bf ff 	addcc  %g2, -1, %g2                            
40018be4:	12 bf ff fb 	bne  40018bd0 <msdos_format_dirent_with_dot+0x7c>
40018be8:	86 02 40 02 	add  %o1, %g2, %g3                             
40018bec:	10 80 00 1d 	b  40018c60 <msdos_format_dirent_with_dot+0x10c>
40018bf0:	c0 2a 00 00 	clrb  [ %o0 ]                                  
    {};                                                               
  /*                                                                  
   * extension is not empty                                           
   */                                                                 
  if (i > 0) {                                                        
    *dst++ = '.'; /* append dot */                                    
40018bf4:	98 02 20 01 	add  %o0, 1, %o4                               
40018bf8:	c6 2a 00 00 	stb  %g3, [ %o0 ]                              
    ++len;        /* dot */                                           
40018bfc:	82 00 60 01 	inc  %g1                                       
    src_tmp = src + MSDOS_SHORT_BASE_LEN;                             
    while (i-- > 0) {                                                 
40018c00:	86 10 20 00 	clr  %g3                                       
      *dst++ = tolower((unsigned char)(*src_tmp++));                  
40018c04:	1b 10 00 b7 	sethi  %hi(0x4002dc00), %o5                    
40018c08:	88 20 80 03 	sub  %g2, %g3, %g4                             
   */                                                                 
  if (i > 0) {                                                        
    *dst++ = '.'; /* append dot */                                    
    ++len;        /* dot */                                           
    src_tmp = src + MSDOS_SHORT_BASE_LEN;                             
    while (i-- > 0) {                                                 
40018c0c:	80 a1 20 00 	cmp  %g4, 0                                    
40018c10:	04 80 00 0e 	ble  40018c48 <msdos_format_dirent_with_dot+0xf4>
40018c14:	88 02 40 03 	add  %o1, %g3, %g4                             
      *dst++ = tolower((unsigned char)(*src_tmp++));                  
40018c18:	d6 03 62 0c 	ld  [ %o5 + 0x20c ], %o3                       
40018c1c:	c8 09 20 08 	ldub  [ %g4 + 8 ], %g4                         
40018c20:	96 02 c0 04 	add  %o3, %g4, %o3                             
40018c24:	d6 0a e0 01 	ldub  [ %o3 + 1 ], %o3                         
40018c28:	96 0a e0 03 	and  %o3, 3, %o3                               
40018c2c:	80 a2 e0 01 	cmp  %o3, 1                                    
40018c30:	22 80 00 02 	be,a   40018c38 <msdos_format_dirent_with_dot+0xe4>
40018c34:	88 01 20 20 	add  %g4, 0x20, %g4                            
40018c38:	96 02 00 03 	add  %o0, %g3, %o3                             
40018c3c:	86 00 e0 01 	inc  %g3                                       
40018c40:	10 bf ff f2 	b  40018c08 <msdos_format_dirent_with_dot+0xb4>
40018c44:	c8 2a e0 01 	stb  %g4, [ %o3 + 1 ]                          
40018c48:	86 38 00 02 	xnor  %g0, %g2, %g3                            
40018c4c:	87 38 e0 1f 	sra  %g3, 0x1f, %g3                            
40018c50:	84 08 80 03 	and  %g2, %g3, %g2                             
40018c54:	90 03 00 02 	add  %o4, %g2, %o0                             
40018c58:	82 00 40 02 	add  %g1, %g2, %g1                             
      ++len;                                                          
    }                                                                 
  }                                                                   
  *dst = '\0'; /* terminate string */                                 
40018c5c:	c0 2a 00 00 	clrb  [ %o0 ]                                  
                                                                      
  return len;                                                         
}                                                                     
40018c60:	81 c3 e0 08 	retl                                           
40018c64:	90 10 00 01 	mov  %g1, %o0                                  
                                                                      

4000d248 <msdos_format_fill_sectors>: ) /*-------------------------------------------------------------------------*\ | Return Value: | | 0, if success, -1 and errno if failed | \*=========================================================================*/ {
4000d248:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
  /*                                                                  
   * allocate and fill buffer                                         
   */                                                                 
  if (ret_val == 0) {                                                 
    fill_buffer = malloc(sector_size);                                
4000d24c:	7f ff e0 14 	call  4000529c <malloc>                        
4000d250:	90 10 00 1c 	mov  %i4, %o0                                  
    if (fill_buffer == NULL) {                                        
4000d254:	a0 92 20 00 	orcc  %o0, 0, %l0                              
4000d258:	12 80 00 07 	bne  4000d274 <msdos_format_fill_sectors+0x2c> <== ALWAYS TAKEN
4000d25c:	92 10 00 1d 	mov  %i5, %o1                                  
      errno = ENOMEM;                                                 
4000d260:	40 00 3c 8b 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000d264:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
4000d268:	82 10 20 0c 	mov  0xc, %g1                                  <== NOT EXECUTED
4000d26c:	10 80 00 05 	b  4000d280 <msdos_format_fill_sectors+0x38>   <== NOT EXECUTED
4000d270:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
      ret_val = -1;                                                   
    }                                                                 
    else {                                                            
      memset(fill_buffer,fill_byte,sector_size);                      
4000d274:	94 10 00 1c 	mov  %i4, %o2                                  
4000d278:	40 00 3f 19 	call  4001cedc <memset>                        
4000d27c:	ba 10 20 00 	clr  %i5                                       
    }                                                                 
  }                                                                   
                                                                      
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,           
4000d280:	90 10 00 18 	mov  %i0, %o0                                  
4000d284:	92 10 20 02 	mov  2, %o1                                    
4000d288:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    
4000d28c:	7f ff ff bf 	call  4000d188 <msdos_format_printf>           
4000d290:	94 12 a3 10 	or  %o2, 0x310, %o2	! 4002cb10 <_Semaphore_Translate_core_mutex_return_code_+0x58>
4000d294:	83 2e e0 02 	sll  %i3, 2, %g1                               
4000d298:	85 2e e0 04 	sll  %i3, 4, %g2                               
  while ((ret_val == 0) &&                                            
	 (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, ".");
4000d29c:	2d 10 00 b2 	sethi  %hi(0x4002c800), %l6                    
4000d2a0:	82 00 40 02 	add  %g1, %g2, %g1                             
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,           
                       "Filling : ");                                 
  /*                                                                  
   * write to consecutive sectors                                     
   */                                                                 
  while ((ret_val == 0) &&                                            
4000d2a4:	a4 10 20 00 	clr  %l2                                       
4000d2a8:	a9 28 60 02 	sll  %g1, 2, %l4                               
\*=========================================================================*/
{                                                                     
  int ret_val = 0;                                                    
  char *fill_buffer = NULL;                                           
  uint32_t total_sectors = sector_cnt;                                
  int last_percent = -1;                                              
4000d2ac:	a6 10 3f ff 	mov  -1, %l3                                   
4000d2b0:	a8 00 40 14 	add  %g1, %l4, %l4                             
4000d2b4:	aa 06 c0 1a 	add  %i3, %i2, %l5                             
  while ((ret_val == 0) &&                                            
	 (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, ".");
4000d2b8:	ac 15 a0 30 	or  %l6, 0x30, %l6                             
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,           
                       "Filling : ");                                 
  /*                                                                  
   * write to consecutive sectors                                     
   */                                                                 
  while ((ret_val == 0) &&                                            
4000d2bc:	80 a5 40 1a 	cmp  %l5, %i2                                  
4000d2c0:	02 80 00 1d 	be  4000d334 <msdos_format_fill_sectors+0xec>  
4000d2c4:	80 a7 60 00 	cmp  %i5, 0                                    
4000d2c8:	12 80 00 1b 	bne  4000d334 <msdos_format_fill_sectors+0xec> <== NEVER TAKEN
4000d2cc:	90 04 80 14 	add  %l2, %l4, %o0                             
	 (sector_cnt > 0)) {                                                 
    int percent = (sector_cnt * 100) / total_sectors;                 
4000d2d0:	7f ff d5 4a 	call  400027f8 <.udiv>                         
4000d2d4:	92 10 00 1b 	mov  %i3, %o1                                  
    if (percent != last_percent) {                                    
4000d2d8:	80 a2 00 13 	cmp  %o0, %l3                                  
4000d2dc:	02 80 00 0b 	be  4000d308 <msdos_format_fill_sectors+0xc0>  
4000d2e0:	a2 10 00 08 	mov  %o0, %l1                                  
      if ((percent & 1) == 0)                                         
4000d2e4:	80 8a 20 01 	btst  1, %o0                                   
4000d2e8:	32 80 00 0a 	bne,a   4000d310 <msdos_format_fill_sectors+0xc8>
4000d2ec:	92 10 00 1a 	mov  %i2, %o1                                  
        msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, ".");
4000d2f0:	90 10 00 18 	mov  %i0, %o0                                  
4000d2f4:	92 10 20 02 	mov  2, %o1                                    
4000d2f8:	7f ff ff a4 	call  4000d188 <msdos_format_printf>           
4000d2fc:	94 10 00 16 	mov  %l6, %o2                                  
      last_percent = percent;                                         
    }                                                                 
    ret_val = msdos_format_write_sec(fd,start_sector,sector_size,fill_buffer);
4000d300:	10 80 00 04 	b  4000d310 <msdos_format_fill_sectors+0xc8>   
4000d304:	92 10 00 1a 	mov  %i2, %o1                                  
4000d308:	a2 10 00 13 	mov  %l3, %l1                                  
4000d30c:	92 10 00 1a 	mov  %i2, %o1                                  
4000d310:	90 10 00 19 	mov  %i1, %o0                                  
4000d314:	94 10 00 1c 	mov  %i4, %o2                                  
4000d318:	96 10 00 10 	mov  %l0, %o3                                  
4000d31c:	7f ff ff b3 	call  4000d1e8 <msdos_format_write_sec>        
4000d320:	b4 06 a0 01 	inc  %i2                                       
4000d324:	a4 04 bf 9c 	add  %l2, -100, %l2                            
4000d328:	ba 10 00 08 	mov  %o0, %i5                                  
    start_sector++;                                                   
4000d32c:	10 bf ff e4 	b  4000d2bc <msdos_format_fill_sectors+0x74>   
4000d330:	a6 10 00 11 	mov  %l1, %l3                                  
    sector_cnt--;                                                     
  }                                                                   
                                                                      
  msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL, "\n");    
4000d334:	90 10 00 18 	mov  %i0, %o0                                  
4000d338:	92 10 20 02 	mov  2, %o1                                    
4000d33c:	15 10 00 b3 	sethi  %hi(0x4002cc00), %o2                    
4000d340:	7f ff ff 92 	call  4000d188 <msdos_format_printf>           
4000d344:	94 12 a0 48 	or  %o2, 0x48, %o2	! 4002cc48 <_Semaphore_Translate_core_mutex_return_code_+0x190>
                                                                      
  if (ret_val)                                                        
4000d348:	80 a7 60 00 	cmp  %i5, 0                                    
4000d34c:	02 80 00 09 	be  4000d370 <msdos_format_fill_sectors+0x128> <== ALWAYS TAKEN
4000d350:	80 a4 20 00 	cmp  %l0, 0                                    
    msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_INFO,           
4000d354:	15 10 00 b2 	sethi  %hi(0x4002c800), %o2                    <== NOT EXECUTED
4000d358:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4000d35c:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4000d360:	94 12 a3 20 	or  %o2, 0x320, %o2                            <== NOT EXECUTED
4000d364:	7f ff ff 89 	call  4000d188 <msdos_format_printf>           <== NOT EXECUTED
4000d368:	96 10 00 1a 	mov  %i2, %o3                                  <== NOT EXECUTED
                         "filling error on sector: %d\n", start_sector);
                                                                      
  /*                                                                  
   * cleanup                                                          
   */                                                                 
  if (fill_buffer != NULL) {                                          
4000d36c:	80 a4 20 00 	cmp  %l0, 0                                    <== NOT EXECUTED
4000d370:	02 80 00 04 	be  4000d380 <msdos_format_fill_sectors+0x138> <== NEVER TAKEN
4000d374:	01 00 00 00 	nop                                            
    free(fill_buffer);                                                
4000d378:	7f ff de 97 	call  40004dd4 <free>                          
4000d37c:	90 10 00 10 	mov  %l0, %o0                                  
    fill_buffer = NULL;                                               
  }                                                                   
  return ret_val;                                                     
}                                                                     
4000d380:	81 c7 e0 08 	ret                                            
4000d384:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

4000d188 <msdos_format_printf>: */ static void msdos_format_printf (const msdos_format_request_param_t *rqdata, int info_level, const char *format, ...) {
4000d188:	9d e3 bf 98 	save  %sp, -104, %sp                           
  va_list args;                                                       
  va_start (args, format);                                            
4000d18c:	82 07 a0 50 	add  %fp, 0x50, %g1                            
4000d190:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
4000d194:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        
4000d198:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        
  if (rqdata != NULL && rqdata->info_level >= info_level)             
4000d19c:	80 a6 20 00 	cmp  %i0, 0                                    
4000d1a0:	02 80 00 10 	be  4000d1e0 <msdos_format_printf+0x58>        
4000d1a4:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
4000d1a8:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
4000d1ac:	80 a0 40 19 	cmp  %g1, %i1                                  
4000d1b0:	06 80 00 0c 	bl  4000d1e0 <msdos_format_printf+0x58>        <== ALWAYS TAKEN
4000d1b4:	01 00 00 00 	nop                                            
  {                                                                   
    vfprintf (stdout, format, args);                                  
4000d1b8:	7f ff d0 37 	call  40001294 <__getreent>                    <== NOT EXECUTED
4000d1bc:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000d1c0:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          <== NOT EXECUTED
4000d1c4:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
4000d1c8:	40 00 5e 12 	call  40024a10 <vfprintf>                      <== NOT EXECUTED
4000d1cc:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
    fflush (stdout);                                                  
4000d1d0:	7f ff d0 31 	call  40001294 <__getreent>                    <== NOT EXECUTED
4000d1d4:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000d1d8:	40 00 3d 6c 	call  4001c788 <fflush>                        <== NOT EXECUTED
4000d1dc:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
4000d1e0:	81 c7 e0 08 	ret                                            
4000d1e4:	81 e8 00 00 	restore                                        
                                                                      

4000d1e8 <msdos_format_write_sec>: ) /*-------------------------------------------------------------------------*\ | Return Value: | | 0, if success, -1 and errno if failed | \*=========================================================================*/ {
4000d1e8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int ret_val = 0;                                                    
                                                                      
  if (0 > lseek(fd,((off_t)start_sector)*sector_size,SEEK_SET)) {     
4000d1ec:	94 10 20 00 	clr  %o2                                       
4000d1f0:	96 10 00 1a 	mov  %i2, %o3                                  
4000d1f4:	90 10 20 00 	clr  %o0                                       
4000d1f8:	7f ff d4 22 	call  40002280 <__muldi3>                      
4000d1fc:	92 10 00 19 	mov  %i1, %o1                                  
4000d200:	84 10 00 08 	mov  %o0, %g2                                  
4000d204:	86 10 00 09 	mov  %o1, %g3                                  
4000d208:	90 10 00 18 	mov  %i0, %o0                                  
4000d20c:	92 10 00 02 	mov  %g2, %o1                                  
4000d210:	94 10 00 03 	mov  %g3, %o2                                  
4000d214:	40 00 1e 22 	call  40014a9c <lseek>                         
4000d218:	96 10 20 00 	clr  %o3                                       
4000d21c:	80 a2 20 00 	cmp  %o0, 0                                    
4000d220:	16 80 00 04 	bge  4000d230 <msdos_format_write_sec+0x48>    <== ALWAYS TAKEN
4000d224:	90 10 00 18 	mov  %i0, %o0                                  
4000d228:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000d22c:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
    ret_val = -1;                                                     
  }                                                                   
  if (ret_val == 0) {                                                 
    if (0 > write(fd,buffer,sector_size)) {                           
4000d230:	92 10 00 1b 	mov  %i3, %o1                                  
4000d234:	7f ff ed d6 	call  4000898c <write>                         
4000d238:	94 10 00 1a 	mov  %i2, %o2                                  
4000d23c:	b1 3a 20 1f 	sra  %o0, 0x1f, %i0                            
      ret_val = -1;                                                   
    }                                                                 
  }                                                                   
                                                                      
  return ret_val;                                                     
}                                                                     
4000d240:	81 c7 e0 08 	ret                                            
4000d244:	81 e8 00 00 	restore                                        
                                                                      

400199f4 <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 ) {
400199f4:	9d e3 bf 50 	save  %sp, -176, %sp                           
    int              rc = RC_OK;                                      
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
400199f8:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
    fat_file_fd_t   *fat_fd = NULL;                                   
400199fc:	c0 27 bf bc 	clr  [ %fp + -68 ]                             
    char             dot_node[MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE];     
    char             dotdot_node[MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE];  
    uint32_t         cl4find = 0;                                     
    rtems_dosfs_convert_control *converter = fs_info->converter;      
40019a00:	e0 07 60 a4 	ld  [ %i5 + 0xa4 ], %l0                        
                                                                      
    /*                                                                
     * open fat-file corresponded to ".."                             
     */                                                               
    rc = fat_file_open(&fs_info->fat, dir_pos, &fat_fd);              
40019a04:	90 10 00 1d 	mov  %i5, %o0                                  
40019a08:	92 10 00 1a 	mov  %i2, %o1                                  
40019a0c:	94 07 bf bc 	add  %fp, -68, %o2                             
40019a10:	7f ff e2 26 	call  400122a8 <fat_file_open>                 
40019a14:	b8 10 00 18 	mov  %i0, %i4                                  
    if (rc != RC_OK)                                                  
40019a18:	80 a2 20 00 	cmp  %o0, 0                                    
40019a1c:	12 80 00 a1 	bne  40019ca0 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NEVER TAKEN
40019a20:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
        return rc;                                                    
                                                                      
    fat_fd->cln = cln;                                                
    fat_fd->fat_file_type = FAT_DIRECTORY;                            
    fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                        
40019a24:	03 00 08 00 	sethi  %hi(0x200000), %g1                      
     */                                                               
    rc = fat_file_open(&fs_info->fat, dir_pos, &fat_fd);              
    if (rc != RC_OK)                                                  
        return rc;                                                    
                                                                      
    fat_fd->cln = cln;                                                
40019a28:	f2 22 60 1c 	st  %i1, [ %o1 + 0x1c ]                        
    fat_fd->fat_file_type = FAT_DIRECTORY;                            
40019a2c:	c0 22 60 10 	clr  [ %o1 + 0x10 ]                            
    fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                        
40019a30:	c2 22 60 14 	st  %g1, [ %o1 + 0x14 ]                        
                                                                      
    fat_fd->map.file_cln = 0;                                         
40019a34:	c0 22 60 34 	clr  [ %o1 + 0x34 ]                            
    fat_fd->map.disk_cln = fat_fd->cln;                               
40019a38:	f2 22 60 38 	st  %i1, [ %o1 + 0x38 ]                        
                                                                      
    rc = fat_file_size(&fs_info->fat, fat_fd);                        
40019a3c:	7f ff e4 cc 	call  40012d6c <fat_file_size>                 
40019a40:	90 10 00 1d 	mov  %i5, %o0                                  
    if (rc != RC_OK)                                                  
40019a44:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019a48:	12 80 00 19 	bne  40019aac <msdos_get_dotdot_dir_info_cluster_num_and_offset+0xb8><== NEVER TAKEN
40019a4c:	b2 07 bf c0 	add  %fp, -64, %i1                             
        fat_file_close(&fs_info->fat, fat_fd);                        
        return rc;                                                    
    }                                                                 
                                                                      
    /* find "." node in opened directory */                           
    memset(dot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);           
40019a50:	92 10 20 00 	clr  %o1                                       
40019a54:	94 10 20 20 	mov  0x20, %o2                                 
40019a58:	40 00 0d 21 	call  4001cedc <memset>                        
40019a5c:	90 10 00 19 	mov  %i1, %o0                                  
    msdos_long_to_short(                                              
40019a60:	31 10 00 b2 	sethi  %hi(0x4002c800), %i0                    
40019a64:	94 10 20 01 	mov  1, %o2                                    
40019a68:	92 16 20 30 	or  %i0, 0x30, %o1                             
40019a6c:	96 10 00 19 	mov  %i1, %o3                                  
40019a70:	98 10 20 0b 	mov  0xb, %o4                                  
40019a74:	7f ff fa 66 	call  4001840c <msdos_long_to_short>           
40019a78:	90 10 00 10 	mov  %l0, %o0                                  
        converter,                                                    
        ".", 1, dot_node, MSDOS_SHORT_NAME_LEN);                      
    rc = msdos_find_name_in_fat_file(mt_entry, fat_fd, false, (const uint8_t*)".", 1,
40019a7c:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
40019a80:	96 16 20 30 	or  %i0, 0x30, %o3                             
40019a84:	f4 23 a0 5c 	st  %i2, [ %sp + 0x5c ]                        
40019a88:	f2 23 a0 60 	st  %i1, [ %sp + 0x60 ]                        
40019a8c:	90 10 00 1c 	mov  %i4, %o0                                  
40019a90:	94 10 20 00 	clr  %o2                                       
40019a94:	98 10 20 01 	mov  1, %o4                                    
40019a98:	7f ff fc 74 	call  40018c68 <msdos_find_name_in_fat_file>   
40019a9c:	9a 10 20 01 	mov  1, %o5                                    
                                     MSDOS_NAME_SHORT, dir_pos, dot_node);
                                                                      
    if (rc != RC_OK)                                                  
40019aa0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019aa4:	02 80 00 05 	be  40019ab8 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0xc4><== ALWAYS TAKEN
40019aa8:	b2 07 bf e0 	add  %fp, -32, %i1                             
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
40019aac:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40019ab0:	10 80 00 76 	b  40019c88 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x294><== NOT EXECUTED
40019ab4:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         <== NOT EXECUTED
        return rc;                                                    
    }                                                                 
                                                                      
    /* find ".." node in opened directory */                          
    memset(dotdot_node, 0, MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);        
40019ab8:	92 10 20 00 	clr  %o1                                       
40019abc:	94 10 20 20 	mov  0x20, %o2                                 
40019ac0:	40 00 0d 07 	call  4001cedc <memset>                        
40019ac4:	90 10 00 19 	mov  %i1, %o0                                  
    msdos_long_to_short(                                              
40019ac8:	31 10 00 b3 	sethi  %hi(0x4002cc00), %i0                    
40019acc:	94 10 20 02 	mov  2, %o2                                    
40019ad0:	92 16 23 b8 	or  %i0, 0x3b8, %o1                            
40019ad4:	96 10 00 19 	mov  %i1, %o3                                  
40019ad8:	98 10 20 0b 	mov  0xb, %o4                                  
40019adc:	7f ff fa 4c 	call  4001840c <msdos_long_to_short>           
40019ae0:	90 10 00 10 	mov  %l0, %o0                                  
        converter,                                                    
        "..", 2, dotdot_node, MSDOS_SHORT_NAME_LEN);                  
    rc = msdos_find_name_in_fat_file(mt_entry, fat_fd, false, (const uint8_t*)"..", 2,
40019ae4:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
40019ae8:	96 16 23 b8 	or  %i0, 0x3b8, %o3                            
40019aec:	f4 23 a0 5c 	st  %i2, [ %sp + 0x5c ]                        
40019af0:	f2 23 a0 60 	st  %i1, [ %sp + 0x60 ]                        
40019af4:	90 10 00 1c 	mov  %i4, %o0                                  
40019af8:	94 10 20 00 	clr  %o2                                       
40019afc:	98 10 20 02 	mov  2, %o4                                    
40019b00:	7f ff fc 5a 	call  40018c68 <msdos_find_name_in_fat_file>   
40019b04:	9a 10 20 01 	mov  1, %o5                                    
                                     MSDOS_NAME_SHORT, dir_pos,       
                                     dotdot_node);                    
                                                                      
    if (rc != RC_OK)                                                  
40019b08:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019b0c:	12 80 00 46 	bne  40019c24 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x230><== NEVER TAKEN
40019b10:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
        return rc;                                                    
    }                                                                 
                                                                      
    cl4find = MSDOS_EXTRACT_CLUSTER_NUM(dot_node);                    
40019b14:	f2 17 bf da 	lduh  [ %fp + -38 ], %i1                       
40019b18:	e0 17 bf d4 	lduh  [ %fp + -44 ], %l0                       
                                                                      
    /* close fat-file corresponded to ".." directory */               
    rc = fat_file_close(&fs_info->fat, fat_fd);                       
40019b1c:	7f ff e2 fb 	call  40012708 <fat_file_close>                
40019b20:	90 10 00 1d 	mov  %i5, %o0                                  
    if ( rc != RC_OK )                                                
40019b24:	80 a2 20 00 	cmp  %o0, 0                                    
40019b28:	12 80 00 5e 	bne  40019ca0 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NEVER TAKEN
40019b2c:	c6 17 bf f4 	lduh  [ %fp + -12 ], %g3                       
        return rc;                                                    
                                                                      
    if ( (MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node)) == 0)               
40019b30:	c2 17 bf fa 	lduh  [ %fp + -6 ], %g1                        
40019b34:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40019b38:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
40019b3c:	89 30 e0 08 	srl  %g3, 8, %g4                               
40019b40:	84 10 a3 ff 	or  %g2, 0x3ff, %g2                            
40019b44:	88 09 00 02 	and  %g4, %g2, %g4                             
40019b48:	83 28 60 10 	sll  %g1, 0x10, %g1                            
40019b4c:	87 30 e0 18 	srl  %g3, 0x18, %g3                            
40019b50:	86 11 00 03 	or  %g4, %g3, %g3                              
40019b54:	89 30 60 08 	srl  %g1, 8, %g4                               
40019b58:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40019b5c:	84 09 00 02 	and  %g4, %g2, %g2                             
40019b60:	83 30 60 18 	srl  %g1, 0x18, %g1                            
40019b64:	82 10 80 01 	or  %g2, %g1, %g1                              
40019b68:	80 90 c0 01 	orcc  %g3, %g1, %g0                            
40019b6c:	12 80 00 08 	bne  40019b8c <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x198>
40019b70:	90 10 00 1d 	mov  %i5, %o0                                  
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
40019b74:	82 10 3f ff 	mov  -1, %g1                                   
fat_dir_pos_init(                                                     
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
40019b78:	c0 26 a0 04 	clr  [ %i2 + 4 ]                               
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
40019b7c:	c2 26 a0 08 	st  %g1, [ %i2 + 8 ]                           
  dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;                           
40019b80:	c2 26 a0 0c 	st  %g1, [ %i2 + 0xc ]                         
        /*                                                            
         * 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;                 
40019b84:	82 10 20 01 	mov  1, %g1                                    
40019b88:	c2 26 80 00 	st  %g1, [ %i2 ]                               
    }                                                                 
                                                                      
    /* open fat-file corresponded to second ".." */                   
    rc = fat_file_open(&fs_info->fat, dir_pos, &fat_fd);              
40019b8c:	92 10 00 1a 	mov  %i2, %o1                                  
40019b90:	7f ff e1 c6 	call  400122a8 <fat_file_open>                 
40019b94:	94 07 bf bc 	add  %fp, -68, %o2                             
    if (rc != RC_OK)                                                  
40019b98:	80 a2 20 00 	cmp  %o0, 0                                    
40019b9c:	12 80 00 41 	bne  40019ca0 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NEVER TAKEN
40019ba0:	c2 17 bf fa 	lduh  [ %fp + -6 ], %g1                        
        return rc;                                                    
                                                                      
    if ((MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node)) == 0)                
40019ba4:	f0 17 bf f4 	lduh  [ %fp + -12 ], %i0                       
40019ba8:	83 28 60 10 	sll  %g1, 0x10, %g1                            
40019bac:	b1 2e 20 10 	sll  %i0, 0x10, %i0                            
40019bb0:	85 30 60 08 	srl  %g1, 8, %g2                               
40019bb4:	89 36 20 08 	srl  %i0, 8, %g4                               
40019bb8:	07 00 00 3f 	sethi  %hi(0xfc00), %g3                        
40019bbc:	b1 36 20 18 	srl  %i0, 0x18, %i0                            
40019bc0:	86 10 e3 ff 	or  %g3, 0x3ff, %g3                            
40019bc4:	83 30 60 18 	srl  %g1, 0x18, %g1                            
40019bc8:	88 09 00 03 	and  %g4, %g3, %g4                             
40019bcc:	84 08 80 03 	and  %g2, %g3, %g2                             
40019bd0:	88 11 00 18 	or  %g4, %i0, %g4                              
40019bd4:	84 10 80 01 	or  %g2, %g1, %g2                              
40019bd8:	89 29 20 10 	sll  %g4, 0x10, %g4                            
40019bdc:	84 91 00 02 	orcc  %g4, %g2, %g2                            
40019be0:	12 80 00 05 	bne  40019bf4 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x200>
40019be4:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
        fat_fd->cln = fs_info->fat.vol.rdir_cl;                       
40019be8:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
40019bec:	10 80 00 03 	b  40019bf8 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x204>
40019bf0:	c2 22 60 1c 	st  %g1, [ %o1 + 0x1c ]                        
    else                                                              
        fat_fd->cln = MSDOS_EXTRACT_CLUSTER_NUM(dotdot_node);         
40019bf4:	c4 22 60 1c 	st  %g2, [ %o1 + 0x1c ]                        
                                                                      
    fat_fd->fat_file_type = FAT_DIRECTORY;                            
    fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                        
40019bf8:	03 00 08 00 	sethi  %hi(0x200000), %g1                      
40019bfc:	c2 22 60 14 	st  %g1, [ %o1 + 0x14 ]                        
                                                                      
    fat_fd->map.file_cln = 0;                                         
    fat_fd->map.disk_cln = fat_fd->cln;                               
40019c00:	c2 02 60 1c 	ld  [ %o1 + 0x1c ], %g1                        
    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;                            
40019c04:	c0 22 60 10 	clr  [ %o1 + 0x10 ]                            
    fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                        
                                                                      
    fat_fd->map.file_cln = 0;                                         
40019c08:	c0 22 60 34 	clr  [ %o1 + 0x34 ]                            
    fat_fd->map.disk_cln = fat_fd->cln;                               
40019c0c:	c2 22 60 38 	st  %g1, [ %o1 + 0x38 ]                        
                                                                      
    rc = fat_file_size(&fs_info->fat, fat_fd);                        
40019c10:	7f ff e4 57 	call  40012d6c <fat_file_size>                 
40019c14:	90 10 00 1d 	mov  %i5, %o0                                  
    if (rc != RC_OK)                                                  
40019c18:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019c1c:	02 80 00 04 	be  40019c2c <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x238><== ALWAYS TAKEN
40019c20:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
40019c24:	10 80 00 19 	b  40019c88 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x294><== NOT EXECUTED
40019c28:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
        return rc;                                                    
    }                                                                 
                                                                      
    cl4find = MSDOS_EXTRACT_CLUSTER_NUM(dot_node);                    
40019c2c:	87 2c 20 10 	sll  %l0, 0x10, %g3                            
40019c30:	95 30 e0 08 	srl  %g3, 8, %o2                               
40019c34:	87 30 e0 18 	srl  %g3, 0x18, %g3                            
40019c38:	83 2e 60 10 	sll  %i1, 0x10, %g1                            
40019c3c:	05 00 00 3f 	sethi  %hi(0xfc00), %g2                        
40019c40:	84 10 a3 ff 	or  %g2, 0x3ff, %g2	! ffff <_TLS_Alignment+0xfffe>
40019c44:	94 0a 80 02 	and  %o2, %g2, %o2                             
40019c48:	94 12 80 03 	or  %o2, %g3, %o2                              
40019c4c:	87 30 60 08 	srl  %g1, 8, %g3                               
40019c50:	83 30 60 18 	srl  %g1, 0x18, %g1                            
40019c54:	84 08 c0 02 	and  %g3, %g2, %g2                             
40019c58:	82 10 80 01 	or  %g2, %g1, %g1                              
40019c5c:	95 2a a0 10 	sll  %o2, 0x10, %o2                            
        fat_file_close(&fs_info->fat, 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,
40019c60:	90 10 00 1c 	mov  %i4, %o0                                  
40019c64:	94 12 80 01 	or  %o2, %g1, %o2                              
40019c68:	96 10 00 1a 	mov  %i2, %o3                                  
40019c6c:	7f ff ff 01 	call  40019870 <msdos_find_node_by_cluster_num_in_fat_file>
40019c70:	98 10 00 1b 	mov  %i3, %o4                                  
40019c74:	d2 07 bf bc 	ld  [ %fp + -68 ], %o1                         
40019c78:	b0 10 00 08 	mov  %o0, %i0                                  
                                                    dir_pos, dir_entry);
    if (rc != RC_OK)                                                  
40019c7c:	80 a6 20 00 	cmp  %i0, 0                                    
40019c80:	02 80 00 06 	be  40019c98 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2a4><== ALWAYS TAKEN
40019c84:	90 10 00 1d 	mov  %i5, %o0                                  
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
40019c88:	7f ff e2 a0 	call  40012708 <fat_file_close>                <== NOT EXECUTED
40019c8c:	01 00 00 00 	nop                                            <== NOT EXECUTED
        return rc;                                                    
40019c90:	10 80 00 04 	b  40019ca0 <msdos_get_dotdot_dir_info_cluster_num_and_offset+0x2ac><== NOT EXECUTED
40019c94:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
    }                                                                 
    rc = fat_file_close(&fs_info->fat, fat_fd);                       
40019c98:	7f ff e2 9c 	call  40012708 <fat_file_close>                
40019c9c:	01 00 00 00 	nop                                            
    return rc;                                                        
}                                                                     
40019ca0:	81 c7 e0 08 	ret                                            
40019ca4:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40019ca8 <msdos_get_name_node>: int name_len, msdos_name_type_t name_type, fat_dir_pos_t *dir_pos, char *name_dir_entry ) {
40019ca8:	9d e3 bf 98 	save  %sp, -104, %sp                           
    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,    
40019cac:	d0 06 20 14 	ld  [ %i0 + 0x14 ], %o0                        
40019cb0:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
    int                                     name_len,                 
    msdos_name_type_t                       name_type,                
    fat_dir_pos_t                          *dir_pos,                  
    char                                   *name_dir_entry            
    )                                                                 
{                                                                     
40019cb4:	e0 07 a0 5c 	ld  [ %fp + 0x5c ], %l0                        
    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,    
40019cb8:	9a 10 00 1c 	mov  %i4, %o5                                  
40019cbc:	fa 23 a0 5c 	st  %i5, [ %sp + 0x5c ]                        
40019cc0:	e0 23 a0 60 	st  %l0, [ %sp + 0x60 ]                        
40019cc4:	94 10 00 19 	mov  %i1, %o2                                  
40019cc8:	96 10 00 1a 	mov  %i2, %o3                                  
40019ccc:	7f ff fb e7 	call  40018c68 <msdos_find_name_in_fat_file>   
40019cd0:	98 10 00 1b 	mov  %i3, %o4                                  
                                     create_node, (const uint8_t*)name, name_len, name_type,
                                     dir_pos, name_dir_entry);        
    if ((rc != RC_OK) && (rc != MSDOS_NAME_NOT_FOUND_ERR))            
40019cd4:	03 00 00 1f 	sethi  %hi(0x7c00), %g1                        
40019cd8:	82 10 61 01 	or  %g1, 0x101, %g1	! 7d01 <_TLS_Alignment+0x7d00>
40019cdc:	80 a2 00 01 	cmp  %o0, %g1                                  
40019ce0:	02 80 00 05 	be  40019cf4 <msdos_get_name_node+0x4c>        
40019ce4:	b8 10 00 08 	mov  %o0, %i4                                  
40019ce8:	80 a2 20 00 	cmp  %o0, 0                                    
40019cec:	12 80 00 2d 	bne  40019da0 <msdos_get_name_node+0xf8>       
40019cf0:	01 00 00 00 	nop                                            
        return rc;                                                    
                                                                      
    if (!create_node)                                                 
40019cf4:	80 a6 60 00 	cmp  %i1, 0                                    
40019cf8:	12 80 00 2a 	bne  40019da0 <msdos_get_name_node+0xf8>       
40019cfc:	03 00 00 1f 	sethi  %hi(0x7c00), %g1                        
    {                                                                 
        /* if we search for valid name and name not found -> return */
        if (rc == MSDOS_NAME_NOT_FOUND_ERR)                           
40019d00:	82 10 61 01 	or  %g1, 0x101, %g1	! 7d01 <_TLS_Alignment+0x7d00>
40019d04:	80 a7 00 01 	cmp  %i4, %g1                                  
40019d08:	02 80 00 26 	be  40019da0 <msdos_get_name_node+0xf8>        
40019d0c:	80 a7 20 00 	cmp  %i4, 0                                    
         * 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)                                              
40019d10:	12 80 00 24 	bne  40019da0 <msdos_get_name_node+0xf8>       <== NEVER TAKEN
40019d14:	90 10 00 1a 	mov  %i2, %o0                                  
        {                                                             
            if (strncmp(name, "..", 2) == 0)                          
40019d18:	13 10 00 b3 	sethi  %hi(0x4002cc00), %o1                    
40019d1c:	94 10 20 02 	mov  2, %o2                                    
40019d20:	40 00 11 17 	call  4001e17c <strncmp>                       
40019d24:	92 12 63 b8 	or  %o1, 0x3b8, %o1                            
40019d28:	80 a2 20 00 	cmp  %o0, 0                                    
40019d2c:	12 80 00 1d 	bne  40019da0 <msdos_get_name_node+0xf8>       
40019d30:	07 00 00 3f 	sethi  %hi(0xfc00), %g3                        
            {                                                         
                dotdot_cln = MSDOS_EXTRACT_CLUSTER_NUM((name_dir_entry));
40019d34:	c4 14 20 1a 	lduh  [ %l0 + 0x1a ], %g2                      
40019d38:	c8 14 20 14 	lduh  [ %l0 + 0x14 ], %g4                      
40019d3c:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40019d40:	89 29 20 10 	sll  %g4, 0x10, %g4                            
40019d44:	83 30 a0 08 	srl  %g2, 8, %g1                               
40019d48:	b3 31 20 08 	srl  %g4, 8, %i1                               
40019d4c:	89 31 20 18 	srl  %g4, 0x18, %g4                            
40019d50:	86 10 e3 ff 	or  %g3, 0x3ff, %g3                            
40019d54:	85 30 a0 18 	srl  %g2, 0x18, %g2                            
40019d58:	b2 0e 40 03 	and  %i1, %g3, %i1                             
40019d5c:	82 08 40 03 	and  %g1, %g3, %g1                             
40019d60:	b2 16 40 04 	or  %i1, %g4, %i1                              
40019d64:	82 10 40 02 	or  %g1, %g2, %g1                              
40019d68:	b3 2e 60 10 	sll  %i1, 0x10, %i1                            
                                                                      
                /* are we right under root dir ? */                   
                if (dotdot_cln == 0)                                  
40019d6c:	b2 96 40 01 	orcc  %i1, %g1, %i1                            
40019d70:	12 80 00 08 	bne  40019d90 <msdos_get_name_node+0xe8>       
40019d74:	82 10 3f ff 	mov  -1, %g1                                   
fat_dir_pos_init(                                                     
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
40019d78:	c0 27 60 04 	clr  [ %i5 + 4 ]                               
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
40019d7c:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
  dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;                           
40019d80:	c2 27 60 0c 	st  %g1, [ %i5 + 0xc ]                         
                    /*                                                
                     * 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;     
40019d84:	82 10 20 01 	mov  1, %g1                                    
40019d88:	10 80 00 06 	b  40019da0 <msdos_get_name_node+0xf8>         
40019d8c:	c2 27 40 00 	st  %g1, [ %i5 ]                               
                }                                                     
                else                                                  
                {                                                     
                    rc =                                              
40019d90:	f0 06 20 14 	ld  [ %i0 + 0x14 ], %i0                        
40019d94:	b4 10 00 1d 	mov  %i5, %i2                                  
40019d98:	7f ff ff 17 	call  400199f4 <msdos_get_dotdot_dir_info_cluster_num_and_offset>
40019d9c:	97 e8 00 10 	restore  %g0, %l0, %o3                         
                }                                                     
            }                                                         
        }                                                             
    }                                                                 
    return rc;                                                        
}                                                                     
40019da0:	81 c7 e0 08 	ret                                            
40019da4:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
                                                                      

40018ad0 <msdos_get_utf16_string_from_long_entry>: const char *entry, uint16_t *entry_string_buf, const size_t buf_size, bool is_first_entry ) {
40018ad0:	9d e3 bf a0 	save  %sp, -96, %sp                            
40018ad4:	ba 10 00 18 	mov  %i0, %i5                                  
    ssize_t chars_in_entry;                                           
                                                                      
    if (buf_size >= MSDOS_LFN_ENTRY_SIZE) {                           
40018ad8:	80 a6 a0 19 	cmp  %i2, 0x19                                 
40018adc:	08 80 00 1c 	bleu  40018b4c <msdos_get_utf16_string_from_long_entry+0x7c><== NEVER TAKEN
40018ae0:	b0 10 20 0c 	mov  0xc, %i0                                  
        memcpy (&entry_string_buf[0],  &entry[1],  10 );              
40018ae4:	92 07 60 01 	add  %i5, 1, %o1                               
40018ae8:	94 10 20 0a 	mov  0xa, %o2                                  
40018aec:	40 00 10 bd 	call  4001cde0 <memcpy>                        
40018af0:	90 10 00 19 	mov  %i1, %o0                                  
        memcpy (&entry_string_buf[5],  &entry[14], 12 );              
40018af4:	92 07 60 0e 	add  %i5, 0xe, %o1                             
40018af8:	94 10 20 0c 	mov  0xc, %o2                                  
40018afc:	40 00 10 b9 	call  4001cde0 <memcpy>                        
40018b00:	90 06 60 0a 	add  %i1, 0xa, %o0                             
        memcpy (&entry_string_buf[11], &entry[28],  4 );              
40018b04:	90 06 60 16 	add  %i1, 0x16, %o0                            
40018b08:	92 07 60 1c 	add  %i5, 0x1c, %o1                            
40018b0c:	40 00 10 b5 	call  4001cde0 <memcpy>                        
40018b10:	94 10 20 04 	mov  4, %o2                                    
                                                                      
        if (is_first_entry) {                                         
40018b14:	80 a6 e0 00 	cmp  %i3, 0                                    
40018b18:	02 80 00 0c 	be  40018b48 <msdos_get_utf16_string_from_long_entry+0x78>
40018b1c:	b0 10 20 0d 	mov  0xd, %i0                                  
40018b20:	b0 10 20 00 	clr  %i0                                       
40018b24:	83 2e 20 01 	sll  %i0, 1, %g1                               
            for (chars_in_entry = 0;                                  
40018b28:	c2 16 40 01 	lduh  [ %i1 + %g1 ], %g1                       
40018b2c:	80 a0 60 00 	cmp  %g1, 0                                    
40018b30:	02 80 00 06 	be  40018b48 <msdos_get_utf16_string_from_long_entry+0x78>
40018b34:	80 a6 20 0d 	cmp  %i0, 0xd                                  
                 (    entry_string_buf[chars_in_entry] != 0x0000      
                  && chars_in_entry < MSDOS_LFN_LEN_PER_ENTRY );      
40018b38:	22 80 00 05 	be,a   40018b4c <msdos_get_utf16_string_from_long_entry+0x7c>
40018b3c:	b1 2e 20 01 	sll  %i0, 1, %i0                               
                  ++chars_in_entry) {                                 
40018b40:	10 bf ff f9 	b  40018b24 <msdos_get_utf16_string_from_long_entry+0x54>
40018b44:	b0 06 20 01 	inc  %i0                                       
            }                                                         
        }                                                             
        else                                                          
            chars_in_entry = MSDOS_LFN_LEN_PER_ENTRY;                 
                                                                      
        return chars_in_entry * MSDOS_NAME_LFN_BYTES_PER_CHAR;        
40018b48:	b1 2e 20 01 	sll  %i0, 1, %i0                               
    }                                                                 
    else                                                              
        return ENOMEM;                                                
}                                                                     
40018b4c:	81 c7 e0 08 	ret                                            
40018b50:	81 e8 00 00 	restore                                        
                                                                      

4000e414 <msdos_initialize_support>: const rtems_filesystem_operations_table *op_table, const rtems_filesystem_file_handlers_r *file_handlers, const rtems_filesystem_file_handlers_r *directory_handlers, rtems_dosfs_convert_control *converter ) {
4000e414:	9d e3 bf 88 	save  %sp, -120, %sp                           
    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));  
4000e418:	90 10 20 01 	mov  1, %o0                                    
    )                                                                 
{                                                                     
    int                rc = RC_OK;                                    
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = NULL;                                
    fat_file_fd_t     *fat_fd = NULL;                                 
4000e41c:	c0 27 bf ec 	clr  [ %fp + -20 ]                             
    fat_dir_pos_t      root_pos;                                      
    uint32_t           cl_buf_size;                                   
                                                                      
    fs_info = (msdos_fs_info_t *)calloc(1, sizeof(msdos_fs_info_t));  
4000e420:	92 10 20 a8 	mov  0xa8, %o1                                 
4000e424:	7f ff da 34 	call  40004cf4 <calloc>                        
4000e428:	a0 10 00 18 	mov  %i0, %l0                                  
    if (!fs_info)                                                     
4000e42c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000e430:	02 80 00 42 	be  4000e538 <msdos_initialize_support+0x124>  <== NEVER TAKEN
4000e434:	01 00 00 00 	nop                                            
                                                                      
    temp_mt_entry->fs_info = fs_info;                                 
                                                                      
    fs_info->converter = converter;                                   
                                                                      
    rc = fat_init_volume_info(&fs_info->fat, temp_mt_entry->dev);     
4000e438:	d2 06 20 38 	ld  [ %i0 + 0x38 ], %o1                        
                                                                      
    fs_info = (msdos_fs_info_t *)calloc(1, sizeof(msdos_fs_info_t));  
    if (!fs_info)                                                     
        rtems_set_errno_and_return_minus_one(ENOMEM);                 
                                                                      
    temp_mt_entry->fs_info = fs_info;                                 
4000e43c:	fa 26 20 08 	st  %i5, [ %i0 + 8 ]                           
                                                                      
    fs_info->converter = converter;                                   
                                                                      
    rc = fat_init_volume_info(&fs_info->fat, temp_mt_entry->dev);     
4000e440:	40 00 14 07 	call  4001345c <fat_init_volume_info>          
4000e444:	f8 27 60 a4 	st  %i4, [ %i5 + 0xa4 ]                        
    if (rc != RC_OK)                                                  
4000e448:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e44c:	12 80 00 12 	bne  4000e494 <msdos_initialize_support+0x80>  <== NEVER TAKEN
4000e450:	82 10 3f ff 	mov  -1, %g1                                   
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
  dir_pos->lname.cln = FAT_FILE_SHORT_NAME;                           
4000e454:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  dir_pos->lname.ofs = FAT_FILE_SHORT_NAME;                           
4000e458:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
    /*                                                                
     * 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;                     
4000e45c:	82 10 20 01 	mov  1, %g1                                    
    {                                                                 
        free(fs_info);                                                
        return rc;                                                    
    }                                                                 
                                                                      
    fs_info->file_handlers      = file_handlers;                      
4000e460:	f4 27 60 98 	st  %i2, [ %i5 + 0x98 ]                        
    fs_info->directory_handlers = directory_handlers;                 
4000e464:	f6 27 60 94 	st  %i3, [ %i5 + 0x94 ]                        
fat_dir_pos_init(                                                     
    fat_dir_pos_t *dir_pos                                            
    )                                                                 
{                                                                     
  dir_pos->sname.cln = 0;                                             
  dir_pos->sname.ofs = 0;                                             
4000e468:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
    /*                                                                
     * 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;                     
4000e46c:	c2 27 bf f0 	st  %g1, [ %fp + -16 ]                         
    rc = fat_file_open(&fs_info->fat, &root_pos, &fat_fd);            
4000e470:	90 10 00 1d 	mov  %i5, %o0                                  
4000e474:	92 07 bf f0 	add  %fp, -16, %o1                             
4000e478:	40 00 0f 8c 	call  400122a8 <fat_file_open>                 
4000e47c:	94 07 bf ec 	add  %fp, -20, %o2                             
    if (rc != RC_OK)                                                  
4000e480:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e484:	02 80 00 08 	be  4000e4a4 <msdos_initialize_support+0x90>   <== ALWAYS TAKEN
4000e488:	d2 07 bf ec 	ld  [ %fp + -20 ], %o1                         
    {                                                                 
        fat_shutdown_drive(&fs_info->fat);                            
4000e48c:	40 00 16 13 	call  40013cd8 <fat_shutdown_drive>            <== NOT EXECUTED
4000e490:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        free(fs_info);                                                
4000e494:	7f ff da 50 	call  40004dd4 <free>                          <== NOT EXECUTED
4000e498:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        return rc;                                                    
4000e49c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e4a0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    }                                                                 
                                                                      
    /* again: unfortunately "fat-file" is just almost fat file :( */  
    fat_fd->fat_file_type = FAT_DIRECTORY;                            
    fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                        
4000e4a4:	03 00 08 00 	sethi  %hi(0x200000), %g1                      
4000e4a8:	c2 22 60 14 	st  %g1, [ %o1 + 0x14 ]                        
    fat_fd->cln = fs_info->fat.vol.rdir_cl;                           
4000e4ac:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
        free(fs_info);                                                
        return rc;                                                    
    }                                                                 
                                                                      
    /* again: unfortunately "fat-file" is just almost fat file :( */  
    fat_fd->fat_file_type = FAT_DIRECTORY;                            
4000e4b0:	c0 22 60 10 	clr  [ %o1 + 0x10 ]                            
    fat_fd->size_limit = MSDOS_MAX_DIR_LENGHT;                        
    fat_fd->cln = fs_info->fat.vol.rdir_cl;                           
4000e4b4:	c2 22 60 1c 	st  %g1, [ %o1 + 0x1c ]                        
                                                                      
    fat_fd->map.file_cln = 0;                                         
4000e4b8:	c0 22 60 34 	clr  [ %o1 + 0x34 ]                            
    fat_fd->map.disk_cln = fat_fd->cln;                               
                                                                      
    /* if we have FAT12/16 */                                         
    if ( fat_fd->cln == 0 )                                           
4000e4bc:	80 a0 60 00 	cmp  %g1, 0                                    
4000e4c0:	12 80 00 09 	bne  4000e4e4 <msdos_initialize_support+0xd0>  
4000e4c4:	c2 22 60 38 	st  %g1, [ %o1 + 0x38 ]                        
    {                                                                 
        fat_fd->fat_file_size = fs_info->fat.vol.rdir_size;           
4000e4c8:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        
        cl_buf_size = (fs_info->fat.vol.bpc > fs_info->fat.vol.rdir_size) ?
                      fs_info->fat.vol.bpc                                :
4000e4cc:	d0 17 60 06 	lduh  [ %i5 + 6 ], %o0                         
                                                                      
    /* if we have FAT12/16 */                                         
    if ( fat_fd->cln == 0 )                                           
    {                                                                 
        fat_fd->fat_file_size = fs_info->fat.vol.rdir_size;           
        cl_buf_size = (fs_info->fat.vol.bpc > fs_info->fat.vol.rdir_size) ?
4000e4d0:	80 a2 00 01 	cmp  %o0, %g1                                  
4000e4d4:	1a 80 00 0d 	bcc  4000e508 <msdos_initialize_support+0xf4>  
4000e4d8:	c2 22 60 18 	st  %g1, [ %o1 + 0x18 ]                        
4000e4dc:	10 80 00 0b 	b  4000e508 <msdos_initialize_support+0xf4>    
4000e4e0:	90 10 00 01 	mov  %g1, %o0                                  
                      fs_info->fat.vol.bpc                                :
                      fs_info->fat.vol.rdir_size;                     
    }                                                                 
    else                                                              
    {                                                                 
        rc = fat_file_size(&fs_info->fat, fat_fd);                    
4000e4e4:	40 00 12 22 	call  40012d6c <fat_file_size>                 
4000e4e8:	90 10 00 1d 	mov  %i5, %o0                                  
        if ( rc != RC_OK )                                            
4000e4ec:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e4f0:	22 80 00 06 	be,a   4000e508 <msdos_initialize_support+0xf4><== ALWAYS TAKEN
4000e4f4:	d0 17 60 06 	lduh  [ %i5 + 6 ], %o0                         
        {                                                             
            fat_file_close(&fs_info->fat, fat_fd);                    
4000e4f8:	d2 07 bf ec 	ld  [ %fp + -20 ], %o1                         <== NOT EXECUTED
4000e4fc:	40 00 10 83 	call  40012708 <fat_file_close>                <== NOT EXECUTED
4000e500:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4000e504:	30 bf ff e2 	b,a   4000e48c <msdos_initialize_support+0x78> <== NOT EXECUTED
            return rc;                                                
        }                                                             
        cl_buf_size = fs_info->fat.vol.bpc;                           
    }                                                                 
                                                                      
    fs_info->cl_buf = (uint8_t *)calloc(cl_buf_size, sizeof(char));   
4000e508:	7f ff d9 fb 	call  40004cf4 <calloc>                        
4000e50c:	92 10 20 01 	mov  1, %o1                                    
    if (fs_info->cl_buf == NULL)                                      
4000e510:	80 a2 20 00 	cmp  %o0, 0                                    
4000e514:	12 80 00 0f 	bne  4000e550 <msdos_initialize_support+0x13c> <== ALWAYS TAKEN
4000e518:	d0 27 60 a0 	st  %o0, [ %i5 + 0xa0 ]                        
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
4000e51c:	d2 07 bf ec 	ld  [ %fp + -20 ], %o1                         <== NOT EXECUTED
4000e520:	40 00 10 7a 	call  40012708 <fat_file_close>                <== NOT EXECUTED
4000e524:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        fat_shutdown_drive(&fs_info->fat);                            
4000e528:	40 00 15 ec 	call  40013cd8 <fat_shutdown_drive>            <== NOT EXECUTED
4000e52c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        free(fs_info);                                                
4000e530:	7f ff da 29 	call  40004dd4 <free>                          <== NOT EXECUTED
4000e534:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        rtems_set_errno_and_return_minus_one(ENOMEM);                 
4000e538:	40 00 37 d5 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e53c:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000e540:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
4000e544:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4000e548:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e54c:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
    }                                                                 
                                                                      
    sc = rtems_semaphore_create(3,                                    
4000e550:	92 10 20 01 	mov  1, %o1                                    
4000e554:	90 10 20 03 	mov  3, %o0                                    
4000e558:	94 10 20 10 	mov  0x10, %o2                                 
4000e55c:	96 10 20 00 	clr  %o3                                       
4000e560:	7f ff ea 7c 	call  40008f50 <rtems_semaphore_create>        
4000e564:	98 07 60 9c 	add  %i5, 0x9c, %o4                            
                                1,                                    
                                RTEMS_BINARY_SEMAPHORE | RTEMS_FIFO,  
                                0,                                    
                                &fs_info->vol_sema);                  
    if (sc != RTEMS_SUCCESSFUL)                                       
4000e568:	80 a2 20 00 	cmp  %o0, 0                                    
4000e56c:	02 80 00 0e 	be  4000e5a4 <msdos_initialize_support+0x190>  <== ALWAYS TAKEN
4000e570:	d2 07 bf ec 	ld  [ %fp + -20 ], %o1                         
    {                                                                 
        fat_file_close(&fs_info->fat, fat_fd);                        
4000e574:	40 00 10 65 	call  40012708 <fat_file_close>                <== NOT EXECUTED
4000e578:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        fat_shutdown_drive(&fs_info->fat);                            
4000e57c:	40 00 15 d7 	call  40013cd8 <fat_shutdown_drive>            <== NOT EXECUTED
4000e580:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        free(fs_info->cl_buf);                                        
4000e584:	7f ff da 14 	call  40004dd4 <free>                          <== NOT EXECUTED
4000e588:	d0 07 60 a0 	ld  [ %i5 + 0xa0 ], %o0                        <== NOT EXECUTED
        free(fs_info);                                                
4000e58c:	7f ff da 12 	call  40004dd4 <free>                          <== NOT EXECUTED
4000e590:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        rtems_set_errno_and_return_minus_one( EIO );                  
4000e594:	40 00 37 be 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e598:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000e59c:	10 bf ff ea 	b  4000e544 <msdos_initialize_support+0x130>   <== NOT EXECUTED
4000e5a0:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
    }                                                                 
                                                                      
    temp_mt_entry->mt_fs_root->location.node_access = fat_fd;         
4000e5a4:	c2 04 20 24 	ld  [ %l0 + 0x24 ], %g1                        
4000e5a8:	d2 20 60 08 	st  %o1, [ %g1 + 8 ]                           
    temp_mt_entry->mt_fs_root->location.handlers = directory_handlers;
4000e5ac:	f6 20 60 10 	st  %i3, [ %g1 + 0x10 ]                        
    temp_mt_entry->ops = op_table;                                    
4000e5b0:	f2 24 20 0c 	st  %i1, [ %l0 + 0xc ]                         
                                                                      
    return rc;                                                        
}                                                                     
4000e5b4:	81 c7 e0 08 	ret                                            
4000e5b8:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000e350 <msdos_lock>: .rename_h = msdos_rename, .statvfs_h = msdos_statvfs }; void msdos_lock(const rtems_filesystem_mount_table_entry_t *mt_entry) {
4000e350:	9d e3 bf a0 	save  %sp, -96, %sp                            
  msdos_fs_info_t *fs_info = mt_entry->fs_info;                       
  rtems_status_code sc = rtems_semaphore_obtain(                      
4000e354:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
4000e358:	92 10 20 00 	clr  %o1                                       
4000e35c:	d0 00 60 9c 	ld  [ %g1 + 0x9c ], %o0                        
4000e360:	7f ff eb af 	call  4000921c <rtems_semaphore_obtain>        
4000e364:	94 10 20 00 	clr  %o2                                       
    fs_info->vol_sema,                                                
    RTEMS_WAIT,                                                       
    RTEMS_NO_TIMEOUT                                                  
  );                                                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000e368:	80 a2 20 00 	cmp  %o0, 0                                    
4000e36c:	02 80 00 04 	be  4000e37c <msdos_lock+0x2c>                 <== ALWAYS TAKEN
4000e370:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
    rtems_fatal_error_occurred(0xdeadbeef);                           
4000e374:	7f ff ed 75 	call  40009948 <rtems_fatal_error_occurred>    <== NOT EXECUTED
4000e378:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
4000e37c:	81 c7 e0 08 	ret                                            
4000e380:	81 e8 00 00 	restore                                        
                                                                      

4001840c <msdos_long_to_short>: msdos_long_to_short(rtems_dosfs_convert_control *converter, const char *lfn, int lfn_len, char *sfn, int sfn_len) {
4001840c:	9d e3 bf 90 	save  %sp, -112, %sp                           
    msdos_name_type_t type;                                           
    int               eno = 0;                                        
    int               i;                                              
    ssize_t           short_filename_length = sfn_len;                
    void             *buffer = converter->buffer.data;                
    size_t            codepage_name_len = converter->buffer.size;     
40018410:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
{                                                                     
    msdos_name_type_t type;                                           
    int               eno = 0;                                        
    int               i;                                              
    ssize_t           short_filename_length = sfn_len;                
    void             *buffer = converter->buffer.data;                
40018414:	e2 06 20 04 	ld  [ %i0 + 4 ], %l1                           
    size_t            codepage_name_len = converter->buffer.size;     
40018418:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
                                                                      
    /*                                                                
     * Fill with spaces. This is how a short directory entry is padded.
     */                                                               
    memset (sfn, ' ', sfn_len);                                       
4001841c:	90 10 00 1b 	mov  %i3, %o0                                  
40018420:	92 10 20 20 	mov  0x20, %o1                                 
40018424:	40 00 12 ae 	call  4001cedc <memset>                        
40018428:	94 10 00 1c 	mov  %i4, %o2                                  
                                                                      
    /*                                                                
     * Handle '.' and '..' specially.                                 
     */                                                               
    if ((lfn[0] == '.') && (lfn_len == 1))                            
4001842c:	c2 4e 40 00 	ldsb  [ %i1 ], %g1                             
40018430:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
40018434:	32 80 00 15 	bne,a   40018488 <msdos_long_to_short+0x7c>    
40018438:	82 10 20 00 	clr  %g1                                       
4001843c:	80 a6 a0 01 	cmp  %i2, 1                                    
40018440:	22 80 00 0c 	be,a   40018470 <msdos_long_to_short+0x64>     
40018444:	c2 2e c0 00 	stb  %g1, [ %i3 ]                              
        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))         
40018448:	c2 4e 60 01 	ldsb  [ %i1 + 1 ], %g1                         
4001844c:	80 a0 60 2e 	cmp  %g1, 0x2e                                 
40018450:	32 80 00 0e 	bne,a   40018488 <msdos_long_to_short+0x7c>    <== NEVER TAKEN
40018454:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
40018458:	80 a6 a0 02 	cmp  %i2, 2                                    
4001845c:	22 80 00 04 	be,a   4001846c <msdos_long_to_short+0x60>     
40018460:	c2 2e e0 01 	stb  %g1, [ %i3 + 1 ]                          
msdos_long_to_short(rtems_dosfs_convert_control     *converter,       
                    const char                      *lfn,             
                    int                              lfn_len,         
                    char                            *sfn,             
                    int                              sfn_len)         
{                                                                     
40018464:	10 80 00 09 	b  40018488 <msdos_long_to_short+0x7c>         
40018468:	82 10 20 00 	clr  %g1                                       
        return MSDOS_NAME_SHORT;                                      
    }                                                                 
                                                                      
    if ((lfn[0] == '.') && (lfn[1] == '.') && (lfn_len == 2))         
    {                                                                 
        sfn[0] = sfn[1] = '.';                                        
4001846c:	c2 2e c0 00 	stb  %g1, [ %i3 ]                              
#if MSDOS_L2S_PRINT                                                   
        printf ("MSDOS_L2S: SHORT[2]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif                                                                
        return MSDOS_NAME_SHORT;                                      
40018470:	81 c7 e0 08 	ret                                            
40018474:	91 e8 20 01 	restore  %g0, 1, %o0                           
                                                                      
    /*                                                                
     * Filenames with only blanks and dots are not allowed!           
     */                                                               
    for (i = 0; i < lfn_len; i++)                                     
        if ((lfn[i] != ' ') && (lfn[i] != '.'))                       
40018478:	80 a0 a0 2e 	cmp  %g2, 0x2e                                 
4001847c:	12 80 00 07 	bne  40018498 <msdos_long_to_short+0x8c>       
40018480:	80 a0 a0 20 	cmp  %g2, 0x20                                 
    }                                                                 
                                                                      
    /*                                                                
     * Filenames with only blanks and dots are not allowed!           
     */                                                               
    for (i = 0; i < lfn_len; i++)                                     
40018484:	82 00 60 01 	inc  %g1                                       
40018488:	80 a0 40 1a 	cmp  %g1, %i2                                  
4001848c:	26 bf ff fb 	bl,a   40018478 <msdos_long_to_short+0x6c>     
40018490:	c4 4e 40 01 	ldsb  [ %i1 + %g1 ], %g2                       
40018494:	30 80 00 05 	b,a   400184a8 <msdos_long_to_short+0x9c>      
        if ((lfn[i] != ' ') && (lfn[i] != '.'))                       
40018498:	22 bf ff fc 	be,a   40018488 <msdos_long_to_short+0x7c>     
4001849c:	82 00 60 01 	inc  %g1                                       
                                                                      
    /*                                                                
     * Is this a short name ?                                         
     */                                                               
                                                                      
    eno = (*converter->handler->utf8_to_codepage) (                   
400184a0:	10 80 00 06 	b  400184b8 <msdos_long_to_short+0xac>         
400184a4:	c2 06 00 00 	ld  [ %i0 ], %g1                               
     */                                                               
    for (i = 0; i < lfn_len; i++)                                     
        if ((lfn[i] != ' ') && (lfn[i] != '.'))                       
            break;                                                    
                                                                      
    if (i == lfn_len)                                                 
400184a8:	32 80 00 04 	bne,a   400184b8 <msdos_long_to_short+0xac>    <== NEVER TAKEN
400184ac:	c2 06 00 00 	ld  [ %i0 ], %g1                               <== NOT EXECUTED
    {                                                                 
#if MSDOS_L2S_PRINT                                                   
        printf ("MSDOS_L2S: INVALID[1]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif                                                                
        return MSDOS_NAME_INVALID;                                    
400184b0:	81 c7 e0 08 	ret                                            
400184b4:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      
    /*                                                                
     * Is this a short name ?                                         
     */                                                               
                                                                      
    eno = (*converter->handler->utf8_to_codepage) (                   
400184b8:	90 10 00 18 	mov  %i0, %o0                                  
400184bc:	c2 00 40 00 	ld  [ %g1 ], %g1                               
400184c0:	92 10 00 19 	mov  %i1, %o1                                  
400184c4:	94 10 00 1a 	mov  %i2, %o2                                  
400184c8:	96 10 00 11 	mov  %l1, %o3                                  
400184cc:	9f c0 40 00 	call  %g1                                      
400184d0:	98 07 bf fc 	add  %fp, -4, %o4                              
        converter,                                                    
        (const uint8_t*)&lfn[0],                                      
        lfn_len,                                                      
        buffer,                                                       
        &codepage_name_len);                                          
    if (eno == EINVAL)                                                
400184d4:	80 a2 20 16 	cmp  %o0, 0x16                                 
400184d8:	02 80 00 5c 	be  40018648 <msdos_long_to_short+0x23c>       
400184dc:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
msdos_name_type(const char *name, int name_len)                       
{                                                                     
    bool lowercase = false;                                           
    bool uppercase = false;                                           
    int  dot_at = -1;                                                 
    int  count = 0;                                                   
400184e0:	a0 10 20 00 	clr  %l0                                       
        eno = 0;                                                      
        type = MSDOS_NAME_LONG;                                       
    }                                                                 
    else                                                              
    {                                                                 
        type = msdos_name_type (                                      
400184e4:	c2 27 bf f4 	st  %g1, [ %fp + -12 ]                         
msdos_is_valid_name_char(const char ch)                               
{                                                                     
    if (strchr(" +,;=[]", ch) != NULL)                                
        return MSDOS_NAME_LONG;                                       
                                                                      
    if ((ch == '.') || isalnum((unsigned char)ch) ||                  
400184e8:	03 10 00 b7 	sethi  %hi(0x4002dc00), %g1                    
400184ec:	c2 00 62 0c 	ld  [ %g1 + 0x20c ], %g1	! 4002de0c <__ctype_ptr__>
static msdos_name_type_t                                              
msdos_name_type(const char *name, int name_len)                       
{                                                                     
    bool lowercase = false;                                           
    bool uppercase = false;                                           
    int  dot_at = -1;                                                 
400184f0:	aa 10 3f ff 	mov  -1, %l5                                   
msdos_is_valid_name_char(const char ch)                               
{                                                                     
    if (strchr(" +,;=[]", ch) != NULL)                                
        return MSDOS_NAME_LONG;                                       
                                                                      
    if ((ch == '.') || isalnum((unsigned char)ch) ||                  
400184f4:	c2 27 bf f0 	st  %g1, [ %fp + -16 ]                         
#define MSDOS_NAME_TYPE_PRINT 0                                       
static msdos_name_type_t                                              
msdos_name_type(const char *name, int name_len)                       
{                                                                     
    bool lowercase = false;                                           
    bool uppercase = false;                                           
400184f8:	a6 10 20 00 	clr  %l3                                       
 */                                                                   
#define MSDOS_NAME_TYPE_PRINT 0                                       
static msdos_name_type_t                                              
msdos_name_type(const char *name, int name_len)                       
{                                                                     
    bool lowercase = false;                                           
400184fc:	a4 10 20 00 	clr  %l2                                       
    bool uppercase = false;                                           
    int  dot_at = -1;                                                 
    int  count = 0;                                                   
                                                                      
    while (*name && (count < name_len))                               
40018500:	ec 4c 40 10 	ldsb  [ %l1 + %l0 ], %l6                       
40018504:	80 a5 a0 00 	cmp  %l6, 0                                    
40018508:	12 80 00 09 	bne  4001852c <msdos_long_to_short+0x120>      
4001850c:	e8 0c 40 10 	ldub  [ %l1 + %l0 ], %l4                       
                                                                      
        count++;                                                      
        name++;                                                       
    }                                                                 
                                                                      
    if (lowercase && uppercase)                                       
40018510:	80 8c e0 ff 	btst  0xff, %l3                                
40018514:	02 80 00 04 	be  40018524 <msdos_long_to_short+0x118>       
40018518:	80 8c a0 ff 	btst  0xff, %l2                                
4001851c:	32 80 00 4c 	bne,a   4001864c <msdos_long_to_short+0x240>   
40018520:	ba 10 20 02 	mov  2, %i5                                    
    }                                                                 
                                                                      
#if MSDOS_NAME_TYPE_PRINT                                             
    printf ("MSDOS_NAME_TYPE: SHORT[1]\n");                           
#endif                                                                
    return MSDOS_NAME_SHORT;                                          
40018524:	10 80 00 4a 	b  4001864c <msdos_long_to_short+0x240>        
40018528:	ba 10 20 01 	mov  1, %i5                                    
    bool lowercase = false;                                           
    bool uppercase = false;                                           
    int  dot_at = -1;                                                 
    int  count = 0;                                                   
                                                                      
    while (*name && (count < name_len))                               
4001852c:	c2 07 bf f4 	ld  [ %fp + -12 ], %g1                         
40018530:	80 a4 00 01 	cmp  %l0, %g1                                  
40018534:	16 bf ff f7 	bge  40018510 <msdos_long_to_short+0x104>      
40018538:	84 1d a0 2e 	xor  %l6, 0x2e, %g2                            
    {                                                                 
        bool is_dot = *name == '.';                                   
4001853c:	80 a0 00 02 	cmp  %g0, %g2                                  
 *                                                                    
 */                                                                   
static msdos_name_type_t                                              
msdos_is_valid_name_char(const char ch)                               
{                                                                     
    if (strchr(" +,;=[]", ch) != NULL)                                
40018540:	11 10 00 b4 	sethi  %hi(0x4002d000), %o0                    
    int  dot_at = -1;                                                 
    int  count = 0;                                                   
                                                                      
    while (*name && (count < name_len))                               
    {                                                                 
        bool is_dot = *name == '.';                                   
40018544:	ae 60 3f ff 	subx  %g0, -1, %l7                             
 *                                                                    
 */                                                                   
static msdos_name_type_t                                              
msdos_is_valid_name_char(const char ch)                               
{                                                                     
    if (strchr(" +,;=[]", ch) != NULL)                                
40018548:	90 12 22 f8 	or  %o0, 0x2f8, %o0                            
4001854c:	92 10 00 16 	mov  %l6, %o1                                  
40018550:	40 00 16 03 	call  4001dd5c <strchr>                        
40018554:	ba 10 20 02 	mov  2, %i5                                    
40018558:	80 a2 20 00 	cmp  %o0, 0                                    
4001855c:	12 80 00 16 	bne  400185b4 <msdos_long_to_short+0x1a8>      
40018560:	80 8f 60 01 	btst  1, %i5                                   
        return MSDOS_NAME_LONG;                                       
                                                                      
    if ((ch == '.') || isalnum((unsigned char)ch) ||                  
40018564:	80 a5 e0 00 	cmp  %l7, 0                                    
40018568:	12 80 00 11 	bne  400185ac <msdos_long_to_short+0x1a0>      
4001856c:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
40018570:	ba 0d 20 ff 	and  %l4, 0xff, %i5                            
40018574:	ba 00 40 1d 	add  %g1, %i5, %i5                             
40018578:	de 0f 60 01 	ldub  [ %i5 + 1 ], %o7                         
4001857c:	80 8b e0 07 	btst  7, %o7                                   
40018580:	12 80 00 0c 	bne  400185b0 <msdos_long_to_short+0x1a4>      
40018584:	ba 10 20 01 	mov  1, %i5                                    
        (strchr("$%'-_@~`!(){}^#&", ch) != NULL) || (unsigned char) ch > 127)
40018588:	11 10 00 b4 	sethi  %hi(0x4002d000), %o0                    
4001858c:	92 10 00 16 	mov  %l6, %o1                                  
40018590:	40 00 15 f3 	call  4001dd5c <strchr>                        
40018594:	90 12 23 00 	or  %o0, 0x300, %o0                            
msdos_is_valid_name_char(const char ch)                               
{                                                                     
    if (strchr(" +,;=[]", ch) != NULL)                                
        return MSDOS_NAME_LONG;                                       
                                                                      
    if ((ch == '.') || isalnum((unsigned char)ch) ||                  
40018598:	80 a2 20 00 	cmp  %o0, 0                                    
4001859c:	22 80 00 05 	be,a   400185b0 <msdos_long_to_short+0x1a4>    
400185a0:	bb 35 a0 1f 	srl  %l6, 0x1f, %i5                            
                                                                      
#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))
400185a4:	10 80 00 04 	b  400185b4 <msdos_long_to_short+0x1a8>        
400185a8:	80 8f 60 01 	btst  1, %i5                                   
    if (strchr(" +,;=[]", ch) != NULL)                                
        return MSDOS_NAME_LONG;                                       
                                                                      
    if ((ch == '.') || isalnum((unsigned char)ch) ||                  
        (strchr("$%'-_@~`!(){}^#&", ch) != NULL) || (unsigned char) ch > 127)
        return MSDOS_NAME_SHORT;                                      
400185ac:	ba 10 20 01 	mov  1, %i5                                    
                                                                      
#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))
400185b0:	80 8f 60 01 	btst  1, %i5                                   
400185b4:	02 80 00 20 	be  40018634 <msdos_long_to_short+0x228>       
400185b8:	80 a5 60 00 	cmp  %l5, 0                                    
            return type;                                              
                                                                      
        if (dot_at >= 0)                                              
400185bc:	06 80 00 09 	bl  400185e0 <msdos_long_to_short+0x1d4>       
400185c0:	80 a5 e0 00 	cmp  %l7, 0                                    
        {                                                             
            if (is_dot || ((count - dot_at) > 3))                     
400185c4:	12 80 00 21 	bne  40018648 <msdos_long_to_short+0x23c>      
400185c8:	82 24 00 15 	sub  %l0, %l5, %g1                             
400185cc:	80 a0 60 03 	cmp  %g1, 3                                    
400185d0:	04 80 00 0c 	ble  40018600 <msdos_long_to_short+0x1f4>      <== ALWAYS TAKEN
400185d4:	82 05 3f bf 	add  %l4, -65, %g1                             
        buffer,                                                       
        &codepage_name_len);                                          
    if (eno == EINVAL)                                                
    {                                                                 
        eno = 0;                                                      
        type = MSDOS_NAME_LONG;                                       
400185d8:	10 80 00 1d 	b  4001864c <msdos_long_to_short+0x240>        <== NOT EXECUTED
400185dc:	ba 10 20 02 	mov  2, %i5                                    <== NOT EXECUTED
                return MSDOS_NAME_LONG;                               
            }                                                         
        }                                                             
        else                                                          
        {                                                             
            if (count == 8 && !is_dot)                                
400185e0:	32 80 00 13 	bne,a   4001862c <msdos_long_to_short+0x220>   
400185e4:	aa 10 00 10 	mov  %l0, %l5                                  
400185e8:	80 a4 20 08 	cmp  %l0, 8                                    
400185ec:	02 80 00 17 	be  40018648 <msdos_long_to_short+0x23c>       
400185f0:	80 a5 e0 00 	cmp  %l7, 0                                    
#endif                                                                
                return MSDOS_NAME_LONG;                               
            }                                                         
        }                                                             
                                                                      
        if (is_dot)                                                   
400185f4:	32 80 00 0e 	bne,a   4001862c <msdos_long_to_short+0x220>   <== NEVER TAKEN
400185f8:	aa 10 00 10 	mov  %l0, %l5                                  <== NOT EXECUTED
            dot_at = count;                                           
        else if ((*name >= 'A') && (*name <= 'Z'))                    
400185fc:	82 05 3f bf 	add  %l4, -65, %g1                             
40018600:	82 08 60 ff 	and  %g1, 0xff, %g1                            
40018604:	80 a0 60 19 	cmp  %g1, 0x19                                 
40018608:	28 80 00 09 	bleu,a   4001862c <msdos_long_to_short+0x220>  
4001860c:	a6 10 20 01 	mov  1, %l3                                    
            uppercase = true;                                         
        else if ((*name >= 'a') && (*name <= 'z'))                    
40018610:	86 05 3f 9f 	add  %l4, -97, %g3                             
40018614:	86 08 e0 ff 	and  %g3, 0xff, %g3                            
40018618:	80 a0 e0 19 	cmp  %g3, 0x19                                 
4001861c:	28 80 00 04 	bleu,a   4001862c <msdos_long_to_short+0x220>  
40018620:	a4 10 20 01 	mov  1, %l2                                    
            lowercase = true;                                         
                                                                      
        count++;                                                      
40018624:	10 bf ff b7 	b  40018500 <msdos_long_to_short+0xf4>         
40018628:	a0 04 20 01 	inc  %l0                                       
4001862c:	10 bf ff b5 	b  40018500 <msdos_long_to_short+0xf4>         
40018630:	a0 04 20 01 	inc  %l0                                       
        type = msdos_name_type (                                      
            buffer,                                                   
            codepage_name_len);                                       
    }                                                                 
                                                                      
    if (type != MSDOS_NAME_INVALID)                                   
40018634:	80 a7 60 00 	cmp  %i5, 0                                    
40018638:	02 bf ff 9e 	be  400184b0 <msdos_long_to_short+0xa4>        
4001863c:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        short_filename_length = msdos_filename_utf8_to_short_name_for_save (
40018640:	10 80 00 05 	b  40018654 <msdos_long_to_short+0x248>        
40018644:	92 10 00 19 	mov  %i1, %o1                                  
        buffer,                                                       
        &codepage_name_len);                                          
    if (eno == EINVAL)                                                
    {                                                                 
        eno = 0;                                                      
        type = MSDOS_NAME_LONG;                                       
40018648:	ba 10 20 02 	mov  2, %i5                                    
            codepage_name_len);                                       
    }                                                                 
                                                                      
    if (type != MSDOS_NAME_INVALID)                                   
    {                                                                 
        short_filename_length = msdos_filename_utf8_to_short_name_for_save (
4001864c:	90 10 00 18 	mov  %i0, %o0                                  
40018650:	92 10 00 19 	mov  %i1, %o1                                  
40018654:	94 10 00 1a 	mov  %i2, %o2                                  
40018658:	96 10 00 1b 	mov  %i3, %o3                                  
4001865c:	98 10 00 1c 	mov  %i4, %o4                                  
40018660:	40 00 0c 43 	call  4001b76c <msdos_filename_utf8_to_short_name_for_save>
40018664:	b0 10 20 00 	clr  %i0                                       
            converter,                                                
            (const uint8_t*)lfn,                                      
            lfn_len,                                                  
            sfn,                                                      
            short_filename_length);                                   
        if (short_filename_length < 0 ) {                             
40018668:	80 a2 20 00 	cmp  %o0, 0                                    
4001866c:	06 80 00 03 	bl  40018678 <msdos_long_to_short+0x26c>       <== NEVER TAKEN
40018670:	01 00 00 00 	nop                                            
40018674:	b0 10 00 1d 	mov  %i5, %i0                                  
        printf ("MSDOS_L2S: INVALID[2]: lfn:'%s' SFN:'%s'\n", lfn, sfn);
#endif                                                                
    }                                                                 
                                                                      
    return type;                                                      
}                                                                     
40018678:	81 c7 e0 08 	ret                                            
4001867c:	81 e8 00 00 	restore                                        
                                                                      

4000e5bc <msdos_mknod>: const char *name, size_t namelen, mode_t mode, dev_t dev ) {
4000e5bc:	9d e3 bf a0 	save  %sp, -96, %sp                            
    msdos_node_type_t    type = 0;                                    
                                                                      
    /*                                                                
     *  Figure out what type of msdos node this is.                   
     */                                                               
    if (S_ISDIR(mode))                                                
4000e5c0:	05 00 00 3c 	sethi  %hi(0xf000), %g2                        
4000e5c4:	03 00 00 10 	sethi  %hi(0x4000), %g1                        
4000e5c8:	84 0e c0 02 	and  %i3, %g2, %g2                             
    const char *name,                                                 
    size_t namelen,                                                   
    mode_t mode,                                                      
    dev_t dev                                                         
)                                                                     
{                                                                     
4000e5cc:	88 10 00 19 	mov  %i1, %g4                                  
4000e5d0:	86 10 00 1a 	mov  %i2, %g3                                  
    msdos_node_type_t    type = 0;                                    
                                                                      
    /*                                                                
     *  Figure out what type of msdos node this is.                   
     */                                                               
    if (S_ISDIR(mode))                                                
4000e5d4:	80 a0 80 01 	cmp  %g2, %g1                                  
4000e5d8:	02 80 00 07 	be  4000e5f4 <msdos_mknod+0x38>                
4000e5dc:	b8 10 00 1b 	mov  %i3, %i4                                  
    {                                                                 
       type = MSDOS_DIRECTORY;                                        
    }                                                                 
    else if (S_ISREG(mode))                                           
4000e5e0:	3b 00 00 20 	sethi  %hi(0x8000), %i5                        
4000e5e4:	80 a0 80 1d 	cmp  %g2, %i5                                  
4000e5e8:	02 80 00 04 	be  4000e5f8 <msdos_mknod+0x3c>                <== ALWAYS TAKEN
4000e5ec:	b2 10 20 04 	mov  4, %i1                                    
4000e5f0:	30 80 00 06 	b,a   4000e608 <msdos_mknod+0x4c>              <== NOT EXECUTED
    /*                                                                
     *  Figure out what type of msdos node this is.                   
     */                                                               
    if (S_ISDIR(mode))                                                
    {                                                                 
       type = MSDOS_DIRECTORY;                                        
4000e5f4:	b2 10 20 00 	clr  %i1                                       
    }                                                                 
    else                                                              
        rtems_set_errno_and_return_minus_one(EINVAL);                 
                                                                      
    /* Create an MSDOS node */                                        
    rc = msdos_creat_node(parentloc, type, name, namelen, mode, NULL);
4000e5f8:	b4 10 00 04 	mov  %g4, %i2                                  
4000e5fc:	b6 10 00 03 	mov  %g3, %i3                                  
4000e600:	40 00 25 dc 	call  40017d70 <msdos_creat_node>              
4000e604:	9b e8 20 00 	restore  %g0, 0, %o5                           
    else if (S_ISREG(mode))                                           
    {                                                                 
        type = MSDOS_REGULAR_FILE;                                    
    }                                                                 
    else                                                              
        rtems_set_errno_and_return_minus_one(EINVAL);                 
4000e608:	40 00 37 a1 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e60c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4000e610:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
4000e614:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
                                                                      
    /* Create an MSDOS node */                                        
    rc = msdos_creat_node(parentloc, type, name, namelen, mode, NULL);
                                                                      
    return rc;                                                        
}                                                                     
4000e618:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e61c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40018360 <msdos_on_entry_found.isra.0>: return RC_OK; } #define MSDOS_FIND_PRINT 0 static int msdos_on_entry_found (
40018360:	9d e3 bf a0 	save  %sp, -96, %sp                            
#endif                                                                
    /*                                                                
     * We get the entry we looked for - fill the position             
     * structure and the 32 bytes of the short entry                  
     */                                                               
    rc = fat_file_ioctl(&fs_info->fat,                                
40018364:	d2 07 a0 5c 	ld  [ %fp + 0x5c ], %o1                        
40018368:	7f ff a8 ea 	call  40002710 <.umul>                         
4001836c:	90 10 00 1a 	mov  %i2, %o0                                  
    return RC_OK;                                                     
}                                                                     
                                                                      
#define MSDOS_FIND_PRINT 0                                            
static int                                                            
msdos_on_entry_found (                                                
40018370:	a2 10 00 18 	mov  %i0, %l1                                  
#endif                                                                
    /*                                                                
     * We get the entry we looked for - fill the position             
     * structure and the 32 bytes of the short entry                  
     */                                                               
    rc = fat_file_ioctl(&fs_info->fat,                                
40018374:	96 10 00 08 	mov  %o0, %o3                                  
    return RC_OK;                                                     
}                                                                     
                                                                      
#define MSDOS_FIND_PRINT 0                                            
static int                                                            
msdos_on_entry_found (                                                
40018378:	e0 07 a0 64 	ld  [ %fp + 0x64 ], %l0                        
#endif                                                                
    /*                                                                
     * We get the entry we looked for - fill the position             
     * structure and the 32 bytes of the short entry                  
     */                                                               
    rc = fat_file_ioctl(&fs_info->fat,                                
4001837c:	90 10 00 18 	mov  %i0, %o0                                  
40018380:	92 10 00 19 	mov  %i1, %o1                                  
40018384:	94 10 20 01 	mov  1, %o2                                    
40018388:	7f ff e9 0d 	call  400127bc <fat_file_ioctl>                
4001838c:	98 10 00 1d 	mov  %i5, %o4                                  
                        fat_fd,                                       
                        F_CLU_NUM,                                    
                        *dir_offset * bts2rd,                         
                        &dir_pos->sname.cln);                         
    if (rc == RC_OK) {                                                
40018390:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40018394:	12 80 00 0e 	bne  400183cc <msdos_on_entry_found.isra.0+0x6c><== NEVER TAKEN
40018398:	c2 07 a0 60 	ld  [ %fp + 0x60 ], %g1                        
        dir_pos->sname.ofs = dir_entry;                               
                                                                      
        if (lfn_start->cln != FAT_FILE_SHORT_NAME)                    
4001839c:	d2 04 00 00 	ld  [ %l0 ], %o1                               
400183a0:	80 a2 7f ff 	cmp  %o1, -1                                   
400183a4:	12 80 00 0c 	bne  400183d4 <msdos_on_entry_found.isra.0+0x74>
400183a8:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
                                 F_CLU_NUM,                           
                                 lfn_start->cln * bts2rd,             
                                 &lfn_start->cln);                    
        }                                                             
        if ( rc == RC_OK ) {                                          
            dir_pos->lname.cln = lfn_start->cln;                      
400183ac:	c2 04 00 00 	ld  [ %l0 ], %g1                               
            dir_pos->lname.ofs = lfn_start->ofs;                      
                                                                      
            memcpy(name_dir_entry, entry,                             
400183b0:	90 10 00 1b 	mov  %i3, %o0                                  
                                 F_CLU_NUM,                           
                                 lfn_start->cln * bts2rd,             
                                 &lfn_start->cln);                    
        }                                                             
        if ( rc == RC_OK ) {                                          
            dir_pos->lname.cln = lfn_start->cln;                      
400183b4:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
            dir_pos->lname.ofs = lfn_start->ofs;                      
400183b8:	c2 04 20 04 	ld  [ %l0 + 4 ], %g1                           
                                                                      
            memcpy(name_dir_entry, entry,                             
400183bc:	92 10 00 1c 	mov  %i4, %o1                                  
                                 lfn_start->cln * bts2rd,             
                                 &lfn_start->cln);                    
        }                                                             
        if ( rc == RC_OK ) {                                          
            dir_pos->lname.cln = lfn_start->cln;                      
            dir_pos->lname.ofs = lfn_start->ofs;                      
400183c0:	c2 27 60 0c 	st  %g1, [ %i5 + 0xc ]                         
                                                                      
            memcpy(name_dir_entry, entry,                             
400183c4:	40 00 12 87 	call  4001cde0 <memcpy>                        
400183c8:	94 10 20 20 	mov  0x20, %o2                                 
400183cc:	81 c7 e0 08 	ret                                            
400183d0:	81 e8 00 00 	restore                                        
    if (rc == RC_OK) {                                                
        dir_pos->sname.ofs = dir_entry;                               
                                                                      
        if (lfn_start->cln != FAT_FILE_SHORT_NAME)                    
        {                                                             
            rc = fat_file_ioctl (&fs_info->fat,                       
400183d4:	7f ff a8 cf 	call  40002710 <.umul>                         
400183d8:	90 10 00 1a 	mov  %i2, %o0                                  
400183dc:	92 10 00 19 	mov  %i1, %o1                                  
400183e0:	96 10 00 08 	mov  %o0, %o3                                  
400183e4:	94 10 20 01 	mov  1, %o2                                    
400183e8:	90 10 00 11 	mov  %l1, %o0                                  
400183ec:	7f ff e8 f4 	call  400127bc <fat_file_ioctl>                
400183f0:	98 10 00 10 	mov  %l0, %o4                                  
                                 fat_fd,                              
                                 F_CLU_NUM,                           
                                 lfn_start->cln * bts2rd,             
                                 &lfn_start->cln);                    
        }                                                             
        if ( rc == RC_OK ) {                                          
400183f4:	80 a2 20 00 	cmp  %o0, 0                                    
400183f8:	22 bf ff ee 	be,a   400183b0 <msdos_on_entry_found.isra.0+0x50><== ALWAYS TAKEN
400183fc:	c2 04 00 00 	ld  [ %l0 ], %g1                               
40018400:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
                   MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE);                
        }                                                             
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
40018404:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40018408:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e62c <msdos_rename>: const rtems_filesystem_location_info_t *old_loc, const rtems_filesystem_location_info_t *new_parent_loc, const char *new_name, size_t new_namelen ) {
4000e62c:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
    int                rc = RC_OK;                                    
    fat_file_fd_t     *old_fat_fd  = old_loc->node_access;            
4000e630:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           <== NOT EXECUTED
                                                                      
    /*                                                                
     * create new directory entry as "hard link", copying relevant info from
     * existing file                                                  
     */                                                               
    rc = msdos_creat_node(new_parent_loc,                             
4000e634:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
4000e638:	92 10 20 02 	mov  2, %o1                                    <== NOT EXECUTED
4000e63c:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
4000e640:	96 10 00 1c 	mov  %i4, %o3                                  <== NOT EXECUTED
4000e644:	19 00 00 20 	sethi  %hi(0x8000), %o4                        <== NOT EXECUTED
4000e648:	40 00 25 ca 	call  40017d70 <msdos_creat_node>              <== NOT EXECUTED
4000e64c:	9a 10 00 1d 	mov  %i5, %o5                                  <== NOT EXECUTED
                          MSDOS_HARD_LINK,new_name,new_namelen,S_IFREG,
                          old_fat_fd);                                
    if (rc != RC_OK)                                                  
4000e650:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
4000e654:	12 80 00 05 	bne  4000e668 <msdos_rename+0x3c>              <== NOT EXECUTED
4000e658:	b4 10 20 e5 	mov  0xe5, %i2                                 <== NOT EXECUTED
    }                                                                 
                                                                      
    /*                                                                
     * mark file removed                                              
     */                                                               
    rc = msdos_set_first_char4file_name(old_loc->mt_entry,            
4000e65c:	f0 06 60 14 	ld  [ %i1 + 0x14 ], %i0                        <== NOT EXECUTED
4000e660:	40 00 28 88 	call  40018880 <msdos_set_first_char4file_name><== NOT EXECUTED
4000e664:	93 ef 60 20 	restore  %i5, 0x20, %o1                        <== NOT EXECUTED
                                        &old_fat_fd->dir_pos,         
                                        MSDOS_THIS_DIR_ENTRY_EMPTY);  
                                                                      
    return rc;                                                        
}                                                                     
4000e668:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e66c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e670 <msdos_rmnod>: #include "msdos.h" int msdos_rmnod(const rtems_filesystem_location_info_t *parent_pathloc, const rtems_filesystem_location_info_t *pathloc) {
4000e670:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                rc = RC_OK;                                    
    msdos_fs_info_t   *fs_info = pathloc->mt_entry->fs_info;          
    fat_file_fd_t     *fat_fd = pathloc->node_access;                 
4000e674:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           
int                                                                   
msdos_rmnod(const rtems_filesystem_location_info_t *parent_pathloc,   
            const rtems_filesystem_location_info_t *pathloc)          
{                                                                     
    int                rc = RC_OK;                                    
    msdos_fs_info_t   *fs_info = pathloc->mt_entry->fs_info;          
4000e678:	d0 06 60 14 	ld  [ %i1 + 0x14 ], %o0                        
    fat_file_fd_t     *fat_fd = pathloc->node_access;                 
                                                                      
    if (fat_fd->fat_file_type == MSDOS_DIRECTORY)                     
4000e67c:	c4 07 60 10 	ld  [ %i5 + 0x10 ], %g2                        
4000e680:	80 a0 a0 00 	cmp  %g2, 0                                    
4000e684:	12 80 00 19 	bne  4000e6e8 <msdos_rmnod+0x78>               
4000e688:	f8 02 20 08 	ld  [ %o0 + 8 ], %i4                           
    {                                                                 
        bool is_empty = false;                                        
4000e68c:	c0 2f bf ff 	clrb  [ %fp + -1 ]                             
                                                                      
        /*                                                            
         * You cannot remove a node that still has children           
         */                                                           
        rc = msdos_dir_is_empty(pathloc->mt_entry, fat_fd, &is_empty);
4000e690:	92 10 00 1d 	mov  %i5, %o1                                  
4000e694:	40 00 28 c6 	call  400189ac <msdos_dir_is_empty>            
4000e698:	94 07 bf ff 	add  %fp, -1, %o2                              
        if (rc != RC_OK)                                              
4000e69c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e6a0:	12 80 00 1a 	bne  4000e708 <msdos_rmnod+0x98>               <== NEVER TAKEN
4000e6a4:	c2 0f bf ff 	ldub  [ %fp + -1 ], %g1                        
        {                                                             
            return rc;                                                
        }                                                             
                                                                      
        if (!is_empty)                                                
4000e6a8:	80 a0 60 00 	cmp  %g1, 0                                    
4000e6ac:	32 80 00 06 	bne,a   4000e6c4 <msdos_rmnod+0x54>            
4000e6b0:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
        {                                                             
            rtems_set_errno_and_return_minus_one(ENOTEMPTY);          
4000e6b4:	40 00 37 76 	call  4001c48c <__errno>                       
4000e6b8:	01 00 00 00 	nop                                            
4000e6bc:	10 80 00 08 	b  4000e6dc <msdos_rmnod+0x6c>                 
4000e6c0:	82 10 20 5a 	mov  0x5a, %g1	! 5a <_TLS_Alignment+0x59>      
                                                                      
        /*                                                            
         * We deny attempts to delete open directory (if directory is current
         * directory we assume it is open one)                        
         */                                                           
        if (fat_fd->links_num > 1)                                    
4000e6c4:	80 a0 60 01 	cmp  %g1, 1                                    
4000e6c8:	28 80 00 08 	bleu,a   4000e6e8 <msdos_rmnod+0x78>           <== ALWAYS TAKEN
4000e6cc:	d0 06 60 14 	ld  [ %i1 + 0x14 ], %o0                        
        {                                                             
            rtems_set_errno_and_return_minus_one(EBUSY);              
4000e6d0:	40 00 37 6f 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e6d4:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000e6d8:	82 10 20 10 	mov  0x10, %g1	! 10 <_TLS_Alignment+0xf>       <== NOT EXECUTED
4000e6dc:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000e6e0:	81 c7 e0 08 	ret                                            
4000e6e4:	91 e8 3f ff 	restore  %g0, -1, %o0                          
         * not used - mount() not implemenetd yet.                    
         */                                                           
    }                                                                 
                                                                      
    /* mark file removed */                                           
    rc = msdos_set_first_char4file_name(pathloc->mt_entry, &fat_fd->dir_pos,
4000e6e8:	92 07 60 20 	add  %i5, 0x20, %o1                            
4000e6ec:	40 00 28 65 	call  40018880 <msdos_set_first_char4file_name>
4000e6f0:	94 10 20 e5 	mov  0xe5, %o2                                 
                                        MSDOS_THIS_DIR_ENTRY_EMPTY);  
    if (rc != RC_OK)                                                  
4000e6f4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e6f8:	12 80 00 04 	bne  4000e708 <msdos_rmnod+0x98>               <== NEVER TAKEN
4000e6fc:	90 10 00 1c 	mov  %i4, %o0                                  
    {                                                                 
        return rc;                                                    
    }                                                                 
                                                                      
    fat_file_mark_removed(&fs_info->fat, fat_fd);                     
4000e700:	40 00 11 82 	call  40012d08 <fat_file_mark_removed>         
4000e704:	92 10 00 1d 	mov  %i5, %o1                                  
                                                                      
    return rc;                                                        
}                                                                     
4000e708:	81 c7 e0 08 	ret                                            
4000e70c:	81 e8 00 00 	restore                                        
                                                                      

40018680 <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 ) {
40018680:	9d e3 bf 98 	save  %sp, -104, %sp                           
    uint16_t         time_val;                                        
    uint16_t         date;                                            
    uint32_t         sec = 0;                                         
    uint32_t         byte = 0;                                        
                                                                      
    msdos_date_unix2dos(fat_fd->mtime, &date, &time_val);             
40018684:	d0 06 60 40 	ld  [ %i1 + 0x40 ], %o0                        
    rtems_filesystem_mount_table_entry_t *mt_entry,                   
    fat_file_fd_t                        *fat_fd                      
    )                                                                 
{                                                                     
    ssize_t          ret1 = 0, ret2 = 0, ret3 = 0;                    
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
40018688:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
    uint16_t         time_val;                                        
    uint16_t         date;                                            
    uint32_t         sec = 0;                                         
    uint32_t         byte = 0;                                        
                                                                      
    msdos_date_unix2dos(fat_fd->mtime, &date, &time_val);             
4001868c:	94 07 bf fc 	add  %fp, -4, %o2                              
40018690:	40 00 0a d2 	call  4001b1d8 <msdos_date_unix2dos>           
40018694:	92 07 bf fe 	add  %fp, -2, %o1                              
                                                                      
    /*                                                                
     * calculate input for fat_sector_write: convert (cluster num, offset) to
     * (sector num, new offset)                                       
     */                                                               
    sec = fat_cluster_num_to_sector_num(&fs_info->fat, fat_fd->dir_pos.sname.cln);
40018698:	d2 06 60 20 	ld  [ %i1 + 0x20 ], %o1                        
4001869c:	7f ff ff 02 	call  400182a4 <fat_cluster_num_to_sector_num> 
400186a0:	90 10 00 1d 	mov  %i5, %o0                                  
    sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);  
400186a4:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
    /* byte points to start of 32bytes structure */                   
    byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);    
400186a8:	f8 17 40 00 	lduh  [ %i5 ], %i4                             
    /*                                                                
     * calculate input for fat_sector_write: convert (cluster num, offset) to
     * (sector num, new offset)                                       
     */                                                               
    sec = fat_cluster_num_to_sector_num(&fs_info->fat, fat_fd->dir_pos.sname.cln);
    sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);  
400186ac:	f6 0f 60 02 	ldub  [ %i5 + 2 ], %i3                         
    /* byte points to start of 32bytes structure */                   
    byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);    
400186b0:	b8 07 3f ff 	add  %i4, -1, %i4                              
    /*                                                                
     * calculate input for fat_sector_write: convert (cluster num, offset) to
     * (sector num, new offset)                                       
     */                                                               
    sec = fat_cluster_num_to_sector_num(&fs_info->fat, fat_fd->dir_pos.sname.cln);
    sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);  
400186b4:	b7 30 40 1b 	srl  %g1, %i3, %i3                             
    /* byte points to start of 32bytes structure */                   
    byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);    
400186b8:	b8 0f 00 01 	and  %i4, %g1, %i4                             
                                                                      
    time_val = CT_LE_W(time_val);                                     
400186bc:	c2 17 bf fc 	lduh  [ %fp + -4 ], %g1                        
    /*                                                                
     * calculate input for fat_sector_write: convert (cluster num, offset) to
     * (sector num, new offset)                                       
     */                                                               
    sec = fat_cluster_num_to_sector_num(&fs_info->fat, fat_fd->dir_pos.sname.cln);
    sec += (fat_fd->dir_pos.sname.ofs >> fs_info->fat.vol.sec_log2);  
400186c0:	b6 02 00 1b 	add  %o0, %i3, %i3                             
    /* 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);                                     
400186c4:	83 28 60 10 	sll  %g1, 0x10, %g1                            
400186c8:	85 30 60 08 	srl  %g1, 8, %g2                               
400186cc:	83 30 60 18 	srl  %g1, 0x18, %g1                            
400186d0:	82 10 80 01 	or  %g2, %g1, %g1                              
    ret1 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WTIME_OFFSET,
400186d4:	92 10 00 1b 	mov  %i3, %o1                                  
    sec = fat_cluster_num_to_sector_num(&fs_info->fat, 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);                                     
400186d8:	c2 37 bf fc 	sth  %g1, [ %fp + -4 ]                         
    ret1 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WTIME_OFFSET,
400186dc:	94 07 20 16 	add  %i4, 0x16, %o2                            
400186e0:	96 10 20 02 	mov  2, %o3                                    
400186e4:	98 07 bf fc 	add  %fp, -4, %o4                              
400186e8:	7f ff ea ac 	call  40013198 <fat_sector_write>              
400186ec:	90 10 00 1d 	mov  %i5, %o0                                  
                            2, (char *)(&time_val));                  
    date = CT_LE_W(date);                                             
400186f0:	c2 17 bf fe 	lduh  [ %fp + -2 ], %g1                        
    ret2 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WDATE_OFFSET,
400186f4:	92 10 00 1b 	mov  %i3, %o1                                  
    byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);    
                                                                      
    time_val = CT_LE_W(time_val);                                     
    ret1 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WTIME_OFFSET,
                            2, (char *)(&time_val));                  
    date = CT_LE_W(date);                                             
400186f8:	83 28 60 10 	sll  %g1, 0x10, %g1                            
400186fc:	85 30 60 08 	srl  %g1, 8, %g2                               
40018700:	83 30 60 18 	srl  %g1, 0x18, %g1                            
40018704:	82 10 80 01 	or  %g2, %g1, %g1                              
    ret2 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WDATE_OFFSET,
40018708:	94 07 20 18 	add  %i4, 0x18, %o2                            
    byte = fat_fd->dir_pos.sname.ofs & (fs_info->fat.vol.bps - 1);    
                                                                      
    time_val = CT_LE_W(time_val);                                     
    ret1 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WTIME_OFFSET,
                            2, (char *)(&time_val));                  
    date = CT_LE_W(date);                                             
4001870c:	c2 37 bf fe 	sth  %g1, [ %fp + -2 ]                         
    ret2 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WDATE_OFFSET,
40018710:	96 10 20 02 	mov  2, %o3                                    
40018714:	98 07 bf fe 	add  %fp, -2, %o4                              
    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_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WTIME_OFFSET,
40018718:	b4 10 00 08 	mov  %o0, %i2                                  
                            2, (char *)(&time_val));                  
    date = CT_LE_W(date);                                             
    ret2 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WDATE_OFFSET,
4001871c:	7f ff ea 9f 	call  40013198 <fat_sector_write>              
40018720:	90 10 00 1d 	mov  %i5, %o0                                  
                            2, (char *)(&date));                      
    ret3 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_ADATE_OFFSET,
40018724:	92 10 00 1b 	mov  %i3, %o1                                  
                                                                      
    time_val = CT_LE_W(time_val);                                     
    ret1 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WTIME_OFFSET,
                            2, (char *)(&time_val));                  
    date = CT_LE_W(date);                                             
    ret2 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_WDATE_OFFSET,
40018728:	b2 10 00 08 	mov  %o0, %i1                                  
                            2, (char *)(&date));                      
    ret3 = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_ADATE_OFFSET,
4001872c:	94 07 20 12 	add  %i4, 0x12, %o2                            
40018730:	90 10 00 1d 	mov  %i5, %o0                                  
40018734:	96 10 20 02 	mov  2, %o3                                    
40018738:	7f ff ea 98 	call  40013198 <fat_sector_write>              
4001873c:	98 07 bf fe 	add  %fp, -2, %o4                              
                            2, (char *)(&date));                      
                                                                      
    if ( (ret1 < 0) || (ret2 < 0) || (ret3 < 0) )                     
40018740:	80 a6 60 00 	cmp  %i1, 0                                    
40018744:	06 80 00 07 	bl  40018760 <msdos_set_dir_wrt_time_and_date+0xe0><== NEVER TAKEN
40018748:	80 a6 a0 00 	cmp  %i2, 0                                    
4001874c:	06 80 00 05 	bl  40018760 <msdos_set_dir_wrt_time_and_date+0xe0><== NEVER TAKEN
40018750:	01 00 00 00 	nop                                            
40018754:	b1 3a 20 1f 	sra  %o0, 0x1f, %i0                            
40018758:	81 c7 e0 08 	ret                                            
4001875c:	81 e8 00 00 	restore                                        
        return -1;                                                    
                                                                      
    return RC_OK;                                                     
}                                                                     
40018760:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40018764:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      

40018880 <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 ) {
40018880:	9d e3 bf 98 	save  %sp, -104, %sp                           
    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;                          
40018884:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
    fat_dir_pos_t                        *dir_pos,                    
    unsigned char                         fchar                       
    )                                                                 
{                                                                     
    ssize_t          ret;                                             
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
40018888:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
    uint32_t         dir_block_size;                                  
    fat_pos_t        start = dir_pos->lname;                          
4001888c:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
40018890:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
    fat_pos_t        end = dir_pos->sname;                            
40018894:	f8 06 40 00 	ld  [ %i1 ], %i4                               
    )                                                                 
{                                                                     
    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;                          
40018898:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
    fat_pos_t        end = dir_pos->sname;                            
                                                                      
    if ((end.cln == fs_info->fat.vol.rdir_cl) &&                      
4001889c:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
msdos_set_first_char4file_name(                                       
    rtems_filesystem_mount_table_entry_t *mt_entry,                   
    fat_dir_pos_t                        *dir_pos,                    
    unsigned char                         fchar                       
    )                                                                 
{                                                                     
400188a0:	f4 2f a0 4c 	stb  %i2, [ %fp + 0x4c ]                       
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
    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) &&                      
400188a4:	80 a7 00 01 	cmp  %i4, %g1                                  
400188a8:	12 80 00 08 	bne  400188c8 <msdos_set_first_char4file_name+0x48>
400188ac:	f4 06 60 04 	ld  [ %i1 + 4 ], %i2                           
        (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))            
400188b0:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       
    msdos_fs_info_t *fs_info = mt_entry->fs_info;                     
    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) &&                      
400188b4:	80 88 60 03 	btst  3, %g1                                   
400188b8:	22 80 00 05 	be,a   400188cc <msdos_set_first_char4file_name+0x4c><== NEVER TAKEN
400188bc:	f6 17 60 06 	lduh  [ %i5 + 6 ], %i3                         <== NOT EXECUTED
        (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))            
      dir_block_size = fs_info->fat.vol.rdir_size;                    
400188c0:	10 80 00 03 	b  400188cc <msdos_set_first_char4file_name+0x4c>
400188c4:	f6 07 60 2c 	ld  [ %i5 + 0x2c ], %i3                        
    else                                                              
      dir_block_size = fs_info->fat.vol.bpc;                          
400188c8:	f6 17 60 06 	lduh  [ %i5 + 6 ], %i3                         
                                                                      
    if (dir_pos->lname.cln == FAT_FILE_SHORT_NAME)                    
400188cc:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
400188d0:	80 a0 7f ff 	cmp  %g1, -1                                   
400188d4:	12 80 00 07 	bne  400188f0 <msdos_set_first_char4file_name+0x70>
400188d8:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
      start = dir_pos->sname;                                         
400188dc:	c2 06 40 00 	ld  [ %i1 ], %g1                               
400188e0:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
400188e4:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
400188e8:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
     * name code was written rather than use the fat_file_write       
     * interface.                                                     
     */                                                               
    while (true)                                                      
    {                                                                 
      uint32_t sec = (fat_cluster_num_to_sector_num(&fs_info->fat, start.cln) +
400188ec:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
400188f0:	7f ff fe 6d 	call  400182a4 <fat_cluster_num_to_sector_num> 
400188f4:	90 10 00 1d 	mov  %i5, %o0                                  
                      (start.ofs >> fs_info->fat.vol.sec_log2));      
400188f8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
400188fc:	d2 0f 60 02 	ldub  [ %i5 + 2 ], %o1                         
      uint32_t byte = (start.ofs & (fs_info->fat.vol.bps - 1));       
40018900:	d4 17 40 00 	lduh  [ %i5 ], %o2                             
     * interface.                                                     
     */                                                               
    while (true)                                                      
    {                                                                 
      uint32_t sec = (fat_cluster_num_to_sector_num(&fs_info->fat, start.cln) +
                      (start.ofs >> fs_info->fat.vol.sec_log2));      
40018904:	93 30 40 09 	srl  %g1, %o1, %o1                             
      uint32_t byte = (start.ofs & (fs_info->fat.vol.bps - 1));       
40018908:	94 02 bf ff 	add  %o2, -1, %o2                              
     * name code was written rather than use the fat_file_write       
     * interface.                                                     
     */                                                               
    while (true)                                                      
    {                                                                 
      uint32_t sec = (fat_cluster_num_to_sector_num(&fs_info->fat, start.cln) +
4001890c:	92 02 00 09 	add  %o0, %o1, %o1                             
                      (start.ofs >> fs_info->fat.vol.sec_log2));      
      uint32_t byte = (start.ofs & (fs_info->fat.vol.bps - 1));       
                                                                      
      ret = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_NAME_OFFSET,
40018910:	94 0a 80 01 	and  %o2, %g1, %o2                             
40018914:	90 10 00 1d 	mov  %i5, %o0                                  
40018918:	96 10 20 01 	mov  1, %o3                                    
4001891c:	7f ff ea 1f 	call  40013198 <fat_sector_write>              
40018920:	98 07 a0 4c 	add  %fp, 0x4c, %o4                            
                             1, &fchar);                              
      if (ret < 0)                                                    
40018924:	80 a2 20 00 	cmp  %o0, 0                                    
40018928:	06 80 00 1d 	bl  4001899c <msdos_set_first_char4file_name+0x11c><== NEVER TAKEN
4001892c:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
        return -1;                                                    
                                                                      
      if ((start.cln == end.cln) && (start.ofs == end.ofs))           
40018930:	80 a2 40 1c 	cmp  %o1, %i4                                  
40018934:	12 80 00 07 	bne  40018950 <msdos_set_first_char4file_name+0xd0>
40018938:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4001893c:	80 a0 40 1a 	cmp  %g1, %i2                                  
40018940:	12 80 00 05 	bne  40018954 <msdos_set_first_char4file_name+0xd4>
40018944:	82 00 60 20 	add  %g1, 0x20, %g1                            
          return rc;                                                  
        start.ofs = 0;                                                
      }                                                               
    }                                                                 
                                                                      
    return  RC_OK;                                                    
40018948:	81 c7 e0 08 	ret                                            
4001894c:	91 e8 20 00 	restore  %g0, 0, %o0                           
        return -1;                                                    
                                                                      
      if ((start.cln == end.cln) && (start.ofs == end.ofs))           
        break;                                                        
                                                                      
      start.ofs += MSDOS_DIRECTORY_ENTRY_STRUCT_SIZE;                 
40018950:	82 00 60 20 	add  %g1, 0x20, %g1                            
      if (start.ofs >= dir_block_size)                                
40018954:	80 a0 40 1b 	cmp  %g1, %i3                                  
40018958:	0a bf ff e5 	bcs  400188ec <msdos_set_first_char4file_name+0x6c>
4001895c:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
      {                                                               
        int rc;                                                       
        if ((end.cln == fs_info->fat.vol.rdir_cl) &&                  
40018960:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
40018964:	80 a7 00 01 	cmp  %i4, %g1                                  
40018968:	12 80 00 06 	bne  40018980 <msdos_set_first_char4file_name+0x100><== ALWAYS TAKEN
4001896c:	90 10 00 1d 	mov  %i5, %o0                                  
            (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))        
40018970:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       <== 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) &&                  
40018974:	80 88 60 03 	btst  3, %g1                                   <== NOT EXECUTED
40018978:	12 bf ff f4 	bne  40018948 <msdos_set_first_char4file_name+0xc8><== NOT EXECUTED
4001897c:	01 00 00 00 	nop                                            <== NOT EXECUTED
            (fs_info->fat.vol.type & (FAT_FAT12 | FAT_FAT16)))        
          break;                                                      
        rc = fat_get_fat_cluster(&fs_info->fat, start.cln, &start.cln);
40018980:	7f ff e4 59 	call  40011ae4 <fat_get_fat_cluster>           
40018984:	94 07 bf f8 	add  %fp, -8, %o2                              
        if ( rc != RC_OK )                                            
40018988:	80 a2 20 00 	cmp  %o0, 0                                    
4001898c:	12 80 00 06 	bne  400189a4 <msdos_set_first_char4file_name+0x124><== NEVER TAKEN
40018990:	01 00 00 00 	nop                                            
          return rc;                                                  
        start.ofs = 0;                                                
40018994:	10 bf ff d6 	b  400188ec <msdos_set_first_char4file_name+0x6c>
40018998:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
      uint32_t byte = (start.ofs & (fs_info->fat.vol.bps - 1));       
                                                                      
      ret = fat_sector_write(&fs_info->fat, sec, byte + MSDOS_FILE_NAME_OFFSET,
                             1, &fchar);                              
      if (ret < 0)                                                    
        return -1;                                                    
4001899c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400189a0:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
        start.ofs = 0;                                                
      }                                                               
    }                                                                 
                                                                      
    return  RC_OK;                                                    
}                                                                     
400189a4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400189a8:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

4000d388 <msdos_set_sectors_per_cluster_from_request>: static int msdos_set_sectors_per_cluster_from_request( const msdos_format_request_param_t *rqdata, msdos_format_param_t *fmt_params ) {
4000d388:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int      ret_val = -1;                                              
  uint32_t onebit;                                                    
                                                                      
  if ( rqdata != NULL && rqdata->sectors_per_cluster > 0 ) {          
4000d38c:	80 a6 20 00 	cmp  %i0, 0                                    
4000d390:	02 80 00 07 	be  4000d3ac <msdos_set_sectors_per_cluster_from_request+0x24>
4000d394:	ba 10 20 80 	mov  0x80, %i5                                 
4000d398:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
4000d39c:	80 a0 60 00 	cmp  %g1, 0                                    
4000d3a0:	32 80 00 03 	bne,a   4000d3ac <msdos_set_sectors_per_cluster_from_request+0x24>
4000d3a4:	c2 26 60 0c 	st  %g1, [ %i1 + 0xc ]                         
                                                                      
static int                                                            
msdos_set_sectors_per_cluster_from_request(                           
  const msdos_format_request_param_t *rqdata,                         
  msdos_format_param_t               *fmt_params )                    
{                                                                     
4000d3a8:	ba 10 20 80 	mov  0x80, %i5                                 
4000d3ac:	b0 10 3f ff 	mov  -1, %i0                                   
   * 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 ) {                
4000d3b0:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
4000d3b4:	80 a0 40 1d 	cmp  %g1, %i5                                  
4000d3b8:	2a 80 00 0c 	bcs,a   4000d3e8 <msdos_set_sectors_per_cluster_from_request+0x60>
4000d3bc:	bb 37 60 01 	srl  %i5, 1, %i5                               
      fmt_params->sectors_per_cluster = onebit;                       
      if (   fmt_params->sectors_per_cluster                          
          <= 32768L / fmt_params->bytes_per_sector ) {                
4000d3c0:	d2 06 40 00 	ld  [ %i1 ], %o1                               
   * 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 ) {                
      fmt_params->sectors_per_cluster = onebit;                       
4000d3c4:	fa 26 60 0c 	st  %i5, [ %i1 + 0xc ]                         
      if (   fmt_params->sectors_per_cluster                          
          <= 32768L / fmt_params->bytes_per_sector ) {                
4000d3c8:	7f ff d5 0c 	call  400027f8 <.udiv>                         
4000d3cc:	11 00 00 20 	sethi  %hi(0x8000), %o0                        
   * 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 ) {                
      fmt_params->sectors_per_cluster = onebit;                       
      if (   fmt_params->sectors_per_cluster                          
4000d3d0:	80 a7 40 08 	cmp  %i5, %o0                                  
4000d3d4:	18 80 00 05 	bgu  4000d3e8 <msdos_set_sectors_per_cluster_from_request+0x60><== NEVER TAKEN
4000d3d8:	bb 37 60 01 	srl  %i5, 1, %i5                               
          <= 32768L / fmt_params->bytes_per_sector ) {                
        /* value is small enough so this value is ok */               
        onebit = 1;                                                   
4000d3dc:	ba 10 20 01 	mov  1, %i5                                    
        ret_val = 0;                                                  
4000d3e0:	b0 10 20 00 	clr  %i0                                       
   * 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 ) {           
4000d3e4:	bb 37 60 01 	srl  %i5, 1, %i5                               
4000d3e8:	80 a7 60 00 	cmp  %i5, 0                                    
4000d3ec:	32 bf ff f2 	bne,a   4000d3b4 <msdos_set_sectors_per_cluster_from_request+0x2c>
4000d3f0:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
        ret_val = 0;                                                  
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  if (ret_val != 0) {                                                 
4000d3f4:	80 a6 20 00 	cmp  %i0, 0                                    
4000d3f8:	02 80 00 06 	be  4000d410 <msdos_set_sectors_per_cluster_from_request+0x88><== ALWAYS TAKEN
4000d3fc:	01 00 00 00 	nop                                            
    errno = EINVAL;                                                   
4000d400:	40 00 3c 23 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000d404:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000d408:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
4000d40c:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return ret_val;                                                     
}                                                                     
4000d410:	81 c7 e0 08 	ret                                            
4000d414:	81 e8 00 00 	restore                                        
                                                                      

4000e710 <msdos_statvfs>: #include "msdos.h" int msdos_statvfs( const rtems_filesystem_location_info_t *__restrict root_loc, struct statvfs *__restrict sb) {
4000e710:	9d e3 bf 98 	save  %sp, -104, %sp                           <== NOT EXECUTED
  msdos_fs_info_t *fs_info = root_loc->mt_entry->fs_info;             
4000e714:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        <== NOT EXECUTED
  fat_vol_t *vol = &fs_info->fat.vol;                                 
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,          
4000e718:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
                                                                      
int msdos_statvfs(                                                    
  const rtems_filesystem_location_info_t *__restrict root_loc,        
  struct statvfs *__restrict sb)                                      
{                                                                     
  msdos_fs_info_t *fs_info = root_loc->mt_entry->fs_info;             
4000e71c:	f6 00 60 08 	ld  [ %g1 + 8 ], %i3                           <== NOT EXECUTED
  fat_vol_t *vol = &fs_info->fat.vol;                                 
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,          
4000e720:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4000e724:	7f ff ea be 	call  4000921c <rtems_semaphore_obtain>        <== NOT EXECUTED
4000e728:	d0 06 e0 9c 	ld  [ %i3 + 0x9c ], %o0                        <== NOT EXECUTED
                              MSDOS_VOLUME_SEMAPHORE_TIMEOUT);        
  if (sc != RTEMS_SUCCESSFUL)                                         
4000e72c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4000e730:	02 80 00 08 	be  4000e750 <msdos_statvfs+0x40>              <== NOT EXECUTED
4000e734:	82 10 22 00 	mov  0x200, %g1                                <== NOT EXECUTED
      rtems_set_errno_and_return_minus_one(EIO);                      
4000e738:	40 00 37 55 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e73c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4000e740:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
4000e744:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4000e748:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e74c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
  sb->f_bsize = FAT_SECTOR512_SIZE;                                   
4000e750:	c2 26 40 00 	st  %g1, [ %i1 ]                               <== NOT EXECUTED
  sb->f_frsize = vol->bpc;                                            
4000e754:	c2 16 e0 06 	lduh  [ %i3 + 6 ], %g1                         <== NOT EXECUTED
  sb->f_blocks = vol->data_cls;                                       
4000e758:	c4 06 e0 38 	ld  [ %i3 + 0x38 ], %g2                        <== NOT EXECUTED
                              MSDOS_VOLUME_SEMAPHORE_TIMEOUT);        
  if (sc != RTEMS_SUCCESSFUL)                                         
      rtems_set_errno_and_return_minus_one(EIO);                      
                                                                      
  sb->f_bsize = FAT_SECTOR512_SIZE;                                   
  sb->f_frsize = vol->bpc;                                            
4000e75c:	c2 26 60 04 	st  %g1, [ %i1 + 4 ]                           <== NOT EXECUTED
  sb->f_bavail = 0;                                                   
  sb->f_files = 0;    // FAT doesn't store inodes                     
  sb->f_ffree = 0;                                                    
  sb->f_favail = 0;                                                   
  sb->f_flag = 0;                                                     
  sb->f_namemax = MSDOS_NAME_MAX_LNF_LEN;                             
4000e760:	82 10 20 ff 	mov  0xff, %g1                                 <== NOT EXECUTED
4000e764:	c2 26 60 34 	st  %g1, [ %i1 + 0x34 ]                        <== NOT EXECUTED
                                                                      
  if (vol->free_cls == FAT_UNDEFINED_VALUE)                           
4000e768:	c2 06 e0 44 	ld  [ %i3 + 0x44 ], %g1                        <== NOT EXECUTED
  if (sc != RTEMS_SUCCESSFUL)                                         
      rtems_set_errno_and_return_minus_one(EIO);                      
                                                                      
  sb->f_bsize = FAT_SECTOR512_SIZE;                                   
  sb->f_frsize = vol->bpc;                                            
  sb->f_blocks = vol->data_cls;                                       
4000e76c:	c0 26 60 08 	clr  [ %i1 + 8 ]                               <== NOT EXECUTED
4000e770:	c4 26 60 0c 	st  %g2, [ %i1 + 0xc ]                         <== NOT EXECUTED
  sb->f_bfree = 0;                                                    
4000e774:	c0 26 60 10 	clr  [ %i1 + 0x10 ]                            <== NOT EXECUTED
4000e778:	c0 26 60 14 	clr  [ %i1 + 0x14 ]                            <== NOT EXECUTED
  sb->f_bavail = 0;                                                   
4000e77c:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            <== NOT EXECUTED
4000e780:	c0 26 60 1c 	clr  [ %i1 + 0x1c ]                            <== NOT EXECUTED
  sb->f_files = 0;    // FAT doesn't store inodes                     
4000e784:	c0 26 60 20 	clr  [ %i1 + 0x20 ]                            <== NOT EXECUTED
  sb->f_ffree = 0;                                                    
4000e788:	c0 26 60 24 	clr  [ %i1 + 0x24 ]                            <== NOT EXECUTED
  sb->f_favail = 0;                                                   
4000e78c:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            <== NOT EXECUTED
  sb->f_flag = 0;                                                     
  sb->f_namemax = MSDOS_NAME_MAX_LNF_LEN;                             
                                                                      
  if (vol->free_cls == FAT_UNDEFINED_VALUE)                           
4000e790:	80 a0 7f ff 	cmp  %g1, -1                                   <== NOT EXECUTED
4000e794:	12 80 00 1e 	bne  4000e80c <msdos_statvfs+0xfc>             <== NOT EXECUTED
4000e798:	c0 26 60 30 	clr  [ %i1 + 0x30 ]                            <== NOT EXECUTED
  {                                                                   
    int rc;                                                           
    uint32_t cur_cl = 2;                                              
    uint32_t value = 0;                                               
4000e79c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              <== NOT EXECUTED
    uint32_t data_cls_val = vol->data_cls + 2;                        
4000e7a0:	a0 00 a0 02 	add  %g2, 2, %l0                               <== NOT EXECUTED
  sb->f_namemax = MSDOS_NAME_MAX_LNF_LEN;                             
                                                                      
  if (vol->free_cls == FAT_UNDEFINED_VALUE)                           
  {                                                                   
    int rc;                                                           
    uint32_t cur_cl = 2;                                              
4000e7a4:	b4 10 20 02 	mov  2, %i2                                    <== NOT EXECUTED
    uint32_t value = 0;                                               
    uint32_t data_cls_val = vol->data_cls + 2;                        
                                                                      
    for (; cur_cl < data_cls_val; ++cur_cl)                           
4000e7a8:	80 a6 80 10 	cmp  %i2, %l0                                  <== NOT EXECUTED
4000e7ac:	1a 80 00 1c 	bcc  4000e81c <msdos_statvfs+0x10c>            <== NOT EXECUTED
4000e7b0:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
    {                                                                 
      rc = fat_get_fat_cluster(&fs_info->fat, cur_cl, &value);        
4000e7b4:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4000e7b8:	40 00 0c cb 	call  40011ae4 <fat_get_fat_cluster>           <== NOT EXECUTED
4000e7bc:	94 07 bf fc 	add  %fp, -4, %o2                              <== NOT EXECUTED
      if (rc != RC_OK)                                                
4000e7c0:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
4000e7c4:	02 80 00 06 	be  4000e7dc <msdos_statvfs+0xcc>              <== NOT EXECUTED
4000e7c8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          <== NOT EXECUTED
      {                                                               
        rtems_semaphore_release(fs_info->vol_sema);                   
4000e7cc:	7f ff ea dc 	call  4000933c <rtems_semaphore_release>       <== NOT EXECUTED
4000e7d0:	d0 06 e0 9c 	ld  [ %i3 + 0x9c ], %o0                        <== NOT EXECUTED
4000e7d4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e7d8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
        return rc;                                                    
      }                                                               
                                                                      
      if (value == FAT_GENFAT_FREE)                                   
4000e7dc:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e7e0:	12 bf ff f2 	bne  4000e7a8 <msdos_statvfs+0x98>             <== NOT EXECUTED
4000e7e4:	b4 06 a0 01 	inc  %i2                                       <== NOT EXECUTED
      {                                                               
        sb->f_bfree++;                                                
4000e7e8:	c4 1e 60 10 	ldd  [ %i1 + 0x10 ], %g2                       <== NOT EXECUTED
4000e7ec:	ba 80 e0 01 	addcc  %g3, 1, %i5                             <== NOT EXECUTED
4000e7f0:	b8 40 a0 00 	addx  %g2, 0, %i4                              <== NOT EXECUTED
        sb->f_bavail++;                                               
4000e7f4:	c4 1e 60 18 	ldd  [ %i1 + 0x18 ], %g2                       <== NOT EXECUTED
        return rc;                                                    
      }                                                               
                                                                      
      if (value == FAT_GENFAT_FREE)                                   
      {                                                               
        sb->f_bfree++;                                                
4000e7f8:	f8 3e 60 10 	std  %i4, [ %i1 + 0x10 ]                       <== NOT EXECUTED
        sb->f_bavail++;                                               
4000e7fc:	ba 80 e0 01 	addcc  %g3, 1, %i5                             <== NOT EXECUTED
4000e800:	b8 40 a0 00 	addx  %g2, 0, %i4                              <== NOT EXECUTED
4000e804:	10 bf ff e9 	b  4000e7a8 <msdos_statvfs+0x98>               <== NOT EXECUTED
4000e808:	f8 3e 60 18 	std  %i4, [ %i1 + 0x18 ]                       <== NOT EXECUTED
      }                                                               
    }                                                                 
  }                                                                   
  else                                                                
  {                                                                   
    sb->f_bfree = vol->free_cls;                                      
4000e80c:	c0 26 60 10 	clr  [ %i1 + 0x10 ]                            <== NOT EXECUTED
4000e810:	c2 26 60 14 	st  %g1, [ %i1 + 0x14 ]                        <== NOT EXECUTED
    sb->f_bavail = vol->free_cls;                                     
4000e814:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            <== NOT EXECUTED
4000e818:	c2 26 60 1c 	st  %g1, [ %i1 + 0x1c ]                        <== NOT EXECUTED
  }                                                                   
                                                                      
  rtems_semaphore_release(fs_info->vol_sema);                         
4000e81c:	d0 06 e0 9c 	ld  [ %i3 + 0x9c ], %o0                        <== NOT EXECUTED
4000e820:	7f ff ea c7 	call  4000933c <rtems_semaphore_release>       <== NOT EXECUTED
4000e824:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
  return RC_OK;                                                       
}                                                                     
4000e828:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e82c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40019fb4 <msdos_sync>: return MSDOS_NAME_NOT_FOUND_ERR; } int msdos_sync(rtems_libio_t *iop) {
40019fb4:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int                rc = RC_OK;                                    
    rtems_status_code  sc = RTEMS_SUCCESSFUL;                         
    msdos_fs_info_t   *fs_info = iop->pathinfo.mt_entry->fs_info;     
40019fb8:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
40019fbc:	92 10 20 00 	clr  %o1                                       
int                                                                   
msdos_sync(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;     
40019fc0:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
                                                                      
    sc = rtems_semaphore_obtain(fs_info->vol_sema, RTEMS_WAIT,        
40019fc4:	94 10 20 00 	clr  %o2                                       
40019fc8:	7f ff bc 95 	call  4000921c <rtems_semaphore_obtain>        
40019fcc:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
                                MSDOS_VOLUME_SEMAPHORE_TIMEOUT);      
    if (sc != RTEMS_SUCCESSFUL)                                       
40019fd0:	80 a2 20 00 	cmp  %o0, 0                                    
40019fd4:	02 80 00 08 	be  40019ff4 <msdos_sync+0x40>                 <== ALWAYS TAKEN
40019fd8:	01 00 00 00 	nop                                            
        rtems_set_errno_and_return_minus_one(EIO);                    
40019fdc:	40 00 09 2c 	call  4001c48c <__errno>                       <== NOT EXECUTED
40019fe0:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
40019fe4:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40019fe8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40019fec:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40019ff0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    rc = fat_sync(&fs_info->fat);                                     
40019ff4:	7f ff e7 09 	call  40013c18 <fat_sync>                      
40019ff8:	90 10 00 1d 	mov  %i5, %o0                                  
40019ffc:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
    rtems_semaphore_release(fs_info->vol_sema);                       
4001a000:	7f ff bc cf 	call  4000933c <rtems_semaphore_release>       
4001a004:	d0 07 60 9c 	ld  [ %i5 + 0x9c ], %o0                        
    return rc;                                                        
}                                                                     
4001a008:	81 c7 e0 08 	ret                                            
4001a00c:	81 e8 00 00 	restore                                        
                                                                      

4000e384 <msdos_unlock>: } } void msdos_unlock(const rtems_filesystem_mount_table_entry_t *mt_entry) {
4000e384:	9d e3 bf a0 	save  %sp, -96, %sp                            
  msdos_fs_info_t *fs_info = mt_entry->fs_info;                       
  rtems_status_code sc = rtems_semaphore_release(fs_info->vol_sema);  
4000e388:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
4000e38c:	7f ff eb ec 	call  4000933c <rtems_semaphore_release>       
4000e390:	d0 00 60 9c 	ld  [ %g1 + 0x9c ], %o0                        
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000e394:	80 a2 20 00 	cmp  %o0, 0                                    
4000e398:	02 80 00 04 	be  4000e3a8 <msdos_unlock+0x24>               <== ALWAYS TAKEN
4000e39c:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
    rtems_fatal_error_occurred(0xdeadbeef);                           
4000e3a0:	7f ff ed 6a 	call  40009948 <rtems_fatal_error_occurred>    <== NOT EXECUTED
4000e3a4:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
4000e3a8:	81 c7 e0 08 	ret                                            
4000e3ac:	81 e8 00 00 	restore                                        
                                                                      

4000ea58 <msdos_utf8_destroy>: } static void msdos_utf8_destroy( rtems_dosfs_convert_control *super ) {
4000ea58:	9d e3 bf a0 	save  %sp, -96, %sp                            
  msdos_utf8_convert_control *self = (msdos_utf8_convert_control *) super;
  int                         rv;                                     
                                                                      
  if ( self->desc_utf16_to_utf8 != INVALID_ICONV_DESC ) {             
4000ea5c:	d0 06 20 14 	ld  [ %i0 + 0x14 ], %o0                        
4000ea60:	80 a2 3f ff 	cmp  %o0, -1                                   
4000ea64:	22 80 00 0b 	be,a   4000ea90 <msdos_utf8_destroy+0x38>      <== NEVER TAKEN
4000ea68:	d0 06 20 0c 	ld  [ %i0 + 0xc ], %o0                         <== NOT EXECUTED
    rv = iconv_close( self->desc_utf16_to_utf8 );                     
4000ea6c:	40 00 44 7f 	call  4001fc68 <iconv_close>                   
4000ea70:	01 00 00 00 	nop                                            
    assert( rv == 0 );                                                
4000ea74:	80 a2 20 00 	cmp  %o0, 0                                    
4000ea78:	22 80 00 06 	be,a   4000ea90 <msdos_utf8_destroy+0x38>      <== ALWAYS TAKEN
4000ea7c:	d0 06 20 0c 	ld  [ %i0 + 0xc ], %o0                         
4000ea80:	11 10 00 e4 	sethi  %hi(0x40039000), %o0                    <== NOT EXECUTED
4000ea84:	92 10 21 03 	mov  0x103, %o1                                <== NOT EXECUTED
4000ea88:	10 80 00 0d 	b  4000eabc <msdos_utf8_destroy+0x64>          <== NOT EXECUTED
4000ea8c:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
  }                                                                   
                                                                      
  if ( self->desc_codepage_to_utf8 != INVALID_ICONV_DESC ) {          
4000ea90:	80 a2 3f ff 	cmp  %o0, -1                                   
4000ea94:	22 80 00 0f 	be,a   4000ead0 <msdos_utf8_destroy+0x78>      <== NEVER TAKEN
4000ea98:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        <== NOT EXECUTED
    rv = iconv_close( self->desc_codepage_to_utf8 );                  
4000ea9c:	40 00 44 73 	call  4001fc68 <iconv_close>                   
4000eaa0:	01 00 00 00 	nop                                            
    assert( rv == 0 );                                                
4000eaa4:	80 a2 20 00 	cmp  %o0, 0                                    
4000eaa8:	22 80 00 0a 	be,a   4000ead0 <msdos_utf8_destroy+0x78>      <== ALWAYS TAKEN
4000eaac:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        
4000eab0:	11 10 00 e4 	sethi  %hi(0x40039000), %o0                    <== NOT EXECUTED
4000eab4:	92 10 21 08 	mov  0x108, %o1                                <== NOT EXECUTED
4000eab8:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
4000eabc:	15 10 00 e4 	sethi  %hi(0x40039000), %o2                    <== NOT EXECUTED
4000eac0:	17 10 00 e4 	sethi  %hi(0x40039000), %o3                    <== NOT EXECUTED
4000eac4:	94 12 a2 00 	or  %o2, 0x200, %o2                            <== NOT EXECUTED
4000eac8:	7f ff dd 36 	call  40005fa0 <__assert_func>                 <== NOT EXECUTED
4000eacc:	96 12 e1 d8 	or  %o3, 0x1d8, %o3                            <== NOT EXECUTED
  }                                                                   
                                                                      
  if ( self->desc_utf8_to_codepage != INVALID_ICONV_DESC ) {          
4000ead0:	80 a2 3f ff 	cmp  %o0, -1                                   
4000ead4:	22 80 00 0b 	be,a   4000eb00 <msdos_utf8_destroy+0xa8>      <== NEVER TAKEN
4000ead8:	d0 06 20 18 	ld  [ %i0 + 0x18 ], %o0                        <== NOT EXECUTED
    rv = iconv_close( self->desc_utf8_to_codepage );                  
4000eadc:	40 00 44 63 	call  4001fc68 <iconv_close>                   
4000eae0:	01 00 00 00 	nop                                            
    assert( rv == 0 );                                                
4000eae4:	80 a2 20 00 	cmp  %o0, 0                                    
4000eae8:	22 80 00 06 	be,a   4000eb00 <msdos_utf8_destroy+0xa8>      <== ALWAYS TAKEN
4000eaec:	d0 06 20 18 	ld  [ %i0 + 0x18 ], %o0                        
4000eaf0:	11 10 00 e4 	sethi  %hi(0x40039000), %o0                    <== NOT EXECUTED
4000eaf4:	92 10 21 0d 	mov  0x10d, %o1                                <== NOT EXECUTED
4000eaf8:	10 bf ff f1 	b  4000eabc <msdos_utf8_destroy+0x64>          <== NOT EXECUTED
4000eafc:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
  }                                                                   
                                                                      
  if ( self->desc_utf8_to_utf16 != INVALID_ICONV_DESC ) {             
4000eb00:	80 a2 3f ff 	cmp  %o0, -1                                   
4000eb04:	02 80 00 0a 	be  4000eb2c <msdos_utf8_destroy+0xd4>         <== NEVER TAKEN
4000eb08:	01 00 00 00 	nop                                            
    rv = iconv_close( self->desc_utf8_to_utf16 );                     
4000eb0c:	40 00 44 57 	call  4001fc68 <iconv_close>                   
4000eb10:	01 00 00 00 	nop                                            
    assert( rv == 0 );                                                
4000eb14:	80 a2 20 00 	cmp  %o0, 0                                    
4000eb18:	02 80 00 05 	be  4000eb2c <msdos_utf8_destroy+0xd4>         <== ALWAYS TAKEN
4000eb1c:	11 10 00 e4 	sethi  %hi(0x40039000), %o0                    
4000eb20:	92 10 21 12 	mov  0x112, %o1                                <== NOT EXECUTED
4000eb24:	10 bf ff e6 	b  4000eabc <msdos_utf8_destroy+0x64>          <== NOT EXECUTED
4000eb28:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
  }                                                                   
                                                                      
  free( self );                                                       
4000eb2c:	7f ff dd 85 	call  40006140 <free>                          
4000eb30:	81 e8 00 00 	restore                                        
                                                                      

4000eb34 <msdos_utf8_normalize_and_fold>: const uint8_t *src, const size_t src_size, uint8_t *dst, size_t *dst_size ) {
4000eb34:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int      eno              = 0;                                      
  int32_t *unicode_buf      = (int32_t *) dst;                        
  ssize_t  unicode_buf_size = *dst_size / sizeof( *unicode_buf );     
4000eb38:	fa 07 00 00 	ld  [ %i4 ], %i5                               
  ssize_t  unicodes_to_reencode;                                      
  ssize_t  result;                                                    
                                                                      
  (void) super;                                                       
                                                                      
  result = utf8proc_decompose(                                        
4000eb3c:	92 10 00 1a 	mov  %i2, %o1                                  
  size_t        *dst_size                                             
)                                                                     
{                                                                     
  int      eno              = 0;                                      
  int32_t *unicode_buf      = (int32_t *) dst;                        
  ssize_t  unicode_buf_size = *dst_size / sizeof( *unicode_buf );     
4000eb40:	bb 37 60 02 	srl  %i5, 2, %i5                               
  ssize_t  unicodes_to_reencode;                                      
  ssize_t  result;                                                    
                                                                      
  (void) super;                                                       
                                                                      
  result = utf8proc_decompose(                                        
4000eb44:	90 10 00 19 	mov  %i1, %o0                                  
4000eb48:	94 10 00 1b 	mov  %i3, %o2                                  
4000eb4c:	96 10 00 1d 	mov  %i5, %o3                                  
4000eb50:	40 00 09 19 	call  40010fb4 <utf8proc_decompose>            
4000eb54:	98 10 24 12 	mov  0x412, %o4                                
    unicode_buf,                                                      
    unicode_buf_size,                                                 
    UTF8PROC_STABLE | UTF8PROC_DECOMPOSE | UTF8PROC_CASEFOLD          
  );                                                                  
                                                                      
  if ( result >= 0 ) {                                                
4000eb58:	92 92 20 00 	orcc  %o0, 0, %o1                              
4000eb5c:	06 80 00 17 	bl  4000ebb8 <msdos_utf8_normalize_and_fold+0x84><== NEVER TAKEN
4000eb60:	80 a2 40 1d 	cmp  %o1, %i5                                  
    if ( result < unicode_buf_size ) {                                
4000eb64:	06 80 00 04 	bl  4000eb74 <msdos_utf8_normalize_and_fold+0x40><== ALWAYS TAKEN
4000eb68:	b0 10 20 00 	clr  %i0                                       
      unicodes_to_reencode = result;                                  
    } else {                                                          
      unicodes_to_reencode = unicode_buf_size - 1;                    
4000eb6c:	92 07 7f ff 	add  %i5, -1, %o1                              <== NOT EXECUTED
      eno = ENOMEM;                                                   
4000eb70:	b0 10 20 0c 	mov  0xc, %i0                                  <== NOT EXECUTED
    }                                                                 
                                                                      
    result = utf8proc_reencode(                                       
4000eb74:	90 10 00 1b 	mov  %i3, %o0                                  
4000eb78:	40 00 09 78 	call  40011158 <utf8proc_reencode>             
4000eb7c:	94 10 20 12 	mov  0x12, %o2                                 
      unicode_buf,                                                    
      unicodes_to_reencode,                                           
      UTF8PROC_STABLE | UTF8PROC_DECOMPOSE                            
    );                                                                
                                                                      
    if ( result >= 0 ) {                                              
4000eb80:	80 a2 20 00 	cmp  %o0, 0                                    
4000eb84:	26 80 00 05 	bl,a   4000eb98 <msdos_utf8_normalize_and_fold+0x64><== NEVER TAKEN
4000eb88:	90 02 20 05 	add  %o0, 5, %o0                               <== NOT EXECUTED
      *dst_size = result;                                             
4000eb8c:	d0 27 00 00 	st  %o0, [ %i4 ]                               
4000eb90:	81 c7 e0 08 	ret                                            
4000eb94:	81 e8 00 00 	restore                                        
4000eb98:	80 a2 20 05 	cmp  %o0, 5                                    <== NOT EXECUTED
static int msdos_utf8proc_errmsg_to_errno( ssize_t errcode )          
{                                                                     
  int eno = 0;                                                        
                                                                      
                                                                      
  switch ( errcode ) {                                                
4000eb9c:	18 bf ff fd 	bgu  4000eb90 <msdos_utf8_normalize_and_fold+0x5c><== NOT EXECUTED
4000eba0:	b0 10 20 02 	mov  2, %i0                                    <== NOT EXECUTED
4000eba4:	03 10 00 e4 	sethi  %hi(0x40039000), %g1                    <== NOT EXECUTED
4000eba8:	82 10 61 f8 	or  %g1, 0x1f8, %g1	! 400391f8 <CSWTCH.5>      <== NOT EXECUTED
4000ebac:	f0 08 40 08 	ldub  [ %g1 + %o0 ], %i0                       <== NOT EXECUTED
4000ebb0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000ebb4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
4000ebb8:	92 02 60 05 	add  %o1, 5, %o1                               <== NOT EXECUTED
4000ebbc:	80 a2 60 05 	cmp  %o1, 5                                    <== NOT EXECUTED
4000ebc0:	18 bf ff f4 	bgu  4000eb90 <msdos_utf8_normalize_and_fold+0x5c><== NOT EXECUTED
4000ebc4:	b0 10 20 02 	mov  2, %i0                                    <== NOT EXECUTED
4000ebc8:	03 10 00 e4 	sethi  %hi(0x40039000), %g1                    <== NOT EXECUTED
4000ebcc:	82 10 61 f8 	or  %g1, 0x1f8, %g1	! 400391f8 <CSWTCH.5>      <== NOT EXECUTED
4000ebd0:	f0 08 40 09 	ldub  [ %g1 + %o1 ], %i0                       <== NOT EXECUTED
  } else {                                                            
    eno = msdos_utf8proc_errmsg_to_errno( result );                   
  }                                                                   
                                                                      
  return eno;                                                         
}                                                                     
4000ebd4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000ebd8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40001f84 <notify>: } void notify (s) char *s; {
40001f84:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
    printf ("%s test appears to be inconsistent...\n", s);            
40001f88:	11 10 00 9b 	sethi  %hi(0x40026c00), %o0                    <== NOT EXECUTED
40001f8c:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
40001f90:	90 12 23 98 	or  %o0, 0x398, %o0                            <== NOT EXECUTED
40001f94:	40 00 69 60 	call  4001c514 <printf>                        <== NOT EXECUTED
40001f98:	31 10 00 9b 	sethi  %hi(0x40026c00), %i0                    <== NOT EXECUTED
    printf ("   PLEASE NOTIFY KARPINKSI!\n");                         
40001f9c:	40 00 69 99 	call  4001c600 <puts>                          <== NOT EXECUTED
40001fa0:	91 ee 23 c0 	restore  %i0, 0x3c0, %o0                       <== NOT EXECUTED
                                                                      

400069d4 <null_op_chown>: uid_t owner, gid_t group ) { return -1; }
400069d4:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400069d8:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

400069cc <null_op_fchmod>: const rtems_filesystem_location_info_t *pathloc, mode_t mode ) { return -1; }
400069cc:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400069d0:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

400069ec <null_op_fsmount_me>: rtems_filesystem_mount_table_entry_t *mt_entry, const void *data ) { return -1; }
400069ec:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400069f0:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

400069fc <null_op_fsunmount_me>: static void null_op_fsunmount_me( rtems_filesystem_mount_table_entry_t *mt_entry ) {
400069fc:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
                                                                      

400069c4 <null_op_link>: const char *name, size_t namelen ) { return -1; }
400069c4:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400069c8:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

400069e4 <null_op_mount>: static int null_op_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { return -1; }
400069e4:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400069e8:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

40006a14 <null_op_readlink>: char *buf, size_t bufsize ) { return -1; }
40006a14:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
40006a18:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

40006a1c <null_op_rename>: const char *name, size_t namelen ) { return -1; }
40006a1c:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
40006a20:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

400069bc <null_op_rmnod>: const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc ) { return -1; }
400069bc:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
400069c0:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
                                                                      

40005b68 <oproc>: /* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) {
40005b68:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int  i;                                                             
                                                                      
  if (tty->termios.c_oflag & OPOST) {                                 
40005b6c:	c2 06 60 34 	ld  [ %i1 + 0x34 ], %g1                        
40005b70:	80 88 60 01 	btst  1, %g1                                   
40005b74:	02 80 00 53 	be  40005cc0 <oproc+0x158>                     <== NEVER TAKEN
40005b78:	f0 2f a0 44 	stb  %i0, [ %fp + 0x44 ]                       
    switch (c) {                                                      
40005b7c:	b0 0e 20 ff 	and  %i0, 0xff, %i0                            
40005b80:	80 a6 20 09 	cmp  %i0, 9                                    
40005b84:	22 80 00 2a 	be,a   40005c2c <oproc+0xc4>                   
40005b88:	c4 06 60 28 	ld  [ %i1 + 0x28 ], %g2                        
40005b8c:	18 80 00 07 	bgu  40005ba8 <oproc+0x40>                     <== ALWAYS TAKEN
40005b90:	80 a6 20 0a 	cmp  %i0, 0xa                                  
40005b94:	80 a6 20 08 	cmp  %i0, 8                                    <== NOT EXECUTED
40005b98:	22 80 00 31 	be,a   40005c5c <oproc+0xf4>                   <== NOT EXECUTED
40005b9c:	c2 06 60 28 	ld  [ %i1 + 0x28 ], %g1                        <== NOT EXECUTED
      if (tty->column > 0)                                            
        tty->column--;                                                
      break;                                                          
                                                                      
    default:                                                          
      if (tty->termios.c_oflag & OLCUC)                               
40005ba0:	10 80 00 34 	b  40005c70 <oproc+0x108>                      <== NOT EXECUTED
40005ba4:	80 88 60 02 	btst  2, %g1                                   <== NOT EXECUTED
oproc (unsigned char c, struct rtems_termios_tty *tty)                
{                                                                     
  int  i;                                                             
                                                                      
  if (tty->termios.c_oflag & OPOST) {                                 
    switch (c) {                                                      
40005ba8:	02 80 00 06 	be  40005bc0 <oproc+0x58>                      
40005bac:	80 a6 20 0d 	cmp  %i0, 0xd                                  
40005bb0:	22 80 00 11 	be,a   40005bf4 <oproc+0x8c>                   <== NEVER TAKEN
40005bb4:	80 88 60 10 	btst  0x10, %g1                                <== NOT EXECUTED
      if (tty->column > 0)                                            
        tty->column--;                                                
      break;                                                          
                                                                      
    default:                                                          
      if (tty->termios.c_oflag & OLCUC)                               
40005bb8:	10 80 00 2e 	b  40005c70 <oproc+0x108>                      
40005bbc:	80 88 60 02 	btst  2, %g1                                   
  int  i;                                                             
                                                                      
  if (tty->termios.c_oflag & OPOST) {                                 
    switch (c) {                                                      
    case '\n':                                                        
      if (tty->termios.c_oflag & ONLRET)                              
40005bc0:	80 88 60 20 	btst  0x20, %g1                                
40005bc4:	32 80 00 02 	bne,a   40005bcc <oproc+0x64>                  <== NEVER TAKEN
40005bc8:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            <== NOT EXECUTED
        tty->column = 0;                                              
      if (tty->termios.c_oflag & ONLCR) {                             
40005bcc:	80 88 60 04 	btst  4, %g1                                   
40005bd0:	02 80 00 3d 	be  40005cc4 <oproc+0x15c>                     <== NEVER TAKEN
40005bd4:	90 07 a0 44 	add  %fp, 0x44, %o0                            
        rtems_termios_puts ("\r", 1, tty);                            
40005bd8:	11 10 00 57 	sethi  %hi(0x40015c00), %o0                    
40005bdc:	92 10 20 01 	mov  1, %o1                                    
40005be0:	90 12 20 38 	or  %o0, 0x38, %o0                             
40005be4:	7f ff ff 99 	call  40005a48 <rtems_termios_puts>            
40005be8:	94 10 00 19 	mov  %i1, %o2                                  
        c = '\n';                                                     
        if (tty->termios.c_oflag & ONLRET)                            
          tty->column = 0;                                            
        break;                                                        
      }                                                               
      tty->column = 0;                                                
40005bec:	10 80 00 35 	b  40005cc0 <oproc+0x158>                      
40005bf0:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            
        tty->column = 0;                                              
      }                                                               
      break;                                                          
                                                                      
    case '\r':                                                        
      if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0))       
40005bf4:	02 80 00 06 	be  40005c0c <oproc+0xa4>                      <== NOT EXECUTED
40005bf8:	80 88 60 08 	btst  8, %g1                                   <== NOT EXECUTED
40005bfc:	c4 06 60 28 	ld  [ %i1 + 0x28 ], %g2                        <== NOT EXECUTED
40005c00:	80 a0 a0 00 	cmp  %g2, 0                                    <== NOT EXECUTED
40005c04:	02 80 00 33 	be  40005cd0 <oproc+0x168>                     <== NOT EXECUTED
40005c08:	80 88 60 08 	btst  8, %g1                                   <== NOT EXECUTED
        return;                                                       
      if (tty->termios.c_oflag & OCRNL) {                             
40005c0c:	22 80 00 2d 	be,a   40005cc0 <oproc+0x158>                  <== NOT EXECUTED
40005c10:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            <== NOT EXECUTED
        c = '\n';                                                     
40005c14:	84 10 20 0a 	mov  0xa, %g2                                  <== NOT EXECUTED
        if (tty->termios.c_oflag & ONLRET)                            
40005c18:	80 88 60 20 	btst  0x20, %g1                                <== NOT EXECUTED
40005c1c:	02 80 00 29 	be  40005cc0 <oproc+0x158>                     <== NOT EXECUTED
40005c20:	c4 2f a0 44 	stb  %g2, [ %fp + 0x44 ]                       <== NOT EXECUTED
          tty->column = 0;                                            
        break;                                                        
      }                                                               
      tty->column = 0;                                                
      break;                                                          
40005c24:	10 80 00 27 	b  40005cc0 <oproc+0x158>                      <== NOT EXECUTED
40005c28:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            <== NOT EXECUTED
                                                                      
    case '\t':                                                        
      i = 8 - (tty->column & 7);                                      
40005c2c:	92 10 20 08 	mov  8, %o1                                    
40005c30:	86 08 a0 07 	and  %g2, 7, %g3                               
40005c34:	92 22 40 03 	sub  %o1, %g3, %o1                             
      if ((tty->termios.c_oflag & TABDLY) == XTABS) {                 
40005c38:	07 00 00 06 	sethi  %hi(0x1800), %g3                        
40005c3c:	82 08 40 03 	and  %g1, %g3, %g1                             
40005c40:	80 a0 40 03 	cmp  %g1, %g3                                  
40005c44:	82 00 80 09 	add  %g2, %o1, %g1                             
40005c48:	12 80 00 1e 	bne  40005cc0 <oproc+0x158>                    <== NEVER TAKEN
40005c4c:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        
        tty->column += i;                                             
        rtems_termios_puts ( "        ",  i, tty);                    
40005c50:	11 10 00 57 	sethi  %hi(0x40015c00), %o0                    
40005c54:	10 80 00 1d 	b  40005cc8 <oproc+0x160>                      
40005c58:	90 12 20 40 	or  %o0, 0x40, %o0	! 40015c40 <rtems_termios_baud_table+0x108>
      }                                                               
      tty->column += i;                                               
      break;                                                          
                                                                      
    case '\b':                                                        
      if (tty->column > 0)                                            
40005c5c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40005c60:	04 80 00 18 	ble  40005cc0 <oproc+0x158>                    <== NOT EXECUTED
40005c64:	82 00 7f ff 	add  %g1, -1, %g1                              <== NOT EXECUTED
                                                                      
    default:                                                          
      if (tty->termios.c_oflag & OLCUC)                               
        c = toupper(c);                                               
      if (!iscntrl(c))                                                
        tty->column++;                                                
40005c68:	10 80 00 16 	b  40005cc0 <oproc+0x158>                      <== NOT EXECUTED
40005c6c:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        <== NOT EXECUTED
      if (tty->column > 0)                                            
        tty->column--;                                                
      break;                                                          
                                                                      
    default:                                                          
      if (tty->termios.c_oflag & OLCUC)                               
40005c70:	02 80 00 0a 	be  40005c98 <oproc+0x130>                     <== ALWAYS TAKEN
40005c74:	03 10 00 5b 	sethi  %hi(0x40016c00), %g1                    
        c = toupper(c);                                               
40005c78:	c4 00 61 0c 	ld  [ %g1 + 0x10c ], %g2	! 40016d0c <__ctype_ptr__><== NOT EXECUTED
40005c7c:	84 00 80 18 	add  %g2, %i0, %g2                             <== NOT EXECUTED
40005c80:	c4 08 a0 01 	ldub  [ %g2 + 1 ], %g2                         <== NOT EXECUTED
40005c84:	84 08 a0 03 	and  %g2, 3, %g2                               <== NOT EXECUTED
40005c88:	80 a0 a0 02 	cmp  %g2, 2                                    <== NOT EXECUTED
40005c8c:	22 80 00 02 	be,a   40005c94 <oproc+0x12c>                  <== NOT EXECUTED
40005c90:	b0 06 3f e0 	add  %i0, -32, %i0                             <== NOT EXECUTED
40005c94:	f0 2f a0 44 	stb  %i0, [ %fp + 0x44 ]                       <== NOT EXECUTED
      if (!iscntrl(c))                                                
40005c98:	c4 0f a0 44 	ldub  [ %fp + 0x44 ], %g2                      
40005c9c:	c2 00 61 0c 	ld  [ %g1 + 0x10c ], %g1                       
40005ca0:	82 00 40 02 	add  %g1, %g2, %g1                             
40005ca4:	c2 08 60 01 	ldub  [ %g1 + 1 ], %g1                         
40005ca8:	80 88 60 20 	btst  0x20, %g1                                
40005cac:	12 80 00 06 	bne  40005cc4 <oproc+0x15c>                    <== NEVER TAKEN
40005cb0:	90 07 a0 44 	add  %fp, 0x44, %o0                            
        tty->column++;                                                
40005cb4:	c2 06 60 28 	ld  [ %i1 + 0x28 ], %g1                        
40005cb8:	82 00 60 01 	inc  %g1                                       
40005cbc:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        
      break;                                                          
    }                                                                 
  }                                                                   
  rtems_termios_puts (&c, 1, tty);                                    
40005cc0:	90 07 a0 44 	add  %fp, 0x44, %o0                            
40005cc4:	92 10 20 01 	mov  1, %o1                                    
40005cc8:	7f ff ff 60 	call  40005a48 <rtems_termios_puts>            
40005ccc:	94 10 00 19 	mov  %i1, %o2                                  
40005cd0:	81 c7 e0 08 	ret                                            
40005cd4:	81 e8 00 00 	restore                                        
                                                                      

400053b0 <partition_free>: * RETURNS: * N/A */ static void partition_free(rtems_part_desc_t *part_desc) {
400053b0:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int part_num;                                                     
                                                                      
    if (part_desc == NULL)                                            
400053b4:	80 a6 20 00 	cmp  %i0, 0                                    
400053b8:	02 80 00 11 	be  400053fc <partition_free+0x4c>             
400053bc:	01 00 00 00 	nop                                            
 *      true if partition type is extended, false otherwise           
 */                                                                   
static bool                                                           
is_extended(uint8_t type)                                             
{                                                                     
    return ((type == EXTENDED_PARTITION) || (type == LINUX_EXTENDED));
400053c0:	c2 0e 20 01 	ldub  [ %i0 + 1 ], %g1                         
    int part_num;                                                     
                                                                      
    if (part_desc == NULL)                                            
        return;                                                       
                                                                      
    if (is_extended(part_desc->sys_type))                             
400053c4:	82 08 60 7f 	and  %g1, 0x7f, %g1                            
400053c8:	80 a0 60 05 	cmp  %g1, 5                                    
400053cc:	22 80 00 04 	be,a   400053dc <partition_free+0x2c>          <== NEVER TAKEN
400053d0:	ba 10 20 00 	clr  %i5                                       <== NOT EXECUTED
        {                                                             
            partition_free(part_desc->sub_part[part_num]);            
        }                                                             
    }                                                                 
                                                                      
    free(part_desc);                                                  
400053d4:	40 00 03 e0 	call  40006354 <free>                          
400053d8:	81 e8 00 00 	restore                                        
400053dc:	82 06 00 1d 	add  %i0, %i5, %g1                             <== NOT EXECUTED
    {                                                                 
        for (part_num = 0;                                            
             part_num < RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER; 
             part_num++)                                              
        {                                                             
            partition_free(part_desc->sub_part[part_num]);            
400053e0:	d0 00 60 18 	ld  [ %g1 + 0x18 ], %o0                        <== NOT EXECUTED
400053e4:	7f ff ff f3 	call  400053b0 <partition_free>                <== NOT EXECUTED
400053e8:	ba 07 60 04 	add  %i5, 4, %i5                               <== NOT EXECUTED
    if (part_desc == NULL)                                            
        return;                                                       
                                                                      
    if (is_extended(part_desc->sys_type))                             
    {                                                                 
        for (part_num = 0;                                            
400053ec:	80 a7 60 10 	cmp  %i5, 0x10                                 <== NOT EXECUTED
400053f0:	12 bf ff fc 	bne  400053e0 <partition_free+0x30>            <== NOT EXECUTED
400053f4:	82 06 00 1d 	add  %i0, %i5, %g1                             <== NOT EXECUTED
400053f8:	30 bf ff f7 	b,a   400053d4 <partition_free+0x24>           <== NOT EXECUTED
400053fc:	81 c7 e0 08 	ret                                            
40005400:	81 e8 00 00 	restore                                        
                                                                      

400056e4 <partition_table_get>: * RTEMS_SUCCESSFUL if success, * RTEMS_INTERNAL_ERROR otherwise */ static rtems_status_code partition_table_get(const char *dev_name, rtems_disk_desc_t *disk_desc) {
400056e4:	9d e3 bf 50 	save  %sp, -176, %sp                           
    struct stat         dev_stat;                                     
    rtems_status_code   rc;                                           
    int                 fd;                                           
                                                                      
    fd = open(dev_name, O_RDONLY);                                    
400056e8:	92 10 20 00 	clr  %o1                                       
400056ec:	90 10 00 18 	mov  %i0, %o0                                  
400056f0:	40 00 06 2a 	call  40006f98 <open>                          
400056f4:	ba 10 20 19 	mov  0x19, %i5                                 
    if (fd < 0)                                                       
400056f8:	80 a2 20 00 	cmp  %o0, 0                                    
400056fc:	06 80 00 6d 	bl  400058b0 <partition_table_get+0x1cc>       <== NEVER TAKEN
40005700:	b8 10 00 08 	mov  %o0, %i4                                  
    {                                                                 
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    rc = fstat(fd, &dev_stat);                                        
40005704:	40 00 03 3e 	call  400063fc <fstat>                         
40005708:	92 07 bf b8 	add  %fp, -72, %o1                             
    if (rc != RTEMS_SUCCESSFUL)                                       
4000570c:	80 a2 20 00 	cmp  %o0, 0                                    
40005710:	12 80 00 66 	bne  400058a8 <partition_table_get+0x1c4>      <== NEVER TAKEN
40005714:	90 06 60 08 	add  %i1, 8, %o0                               
    {                                                                 
        close(fd);                                                    
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    strncpy (disk_desc->dev_name, dev_name, 15);                      
40005718:	92 10 00 18 	mov  %i0, %o1                                  
4000571c:	40 00 45 63 	call  40016ca8 <strncpy>                       
40005720:	94 10 20 0f 	mov  0xf, %o2                                  
    disk_desc->dev = dev_stat.st_rdev;                                
40005724:	c4 1f bf d0 	ldd  [ %fp + -48 ], %g2                        
40005728:	c4 3e 40 00 	std  %g2, [ %i1 ]                              
    disk_desc->sector_size = (dev_stat.st_blksize) ? dev_stat.st_blksize :
4000572c:	c4 07 bf f8 	ld  [ %fp + -8 ], %g2                          
40005730:	80 a0 a0 00 	cmp  %g2, 0                                    
40005734:	02 80 00 03 	be  40005740 <partition_table_get+0x5c>        <== ALWAYS TAKEN
40005738:	82 10 22 00 	mov  0x200, %g1                                
4000573c:	82 10 00 02 	mov  %g2, %g1                                  <== NOT EXECUTED
40005740:	c2 26 60 18 	st  %g1, [ %i1 + 0x18 ]                        
 */                                                                   
static rtems_status_code                                              
read_mbr(int fd, rtems_disk_desc_t *disk_desc)                        
{                                                                     
    int                  part_num;                                    
    rtems_sector_data_t *sector = NULL;                               
40005744:	c0 27 bf b0 	clr  [ %fp + -80 ]                             
    {                                                                 
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    off = sector_num * RTEMS_IDE_SECTOR_SIZE;                         
    new_off = lseek(fd, off, SEEK_SET);                               
40005748:	90 10 00 1c 	mov  %i4, %o0                                  
4000574c:	92 10 20 00 	clr  %o1                                       
40005750:	94 10 20 00 	clr  %o2                                       
40005754:	96 10 20 00 	clr  %o3                                       
40005758:	40 00 04 0d 	call  4000678c <lseek>                         
4000575c:	ba 10 20 1b 	mov  0x1b, %i5                                 
    if (new_off != off) {                                             
40005760:	80 92 00 09 	orcc  %o0, %o1, %g0                            
40005764:	12 80 00 09 	bne  40005788 <partition_table_get+0xa4>       <== NEVER TAKEN
40005768:	d0 07 bf b0 	ld  [ %fp + -80 ], %o0                         
4000576c:	90 10 00 1c 	mov  %i4, %o0                                  
40005770:	92 10 20 00 	clr  %o1                                       
40005774:	7f ff ff 2f 	call  40005430 <get_sector.part.0>             
40005778:	94 07 bf b0 	add  %fp, -80, %o2                             
    uint8_t             *data;                                        
    rtems_status_code    rc;                                          
                                                                      
    /* get MBR sector */                                              
    rc = get_sector(fd, 0, §or);                                  
    if (rc != RTEMS_SUCCESSFUL)                                       
4000577c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40005780:	02 80 00 06 	be  40005798 <partition_table_get+0xb4>        <== ALWAYS TAKEN
40005784:	d0 07 bf b0 	ld  [ %fp + -80 ], %o0                         
    {                                                                 
        if (sector)                                                   
40005788:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4000578c:	12 80 00 1b 	bne  400057f8 <partition_table_get+0x114>      <== NOT EXECUTED
40005790:	01 00 00 00 	nop                                            <== NOT EXECUTED
40005794:	30 80 00 45 	b,a   400058a8 <partition_table_get+0x1c4>     <== NOT EXECUTED
static bool                                                           
msdos_signature_check (rtems_sector_data_t *sector)                   
{                                                                     
    uint8_t *p = sector->data + RTEMS_IDE_PARTITION_MSDOS_SIGNATURE_OFFSET;
                                                                      
    return ((p[0] == RTEMS_IDE_PARTITION_MSDOS_SIGNATURE_DATA1) &&    
40005798:	c4 0a 22 02 	ldub  [ %o0 + 0x202 ], %g2                     
4000579c:	80 a0 a0 55 	cmp  %g2, 0x55                                 
400057a0:	12 80 00 06 	bne  400057b8 <partition_table_get+0xd4>       <== NEVER TAKEN
400057a4:	82 10 20 00 	clr  %g1                                       
400057a8:	c2 0a 22 03 	ldub  [ %o0 + 0x203 ], %g1                     
400057ac:	82 18 60 aa 	xor  %g1, 0xaa, %g1                            
400057b0:	80 a0 00 01 	cmp  %g0, %g1                                  
400057b4:	82 60 3f ff 	subx  %g0, -1, %g1                             
            free(sector);                                             
        return rc;                                                    
    }                                                                 
                                                                      
    /* check if the partition table structure is MS-DOS style */      
    if (!msdos_signature_check(sector))                               
400057b8:	80 a0 60 00 	cmp  %g1, 0                                    
400057bc:	32 80 00 05 	bne,a   400057d0 <partition_table_get+0xec>    <== ALWAYS TAKEN
400057c0:	a0 02 21 c2 	add  %o0, 0x1c2, %l0                           
    {                                                                 
        free(sector);                                                 
400057c4:	40 00 02 e4 	call  40006354 <free>                          <== NOT EXECUTED
400057c8:	ba 10 20 19 	mov  0x19, %i5                                 <== NOT EXECUTED
400057cc:	30 80 00 37 	b,a   400058a8 <partition_table_get+0x1c4>     <== NOT EXECUTED
400057d0:	b6 10 00 19 	mov  %i1, %i3                                  
                                                                      
    /* read and process 4 primary partition descriptors */            
                                                                      
    data = sector->data + RTEMS_IDE_PARTITION_TABLE_OFFSET;           
                                                                      
    for (part_num = 0;                                                
400057d4:	b0 10 20 00 	clr  %i0                                       
400057d8:	91 2e 20 04 	sll  %i0, 4, %o0                               
400057dc:	92 07 bf b4 	add  %fp, -76, %o1                             
400057e0:	7f ff ff 2a 	call  40005488 <data_to_part_desc.part.1>      
400057e4:	90 04 00 08 	add  %l0, %o0, %o0                             
         part_num < RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER;     
         part_num++)                                                  
    {                                                                 
        rc = data_to_part_desc(data, &part_desc);                     
        if (rc != RTEMS_SUCCESSFUL)                                   
400057e8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400057ec:	02 80 00 06 	be  40005804 <partition_table_get+0x120>       <== ALWAYS TAKEN
400057f0:	c2 07 bf b4 	ld  [ %fp + -76 ], %g1                         
        {                                                             
            free(sector);                                             
400057f4:	d0 07 bf b0 	ld  [ %fp + -80 ], %o0                         <== NOT EXECUTED
400057f8:	40 00 02 d7 	call  40006354 <free>                          <== NOT EXECUTED
400057fc:	01 00 00 00 	nop                                            <== NOT EXECUTED
40005800:	30 80 00 2a 	b,a   400058a8 <partition_table_get+0x1c4>     <== NOT EXECUTED
            return rc;                                                
        }                                                             
                                                                      
        if (part_desc != NULL)                                        
40005804:	80 a0 60 00 	cmp  %g1, 0                                    
40005808:	02 80 00 0b 	be  40005834 <partition_table_get+0x150>       <== NEVER TAKEN
4000580c:	b4 06 20 01 	add  %i0, 1, %i2                               
        {                                                             
            part_desc->log_id = part_num + 1;                         
            part_desc->disk_desc = disk_desc;                         
            part_desc->end = part_desc->start + part_desc->size - 1;  
40005810:	c6 00 60 04 	ld  [ %g1 + 4 ], %g3                           
40005814:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
            return rc;                                                
        }                                                             
                                                                      
        if (part_desc != NULL)                                        
        {                                                             
            part_desc->log_id = part_num + 1;                         
40005818:	f4 28 60 02 	stb  %i2, [ %g1 + 2 ]                          
            part_desc->disk_desc = disk_desc;                         
4000581c:	f2 20 60 10 	st  %i1, [ %g1 + 0x10 ]                        
            part_desc->end = part_desc->start + part_desc->size - 1;  
40005820:	84 00 c0 02 	add  %g3, %g2, %g2                             
40005824:	84 00 bf ff 	add  %g2, -1, %g2                              
40005828:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
            disk_desc->partitions[part_num] = part_desc;              
4000582c:	10 80 00 03 	b  40005838 <partition_table_get+0x154>        
40005830:	c2 26 e0 28 	st  %g1, [ %i3 + 0x28 ]                        
        }                                                             
        else                                                          
        {                                                             
            disk_desc->partitions[part_num] = NULL;                   
40005834:	c0 26 e0 28 	clr  [ %i3 + 0x28 ]                            <== NOT EXECUTED
                                                                      
    data = sector->data + RTEMS_IDE_PARTITION_TABLE_OFFSET;           
                                                                      
    for (part_num = 0;                                                
         part_num < RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER;     
         part_num++)                                                  
40005838:	b0 10 00 1a 	mov  %i2, %i0                                  
                                                                      
    /* read and process 4 primary partition descriptors */            
                                                                      
    data = sector->data + RTEMS_IDE_PARTITION_TABLE_OFFSET;           
                                                                      
    for (part_num = 0;                                                
4000583c:	80 a6 a0 04 	cmp  %i2, 4                                    
40005840:	12 bf ff e6 	bne  400057d8 <partition_table_get+0xf4>       
40005844:	b6 06 e0 04 	add  %i3, 4, %i3                               
        }                                                             
                                                                      
        data += RTEMS_IDE_PARTITION_DESCRIPTOR_SIZE;                  
    }                                                                 
                                                                      
    free(sector);                                                     
40005848:	d0 07 bf b0 	ld  [ %fp + -80 ], %o0                         
4000584c:	40 00 02 c2 	call  40006354 <free>                          
40005850:	b6 10 20 00 	clr  %i3                                       
                                                                      
    disk_desc->last_log_id = RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER;
40005854:	f4 26 60 24 	st  %i2, [ %i1 + 0x24 ]                        
40005858:	b4 06 40 1b 	add  %i1, %i3, %i2                             
       but we are to process each primary partition */                
    for (part_num = 0;                                                
         part_num < RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER;     
         part_num++)                                                  
    {                                                                 
        part_desc = disk_desc->partitions[part_num];                  
4000585c:	d4 06 a0 28 	ld  [ %i2 + 0x28 ], %o2                        
        if (part_desc != NULL && is_extended(part_desc->sys_type))    
40005860:	80 a2 a0 00 	cmp  %o2, 0                                    
40005864:	02 80 00 0d 	be  40005898 <partition_table_get+0x1b4>       <== NEVER TAKEN
40005868:	d4 27 bf b4 	st  %o2, [ %fp + -76 ]                         
 *      true if partition type is extended, false otherwise           
 */                                                                   
static bool                                                           
is_extended(uint8_t type)                                             
{                                                                     
    return ((type == EXTENDED_PARTITION) || (type == LINUX_EXTENDED));
4000586c:	c2 0a a0 01 	ldub  [ %o2 + 1 ], %g1                         
    for (part_num = 0;                                                
         part_num < RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER;     
         part_num++)                                                  
    {                                                                 
        part_desc = disk_desc->partitions[part_num];                  
        if (part_desc != NULL && is_extended(part_desc->sys_type))    
40005870:	82 08 60 7f 	and  %g1, 0x7f, %g1                            
40005874:	80 a0 60 05 	cmp  %g1, 5                                    
40005878:	32 80 00 09 	bne,a   4000589c <partition_table_get+0x1b8>   
4000587c:	b6 06 e0 04 	add  %i3, 4, %i3                               
        {                                                             
            read_extended_partition(fd, part_desc->start, part_desc); 
40005880:	d2 02 a0 04 	ld  [ %o2 + 4 ], %o1                           
40005884:	7f ff ff 32 	call  4000554c <read_extended_partition>       
40005888:	90 10 00 1c 	mov  %i4, %o0                                  
            free(part_desc);                                          
4000588c:	40 00 02 b2 	call  40006354 <free>                          
40005890:	d0 07 bf b4 	ld  [ %fp + -76 ], %o0                         
            disk_desc->partitions[part_num] = NULL;                   
40005894:	c0 26 a0 28 	clr  [ %i2 + 0x28 ]                            
40005898:	b6 06 e0 04 	add  %i3, 4, %i3                               
                                                                      
    disk_desc->last_log_id = RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER;
                                                                      
    /* There cannot be more than one extended partition,              
       but we are to process each primary partition */                
    for (part_num = 0;                                                
4000589c:	80 a6 e0 10 	cmp  %i3, 0x10                                 
400058a0:	12 bf ff ef 	bne  4000585c <partition_table_get+0x178>      
400058a4:	b4 06 40 1b 	add  %i1, %i3, %i2                             
    disk_desc->sector_size = (dev_stat.st_blksize) ? dev_stat.st_blksize :
                                              RTEMS_IDE_SECTOR_SIZE;  
                                                                      
    rc = read_mbr(fd, disk_desc);                                     
                                                                      
    close(fd);                                                        
400058a8:	40 00 02 88 	call  400062c8 <close>                         
400058ac:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
    return rc;                                                        
}                                                                     
400058b0:	81 c7 e0 08 	ret                                            
400058b4:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

4000d1e0 <pipe_create>: static uint16_t rtems_pipe_no = 0; int pipe_create( int filsdes[2] ) {
4000d1e0:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_libio_t *iop;                                                 
  int err = 0;                                                        
                                                                      
  if (rtems_mkdir("/tmp", S_IRWXU | S_IRWXG | S_IRWXO) != 0)          
4000d1e4:	11 10 00 7c 	sethi  %hi(0x4001f000), %o0                    
4000d1e8:	92 10 21 ff 	mov  0x1ff, %o1                                
4000d1ec:	40 00 05 02 	call  4000e5f4 <rtems_mkdir>                   
4000d1f0:	90 12 21 e8 	or  %o0, 0x1e8, %o0                            
4000d1f4:	80 a2 20 00 	cmp  %o0, 0                                    
4000d1f8:	12 80 00 48 	bne  4000d318 <pipe_create+0x138>              
4000d1fc:	03 00 00 19 	sethi  %hi(0x6400), %g1                        
    return -1;                                                        
                                                                      
  /* /tmp/.fifoXXXX */                                                
  char fifopath[15];                                                  
  memcpy(fifopath, "/tmp/.fifo", 10);                                 
4000d200:	82 10 62 6f 	or  %g1, 0x26f, %g1	! 666f <_TLS_Alignment+0x666e>
4000d204:	c2 37 bf f8 	sth  %g1, [ %fp + -8 ]                         
  sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);                   
4000d208:	03 10 00 83 	sethi  %hi(0x40020c00), %g1                    
4000d20c:	d4 10 63 88 	lduh  [ %g1 + 0x388 ], %o2	! 40020f88 <rtems_pipe_no>
  if (rtems_mkdir("/tmp", S_IRWXU | S_IRWXG | S_IRWXO) != 0)          
    return -1;                                                        
                                                                      
  /* /tmp/.fifoXXXX */                                                
  char fifopath[15];                                                  
  memcpy(fifopath, "/tmp/.fifo", 10);                                 
4000d210:	05 0b dd 1b 	sethi  %hi(0x2f746c00), %g2                    
4000d214:	84 10 a1 70 	or  %g2, 0x170, %g2	! 2f746d70 <RAM_SIZE+0x2f346d70>
4000d218:	07 0b cb 99 	sethi  %hi(0x2f2e6400), %g3                    
4000d21c:	86 10 e2 69 	or  %g3, 0x269, %g3	! 2f2e6669 <RAM_SIZE+0x2eee6669>
4000d220:	c4 3f bf f0 	std  %g2, [ %fp + -16 ]                        
  sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);                   
4000d224:	84 02 a0 01 	add  %o2, 1, %g2                               
4000d228:	90 07 bf fa 	add  %fp, -6, %o0                              
4000d22c:	c4 30 63 88 	sth  %g2, [ %g1 + 0x388 ]                      
4000d230:	95 2a a0 10 	sll  %o2, 0x10, %o2                            
4000d234:	13 10 00 7c 	sethi  %hi(0x4001f000), %o1                    
4000d238:	95 32 a0 10 	srl  %o2, 0x10, %o2                            
4000d23c:	40 00 11 80 	call  4001183c <sprintf>                       
4000d240:	92 12 61 f0 	or  %o1, 0x1f0, %o1                            
                                                                      
  /* Try creating FIFO file until find an available file name */      
  while (mkfifo(fifopath, S_IRUSR|S_IWUSR) != 0) {                    
4000d244:	90 07 bf f0 	add  %fp, -16, %o0                             
4000d248:	40 00 04 98 	call  4000e4a8 <mkfifo>                        
4000d24c:	92 10 21 80 	mov  0x180, %o1                                
4000d250:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000d254:	02 80 00 06 	be  4000d26c <pipe_create+0x8c>                <== ALWAYS TAKEN
4000d258:	90 07 bf f0 	add  %fp, -16, %o0                             
    if (errno != EEXIST){                                             
4000d25c:	40 00 10 68 	call  400113fc <__errno>                       <== NOT EXECUTED
4000d260:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
  unlink(fifopath);                                                   
  }                                                                   
  if(err != 0)                                                        
    rtems_set_errno_and_return_minus_one(err);                        
  return 0;                                                           
}                                                                     
4000d264:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000d268:	91 e8 00 1d 	restore  %g0, %i5, %o0                         <== NOT EXECUTED
    return -1;                                                        
    /* sprintf(fifopath + 10, "%04x", rtems_pipe_no ++); */           
  }                                                                   
                                                                      
  /* Non-blocking open to avoid waiting for writers */                
  filsdes[0] = open(fifopath, O_RDONLY | O_NONBLOCK);                 
4000d26c:	7f ff de 79 	call  40004c50 <open>                          
4000d270:	13 00 00 10 	sethi  %hi(0x4000), %o1                        
  if (filsdes[0] < 0) {                                               
4000d274:	80 a2 20 00 	cmp  %o0, 0                                    
4000d278:	16 80 00 06 	bge  4000d290 <pipe_create+0xb0>               
4000d27c:	d0 26 00 00 	st  %o0, [ %i0 ]                               
    err = errno;                                                      
4000d280:	40 00 10 5f 	call  400113fc <__errno>                       
4000d284:	01 00 00 00 	nop                                            
4000d288:	10 80 00 1c 	b  4000d2f8 <pipe_create+0x118>                
4000d28c:	f8 02 00 00 	ld  [ %o0 ], %i4                               
     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]);                                
4000d290:	03 10 00 7e 	sethi  %hi(0x4001f800), %g1                    
4000d294:	c4 00 63 e0 	ld  [ %g1 + 0x3e0 ], %g2	! 4001fbe0 <rtems_libio_number_iops>
4000d298:	80 a2 00 02 	cmp  %o0, %g2                                  
4000d29c:	1a 80 00 08 	bcc  4000d2bc <pipe_create+0xdc>               <== NEVER TAKEN
4000d2a0:	82 10 20 00 	clr  %g1                                       
4000d2a4:	83 2a 20 03 	sll  %o0, 3, %g1                               
4000d2a8:	91 2a 20 06 	sll  %o0, 6, %o0                               
4000d2ac:	90 22 00 01 	sub  %o0, %g1, %o0                             
4000d2b0:	03 10 00 84 	sethi  %hi(0x40021000), %g1                    
4000d2b4:	c2 00 63 f8 	ld  [ %g1 + 0x3f8 ], %g1	! 400213f8 <rtems_libio_iops>
4000d2b8:	82 00 40 08 	add  %g1, %o0, %g1                             
    iop->flags &= ~LIBIO_FLAGS_NO_DELAY;                              
4000d2bc:	c4 00 60 10 	ld  [ %g1 + 0x10 ], %g2                        
                                                                      
    filsdes[1] = open(fifopath, O_WRONLY);                            
4000d2c0:	90 07 bf f0 	add  %fp, -16, %o0                             
    unlink(fifopath);                                                 
  }                                                                   
  else {                                                              
  /* Reset open file to blocking mode */                              
    iop = rtems_libio_iop(filsdes[0]);                                
    iop->flags &= ~LIBIO_FLAGS_NO_DELAY;                              
4000d2c4:	84 08 bf fe 	and  %g2, -2, %g2                              
                                                                      
    filsdes[1] = open(fifopath, O_WRONLY);                            
4000d2c8:	92 10 20 01 	mov  1, %o1                                    
4000d2cc:	7f ff de 61 	call  40004c50 <open>                          
4000d2d0:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
4000d2d4:	d0 26 20 04 	st  %o0, [ %i0 + 4 ]                           
                                                                      
    if (filsdes[1] < 0) {                                             
4000d2d8:	80 a2 20 00 	cmp  %o0, 0                                    
4000d2dc:	16 80 00 07 	bge  4000d2f8 <pipe_create+0x118>              
4000d2e0:	b8 10 20 00 	clr  %i4                                       
    err = errno;                                                      
4000d2e4:	40 00 10 46 	call  400113fc <__errno>                       
4000d2e8:	01 00 00 00 	nop                                            
4000d2ec:	f8 02 00 00 	ld  [ %o0 ], %i4                               
    close(filsdes[0]);                                                
4000d2f0:	7f ff db 8e 	call  40004128 <close>                         
4000d2f4:	d0 06 00 00 	ld  [ %i0 ], %o0                               
    }                                                                 
  unlink(fifopath);                                                   
4000d2f8:	7f ff e9 ad 	call  400079ac <unlink>                        
4000d2fc:	90 07 bf f0 	add  %fp, -16, %o0                             
  }                                                                   
  if(err != 0)                                                        
4000d300:	80 a7 20 00 	cmp  %i4, 0                                    
4000d304:	22 80 00 07 	be,a   4000d320 <pipe_create+0x140>            
4000d308:	b0 10 00 1d 	mov  %i5, %i0                                  
    rtems_set_errno_and_return_minus_one(err);                        
4000d30c:	40 00 10 3c 	call  400113fc <__errno>                       
4000d310:	01 00 00 00 	nop                                            
4000d314:	f8 22 00 00 	st  %i4, [ %o0 ]                               
{                                                                     
  rtems_libio_t *iop;                                                 
  int err = 0;                                                        
                                                                      
  if (rtems_mkdir("/tmp", S_IRWXU | S_IRWXG | S_IRWXO) != 0)          
    return -1;                                                        
4000d318:	ba 10 3f ff 	mov  -1, %i5                                   
  unlink(fifopath);                                                   
  }                                                                   
  if(err != 0)                                                        
    rtems_set_errno_and_return_minus_one(err);                        
  return 0;                                                           
}                                                                     
4000d31c:	b0 10 00 1d 	mov  %i5, %i0                                  
4000d320:	81 c7 e0 08 	ret                                            
4000d324:	81 e8 00 00 	restore                                        
                                                                      

4000e92c <pipe_ioctl>: pipe_control_t *pipe, ioctl_command_t cmd, void *buffer, rtems_libio_t *iop ) {
4000e92c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (cmd == FIONREAD) {                                              
4000e930:	03 10 01 19 	sethi  %hi(0x40046400), %g1                    
4000e934:	82 10 62 7f 	or  %g1, 0x27f, %g1	! 4004667f <__end+0x2090f> 
4000e938:	80 a6 40 01 	cmp  %i1, %g1                                  
4000e93c:	12 80 00 11 	bne  4000e980 <pipe_ioctl+0x54>                
4000e940:	80 a6 a0 00 	cmp  %i2, 0                                    
    if (buffer == NULL)                                               
4000e944:	02 80 00 11 	be  4000e988 <pipe_ioctl+0x5c>                 
4000e948:	92 10 20 00 	clr  %o1                                       
      return -EFAULT;                                                 
                                                                      
    if (! PIPE_LOCK(pipe))                                            
4000e94c:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
4000e950:	7f ff ea 05 	call  40009164 <rtems_semaphore_obtain>        
4000e954:	94 10 20 00 	clr  %o2                                       
4000e958:	80 a2 20 00 	cmp  %o0, 0                                    
4000e95c:	12 80 00 0d 	bne  4000e990 <pipe_ioctl+0x64>                <== NEVER TAKEN
4000e960:	01 00 00 00 	nop                                            
      return -EINTR;                                                  
                                                                      
    /* Return length of pipe */                                       
    *(unsigned int *)buffer = pipe->Length;                           
4000e964:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
    PIPE_UNLOCK(pipe);                                                
4000e968:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
                                                                      
    if (! PIPE_LOCK(pipe))                                            
      return -EINTR;                                                  
                                                                      
    /* Return length of pipe */                                       
    *(unsigned int *)buffer = pipe->Length;                           
4000e96c:	c2 26 80 00 	st  %g1, [ %i2 ]                               
    PIPE_UNLOCK(pipe);                                                
4000e970:	7f ff ea 45 	call  40009284 <rtems_semaphore_release>       
4000e974:	b0 10 20 00 	clr  %i0                                       
    return 0;                                                         
4000e978:	81 c7 e0 08 	ret                                            
4000e97c:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return -EINVAL;                                                     
4000e980:	81 c7 e0 08 	ret                                            
4000e984:	91 e8 3f ea 	restore  %g0, -22, %o0                         
  rtems_libio_t   *iop                                                
)                                                                     
{                                                                     
  if (cmd == FIONREAD) {                                              
    if (buffer == NULL)                                               
      return -EFAULT;                                                 
4000e988:	81 c7 e0 08 	ret                                            
4000e98c:	91 e8 3f f2 	restore  %g0, -14, %o0                         
    PIPE_UNLOCK(pipe);                                                
    return 0;                                                         
  }                                                                   
                                                                      
  return -EINVAL;                                                     
}                                                                     
4000e990:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e994:	91 e8 3f fc 	restore  %g0, -4, %o0                          <== NOT EXECUTED
                                                                      

4000e5e0 <pipe_read>: pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) {
4000e5e0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int chunk, chunk1, read = 0, ret = 0;                               
                                                                      
  if (! PIPE_LOCK(pipe))                                              
4000e5e4:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
4000e5e8:	92 10 20 00 	clr  %o1                                       
4000e5ec:	7f ff ea de 	call  40009164 <rtems_semaphore_obtain>        
4000e5f0:	94 10 20 00 	clr  %o2                                       
4000e5f4:	80 a2 20 00 	cmp  %o0, 0                                    
4000e5f8:	12 80 00 20 	bne  4000e678 <pipe_read+0x98>                 <== NEVER TAKEN
4000e5fc:	01 00 00 00 	nop                                            
    return -EINTR;                                                    
                                                                      
  while (PIPE_EMPTY(pipe)) {                                          
4000e600:	fa 06 20 0c 	ld  [ %i0 + 0xc ], %i5                         
4000e604:	80 a7 60 00 	cmp  %i5, 0                                    
4000e608:	12 80 00 24 	bne  4000e698 <pipe_read+0xb8>                 
4000e60c:	80 a7 40 1a 	cmp  %i5, %i2                                  
    /* Not an error */                                                
    if (pipe->Writers == 0)                                           
4000e610:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
4000e614:	80 a0 60 00 	cmp  %g1, 0                                    
4000e618:	22 80 00 47 	be,a   4000e734 <pipe_read+0x154>              
4000e61c:	ba 10 20 00 	clr  %i5                                       
      goto out_locked;                                                
                                                                      
    if (LIBIO_NODELAY(iop)) {                                         
4000e620:	c2 06 e0 10 	ld  [ %i3 + 0x10 ], %g1                        
4000e624:	80 88 60 01 	btst  1, %g1                                   
4000e628:	32 80 00 43 	bne,a   4000e734 <pipe_read+0x154>             
4000e62c:	ba 10 3f f5 	mov  -11, %i5                                  
      ret = -EAGAIN;                                                  
      goto out_locked;                                                
    }                                                                 
                                                                      
    /* Wait until pipe is no more empty or no writer exists */        
    pipe->waitingReaders ++;                                          
4000e630:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
    PIPE_UNLOCK(pipe);                                                
4000e634:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
      ret = -EAGAIN;                                                  
      goto out_locked;                                                
    }                                                                 
                                                                      
    /* Wait until pipe is no more empty or no writer exists */        
    pipe->waitingReaders ++;                                          
4000e638:	82 00 60 01 	inc  %g1                                       
    PIPE_UNLOCK(pipe);                                                
4000e63c:	7f ff eb 12 	call  40009284 <rtems_semaphore_release>       
4000e640:	c2 26 20 18 	st  %g1, [ %i0 + 0x18 ]                        
    if (! PIPE_READWAIT(pipe))                                        
4000e644:	d0 06 20 2c 	ld  [ %i0 + 0x2c ], %o0                        
4000e648:	40 00 05 3a 	call  4000fb30 <rtems_barrier_wait>            
4000e64c:	92 10 20 00 	clr  %o1                                       
4000e650:	80 a0 00 08 	cmp  %g0, %o0                                  
      ret = -EINTR;                                                   
    if (! PIPE_LOCK(pipe)) {                                          
4000e654:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
    }                                                                 
                                                                      
    /* Wait until pipe is no more empty or no writer exists */        
    pipe->waitingReaders ++;                                          
    PIPE_UNLOCK(pipe);                                                
    if (! PIPE_READWAIT(pipe))                                        
4000e658:	ba 60 20 00 	subx  %g0, 0, %i5                              
      ret = -EINTR;                                                   
    if (! PIPE_LOCK(pipe)) {                                          
4000e65c:	92 10 20 00 	clr  %o1                                       
4000e660:	94 10 20 00 	clr  %o2                                       
4000e664:	7f ff ea c0 	call  40009164 <rtems_semaphore_obtain>        
4000e668:	ba 0f 7f fc 	and  %i5, -4, %i5                              
4000e66c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e670:	22 80 00 04 	be,a   4000e680 <pipe_read+0xa0>               <== ALWAYS TAKEN
4000e674:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        
)                                                                     
{                                                                     
  int chunk, chunk1, read = 0, ret = 0;                               
                                                                      
  if (! PIPE_LOCK(pipe))                                              
    return -EINTR;                                                    
4000e678:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e67c:	91 e8 3f fc 	restore  %g0, -4, %o0                          <== NOT EXECUTED
      /* WARN waitingReaders not restored! */                         
      ret = -EINTR;                                                   
      goto out_nolock;                                                
    }                                                                 
    pipe->waitingReaders --;                                          
    if (ret != 0)                                                     
4000e680:	80 a7 60 00 	cmp  %i5, 0                                    
    if (! PIPE_LOCK(pipe)) {                                          
      /* WARN waitingReaders not restored! */                         
      ret = -EINTR;                                                   
      goto out_nolock;                                                
    }                                                                 
    pipe->waitingReaders --;                                          
4000e684:	82 00 7f ff 	add  %g1, -1, %g1                              
    if (ret != 0)                                                     
4000e688:	02 bf ff de 	be  4000e600 <pipe_read+0x20>                  <== ALWAYS TAKEN
4000e68c:	c2 26 20 18 	st  %g1, [ %i0 + 0x18 ]                        
  void           *buffer,                                             
  size_t          count,                                              
  rtems_libio_t  *iop                                                 
)                                                                     
{                                                                     
  int chunk, chunk1, read = 0, ret = 0;                               
4000e690:	10 80 00 2a 	b  4000e738 <pipe_read+0x158>                  <== NOT EXECUTED
4000e694:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
    if (ret != 0)                                                     
      goto out_locked;                                                
  }                                                                   
                                                                      
  /* Read chunk bytes */                                              
  chunk = MIN(count - read,  pipe->Length);                           
4000e698:	38 80 00 02 	bgu,a   4000e6a0 <pipe_read+0xc0>              
4000e69c:	ba 10 00 1a 	mov  %i2, %i5                                  
  chunk1 = pipe->Size - pipe->Start;                                  
4000e6a0:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
4000e6a4:	f6 06 20 04 	ld  [ %i0 + 4 ], %i3                           
4000e6a8:	d2 06 00 00 	ld  [ %i0 ], %o1                               
4000e6ac:	b6 26 c0 01 	sub  %i3, %g1, %i3                             
    if (ret != 0)                                                     
      goto out_locked;                                                
  }                                                                   
                                                                      
  /* Read chunk bytes */                                              
  chunk = MIN(count - read,  pipe->Length);                           
4000e6b0:	b8 10 00 1d 	mov  %i5, %i4                                  
  if (chunk > chunk1) {                                               
    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);         
4000e6b4:	94 10 00 1d 	mov  %i5, %o2                                  
  }                                                                   
                                                                      
  /* Read chunk bytes */                                              
  chunk = MIN(count - read,  pipe->Length);                           
  chunk1 = pipe->Size - pipe->Start;                                  
  if (chunk > chunk1) {                                               
4000e6b8:	80 a7 40 1b 	cmp  %i5, %i3                                  
    memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1);        
4000e6bc:	90 10 00 19 	mov  %i1, %o0                                  
  }                                                                   
                                                                      
  /* Read chunk bytes */                                              
  chunk = MIN(count - read,  pipe->Length);                           
  chunk1 = pipe->Size - pipe->Start;                                  
  if (chunk > chunk1) {                                               
4000e6c0:	04 80 00 07 	ble  4000e6dc <pipe_read+0xfc>                 
4000e6c4:	92 02 40 01 	add  %o1, %g1, %o1                             
    memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1);        
4000e6c8:	40 00 0f 74 	call  40012498 <memcpy>                        
4000e6cc:	94 10 00 1b 	mov  %i3, %o2                                  
    memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1);     
4000e6d0:	d2 06 00 00 	ld  [ %i0 ], %o1                               
4000e6d4:	90 06 40 1b 	add  %i1, %i3, %o0                             
4000e6d8:	94 27 40 1b 	sub  %i5, %i3, %o2                             
  }                                                                   
  else                                                                
    memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk);         
4000e6dc:	40 00 0f 6f 	call  40012498 <memcpy>                        
4000e6e0:	01 00 00 00 	nop                                            
                                                                      
  pipe->Start += chunk;                                               
4000e6e4:	d0 06 20 08 	ld  [ %i0 + 8 ], %o0                           
  pipe->Start %= pipe->Size;                                          
4000e6e8:	d2 06 20 04 	ld  [ %i0 + 4 ], %o1                           
4000e6ec:	40 00 40 e5 	call  4001ea80 <.urem>                         
4000e6f0:	90 07 40 08 	add  %i5, %o0, %o0                             
  pipe->Length -= chunk;                                              
4000e6f4:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
  }                                                                   
  else                                                                
    memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk);         
                                                                      
  pipe->Start += chunk;                                               
  pipe->Start %= pipe->Size;                                          
4000e6f8:	d0 26 20 08 	st  %o0, [ %i0 + 8 ]                           
  pipe->Length -= chunk;                                              
4000e6fc:	ba 20 40 1d 	sub  %g1, %i5, %i5                             
  /* For buffering optimization */                                    
  if (PIPE_EMPTY(pipe))                                               
4000e700:	80 a7 60 00 	cmp  %i5, 0                                    
4000e704:	12 80 00 03 	bne  4000e710 <pipe_read+0x130>                
4000e708:	fa 26 20 0c 	st  %i5, [ %i0 + 0xc ]                         
    pipe->Start = 0;                                                  
4000e70c:	c0 26 20 08 	clr  [ %i0 + 8 ]                               
                                                                      
  if (pipe->waitingWriters > 0)                                       
4000e710:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        
4000e714:	80 a0 60 00 	cmp  %g1, 0                                    
4000e718:	02 80 00 08 	be  4000e738 <pipe_read+0x158>                 
4000e71c:	ba 10 20 00 	clr  %i5                                       
    PIPE_WAKEUPWRITERS(pipe);                                         
4000e720:	d0 06 20 30 	ld  [ %i0 + 0x30 ], %o0                        
4000e724:	40 00 04 ed 	call  4000fad8 <rtems_barrier_release>         
4000e728:	92 07 bf fc 	add  %fp, -4, %o1                              
  read += chunk;                                                      
                                                                      
out_locked:                                                           
  PIPE_UNLOCK(pipe);                                                  
4000e72c:	10 80 00 04 	b  4000e73c <pipe_read+0x15c>                  
4000e730:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
  void           *buffer,                                             
  size_t          count,                                              
  rtems_libio_t  *iop                                                 
)                                                                     
{                                                                     
  int chunk, chunk1, read = 0, ret = 0;                               
4000e734:	b8 10 20 00 	clr  %i4                                       
  if (pipe->waitingWriters > 0)                                       
    PIPE_WAKEUPWRITERS(pipe);                                         
  read += chunk;                                                      
                                                                      
out_locked:                                                           
  PIPE_UNLOCK(pipe);                                                  
4000e738:	d0 06 20 28 	ld  [ %i0 + 0x28 ], %o0                        
4000e73c:	7f ff ea d2 	call  40009284 <rtems_semaphore_release>       
4000e740:	b0 10 00 1d 	mov  %i5, %i0                                  
                                                                      
out_nolock:                                                           
  if (read > 0)                                                       
4000e744:	80 a7 20 00 	cmp  %i4, 0                                    
4000e748:	34 80 00 02 	bg,a   4000e750 <pipe_read+0x170>              
4000e74c:	b0 10 00 1c 	mov  %i4, %i0                                  
    return read;                                                      
  return ret;                                                         
}                                                                     
4000e750:	81 c7 e0 08 	ret                                            
4000e754:	81 e8 00 00 	restore                                        
                                                                      

4000e0e0 <pipe_release>: void pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) {
4000e0e0:	9d e3 bf 98 	save  %sp, -104, %sp                           
    /* WARN pipe not released! */                                     
    if (!PIPE_LOCK(pipe))                                             
      rtems_fatal_error_occurred(0xdeadbeef);                         
  #endif                                                              
                                                                      
  mode = LIBIO_ACCMODE(iop);                                          
4000e0e4:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
void pipe_release(                                                    
  pipe_control_t **pipep,                                             
  rtems_libio_t *iop                                                  
)                                                                     
{                                                                     
  pipe_control_t *pipe = *pipep;                                      
4000e0e8:	fa 06 00 00 	ld  [ %i0 ], %i5                               
    if (!PIPE_LOCK(pipe))                                             
      rtems_fatal_error_occurred(0xdeadbeef);                         
  #endif                                                              
                                                                      
  mode = LIBIO_ACCMODE(iop);                                          
  if (mode & LIBIO_FLAGS_READ)                                        
4000e0ec:	80 88 60 02 	btst  2, %g1                                   
4000e0f0:	02 80 00 05 	be  4000e104 <pipe_release+0x24>               
4000e0f4:	b8 08 60 06 	and  %g1, 6, %i4                               
     pipe->Readers --;                                                
4000e0f8:	c4 07 60 10 	ld  [ %i5 + 0x10 ], %g2                        
4000e0fc:	84 00 bf ff 	add  %g2, -1, %g2                              
4000e100:	c4 27 60 10 	st  %g2, [ %i5 + 0x10 ]                        
  if (mode & LIBIO_FLAGS_WRITE)                                       
4000e104:	80 88 60 04 	btst  4, %g1                                   
4000e108:	02 80 00 05 	be  4000e11c <pipe_release+0x3c>               
4000e10c:	01 00 00 00 	nop                                            
     pipe->Writers --;                                                
4000e110:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000e114:	82 00 7f ff 	add  %g1, -1, %g1                              
4000e118:	c2 27 60 14 	st  %g1, [ %i5 + 0x14 ]                        
                                                                      
  PIPE_UNLOCK(pipe);                                                  
4000e11c:	7f ff ec 5a 	call  40009284 <rtems_semaphore_release>       
4000e120:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
                                                                      
  if (pipe->Readers == 0 && pipe->Writers == 0) {                     
4000e124:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000e128:	80 a0 60 00 	cmp  %g1, 0                                    
4000e12c:	12 80 00 0d 	bne  4000e160 <pipe_release+0x80>              
4000e130:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000e134:	80 a0 60 00 	cmp  %g1, 0                                    
4000e138:	12 80 00 06 	bne  4000e150 <pipe_release+0x70>              
4000e13c:	80 a7 20 04 	cmp  %i4, 4                                    
#if 0                                                                 
    /* To delete an anonymous pipe file when all users closed it */   
    if (pipe->Anonymous)                                              
      delfile = TRUE;                                                 
#endif                                                                
    pipe_free(pipe);                                                  
4000e140:	7f ff ff dd 	call  4000e0b4 <pipe_free>                     
4000e144:	90 10 00 1d 	mov  %i5, %o0                                  
    *pipep = NULL;                                                    
4000e148:	10 80 00 0e 	b  4000e180 <pipe_release+0xa0>                
4000e14c:	c0 26 00 00 	clr  [ %i0 ]                                   
  }                                                                   
  else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE)           
4000e150:	02 80 00 05 	be  4000e164 <pipe_release+0x84>               <== NEVER TAKEN
4000e154:	80 a0 60 00 	cmp  %g1, 0                                    
    /* Notify waiting Writers that all their partners left */         
    PIPE_WAKEUPWRITERS(pipe);                                         
4000e158:	10 80 00 08 	b  4000e178 <pipe_release+0x98>                
4000e15c:	d0 07 60 30 	ld  [ %i5 + 0x30 ], %o0                        
  else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)            
4000e160:	80 a0 60 00 	cmp  %g1, 0                                    
4000e164:	12 80 00 07 	bne  4000e180 <pipe_release+0xa0>              <== NEVER TAKEN
4000e168:	80 a7 20 02 	cmp  %i4, 2                                    
4000e16c:	02 80 00 06 	be  4000e184 <pipe_release+0xa4>               <== NEVER TAKEN
4000e170:	03 10 00 92 	sethi  %hi(0x40024800), %g1                    
    PIPE_WAKEUPREADERS(pipe);                                         
4000e174:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        
4000e178:	40 00 06 58 	call  4000fad8 <rtems_barrier_release>         
4000e17c:	92 07 bf fc 	add  %fp, -4, %o1                              
#ifdef RTEMS_DEBUG                                                    
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  sc =                                                                
#endif                                                                
   rtems_semaphore_release(pipe_semaphore);                           
4000e180:	03 10 00 92 	sethi  %hi(0x40024800), %g1                    
4000e184:	7f ff ec 40 	call  40009284 <rtems_semaphore_release>       
4000e188:	d0 00 61 c8 	ld  [ %g1 + 0x1c8 ], %o0	! 400249c8 <pipe_semaphore>
4000e18c:	81 c7 e0 08 	ret                                            
4000e190:	81 e8 00 00 	restore                                        
                                                                      

4000e758 <pipe_write>: pipe_control_t *pipe, const void *buffer, size_t count, rtems_libio_t *iop ) {
4000e758:	9d e3 bf 98 	save  %sp, -104, %sp                           
4000e75c:	ba 10 00 18 	mov  %i0, %i5                                  
  int chunk, chunk1, written = 0, ret = 0;                            
                                                                      
  /* Write nothing */                                                 
  if (count == 0)                                                     
4000e760:	80 a6 a0 00 	cmp  %i2, 0                                    
4000e764:	02 80 00 70 	be  4000e924 <pipe_write+0x1cc>                <== NEVER TAKEN
4000e768:	b0 10 20 00 	clr  %i0                                       
    return 0;                                                         
                                                                      
  if (! PIPE_LOCK(pipe))                                              
4000e76c:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
4000e770:	92 10 20 00 	clr  %o1                                       
4000e774:	7f ff ea 7c 	call  40009164 <rtems_semaphore_obtain>        
4000e778:	94 10 20 00 	clr  %o2                                       
4000e77c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e780:	32 80 00 69 	bne,a   4000e924 <pipe_write+0x1cc>            <== NEVER TAKEN
4000e784:	b0 10 3f fc 	mov  -4, %i0                                   <== NOT EXECUTED
    return -EINTR;                                                    
                                                                      
  if (pipe->Readers == 0) {                                           
4000e788:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000e78c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e790:	22 80 00 54 	be,a   4000e8e0 <pipe_write+0x188>             
4000e794:	b0 10 3f e0 	mov  -32, %i0                                  
    ret = -EPIPE;                                                     
    goto out_locked;                                                  
  }                                                                   
                                                                      
  /* Write of PIPE_BUF bytes or less shall not be interleaved */      
  chunk = count <= pipe->Size ? count : 1;                            
4000e798:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
4000e79c:	80 a6 80 01 	cmp  %i2, %g1                                  
4000e7a0:	18 80 00 03 	bgu  4000e7ac <pipe_write+0x54>                <== NEVER TAKEN
4000e7a4:	a2 10 20 01 	mov  1, %l1                                    
4000e7a8:	a2 10 00 1a 	mov  %i2, %l1                                  
                                                                      
      /* Wait until there is chunk bytes space or no reader exists */ 
      pipe->waitingWriters ++;                                        
      PIPE_UNLOCK(pipe);                                              
      if (! PIPE_WRITEWAIT(pipe))                                     
        ret = -EINTR;                                                 
4000e7ac:	b8 10 20 00 	clr  %i4                                       
  }                                                                   
                                                                      
  /* Write of PIPE_BUF bytes or less shall not be interleaved */      
  chunk = count <= pipe->Size ? count : 1;                            
                                                                      
  while (written < count) {                                           
4000e7b0:	80 a7 00 1a 	cmp  %i4, %i2                                  
4000e7b4:	1a 80 00 4c 	bcc  4000e8e4 <pipe_write+0x18c>               
4000e7b8:	b0 10 20 00 	clr  %i0                                       
    while (PIPE_SPACE(pipe) < chunk) {                                
4000e7bc:	e0 07 60 04 	ld  [ %i5 + 4 ], %l0                           
4000e7c0:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4000e7c4:	b0 24 00 01 	sub  %l0, %g1, %i0                             
4000e7c8:	80 a6 00 11 	cmp  %i0, %l1                                  
4000e7cc:	1a 80 00 22 	bcc  4000e854 <pipe_write+0xfc>                
4000e7d0:	84 26 80 1c 	sub  %i2, %i4, %g2                             
      if (LIBIO_NODELAY(iop)) {                                       
4000e7d4:	c2 06 e0 10 	ld  [ %i3 + 0x10 ], %g1                        
4000e7d8:	80 88 60 01 	btst  1, %g1                                   
4000e7dc:	32 80 00 42 	bne,a   4000e8e4 <pipe_write+0x18c>            
4000e7e0:	b0 10 3f f5 	mov  -11, %i0                                  
        ret = -EAGAIN;                                                
        goto out_locked;                                              
      }                                                               
                                                                      
      /* Wait until there is chunk bytes space or no reader exists */ 
      pipe->waitingWriters ++;                                        
4000e7e4:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
      PIPE_UNLOCK(pipe);                                              
4000e7e8:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
        ret = -EAGAIN;                                                
        goto out_locked;                                              
      }                                                               
                                                                      
      /* Wait until there is chunk bytes space or no reader exists */ 
      pipe->waitingWriters ++;                                        
4000e7ec:	82 00 60 01 	inc  %g1                                       
      PIPE_UNLOCK(pipe);                                              
4000e7f0:	7f ff ea a5 	call  40009284 <rtems_semaphore_release>       
4000e7f4:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        
      if (! PIPE_WRITEWAIT(pipe))                                     
4000e7f8:	d0 07 60 30 	ld  [ %i5 + 0x30 ], %o0                        
4000e7fc:	40 00 04 cd 	call  4000fb30 <rtems_barrier_wait>            
4000e800:	92 10 20 00 	clr  %o1                                       
4000e804:	80 a0 00 08 	cmp  %g0, %o0                                  
        ret = -EINTR;                                                 
      if (! PIPE_LOCK(pipe)) {                                        
4000e808:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
      }                                                               
                                                                      
      /* Wait until there is chunk bytes space or no reader exists */ 
      pipe->waitingWriters ++;                                        
      PIPE_UNLOCK(pipe);                                              
      if (! PIPE_WRITEWAIT(pipe))                                     
4000e80c:	b0 60 20 00 	subx  %g0, 0, %i0                              
        ret = -EINTR;                                                 
      if (! PIPE_LOCK(pipe)) {                                        
4000e810:	92 10 20 00 	clr  %o1                                       
4000e814:	94 10 20 00 	clr  %o2                                       
4000e818:	7f ff ea 53 	call  40009164 <rtems_semaphore_obtain>        
4000e81c:	b0 0e 3f fc 	and  %i0, -4, %i0                              
4000e820:	80 a2 20 00 	cmp  %o0, 0                                    
4000e824:	12 80 00 3b 	bne  4000e910 <pipe_write+0x1b8>               <== NEVER TAKEN
4000e828:	80 a6 20 00 	cmp  %i0, 0                                    
        /* WARN waitingWriters not restored! */                       
        ret = -EINTR;                                                 
        goto out_nolock;                                              
      }                                                               
      pipe->waitingWriters --;                                        
4000e82c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
4000e830:	82 00 7f ff 	add  %g1, -1, %g1                              
      if (ret != 0)                                                   
4000e834:	12 80 00 2c 	bne  4000e8e4 <pipe_write+0x18c>               <== NEVER TAKEN
4000e838:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        
        goto out_locked;                                              
                                                                      
      if (pipe->Readers == 0) {                                       
4000e83c:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000e840:	80 a0 60 00 	cmp  %g1, 0                                    
4000e844:	32 bf ff df 	bne,a   4000e7c0 <pipe_write+0x68>             <== ALWAYS TAKEN
4000e848:	e0 07 60 04 	ld  [ %i5 + 4 ], %l0                           
        ret = -EPIPE;                                                 
4000e84c:	10 80 00 26 	b  4000e8e4 <pipe_write+0x18c>                 <== NOT EXECUTED
4000e850:	b0 10 3f e0 	mov  -32, %i0                                  <== NOT EXECUTED
        goto out_locked;                                              
      }                                                               
    }                                                                 
                                                                      
    chunk = MIN(count - written, PIPE_SPACE(pipe));                   
4000e854:	80 a6 00 02 	cmp  %i0, %g2                                  
4000e858:	38 80 00 02 	bgu,a   4000e860 <pipe_write+0x108>            
4000e85c:	b0 10 00 02 	mov  %g2, %i0                                  
    chunk1 = pipe->Size - PIPE_WSTART(pipe);                          
4000e860:	d0 07 60 08 	ld  [ %i5 + 8 ], %o0                           
4000e864:	92 10 00 10 	mov  %l0, %o1                                  
4000e868:	40 00 40 86 	call  4001ea80 <.urem>                         
4000e86c:	90 00 40 08 	add  %g1, %o0, %o0                             
4000e870:	c2 07 40 00 	ld  [ %i5 ], %g1                               
4000e874:	a0 24 00 08 	sub  %l0, %o0, %l0                             
    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);
4000e878:	94 10 00 18 	mov  %i0, %o2                                  
      }                                                               
    }                                                                 
                                                                      
    chunk = MIN(count - written, PIPE_SPACE(pipe));                   
    chunk1 = pipe->Size - PIPE_WSTART(pipe);                          
    if (chunk > chunk1) {                                             
4000e87c:	80 a6 00 10 	cmp  %i0, %l0                                  
4000e880:	92 06 40 1c 	add  %i1, %i4, %o1                             
4000e884:	04 80 00 08 	ble  4000e8a4 <pipe_write+0x14c>               
4000e888:	90 00 40 08 	add  %g1, %o0, %o0                             
      memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1);
4000e88c:	40 00 0f 03 	call  40012498 <memcpy>                        
4000e890:	94 10 00 10 	mov  %l0, %o2                                  
      memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1);
4000e894:	d0 07 40 00 	ld  [ %i5 ], %o0                               
4000e898:	92 04 00 1c 	add  %l0, %i4, %o1                             
4000e89c:	94 26 00 10 	sub  %i0, %l0, %o2                             
4000e8a0:	92 06 40 09 	add  %i1, %o1, %o1                             
    }                                                                 
    else                                                              
      memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk);
4000e8a4:	40 00 0e fd 	call  40012498 <memcpy>                        
4000e8a8:	01 00 00 00 	nop                                            
                                                                      
    pipe->Length += chunk;                                            
4000e8ac:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4000e8b0:	82 00 40 18 	add  %g1, %i0, %g1                             
4000e8b4:	c2 27 60 0c 	st  %g1, [ %i5 + 0xc ]                         
    if (pipe->waitingReaders > 0)                                     
4000e8b8:	c2 07 60 18 	ld  [ %i5 + 0x18 ], %g1                        
4000e8bc:	80 a0 60 00 	cmp  %g1, 0                                    
4000e8c0:	22 80 00 06 	be,a   4000e8d8 <pipe_write+0x180>             
4000e8c4:	b8 07 00 18 	add  %i4, %i0, %i4                             
      PIPE_WAKEUPREADERS(pipe);                                       
4000e8c8:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        
4000e8cc:	40 00 04 83 	call  4000fad8 <rtems_barrier_release>         
4000e8d0:	92 07 bf fc 	add  %fp, -4, %o1                              
    written += chunk;                                                 
4000e8d4:	b8 07 00 18 	add  %i4, %i0, %i4                             
    /* Write of more than PIPE_BUF bytes can be interleaved */        
    chunk = 1;                                                        
4000e8d8:	10 bf ff b6 	b  4000e7b0 <pipe_write+0x58>                  
4000e8dc:	a2 10 20 01 	mov  1, %l1                                    
4000e8e0:	b8 10 20 00 	clr  %i4                                       
  }                                                                   
                                                                      
out_locked:                                                           
  PIPE_UNLOCK(pipe);                                                  
4000e8e4:	7f ff ea 68 	call  40009284 <rtems_semaphore_release>       
4000e8e8:	d0 07 60 28 	ld  [ %i5 + 0x28 ], %o0                        
                                                                      
out_nolock:                                                           
#ifdef RTEMS_POSIX_API                                                
  /* Signal SIGPIPE */                                                
  if (ret == -EPIPE)                                                  
4000e8ec:	80 a6 3f e0 	cmp  %i0, -32                                  
4000e8f0:	32 80 00 0a 	bne,a   4000e918 <pipe_write+0x1c0>            
4000e8f4:	80 a7 20 00 	cmp  %i4, 0                                    
    kill(getpid(), SIGPIPE);                                          
4000e8f8:	40 00 01 48 	call  4000ee18 <getpid>                        
4000e8fc:	01 00 00 00 	nop                                            
4000e900:	40 00 02 91 	call  4000f344 <kill>                          
4000e904:	92 10 20 0d 	mov  0xd, %o1	! d <_TLS_Alignment+0xc>         
#endif                                                                
                                                                      
  if (written > 0)                                                    
4000e908:	10 80 00 04 	b  4000e918 <pipe_write+0x1c0>                 
4000e90c:	80 a7 20 00 	cmp  %i4, 0                                    
      PIPE_UNLOCK(pipe);                                              
      if (! PIPE_WRITEWAIT(pipe))                                     
        ret = -EINTR;                                                 
      if (! PIPE_LOCK(pipe)) {                                        
        /* WARN waitingWriters not restored! */                       
        ret = -EINTR;                                                 
4000e910:	b0 10 3f fc 	mov  -4, %i0                                   <== NOT EXECUTED
  /* Signal SIGPIPE */                                                
  if (ret == -EPIPE)                                                  
    kill(getpid(), SIGPIPE);                                          
#endif                                                                
                                                                      
  if (written > 0)                                                    
4000e914:	80 a7 20 00 	cmp  %i4, 0                                    <== NOT EXECUTED
4000e918:	04 80 00 03 	ble  4000e924 <pipe_write+0x1cc>               
4000e91c:	01 00 00 00 	nop                                            
4000e920:	b0 10 00 1c 	mov  %i4, %i0                                  
    return written;                                                   
  return ret;                                                         
}                                                                     
4000e924:	81 c7 e0 08 	ret                                            
4000e928:	81 e8 00 00 	restore                                        
                                                                      

40008b68 <posix_memalign>: ) { /* * Update call statistics */ MSBUMP(memalign_calls, 1);
40008b68:	05 10 00 82 	sethi  %hi(0x40020800), %g2                    
40008b6c:	84 10 a1 40 	or  %g2, 0x140, %g2	! 40020940 <rtems_malloc_statistics>
40008b70:	c6 00 a0 08 	ld  [ %g2 + 8 ], %g3                           
40008b74:	86 00 e0 01 	inc  %g3                                       
40008b78:	c6 20 a0 08 	st  %g3, [ %g2 + 8 ]                           
                                                                      
  if (((alignment - 1) & alignment) != 0 || (alignment < sizeof(void *)))
40008b7c:	84 02 7f ff 	add  %o1, -1, %g2                              
40008b80:	80 88 80 09 	btst  %g2, %o1                                 
40008b84:	12 80 00 07 	bne  40008ba0 <posix_memalign+0x38>            <== NEVER TAKEN
40008b88:	80 a2 60 03 	cmp  %o1, 3                                    
40008b8c:	08 80 00 05 	bleu  40008ba0 <posix_memalign+0x38>           
40008b90:	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 );                  
40008b94:	82 13 c0 00 	mov  %o7, %g1                                  
40008b98:	40 00 00 ca 	call  40008ec0 <rtems_memalign>                
40008b9c:	9e 10 40 00 	mov  %g1, %o7                                  
}                                                                     
40008ba0:	81 c3 e0 08 	retl                                           
40008ba4:	90 10 20 16 	mov  0x16, %o0                                 
                                                                      

4000c908 <pthread_attr_setschedpolicy>: int pthread_attr_setschedpolicy( pthread_attr_t *attr, int policy ) {
4000c908:	82 10 00 08 	mov  %o0, %g1                                  
  if ( !attr || !attr->is_initialized )                               
4000c90c:	80 a0 60 00 	cmp  %g1, 0                                    
4000c910:	02 80 00 0f 	be  4000c94c <pthread_attr_setschedpolicy+0x44>
4000c914:	90 10 20 16 	mov  0x16, %o0                                 
4000c918:	c4 00 40 00 	ld  [ %g1 ], %g2                               
4000c91c:	80 a0 a0 00 	cmp  %g2, 0                                    
4000c920:	02 80 00 0b 	be  4000c94c <pthread_attr_setschedpolicy+0x44>
4000c924:	80 a2 60 04 	cmp  %o1, 4                                    
    case SCHED_SPORADIC:                                              
      attr->schedpolicy = policy;                                     
      return 0;                                                       
                                                                      
    default:                                                          
      return ENOTSUP;                                                 
4000c928:	18 80 00 09 	bgu  4000c94c <pthread_attr_setschedpolicy+0x44>
4000c92c:	90 10 20 86 	mov  0x86, %o0                                 
4000c930:	84 10 20 01 	mov  1, %g2                                    
4000c934:	85 28 80 09 	sll  %g2, %o1, %g2                             
4000c938:	80 88 a0 17 	btst  0x17, %g2                                
4000c93c:	02 80 00 04 	be  4000c94c <pthread_attr_setschedpolicy+0x44><== NEVER TAKEN
4000c940:	01 00 00 00 	nop                                            
  switch ( policy ) {                                                 
    case SCHED_OTHER:                                                 
    case SCHED_FIFO:                                                  
    case SCHED_RR:                                                    
    case SCHED_SPORADIC:                                              
      attr->schedpolicy = policy;                                     
4000c944:	d2 20 60 14 	st  %o1, [ %g1 + 0x14 ]                        
      return 0;                                                       
4000c948:	90 10 20 00 	clr  %o0                                       
                                                                      
    default:                                                          
      return ENOTSUP;                                                 
  }                                                                   
}                                                                     
4000c94c:	81 c3 e0 08 	retl                                           
                                                                      

40007ae4 <pthread_barrier_init>: int pthread_barrier_init( pthread_barrier_t *barrier, const pthread_barrierattr_t *attr, unsigned int count ) {
40007ae4:	9d e3 bf 90 	save  %sp, -112, %sp                           
  const pthread_barrierattr_t   *the_attr;                            
                                                                      
  /*                                                                  
   *  Error check parameters                                          
   */                                                                 
  if ( !barrier )                                                     
40007ae8:	80 a6 20 00 	cmp  %i0, 0                                    
40007aec:	02 80 00 2e 	be  40007ba4 <pthread_barrier_init+0xc0>       
40007af0:	80 a6 a0 00 	cmp  %i2, 0                                    
    return EINVAL;                                                    
                                                                      
  if ( count == 0 )                                                   
40007af4:	02 80 00 2d 	be  40007ba8 <pthread_barrier_init+0xc4>       
40007af8:	b8 10 20 16 	mov  0x16, %i4                                 
    return EINVAL;                                                    
                                                                      
  /*                                                                  
   * If the user passed in NULL, use the default attributes           
   */                                                                 
  if ( attr ) {                                                       
40007afc:	80 a6 60 00 	cmp  %i1, 0                                    
40007b00:	32 80 00 06 	bne,a   40007b18 <pthread_barrier_init+0x34>   
40007b04:	c2 06 40 00 	ld  [ %i1 ], %g1                               
    the_attr = attr;                                                  
  } else {                                                            
    (void) pthread_barrierattr_init( &my_attr );                      
40007b08:	90 07 bf f8 	add  %fp, -8, %o0                              
40007b0c:	7f ff ff 81 	call  40007910 <pthread_barrierattr_init>      
40007b10:	b2 07 bf f8 	add  %fp, -8, %i1                              
  }                                                                   
                                                                      
  /*                                                                  
   * Now start error checking the attributes that we are going to use 
   */                                                                 
  if ( !the_attr->is_initialized )                                    
40007b14:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40007b18:	80 a0 60 00 	cmp  %g1, 0                                    
40007b1c:	02 80 00 23 	be  40007ba8 <pthread_barrier_init+0xc4>       
40007b20:	b8 10 20 16 	mov  0x16, %i4                                 
    return EINVAL;                                                    
                                                                      
  switch ( the_attr->process_shared ) {                               
40007b24:	f8 06 60 04 	ld  [ %i1 + 4 ], %i4                           
40007b28:	80 a7 20 00 	cmp  %i4, 0                                    
40007b2c:	32 80 00 1f 	bne,a   40007ba8 <pthread_barrier_init+0xc4>   <== NEVER TAKEN
40007b30:	b8 10 20 16 	mov  0x16, %i4                                 <== NOT EXECUTED
                                                                      
  /*                                                                  
   * Convert from POSIX attributes to Core Barrier attributes         
   */                                                                 
  the_attributes.discipline    = CORE_BARRIER_AUTOMATIC_RELEASE;      
  the_attributes.maximum_count = count;                               
40007b34:	f4 27 bf f4 	st  %i2, [ %fp + -12 ]                         
  }                                                                   
                                                                      
  /*                                                                  
   * Convert from POSIX attributes to Core Barrier attributes         
   */                                                                 
  the_attributes.discipline    = CORE_BARRIER_AUTOMATIC_RELEASE;      
40007b38:	c0 27 bf f0 	clr  [ %fp + -16 ]                             
 * 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 *)                                    
40007b3c:	37 10 00 67 	sethi  %hi(0x40019c00), %i3                    
40007b40:	35 10 00 66 	sethi  %hi(0x40019800), %i2                    
40007b44:	40 00 08 92 	call  40009d8c <_Objects_Allocate>             
40007b48:	90 16 e0 98 	or  %i3, 0x98, %o0                             
  the_attributes.maximum_count = count;                               
                                                                      
  the_barrier = _POSIX_Barrier_Allocate();                            
                                                                      
  if ( !the_barrier ) {                                               
40007b4c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40007b50:	12 80 00 07 	bne  40007b6c <pthread_barrier_init+0x88>      
40007b54:	90 07 60 10 	add  %i5, 0x10, %o0                            
40007b58:	d0 06 a1 d8 	ld  [ %i2 + 0x1d8 ], %o0                       
40007b5c:	40 00 05 98 	call  400091bc <_API_Mutex_Unlock>             
40007b60:	b8 10 20 0b 	mov  0xb, %i4                                  
  );                                                                  
                                                                      
  *barrier = the_barrier->Object.id;                                  
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40007b64:	81 c7 e0 08 	ret                                            
40007b68:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
  if ( !the_barrier ) {                                               
    _Objects_Allocator_unlock();                                      
    return EAGAIN;                                                    
  }                                                                   
                                                                      
  _CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes ); 
40007b6c:	40 00 05 d0 	call  400092ac <_CORE_barrier_Initialize>      
40007b70:	92 07 bf f0 	add  %fp, -16, %o1                             
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
40007b74:	c4 17 60 0a 	lduh  [ %i5 + 0xa ], %g2                       
  Objects_Control     *the_object,                                    
  uint32_t             name                                           
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
40007b78:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open_u32(                          
  Objects_Information *information,                                   
40007b7c:	b6 16 e0 98 	or  %i3, 0x98, %i3                             
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40007b80:	c6 06 e0 1c 	ld  [ %i3 + 0x1c ], %g3                        
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
40007b84:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40007b88:	85 28 a0 02 	sll  %g2, 2, %g2                               
40007b8c:	fa 20 c0 02 	st  %i5, [ %g3 + %g2 ]                         
40007b90:	d0 06 a1 d8 	ld  [ %i2 + 0x1d8 ], %o0                       
40007b94:	40 00 05 8a 	call  400091bc <_API_Mutex_Unlock>             
40007b98:	c2 26 00 00 	st  %g1, [ %i0 ]                               
  );                                                                  
                                                                      
  *barrier = the_barrier->Object.id;                                  
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40007b9c:	81 c7 e0 08 	ret                                            
40007ba0:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
  switch ( the_attr->process_shared ) {                               
    case PTHREAD_PROCESS_PRIVATE:    /* only supported values */      
      break;                                                          
    case PTHREAD_PROCESS_SHARED:                                      
    default:                                                          
      return EINVAL;                                                  
40007ba4:	b8 10 20 16 	mov  0x16, %i4                                 
  );                                                                  
                                                                      
  *barrier = the_barrier->Object.id;                                  
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40007ba8:	b0 10 00 1c 	mov  %i4, %i0                                  
40007bac:	81 c7 e0 08 	ret                                            
40007bb0:	81 e8 00 00 	restore                                        
                                                                      

40010838 <pthread_cond_init>: */ int pthread_cond_init( pthread_cond_t *cond, const pthread_condattr_t *attr ) {
40010838:	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;                                        
4001083c:	80 a6 60 00 	cmp  %i1, 0                                    
40010840:	32 80 00 05 	bne,a   40010854 <pthread_cond_init+0x1c>      
40010844:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           
  else        the_attr = &_POSIX_Condition_variables_Default_attributes;
40010848:	33 10 00 6a 	sethi  %hi(0x4001a800), %i1                    
4001084c:	b2 16 62 d0 	or  %i1, 0x2d0, %i1	! 4001aad0 <_POSIX_Condition_variables_Default_attributes>
                                                                      
  /*                                                                  
   *  Be careful about attributes when global!!!                      
   */                                                                 
  if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )           
40010850:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           
40010854:	80 a0 a0 01 	cmp  %g2, 1                                    
40010858:	02 80 00 22 	be  400108e0 <pthread_cond_init+0xa8>          <== NEVER TAKEN
4001085c:	82 10 20 16 	mov  0x16, %g1                                 
    return EINVAL;                                                    
                                                                      
  if ( !the_attr->is_initialized )                                    
40010860:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40010864:	80 a0 a0 00 	cmp  %g2, 0                                    
40010868:	02 80 00 1e 	be  400108e0 <pthread_cond_init+0xa8>          
4001086c:	39 10 00 73 	sethi  %hi(0x4001cc00), %i4                    
40010870:	37 10 00 72 	sethi  %hi(0x4001c800), %i3                    
 *  the inactive chain of free condition variable control blocks.     
 */                                                                   
RTEMS_INLINE_ROUTINE POSIX_Condition_variables_Control *              
  _POSIX_Condition_variables_Allocate( void )                         
{                                                                     
  return (POSIX_Condition_variables_Control *)                        
40010874:	7f ff e6 3a 	call  4000a15c <_Objects_Allocate>             
40010878:	90 17 20 08 	or  %i4, 8, %o0                                
    return EINVAL;                                                    
                                                                      
  the_cond = _POSIX_Condition_variables_Allocate();                   
                                                                      
  if ( !the_cond ) {                                                  
4001087c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40010880:	32 80 00 06 	bne,a   40010898 <pthread_cond_init+0x60>      
40010884:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
40010888:	7f ff e3 8f 	call  400096c4 <_API_Mutex_Unlock>             
4001088c:	d0 06 e0 b8 	ld  [ %i3 + 0xb8 ], %o0                        
    _Objects_Allocator_unlock();                                      
    return ENOMEM;                                                    
40010890:	10 80 00 14 	b  400108e0 <pthread_cond_init+0xa8>           
40010894:	82 10 20 0c 	mov  0xc, %g1                                  
                                                                      
  the_cond->process_shared  = the_attr->process_shared;               
                                                                      
  the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX;               
                                                                      
  _Thread_queue_Initialize(                                           
40010898:	90 07 60 18 	add  %i5, 0x18, %o0                            
  if ( !the_cond ) {                                                  
    _Objects_Allocator_unlock();                                      
    return ENOMEM;                                                    
  }                                                                   
                                                                      
  the_cond->process_shared  = the_attr->process_shared;               
4001089c:	c2 27 60 10 	st  %g1, [ %i5 + 0x10 ]                        
                                                                      
  the_cond->Mutex = POSIX_CONDITION_VARIABLES_NO_MUTEX;               
                                                                      
  _Thread_queue_Initialize(                                           
400108a0:	92 10 20 00 	clr  %o1                                       
400108a4:	15 04 00 02 	sethi  %hi(0x10000800), %o2                    
400108a8:	96 10 20 74 	mov  0x74, %o3                                 
400108ac:	7f ff ec cb 	call  4000bbd8 <_Thread_queue_Initialize>      
400108b0:	c0 27 60 14 	clr  [ %i5 + 0x14 ]                            
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
400108b4:	c4 17 60 0a 	lduh  [ %i5 + 0xa ], %g2                       
  Objects_Control     *the_object,                                    
  uint32_t             name                                           
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
400108b8:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open_u32(                          
  Objects_Information *information,                                   
400108bc:	b8 17 20 08 	or  %i4, 8, %i4                                
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
400108c0:	c6 07 20 1c 	ld  [ %i4 + 0x1c ], %g3                        
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
400108c4:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
400108c8:	85 28 a0 02 	sll  %g2, 2, %g2                               
400108cc:	fa 20 c0 02 	st  %i5, [ %g3 + %g2 ]                         
400108d0:	d0 06 e0 b8 	ld  [ %i3 + 0xb8 ], %o0                        
400108d4:	7f ff e3 7c 	call  400096c4 <_API_Mutex_Unlock>             
400108d8:	c2 26 00 00 	st  %g1, [ %i0 ]                               
                                                                      
  *cond = the_cond->Object.id;                                        
                                                                      
  _Objects_Allocator_unlock();                                        
                                                                      
  return 0;                                                           
400108dc:	82 10 20 00 	clr  %g1                                       
}                                                                     
400108e0:	81 c7 e0 08 	ret                                            
400108e4:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40008224 <pthread_condattr_destroy>: */ int pthread_condattr_destroy( pthread_condattr_t *attr ) {
40008224:	82 10 00 08 	mov  %o0, %g1                                  
  if ( !attr || attr->is_initialized == false )                       
40008228:	80 a0 60 00 	cmp  %g1, 0                                    
4000822c:	02 80 00 08 	be  4000824c <pthread_condattr_destroy+0x28>   
40008230:	90 10 20 16 	mov  0x16, %o0                                 
40008234:	c4 00 40 00 	ld  [ %g1 ], %g2                               
40008238:	80 a0 a0 00 	cmp  %g2, 0                                    
4000823c:	02 80 00 04 	be  4000824c <pthread_condattr_destroy+0x28>   <== NEVER TAKEN
40008240:	01 00 00 00 	nop                                            
    return EINVAL;                                                    
                                                                      
  attr->is_initialized = false;                                       
40008244:	c0 20 40 00 	clr  [ %g1 ]                                   
  return 0;                                                           
40008248:	90 10 20 00 	clr  %o0                                       
}                                                                     
4000824c:	81 c3 e0 08 	retl                                           
                                                                      

40007510 <pthread_create>: pthread_t *thread, const pthread_attr_t *attr, void *(*start_routine)( void * ), void *arg ) {
40007510:	9d e3 bf 58 	save  %sp, -168, %sp                           
  int                                 schedpolicy = SCHED_RR;         
  struct sched_param                  schedparam;                     
  Objects_Name                        name;                           
  int                                 rc;                             
                                                                      
  if ( !start_routine )                                               
40007514:	80 a6 a0 00 	cmp  %i2, 0                                    
40007518:	02 80 00 94 	be  40007768 <pthread_create+0x258>            
4000751c:	ba 10 20 0e 	mov  0xe, %i5                                  
    return EFAULT;                                                    
                                                                      
  the_attr = (attr) ? attr : &_POSIX_Threads_Default_attributes;      
40007520:	80 a6 60 00 	cmp  %i1, 0                                    
40007524:	32 80 00 05 	bne,a   40007538 <pthread_create+0x28>         
40007528:	c2 06 40 00 	ld  [ %i1 ], %g1                               
4000752c:	33 10 00 7c 	sethi  %hi(0x4001f000), %i1                    
40007530:	b2 16 62 c4 	or  %i1, 0x2c4, %i1	! 4001f2c4 <_POSIX_Threads_Default_attributes>
                                                                      
  if ( !the_attr->is_initialized )                                    
40007534:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40007538:	80 a0 60 00 	cmp  %g1, 0                                    
4000753c:	22 80 00 8b 	be,a   40007768 <pthread_create+0x258>         
40007540:	ba 10 20 16 	mov  0x16, %i5                                 
   *  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) )
40007544:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
40007548:	80 a0 60 00 	cmp  %g1, 0                                    
4000754c:	02 80 00 07 	be  40007568 <pthread_create+0x58>             
40007550:	03 10 00 7c 	sethi  %hi(0x4001f000), %g1                    
40007554:	c4 06 60 08 	ld  [ %i1 + 8 ], %g2                           
40007558:	c2 00 61 18 	ld  [ %g1 + 0x118 ], %g1                       
4000755c:	80 a0 80 01 	cmp  %g2, %g1                                  
40007560:	2a 80 00 82 	bcs,a   40007768 <pthread_create+0x258>        
40007564:	ba 10 20 16 	mov  0x16, %i5                                 
   *  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 ) {                                 
40007568:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000756c:	80 a0 60 01 	cmp  %g1, 1                                    
40007570:	02 80 00 09 	be  40007594 <pthread_create+0x84>             
40007574:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
40007578:	80 a0 60 02 	cmp  %g1, 2                                    
4000757c:	12 80 00 7b 	bne  40007768 <pthread_create+0x258>           
40007580:	ba 10 20 16 	mov  0x16, %i5                                 
      schedpolicy = api->schedpolicy;                                 
      schedparam  = api->schedparam;                                  
      break;                                                          
                                                                      
    case PTHREAD_EXPLICIT_SCHED:                                      
      schedpolicy = the_attr->schedpolicy;                            
40007584:	e2 06 60 14 	ld  [ %i1 + 0x14 ], %l1                        
      schedparam  = the_attr->schedparam;                             
40007588:	90 07 bf e4 	add  %fp, -28, %o0                             
4000758c:	10 80 00 06 	b  400075a4 <pthread_create+0x94>              
40007590:	92 06 60 18 	add  %i1, 0x18, %o1                            
   *  PTHREAD_EXPLICIT_SCHED, then scheduling parameters come from the
   *  attributes structure.                                           
   */                                                                 
  switch ( the_attr->inheritsched ) {                                 
    case PTHREAD_INHERIT_SCHED:                                       
      api = executing->API_Extensions[ THREAD_API_POSIX ];            
40007594:	d2 00 a1 30 	ld  [ %g2 + 0x130 ], %o1                       
      schedpolicy = api->schedpolicy;                                 
      schedparam  = api->schedparam;                                  
40007598:	90 07 bf e4 	add  %fp, -28, %o0                             
   *  attributes structure.                                           
   */                                                                 
  switch ( the_attr->inheritsched ) {                                 
    case PTHREAD_INHERIT_SCHED:                                       
      api = executing->API_Extensions[ THREAD_API_POSIX ];            
      schedpolicy = api->schedpolicy;                                 
4000759c:	e2 02 60 90 	ld  [ %o1 + 0x90 ], %l1                        
      schedparam  = api->schedparam;                                  
400075a0:	92 02 60 94 	add  %o1, 0x94, %o1                            
      break;                                                          
                                                                      
    case PTHREAD_EXPLICIT_SCHED:                                      
      schedpolicy = the_attr->schedpolicy;                            
      schedparam  = the_attr->schedparam;                             
400075a4:	40 00 24 02 	call  400105ac <memcpy>                        
400075a8:	94 10 20 1c 	mov  0x1c, %o2                                 
                                                                      
  /*                                                                  
   *  Check the contentionscope since rtems only supports PROCESS wide
   *  contention (i.e. no system wide contention).                    
   */                                                                 
  if ( the_attr->contentionscope != PTHREAD_SCOPE_PROCESS )           
400075ac:	fa 06 60 0c 	ld  [ %i1 + 0xc ], %i5                         
400075b0:	80 a7 60 00 	cmp  %i5, 0                                    
400075b4:	32 80 00 6d 	bne,a   40007768 <pthread_create+0x258>        
400075b8:	ba 10 20 86 	mov  0x86, %i5                                 
    return ENOTSUP;                                                   
                                                                      
  /*                                                                  
   *  Interpret the scheduling parameters.                            
   */                                                                 
  if ( !_POSIX_Priority_Is_valid( schedparam.sched_priority ) )       
400075bc:	40 00 18 dc 	call  4000d92c <_POSIX_Priority_Is_valid>      
400075c0:	d0 07 bf e4 	ld  [ %fp + -28 ], %o0                         
400075c4:	80 a2 20 00 	cmp  %o0, 0                                    
400075c8:	22 80 00 68 	be,a   40007768 <pthread_create+0x258>         <== NEVER TAKEN
400075cc:	ba 10 20 16 	mov  0x16, %i5                                 <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(        
  int priority                                                        
)                                                                     
{                                                                     
  return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
400075d0:	03 10 00 7c 	sethi  %hi(0x4001f000), %g1                    
    return EINVAL;                                                    
                                                                      
  core_priority = _POSIX_Priority_To_core( schedparam.sched_priority );
400075d4:	e8 07 bf e4 	ld  [ %fp + -28 ], %l4                         
400075d8:	ea 08 61 14 	ldub  [ %g1 + 0x114 ], %l5                     
                                                                      
  /*                                                                  
   *  Set the core scheduling policy information.                     
   */                                                                 
  rc = _POSIX_Thread_Translate_sched_param(                           
400075dc:	90 10 00 11 	mov  %l1, %o0                                  
400075e0:	92 07 bf e4 	add  %fp, -28, %o1                             
400075e4:	94 07 bf dc 	add  %fp, -36, %o2                             
400075e8:	40 00 18 dc 	call  4000d958 <_POSIX_Thread_Translate_sched_param>
400075ec:	96 07 bf e0 	add  %fp, -32, %o3                             
    schedpolicy,                                                      
    &schedparam,                                                      
    &budget_algorithm,                                                
    &budget_callout                                                   
  );                                                                  
  if ( rc )                                                           
400075f0:	80 a2 20 00 	cmp  %o0, 0                                    
400075f4:	32 80 00 5d 	bne,a   40007768 <pthread_create+0x258>        
400075f8:	ba 10 00 08 	mov  %o0, %i5                                  
 */                                                                   
SCORE_EXTERN API_Mutex_Control *_RTEMS_Allocator_Mutex;               
                                                                      
static inline void _RTEMS_Lock_allocator( void )                      
{                                                                     
  _API_Mutex_Lock( _RTEMS_Allocator_Mutex );                          
400075fc:	39 10 00 82 	sethi  %hi(0x40020800), %i4                    
40007600:	d0 07 22 f8 	ld  [ %i4 + 0x2f8 ], %o0	! 40020af8 <_RTEMS_Allocator_Mutex>
40007604:	40 00 05 74 	call  40008bd4 <_API_Mutex_Lock>               
40007608:	27 10 00 83 	sethi  %hi(0x40020c00), %l3                    
                                                                      
RTEMS_INLINE_ROUTINE Thread_Control *_POSIX_Threads_Allocate(void)    
{                                                                     
  _Objects_Allocator_lock();                                          
                                                                      
  _Thread_Kill_zombies();                                             
4000760c:	40 00 0f b0 	call  4000b4cc <_Thread_Kill_zombies>          
40007610:	a4 10 00 1c 	mov  %i4, %l2                                  
                                                                      
  return (Thread_Control *)                                           
40007614:	40 00 08 40 	call  40009714 <_Objects_Allocate_unprotected> 
40007618:	90 14 e0 50 	or  %l3, 0x50, %o0                             
   *  Allocate the thread control block.                              
   *                                                                  
   *  NOTE:  Global threads are not currently supported.              
   */                                                                 
  the_thread = _POSIX_Threads_Allocate();                             
  if ( !the_thread ) {                                                
4000761c:	a0 92 20 00 	orcc  %o0, 0, %l0                              
40007620:	12 80 00 04 	bne  40007630 <pthread_create+0x120>           
40007624:	90 10 00 13 	mov  %l3, %o0                                  
}                                                                     
                                                                      
static inline void _RTEMS_Unlock_allocator( void )                    
{                                                                     
  _API_Mutex_Unlock( _RTEMS_Allocator_Mutex );                        
40007628:	10 80 00 24 	b  400076b8 <pthread_create+0x1a8>             
4000762c:	d0 07 22 f8 	ld  [ %i4 + 0x2f8 ], %o0                       
 *                                                                    
 * @return This method returns the minimum stack size;                
 */                                                                   
RTEMS_INLINE_ROUTINE uint32_t _Stack_Minimum (void)                   
{                                                                     
  return rtems_minimum_stack_size;                                    
40007630:	03 10 00 7c 	sethi  %hi(0x4001f000), %g1                    
                                                                      
static inline size_t _POSIX_Threads_Ensure_minimum_stack (            
  size_t size                                                         
)                                                                     
{                                                                     
  if ( size >= PTHREAD_MINIMUM_STACK_SIZE )                           
40007634:	d8 00 61 18 	ld  [ %g1 + 0x118 ], %o4	! 4001f118 <rtems_minimum_stack_size>
40007638:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
                                                                      
  /*                                                                  
   *  Initialize the core thread for this task.                       
   */                                                                 
  name.name_p = NULL;   /* posix threads don't have a name by default */
  status = _Thread_Initialize(                                        
4000763c:	c0 27 bf d4 	clr  [ %fp + -44 ]                             
40007640:	99 2b 20 01 	sll  %o4, 1, %o4                               
40007644:	80 a3 00 01 	cmp  %o4, %g1                                  
40007648:	1a 80 00 03 	bcc  40007654 <pthread_create+0x144>           
4000764c:	d6 06 60 04 	ld  [ %i1 + 4 ], %o3                           
40007650:	98 10 00 01 	mov  %g1, %o4                                  
40007654:	82 10 20 01 	mov  1, %g1                                    
40007658:	c2 23 a0 60 	st  %g1, [ %sp + 0x60 ]                        
4000765c:	c2 07 bf dc 	ld  [ %fp + -36 ], %g1                         
40007660:	aa 0d 60 ff 	and  %l5, 0xff, %l5                            
40007664:	c2 23 a0 64 	st  %g1, [ %sp + 0x64 ]                        
40007668:	c2 07 bf e0 	ld  [ %fp + -32 ], %g1                         
4000766c:	a8 25 40 14 	sub  %l5, %l4, %l4                             
40007670:	c2 23 a0 68 	st  %g1, [ %sp + 0x68 ]                        
40007674:	82 07 bf d4 	add  %fp, -44, %g1                             
40007678:	e8 23 a0 5c 	st  %l4, [ %sp + 0x5c ]                        
4000767c:	c0 23 a0 6c 	clr  [ %sp + 0x6c ]                            
40007680:	c2 23 a0 70 	st  %g1, [ %sp + 0x70 ]                        
40007684:	90 12 20 50 	or  %o0, 0x50, %o0                             
40007688:	92 10 00 10 	mov  %l0, %o1                                  
4000768c:	15 10 00 77 	sethi  %hi(0x4001dc00), %o2                    
40007690:	9a 10 20 00 	clr  %o5                                       
40007694:	40 00 0d 03 	call  4000aaa0 <_Thread_Initialize>            
40007698:	94 12 a1 5c 	or  %o2, 0x15c, %o2                            
    budget_algorithm,                                                 
    budget_callout,                                                   
    0,                    /* isr level */                             
    name                  /* posix threads don't have a name */       
  );                                                                  
  if ( !status ) {                                                    
4000769c:	80 a2 20 00 	cmp  %o0, 0                                    
400076a0:	12 80 00 0a 	bne  400076c8 <pthread_create+0x1b8>           
400076a4:	11 10 00 83 	sethi  %hi(0x40020c00), %o0                    
                                                                      
RTEMS_INLINE_ROUTINE void _POSIX_Threads_Free (                       
  Thread_Control *the_pthread                                         
)                                                                     
{                                                                     
  _Objects_Free( &_POSIX_Threads_Information, &the_pthread->Object ); 
400076a8:	92 10 00 10 	mov  %l0, %o1                                  
400076ac:	40 00 09 15 	call  40009b00 <_Objects_Free>                 
400076b0:	90 12 20 50 	or  %o0, 0x50, %o0                             
400076b4:	d0 04 a2 f8 	ld  [ %l2 + 0x2f8 ], %o0                       
400076b8:	40 00 05 7e 	call  40008cb0 <_API_Mutex_Unlock>             
400076bc:	ba 10 20 0b 	mov  0xb, %i5                                  
   */                                                                 
  *thread = the_thread->Object.id;                                    
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
400076c0:	81 c7 e0 08 	ret                                            
400076c4:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
#endif                                                                
                                                                      
  /*                                                                  
   *  finish initializing the per API structure                       
   */                                                                 
  api = the_thread->API_Extensions[ THREAD_API_POSIX ];               
400076c8:	f8 04 21 30 	ld  [ %l0 + 0x130 ], %i4                       
RTEMS_INLINE_ROUTINE void _POSIX_Threads_Copy_attributes(             
  pthread_attr_t        *dst_attr,                                    
  const pthread_attr_t  *src_attr                                     
)                                                                     
{                                                                     
  *dst_attr = *src_attr;                                              
400076cc:	92 10 00 19 	mov  %i1, %o1                                  
400076d0:	90 10 00 1c 	mov  %i4, %o0                                  
400076d4:	40 00 23 b6 	call  400105ac <memcpy>                        
400076d8:	94 10 20 4c 	mov  0x4c, %o2                                 
                                                                      
  _POSIX_Threads_Copy_attributes( &api->Attributes, the_attr );       
  api->detachstate = the_attr->detachstate;                           
400076dc:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
  api->schedpolicy = schedpolicy;                                     
  api->schedparam  = schedparam;                                      
400076e0:	90 07 20 94 	add  %i4, 0x94, %o0                            
   *  finish initializing the per API structure                       
   */                                                                 
  api = the_thread->API_Extensions[ THREAD_API_POSIX ];               
                                                                      
  _POSIX_Threads_Copy_attributes( &api->Attributes, the_attr );       
  api->detachstate = the_attr->detachstate;                           
400076e4:	c2 27 20 4c 	st  %g1, [ %i4 + 0x4c ]                        
  api->schedpolicy = schedpolicy;                                     
400076e8:	e2 27 20 90 	st  %l1, [ %i4 + 0x90 ]                        
  api->schedparam  = schedparam;                                      
400076ec:	92 07 bf e4 	add  %fp, -28, %o1                             
400076f0:	40 00 23 af 	call  400105ac <memcpy>                        
400076f4:	94 10 20 1c 	mov  0x1c, %o2                                 
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
400076f8:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
400076fc:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40007700:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
  _Thread_Disable_dispatch();                                         
                                                                      
  /*                                                                  
   *  POSIX threads are allocated and started in one operation.       
   */                                                                 
  status = _Thread_Start(                                             
40007704:	92 10 20 01 	mov  1, %o1                                    
40007708:	90 10 00 10 	mov  %l0, %o0                                  
4000770c:	94 10 00 1a 	mov  %i2, %o2                                  
40007710:	96 10 00 1b 	mov  %i3, %o3                                  
40007714:	98 10 20 00 	clr  %o4                                       
40007718:	40 00 10 3d 	call  4000b80c <_Thread_Start>                 
4000771c:	9a 10 20 00 	clr  %o5                                       
      _Objects_Allocator_unlock();                                    
      return EINVAL;                                                  
    }                                                                 
  #endif                                                              
                                                                      
  if ( schedpolicy == SCHED_SPORADIC ) {                              
40007720:	80 a4 60 04 	cmp  %l1, 4                                    
40007724:	12 80 00 09 	bne  40007748 <pthread_create+0x238>           
40007728:	01 00 00 00 	nop                                            
    _Watchdog_Insert_ticks(                                           
4000772c:	40 00 10 7b 	call  4000b918 <_Timespec_To_ticks>            
40007730:	90 07 20 9c 	add  %i4, 0x9c, %o0                            
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
40007734:	92 07 20 b4 	add  %i4, 0xb4, %o1                            
  Watchdog_Control      *the_watchdog,                                
  Watchdog_Interval      units                                        
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
40007738:	d0 27 20 c0 	st  %o0, [ %i4 + 0xc0 ]                        
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
4000773c:	11 10 00 82 	sethi  %hi(0x40020800), %o0                    
40007740:	40 00 11 3e 	call  4000bc38 <_Watchdog_Insert>              
40007744:	90 12 23 10 	or  %o0, 0x310, %o0	! 40020b10 <_Watchdog_Ticks_chain>
      &api->Sporadic_timer,                                           
      _Timespec_To_ticks( &api->schedparam.sched_ss_repl_period )     
    );                                                                
  }                                                                   
                                                                      
  _Thread_Enable_dispatch();                                          
40007748:	40 00 0c a7 	call  4000a9e4 <_Thread_Enable_dispatch>       
4000774c:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   *  Return the id and indicate we successfully created the thread   
   */                                                                 
  *thread = the_thread->Object.id;                                    
40007750:	c2 04 20 08 	ld  [ %l0 + 8 ], %g1                           
40007754:	d0 04 a2 f8 	ld  [ %l2 + 0x2f8 ], %o0                       
40007758:	40 00 05 56 	call  40008cb0 <_API_Mutex_Unlock>             
4000775c:	c2 26 00 00 	st  %g1, [ %i0 ]                               
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40007760:	81 c7 e0 08 	ret                                            
40007764:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
40007768:	b0 10 00 1d 	mov  %i5, %i0                                  
4000776c:	81 c7 e0 08 	ret                                            
40007770:	81 e8 00 00 	restore                                        
                                                                      

400299c8 <pthread_kill>: int pthread_kill( pthread_t thread, int sig ) {
400299c8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  POSIX_API_Control  *api;                                            
  Thread_Control     *the_thread;                                     
  Objects_Locations  location;                                        
                                                                      
  if ( !sig )                                                         
400299cc:	80 a6 60 00 	cmp  %i1, 0                                    
400299d0:	12 80 00 06 	bne  400299e8 <pthread_kill+0x20>              
400299d4:	ba 06 7f ff 	add  %i1, -1, %i5                              
    rtems_set_errno_and_return_minus_one( EINVAL );                   
400299d8:	7f ff b8 2d 	call  40017a8c <__errno>                       
400299dc:	01 00 00 00 	nop                                            
400299e0:	10 80 00 24 	b  40029a70 <pthread_kill+0xa8>                
400299e4:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
                                                                      
  if ( !is_valid_signo(sig) )                                         
400299e8:	80 a7 60 1f 	cmp  %i5, 0x1f                                 
400299ec:	18 bf ff fb 	bgu  400299d8 <pthread_kill+0x10>              
400299f0:	01 00 00 00 	nop                                            
    rtems_set_errno_and_return_minus_one( EINVAL );                   
                                                                      
  the_thread = _Thread_Get( thread, &location );                      
400299f4:	90 10 00 18 	mov  %i0, %o0                                  
400299f8:	7f ff 91 fc 	call  4000e1e8 <_Thread_Get>                   
400299fc:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
40029a00:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
40029a04:	80 a0 a0 00 	cmp  %g2, 0                                    
40029a08:	12 80 00 17 	bne  40029a64 <pthread_kill+0x9c>              <== NEVER TAKEN
40029a0c:	87 2e 60 02 	sll  %i1, 2, %g3                               
                                                                      
      api = the_thread->API_Extensions[ THREAD_API_POSIX ];           
                                                                      
      if ( sig ) {                                                    
                                                                      
        if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN ) {  
40029a10:	89 2e 60 04 	sll  %i1, 4, %g4                               
40029a14:	05 10 00 c3 	sethi  %hi(0x40030c00), %g2                    
40029a18:	86 21 00 03 	sub  %g4, %g3, %g3                             
40029a1c:	84 10 a0 cc 	or  %g2, 0xcc, %g2                             
40029a20:	84 00 80 03 	add  %g2, %g3, %g2                             
40029a24:	c4 00 a0 08 	ld  [ %g2 + 8 ], %g2                           
40029a28:	80 a0 a0 01 	cmp  %g2, 1                                    
40029a2c:	02 80 00 0a 	be  40029a54 <pthread_kill+0x8c>               
40029a30:	c2 02 21 30 	ld  [ %o0 + 0x130 ], %g1                       
40029a34:	84 10 20 01 	mov  1, %g2                                    
40029a38:	bb 28 80 1d 	sll  %g2, %i5, %i5                             
          return 0;                                                   
        }                                                             
                                                                      
        /* XXX critical section */                                    
                                                                      
        api->signals_pending |= signo_to_mask( sig );                 
40029a3c:	c4 00 60 e0 	ld  [ %g1 + 0xe0 ], %g2                        
                                                                      
        (void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
40029a40:	92 10 00 19 	mov  %i1, %o1                                  
          return 0;                                                   
        }                                                             
                                                                      
        /* XXX critical section */                                    
                                                                      
        api->signals_pending |= signo_to_mask( sig );                 
40029a44:	ba 10 80 1d 	or  %g2, %i5, %i5                              
                                                                      
        (void) _POSIX_signals_Unblock_thread( the_thread, sig, NULL );
40029a48:	94 10 20 00 	clr  %o2                                       
40029a4c:	7f ff ff 84 	call  4002985c <_POSIX_signals_Unblock_thread> 
40029a50:	fa 20 60 e0 	st  %i5, [ %g1 + 0xe0 ]                        
40029a54:	7f ff 91 da 	call  4000e1bc <_Thread_Enable_dispatch>       
40029a58:	b0 10 20 00 	clr  %i0                                       
      }                                                               
      _Objects_Put( &the_thread->Object );                            
      return 0;                                                       
40029a5c:	81 c7 e0 08 	ret                                            
40029a60:	81 e8 00 00 	restore                                        
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  rtems_set_errno_and_return_minus_one( ESRCH );                      
40029a64:	7f ff b8 0a 	call  40017a8c <__errno>                       <== NOT EXECUTED
40029a68:	01 00 00 00 	nop                                            <== NOT EXECUTED
40029a6c:	82 10 20 03 	mov  3, %g1	! 3 <_TLS_Alignment+0x2>           <== NOT EXECUTED
40029a70:	c2 22 00 00 	st  %g1, [ %o0 ]                               
}                                                                     
40029a74:	81 c7 e0 08 	ret                                            
40029a78:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      

40010e74 <pthread_mutex_init>: int pthread_mutex_init( pthread_mutex_t *mutex, const pthread_mutexattr_t *attr ) {
40010e74:	9d e3 bf a0 	save  %sp, -96, %sp                            
  POSIX_Mutex_Control          *the_mutex;                            
  CORE_mutex_Attributes        *the_mutex_attr;                       
  const pthread_mutexattr_t    *the_attr;                             
  CORE_mutex_Disciplines        the_discipline;                       
                                                                      
  if ( attr ) the_attr = attr;                                        
40010e78:	80 a6 60 00 	cmp  %i1, 0                                    
40010e7c:	12 80 00 04 	bne  40010e8c <pthread_mutex_init+0x18>        
40010e80:	80 a6 20 00 	cmp  %i0, 0                                    
  else        the_attr = &_POSIX_Mutex_Default_attributes;            
40010e84:	33 10 00 72 	sethi  %hi(0x4001c800), %i1                    
40010e88:	b2 16 63 b4 	or  %i1, 0x3b4, %i1	! 4001cbb4 <_POSIX_Mutex_Default_attributes>
                                                                      
  /* Check for NULL mutex */                                          
  if ( !mutex )                                                       
40010e8c:	02 80 00 52 	be  40010fd4 <pthread_mutex_init+0x160>        
40010e90:	b8 10 20 16 	mov  0x16, %i4                                 
      }                                                               
    }                                                                 
  }                                                                   
  #endif                                                              
                                                                      
  if ( !the_attr->is_initialized )                                    
40010e94:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40010e98:	80 a0 60 00 	cmp  %g1, 0                                    
40010e9c:	22 80 00 4f 	be,a   40010fd8 <pthread_mutex_init+0x164>     
40010ea0:	b0 10 00 1c 	mov  %i4, %i0                                  
    return EINVAL;                                                    
                                                                      
  /*                                                                  
   *  We only support process private mutexes.                        
   */                                                                 
  if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )           
40010ea4:	f8 06 60 04 	ld  [ %i1 + 4 ], %i4                           
40010ea8:	80 a7 20 01 	cmp  %i4, 1                                    
40010eac:	02 80 00 47 	be  40010fc8 <pthread_mutex_init+0x154>        
40010eb0:	80 a7 20 00 	cmp  %i4, 0                                    
    return ENOSYS;                                                    
                                                                      
  if ( the_attr->process_shared != PTHREAD_PROCESS_PRIVATE )          
40010eb4:	32 80 00 48 	bne,a   40010fd4 <pthread_mutex_init+0x160>    
40010eb8:	b8 10 20 16 	mov  0x16, %i4                                 
    return EINVAL;                                                    
                                                                      
  /*                                                                  
   *  Determine the discipline of the mutex                           
   */                                                                 
  switch ( the_attr->protocol ) {                                     
40010ebc:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
40010ec0:	80 a0 60 01 	cmp  %g1, 1                                    
40010ec4:	02 80 00 09 	be  40010ee8 <pthread_mutex_init+0x74>         
40010ec8:	80 a0 60 02 	cmp  %g1, 2                                    
40010ecc:	02 80 00 05 	be  40010ee0 <pthread_mutex_init+0x6c>         
40010ed0:	80 a0 60 00 	cmp  %g1, 0                                    
40010ed4:	12 80 00 3f 	bne  40010fd0 <pthread_mutex_init+0x15c>       
40010ed8:	b6 10 20 00 	clr  %i3                                       
40010edc:	30 80 00 04 	b,a   40010eec <pthread_mutex_init+0x78>       
    case PTHREAD_PRIO_INHERIT:                                        
      the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;       
      break;                                                          
    case PTHREAD_PRIO_PROTECT:                                        
      the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING;       
      break;                                                          
40010ee0:	10 80 00 03 	b  40010eec <pthread_mutex_init+0x78>          
40010ee4:	b6 10 20 03 	mov  3, %i3                                    
  switch ( the_attr->protocol ) {                                     
    case PTHREAD_PRIO_NONE:                                           
      the_discipline = CORE_MUTEX_DISCIPLINES_FIFO;                   
      break;                                                          
    case PTHREAD_PRIO_INHERIT:                                        
      the_discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;       
40010ee8:	b6 10 20 02 	mov  2, %i3                                    
  }                                                                   
                                                                      
  /*                                                                  
   *  Validate the priority ceiling field -- should always be valid.  
   */                                                                 
  if ( !_POSIX_Priority_Is_valid( the_attr->prio_ceiling ) )          
40010eec:	40 00 01 20 	call  4001136c <_POSIX_Priority_Is_valid>      
40010ef0:	d0 06 60 08 	ld  [ %i1 + 8 ], %o0                           
40010ef4:	80 a2 20 00 	cmp  %o0, 0                                    
40010ef8:	22 80 00 37 	be,a   40010fd4 <pthread_mutex_init+0x160>     
40010efc:	b8 10 20 16 	mov  0x16, %i4                                 
#if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES)                          
  /*                                                                  
   *  Validate the mutex type and set appropriate SuperCore mutex     
   *  attributes.                                                     
   */                                                                 
  switch ( the_attr->type ) {                                         
40010f00:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
40010f04:	80 a0 60 03 	cmp  %g1, 3                                    
40010f08:	38 80 00 33 	bgu,a   40010fd4 <pthread_mutex_init+0x160>    
40010f0c:	b8 10 20 16 	mov  0x16, %i4                                 
 *  This function allocates a mutexes control block from              
 *  the inactive chain of free mutexes control blocks.                
 */                                                                   
RTEMS_INLINE_ROUTINE POSIX_Mutex_Control *_POSIX_Mutex_Allocate( void )
{                                                                     
  return (POSIX_Mutex_Control *) _Objects_Allocate( &_POSIX_Mutex_Information );
40010f10:	35 10 00 72 	sethi  %hi(0x4001c800), %i2                    
40010f14:	90 16 a3 3c 	or  %i2, 0x33c, %o0	! 4001cb3c <_POSIX_Mutex_Information>
40010f18:	7f ff e4 91 	call  4000a15c <_Objects_Allocate>             
40010f1c:	a0 10 00 1a 	mov  %i2, %l0                                  
  }                                                                   
#endif                                                                
                                                                      
  the_mutex = _POSIX_Mutex_Allocate();                                
                                                                      
  if ( !the_mutex ) {                                                 
40010f20:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40010f24:	12 80 00 07 	bne  40010f40 <pthread_mutex_init+0xcc>        
40010f28:	35 10 00 72 	sethi  %hi(0x4001c800), %i2                    
40010f2c:	d0 06 a0 b8 	ld  [ %i2 + 0xb8 ], %o0	! 4001c8b8 <_RTEMS_Allocator_Mutex>
40010f30:	7f ff e1 e5 	call  400096c4 <_API_Mutex_Unlock>             
40010f34:	b8 10 20 0b 	mov  0xb, %i4                                  
                                                                      
  *mutex = the_mutex->Object.id;                                      
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40010f38:	81 c7 e0 08 	ret                                            
40010f3c:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
  if ( !the_mutex ) {                                                 
    _Objects_Allocator_unlock();                                      
    return EAGAIN;                                                    
  }                                                                   
                                                                      
  the_mutex->process_shared = the_attr->process_shared;               
40010f40:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
40010f44:	c2 27 60 10 	st  %g1, [ %i5 + 0x10 ]                        
                                                                      
  the_mutex_attr = &the_mutex->Mutex.Attributes;                      
                                                                      
  if ( the_attr->type == PTHREAD_MUTEX_RECURSIVE )                    
40010f48:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
40010f4c:	80 a0 60 01 	cmp  %g1, 1                                    
40010f50:	12 80 00 04 	bne  40010f60 <pthread_mutex_init+0xec>        <== ALWAYS TAKEN
40010f54:	94 07 60 54 	add  %i5, 0x54, %o2                            
40010f58:	10 80 00 04 	b  40010f68 <pthread_mutex_init+0xf4>          <== NOT EXECUTED
40010f5c:	c0 27 60 54 	clr  [ %i5 + 0x54 ]                            <== NOT EXECUTED
    the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
  else                                                                
    the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
40010f60:	82 10 20 01 	mov  1, %g1                                    
40010f64:	c2 27 60 54 	st  %g1, [ %i5 + 0x54 ]                        
  the_mutex_attr->only_owner_release = true;                          
40010f68:	82 10 20 01 	mov  1, %g1                                    
40010f6c:	c2 2f 60 58 	stb  %g1, [ %i5 + 0x58 ]                       
 */                                                                   
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core(        
  int priority                                                        
)                                                                     
{                                                                     
  return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
40010f70:	03 10 00 6b 	sethi  %hi(0x4001ac00), %g1                    
40010f74:	c4 08 63 a4 	ldub  [ %g1 + 0x3a4 ], %g2	! 4001afa4 <rtems_maximum_priority>
40010f78:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
  the_mutex_attr->discipline = the_discipline;                        
                                                                      
  /*                                                                  
   *  Must be initialized to unlocked.                                
   */                                                                 
  _CORE_mutex_Initialize( &the_mutex->Mutex, NULL, the_mutex_attr, false );
40010f7c:	90 07 60 14 	add  %i5, 0x14, %o0                            
40010f80:	82 20 80 01 	sub  %g2, %g1, %g1                             
  else                                                                
    the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
  the_mutex_attr->only_owner_release = true;                          
  the_mutex_attr->priority_ceiling =                                  
    _POSIX_Priority_To_core( the_attr->prio_ceiling );                
  the_mutex_attr->discipline = the_discipline;                        
40010f84:	f6 27 60 5c 	st  %i3, [ %i5 + 0x5c ]                        
  if ( the_attr->type == PTHREAD_MUTEX_RECURSIVE )                    
    the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES;
  else                                                                
    the_mutex_attr->lock_nesting_behavior = CORE_MUTEX_NESTING_IS_ERROR;
  the_mutex_attr->only_owner_release = true;                          
  the_mutex_attr->priority_ceiling =                                  
40010f88:	c2 27 60 60 	st  %g1, [ %i5 + 0x60 ]                        
  the_mutex_attr->discipline = the_discipline;                        
                                                                      
  /*                                                                  
   *  Must be initialized to unlocked.                                
   */                                                                 
  _CORE_mutex_Initialize( &the_mutex->Mutex, NULL, the_mutex_attr, false );
40010f8c:	92 10 20 00 	clr  %o1                                       
40010f90:	7f ff e2 0c 	call  400097c0 <_CORE_mutex_Initialize>        
40010f94:	96 10 20 00 	clr  %o3                                       
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
40010f98:	c4 17 60 0a 	lduh  [ %i5 + 0xa ], %g2                       
  Objects_Control     *the_object,                                    
  uint32_t             name                                           
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
40010f9c:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open_u32(                          
  Objects_Information *information,                                   
40010fa0:	a0 14 23 3c 	or  %l0, 0x33c, %l0                            
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40010fa4:	c6 04 20 1c 	ld  [ %l0 + 0x1c ], %g3                        
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
40010fa8:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40010fac:	85 28 a0 02 	sll  %g2, 2, %g2                               
40010fb0:	fa 20 c0 02 	st  %i5, [ %g3 + %g2 ]                         
40010fb4:	d0 06 a0 b8 	ld  [ %i2 + 0xb8 ], %o0                        
40010fb8:	7f ff e1 c3 	call  400096c4 <_API_Mutex_Unlock>             
40010fbc:	c2 26 00 00 	st  %g1, [ %i0 ]                               
                                                                      
  *mutex = the_mutex->Object.id;                                      
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40010fc0:	81 c7 e0 08 	ret                                            
40010fc4:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
                                                                      
  /*                                                                  
   *  We only support process private mutexes.                        
   */                                                                 
  if ( the_attr->process_shared == PTHREAD_PROCESS_SHARED )           
    return ENOSYS;                                                    
40010fc8:	10 80 00 03 	b  40010fd4 <pthread_mutex_init+0x160>         
40010fcc:	b8 10 20 58 	mov  0x58, %i4                                 
    case PTHREAD_MUTEX_ERRORCHECK:                                    
    case PTHREAD_MUTEX_DEFAULT:                                       
      break;                                                          
                                                                      
    default:                                                          
      return EINVAL;                                                  
40010fd0:	b8 10 20 16 	mov  0x16, %i4                                 
                                                                      
  *mutex = the_mutex->Object.id;                                      
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40010fd4:	b0 10 00 1c 	mov  %i4, %i0                                  
40010fd8:	81 c7 e0 08 	ret                                            
40010fdc:	81 e8 00 00 	restore                                        
                                                                      

40009ddc <pthread_mutex_timedlock>: */ int pthread_mutex_timedlock( pthread_mutex_t *mutex, const struct timespec *abstime ) {
40009ddc:	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 );       
40009de0:	92 07 bf fc 	add  %fp, -4, %o1                              
40009de4:	40 00 00 35 	call  40009eb8 <_POSIX_Absolute_timeout_to_ticks>
40009de8:	90 10 00 19 	mov  %i1, %o0                                  
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
    do_wait = false;                                                  
                                                                      
  lock_status = _POSIX_Mutex_Lock_support( mutex, do_wait, ticks );   
40009dec:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
   *  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 );       
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
40009df0:	82 1a 20 03 	xor  %o0, 3, %g1                               
40009df4:	80 a0 00 01 	cmp  %g0, %g1                                  
   *                                                                  
   *  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 );       
40009df8:	ba 10 00 08 	mov  %o0, %i5                                  
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
40009dfc:	b8 60 3f ff 	subx  %g0, -1, %i4                             
    do_wait = false;                                                  
                                                                      
  lock_status = _POSIX_Mutex_Lock_support( mutex, do_wait, ticks );   
40009e00:	90 10 00 18 	mov  %i0, %o0                                  
40009e04:	7f ff ff b7 	call  40009ce0 <_POSIX_Mutex_Lock_support>     
40009e08:	92 10 00 1c 	mov  %i4, %o1                                  
   *  This service only gives us the option to block.  We used a polling
   *  attempt to lock if the abstime was not in the future.  If we did
   *  not obtain the mutex, then not look at the status immediately,  
   *  make sure the right reason is returned.                         
   */                                                                 
  if ( !do_wait && (lock_status == EBUSY) ) {                         
40009e0c:	80 a7 20 00 	cmp  %i4, 0                                    
40009e10:	32 80 00 0d 	bne,a   40009e44 <pthread_mutex_timedlock+0x68>
40009e14:	b0 10 00 08 	mov  %o0, %i0                                  
40009e18:	80 a2 20 10 	cmp  %o0, 0x10                                 
40009e1c:	32 80 00 0a 	bne,a   40009e44 <pthread_mutex_timedlock+0x68>
40009e20:	b0 10 00 08 	mov  %o0, %i0                                  
    if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )                   
40009e24:	80 a7 60 00 	cmp  %i5, 0                                    
40009e28:	02 80 00 07 	be  40009e44 <pthread_mutex_timedlock+0x68>    <== NEVER TAKEN
40009e2c:	b0 10 20 16 	mov  0x16, %i0                                 
      return EINVAL;                                                  
    if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||               
40009e30:	ba 07 7f ff 	add  %i5, -1, %i5                              
40009e34:	80 a7 60 01 	cmp  %i5, 1                                    
40009e38:	18 80 00 03 	bgu  40009e44 <pthread_mutex_timedlock+0x68>   <== NEVER TAKEN
40009e3c:	b0 10 20 10 	mov  0x10, %i0                                 
40009e40:	b0 10 20 74 	mov  0x74, %i0                                 
         status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )                    
      return ETIMEDOUT;                                               
  }                                                                   
                                                                      
  return lock_status;                                                 
}                                                                     
40009e44:	81 c7 e0 08 	ret                                            
40009e48:	81 e8 00 00 	restore                                        
                                                                      

40006e60 <pthread_mutexattr_gettype>: #if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES) int pthread_mutexattr_gettype( const pthread_mutexattr_t *attr, int *type ) {
40006e60:	82 10 00 08 	mov  %o0, %g1                                  
  if ( !attr )                                                        
40006e64:	80 a0 60 00 	cmp  %g1, 0                                    
40006e68:	02 80 00 0b 	be  40006e94 <pthread_mutexattr_gettype+0x34>  
40006e6c:	90 10 20 16 	mov  0x16, %o0                                 
    return EINVAL;                                                    
                                                                      
  if ( !attr->is_initialized )                                        
40006e70:	c4 00 40 00 	ld  [ %g1 ], %g2                               
40006e74:	80 a0 a0 00 	cmp  %g2, 0                                    
40006e78:	02 80 00 07 	be  40006e94 <pthread_mutexattr_gettype+0x34>  
40006e7c:	80 a2 60 00 	cmp  %o1, 0                                    
    return EINVAL;                                                    
                                                                      
  if ( !type )                                                        
40006e80:	02 80 00 05 	be  40006e94 <pthread_mutexattr_gettype+0x34>  <== NEVER TAKEN
40006e84:	01 00 00 00 	nop                                            
    return EINVAL;                                                    
                                                                      
  *type = attr->type;                                                 
40006e88:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
  return 0;                                                           
40006e8c:	90 10 20 00 	clr  %o0                                       
    return EINVAL;                                                    
                                                                      
  if ( !type )                                                        
    return EINVAL;                                                    
                                                                      
  *type = attr->type;                                                 
40006e90:	c2 22 40 00 	st  %g1, [ %o1 ]                               
  return 0;                                                           
}                                                                     
40006e94:	81 c3 e0 08 	retl                                           
                                                                      

4000997c <pthread_mutexattr_setpshared>: int pthread_mutexattr_setpshared( pthread_mutexattr_t *attr, int pshared ) {
4000997c:	82 10 00 08 	mov  %o0, %g1                                  
  if ( !attr || !attr->is_initialized )                               
40009980:	80 a0 60 00 	cmp  %g1, 0                                    
40009984:	02 80 00 0a 	be  400099ac <pthread_mutexattr_setpshared+0x30>
40009988:	90 10 20 16 	mov  0x16, %o0                                 
4000998c:	c4 00 40 00 	ld  [ %g1 ], %g2                               
40009990:	80 a0 a0 00 	cmp  %g2, 0                                    
40009994:	02 80 00 06 	be  400099ac <pthread_mutexattr_setpshared+0x30>
40009998:	80 a2 60 01 	cmp  %o1, 1                                    
    return EINVAL;                                                    
                                                                      
  switch ( pshared ) {                                                
4000999c:	18 80 00 04 	bgu  400099ac <pthread_mutexattr_setpshared+0x30><== NEVER TAKEN
400099a0:	01 00 00 00 	nop                                            
    case PTHREAD_PROCESS_SHARED:                                      
    case PTHREAD_PROCESS_PRIVATE:                                     
      attr->process_shared = pshared;                                 
400099a4:	d2 20 60 04 	st  %o1, [ %g1 + 4 ]                           
      return 0;                                                       
400099a8:	90 10 20 00 	clr  %o0                                       
                                                                      
    default:                                                          
      return EINVAL;                                                  
  }                                                                   
}                                                                     
400099ac:	81 c3 e0 08 	retl                                           
                                                                      

40006ecc <pthread_mutexattr_settype>: #if defined(_UNIX98_THREAD_MUTEX_ATTRIBUTES) int pthread_mutexattr_settype( pthread_mutexattr_t *attr, int type ) {
40006ecc:	82 10 00 08 	mov  %o0, %g1                                  
  if ( !attr || !attr->is_initialized )                               
40006ed0:	80 a0 60 00 	cmp  %g1, 0                                    
40006ed4:	02 80 00 0a 	be  40006efc <pthread_mutexattr_settype+0x30>  
40006ed8:	90 10 20 16 	mov  0x16, %o0                                 
40006edc:	c4 00 40 00 	ld  [ %g1 ], %g2                               
40006ee0:	80 a0 a0 00 	cmp  %g2, 0                                    
40006ee4:	02 80 00 06 	be  40006efc <pthread_mutexattr_settype+0x30>  <== NEVER TAKEN
40006ee8:	80 a2 60 03 	cmp  %o1, 3                                    
    return EINVAL;                                                    
                                                                      
  switch ( type ) {                                                   
40006eec:	18 80 00 04 	bgu  40006efc <pthread_mutexattr_settype+0x30> 
40006ef0:	01 00 00 00 	nop                                            
    case PTHREAD_MUTEX_NORMAL:                                        
    case PTHREAD_MUTEX_RECURSIVE:                                     
    case PTHREAD_MUTEX_ERRORCHECK:                                    
    case PTHREAD_MUTEX_DEFAULT:                                       
      attr->type = type;                                              
40006ef4:	d2 20 60 10 	st  %o1, [ %g1 + 0x10 ]                        
      return 0;                                                       
40006ef8:	90 10 20 00 	clr  %o0                                       
                                                                      
    default:                                                          
      return EINVAL;                                                  
  }                                                                   
}                                                                     
40006efc:	81 c3 e0 08 	retl                                           
                                                                      

400115f0 <pthread_once>: int pthread_once( pthread_once_t *once_control, void (*init_routine)(void) ) { if ( !once_control || !init_routine )
400115f0:	80 a2 20 00 	cmp  %o0, 0                                    
400115f4:	02 80 00 0c 	be  40011624 <pthread_once+0x34>               
400115f8:	80 a2 60 00 	cmp  %o1, 0                                    
400115fc:	02 80 00 0a 	be  40011624 <pthread_once+0x34>               
40011600:	01 00 00 00 	nop                                            
    return EINVAL;                                                    
                                                                      
  if ( once_control->is_initialized != 1 )                            
40011604:	c2 02 00 00 	ld  [ %o0 ], %g1                               
40011608:	80 a0 60 01 	cmp  %g1, 1                                    
4001160c:	12 80 00 06 	bne  40011624 <pthread_once+0x34>              <== NEVER TAKEN
40011610:	01 00 00 00 	nop                                            
    return EINVAL;                                                    
                                                                      
  return _Once( &once_control->init_executed, init_routine );         
40011614:	90 02 20 04 	add  %o0, 4, %o0                               
40011618:	82 13 c0 00 	mov  %o7, %g1                                  
4001161c:	40 00 03 0b 	call  40012248 <_Once>                         
40011620:	9e 10 40 00 	mov  %g1, %o7                                  
}                                                                     
40011624:	81 c3 e0 08 	retl                                           
40011628:	90 10 20 16 	mov  0x16, %o0                                 
                                                                      

40008448 <pthread_rwlock_init>: int pthread_rwlock_init( pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr ) {
40008448:	9d e3 bf 90 	save  %sp, -112, %sp                           
  const pthread_rwlockattr_t  *the_attr;                              
                                                                      
  /*                                                                  
   *  Error check parameters                                          
   */                                                                 
  if ( !rwlock )                                                      
4000844c:	80 a6 20 00 	cmp  %i0, 0                                    
40008450:	02 80 00 2a 	be  400084f8 <pthread_rwlock_init+0xb0>        
40008454:	80 a6 60 00 	cmp  %i1, 0                                    
    return EINVAL;                                                    
                                                                      
  /*                                                                  
   * If the user passed in NULL, use the default attributes           
   */                                                                 
  if ( attr ) {                                                       
40008458:	32 80 00 06 	bne,a   40008470 <pthread_rwlock_init+0x28>    
4000845c:	c2 06 40 00 	ld  [ %i1 ], %g1                               
    the_attr = attr;                                                  
  } else {                                                            
    (void) pthread_rwlockattr_init( &default_attr );                  
40008460:	90 07 bf f8 	add  %fp, -8, %o0                              
40008464:	40 00 01 b5 	call  40008b38 <pthread_rwlockattr_init>       
40008468:	b2 07 bf f8 	add  %fp, -8, %i1                              
  }                                                                   
                                                                      
  /*                                                                  
   * Now start error checking the attributes that we are going to use 
   */                                                                 
  if ( !the_attr->is_initialized )                                    
4000846c:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40008470:	80 a0 60 00 	cmp  %g1, 0                                    
40008474:	02 80 00 22 	be  400084fc <pthread_rwlock_init+0xb4>        <== NEVER TAKEN
40008478:	b8 10 20 16 	mov  0x16, %i4                                 
    return EINVAL;                                                    
                                                                      
  switch ( the_attr->process_shared ) {                               
4000847c:	f8 06 60 04 	ld  [ %i1 + 4 ], %i4                           
40008480:	80 a7 20 00 	cmp  %i4, 0                                    
40008484:	32 80 00 1e 	bne,a   400084fc <pthread_rwlock_init+0xb4>    <== NEVER TAKEN
40008488:	b8 10 20 16 	mov  0x16, %i4                                 <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE void _CORE_RWLock_Initialize_attributes(         
  CORE_RWLock_Attributes *the_attributes                              
)                                                                     
{                                                                     
  the_attributes->XXX = 0;                                            
4000848c:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
 * 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 *)                                     
40008490:	37 10 00 78 	sethi  %hi(0x4001e000), %i3                    
40008494:	35 10 00 78 	sethi  %hi(0x4001e000), %i2                    
40008498:	40 00 0b 4e 	call  4000b1d0 <_Objects_Allocate>             
4000849c:	90 16 e2 30 	or  %i3, 0x230, %o0                            
   */                                                                 
  _CORE_RWLock_Initialize_attributes( &the_attributes );              
                                                                      
  the_rwlock = _POSIX_RWLock_Allocate();                              
                                                                      
  if ( !the_rwlock ) {                                                
400084a0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400084a4:	12 80 00 07 	bne  400084c0 <pthread_rwlock_init+0x78>       
400084a8:	90 07 60 10 	add  %i5, 0x10, %o0                            
400084ac:	d0 06 a0 d8 	ld  [ %i2 + 0xd8 ], %o0                        
400084b0:	40 00 07 f4 	call  4000a480 <_API_Mutex_Unlock>             
400084b4:	b8 10 20 0b 	mov  0xb, %i4                                  
                                                                      
  *rwlock = the_rwlock->Object.id;                                    
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
400084b8:	81 c7 e0 08 	ret                                            
400084bc:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
  if ( !the_rwlock ) {                                                
    _Objects_Allocator_unlock();                                      
    return EAGAIN;                                                    
  }                                                                   
                                                                      
  _CORE_RWLock_Initialize( &the_rwlock->RWLock, &the_attributes );    
400084c0:	40 00 09 25 	call  4000a954 <_CORE_RWLock_Initialize>       
400084c4:	92 07 bf f4 	add  %fp, -12, %o1                             
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
400084c8:	c4 17 60 0a 	lduh  [ %i5 + 0xa ], %g2                       
  Objects_Control     *the_object,                                    
  uint32_t             name                                           
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
400084cc:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open_u32(                          
  Objects_Information *information,                                   
400084d0:	b6 16 e2 30 	or  %i3, 0x230, %i3                            
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
400084d4:	c6 06 e0 1c 	ld  [ %i3 + 0x1c ], %g3                        
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
400084d8:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
400084dc:	85 28 a0 02 	sll  %g2, 2, %g2                               
400084e0:	fa 20 c0 02 	st  %i5, [ %g3 + %g2 ]                         
400084e4:	d0 06 a0 d8 	ld  [ %i2 + 0xd8 ], %o0                        
400084e8:	40 00 07 e6 	call  4000a480 <_API_Mutex_Unlock>             
400084ec:	c2 26 00 00 	st  %g1, [ %i0 ]                               
                                                                      
  *rwlock = the_rwlock->Object.id;                                    
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
400084f0:	81 c7 e0 08 	ret                                            
400084f4:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
  switch ( the_attr->process_shared ) {                               
    case PTHREAD_PROCESS_PRIVATE:    /* only supported values */      
      break;                                                          
    case PTHREAD_PROCESS_SHARED:                                      
    default:                                                          
      return EINVAL;                                                  
400084f8:	b8 10 20 16 	mov  0x16, %i4                                 
                                                                      
  *rwlock = the_rwlock->Object.id;                                    
                                                                      
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
400084fc:	b0 10 00 1c 	mov  %i4, %i0                                  
40008500:	81 c7 e0 08 	ret                                            
40008504:	81 e8 00 00 	restore                                        
                                                                      

40008b14 <pthread_rwlock_timedrdlock>: int pthread_rwlock_timedrdlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) {
40008b14:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Watchdog_Interval                            ticks;                 
  bool                                         do_wait = true;        
  POSIX_Absolute_timeout_conversion_results_t  status;                
  Thread_Control                              *executing;             
                                                                      
  if ( !rwlock )                                                      
40008b18:	80 a6 20 00 	cmp  %i0, 0                                    
40008b1c:	02 80 00 2b 	be  40008bc8 <pthread_rwlock_timedrdlock+0xb4> 
40008b20:	92 07 bf fc 	add  %fp, -4, %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 );       
40008b24:	40 00 19 fe 	call  4000f31c <_POSIX_Absolute_timeout_to_ticks>
40008b28:	90 10 00 19 	mov  %i1, %o0                                  
40008b2c:	d2 06 00 00 	ld  [ %i0 ], %o1                               
40008b30:	ba 10 00 08 	mov  %o0, %i5                                  
40008b34:	94 07 bf f8 	add  %fp, -8, %o2                              
40008b38:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
40008b3c:	40 00 0b 26 	call  4000b7d4 <_Objects_Get>                  
40008b40:	90 12 20 f4 	or  %o0, 0xf4, %o0	! 4001c4f4 <_POSIX_RWLock_Information>
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
    do_wait = false;                                                  
                                                                      
  the_rwlock = _POSIX_RWLock_Get( rwlock, &location );                
  switch ( location ) {                                               
40008b44:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
40008b48:	80 a0 60 00 	cmp  %g1, 0                                    
40008b4c:	32 80 00 20 	bne,a   40008bcc <pthread_rwlock_timedrdlock+0xb8>
40008b50:	b0 10 20 16 	mov  0x16, %i0                                 
                                                                      
    case OBJECTS_LOCAL:                                               
                                                                      
      executing = _Thread_Executing;                                  
40008b54:	f8 01 a0 18 	ld  [ %g6 + 0x18 ], %i4                        
      _CORE_RWLock_Obtain_for_reading(                                
40008b58:	d4 06 00 00 	ld  [ %i0 ], %o2                               
40008b5c:	d8 07 bf fc 	ld  [ %fp + -4 ], %o4                          
   *  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 );       
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
40008b60:	82 1f 60 03 	xor  %i5, 3, %g1                               
  switch ( location ) {                                               
                                                                      
    case OBJECTS_LOCAL:                                               
                                                                      
      executing = _Thread_Executing;                                  
      _CORE_RWLock_Obtain_for_reading(                                
40008b64:	90 02 20 10 	add  %o0, 0x10, %o0                            
40008b68:	80 a0 00 01 	cmp  %g0, %g1                                  
40008b6c:	92 10 00 1c 	mov  %i4, %o1                                  
40008b70:	b6 60 3f ff 	subx  %g0, -1, %i3                             
40008b74:	9a 10 20 00 	clr  %o5                                       
40008b78:	40 00 07 62 	call  4000a900 <_CORE_RWLock_Obtain_for_reading>
40008b7c:	96 10 00 1b 	mov  %i3, %o3                                  
40008b80:	40 00 0e 66 	call  4000c518 <_Thread_Enable_dispatch>       
40008b84:	01 00 00 00 	nop                                            
        ticks,                                                        
        NULL                                                          
      );                                                              
                                                                      
      _Objects_Put( &the_rwlock->Object );                            
      if ( !do_wait ) {                                               
40008b88:	80 a6 e0 00 	cmp  %i3, 0                                    
40008b8c:	12 80 00 0b 	bne  40008bb8 <pthread_rwlock_timedrdlock+0xa4>
40008b90:	d0 07 20 34 	ld  [ %i4 + 0x34 ], %o0                        
        if ( executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE ) {
40008b94:	80 a2 20 02 	cmp  %o0, 2                                    
40008b98:	12 80 00 08 	bne  40008bb8 <pthread_rwlock_timedrdlock+0xa4>
40008b9c:	80 a7 60 00 	cmp  %i5, 0                                    
          if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )             
40008ba0:	22 80 00 0b 	be,a   40008bcc <pthread_rwlock_timedrdlock+0xb8><== NEVER TAKEN
40008ba4:	b0 10 20 16 	mov  0x16, %i0                                 <== NOT EXECUTED
            return EINVAL;                                            
          if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||         
40008ba8:	ba 07 7f ff 	add  %i5, -1, %i5                              
40008bac:	80 a7 60 01 	cmp  %i5, 1                                    
40008bb0:	08 80 00 07 	bleu  40008bcc <pthread_rwlock_timedrdlock+0xb8><== ALWAYS TAKEN
40008bb4:	b0 10 20 74 	mov  0x74, %i0                                 
               status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )              
            return ETIMEDOUT;                                         
        }                                                             
      }                                                               
                                                                      
      return _POSIX_RWLock_Translate_core_RWLock_return_code(         
40008bb8:	40 00 00 37 	call  40008c94 <_POSIX_RWLock_Translate_core_RWLock_return_code>
40008bbc:	01 00 00 00 	nop                                            
40008bc0:	81 c7 e0 08 	ret                                            
40008bc4:	91 e8 00 08 	restore  %g0, %o0, %o0                         
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return EINVAL;                                                      
40008bc8:	b0 10 20 16 	mov  0x16, %i0                                 
}                                                                     
40008bcc:	81 c7 e0 08 	ret                                            
40008bd0:	81 e8 00 00 	restore                                        
                                                                      

40008bd4 <pthread_rwlock_timedwrlock>: int pthread_rwlock_timedwrlock( pthread_rwlock_t *rwlock, const struct timespec *abstime ) {
40008bd4:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Watchdog_Interval                            ticks;                 
  bool                                         do_wait = true;        
  POSIX_Absolute_timeout_conversion_results_t  status;                
  Thread_Control                              *executing;             
                                                                      
  if ( !rwlock )                                                      
40008bd8:	80 a6 20 00 	cmp  %i0, 0                                    
40008bdc:	02 80 00 2b 	be  40008c88 <pthread_rwlock_timedwrlock+0xb4> 
40008be0:	92 07 bf fc 	add  %fp, -4, %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 );       
40008be4:	40 00 19 ce 	call  4000f31c <_POSIX_Absolute_timeout_to_ticks>
40008be8:	90 10 00 19 	mov  %i1, %o0                                  
40008bec:	d2 06 00 00 	ld  [ %i0 ], %o1                               
40008bf0:	ba 10 00 08 	mov  %o0, %i5                                  
40008bf4:	94 07 bf f8 	add  %fp, -8, %o2                              
40008bf8:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
40008bfc:	40 00 0a f6 	call  4000b7d4 <_Objects_Get>                  
40008c00:	90 12 20 f4 	or  %o0, 0xf4, %o0	! 4001c4f4 <_POSIX_RWLock_Information>
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
    do_wait = false;                                                  
                                                                      
  the_rwlock = _POSIX_RWLock_Get( rwlock, &location );                
  switch ( location ) {                                               
40008c04:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
40008c08:	80 a0 60 00 	cmp  %g1, 0                                    
40008c0c:	32 80 00 20 	bne,a   40008c8c <pthread_rwlock_timedwrlock+0xb8>
40008c10:	b0 10 20 16 	mov  0x16, %i0                                 
                                                                      
    case OBJECTS_LOCAL:                                               
                                                                      
      executing = _Thread_Executing;                                  
40008c14:	f8 01 a0 18 	ld  [ %g6 + 0x18 ], %i4                        
      _CORE_RWLock_Obtain_for_writing(                                
40008c18:	d4 06 00 00 	ld  [ %i0 ], %o2                               
40008c1c:	d8 07 bf fc 	ld  [ %fp + -4 ], %o4                          
   *  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 );       
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
40008c20:	82 1f 60 03 	xor  %i5, 3, %g1                               
  switch ( location ) {                                               
                                                                      
    case OBJECTS_LOCAL:                                               
                                                                      
      executing = _Thread_Executing;                                  
      _CORE_RWLock_Obtain_for_writing(                                
40008c24:	90 02 20 10 	add  %o0, 0x10, %o0                            
40008c28:	80 a0 00 01 	cmp  %g0, %g1                                  
40008c2c:	92 10 00 1c 	mov  %i4, %o1                                  
40008c30:	b6 60 3f ff 	subx  %g0, -1, %i3                             
40008c34:	9a 10 20 00 	clr  %o5                                       
40008c38:	40 00 07 60 	call  4000a9b8 <_CORE_RWLock_Obtain_for_writing>
40008c3c:	96 10 00 1b 	mov  %i3, %o3                                  
40008c40:	40 00 0e 36 	call  4000c518 <_Thread_Enable_dispatch>       
40008c44:	01 00 00 00 	nop                                            
        ticks,                                                        
        NULL                                                          
      );                                                              
                                                                      
      _Objects_Put( &the_rwlock->Object );                            
      if ( !do_wait &&                                                
40008c48:	80 a6 e0 00 	cmp  %i3, 0                                    
40008c4c:	12 80 00 0b 	bne  40008c78 <pthread_rwlock_timedwrlock+0xa4>
40008c50:	d0 07 20 34 	ld  [ %i4 + 0x34 ], %o0                        
40008c54:	80 a2 20 02 	cmp  %o0, 2                                    
40008c58:	12 80 00 08 	bne  40008c78 <pthread_rwlock_timedwrlock+0xa4>
40008c5c:	80 a7 60 00 	cmp  %i5, 0                                    
           (executing->Wait.return_code == CORE_RWLOCK_UNAVAILABLE) ) {
        if ( status == POSIX_ABSOLUTE_TIMEOUT_INVALID )               
40008c60:	22 80 00 0b 	be,a   40008c8c <pthread_rwlock_timedwrlock+0xb8><== NEVER TAKEN
40008c64:	b0 10 20 16 	mov  0x16, %i0                                 <== NOT EXECUTED
          return EINVAL;                                              
        if ( status == POSIX_ABSOLUTE_TIMEOUT_IS_IN_PAST ||           
40008c68:	ba 07 7f ff 	add  %i5, -1, %i5                              
40008c6c:	80 a7 60 01 	cmp  %i5, 1                                    
40008c70:	08 80 00 07 	bleu  40008c8c <pthread_rwlock_timedwrlock+0xb8><== ALWAYS TAKEN
40008c74:	b0 10 20 74 	mov  0x74, %i0                                 
             status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )                
          return ETIMEDOUT;                                           
      }                                                               
                                                                      
      return _POSIX_RWLock_Translate_core_RWLock_return_code(         
40008c78:	40 00 00 07 	call  40008c94 <_POSIX_RWLock_Translate_core_RWLock_return_code>
40008c7c:	01 00 00 00 	nop                                            
40008c80:	81 c7 e0 08 	ret                                            
40008c84:	91 e8 00 08 	restore  %g0, %o0, %o0                         
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return EINVAL;                                                      
40008c88:	b0 10 20 16 	mov  0x16, %i0                                 
}                                                                     
40008c8c:	81 c7 e0 08 	ret                                            
40008c90:	81 e8 00 00 	restore                                        
                                                                      

4000943c <pthread_rwlockattr_setpshared>: int pthread_rwlockattr_setpshared( pthread_rwlockattr_t *attr, int pshared ) {
4000943c:	82 10 00 08 	mov  %o0, %g1                                  
  if ( !attr )                                                        
40009440:	80 a0 60 00 	cmp  %g1, 0                                    
40009444:	02 80 00 0a 	be  4000946c <pthread_rwlockattr_setpshared+0x30>
40009448:	90 10 20 16 	mov  0x16, %o0                                 
    return EINVAL;                                                    
                                                                      
  if ( !attr->is_initialized )                                        
4000944c:	c4 00 40 00 	ld  [ %g1 ], %g2                               
40009450:	80 a0 a0 00 	cmp  %g2, 0                                    
40009454:	02 80 00 06 	be  4000946c <pthread_rwlockattr_setpshared+0x30>
40009458:	80 a2 60 01 	cmp  %o1, 1                                    
    return EINVAL;                                                    
                                                                      
  switch ( pshared ) {                                                
4000945c:	18 80 00 04 	bgu  4000946c <pthread_rwlockattr_setpshared+0x30><== NEVER TAKEN
40009460:	01 00 00 00 	nop                                            
    case PTHREAD_PROCESS_SHARED:                                      
    case PTHREAD_PROCESS_PRIVATE:                                     
      attr->process_shared = pshared;                                 
40009464:	d2 20 60 04 	st  %o1, [ %g1 + 4 ]                           
      return 0;                                                       
40009468:	90 10 20 00 	clr  %o0                                       
                                                                      
    default:                                                          
      return EINVAL;                                                  
  }                                                                   
}                                                                     
4000946c:	81 c3 e0 08 	retl                                           
                                                                      

4000a674 <pthread_setschedparam>: int pthread_setschedparam( pthread_t thread, int policy, struct sched_param *param ) {
4000a674:	9d e3 bf 90 	save  %sp, -112, %sp                           
  int                                  rc;                            
                                                                      
  /*                                                                  
   *  Check all the parameters                                        
   */                                                                 
  if ( !param )                                                       
4000a678:	80 a6 a0 00 	cmp  %i2, 0                                    
4000a67c:	02 80 00 43 	be  4000a788 <pthread_setschedparam+0x114>     
4000a680:	90 10 20 16 	mov  0x16, %o0                                 
    return EINVAL;                                                    
                                                                      
  rc = _POSIX_Thread_Translate_sched_param(                           
4000a684:	90 10 00 19 	mov  %i1, %o0                                  
4000a688:	92 10 00 1a 	mov  %i2, %o1                                  
4000a68c:	94 07 bf f4 	add  %fp, -12, %o2                             
4000a690:	40 00 17 ed 	call  40010644 <_POSIX_Thread_Translate_sched_param>
4000a694:	96 07 bf f8 	add  %fp, -8, %o3                              
    policy,                                                           
    param,                                                            
    &budget_algorithm,                                                
    &budget_callout                                                   
  );                                                                  
  if ( rc )                                                           
4000a698:	80 a2 20 00 	cmp  %o0, 0                                    
4000a69c:	12 80 00 3b 	bne  4000a788 <pthread_setschedparam+0x114>    
4000a6a0:	01 00 00 00 	nop                                            
    return rc;                                                        
                                                                      
  /*                                                                  
   *  Actually change the scheduling policy and parameters            
   */                                                                 
  the_thread = _Thread_Get( thread, &location );                      
4000a6a4:	90 10 00 18 	mov  %i0, %o0                                  
4000a6a8:	40 00 0b da 	call  4000d610 <_Thread_Get>                   
4000a6ac:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
4000a6b0:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
    return rc;                                                        
                                                                      
  /*                                                                  
   *  Actually change the scheduling policy and parameters            
   */                                                                 
  the_thread = _Thread_Get( thread, &location );                      
4000a6b4:	b8 10 00 08 	mov  %o0, %i4                                  
  switch ( location ) {                                               
4000a6b8:	80 a0 60 00 	cmp  %g1, 0                                    
4000a6bc:	12 80 00 33 	bne  4000a788 <pthread_setschedparam+0x114>    
4000a6c0:	90 10 20 03 	mov  3, %o0                                    
                                                                      
    case OBJECTS_LOCAL:                                               
      api = the_thread->API_Extensions[ THREAD_API_POSIX ];           
4000a6c4:	fa 07 21 30 	ld  [ %i4 + 0x130 ], %i5                       
                                                                      
      if ( api->schedpolicy == SCHED_SPORADIC )                       
4000a6c8:	c2 07 60 90 	ld  [ %i5 + 0x90 ], %g1                        
4000a6cc:	80 a0 60 04 	cmp  %g1, 4                                    
4000a6d0:	12 80 00 05 	bne  4000a6e4 <pthread_setschedparam+0x70>     
4000a6d4:	92 10 00 1a 	mov  %i2, %o1                                  
        (void) _Watchdog_Remove( &api->Sporadic_timer );              
4000a6d8:	40 00 10 f3 	call  4000eaa4 <_Watchdog_Remove>              
4000a6dc:	90 07 60 b4 	add  %i5, 0xb4, %o0                            
                                                                      
      api->schedpolicy = policy;                                      
      api->schedparam  = *param;                                      
4000a6e0:	92 10 00 1a 	mov  %i2, %o1                                  
4000a6e4:	94 10 20 1c 	mov  0x1c, %o2                                 
      api = the_thread->API_Extensions[ THREAD_API_POSIX ];           
                                                                      
      if ( api->schedpolicy == SCHED_SPORADIC )                       
        (void) _Watchdog_Remove( &api->Sporadic_timer );              
                                                                      
      api->schedpolicy = policy;                                      
4000a6e8:	f2 27 60 90 	st  %i1, [ %i5 + 0x90 ]                        
      api->schedparam  = *param;                                      
4000a6ec:	40 00 22 fa 	call  400132d4 <memcpy>                        
4000a6f0:	90 07 60 94 	add  %i5, 0x94, %o0                            
      api->Attributes.schedpolicy = policy;                           
      api->Attributes.schedparam  = *param;                           
4000a6f4:	90 07 60 18 	add  %i5, 0x18, %o0                            
      if ( api->schedpolicy == SCHED_SPORADIC )                       
        (void) _Watchdog_Remove( &api->Sporadic_timer );              
                                                                      
      api->schedpolicy = policy;                                      
      api->schedparam  = *param;                                      
      api->Attributes.schedpolicy = policy;                           
4000a6f8:	f2 27 60 14 	st  %i1, [ %i5 + 0x14 ]                        
      api->Attributes.schedparam  = *param;                           
4000a6fc:	92 10 00 1a 	mov  %i2, %o1                                  
4000a700:	40 00 22 f5 	call  400132d4 <memcpy>                        
4000a704:	94 10 20 1c 	mov  0x1c, %o2                                 
                                                                      
      the_thread->budget_algorithm = budget_algorithm;                
4000a708:	c2 07 bf f4 	ld  [ %fp + -12 ], %g1                         
      the_thread->budget_callout   = budget_callout;                  
                                                                      
      switch ( api->schedpolicy ) {                                   
4000a70c:	80 a6 60 00 	cmp  %i1, 0                                    
      api->schedpolicy = policy;                                      
      api->schedparam  = *param;                                      
      api->Attributes.schedpolicy = policy;                           
      api->Attributes.schedparam  = *param;                           
                                                                      
      the_thread->budget_algorithm = budget_algorithm;                
4000a710:	c2 27 20 78 	st  %g1, [ %i4 + 0x78 ]                        
      the_thread->budget_callout   = budget_callout;                  
4000a714:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
                                                                      
      switch ( api->schedpolicy ) {                                   
4000a718:	06 80 00 19 	bl  4000a77c <pthread_setschedparam+0x108>     <== NEVER TAKEN
4000a71c:	c2 27 20 7c 	st  %g1, [ %i4 + 0x7c ]                        
4000a720:	80 a6 60 02 	cmp  %i1, 2                                    
4000a724:	04 80 00 0b 	ble  4000a750 <pthread_setschedparam+0xdc>     
4000a728:	80 a6 60 04 	cmp  %i1, 4                                    
4000a72c:	12 80 00 14 	bne  4000a77c <pthread_setschedparam+0x108>    <== NEVER TAKEN
4000a730:	90 07 60 b4 	add  %i5, 0xb4, %o0                            
             true                                                     
          );                                                          
          break;                                                      
                                                                      
        case SCHED_SPORADIC:                                          
          api->ss_high_priority = api->schedparam.sched_priority;     
4000a734:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        
          _Watchdog_Remove( &api->Sporadic_timer );                   
4000a738:	40 00 10 db 	call  4000eaa4 <_Watchdog_Remove>              
4000a73c:	c2 27 60 b0 	st  %g1, [ %i5 + 0xb0 ]                        
          _POSIX_Threads_Sporadic_budget_TSR( 0, the_thread );        
4000a740:	90 10 20 00 	clr  %o0                                       
4000a744:	7f ff ff 29 	call  4000a3e8 <_POSIX_Threads_Sporadic_budget_TSR>
4000a748:	92 10 00 1c 	mov  %i4, %o1                                  
          break;                                                      
4000a74c:	30 80 00 0c 	b,a   4000a77c <pthread_setschedparam+0x108>   
      switch ( api->schedpolicy ) {                                   
        case SCHED_OTHER:                                             
        case SCHED_FIFO:                                              
        case SCHED_RR:                                                
          the_thread->cpu_time_budget =                               
            rtems_configuration_get_ticks_per_timeslice();            
4000a750:	03 10 00 6b 	sethi  %hi(0x4001ac00), %g1                    
                                                                      
      switch ( api->schedpolicy ) {                                   
        case SCHED_OTHER:                                             
        case SCHED_FIFO:                                              
        case SCHED_RR:                                                
          the_thread->cpu_time_budget =                               
4000a754:	c2 00 63 dc 	ld  [ %g1 + 0x3dc ], %g1	! 4001afdc <Configuration+0x1c>
            rtems_configuration_get_ticks_per_timeslice();            
                                                                      
          the_thread->real_priority =                                 
            _POSIX_Priority_To_core( api->schedparam.sched_priority );
                                                                      
          _Thread_Change_priority(                                    
4000a758:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
      switch ( api->schedpolicy ) {                                   
        case SCHED_OTHER:                                             
        case SCHED_FIFO:                                              
        case SCHED_RR:                                                
          the_thread->cpu_time_budget =                               
4000a75c:	c2 27 20 74 	st  %g1, [ %i4 + 0x74 ]                        
4000a760:	03 10 00 71 	sethi  %hi(0x4001c400), %g1                    
4000a764:	d2 08 60 94 	ldub  [ %g1 + 0x94 ], %o1	! 4001c494 <rtems_maximum_priority>
4000a768:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        
            rtems_configuration_get_ticks_per_timeslice();            
                                                                      
          the_thread->real_priority =                                 
            _POSIX_Priority_To_core( api->schedparam.sched_priority );
                                                                      
          _Thread_Change_priority(                                    
4000a76c:	94 10 20 01 	mov  1, %o2                                    
4000a770:	92 22 40 01 	sub  %o1, %g1, %o1                             
4000a774:	40 00 0a af 	call  4000d230 <_Thread_Change_priority>       
4000a778:	d2 27 20 18 	st  %o1, [ %i4 + 0x18 ]                        
4000a77c:	40 00 0b 9a 	call  4000d5e4 <_Thread_Enable_dispatch>       
4000a780:	01 00 00 00 	nop                                            
          _POSIX_Threads_Sporadic_budget_TSR( 0, the_thread );        
          break;                                                      
      }                                                               
                                                                      
      _Objects_Put( &the_thread->Object );                            
      return 0;                                                       
4000a784:	90 10 20 00 	clr  %o0	! 0 <_TLS_BSS_size>                   
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return ESRCH;                                                       
}                                                                     
4000a788:	81 c7 e0 08 	ret                                            
4000a78c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40006134 <pthread_setspecific>: int pthread_setspecific( pthread_key_t key, const void *value ) {
40006134:	9d e3 bf 78 	save  %sp, -136, %sp                           
40006138:	11 10 00 53 	sethi  %hi(0x40014c00), %o0                    
4000613c:	92 10 00 18 	mov  %i0, %o1                                  
40006140:	90 12 22 0c 	or  %o0, 0x20c, %o0                            
40006144:	40 00 06 74 	call  40007b14 <_Objects_Get>                  
40006148:	94 07 bf d8 	add  %fp, -40, %o2                             
  POSIX_Keys_Key_value_pair   *value_pair_ptr;                        
  RBTree_Node                 *p;                                     
  POSIX_Keys_Key_value_pair    search_node;                           
                                                                      
  the_key = _POSIX_Keys_Get( key, &location );                        
  switch ( location ) {                                               
4000614c:	c2 07 bf d8 	ld  [ %fp + -40 ], %g1                         
40006150:	80 a0 60 00 	cmp  %g1, 0                                    
40006154:	12 80 00 29 	bne  400061f8 <pthread_setspecific+0xc4>       
40006158:	39 10 00 53 	sethi  %hi(0x40014c00), %i4                    
                                                                      
    case OBJECTS_LOCAL:                                               
      search_node.key = key;                                          
      search_node.thread_id = _Thread_Executing->Object.id;           
4000615c:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
                                                                      
  the_key = _POSIX_Keys_Get( key, &location );                        
  switch ( location ) {                                               
                                                                      
    case OBJECTS_LOCAL:                                               
      search_node.key = key;                                          
40006160:	f0 27 bf f4 	st  %i0, [ %fp + -12 ]                         
      search_node.thread_id = _Thread_Executing->Object.id;           
40006164:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
40006168:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
      p = _RBTree_Find( &_POSIX_Keys_Key_value_lookup_tree,           
4000616c:	90 17 22 c8 	or  %i4, 0x2c8, %o0                            
40006170:	40 00 07 09 	call  40007d94 <_RBTree_Find>                  
40006174:	92 07 bf e4 	add  %fp, -28, %o1                             
                                    &search_node.Key_value_lookup_node );
                                                                      
      if ( p ) {                                                      
40006178:	80 a2 20 00 	cmp  %o0, 0                                    
4000617c:	22 80 00 04 	be,a   4000618c <pthread_setspecific+0x58>     
40006180:	11 10 00 53 	sethi  %hi(0x40014c00), %o0                    
40006184:	10 80 00 19 	b  400061e8 <pthread_setspecific+0xb4>         
40006188:	f2 22 20 18 	st  %i1, [ %o0 + 0x18 ]	! 40014c18 <_POSIX_RWLock_Information+0x4>
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE POSIX_Keys_Key_value_pair *                      
_POSIX_Keys_Key_value_pair_allocate( void )                           
{                                                                     
  return (POSIX_Keys_Key_value_pair *) _Freechain_Get( &_POSIX_Keys_Keypool );
4000618c:	40 00 03 e8 	call  4000712c <_Freechain_Get>                
40006190:	90 12 22 84 	or  %o0, 0x284, %o0                            
                                                                      
        value_pair_ptr->value = value;                                
      } else {                                                        
        value_pair_ptr = _POSIX_Keys_Key_value_pair_allocate();       
                                                                      
        if ( !value_pair_ptr ) {                                      
40006194:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40006198:	32 80 00 06 	bne,a   400061b0 <pthread_setspecific+0x7c>    <== ALWAYS TAKEN
4000619c:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
400061a0:	40 00 0a 13 	call  400089ec <_Thread_Enable_dispatch>       <== NOT EXECUTED
400061a4:	b0 10 20 0c 	mov  0xc, %i0                                  <== NOT EXECUTED
          _Objects_Put( &the_key->Object );                           
                                                                      
          return ENOMEM;                                              
400061a8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400061ac:	81 e8 00 00 	restore                                        <== NOT EXECUTED
        }                                                             
                                                                      
        value_pair_ptr->key = key;                                    
400061b0:	f0 27 60 18 	st  %i0, [ %i5 + 0x18 ]                        
        value_pair_ptr->thread_id = _Thread_Executing->Object.id;     
400061b4:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
        value_pair_ptr->value = value;                                
        /* The insert can only go wrong if the same node is already in a unique
         * tree. This has been already checked with the _RBTree_Find() */
        (void) _RBTree_Insert( &_POSIX_Keys_Key_value_lookup_tree,    
400061b8:	90 17 22 c8 	or  %i4, 0x2c8, %o0                            
                                                                      
          return ENOMEM;                                              
        }                                                             
                                                                      
        value_pair_ptr->key = key;                                    
        value_pair_ptr->thread_id = _Thread_Executing->Object.id;     
400061bc:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        
        value_pair_ptr->value = value;                                
400061c0:	f2 27 60 20 	st  %i1, [ %i5 + 0x20 ]                        
        /* The insert can only go wrong if the same node is already in a unique
         * tree. This has been already checked with the _RBTree_Find() */
        (void) _RBTree_Insert( &_POSIX_Keys_Key_value_lookup_tree,    
400061c4:	40 00 07 2c 	call  40007e74 <_RBTree_Insert>                
400061c8:	92 07 60 08 	add  %i5, 8, %o1                               
                             &(value_pair_ptr->Key_value_lookup_node) );
                                                                      
        /** append rb_node to the thread API extension's chain */     
        _Chain_Append_unprotected(                                    
          &_Thread_Executing->Key_Chain,                              
400061cc:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
400061d0:	c4 00 61 40 	ld  [ %g1 + 0x140 ], %g2                       
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
400061d4:	86 00 61 3c 	add  %g1, 0x13c, %g3                           
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
400061d8:	c6 27 40 00 	st  %g3, [ %i5 ]                               
  tail->previous = the_node;                                          
400061dc:	fa 20 61 40 	st  %i5, [ %g1 + 0x140 ]                       
  old_last->next = the_node;                                          
400061e0:	fa 20 80 00 	st  %i5, [ %g2 ]                               
  the_node->previous = old_last;                                      
400061e4:	c4 27 60 04 	st  %g2, [ %i5 + 4 ]                           
400061e8:	40 00 0a 01 	call  400089ec <_Thread_Enable_dispatch>       
400061ec:	b0 10 20 00 	clr  %i0                                       
        );                                                            
      }                                                               
                                                                      
      _Objects_Put( &the_key->Object );                               
                                                                      
      return 0;                                                       
400061f0:	81 c7 e0 08 	ret                                            
400061f4:	81 e8 00 00 	restore                                        
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return EINVAL;                                                      
}                                                                     
400061f8:	81 c7 e0 08 	ret                                            
400061fc:	91 e8 20 16 	restore  %g0, 0x16, %o0                        
                                                                      

400078fc <pthread_testcancel>: /* * 18.2.2 Setting Cancelability State, P1003.1c/Draft 10, p. 183 */ void pthread_testcancel( void ) {
400078fc:	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() )                                        
40007900:	c4 01 a0 0c 	ld  [ %g6 + 0xc ], %g2                         
40007904:	80 a0 a0 00 	cmp  %g2, 0                                    
40007908:	12 80 00 15 	bne  4000795c <pthread_testcancel+0x60>        <== NEVER TAKEN
4000790c:	01 00 00 00 	nop                                            
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40007910:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40007914:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40007918:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
    return;                                                           
                                                                      
  _Thread_Disable_dispatch();                                         
    executing = _Thread_Executing;                                    
4000791c:	f0 01 a0 18 	ld  [ %g6 + 0x18 ], %i0                        
    thread_support = executing->API_Extensions[ THREAD_API_POSIX ];   
40007920:	c2 06 21 30 	ld  [ %i0 + 0x130 ], %g1                       
                                                                      
    if ( thread_support->cancelability_state == PTHREAD_CANCEL_ENABLE &&
40007924:	c4 00 60 f0 	ld  [ %g1 + 0xf0 ], %g2                        
40007928:	80 a0 a0 00 	cmp  %g2, 0                                    
4000792c:	12 80 00 05 	bne  40007940 <pthread_testcancel+0x44>        <== NEVER TAKEN
40007930:	ba 10 20 00 	clr  %i5                                       
40007934:	c2 00 60 f8 	ld  [ %g1 + 0xf8 ], %g1                        
40007938:	80 a0 00 01 	cmp  %g0, %g1                                  
4000793c:	ba 40 20 00 	addx  %g0, 0, %i5                              
         thread_support->cancelation_requested )                      
      cancel = true;                                                  
  _Thread_Enable_dispatch();                                          
40007940:	40 00 0b 5e 	call  4000a6b8 <_Thread_Enable_dispatch>       
40007944:	01 00 00 00 	nop                                            
                                                                      
  if ( cancel )                                                       
40007948:	80 8f 60 ff 	btst  0xff, %i5                                
4000794c:	02 80 00 04 	be  4000795c <pthread_testcancel+0x60>         
40007950:	01 00 00 00 	nop                                            
    _POSIX_Thread_Exit( executing, PTHREAD_CANCELED );                
40007954:	40 00 17 9f 	call  4000d7d0 <_POSIX_Thread_Exit>            
40007958:	93 e8 3f ff 	restore  %g0, -1, %o1                          
4000795c:	81 c7 e0 08 	ret                                            
40007960:	81 e8 00 00 	restore                                        
                                                                      

4000cc28 <ramdisk_allocate>: void *area_begin, uint32_t media_block_size, rtems_blkdev_bnum media_block_count, bool trace ) {
4000cc28:	9d e3 bf a0 	save  %sp, -96, %sp                            
  struct ramdisk *rd = malloc(sizeof(struct ramdisk));                
4000cc2c:	7f ff e0 88 	call  40004e4c <malloc>                        
4000cc30:	90 10 20 10 	mov  0x10, %o0                                 
                                                                      
  if (rd == NULL) {                                                   
4000cc34:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000cc38:	02 80 00 17 	be  4000cc94 <ramdisk_allocate+0x6c>           <== NEVER TAKEN
4000cc3c:	80 a6 20 00 	cmp  %i0, 0                                    
    return NULL;                                                      
  }                                                                   
                                                                      
  if (area_begin == NULL) {                                           
4000cc40:	32 80 00 0d 	bne,a   4000cc74 <ramdisk_allocate+0x4c>       
4000cc44:	c0 2f 60 0d 	clrb  [ %i5 + 0xd ]                            
    area_begin = calloc(media_block_count, media_block_size);         
4000cc48:	90 10 00 1a 	mov  %i2, %o0                                  
4000cc4c:	7f ff df 1f 	call  400048c8 <calloc>                        
4000cc50:	92 10 00 19 	mov  %i1, %o1                                  
    if (area_begin == NULL) {                                         
4000cc54:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000cc58:	12 80 00 06 	bne  4000cc70 <ramdisk_allocate+0x48>          <== ALWAYS TAKEN
4000cc5c:	82 10 20 01 	mov  1, %g1                                    
      free(rd);                                                       
4000cc60:	7f ff df 52 	call  400049a8 <free>                          <== NOT EXECUTED
4000cc64:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                                                                      
      return NULL;                                                    
4000cc68:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000cc6c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
4000cc70:	c2 2f 60 0d 	stb  %g1, [ %i5 + 0xd ]                        
  } else {                                                            
    rd->malloced = false;                                             
  }                                                                   
  rd->block_size = media_block_size;                                  
  rd->block_num = media_block_count;                                  
  rd->area = area_begin;                                              
4000cc74:	f0 27 60 08 	st  %i0, [ %i5 + 8 ]                           
  rd->trace = trace;                                                  
  rd->initialized = true;                                             
4000cc78:	82 10 20 01 	mov  1, %g1                                    
    }                                                                 
    rd->malloced = true;                                              
  } else {                                                            
    rd->malloced = false;                                             
  }                                                                   
  rd->block_size = media_block_size;                                  
4000cc7c:	f2 27 40 00 	st  %i1, [ %i5 ]                               
  rd->block_num = media_block_count;                                  
4000cc80:	f4 27 60 04 	st  %i2, [ %i5 + 4 ]                           
  rd->area = area_begin;                                              
  rd->trace = trace;                                                  
4000cc84:	f6 2f 60 0e 	stb  %i3, [ %i5 + 0xe ]                        
  rd->initialized = true;                                             
4000cc88:	c2 2f 60 0c 	stb  %g1, [ %i5 + 0xc ]                        
                                                                      
  return rd;                                                          
4000cc8c:	81 c7 e0 08 	ret                                            
4000cc90:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
}                                                                     
4000cc94:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000cc98:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
                                                                      

4000cc9c <ramdisk_free>: void ramdisk_free(ramdisk *rd) {
4000cc9c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (rd != NULL) {                                                   
4000cca0:	80 a6 20 00 	cmp  %i0, 0                                    
4000cca4:	02 80 00 0a 	be  4000cccc <ramdisk_free+0x30>               <== NEVER TAKEN
4000cca8:	01 00 00 00 	nop                                            
    if (rd->malloced) {                                               
4000ccac:	c2 0e 20 0d 	ldub  [ %i0 + 0xd ], %g1                       
4000ccb0:	80 a0 60 00 	cmp  %g1, 0                                    
4000ccb4:	02 80 00 04 	be  4000ccc4 <ramdisk_free+0x28>               
4000ccb8:	01 00 00 00 	nop                                            
      free(rd->area);                                                 
4000ccbc:	7f ff df 3b 	call  400049a8 <free>                          
4000ccc0:	d0 06 20 08 	ld  [ %i0 + 8 ], %o0                           
    }                                                                 
    free(rd);                                                         
4000ccc4:	7f ff df 39 	call  400049a8 <free>                          
4000ccc8:	81 e8 00 00 	restore                                        
4000cccc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000ccd0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e86c <ramdisk_initialize>: rtems_device_driver ramdisk_initialize( rtems_device_major_number major, rtems_device_minor_number minor __attribute__((unused)), void *arg __attribute__((unused))) {
4000e86c:	9d e3 bf 88 	save  %sp, -120, %sp                           
    rtems_device_minor_number i;                                      
    rtems_ramdisk_config *c = rtems_ramdisk_configuration;            
    struct ramdisk *r;                                                
    rtems_status_code rc;                                             
                                                                      
    rc = rtems_disk_io_initialize();                                  
4000e870:	7f ff da 95 	call  400052c4 <rtems_disk_io_initialize>      
4000e874:	a8 10 00 18 	mov  %i0, %l4                                  
    if (rc != RTEMS_SUCCESSFUL)                                       
4000e878:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000e87c:	12 80 00 46 	bne  4000e994 <ramdisk_initialize+0x128>       <== NEVER TAKEN
4000e880:	3b 10 00 9d 	sethi  %hi(0x40027400), %i5                    
     * 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));
4000e884:	d0 07 60 80 	ld  [ %i5 + 0x80 ], %o0	! 40027480 <rtems_ramdisk_configuration_size>
4000e888:	92 10 20 10 	mov  0x10, %o1                                 
4000e88c:	7f ff de 7a 	call  40006274 <calloc>                        
4000e890:	33 10 00 9d 	sethi  %hi(0x40027400), %i1                    
4000e894:	a6 10 00 1d 	mov  %i5, %l3                                  
    r->trace = false;                                                 
    for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)  
    {                                                                 
        dev_t dev = rtems_filesystem_make_dev_t(major, i);            
        char name [] = RAMDISK_DEVICE_BASE_NAME "a";                  
4000e898:	39 0b d9 19 	sethi  %hi(0x2f646400), %i4                    
4000e89c:	3b 0b dc 99 	sethi  %hi(0x2f726400), %i5                    
        {                                                             
            r->malloced = false;                                      
            r->initialized = true;                                    
            r->area = c->location;                                    
        }                                                             
        rc = rtems_disk_create_phys(dev, c->block_size, c->block_num, 
4000e8a0:	2b 10 00 3a 	sethi  %hi(0x4000e800), %l5                    
     * 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));
4000e8a4:	b6 10 00 08 	mov  %o0, %i3                                  
    r->trace = false;                                                 
4000e8a8:	c0 2a 20 0e 	clrb  [ %o0 + 0xe ]                            
    rtems_device_major_number major,                                  
    rtems_device_minor_number minor __attribute__((unused)),          
    void *arg __attribute__((unused)))                                
{                                                                     
    rtems_device_minor_number i;                                      
    rtems_ramdisk_config *c = rtems_ramdisk_configuration;            
4000e8ac:	b2 16 60 84 	or  %i1, 0x84, %i1                             
     * 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++)  
4000e8b0:	b4 10 20 00 	clr  %i2                                       
    {                                                                 
        dev_t dev = rtems_filesystem_make_dev_t(major, i);            
        char name [] = RAMDISK_DEVICE_BASE_NAME "a";                  
4000e8b4:	b8 17 21 76 	or  %i4, 0x176, %i4                            
4000e8b8:	ba 17 60 61 	or  %i5, 0x61, %i5                             
        {                                                             
            r->malloced = false;                                      
            r->initialized = true;                                    
            r->area = c->location;                                    
        }                                                             
        rc = rtems_disk_create_phys(dev, c->block_size, c->block_num, 
4000e8bc:	b0 07 bf f0 	add  %fp, -16, %i0                             
4000e8c0:	aa 15 61 9c 	or  %l5, 0x19c, %l5                            
            }                                                         
        }                                                             
        else                                                          
        {                                                             
            r->malloced = false;                                      
            r->initialized = true;                                    
4000e8c4:	a0 10 20 01 	mov  1, %l0                                    
     * 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++)  
4000e8c8:	c2 04 e0 80 	ld  [ %l3 + 0x80 ], %g1                        
4000e8cc:	80 a6 80 01 	cmp  %i2, %g1                                  
4000e8d0:	1a 80 00 30 	bcc  4000e990 <ramdisk_initialize+0x124>       
4000e8d4:	82 06 a0 61 	add  %i2, 0x61, %g1                            
    {                                                                 
        dev_t dev = rtems_filesystem_make_dev_t(major, i);            
        char name [] = RAMDISK_DEVICE_BASE_NAME "a";                  
4000e8d8:	f8 3f bf f0 	std  %i4, [ %fp + -16 ]                        
4000e8dc:	c0 2f bf f8 	clrb  [ %fp + -8 ]                             
        name [sizeof(RAMDISK_DEVICE_BASE_NAME) - 1] += i;             
4000e8e0:	c2 2f bf f7 	stb  %g1, [ %fp + -9 ]                         
        r->block_size = c->block_size;                                
4000e8e4:	e4 06 40 00 	ld  [ %i1 ], %l2                               
        r->block_num = c->block_num;                                  
4000e8e8:	e2 06 60 04 	ld  [ %i1 + 4 ], %l1                           
        if (c->location == NULL)                                      
4000e8ec:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
    for (i = 0; i < rtems_ramdisk_configuration_size; i++, c++, r++)  
    {                                                                 
        dev_t dev = rtems_filesystem_make_dev_t(major, i);            
        char name [] = RAMDISK_DEVICE_BASE_NAME "a";                  
        name [sizeof(RAMDISK_DEVICE_BASE_NAME) - 1] += i;             
        r->block_size = c->block_size;                                
4000e8f0:	e4 26 c0 00 	st  %l2, [ %i3 ]                               
        r->block_num = c->block_num;                                  
        if (c->location == NULL)                                      
4000e8f4:	80 a0 60 00 	cmp  %g1, 0                                    
4000e8f8:	12 80 00 0d 	bne  4000e92c <ramdisk_initialize+0xc0>        
4000e8fc:	e2 26 e0 04 	st  %l1, [ %i3 + 4 ]                           
        {                                                             
            r->malloced = true;                                       
            r->area = malloc(r->block_size * r->block_num);           
4000e900:	92 10 00 12 	mov  %l2, %o1                                  
        name [sizeof(RAMDISK_DEVICE_BASE_NAME) - 1] += i;             
        r->block_size = c->block_size;                                
        r->block_num = c->block_num;                                  
        if (c->location == NULL)                                      
        {                                                             
            r->malloced = true;                                       
4000e904:	e0 2e e0 0d 	stb  %l0, [ %i3 + 0xd ]                        
            r->area = malloc(r->block_size * r->block_num);           
4000e908:	40 00 50 5b 	call  40022a74 <.umul>                         
4000e90c:	90 10 00 11 	mov  %l1, %o0                                  
4000e910:	7f ff e0 09 	call  40006934 <malloc>                        
4000e914:	01 00 00 00 	nop                                            
            if (r->area == NULL) /* No enough memory for this disk */ 
4000e918:	80 a2 20 00 	cmp  %o0, 0                                    
4000e91c:	02 80 00 18 	be  4000e97c <ramdisk_initialize+0x110>        <== NEVER TAKEN
4000e920:	d0 26 e0 08 	st  %o0, [ %i3 + 8 ]                           
4000e924:	10 80 00 05 	b  4000e938 <ramdisk_initialize+0xcc>          
4000e928:	e0 2e e0 0c 	stb  %l0, [ %i3 + 0xc ]                        
                r->initialized = true;                                
            }                                                         
        }                                                             
        else                                                          
        {                                                             
            r->malloced = false;                                      
4000e92c:	c0 2e e0 0d 	clrb  [ %i3 + 0xd ]                            
            r->initialized = true;                                    
4000e930:	e0 2e e0 0c 	stb  %l0, [ %i3 + 0xc ]                        
            r->area = c->location;                                    
4000e934:	c2 26 e0 08 	st  %g1, [ %i3 + 8 ]                           
        }                                                             
        rc = rtems_disk_create_phys(dev, c->block_size, c->block_num, 
4000e938:	f0 23 a0 5c 	st  %i0, [ %sp + 0x5c ]                        
4000e93c:	90 10 00 14 	mov  %l4, %o0                                  
4000e940:	92 10 00 1a 	mov  %i2, %o1                                  
4000e944:	94 10 00 12 	mov  %l2, %o2                                  
4000e948:	96 10 00 11 	mov  %l1, %o3                                  
4000e94c:	98 10 00 15 	mov  %l5, %o4                                  
4000e950:	7f ff d9 bf 	call  4000504c <rtems_disk_create_phys>        
4000e954:	9a 10 00 1b 	mov  %i3, %o5                                  
                                    ramdisk_ioctl, r, name);          
        if (rc != RTEMS_SUCCESSFUL)                                   
4000e958:	80 a2 20 00 	cmp  %o0, 0                                    
4000e95c:	22 80 00 0a 	be,a   4000e984 <ramdisk_initialize+0x118>     <== ALWAYS TAKEN
4000e960:	b4 06 a0 01 	inc  %i2                                       
        {                                                             
            if (r->malloced)                                          
4000e964:	c2 0e e0 0d 	ldub  [ %i3 + 0xd ], %g1                       <== NOT EXECUTED
4000e968:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e96c:	22 80 00 05 	be,a   4000e980 <ramdisk_initialize+0x114>     <== NOT EXECUTED
4000e970:	c0 2e e0 0c 	clrb  [ %i3 + 0xc ]                            <== NOT EXECUTED
            {                                                         
                free(r->area);                                        
4000e974:	7f ff de 78 	call  40006354 <free>                          <== NOT EXECUTED
4000e978:	d0 06 e0 08 	ld  [ %i3 + 8 ], %o0                           <== NOT EXECUTED
            }                                                         
            r->initialized = false;                                   
4000e97c:	c0 2e e0 0c 	clrb  [ %i3 + 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++)  
4000e980:	b4 06 a0 01 	inc  %i2                                       <== NOT EXECUTED
4000e984:	b2 06 60 0c 	add  %i1, 0xc, %i1                             
4000e988:	10 bf ff d0 	b  4000e8c8 <ramdisk_initialize+0x5c>          
4000e98c:	b6 06 e0 10 	add  %i3, 0x10, %i3                            
                free(r->area);                                        
            }                                                         
            r->initialized = false;                                   
        }                                                             
    }                                                                 
    return RTEMS_SUCCESSFUL;                                          
4000e990:	b0 10 20 00 	clr  %i0                                       
}                                                                     
4000e994:	81 c7 e0 08 	ret                                            
4000e998:	81 e8 00 00 	restore                                        
                                                                      

4000caf8 <ramdisk_ioctl>: return 0; } int ramdisk_ioctl(rtems_disk_device *dd, uint32_t req, void *argp) {
4000caf8:	9d e3 bf a0 	save  %sp, -96, %sp                            
    struct ramdisk *rd = rtems_disk_get_driver_data(dd);              
                                                                      
    switch (req)                                                      
4000cafc:	05 08 00 10 	sethi  %hi(0x20004000), %g2                    
    return 0;                                                         
}                                                                     
                                                                      
int                                                                   
ramdisk_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)        
{                                                                     
4000cb00:	ba 10 00 1a 	mov  %i2, %i5                                  
    struct ramdisk *rd = rtems_disk_get_driver_data(dd);              
                                                                      
    switch (req)                                                      
4000cb04:	84 10 a2 07 	or  %g2, 0x207, %g2                            
4000cb08:	80 a6 40 02 	cmp  %i1, %g2                                  
4000cb0c:	02 80 00 38 	be  4000cbec <ramdisk_ioctl+0xf4>              
4000cb10:	f8 06 20 3c 	ld  [ %i0 + 0x3c ], %i4                        
4000cb14:	05 30 06 10 	sethi  %hi(0xc0184000), %g2                    
4000cb18:	84 10 a2 01 	or  %g2, 0x201, %g2	! c0184201 <RAM_END+0x7fd84201>
4000cb1c:	80 a6 40 02 	cmp  %i1, %g2                                  
4000cb20:	12 80 00 3a 	bne  4000cc08 <ramdisk_ioctl+0x110>            
4000cb24:	01 00 00 00 	nop                                            
    {                                                                 
        case RTEMS_BLKIO_REQUEST:                                     
        {                                                             
            rtems_blkdev_request *r = argp;                           
                                                                      
            switch (r->req)                                           
4000cb28:	c2 06 80 00 	ld  [ %i2 ], %g1                               
4000cb2c:	80 a0 60 00 	cmp  %g1, 0                                    
4000cb30:	02 80 00 07 	be  4000cb4c <ramdisk_ioctl+0x54>              
4000cb34:	80 a0 60 01 	cmp  %g1, 1                                    
4000cb38:	12 80 00 36 	bne  4000cc10 <ramdisk_ioctl+0x118>            <== NEVER TAKEN
4000cb3c:	b6 06 a0 18 	add  %i2, 0x18, %i3                            
}                                                                     
                                                                      
static int                                                            
ramdisk_write(struct ramdisk *rd, rtems_blkdev_request *req)          
{                                                                     
    uint8_t *to = rd->area;                                           
4000cb40:	f2 07 20 08 	ld  [ %i4 + 8 ], %i1                           
                                                                      
#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++)           
4000cb44:	10 80 00 15 	b  4000cb98 <ramdisk_ioctl+0xa0>               
4000cb48:	b4 10 20 00 	clr  %i2                                       
#endif                                                                
                                                                      
static int                                                            
ramdisk_read(struct ramdisk *rd, rtems_blkdev_request *req)           
{                                                                     
    uint8_t *from = rd->area;                                         
4000cb4c:	f2 07 20 08 	ld  [ %i4 + 8 ], %i1                           
#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++)           
4000cb50:	b6 06 a0 18 	add  %i2, 0x18, %i3                            
4000cb54:	b4 10 20 00 	clr  %i2                                       
4000cb58:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000cb5c:	80 a6 80 01 	cmp  %i2, %g1                                  
4000cb60:	3a 80 00 1d 	bcc,a   4000cbd4 <ramdisk_ioctl+0xdc>          
4000cb64:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
#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);
4000cb68:	d0 06 c0 00 	ld  [ %i3 ], %o0                               
4000cb6c:	d2 07 00 00 	ld  [ %i4 ], %o1                               
4000cb70:	40 00 2c 9d 	call  40017de4 <.umul>                         
4000cb74:	f0 06 e0 08 	ld  [ %i3 + 8 ], %i0                           
4000cb78:	d4 06 e0 04 	ld  [ %i3 + 4 ], %o2                           
4000cb7c:	92 06 40 08 	add  %i1, %o0, %o1                             
#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++)           
4000cb80:	b4 06 a0 01 	inc  %i2                                       
#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);
4000cb84:	90 10 00 18 	mov  %i0, %o0                                  
4000cb88:	40 00 1e 89 	call  400145ac <memcpy>                        
4000cb8c:	b6 06 e0 10 	add  %i3, 0x10, %i3                            
#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++)           
4000cb90:	10 bf ff f3 	b  4000cb5c <ramdisk_ioctl+0x64>               
4000cb94:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
                                                                      
#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++)           
4000cb98:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000cb9c:	80 a6 80 01 	cmp  %i2, %g1                                  
4000cba0:	3a 80 00 0d 	bcc,a   4000cbd4 <ramdisk_ioctl+0xdc>          
4000cba4:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
#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);
4000cba8:	d0 06 c0 00 	ld  [ %i3 ], %o0                               
4000cbac:	d2 07 00 00 	ld  [ %i4 ], %o1                               
4000cbb0:	40 00 2c 8d 	call  40017de4 <.umul>                         
4000cbb4:	b4 06 a0 01 	inc  %i2                                       
4000cbb8:	d2 06 e0 08 	ld  [ %i3 + 8 ], %o1                           
4000cbbc:	d4 06 e0 04 	ld  [ %i3 + 4 ], %o2                           
4000cbc0:	90 06 40 08 	add  %i1, %o0, %o0                             
4000cbc4:	40 00 1e 7a 	call  400145ac <memcpy>                        
4000cbc8:	b6 06 e0 10 	add  %i3, 0x10, %i3                            
                                                                      
#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++)           
4000cbcc:	10 bf ff f4 	b  4000cb9c <ramdisk_ioctl+0xa4>               
4000cbd0:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
static inline void rtems_blkdev_request_done(                         
  rtems_blkdev_request *req,                                          
  rtems_status_code status                                            
)                                                                     
{                                                                     
  (*req->done)(req, status);                                          
4000cbd4:	90 10 00 1d 	mov  %i5, %o0                                  
4000cbd8:	92 10 20 00 	clr  %o1                                       
4000cbdc:	9f c0 40 00 	call  %g1                                      
4000cbe0:	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);                      
4000cbe4:	81 c7 e0 08 	ret                                            
4000cbe8:	81 e8 00 00 	restore                                        
            }                                                         
            break;                                                    
        }                                                             
                                                                      
        case RTEMS_BLKIO_DELETED:                                     
            if (rd->free_at_delete_request) {                         
4000cbec:	c2 0f 20 0f 	ldub  [ %i4 + 0xf ], %g1                       
4000cbf0:	80 a0 60 00 	cmp  %g1, 0                                    
4000cbf4:	02 80 00 07 	be  4000cc10 <ramdisk_ioctl+0x118>             
4000cbf8:	01 00 00 00 	nop                                            
              ramdisk_free(rd);                                       
4000cbfc:	40 00 00 28 	call  4000cc9c <ramdisk_free>                  
4000cc00:	90 10 00 1c 	mov  %i4, %o0                                  
4000cc04:	30 80 00 03 	b,a   4000cc10 <ramdisk_ioctl+0x118>           
            }                                                         
            break;                                                    
                                                                      
        default:                                                      
            return rtems_blkdev_ioctl (dd, req, argp);                
4000cc08:	40 00 09 69 	call  4000f1ac <rtems_blkdev_ioctl>            
4000cc0c:	81 e8 00 00 	restore                                        
            break;                                                    
    }                                                                 
                                                                      
    errno = EINVAL;                                                   
4000cc10:	40 00 1e 39 	call  400144f4 <__errno>                       
4000cc14:	b0 10 3f ff 	mov  -1, %i0                                   
4000cc18:	82 10 20 16 	mov  0x16, %g1                                 
4000cc1c:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    return -1;                                                        
}                                                                     
4000cc20:	81 c7 e0 08 	ret                                            
4000cc24:	81 e8 00 00 	restore                                        
                                                                      

4000ef24 <ramdisk_register>: rtems_blkdev_bnum media_block_count, bool trace, const char *disk, dev_t *dev_ptr ) {
4000ef24:	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);             
4000ef28:	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;                                
4000ef2c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
  ramdisk *rd = NULL;                                                 
  dev_t dev = 0;                                                      
                                                                      
  sc = rtems_io_register_driver(0, &ramdisk_ops, &major);             
4000ef30:	13 10 00 67 	sethi  %hi(0x40019c00), %o1                    
4000ef34:	94 07 bf fc 	add  %fp, -4, %o2                              
4000ef38:	92 12 61 d0 	or  %o1, 0x1d0, %o1                            
4000ef3c:	40 00 08 24 	call  40010fcc <rtems_io_register_driver>      
4000ef40:	a0 10 20 0d 	mov  0xd, %l0                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000ef44:	80 a2 20 00 	cmp  %o0, 0                                    
4000ef48:	32 80 00 20 	bne,a   4000efc8 <ramdisk_register+0xa4>       <== NEVER TAKEN
4000ef4c:	b0 10 00 10 	mov  %l0, %i0                                  <== NOT EXECUTED
    return RTEMS_UNSATISFIED;                                         
  }                                                                   
                                                                      
  rd = ramdisk_allocate(NULL, media_block_size, media_block_count, trace);
4000ef50:	96 10 00 1a 	mov  %i2, %o3                                  
4000ef54:	92 10 00 18 	mov  %i0, %o1                                  
4000ef58:	40 00 0e 31 	call  4001281c <ramdisk_allocate>              
4000ef5c:	94 10 00 19 	mov  %i1, %o2                                  
  if (rd == NULL) {                                                   
4000ef60:	b4 92 20 00 	orcc  %o0, 0, %i2                              
4000ef64:	12 80 00 04 	bne  4000ef74 <ramdisk_register+0x50>          <== ALWAYS TAKEN
4000ef68:	fa 07 bf fc 	ld  [ %fp + -4 ], %i5                          
    rtems_io_unregister_driver(major);                                
4000ef6c:	10 80 00 11 	b  4000efb0 <ramdisk_register+0x8c>            <== NOT EXECUTED
4000ef70:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return RTEMS_UNSATISFIED;                                         
  }                                                                   
                                                                      
  dev = rtems_filesystem_make_dev_t(major, 0);                        
                                                                      
  sc = rtems_disk_create_phys(                                        
4000ef74:	f6 23 a0 5c 	st  %i3, [ %sp + 0x5c ]                        
4000ef78:	90 10 00 1d 	mov  %i5, %o0                                  
4000ef7c:	92 10 20 00 	clr  %o1                                       
4000ef80:	94 10 00 18 	mov  %i0, %o2                                  
4000ef84:	96 10 00 19 	mov  %i1, %o3                                  
4000ef88:	19 10 00 49 	sethi  %hi(0x40012400), %o4                    
4000ef8c:	9a 10 00 1a 	mov  %i2, %o5                                  
4000ef90:	7f ff db 58 	call  40005cf0 <rtems_disk_create_phys>        
4000ef94:	98 13 22 ec 	or  %o4, 0x2ec, %o4                            
    media_block_count,                                                
    ramdisk_ioctl,                                                    
    rd,                                                               
    disk                                                              
  );                                                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000ef98:	80 a2 20 00 	cmp  %o0, 0                                    
4000ef9c:	22 80 00 08 	be,a   4000efbc <ramdisk_register+0x98>        <== ALWAYS TAKEN
4000efa0:	fa 27 00 00 	st  %i5, [ %i4 ]                               
    ramdisk_free(rd);                                                 
4000efa4:	40 00 0e 3b 	call  40012890 <ramdisk_free>                  <== NOT EXECUTED
4000efa8:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
    rtems_io_unregister_driver(major);                                
4000efac:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          <== NOT EXECUTED
4000efb0:	40 00 08 62 	call  40011138 <rtems_io_unregister_driver>    <== NOT EXECUTED
4000efb4:	b0 10 00 10 	mov  %l0, %i0                                  <== NOT EXECUTED
                                                                      
    return RTEMS_UNSATISFIED;                                         
4000efb8:	30 80 00 04 	b,a   4000efc8 <ramdisk_register+0xa4>         <== NOT EXECUTED
  }                                                                   
                                                                      
  *dev_ptr = dev;                                                     
4000efbc:	c0 27 20 04 	clr  [ %i4 + 4 ]                               
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000efc0:	a0 10 20 00 	clr  %l0                                       
}                                                                     
4000efc4:	b0 10 00 10 	mov  %l0, %i0                                  
4000efc8:	81 c7 e0 08 	ret                                            
4000efcc:	81 e8 00 00 	restore                                        
                                                                      

40014e10 <read>: ssize_t read( int fd, void *buffer, size_t count ) {
40014e10:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_libio_t *iop;                                                 
                                                                      
  rtems_libio_check_fd( fd );                                         
40014e14:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
40014e18:	c2 00 63 30 	ld  [ %g1 + 0x330 ], %g1	! 40016b30 <rtems_libio_number_iops>
40014e1c:	80 a6 00 01 	cmp  %i0, %g1                                  
40014e20:	2a 80 00 06 	bcs,a   40014e38 <read+0x28>                   
40014e24:	83 2e 20 03 	sll  %i0, 3, %g1                               
40014e28:	7f ff ea fe 	call  4000fa20 <__errno>                       
40014e2c:	01 00 00 00 	nop                                            
40014e30:	10 80 00 10 	b  40014e70 <read+0x60>                        
40014e34:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  iop = rtems_libio_iop( fd );                                        
40014e38:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40014e3c:	b0 26 00 01 	sub  %i0, %g1, %i0                             
40014e40:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40014e44:	d0 00 63 30 	ld  [ %g1 + 0x330 ], %o0	! 40018330 <rtems_libio_iops>
40014e48:	90 02 00 18 	add  %o0, %i0, %o0                             
  rtems_libio_check_is_open( iop );                                   
40014e4c:	c2 02 20 10 	ld  [ %o0 + 0x10 ], %g1                        
40014e50:	80 88 61 00 	btst  0x100, %g1                               
40014e54:	02 bf ff f5 	be  40014e28 <read+0x18>                       
40014e58:	80 a6 60 00 	cmp  %i1, 0                                    
  rtems_libio_check_buffer( buffer );                                 
40014e5c:	12 80 00 08 	bne  40014e7c <read+0x6c>                      <== ALWAYS TAKEN
40014e60:	80 a6 a0 00 	cmp  %i2, 0                                    
40014e64:	7f ff ea ef 	call  4000fa20 <__errno>                       <== NOT EXECUTED
40014e68:	01 00 00 00 	nop                                            <== NOT EXECUTED
40014e6c:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
40014e70:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40014e74:	81 c7 e0 08 	ret                                            
40014e78:	91 e8 3f ff 	restore  %g0, -1, %o0                          
  rtems_libio_check_count( count );                                   
40014e7c:	02 80 00 0a 	be  40014ea4 <read+0x94>                       
40014e80:	b0 10 20 00 	clr  %i0                                       
  rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_READ, EBADF );
40014e84:	80 88 60 02 	btst  2, %g1                                   
40014e88:	02 bf ff e8 	be  40014e28 <read+0x18>                       
40014e8c:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  /*                                                                  
   *  Now process the read().                                         
   */                                                                 
  return (*iop->pathinfo.handlers->read_h)( iop, buffer, count );     
40014e90:	c2 02 20 24 	ld  [ %o0 + 0x24 ], %g1                        
40014e94:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
40014e98:	9f c0 40 00 	call  %g1                                      
40014e9c:	94 10 00 1a 	mov  %i2, %o2                                  
40014ea0:	b0 10 00 08 	mov  %o0, %i0                                  
}                                                                     
40014ea4:	81 c7 e0 08 	ret                                            
40014ea8:	81 e8 00 00 	restore                                        
                                                                      

4000554c <read_extended_partition>: * RTEMS_NO_MEMOTY if cannot allocate memory for part_desc_t strucure, * RTEMS_INTERNAL_ERROR if other error occurs. */ static rtems_status_code read_extended_partition(int fd, uint32_t start, rtems_part_desc_t *ext_part) {
4000554c:	9d e3 bf 98 	save  %sp, -104, %sp                           
    int                  i;                                           
    rtems_sector_data_t *sector = NULL;                               
40005550:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
    uint32_t             here;                                        
    uint8_t             *data;                                        
    rtems_part_desc_t   *new_part_desc;                               
    rtems_status_code    rc;                                          
                                                                      
    if ((ext_part == NULL) || (ext_part->disk_desc == NULL))          
40005554:	80 a6 a0 00 	cmp  %i2, 0                                    
40005558:	02 80 00 60 	be  400056d8 <read_extended_partition+0x18c>   <== NEVER TAKEN
4000555c:	ba 10 20 19 	mov  0x19, %i5                                 
40005560:	c2 06 a0 10 	ld  [ %i2 + 0x10 ], %g1                        
40005564:	80 a0 60 00 	cmp  %g1, 0                                    
40005568:	02 80 00 5c 	be  400056d8 <read_extended_partition+0x18c>   <== NEVER TAKEN
4000556c:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    /* get start sector of current extended partition */              
    here = ext_part->start;                                           
40005570:	f6 06 a0 04 	ld  [ %i2 + 4 ], %i3                           
    if (sector == NULL)                                               
    {                                                                 
        return RTEMS_INTERNAL_ERROR;                                  
    }                                                                 
                                                                      
    off = sector_num * RTEMS_IDE_SECTOR_SIZE;                         
40005574:	bb 2e e0 09 	sll  %i3, 9, %i5                               
    new_off = lseek(fd, off, SEEK_SET);                               
40005578:	92 10 20 00 	clr  %o1                                       
4000557c:	94 10 00 1d 	mov  %i5, %o2                                  
40005580:	40 00 04 83 	call  4000678c <lseek>                         
40005584:	96 10 20 00 	clr  %o3                                       
    if (new_off != off) {                                             
40005588:	80 a2 20 00 	cmp  %o0, 0                                    
4000558c:	32 80 00 0e 	bne,a   400055c4 <read_extended_partition+0x78><== NEVER TAKEN
40005590:	ba 10 20 1b 	mov  0x1b, %i5                                 <== NOT EXECUTED
40005594:	80 a2 40 1d 	cmp  %o1, %i5                                  
40005598:	12 80 00 0b 	bne  400055c4 <read_extended_partition+0x78>   <== NEVER TAKEN
4000559c:	ba 10 20 1b 	mov  0x1b, %i5                                 
400055a0:	90 10 00 18 	mov  %i0, %o0                                  
400055a4:	92 10 00 1b 	mov  %i3, %o1                                  
400055a8:	7f ff ff a2 	call  40005430 <get_sector.part.0>             
400055ac:	94 07 bf f8 	add  %fp, -8, %o2                              
    here = ext_part->start;                                           
                                                                      
    /* get first extended partition sector */                         
                                                                      
    rc = get_sector(fd, here, §or);                               
    if (rc != RTEMS_SUCCESSFUL)                                       
400055b0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400055b4:	02 80 00 0a 	be  400055dc <read_extended_partition+0x90>    <== ALWAYS TAKEN
400055b8:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
    {                                                                 
        if (sector)                                                   
400055bc:	10 80 00 04 	b  400055cc <read_extended_partition+0x80>     <== NOT EXECUTED
400055c0:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
400055c4:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          <== NOT EXECUTED
400055c8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
400055cc:	12 80 00 41 	bne  400056d0 <read_extended_partition+0x184>  <== NOT EXECUTED
400055d0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400055d4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400055d8:	91 e8 00 1d 	restore  %g0, %i5, %o0                         <== NOT EXECUTED
static bool                                                           
msdos_signature_check (rtems_sector_data_t *sector)                   
{                                                                     
    uint8_t *p = sector->data + RTEMS_IDE_PARTITION_MSDOS_SIGNATURE_OFFSET;
                                                                      
    return ((p[0] == RTEMS_IDE_PARTITION_MSDOS_SIGNATURE_DATA1) &&    
400055dc:	c6 0a 22 02 	ldub  [ %o0 + 0x202 ], %g3                     
400055e0:	80 a0 e0 55 	cmp  %g3, 0x55                                 
400055e4:	12 80 00 06 	bne  400055fc <read_extended_partition+0xb0>   <== NEVER TAKEN
400055e8:	84 10 20 00 	clr  %g2                                       
400055ec:	c4 0a 22 03 	ldub  [ %o0 + 0x203 ], %g2                     
400055f0:	84 18 a0 aa 	xor  %g2, 0xaa, %g2                            
400055f4:	80 a0 00 02 	cmp  %g0, %g2                                  
400055f8:	84 60 3f ff 	subx  %g0, -1, %g2                             
        if (sector)                                                   
            free(sector);                                             
        return rc;                                                    
    }                                                                 
                                                                      
    if (!msdos_signature_check(sector))                               
400055fc:	80 a0 a0 00 	cmp  %g2, 0                                    
40005600:	12 80 00 06 	bne  40005618 <read_extended_partition+0xcc>   <== ALWAYS TAKEN
40005604:	a0 02 21 d2 	add  %o0, 0x1d2, %l0                           
    {                                                                 
        free(sector);                                                 
40005608:	40 00 03 53 	call  40006354 <free>                          <== NOT EXECUTED
4000560c:	ba 10 20 19 	mov  0x19, %i5                                 <== NOT EXECUTED
        return RTEMS_INTERNAL_ERROR;                                  
40005610:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005614:	91 e8 00 1d 	restore  %g0, %i5, %o0                         <== NOT EXECUTED
40005618:	b8 10 00 1a 	mov  %i2, %i4                                  
4000561c:	a2 06 a0 10 	add  %i2, 0x10, %l1                            
40005620:	90 04 3f f0 	add  %l0, -16, %o0                             
40005624:	7f ff ff 99 	call  40005488 <data_to_part_desc.part.1>      
40005628:	92 07 bf fc 	add  %fp, -4, %o1                              
    {                                                                 
        /* if data_to_part_desc fails skip this partition             
         * and parse the next one                                     
         */                                                           
        rc = data_to_part_desc(data, &new_part_desc);                 
        if (rc != RTEMS_SUCCESSFUL)                                   
4000562c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40005630:	12 80 00 27 	bne  400056cc <read_extended_partition+0x180>  <== NEVER TAKEN
40005634:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
        {                                                             
            free(sector);                                             
            return rc;                                                
        }                                                             
                                                                      
        if (new_part_desc == NULL)                                    
40005638:	80 a2 a0 00 	cmp  %o2, 0                                    
4000563c:	22 80 00 21 	be,a   400056c0 <read_extended_partition+0x174>
40005640:	b8 07 20 04 	add  %i4, 4, %i4                               
        {                                                             
            data += RTEMS_IDE_PARTITION_DESCRIPTOR_SIZE;              
            continue;                                                 
        }                                                             
                                                                      
        ext_part->sub_part[i] = new_part_desc;                        
40005644:	d4 27 20 18 	st  %o2, [ %i4 + 0x18 ]                        
        new_part_desc->ext_part = ext_part;                           
        new_part_desc->disk_desc = ext_part->disk_desc;               
40005648:	c2 06 a0 10 	ld  [ %i2 + 0x10 ], %g1                        
 *      true if partition type is extended, false otherwise           
 */                                                                   
static bool                                                           
is_extended(uint8_t type)                                             
{                                                                     
    return ((type == EXTENDED_PARTITION) || (type == LINUX_EXTENDED));
4000564c:	c4 0a a0 01 	ldub  [ %o2 + 1 ], %g2                         
            data += RTEMS_IDE_PARTITION_DESCRIPTOR_SIZE;              
            continue;                                                 
        }                                                             
                                                                      
        ext_part->sub_part[i] = new_part_desc;                        
        new_part_desc->ext_part = ext_part;                           
40005650:	f4 22 a0 14 	st  %i2, [ %o2 + 0x14 ]                        
        new_part_desc->disk_desc = ext_part->disk_desc;               
                                                                      
        if (is_extended(new_part_desc->sys_type))                     
40005654:	84 08 a0 7f 	and  %g2, 0x7f, %g2                            
            continue;                                                 
        }                                                             
                                                                      
        ext_part->sub_part[i] = new_part_desc;                        
        new_part_desc->ext_part = ext_part;                           
        new_part_desc->disk_desc = ext_part->disk_desc;               
40005658:	c2 22 a0 10 	st  %g1, [ %o2 + 0x10 ]                        
                                                                      
        if (is_extended(new_part_desc->sys_type))                     
4000565c:	80 a0 a0 05 	cmp  %g2, 5                                    
40005660:	12 80 00 0a 	bne  40005688 <read_extended_partition+0x13c>  
40005664:	c4 02 a0 04 	ld  [ %o2 + 4 ], %g2                           
        {                                                             
            new_part_desc->log_id = EMPTY_PARTITION;                  
            new_part_desc->start += start;                            
40005668:	84 00 80 19 	add  %g2, %i1, %g2                             
        new_part_desc->ext_part = ext_part;                           
        new_part_desc->disk_desc = ext_part->disk_desc;               
                                                                      
        if (is_extended(new_part_desc->sys_type))                     
        {                                                             
            new_part_desc->log_id = EMPTY_PARTITION;                  
4000566c:	c0 2a a0 02 	clrb  [ %o2 + 2 ]                              
            new_part_desc->start += start;                            
40005670:	c4 22 a0 04 	st  %g2, [ %o2 + 4 ]                           
            read_extended_partition(fd, start, new_part_desc);        
40005674:	90 10 00 18 	mov  %i0, %o0                                  
40005678:	7f ff ff b5 	call  4000554c <read_extended_partition>       
4000567c:	92 10 00 19 	mov  %i1, %o1                                  
40005680:	10 80 00 10 	b  400056c0 <read_extended_partition+0x174>    
40005684:	b8 07 20 04 	add  %i4, 4, %i4                               
        }                                                             
        else                                                          
        {                                                             
            rtems_disk_desc_t *disk_desc = new_part_desc->disk_desc;  
            disk_desc->partitions[disk_desc->last_log_id] = new_part_desc;
40005688:	c6 00 60 24 	ld  [ %g1 + 0x24 ], %g3                        
4000568c:	88 00 e0 0a 	add  %g3, 0xa, %g4                             
40005690:	89 29 20 02 	sll  %g4, 2, %g4                               
40005694:	d4 20 40 04 	st  %o2, [ %g1 + %g4 ]                         
            new_part_desc->log_id = ++disk_desc->last_log_id;         
40005698:	86 00 e0 01 	inc  %g3                                       
4000569c:	c6 20 60 24 	st  %g3, [ %g1 + 0x24 ]                        
            new_part_desc->start += here;                             
400056a0:	82 06 c0 02 	add  %i3, %g2, %g1                             
            new_part_desc->end = new_part_desc->start + new_part_desc->size - 1;
400056a4:	c4 02 a0 08 	ld  [ %o2 + 8 ], %g2                           
        else                                                          
        {                                                             
            rtems_disk_desc_t *disk_desc = new_part_desc->disk_desc;  
            disk_desc->partitions[disk_desc->last_log_id] = new_part_desc;
            new_part_desc->log_id = ++disk_desc->last_log_id;         
            new_part_desc->start += here;                             
400056a8:	c2 22 a0 04 	st  %g1, [ %o2 + 4 ]                           
            new_part_desc->end = new_part_desc->start + new_part_desc->size - 1;
400056ac:	84 00 bf ff 	add  %g2, -1, %g2                              
        }                                                             
        else                                                          
        {                                                             
            rtems_disk_desc_t *disk_desc = new_part_desc->disk_desc;  
            disk_desc->partitions[disk_desc->last_log_id] = new_part_desc;
            new_part_desc->log_id = ++disk_desc->last_log_id;         
400056b0:	c6 2a a0 02 	stb  %g3, [ %o2 + 2 ]                          
            new_part_desc->start += here;                             
            new_part_desc->end = new_part_desc->start + new_part_desc->size - 1;
400056b4:	82 00 80 01 	add  %g2, %g1, %g1                             
400056b8:	c2 22 a0 0c 	st  %g1, [ %o2 + 0xc ]                         
400056bc:	b8 07 20 04 	add  %i4, 4, %i4                               
                                                                      
    /* read and process up to 4 logical partition descriptors */      
                                                                      
    data = sector->data + RTEMS_IDE_PARTITION_TABLE_OFFSET;           
                                                                      
    for (i = 0; i < RTEMS_IDE_PARTITION_MAX_SUB_PARTITION_NUMBER; i++)
400056c0:	80 a7 00 11 	cmp  %i4, %l1                                  
400056c4:	12 bf ff d7 	bne  40005620 <read_extended_partition+0xd4>   
400056c8:	a0 04 20 10 	add  %l0, 0x10, %l0                            
            new_part_desc->end = new_part_desc->start + new_part_desc->size - 1;
        }                                                             
        data += RTEMS_IDE_PARTITION_DESCRIPTOR_SIZE;                  
    }                                                                 
                                                                      
    free(sector);                                                     
400056cc:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
400056d0:	40 00 03 21 	call  40006354 <free>                          
400056d4:	01 00 00 00 	nop                                            
                                                                      
    return RTEMS_SUCCESSFUL;                                          
}                                                                     
400056d8:	b0 10 00 1d 	mov  %i5, %i0                                  
400056dc:	81 c7 e0 08 	ret                                            
400056e0:	81 e8 00 00 	restore                                        
                                                                      

40005944 <readv>: ssize_t readv( int fd, const struct iovec *iov, int iovcnt ) {
40005944:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
  ssize_t        total;                                               
  int            v;                                                   
  rtems_libio_t *iop;                                                 
                                                                      
  rtems_libio_check_fd( fd );                                         
40005948:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
4000594c:	c2 00 62 00 	ld  [ %g1 + 0x200 ], %g1	! 40018200 <rtems_libio_number_iops>
40005950:	80 a6 00 01 	cmp  %i0, %g1                                  
40005954:	2a 80 00 06 	bcs,a   4000596c <readv+0x28>                  
40005958:	83 2e 20 03 	sll  %i0, 3, %g1                               
4000595c:	40 00 2e 8a 	call  40011384 <__errno>                       
40005960:	01 00 00 00 	nop                                            
40005964:	10 80 00 12 	b  400059ac <readv+0x68>                       
40005968:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  iop = rtems_libio_iop( fd );                                        
4000596c:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40005970:	b0 26 00 01 	sub  %i0, %g1, %i0                             
40005974:	03 10 00 66 	sethi  %hi(0x40019800), %g1                    
40005978:	d0 00 61 f0 	ld  [ %g1 + 0x1f0 ], %o0	! 400199f0 <rtems_libio_iops>
4000597c:	90 02 00 18 	add  %o0, %i0, %o0                             
  rtems_libio_check_is_open( iop );                                   
40005980:	c2 02 20 10 	ld  [ %o0 + 0x10 ], %g1                        
40005984:	80 88 61 00 	btst  0x100, %g1                               
40005988:	02 bf ff f5 	be  4000595c <readv+0x18>                      
4000598c:	80 88 60 02 	btst  2, %g1                                   
  rtems_libio_check_permissions_with_error( iop, flags, EBADF );      
40005990:	02 bf ff f3 	be  4000595c <readv+0x18>                      <== NEVER TAKEN
40005994:	80 a6 60 00 	cmp  %i1, 0                                    
  *iopp = iop;                                                        
                                                                      
  /*                                                                  
   *  Argument validation on IO vector                                
   */                                                                 
  if ( iov == NULL )                                                  
40005998:	12 80 00 08 	bne  400059b8 <readv+0x74>                     
4000599c:	82 06 bf ff 	add  %i2, -1, %g1                              
    rtems_set_errno_and_return_minus_one( EINVAL );                   
400059a0:	40 00 2e 79 	call  40011384 <__errno>                       
400059a4:	01 00 00 00 	nop                                            
400059a8:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
400059ac:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400059b0:	81 c7 e0 08 	ret                                            
400059b4:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  if ( iovcnt <= 0 )                                                  
400059b8:	80 a0 63 ff 	cmp  %g1, 0x3ff                                
400059bc:	18 bf ff f9 	bgu  400059a0 <readv+0x5c>                     
400059c0:	09 1f ff ff 	sethi  %hi(0x7ffffc00), %g4                    
400059c4:	87 2e a0 03 	sll  %i2, 3, %g3                               
400059c8:	82 10 20 00 	clr  %g1                                       
400059cc:	96 10 20 00 	clr  %o3                                       
   */                                                                 
  total = 0;                                                          
  for ( v = 0 ; v < iovcnt ; ++v ) {                                  
    size_t len = iov[ v ].iov_len;                                    
                                                                      
    if ( len > ( size_t ) ( SSIZE_MAX - total ) ) {                   
400059d0:	88 11 23 ff 	or  %g4, 0x3ff, %g4                            
400059d4:	84 06 40 01 	add  %i1, %g1, %g2                             
   *  sum of the iov_len values in the iov array would overflow a     
   *  ssize_t.                                                        
   */                                                                 
  total = 0;                                                          
  for ( v = 0 ; v < iovcnt ; ++v ) {                                  
    size_t len = iov[ v ].iov_len;                                    
400059d8:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
                                                                      
    if ( len > ( size_t ) ( SSIZE_MAX - total ) ) {                   
400059dc:	ba 21 00 0b 	sub  %g4, %o3, %i5                             
400059e0:	80 a0 80 1d 	cmp  %g2, %i5                                  
400059e4:	18 bf ff ef 	bgu  400059a0 <readv+0x5c>                     
400059e8:	01 00 00 00 	nop                                            
      rtems_set_errno_and_return_minus_one( EINVAL );                 
    }                                                                 
                                                                      
    total += ( ssize_t ) len;                                         
                                                                      
    if ( iov[ v ].iov_base == NULL && len != 0 ) {                    
400059ec:	fa 06 40 01 	ld  [ %i1 + %g1 ], %i5                         
400059f0:	80 a7 60 00 	cmp  %i5, 0                                    
400059f4:	12 80 00 05 	bne  40005a08 <readv+0xc4>                     
400059f8:	96 02 c0 02 	add  %o3, %g2, %o3                             
400059fc:	80 a0 a0 00 	cmp  %g2, 0                                    
40005a00:	12 bf ff e8 	bne  400059a0 <readv+0x5c>                     
40005a04:	01 00 00 00 	nop                                            
40005a08:	82 00 60 08 	add  %g1, 8, %g1                               
   *  OpenGroup says that you are supposed to return EINVAL if the    
   *  sum of the iov_len values in the iov array would overflow a     
   *  ssize_t.                                                        
   */                                                                 
  total = 0;                                                          
  for ( v = 0 ; v < iovcnt ; ++v ) {                                  
40005a0c:	80 a0 40 03 	cmp  %g1, %g3                                  
40005a10:	12 bf ff f2 	bne  400059d8 <readv+0x94>                     
40005a14:	84 06 40 01 	add  %i1, %g1, %g2                             
  ssize_t        total;                                               
  rtems_libio_t *iop;                                                 
                                                                      
  total = rtems_libio_iovec_eval( fd, iov, iovcnt, LIBIO_FLAGS_READ, &iop );
                                                                      
  if ( total > 0 ) {                                                  
40005a18:	80 a2 e0 00 	cmp  %o3, 0                                    
40005a1c:	02 80 00 08 	be  40005a3c <readv+0xf8>                      
40005a20:	b0 10 20 00 	clr  %i0                                       
    total = ( *iop->pathinfo.handlers->readv_h )( iop, iov, iovcnt, total );
40005a24:	c2 02 20 24 	ld  [ %o0 + 0x24 ], %g1                        
40005a28:	92 10 00 19 	mov  %i1, %o1                                  
40005a2c:	c2 00 60 34 	ld  [ %g1 + 0x34 ], %g1                        
40005a30:	9f c0 40 00 	call  %g1                                      
40005a34:	94 10 00 1a 	mov  %i2, %o2                                  
40005a38:	b0 10 00 08 	mov  %o0, %i0                                  
  }                                                                   
                                                                      
  return total;                                                       
}                                                                     
40005a3c:	81 c7 e0 08 	ret                                            
40005a40:	81 e8 00 00 	restore                                        
                                                                      

40014f08 <realloc>: void *realloc( void *ptr, size_t size ) {
40014f08:	9d e3 bf 98 	save  %sp, -104, %sp                           
  uintptr_t old_size;                                                 
  char    *new_area;                                                  
                                                                      
  MSBUMP(realloc_calls, 1);                                           
40014f0c:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40014f10:	82 10 63 40 	or  %g1, 0x340, %g1	! 40018340 <rtems_malloc_statistics>
40014f14:	c4 00 60 10 	ld  [ %g1 + 0x10 ], %g2                        
                                                                      
void *realloc(                                                        
  void *ptr,                                                          
  size_t size                                                         
)                                                                     
{                                                                     
40014f18:	ba 10 00 18 	mov  %i0, %i5                                  
  uintptr_t old_size;                                                 
  char    *new_area;                                                  
                                                                      
  MSBUMP(realloc_calls, 1);                                           
40014f1c:	84 00 a0 01 	inc  %g2                                       
40014f20:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
40014f24:	05 10 00 62 	sethi  %hi(0x40018800), %g2                    
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if in a critical section or ISR.
   */                                                                 
                                                                      
  if (_System_state_Is_up(_System_state_Get())) {                     
40014f28:	c4 00 a0 f4 	ld  [ %g2 + 0xf4 ], %g2	! 400188f4 <_System_state_Current>
40014f2c:	80 a0 a0 02 	cmp  %g2, 2                                    
40014f30:	12 80 00 06 	bne  40014f48 <realloc+0x40>                   
40014f34:	b6 10 00 01 	mov  %g1, %i3                                  
40014f38:	c2 01 a0 10 	ld  [ %g6 + 0x10 ], %g1                        
    if (!_Thread_Dispatch_is_enabled())                               
40014f3c:	80 a0 60 00 	cmp  %g1, 0                                    
40014f40:	12 80 00 34 	bne  40015010 <realloc+0x108>                  <== NEVER TAKEN
40014f44:	b0 10 20 00 	clr  %i0                                       
  }                                                                   
                                                                      
  /*                                                                  
   * Continue with realloc().                                         
   */                                                                 
  if ( !ptr )                                                         
40014f48:	80 a7 60 00 	cmp  %i5, 0                                    
40014f4c:	12 80 00 04 	bne  40014f5c <realloc+0x54>                   
40014f50:	80 a6 60 00 	cmp  %i1, 0                                    
    return malloc( size );                                            
40014f54:	7f ff bb 03 	call  40003b60 <malloc>                        
40014f58:	91 e8 00 19 	restore  %g0, %i1, %o0                         
                                                                      
  if ( !size ) {                                                      
40014f5c:	12 80 00 06 	bne  40014f74 <realloc+0x6c>                   <== ALWAYS TAKEN
40014f60:	39 10 00 5a 	sethi  %hi(0x40016800), %i4                    
    free( ptr );                                                      
40014f64:	7f ff ba 2a 	call  4000380c <free>                          <== NOT EXECUTED
40014f68:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40014f6c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40014f70:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
    return (void *) 0;                                                
  }                                                                   
                                                                      
  if ( !_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, ptr, &old_size) ) {
40014f74:	d0 07 23 28 	ld  [ %i4 + 0x328 ], %o0                       
40014f78:	92 10 00 1d 	mov  %i5, %o1                                  
40014f7c:	40 00 00 51 	call  400150c0 <_Protected_heap_Get_block_size>
40014f80:	94 07 bf fc 	add  %fp, -4, %o2                              
40014f84:	80 a2 20 00 	cmp  %o0, 0                                    
40014f88:	12 80 00 08 	bne  40014fa8 <realloc+0xa0>                   
40014f8c:	d0 07 23 28 	ld  [ %i4 + 0x328 ], %o0                       
    errno = EINVAL;                                                   
40014f90:	7f ff ea a4 	call  4000fa20 <__errno>                       
40014f94:	b0 10 20 00 	clr  %i0                                       
40014f98:	82 10 20 16 	mov  0x16, %g1                                 
40014f9c:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40014fa0:	81 c7 e0 08 	ret                                            
40014fa4:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  /*                                                                  
   *  Now resize it.                                                  
   */                                                                 
  if ( _Protected_heap_Resize_block( RTEMS_Malloc_Heap, ptr, size ) ) {
40014fa8:	92 10 00 1d 	mov  %i5, %o1                                  
40014fac:	94 10 00 19 	mov  %i1, %o2                                  
40014fb0:	40 00 00 51 	call  400150f4 <_Protected_heap_Resize_block>  
40014fb4:	b0 10 00 1d 	mov  %i5, %i0                                  
40014fb8:	80 a2 20 00 	cmp  %o0, 0                                    
40014fbc:	12 80 00 18 	bne  4001501c <realloc+0x114>                  
40014fc0:	01 00 00 00 	nop                                            
   *  There used to be a free on this error case but it is wrong to   
   *  free the memory per OpenGroup Single UNIX Specification V2      
   *  and the C Standard.                                             
   */                                                                 
                                                                      
  new_area = malloc( size );                                          
40014fc4:	7f ff ba e7 	call  40003b60 <malloc>                        
40014fc8:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
  MSBUMP(malloc_calls, (uint32_t) -1);   /* subtract off the malloc */
40014fcc:	c2 06 e0 04 	ld  [ %i3 + 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 );                                          
40014fd0:	b8 10 00 08 	mov  %o0, %i4                                  
                                                                      
  MSBUMP(malloc_calls, (uint32_t) -1);   /* subtract off the malloc */
40014fd4:	82 00 7f ff 	add  %g1, -1, %g1                              
                                                                      
  if ( !new_area ) {                                                  
40014fd8:	80 a2 20 00 	cmp  %o0, 0                                    
40014fdc:	02 80 00 0f 	be  40015018 <realloc+0x110>                   
40014fe0:	c2 26 e0 04 	st  %g1, [ %i3 + 4 ]                           
    return (void *) 0;                                                
  }                                                                   
                                                                      
  memcpy( new_area, ptr, (size < old_size) ? size : old_size );       
40014fe4:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40014fe8:	80 a6 40 01 	cmp  %i1, %g1                                  
40014fec:	08 80 00 03 	bleu  40014ff8 <realloc+0xf0>                  <== NEVER TAKEN
40014ff0:	94 10 00 19 	mov  %i1, %o2                                  
40014ff4:	94 10 00 01 	mov  %g1, %o2                                  
40014ff8:	92 10 00 1d 	mov  %i5, %o1                                  
40014ffc:	7f ff ec 6f 	call  400101b8 <memcpy>                        
40015000:	90 10 00 1c 	mov  %i4, %o0                                  
  free( ptr );                                                        
40015004:	90 10 00 1d 	mov  %i5, %o0                                  
40015008:	7f ff ba 01 	call  4000380c <free>                          
4001500c:	b0 10 00 1c 	mov  %i4, %i0                                  
                                                                      
  return new_area;                                                    
40015010:	81 c7 e0 08 	ret                                            
40015014:	81 e8 00 00 	restore                                        
40015018:	b0 10 20 00 	clr  %i0                                       
                                                                      
}                                                                     
4001501c:	81 c7 e0 08 	ret                                            
40015020:	81 e8 00 00 	restore                                        
                                                                      

40007e54 <rtems_aio_enqueue>: * errno - otherwise */ int rtems_aio_enqueue (rtems_aio_request *req) {
40007e54:	9d e3 bf 78 	save  %sp, -136, %sp                           
  struct sched_param param;                                           
                                                                      
  /* The queue should be initialized */                               
  AIO_assert (aio_request_queue.initialized == AIO_QUEUE_INITIALIZED);
                                                                      
  result = pthread_mutex_lock (&aio_request_queue.mutex);             
40007e58:	3b 10 00 6a 	sethi  %hi(0x4001a800), %i5                    
40007e5c:	90 17 60 88 	or  %i5, 0x88, %o0	! 4001a888 <aio_request_queue>
40007e60:	40 00 02 c8 	call  40008980 <pthread_mutex_lock>            
40007e64:	a0 10 00 1d 	mov  %i5, %l0                                  
  if (result != 0) {                                                  
40007e68:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40007e6c:	02 80 00 06 	be  40007e84 <rtems_aio_enqueue+0x30>          <== ALWAYS TAKEN
40007e70:	90 10 00 18 	mov  %i0, %o0                                  
    free (req);                                                       
40007e74:	7f ff f0 09 	call  40003e98 <free>                          <== NOT EXECUTED
40007e78:	b0 10 00 1c 	mov  %i4, %i0                                  <== NOT EXECUTED
    return result;                                                    
40007e7c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40007e80:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  /* _POSIX_PRIORITIZED_IO and _POSIX_PRIORITY_SCHEDULING are defined,
     we can use aio_reqprio to lower the priority of the request */   
  pthread_getschedparam (pthread_self(), &policy, ¶m);            
40007e84:	40 00 04 d7 	call  400091e0 <pthread_self>                  
40007e88:	ba 17 60 88 	or  %i5, 0x88, %i5                             
40007e8c:	92 07 bf e0 	add  %fp, -32, %o1                             
40007e90:	40 00 03 e8 	call  40008e30 <pthread_getschedparam>         
40007e94:	94 07 bf e4 	add  %fp, -28, %o2                             
                                                                      
  req->caller_thread = pthread_self ();                               
40007e98:	40 00 04 d2 	call  400091e0 <pthread_self>                  
40007e9c:	b8 10 00 1d 	mov  %i5, %i4                                  
  req->priority = param.sched_priority - req->aiocbp->aio_reqprio;    
40007ea0:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
40007ea4:	c6 07 bf e4 	ld  [ %fp + -28 ], %g3                         
40007ea8:	c4 00 60 18 	ld  [ %g1 + 0x18 ], %g2                        
                                                                      
  /* _POSIX_PRIORITIZED_IO and _POSIX_PRIORITY_SCHEDULING are defined,
     we can use aio_reqprio to lower the priority of the request */   
  pthread_getschedparam (pthread_self(), &policy, ¶m);            
                                                                      
  req->caller_thread = pthread_self ();                               
40007eac:	d0 26 20 10 	st  %o0, [ %i0 + 0x10 ]                        
  req->priority = param.sched_priority - req->aiocbp->aio_reqprio;    
40007eb0:	84 20 c0 02 	sub  %g3, %g2, %g2                             
40007eb4:	c4 26 20 0c 	st  %g2, [ %i0 + 0xc ]                         
  req->policy = policy;                                               
40007eb8:	c4 07 bf e0 	ld  [ %fp + -32 ], %g2                         
40007ebc:	c4 26 20 08 	st  %g2, [ %i0 + 8 ]                           
  req->aiocbp->error_code = EINPROGRESS;                              
40007ec0:	84 10 20 77 	mov  0x77, %g2                                 
40007ec4:	c4 20 60 34 	st  %g2, [ %g1 + 0x34 ]                        
  req->aiocbp->return_value = 0;                                      
                                                                      
  if ((aio_request_queue.idle_threads == 0) &&                        
40007ec8:	c4 07 60 74 	ld  [ %i5 + 0x74 ], %g2                        
                                                                      
  req->caller_thread = pthread_self ();                               
  req->priority = param.sched_priority - req->aiocbp->aio_reqprio;    
  req->policy = policy;                                               
  req->aiocbp->error_code = EINPROGRESS;                              
  req->aiocbp->return_value = 0;                                      
40007ecc:	c0 20 60 38 	clr  [ %g1 + 0x38 ]                            
                                                                      
  if ((aio_request_queue.idle_threads == 0) &&                        
40007ed0:	80 a0 a0 00 	cmp  %g2, 0                                    
40007ed4:	12 80 00 33 	bne  40007fa0 <rtems_aio_enqueue+0x14c>        <== NEVER TAKEN
40007ed8:	d2 00 40 00 	ld  [ %g1 ], %o1                               
40007edc:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
40007ee0:	80 a0 60 04 	cmp  %g1, 4                                    
40007ee4:	14 80 00 30 	bg  40007fa4 <rtems_aio_enqueue+0x150>         
40007ee8:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    
      aio_request_queue.active_threads < AIO_MAX_THREADS)             
    /* we still have empty places on the active_threads chain */      
    {                                                                 
      chain = &aio_request_queue.work_req;                            
      r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
40007eec:	90 07 60 54 	add  %i5, 0x54, %o0                            
40007ef0:	7f ff ff 7e 	call  40007ce8 <rtems_aio_search_fd>           
40007ef4:	94 10 20 01 	mov  1, %o2                                    
                                                                      
      if (r_chain->new_fd == 1) {                                     
40007ef8:	c2 02 20 18 	ld  [ %o0 + 0x18 ], %g1                        
  if ((aio_request_queue.idle_threads == 0) &&                        
      aio_request_queue.active_threads < AIO_MAX_THREADS)             
    /* we still have empty places on the active_threads chain */      
    {                                                                 
      chain = &aio_request_queue.work_req;                            
      r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
40007efc:	b8 10 00 08 	mov  %o0, %i4                                  
                                                                      
      if (r_chain->new_fd == 1) {                                     
40007f00:	80 a0 60 01 	cmp  %g1, 1                                    
40007f04:	b2 02 20 08 	add  %o0, 8, %i1                               
40007f08:	b6 02 20 1c 	add  %o0, 0x1c, %i3                            
40007f0c:	12 80 00 1c 	bne  40007f7c <rtems_aio_enqueue+0x128>        
40007f10:	b4 02 20 20 	add  %o0, 0x20, %i2                            
RTEMS_INLINE_ROUTINE void _Chain_Prepend(                             
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  _Chain_Insert(_Chain_Head(the_chain), the_node);                    
40007f14:	92 10 00 18 	mov  %i0, %o1                                  
40007f18:	40 00 09 3c 	call  4000a408 <_Chain_Insert>                 
40007f1c:	90 10 00 19 	mov  %i1, %o0                                  
	rtems_chain_prepend (&r_chain->perfd, &req->next_prio);              
	r_chain->new_fd = 0;                                                 
	pthread_mutex_init (&r_chain->mutex, NULL);                          
40007f20:	92 10 20 00 	clr  %o1                                       
      chain = &aio_request_queue.work_req;                            
      r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);
                                                                      
      if (r_chain->new_fd == 1) {                                     
	rtems_chain_prepend (&r_chain->perfd, &req->next_prio);              
	r_chain->new_fd = 0;                                                 
40007f24:	c0 27 20 18 	clr  [ %i4 + 0x18 ]                            
	pthread_mutex_init (&r_chain->mutex, NULL);                          
40007f28:	40 00 02 3b 	call  40008814 <pthread_mutex_init>            
40007f2c:	90 10 00 1b 	mov  %i3, %o0                                  
	pthread_cond_init (&r_chain->cond, NULL);                            
40007f30:	92 10 20 00 	clr  %o1                                       
40007f34:	40 00 01 07 	call  40008350 <pthread_cond_init>             
40007f38:	90 10 00 1a 	mov  %i2, %o0                                  
	                                                                     
	AIO_printf ("New thread \n");                                        
	result = pthread_create (&thid, &aio_request_queue.attr,             
40007f3c:	90 07 bf dc 	add  %fp, -36, %o0                             
40007f40:	92 07 60 08 	add  %i5, 8, %o1                               
40007f44:	15 10 00 1e 	sethi  %hi(0x40007800), %o2                    
40007f48:	96 10 00 1c 	mov  %i4, %o3                                  
40007f4c:	40 00 03 20 	call  40008bcc <pthread_create>                
40007f50:	94 12 a1 98 	or  %o2, 0x198, %o2                            
				 rtems_aio_handle, (void *) r_chain);                             
	if (result != 0) {                                                   
40007f54:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40007f58:	22 80 00 06 	be,a   40007f70 <rtems_aio_enqueue+0x11c>      <== ALWAYS TAKEN
40007f5c:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
	  pthread_mutex_unlock (&aio_request_queue.mutex);                   
40007f60:	40 00 02 a7 	call  400089fc <pthread_mutex_unlock>          <== NOT EXECUTED
40007f64:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
	  return result;                                                     
40007f68:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40007f6c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
	}                                                                    
	++aio_request_queue.active_threads;                                  
40007f70:	82 00 60 01 	inc  %g1                                       
40007f74:	10 80 00 3d 	b  40008068 <rtems_aio_enqueue+0x214>          
40007f78:	c2 27 60 70 	st  %g1, [ %i5 + 0x70 ]                        
      }                                                               
      else {                                                          
	/* put request in the fd chain it belongs to */                      
	pthread_mutex_lock (&r_chain->mutex);                                
40007f7c:	40 00 02 81 	call  40008980 <pthread_mutex_lock>            
40007f80:	90 10 00 1b 	mov  %i3, %o0                                  
	rtems_aio_insert_prio (&r_chain->perfd, req);                        
40007f84:	90 10 00 19 	mov  %i1, %o0                                  
40007f88:	7f ff fe 6d 	call  4000793c <rtems_aio_insert_prio>         
40007f8c:	92 10 00 18 	mov  %i0, %o1                                  
	pthread_cond_signal (&r_chain->cond);                                
40007f90:	40 00 01 1c 	call  40008400 <pthread_cond_signal>           
40007f94:	90 10 00 1a 	mov  %i2, %o0                                  
	pthread_mutex_unlock (&r_chain->mutex);                              
40007f98:	10 80 00 12 	b  40007fe0 <rtems_aio_enqueue+0x18c>          
40007f9c:	90 10 00 1b 	mov  %i3, %o0                                  
  else                                                                
    {                                                                 
      /* the maximum number of threads has been already created       
	 even though some of them might be idle.                             
	 The request belongs to one of the active fd chain */                
      r_chain = rtems_aio_search_fd (&aio_request_queue.work_req,     
40007fa0:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    <== NOT EXECUTED
40007fa4:	94 10 20 00 	clr  %o2                                       
40007fa8:	7f ff ff 50 	call  40007ce8 <rtems_aio_search_fd>           
40007fac:	90 12 20 dc 	or  %o0, 0xdc, %o0                             
				     req->aiocbp->aio_fildes, 0);                                 
      if (r_chain != NULL)                                            
40007fb0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40007fb4:	22 80 00 0f 	be,a   40007ff0 <rtems_aio_enqueue+0x19c>      
40007fb8:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
	{                                                                    
	  pthread_mutex_lock (&r_chain->mutex);                              
40007fbc:	b8 07 60 1c 	add  %i5, 0x1c, %i4                            
40007fc0:	40 00 02 70 	call  40008980 <pthread_mutex_lock>            
40007fc4:	90 10 00 1c 	mov  %i4, %o0                                  
	  rtems_aio_insert_prio (&r_chain->perfd, req);                      
40007fc8:	90 07 60 08 	add  %i5, 8, %o0                               
40007fcc:	7f ff fe 5c 	call  4000793c <rtems_aio_insert_prio>         
40007fd0:	92 10 00 18 	mov  %i0, %o1                                  
	  pthread_cond_signal (&r_chain->cond);                              
40007fd4:	40 00 01 0b 	call  40008400 <pthread_cond_signal>           
40007fd8:	90 07 60 20 	add  %i5, 0x20, %o0                            
	  pthread_mutex_unlock (&r_chain->mutex);                            
40007fdc:	90 10 00 1c 	mov  %i4, %o0                                  
40007fe0:	40 00 02 87 	call  400089fc <pthread_mutex_unlock>          
40007fe4:	01 00 00 00 	nop                                            
40007fe8:	10 80 00 21 	b  4000806c <rtems_aio_enqueue+0x218>          
40007fec:	90 14 20 88 	or  %l0, 0x88, %o0                             
	                                                                     
	} else {                                                             
                                                                      
	/* or to the idle chain */                                           
	chain = &aio_request_queue.idle_req;                                 
	r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);   
40007ff0:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    
40007ff4:	d2 00 40 00 	ld  [ %g1 ], %o1                               
40007ff8:	90 12 20 e8 	or  %o0, 0xe8, %o0                             
40007ffc:	7f ff ff 3b 	call  40007ce8 <rtems_aio_search_fd>           
40008000:	94 10 20 01 	mov  1, %o2                                    
                                                                      
	if (r_chain->new_fd == 1) {                                          
40008004:	c2 02 20 18 	ld  [ %o0 + 0x18 ], %g1                        
	                                                                     
	} else {                                                             
                                                                      
	/* or to the idle chain */                                           
	chain = &aio_request_queue.idle_req;                                 
	r_chain = rtems_aio_search_fd (chain, req->aiocbp->aio_fildes, 1);   
40008008:	ba 10 00 08 	mov  %o0, %i5                                  
4000800c:	92 10 00 18 	mov  %i0, %o1                                  
                                                                      
	if (r_chain->new_fd == 1) {                                          
40008010:	80 a0 60 01 	cmp  %g1, 1                                    
40008014:	12 80 00 0d 	bne  40008048 <rtems_aio_enqueue+0x1f4>        
40008018:	90 02 20 08 	add  %o0, 8, %o0                               
4000801c:	40 00 08 fb 	call  4000a408 <_Chain_Insert>                 
40008020:	01 00 00 00 	nop                                            
	  /* If this is a new fd chain we signal the idle threads that       
	     might be waiting for requests */                                
	  AIO_printf (" New chain on waiting queue \n ");                    
	  rtems_chain_prepend (&r_chain->perfd, &req->next_prio);            
	  r_chain->new_fd = 0;                                               
	  pthread_mutex_init (&r_chain->mutex, NULL);                        
40008024:	90 07 60 1c 	add  %i5, 0x1c, %o0                            
	if (r_chain->new_fd == 1) {                                          
	  /* If this is a new fd chain we signal the idle threads that       
	     might be waiting for requests */                                
	  AIO_printf (" New chain on waiting queue \n ");                    
	  rtems_chain_prepend (&r_chain->perfd, &req->next_prio);            
	  r_chain->new_fd = 0;                                               
40008028:	c0 27 60 18 	clr  [ %i5 + 0x18 ]                            
	  pthread_mutex_init (&r_chain->mutex, NULL);                        
4000802c:	40 00 01 fa 	call  40008814 <pthread_mutex_init>            
40008030:	92 10 20 00 	clr  %o1                                       
	  pthread_cond_init (&r_chain->cond, NULL);                          
40008034:	90 07 60 20 	add  %i5, 0x20, %o0                            
40008038:	40 00 00 c6 	call  40008350 <pthread_cond_init>             
4000803c:	92 10 20 00 	clr  %o1                                       
40008040:	10 80 00 05 	b  40008054 <rtems_aio_enqueue+0x200>          
40008044:	c2 07 20 74 	ld  [ %i4 + 0x74 ], %g1                        
	} else                                                               
	  /* just insert the request in the existing fd chain */             
	  rtems_aio_insert_prio (&r_chain->perfd, req);                      
40008048:	7f ff fe 3d 	call  4000793c <rtems_aio_insert_prio>         
4000804c:	01 00 00 00 	nop                                            
	if (aio_request_queue.idle_threads > 0)                              
40008050:	c2 07 20 74 	ld  [ %i4 + 0x74 ], %g1                        
40008054:	80 a0 60 00 	cmp  %g1, 0                                    
40008058:	04 80 00 05 	ble  4000806c <rtems_aio_enqueue+0x218>        <== ALWAYS TAKEN
4000805c:	90 14 20 88 	or  %l0, 0x88, %o0                             
	  pthread_cond_signal (&aio_request_queue.new_req);                  
40008060:	40 00 00 e8 	call  40008400 <pthread_cond_signal>           <== NOT EXECUTED
40008064:	90 07 20 04 	add  %i4, 4, %o0                               <== NOT EXECUTED
      }                                                               
    }                                                                 
                                                                      
  pthread_mutex_unlock (&aio_request_queue.mutex);                    
40008068:	90 14 20 88 	or  %l0, 0x88, %o0                             
4000806c:	40 00 02 64 	call  400089fc <pthread_mutex_unlock>          
40008070:	b0 10 20 00 	clr  %i0                                       
  return 0;                                                           
}                                                                     
40008074:	81 c7 e0 08 	ret                                            
40008078:	81 e8 00 00 	restore                                        
                                                                      

40007998 <rtems_aio_handle>: * NULL - if error */ static void * rtems_aio_handle (void *arg) {
40007998:	9d e3 bf 78 	save  %sp, -136, %sp                           
      struct timespec timeout;                                        
                                                                      
      AIO_printf ("Chain is empty [WQ], wait for work\n");            
                                                                      
      pthread_mutex_unlock (&r_chain->mutex);                         
      pthread_mutex_lock (&aio_request_queue.mutex);                  
4000799c:	3b 10 00 6a 	sethi  %hi(0x4001a800), %i5                    
400079a0:	ba 17 60 88 	or  %i5, 0x88, %i5	! 4001a888 <aio_request_queue>
	                                                                     
	  }                                                                  
	}                                                                    
      /* If there was a request added in the initial fd chain then release
	 the mutex and process it */                                         
      pthread_mutex_unlock (&aio_request_queue.mutex);                
400079a4:	b4 10 00 1d 	mov  %i5, %i2                                  
	    pthread_cond_destroy (&r_chain->cond);                           
	    free (r_chain);                                                  
	                                                                     
	    /* If the idle chain is empty sleep for 3 seconds and wait for a 
	       signal. The thread now becomes idle. */                       
	    if (rtems_chain_is_empty (&aio_request_queue.idle_req)) {        
400079a8:	b2 07 60 64 	add  %i5, 0x64, %i1                            
  rtems_chain_node *node;                                             
                                                                      
  node = rtems_chain_first (work_req_chain);                          
  temp = (rtems_aio_request_chain *) node;                            
                                                                      
  while (temp->fildes < r_chain->fildes &&                            
400079ac:	a0 07 60 58 	add  %i5, 0x58, %l0                            
    /* acquire the mutex of the current fd chain.                     
       we don't need to lock the queue mutex since we can             
       add requests to idle fd chains or even active ones             
       if the working request has been extracted from the             
       chain */                                                       
    result = pthread_mutex_lock (&r_chain->mutex);                    
400079b0:	b6 06 20 1c 	add  %i0, 0x1c, %i3                            
400079b4:	40 00 03 f3 	call  40008980 <pthread_mutex_lock>            
400079b8:	90 10 00 1b 	mov  %i3, %o0                                  
    if (result != 0)                                                  
400079bc:	80 a2 20 00 	cmp  %o0, 0                                    
400079c0:	12 80 00 93 	bne  40007c0c <rtems_aio_handle+0x274>         <== NEVER TAKEN
400079c4:	82 06 20 0c 	add  %i0, 0xc, %g1                             
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
400079c8:	f8 06 20 08 	ld  [ %i0 + 8 ], %i4                           
                                                                      
    /* If the locked chain is not empty, take the first               
       request extract it, unlock the chain and process               
       the request, in this way the user can supply more              
       requests to this fd chain */                                   
    if (!rtems_chain_is_empty (chain)) {                              
400079cc:	80 a7 00 01 	cmp  %i4, %g1                                  
400079d0:	02 80 00 3b 	be  40007abc <rtems_aio_handle+0x124>          
400079d4:	01 00 00 00 	nop                                            
      node = rtems_chain_first (chain);                               
      req = (rtems_aio_request *) node;                               
                                                                      
      /* See _POSIX_PRIORITIZE_IO and _POSIX_PRIORITY_SCHEDULING      
	 discussion in rtems_aio_enqueue () */                               
      pthread_getschedparam (pthread_self(), &policy, ¶m);        
400079d8:	40 00 06 02 	call  400091e0 <pthread_self>                  
400079dc:	01 00 00 00 	nop                                            
400079e0:	92 07 bf d8 	add  %fp, -40, %o1                             
400079e4:	40 00 05 13 	call  40008e30 <pthread_getschedparam>         
400079e8:	94 07 bf e4 	add  %fp, -28, %o2                             
      param.sched_priority = req->priority;                           
400079ec:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
      pthread_setschedparam (pthread_self(), req->policy, ¶m);    
400079f0:	40 00 05 fc 	call  400091e0 <pthread_self>                  
400079f4:	c2 27 bf e4 	st  %g1, [ %fp + -28 ]                         
400079f8:	d2 07 20 08 	ld  [ %i4 + 8 ], %o1                           
400079fc:	40 00 05 fc 	call  400091ec <pthread_setschedparam>         
40007a00:	94 07 bf e4 	add  %fp, -28, %o2                             
#else                                                                 
RTEMS_INLINE_ROUTINE void rtems_chain_extract(                        
  rtems_chain_node *the_node                                          
)                                                                     
{                                                                     
  _Chain_Extract( the_node );                                         
40007a04:	40 00 0a 68 	call  4000a3a4 <_Chain_Extract>                
40007a08:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
      rtems_chain_extract (node);                                     
                                                                      
      pthread_mutex_unlock (&r_chain->mutex);                         
40007a0c:	40 00 03 fc 	call  400089fc <pthread_mutex_unlock>          
40007a10:	90 10 00 1b 	mov  %i3, %o0                                  
                                                                      
      switch (req->aiocbp->aio_lio_opcode) {                          
40007a14:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
40007a18:	c4 00 60 30 	ld  [ %g1 + 0x30 ], %g2                        
40007a1c:	80 a0 a0 02 	cmp  %g2, 2                                    
40007a20:	22 80 00 10 	be,a   40007a60 <rtems_aio_handle+0xc8>        
40007a24:	c4 18 60 08 	ldd  [ %g1 + 8 ], %g2                          
40007a28:	80 a0 a0 03 	cmp  %g2, 3                                    
40007a2c:	02 80 00 15 	be  40007a80 <rtems_aio_handle+0xe8>           <== NEVER TAKEN
40007a30:	80 a0 a0 01 	cmp  %g2, 1                                    
40007a34:	32 80 00 19 	bne,a   40007a98 <rtems_aio_handle+0x100>      <== NEVER TAKEN
40007a38:	f8 07 20 14 	ld  [ %i4 + 0x14 ], %i4                        <== NOT EXECUTED
      case LIO_READ:                                                  
	AIO_printf ("read\n");                                               
        result = pread (req->aiocbp->aio_fildes,                      
40007a3c:	c4 18 60 08 	ldd  [ %g1 + 8 ], %g2                          
40007a40:	d0 00 40 00 	ld  [ %g1 ], %o0                               
40007a44:	d2 00 60 10 	ld  [ %g1 + 0x10 ], %o1                        
40007a48:	d4 00 60 14 	ld  [ %g1 + 0x14 ], %o2                        
40007a4c:	96 10 00 02 	mov  %g2, %o3                                  
40007a50:	40 00 2a 7c 	call  40012440 <pread>                         
40007a54:	98 10 00 03 	mov  %g3, %o4                                  
                        (void *) req->aiocbp->aio_buf,                
                        req->aiocbp->aio_nbytes, req->aiocbp->aio_offset);
        break;                                                        
40007a58:	10 80 00 0d 	b  40007a8c <rtems_aio_handle+0xf4>            
40007a5c:	80 a2 3f ff 	cmp  %o0, -1                                   
                                                                      
      case LIO_WRITE:                                                 
	AIO_printf ("write\n");                                              
        result = pwrite (req->aiocbp->aio_fildes,                     
40007a60:	d0 00 40 00 	ld  [ %g1 ], %o0                               
40007a64:	d2 00 60 10 	ld  [ %g1 + 0x10 ], %o1                        
40007a68:	d4 00 60 14 	ld  [ %g1 + 0x14 ], %o2                        
40007a6c:	96 10 00 02 	mov  %g2, %o3                                  
40007a70:	40 00 2a b0 	call  40012530 <pwrite>                        
40007a74:	98 10 00 03 	mov  %g3, %o4                                  
                         (void *) req->aiocbp->aio_buf,               
                         req->aiocbp->aio_nbytes, req->aiocbp->aio_offset);
        break;                                                        
40007a78:	10 80 00 05 	b  40007a8c <rtems_aio_handle+0xf4>            
40007a7c:	80 a2 3f ff 	cmp  %o0, -1                                   
                                                                      
      case LIO_SYNC:                                                  
	AIO_printf ("sync\n");                                               
      	result = fsync (req->aiocbp->aio_fildes);                      
40007a80:	40 00 1b a6 	call  4000e918 <fsync>                         <== NOT EXECUTED
40007a84:	d0 00 40 00 	ld  [ %g1 ], %o0                               <== NOT EXECUTED
      	break;                                                         
                                                                      
      default:                                                        
        result = -1;                                                  
      }                                                               
      if (result == -1) {                                             
40007a88:	80 a2 3f ff 	cmp  %o0, -1                                   <== NOT EXECUTED
40007a8c:	32 80 00 09 	bne,a   40007ab0 <rtems_aio_handle+0x118>      <== ALWAYS TAKEN
40007a90:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
        req->aiocbp->return_value = -1;                               
40007a94:	f8 07 20 14 	ld  [ %i4 + 0x14 ], %i4                        <== NOT EXECUTED
40007a98:	82 10 3f ff 	mov  -1, %g1                                   <== NOT EXECUTED
	req->aiocbp->error_code = errno;                                     
40007a9c:	40 00 29 84 	call  400120ac <__errno>                       <== NOT EXECUTED
40007aa0:	c2 27 20 38 	st  %g1, [ %i4 + 0x38 ]                        <== NOT EXECUTED
40007aa4:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
40007aa8:	10 bf ff c2 	b  400079b0 <rtems_aio_handle+0x18>            <== NOT EXECUTED
40007aac:	c2 27 20 34 	st  %g1, [ %i4 + 0x34 ]                        <== NOT EXECUTED
      } else {                                                        
        req->aiocbp->return_value = result;                           
40007ab0:	d0 20 60 38 	st  %o0, [ %g1 + 0x38 ]                        
        req->aiocbp->error_code = 0;                                  
40007ab4:	10 bf ff bf 	b  400079b0 <rtems_aio_handle+0x18>            
40007ab8:	c0 20 60 34 	clr  [ %g1 + 0x34 ]                            
                                                                      
      struct timespec timeout;                                        
                                                                      
      AIO_printf ("Chain is empty [WQ], wait for work\n");            
                                                                      
      pthread_mutex_unlock (&r_chain->mutex);                         
40007abc:	40 00 03 d0 	call  400089fc <pthread_mutex_unlock>          
40007ac0:	90 10 00 1b 	mov  %i3, %o0                                  
      pthread_mutex_lock (&aio_request_queue.mutex);                  
40007ac4:	40 00 03 af 	call  40008980 <pthread_mutex_lock>            
40007ac8:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
      if (rtems_chain_is_empty (chain))                               
40007acc:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
40007ad0:	80 a0 40 1c 	cmp  %g1, %i4                                  
40007ad4:	12 80 00 4a 	bne  40007bfc <rtems_aio_handle+0x264>         <== NEVER TAKEN
40007ad8:	92 07 bf dc 	add  %fp, -36, %o1                             
	{                                                                    
	  clock_gettime (CLOCK_REALTIME, &timeout);                          
40007adc:	40 00 01 b2 	call  400081a4 <clock_gettime>                 
40007ae0:	90 10 20 01 	mov  1, %o0                                    
	  timeout.tv_sec += 3;                                               
40007ae4:	c2 07 bf dc 	ld  [ %fp + -36 ], %g1                         
	  timeout.tv_nsec = 0;                                               
40007ae8:	c0 27 bf e0 	clr  [ %fp + -32 ]                             
      pthread_mutex_lock (&aio_request_queue.mutex);                  
                                                                      
      if (rtems_chain_is_empty (chain))                               
	{                                                                    
	  clock_gettime (CLOCK_REALTIME, &timeout);                          
	  timeout.tv_sec += 3;                                               
40007aec:	82 00 60 03 	add  %g1, 3, %g1                               
	  timeout.tv_nsec = 0;                                               
	  result = pthread_cond_timedwait (&r_chain->cond,                   
40007af0:	b8 06 20 20 	add  %i0, 0x20, %i4                            
      pthread_mutex_lock (&aio_request_queue.mutex);                  
                                                                      
      if (rtems_chain_is_empty (chain))                               
	{                                                                    
	  clock_gettime (CLOCK_REALTIME, &timeout);                          
	  timeout.tv_sec += 3;                                               
40007af4:	c2 27 bf dc 	st  %g1, [ %fp + -36 ]                         
	  timeout.tv_nsec = 0;                                               
	  result = pthread_cond_timedwait (&r_chain->cond,                   
40007af8:	90 10 00 1c 	mov  %i4, %o0                                  
40007afc:	92 10 00 1d 	mov  %i5, %o1                                  
40007b00:	40 00 02 5d 	call  40008474 <pthread_cond_timedwait>        
40007b04:	94 07 bf dc 	add  %fp, -36, %o2                             
					   &aio_request_queue.mutex,                                     
					   &timeout);                                                    
                                                                      
	  /* If no requests were added to the chain we delete the fd chain from
	     the queue and start working with idle fd chains */              
	  if (result == ETIMEDOUT) {                                         
40007b08:	80 a2 20 74 	cmp  %o0, 0x74                                 
40007b0c:	12 80 00 3c 	bne  40007bfc <rtems_aio_handle+0x264>         <== NEVER TAKEN
40007b10:	01 00 00 00 	nop                                            
40007b14:	40 00 0a 24 	call  4000a3a4 <_Chain_Extract>                
40007b18:	90 10 00 18 	mov  %i0, %o0                                  
	    rtems_chain_extract (&r_chain->next_fd);                         
	    pthread_mutex_destroy (&r_chain->mutex);                         
40007b1c:	40 00 02 e6 	call  400086b4 <pthread_mutex_destroy>         
40007b20:	90 10 00 1b 	mov  %i3, %o0                                  
	    pthread_cond_destroy (&r_chain->cond);                           
40007b24:	40 00 01 ce 	call  4000825c <pthread_cond_destroy>          
40007b28:	90 10 00 1c 	mov  %i4, %o0                                  
	    free (r_chain);                                                  
40007b2c:	7f ff f0 db 	call  40003e98 <free>                          
40007b30:	90 10 00 18 	mov  %i0, %o0                                  
	                                                                     
	    /* If the idle chain is empty sleep for 3 seconds and wait for a 
	       signal. The thread now becomes idle. */                       
	    if (rtems_chain_is_empty (&aio_request_queue.idle_req)) {        
40007b34:	c2 07 60 60 	ld  [ %i5 + 0x60 ], %g1                        
40007b38:	80 a0 40 19 	cmp  %g1, %i1                                  
40007b3c:	12 80 00 1b 	bne  40007ba8 <rtems_aio_handle+0x210>         
40007b40:	c2 07 60 74 	ld  [ %i5 + 0x74 ], %g1                        
	      AIO_printf ("Chain is empty [IQ], wait for work\n");	          
                                                                      
	      ++aio_request_queue.idle_threads;                              
	      --aio_request_queue.active_threads;                            
	      clock_gettime (CLOCK_REALTIME, &timeout);                      
40007b44:	92 07 bf dc 	add  %fp, -36, %o1                             
	    /* If the idle chain is empty sleep for 3 seconds and wait for a 
	       signal. The thread now becomes idle. */                       
	    if (rtems_chain_is_empty (&aio_request_queue.idle_req)) {        
	      AIO_printf ("Chain is empty [IQ], wait for work\n");	          
                                                                      
	      ++aio_request_queue.idle_threads;                              
40007b48:	82 00 60 01 	inc  %g1                                       
40007b4c:	c2 27 60 74 	st  %g1, [ %i5 + 0x74 ]                        
	      --aio_request_queue.active_threads;                            
40007b50:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
	      clock_gettime (CLOCK_REALTIME, &timeout);                      
40007b54:	90 10 20 01 	mov  1, %o0                                    
	       signal. The thread now becomes idle. */                       
	    if (rtems_chain_is_empty (&aio_request_queue.idle_req)) {        
	      AIO_printf ("Chain is empty [IQ], wait for work\n");	          
                                                                      
	      ++aio_request_queue.idle_threads;                              
	      --aio_request_queue.active_threads;                            
40007b58:	82 00 7f ff 	add  %g1, -1, %g1                              
	      clock_gettime (CLOCK_REALTIME, &timeout);                      
40007b5c:	40 00 01 92 	call  400081a4 <clock_gettime>                 
40007b60:	c2 27 60 70 	st  %g1, [ %i5 + 0x70 ]                        
	      timeout.tv_sec += 3;                                           
40007b64:	c2 07 bf dc 	ld  [ %fp + -36 ], %g1                         
	      timeout.tv_nsec = 0;                                           
40007b68:	c0 27 bf e0 	clr  [ %fp + -32 ]                             
	      AIO_printf ("Chain is empty [IQ], wait for work\n");	          
                                                                      
	      ++aio_request_queue.idle_threads;                              
	      --aio_request_queue.active_threads;                            
	      clock_gettime (CLOCK_REALTIME, &timeout);                      
	      timeout.tv_sec += 3;                                           
40007b6c:	82 00 60 03 	add  %g1, 3, %g1                               
	      timeout.tv_nsec = 0;                                           
                                                                      
	      result = pthread_cond_timedwait (&aio_request_queue.new_req,   
40007b70:	90 07 60 04 	add  %i5, 4, %o0                               
	      AIO_printf ("Chain is empty [IQ], wait for work\n");	          
                                                                      
	      ++aio_request_queue.idle_threads;                              
	      --aio_request_queue.active_threads;                            
	      clock_gettime (CLOCK_REALTIME, &timeout);                      
	      timeout.tv_sec += 3;                                           
40007b74:	c2 27 bf dc 	st  %g1, [ %fp + -36 ]                         
	      timeout.tv_nsec = 0;                                           
                                                                      
	      result = pthread_cond_timedwait (&aio_request_queue.new_req,   
40007b78:	92 10 00 1d 	mov  %i5, %o1                                  
40007b7c:	40 00 02 3e 	call  40008474 <pthread_cond_timedwait>        
40007b80:	94 07 bf dc 	add  %fp, -36, %o2                             
					       &aio_request_queue.mutex,                                 
					       &timeout);                                                
	                                                                     
	      /* If no new fd chain was added in the idle requests           
		 then this thread is finished */                                    
	      if (result == ETIMEDOUT) {                                     
40007b84:	80 a2 20 74 	cmp  %o0, 0x74                                 
40007b88:	12 80 00 08 	bne  40007ba8 <rtems_aio_handle+0x210>         <== NEVER TAKEN
40007b8c:	c2 07 60 74 	ld  [ %i5 + 0x74 ], %g1                        
		AIO_printf ("Etimeout\n");                                          
		--aio_request_queue.idle_threads;                                   
		pthread_mutex_unlock (&aio_request_queue.mutex);                    
40007b90:	90 10 00 1d 	mov  %i5, %o0                                  
	                                                                     
	      /* If no new fd chain was added in the idle requests           
		 then this thread is finished */                                    
	      if (result == ETIMEDOUT) {                                     
		AIO_printf ("Etimeout\n");                                          
		--aio_request_queue.idle_threads;                                   
40007b94:	82 00 7f ff 	add  %g1, -1, %g1                              
		pthread_mutex_unlock (&aio_request_queue.mutex);                    
40007b98:	40 00 03 99 	call  400089fc <pthread_mutex_unlock>          
40007b9c:	c2 27 60 74 	st  %g1, [ %i5 + 0x74 ]                        
    }                                                                 
  }                                                                   
                                                                      
  AIO_printf ("Thread finished\n");                                   
  return NULL;                                                        
}                                                                     
40007ba0:	81 c7 e0 08 	ret                                            
40007ba4:	91 e8 20 00 	restore  %g0, 0, %o0                           
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
40007ba8:	f0 07 60 60 	ld  [ %i5 + 0x60 ], %i0                        
	      }                                                              
	    }                                                                
	    /* Otherwise move this chain to the working chain and            
	       start the loop all over again */                              
	    AIO_printf ("Work on idle\n");                                   
	    --aio_request_queue.idle_threads;                                
40007bac:	82 00 7f ff 	add  %g1, -1, %g1                              
40007bb0:	c2 27 60 74 	st  %g1, [ %i5 + 0x74 ]                        
	    ++aio_request_queue.active_threads;                              
40007bb4:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
40007bb8:	90 10 00 18 	mov  %i0, %o0                                  
40007bbc:	82 00 60 01 	inc  %g1                                       
40007bc0:	40 00 09 f9 	call  4000a3a4 <_Chain_Extract>                
40007bc4:	c2 27 60 70 	st  %g1, [ %i5 + 0x70 ]                        
40007bc8:	c2 07 60 54 	ld  [ %i5 + 0x54 ], %g1                        
  rtems_chain_node *node;                                             
                                                                      
  node = rtems_chain_first (work_req_chain);                          
  temp = (rtems_aio_request_chain *) node;                            
                                                                      
  while (temp->fildes < r_chain->fildes &&                            
40007bcc:	c4 06 20 14 	ld  [ %i0 + 0x14 ], %g2                        
40007bd0:	c6 00 60 14 	ld  [ %g1 + 0x14 ], %g3                        
40007bd4:	80 a0 c0 02 	cmp  %g3, %g2                                  
40007bd8:	16 80 00 06 	bge  40007bf0 <rtems_aio_handle+0x258>         
40007bdc:	80 a0 40 10 	cmp  %g1, %l0                                  
40007be0:	22 80 00 05 	be,a   40007bf4 <rtems_aio_handle+0x25c>       <== NEVER TAKEN
40007be4:	d0 00 60 04 	ld  [ %g1 + 4 ], %o0                           <== NOT EXECUTED
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
40007be8:	10 bf ff fa 	b  40007bd0 <rtems_aio_handle+0x238>           
40007bec:	c2 00 40 00 	ld  [ %g1 ], %g1                               
RTEMS_INLINE_ROUTINE void rtems_chain_insert(                         
  rtems_chain_node *after_node,                                       
  rtems_chain_node *the_node                                          
)                                                                     
{                                                                     
  _Chain_Insert( after_node, the_node );                              
40007bf0:	d0 00 60 04 	ld  [ %g1 + 4 ], %o0                           
40007bf4:	40 00 0a 05 	call  4000a408 <_Chain_Insert>                 
40007bf8:	92 10 00 18 	mov  %i0, %o1                                  
	                                                                     
	  }                                                                  
	}                                                                    
      /* If there was a request added in the initial fd chain then release
	 the mutex and process it */                                         
      pthread_mutex_unlock (&aio_request_queue.mutex);                
40007bfc:	40 00 03 80 	call  400089fc <pthread_mutex_unlock>          
40007c00:	90 10 00 1a 	mov  %i2, %o0                                  
40007c04:	10 bf ff 6c 	b  400079b4 <rtems_aio_handle+0x1c>            
40007c08:	b6 06 20 1c 	add  %i0, 0x1c, %i3                            
    }                                                                 
  }                                                                   
                                                                      
  AIO_printf ("Thread finished\n");                                   
  return NULL;                                                        
}                                                                     
40007c0c:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
40007c10:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40007c14:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40007c18 <rtems_aio_init>: * 0 - if initialization succeeded */ int rtems_aio_init (void) {
40007c18:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int result = 0;                                                     
                                                                      
  result = pthread_attr_init (&aio_request_queue.attr);               
40007c1c:	3b 10 00 6a 	sethi  %hi(0x4001a800), %i5                    
40007c20:	40 00 03 d1 	call  40008b64 <pthread_attr_init>             
40007c24:	90 17 60 90 	or  %i5, 0x90, %o0	! 4001a890 <aio_request_queue+0x8>
  if (result != 0)                                                    
40007c28:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40007c2c:	12 80 00 2d 	bne  40007ce0 <rtems_aio_init+0xc8>            <== NEVER TAKEN
40007c30:	90 17 60 90 	or  %i5, 0x90, %o0                             
    return result;                                                    
                                                                      
  result =                                                            
40007c34:	40 00 03 d8 	call  40008b94 <pthread_attr_setdetachstate>   
40007c38:	92 10 20 00 	clr  %o1                                       
    pthread_attr_setdetachstate (&aio_request_queue.attr,             
                                 PTHREAD_CREATE_DETACHED);            
  if (result != 0)                                                    
40007c3c:	80 a2 20 00 	cmp  %o0, 0                                    
40007c40:	02 80 00 05 	be  40007c54 <rtems_aio_init+0x3c>             <== ALWAYS TAKEN
40007c44:	39 10 00 6a 	sethi  %hi(0x4001a800), %i4                    
    pthread_attr_destroy (&aio_request_queue.attr);                   
40007c48:	40 00 03 bb 	call  40008b34 <pthread_attr_destroy>          <== NOT EXECUTED
40007c4c:	90 17 60 90 	or  %i5, 0x90, %o0                             <== NOT EXECUTED
                                                                      
                                                                      
  result = pthread_mutex_init (&aio_request_queue.mutex, NULL);       
40007c50:	39 10 00 6a 	sethi  %hi(0x4001a800), %i4                    <== NOT EXECUTED
40007c54:	92 10 20 00 	clr  %o1                                       
40007c58:	40 00 02 ef 	call  40008814 <pthread_mutex_init>            
40007c5c:	90 17 20 88 	or  %i4, 0x88, %o0                             
  if (result != 0)                                                    
40007c60:	80 a2 20 00 	cmp  %o0, 0                                    
40007c64:	22 80 00 05 	be,a   40007c78 <rtems_aio_init+0x60>          <== ALWAYS TAKEN
40007c68:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    
    pthread_attr_destroy (&aio_request_queue.attr);                   
40007c6c:	40 00 03 b2 	call  40008b34 <pthread_attr_destroy>          <== NOT EXECUTED
40007c70:	90 17 60 90 	or  %i5, 0x90, %o0                             <== NOT EXECUTED
                                                                      
                                                                      
  result = pthread_cond_init (&aio_request_queue.new_req, NULL);      
40007c74:	11 10 00 6a 	sethi  %hi(0x4001a800), %o0                    <== NOT EXECUTED
40007c78:	92 10 20 00 	clr  %o1                                       
40007c7c:	40 00 01 b5 	call  40008350 <pthread_cond_init>             
40007c80:	90 12 20 8c 	or  %o0, 0x8c, %o0                             
  if (result != 0) {                                                  
40007c84:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40007c88:	02 80 00 07 	be  40007ca4 <rtems_aio_init+0x8c>             <== ALWAYS TAKEN
40007c8c:	82 17 20 88 	or  %i4, 0x88, %g1                             
    pthread_mutex_destroy (&aio_request_queue.mutex);                 
40007c90:	40 00 02 89 	call  400086b4 <pthread_mutex_destroy>         <== NOT EXECUTED
40007c94:	90 17 20 88 	or  %i4, 0x88, %o0                             <== NOT EXECUTED
    pthread_attr_destroy (&aio_request_queue.attr);                   
40007c98:	40 00 03 a7 	call  40008b34 <pthread_attr_destroy>          <== NOT EXECUTED
40007c9c:	90 17 60 90 	or  %i5, 0x90, %o0                             <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40007ca0:	82 17 20 88 	or  %i4, 0x88, %g1                             <== NOT EXECUTED
40007ca4:	84 00 60 58 	add  %g1, 0x58, %g2                            
40007ca8:	c4 20 60 54 	st  %g2, [ %g1 + 0x54 ]                        
  head->previous = NULL;                                              
  tail->previous = head;                                              
40007cac:	84 00 60 54 	add  %g1, 0x54, %g2                            
40007cb0:	c4 20 60 5c 	st  %g2, [ %g1 + 0x5c ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40007cb4:	84 00 60 64 	add  %g1, 0x64, %g2                            
40007cb8:	c4 20 60 60 	st  %g2, [ %g1 + 0x60 ]                        
  head->previous = NULL;                                              
  tail->previous = head;                                              
40007cbc:	84 00 60 60 	add  %g1, 0x60, %g2                            
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
40007cc0:	c0 20 60 58 	clr  [ %g1 + 0x58 ]                            
  tail->previous = head;                                              
40007cc4:	c4 20 60 68 	st  %g2, [ %g1 + 0x68 ]                        
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
40007cc8:	c0 20 60 64 	clr  [ %g1 + 0x64 ]                            
  rtems_chain_initialize_empty (&aio_request_queue.work_req);         
  rtems_chain_initialize_empty (&aio_request_queue.idle_req);         
                                                                      
  aio_request_queue.active_threads = 0;                               
  aio_request_queue.idle_threads = 0;                                 
  aio_request_queue.initialized = AIO_QUEUE_INITIALIZED;              
40007ccc:	05 00 00 2c 	sethi  %hi(0xb000), %g2                        
  }                                                                   
                                                                      
  rtems_chain_initialize_empty (&aio_request_queue.work_req);         
  rtems_chain_initialize_empty (&aio_request_queue.idle_req);         
                                                                      
  aio_request_queue.active_threads = 0;                               
40007cd0:	c0 20 60 70 	clr  [ %g1 + 0x70 ]                            
  aio_request_queue.idle_threads = 0;                                 
  aio_request_queue.initialized = AIO_QUEUE_INITIALIZED;              
40007cd4:	84 10 a0 0b 	or  %g2, 0xb, %g2                              
                                                                      
  rtems_chain_initialize_empty (&aio_request_queue.work_req);         
  rtems_chain_initialize_empty (&aio_request_queue.idle_req);         
                                                                      
  aio_request_queue.active_threads = 0;                               
  aio_request_queue.idle_threads = 0;                                 
40007cd8:	c0 20 60 74 	clr  [ %g1 + 0x74 ]                            
  aio_request_queue.initialized = AIO_QUEUE_INITIALIZED;              
40007cdc:	c4 20 60 6c 	st  %g2, [ %g1 + 0x6c ]                        
                                                                      
  return result;                                                      
}                                                                     
40007ce0:	81 c7 e0 08 	ret                                            
40007ce4:	81 e8 00 00 	restore                                        
                                                                      

4000793c <rtems_aio_insert_prio>: */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next;
4000793c:	c2 02 00 00 	ld  [ %o0 ], %g1                               
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40007940:	86 02 20 04 	add  %o0, 4, %g3                               
  rtems_chain_node *node;                                             
                                                                      
  AIO_printf ("FD exists \n");                                        
  node = rtems_chain_first (chain);                                   
                                                                      
  if (rtems_chain_is_empty (chain)) {                                 
40007944:	80 a0 40 03 	cmp  %g1, %g3                                  
40007948:	02 80 00 0b 	be  40007974 <rtems_aio_insert_prio+0x38>      <== NEVER TAKEN
4000794c:	84 10 00 09 	mov  %o1, %g2                                  
    AIO_printf ("First in chain \n");                                 
    rtems_chain_prepend (chain, &req->next_prio);                     
  } else {                                                            
    AIO_printf ("Add by priority \n");                                
    int prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;     
40007950:	c8 00 60 14 	ld  [ %g1 + 0x14 ], %g4                        
                                                                      
    while (req->aiocbp->aio_reqprio > prio &&                         
40007954:	da 02 60 14 	ld  [ %o1 + 0x14 ], %o5                        
  if (rtems_chain_is_empty (chain)) {                                 
    AIO_printf ("First in chain \n");                                 
    rtems_chain_prepend (chain, &req->next_prio);                     
  } else {                                                            
    AIO_printf ("Add by priority \n");                                
    int prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;     
40007958:	c8 01 20 18 	ld  [ %g4 + 0x18 ], %g4                        
                                                                      
    while (req->aiocbp->aio_reqprio > prio &&                         
4000795c:	da 03 60 18 	ld  [ %o5 + 0x18 ], %o5                        
40007960:	80 a3 40 04 	cmp  %o5, %g4                                  
40007964:	14 80 00 07 	bg  40007980 <rtems_aio_insert_prio+0x44>      <== NEVER TAKEN
40007968:	80 a0 40 03 	cmp  %g1, %g3                                  
RTEMS_INLINE_ROUTINE void rtems_chain_insert(                         
  rtems_chain_node *after_node,                                       
  rtems_chain_node *the_node                                          
)                                                                     
{                                                                     
  _Chain_Insert( after_node, the_node );                              
4000796c:	d0 00 60 04 	ld  [ %g1 + 4 ], %o0                           
40007970:	92 10 00 02 	mov  %g2, %o1                                  
40007974:	82 13 c0 00 	mov  %o7, %g1                                  
40007978:	40 00 0a a4 	call  4000a408 <_Chain_Insert>                 
4000797c:	9e 10 40 00 	mov  %g1, %o7                                  
40007980:	22 bf ff fc 	be,a   40007970 <rtems_aio_insert_prio+0x34>   <== NOT EXECUTED
40007984:	d0 00 60 04 	ld  [ %g1 + 4 ], %o0                           <== NOT EXECUTED
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
40007988:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
           !rtems_chain_is_tail (chain, node)) {                      
      node = rtems_chain_next (node);                                 
      prio = ((rtems_aio_request *) node)->aiocbp->aio_reqprio;       
4000798c:	c8 00 60 14 	ld  [ %g1 + 0x14 ], %g4                        <== NOT EXECUTED
40007990:	10 bf ff f4 	b  40007960 <rtems_aio_insert_prio+0x24>       <== NOT EXECUTED
40007994:	c8 01 20 18 	ld  [ %g4 + 0x18 ], %g4                        <== NOT EXECUTED
                                                                      

40007ddc <rtems_aio_remove_req>: * AIO_NOTCANCELED - if request was not canceled * AIO_CANCELED - if request was canceled */ int rtems_aio_remove_req (rtems_chain_control *chain, struct aiocb *aiocbp) {
40007ddc:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
40007de0:	fa 06 00 00 	ld  [ %i0 ], %i5                               
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
40007de4:	82 06 20 04 	add  %i0, 4, %g1                               
  if (rtems_chain_is_empty (chain))                                   
40007de8:	80 a7 40 01 	cmp  %i5, %g1                                  
40007dec:	02 80 00 18 	be  40007e4c <rtems_aio_remove_req+0x70>       
40007df0:	b0 10 20 02 	mov  2, %i0                                    
  rtems_chain_node *node = rtems_chain_first (chain);                 
  rtems_aio_request *current;                                         
                                                                      
  current = (rtems_aio_request *) node;                               
                                                                      
  while (!rtems_chain_is_tail (chain, node) && current->aiocbp != aiocbp) {
40007df4:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        
40007df8:	80 a0 80 19 	cmp  %g2, %i1                                  
40007dfc:	02 80 00 08 	be  40007e1c <rtems_aio_remove_req+0x40>       <== ALWAYS TAKEN
40007e00:	80 a7 40 01 	cmp  %i5, %g1                                  
40007e04:	fa 07 40 00 	ld  [ %i5 ], %i5                               <== NOT EXECUTED
40007e08:	80 a7 40 01 	cmp  %i5, %g1                                  <== NOT EXECUTED
40007e0c:	32 bf ff fb 	bne,a   40007df8 <rtems_aio_remove_req+0x1c>   <== NOT EXECUTED
40007e10:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        <== NOT EXECUTED
    node = rtems_chain_next (node);                                   
    current = (rtems_aio_request *) node;                             
  }                                                                   
                                                                      
  if (rtems_chain_is_tail (chain, node))                              
    return AIO_NOTCANCELED;                                           
40007e14:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40007e18:	91 e8 20 01 	restore  %g0, 1, %o0                           <== NOT EXECUTED
  while (!rtems_chain_is_tail (chain, node) && current->aiocbp != aiocbp) {
    node = rtems_chain_next (node);                                   
    current = (rtems_aio_request *) node;                             
  }                                                                   
                                                                      
  if (rtems_chain_is_tail (chain, node))                              
40007e1c:	02 80 00 0c 	be  40007e4c <rtems_aio_remove_req+0x70>       <== NEVER TAKEN
40007e20:	b0 10 20 01 	mov  1, %i0                                    
#else                                                                 
RTEMS_INLINE_ROUTINE void rtems_chain_extract(                        
  rtems_chain_node *the_node                                          
)                                                                     
{                                                                     
  _Chain_Extract( the_node );                                         
40007e24:	40 00 09 60 	call  4000a3a4 <_Chain_Extract>                
40007e28:	90 10 00 1d 	mov  %i5, %o0                                  
    return AIO_NOTCANCELED;                                           
  else                                                                
    {                                                                 
      rtems_chain_extract (node);                                     
      current->aiocbp->error_code = ECANCELED;                        
40007e2c:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
40007e30:	84 10 20 8c 	mov  0x8c, %g2                                 
40007e34:	c4 20 60 34 	st  %g2, [ %g1 + 0x34 ]                        
      current->aiocbp->return_value = -1;                             
40007e38:	84 10 3f ff 	mov  -1, %g2                                   
      free (current);                                                 
40007e3c:	90 10 00 1d 	mov  %i5, %o0                                  
    return AIO_NOTCANCELED;                                           
  else                                                                
    {                                                                 
      rtems_chain_extract (node);                                     
      current->aiocbp->error_code = ECANCELED;                        
      current->aiocbp->return_value = -1;                             
40007e40:	c4 20 60 38 	st  %g2, [ %g1 + 0x38 ]                        
      free (current);                                                 
40007e44:	7f ff f0 15 	call  40003e98 <free>                          
40007e48:	b0 10 20 00 	clr  %i0                                       
    }                                                                 
                                                                      
  return AIO_CANCELED;                                                
40007e4c:	81 c7 e0 08 	ret                                            
40007e50:	81 e8 00 00 	restore                                        
                                                                      

4000e590 <rtems_bdbuf_add_to_modified_list_after_access>: } } static void rtems_bdbuf_add_to_modified_list_after_access (rtems_bdbuf_buffer *bd) {
4000e590:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (bdbuf_cache.sync_active && bdbuf_cache.sync_device == bd->dd)   
4000e594:	3b 10 00 70 	sethi  %hi(0x4001c000), %i5                    
4000e598:	ba 17 63 dc 	or  %i5, 0x3dc, %i5	! 4001c3dc <bdbuf_cache>   
4000e59c:	c2 0f 60 30 	ldub  [ %i5 + 0x30 ], %g1                      
4000e5a0:	80 a0 60 00 	cmp  %g1, 0                                    
4000e5a4:	22 80 00 10 	be,a   4000e5e4 <rtems_bdbuf_add_to_modified_list_after_access+0x54><== ALWAYS TAKEN
4000e5a8:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
4000e5ac:	c4 07 60 38 	ld  [ %i5 + 0x38 ], %g2                        <== NOT EXECUTED
4000e5b0:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        <== NOT EXECUTED
4000e5b4:	80 a0 80 01 	cmp  %g2, %g1                                  <== NOT EXECUTED
4000e5b8:	32 80 00 0b 	bne,a   4000e5e4 <rtems_bdbuf_add_to_modified_list_after_access+0x54><== NOT EXECUTED
4000e5bc:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        <== NOT EXECUTED
  {                                                                   
    rtems_bdbuf_unlock_cache ();                                      
4000e5c0:	7f ff fd f8 	call  4000dda0 <rtems_bdbuf_unlock_cache>      <== NOT EXECUTED
4000e5c4:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
    /*                                                                
     * Wait for the sync lock.                                        
     */                                                               
    rtems_bdbuf_lock_sync ();                                         
4000e5c8:	7f ff f9 e7 	call  4000cd64 <rtems_bdbuf_lock_sync>         <== NOT EXECUTED
4000e5cc:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
    rtems_bdbuf_unlock_sync ();                                       
4000e5d0:	7f ff f9 f0 	call  4000cd90 <rtems_bdbuf_unlock_sync>       <== NOT EXECUTED
4000e5d4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    rtems_bdbuf_lock_cache ();                                        
4000e5d8:	7f ff fd e7 	call  4000dd74 <rtems_bdbuf_lock_cache>        <== NOT EXECUTED
4000e5dc:	01 00 00 00 	nop                                            <== NOT EXECUTED
   * 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                    
4000e5e0:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        <== NOT EXECUTED
4000e5e4:	80 a0 60 05 	cmp  %g1, 5                                    
4000e5e8:	22 80 00 06 	be,a   4000e600 <rtems_bdbuf_add_to_modified_list_after_access+0x70>
4000e5ec:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
4000e5f0:	80 a0 60 03 	cmp  %g1, 3                                    
4000e5f4:	12 80 00 06 	bne  4000e60c <rtems_bdbuf_add_to_modified_list_after_access+0x7c>
4000e5f8:	82 10 20 07 	mov  7, %g1                                    
        || bd->state == RTEMS_BDBUF_STATE_ACCESS_EMPTY)               
    bd->hold_timer = bdbuf_config.swap_block_hold;                    
4000e5fc:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
4000e600:	c2 00 62 e8 	ld  [ %g1 + 0x2e8 ], %g1	! 40019ee8 <rtems_bdbuf_configuration+0x10>
4000e604:	c2 26 20 2c 	st  %g1, [ %i0 + 0x2c ]                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000e608:	82 10 20 07 	mov  7, %g1                                    
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4000e60c:	84 07 60 50 	add  %i5, 0x50, %g2                            
4000e610:	c2 26 20 20 	st  %g1, [ %i0 + 0x20 ]                        
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000e614:	c2 07 60 54 	ld  [ %i5 + 0x54 ], %g1                        
                                                                      
  the_node->next = tail;                                              
4000e618:	c4 26 00 00 	st  %g2, [ %i0 ]                               
  tail->previous = the_node;                                          
4000e61c:	f0 27 60 54 	st  %i0, [ %i5 + 0x54 ]                        
  old_last->next = the_node;                                          
4000e620:	f0 20 40 00 	st  %i0, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000e624:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
    bd->hold_timer = bdbuf_config.swap_block_hold;                    
                                                                      
  rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_MODIFIED);             
  rtems_chain_append_unprotected (&bdbuf_cache.modified, &bd->link);  
                                                                      
  if (bd->waiters)                                                    
4000e628:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
4000e62c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e630:	22 80 00 04 	be,a   4000e640 <rtems_bdbuf_add_to_modified_list_after_access+0xb0>
4000e634:	c2 07 60 74 	ld  [ %i5 + 0x74 ], %g1                        
    rtems_bdbuf_wake (&bdbuf_cache.access_waiters);                   
4000e638:	7f ff fa 42 	call  4000cf40 <rtems_bdbuf_wake>              
4000e63c:	91 ef 60 64 	restore  %i5, 0x64, %o0                        
  else if (rtems_bdbuf_has_buffer_waiters ())                         
4000e640:	80 a0 60 00 	cmp  %g1, 0                                    
4000e644:	02 80 00 04 	be  4000e654 <rtems_bdbuf_add_to_modified_list_after_access+0xc4>
4000e648:	01 00 00 00 	nop                                            
    rtems_bdbuf_wake_swapper ();                                      
4000e64c:	7f ff f9 dc 	call  4000cdbc <rtems_bdbuf_wake_swapper>      
4000e650:	81 e8 00 00 	restore                                        
4000e654:	81 c7 e0 08 	ret                                            
4000e658:	81 e8 00 00 	restore                                        
                                                                      

4000cdec <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) {
4000cdec:	9d e3 bf a0 	save  %sp, -96, %sp                            
  /*                                                                  
   * Indicate we are waiting.                                         
   */                                                                 
  ++waiters->count;                                                   
4000cdf0:	c2 06 00 00 	ld  [ %i0 ], %g1                               
                                                                      
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  {                                                                   
    int eno = pthread_cond_wait (&waiters->cond_var, &bdbuf_cache.lock);
4000cdf4:	90 06 20 04 	add  %i0, 4, %o0                               
rtems_bdbuf_anonymous_wait (rtems_bdbuf_waiters *waiters)             
{                                                                     
  /*                                                                  
   * Indicate we are waiting.                                         
   */                                                                 
  ++waiters->count;                                                   
4000cdf8:	82 00 60 01 	inc  %g1                                       
                                                                      
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  {                                                                   
    int eno = pthread_cond_wait (&waiters->cond_var, &bdbuf_cache.lock);
4000cdfc:	13 10 00 71 	sethi  %hi(0x4001c400), %o1                    
rtems_bdbuf_anonymous_wait (rtems_bdbuf_waiters *waiters)             
{                                                                     
  /*                                                                  
   * Indicate we are waiting.                                         
   */                                                                 
  ++waiters->count;                                                   
4000ce00:	c2 26 00 00 	st  %g1, [ %i0 ]                               
                                                                      
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  {                                                                   
    int eno = pthread_cond_wait (&waiters->cond_var, &bdbuf_cache.lock);
4000ce04:	40 00 0e e0 	call  40010984 <pthread_cond_wait>             
4000ce08:	92 12 60 04 	or  %o1, 4, %o1                                
    if (eno != 0)                                                     
4000ce0c:	80 a2 20 00 	cmp  %o0, 0                                    
4000ce10:	22 80 00 04 	be,a   4000ce20 <rtems_bdbuf_anonymous_wait+0x34><== ALWAYS TAKEN
4000ce14:	c2 06 00 00 	ld  [ %i0 ], %g1                               
      rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_CV_WAIT);                  
4000ce18:	7f ff ff b8 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000ce1c:	90 10 20 1e 	mov  0x1e, %o0                                 <== NOT EXECUTED
                                                                      
    rtems_bdbuf_restore_preemption (prev_mode);                       
  }                                                                   
#endif                                                                
                                                                      
  --waiters->count;                                                   
4000ce20:	82 00 7f ff 	add  %g1, -1, %g1                              
4000ce24:	c2 26 00 00 	st  %g1, [ %i0 ]                               
4000ce28:	81 c7 e0 08 	ret                                            
4000ce2c:	81 e8 00 00 	restore                                        
                                                                      

4000cfe0 <rtems_bdbuf_create_task.constprop.15>: return NULL; } static rtems_status_code rtems_bdbuf_create_task(
4000cfe0:	9a 10 00 0a 	mov  %o2, %o5                                  
  rtems_task_priority default_priority,                               
  rtems_id *id                                                        
)                                                                     
{                                                                     
  rtems_status_code sc;                                               
  size_t stack_size = bdbuf_config.task_stack_size ?                  
4000cfe4:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
4000cfe8:	d4 00 62 f4 	ld  [ %g1 + 0x2f4 ], %o2	! 40019ef4 <rtems_bdbuf_configuration+0x1c>
    bdbuf_config.task_stack_size : RTEMS_BDBUF_TASK_STACK_SIZE_DEFAULT;
4000cfec:	80 a2 a0 00 	cmp  %o2, 0                                    
4000cff0:	22 80 00 02 	be,a   4000cff8 <rtems_bdbuf_create_task.constprop.15+0x18><== NEVER TAKEN
4000cff4:	15 00 00 04 	sethi  %hi(0x1000), %o2                        <== NOT EXECUTED
                                                                      
  priority = priority != 0 ? priority : default_priority;             
4000cff8:	80 a2 60 00 	cmp  %o1, 0                                    
4000cffc:	22 80 00 02 	be,a   4000d004 <rtems_bdbuf_create_task.constprop.15+0x24><== NEVER TAKEN
4000d000:	92 10 20 0f 	mov  0xf, %o1                                  <== NOT EXECUTED
                                                                      
  sc = rtems_task_create (name,                                       
4000d004:	96 10 24 00 	mov  0x400, %o3                                
4000d008:	98 10 20 00 	clr  %o4                                       
4000d00c:	82 13 c0 00 	mov  %o7, %g1                                  
4000d010:	7f ff ef 5c 	call  40008d80 <rtems_task_create>             
4000d014:	9e 10 40 00 	mov  %g1, %o7                                  
                                                                      

4000dba8 <rtems_bdbuf_do_purge_dev>: } } static void rtems_bdbuf_do_purge_dev (rtems_disk_device *dd) {
4000dba8:	9d e3 bf 10 	save  %sp, -240, %sp                           
 *                                                                    
 * @retval true The node is off chain.                                
 * @retval false The node is not off chain.                           
 */                                                                   
RTEMS_INLINE_ROUTINE bool rtems_chain_is_node_off_chain(              
  const rtems_chain_node *node                                        
4000dbac:	c2 06 20 64 	ld  [ %i0 + 0x64 ], %g1                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000dbb0:	b4 07 bf 74 	add  %fp, -140, %i2                            
4000dbb4:	b6 07 bf 78 	add  %fp, -136, %i3                            
  head->previous = NULL;                                              
4000dbb8:	c0 27 bf 78 	clr  [ %fp + -136 ]                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000dbbc:	f6 27 bf 74 	st  %i3, [ %fp + -140 ]                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_read_ahead_cancel (rtems_disk_device *dd)                 
{                                                                     
  if (rtems_bdbuf_is_read_ahead_active (dd))                          
4000dbc0:	80 a0 60 00 	cmp  %g1, 0                                    
4000dbc4:	02 80 00 06 	be  4000dbdc <rtems_bdbuf_do_purge_dev+0x34>   <== ALWAYS TAKEN
4000dbc8:	f4 27 bf 7c 	st  %i2, [ %fp + -132 ]                        
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
4000dbcc:	c4 06 20 68 	ld  [ %i0 + 0x68 ], %g2                        <== NOT EXECUTED
  next->previous = previous;                                          
4000dbd0:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           <== NOT EXECUTED
  previous->next = next;                                              
4000dbd4:	c2 20 80 00 	st  %g1, [ %g2 ]                               <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
4000dbd8:	c0 26 20 64 	clr  [ %i0 + 0x64 ]                            <== NOT EXECUTED
rtems_bdbuf_gather_for_purge (rtems_chain_control *purge_list,        
                              const rtems_disk_device *dd)            
{                                                                     
  rtems_bdbuf_buffer *stack [RTEMS_BDBUF_AVL_MAX_HEIGHT];             
  rtems_bdbuf_buffer **prev = stack;                                  
  rtems_bdbuf_buffer *cur = bdbuf_cache.tree;                         
4000dbdc:	11 10 00 70 	sethi  %hi(0x4001c000), %o0                    
4000dbe0:	90 12 23 dc 	or  %o0, 0x3dc, %o0	! 4001c3dc <bdbuf_cache>   
4000dbe4:	fa 02 20 3c 	ld  [ %o0 + 0x3c ], %i5                        
                                                                      
static void                                                           
rtems_bdbuf_read_ahead_reset (rtems_disk_device *dd)                  
{                                                                     
  rtems_bdbuf_read_ahead_cancel (dd);                                 
  dd->read_ahead.trigger = RTEMS_DISK_READ_AHEAD_NO_TRIGGER;          
4000dbe8:	82 10 3f ff 	mov  -1, %g1                                   
                                                                      
  while (cur != NULL)                                                 
  {                                                                   
    if (cur->dd == dd)                                                
    {                                                                 
      switch (cur->state)                                             
4000dbec:	33 10 00 36 	sethi  %hi(0x4000d800), %i1                    
                                                                      
static void                                                           
rtems_bdbuf_read_ahead_reset (rtems_disk_device *dd)                  
{                                                                     
  rtems_bdbuf_read_ahead_cancel (dd);                                 
  dd->read_ahead.trigger = RTEMS_DISK_READ_AHEAD_NO_TRIGGER;          
4000dbf0:	c2 26 20 6c 	st  %g1, [ %i0 + 0x6c ]                        
{                                                                     
  rtems_bdbuf_buffer *stack [RTEMS_BDBUF_AVL_MAX_HEIGHT];             
  rtems_bdbuf_buffer **prev = stack;                                  
  rtems_bdbuf_buffer *cur = bdbuf_cache.tree;                         
                                                                      
  *prev = NULL;                                                       
4000dbf4:	c0 27 bf 80 	clr  [ %fp + -128 ]                            
static void                                                           
rtems_bdbuf_gather_for_purge (rtems_chain_control *purge_list,        
                              const rtems_disk_device *dd)            
{                                                                     
  rtems_bdbuf_buffer *stack [RTEMS_BDBUF_AVL_MAX_HEIGHT];             
  rtems_bdbuf_buffer **prev = stack;                                  
4000dbf8:	b8 07 bf 80 	add  %fp, -128, %i4                            
                                                                      
  while (cur != NULL)                                                 
  {                                                                   
    if (cur->dd == dd)                                                
    {                                                                 
      switch (cur->state)                                             
4000dbfc:	b2 16 63 7c 	or  %i1, 0x37c, %i1                            
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000dc00:	a0 10 20 06 	mov  6, %l0                                    
4000dc04:	a2 10 20 0a 	mov  0xa, %l1                                  
        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);           
4000dc08:	a4 02 20 6c 	add  %o0, 0x6c, %l2                            
  rtems_bdbuf_buffer **prev = stack;                                  
  rtems_bdbuf_buffer *cur = bdbuf_cache.tree;                         
                                                                      
  *prev = NULL;                                                       
                                                                      
  while (cur != NULL)                                                 
4000dc0c:	80 a7 60 00 	cmp  %i5, 0                                    
4000dc10:	22 80 00 3e 	be,a   4000dd08 <rtems_bdbuf_do_purge_dev+0x160>
4000dc14:	b8 10 20 00 	clr  %i4                                       
  {                                                                   
    if (cur->dd == dd)                                                
4000dc18:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000dc1c:	80 a0 40 18 	cmp  %g1, %i0                                  
4000dc20:	32 80 00 20 	bne,a   4000dca0 <rtems_bdbuf_do_purge_dev+0xf8>
4000dc24:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
    {                                                                 
      switch (cur->state)                                             
4000dc28:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
4000dc2c:	80 a0 60 0a 	cmp  %g1, 0xa                                  
4000dc30:	18 80 00 19 	bgu  4000dc94 <rtems_bdbuf_do_purge_dev+0xec>  <== NEVER TAKEN
4000dc34:	83 28 60 02 	sll  %g1, 2, %g1                               
4000dc38:	c2 06 40 01 	ld  [ %i1 + %g1 ], %g1                         
4000dc3c:	81 c0 40 00 	jmp  %g1                                       
4000dc40:	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);           
4000dc44:	7f ff fc bf 	call  4000cf40 <rtems_bdbuf_wake>              
4000dc48:	90 10 00 12 	mov  %l2, %o0                                  
rtems_bdbuf_gather_for_purge (rtems_chain_control *purge_list,        
                              const rtems_disk_device *dd)            
{                                                                     
  rtems_bdbuf_buffer *stack [RTEMS_BDBUF_AVL_MAX_HEIGHT];             
  rtems_bdbuf_buffer **prev = stack;                                  
  rtems_bdbuf_buffer *cur = bdbuf_cache.tree;                         
4000dc4c:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)                    
{                                                                     
  --bd->group->users;                                                 
4000dc50:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000dc54:	84 00 bf ff 	add  %g2, -1, %g2                              
4000dc58:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
4000dc5c:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4000dc60:	c4 07 40 00 	ld  [ %i5 ], %g2                               
  previous       = the_node->previous;                                
  next->previous = previous;                                          
4000dc64:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4000dc68:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000dc6c:	c2 07 bf 7c 	ld  [ %fp + -132 ], %g1                        
                                                                      
  the_node->next = tail;                                              
4000dc70:	f6 27 40 00 	st  %i3, [ %i5 ]                               
  tail->previous = the_node;                                          
4000dc74:	fa 27 bf 7c 	st  %i5, [ %fp + -132 ]                        
  old_last->next = the_node;                                          
4000dc78:	fa 20 40 00 	st  %i5, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000dc7c:	10 80 00 08 	b  4000dc9c <rtems_bdbuf_do_purge_dev+0xf4>    
4000dc80:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000dc84:	10 80 00 06 	b  4000dc9c <rtems_bdbuf_do_purge_dev+0xf4>    
4000dc88:	e2 27 60 20 	st  %l1, [ %i5 + 0x20 ]                        
4000dc8c:	10 80 00 04 	b  4000dc9c <rtems_bdbuf_do_purge_dev+0xf4>    
4000dc90:	e0 27 60 20 	st  %l0, [ %i5 + 0x20 ]                        
        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_bdbuf_fatal (RTEMS_BDBUF_FATAL_STATE_11);             
4000dc94:	7f ff fc 19 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000dc98:	90 10 20 14 	mov  0x14, %o0                                 <== NOT EXECUTED
      }                                                               
    }                                                                 
                                                                      
    if (cur->avl.left != NULL)                                        
4000dc9c:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
4000dca0:	80 a0 60 00 	cmp  %g1, 0                                    
4000dca4:	32 80 00 07 	bne,a   4000dcc0 <rtems_bdbuf_do_purge_dev+0x118>
4000dca8:	fa 27 20 04 	st  %i5, [ %i4 + 4 ]                           
      /* Left */                                                      
      ++prev;                                                         
      *prev = cur;                                                    
      cur = cur->avl.left;                                            
    }                                                                 
    else if (cur->avl.right != NULL)                                  
4000dcac:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4000dcb0:	80 a0 60 00 	cmp  %g1, 0                                    
4000dcb4:	22 80 00 0b 	be,a   4000dce0 <rtems_bdbuf_do_purge_dev+0x138>
4000dcb8:	c2 07 00 00 	ld  [ %i4 ], %g1                               
    {                                                                 
      /* Right */                                                     
      ++prev;                                                         
      *prev = cur;                                                    
4000dcbc:	fa 27 20 04 	st  %i5, [ %i4 + 4 ]                           
      cur = cur->avl.left;                                            
    }                                                                 
    else if (cur->avl.right != NULL)                                  
    {                                                                 
      /* Right */                                                     
      ++prev;                                                         
4000dcc0:	10 80 00 10 	b  4000dd00 <rtems_bdbuf_do_purge_dev+0x158>   
4000dcc4:	b8 07 20 04 	add  %i4, 4, %i4                               
      cur = cur->avl.right;                                           
    }                                                                 
    else                                                              
    {                                                                 
      while (*prev != NULL                                            
             && (cur == (*prev)->avl.right || (*prev)->avl.right == NULL))
4000dcc8:	80 a7 40 02 	cmp  %i5, %g2                                  
4000dccc:	12 80 00 0a 	bne  4000dcf4 <rtems_bdbuf_do_purge_dev+0x14c> 
4000dcd0:	80 a0 a0 00 	cmp  %g2, 0                                    
      {                                                               
        /* Up */                                                      
        cur = *prev;                                                  
        --prev;                                                       
4000dcd4:	b8 07 3f fc 	add  %i4, -4, %i4                              
4000dcd8:	ba 10 00 01 	mov  %g1, %i5                                  
      *prev = cur;                                                    
      cur = cur->avl.right;                                           
    }                                                                 
    else                                                              
    {                                                                 
      while (*prev != NULL                                            
4000dcdc:	c2 07 00 00 	ld  [ %i4 ], %g1                               
4000dce0:	80 a0 60 00 	cmp  %g1, 0                                    
4000dce4:	32 bf ff f9 	bne,a   4000dcc8 <rtems_bdbuf_do_purge_dev+0x120>
4000dce8:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
        cur = *prev;                                                  
        --prev;                                                       
      }                                                               
      if (*prev != NULL)                                              
        /* Right */                                                   
        cur = (*prev)->avl.right;                                     
4000dcec:	10 bf ff c8 	b  4000dc0c <rtems_bdbuf_do_purge_dev+0x64>    
4000dcf0:	ba 10 00 01 	mov  %g1, %i5                                  
      cur = cur->avl.right;                                           
    }                                                                 
    else                                                              
    {                                                                 
      while (*prev != NULL                                            
             && (cur == (*prev)->avl.right || (*prev)->avl.right == NULL))
4000dcf4:	22 bf ff f9 	be,a   4000dcd8 <rtems_bdbuf_do_purge_dev+0x130>
4000dcf8:	b8 07 3f fc 	add  %i4, -4, %i4                              
        cur = *prev;                                                  
        --prev;                                                       
      }                                                               
      if (*prev != NULL)                                              
        /* Right */                                                   
        cur = (*prev)->avl.right;                                     
4000dcfc:	82 10 00 02 	mov  %g2, %g1                                  
4000dd00:	10 bf ff c3 	b  4000dc0c <rtems_bdbuf_do_purge_dev+0x64>    
4000dd04:	ba 10 00 01 	mov  %g1, %i5                                  
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000dd08:	b2 10 20 01 	mov  1, %i1                                    
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000dd0c:	fa 07 bf 74 	ld  [ %fp + -140 ], %i5                        
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000dd10:	80 a7 40 1b 	cmp  %i5, %i3                                  
4000dd14:	02 80 00 12 	be  4000dd5c <rtems_bdbuf_do_purge_dev+0x1b4>  
4000dd18:	80 8f 20 ff 	btst  0xff, %i4                                
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4000dd1c:	c2 07 40 00 	ld  [ %i5 ], %g1                               
                                                                      
  head->next = new_first;                                             
4000dd20:	c2 27 bf 74 	st  %g1, [ %fp + -140 ]                        
  new_first->previous = head;                                         
4000dd24:	f4 20 60 04 	st  %i2, [ %g1 + 4 ]                           
                                                                      
  while ((node = rtems_chain_get_unprotected (purge_list)) != NULL)   
  {                                                                   
    rtems_bdbuf_buffer *bd = (rtems_bdbuf_buffer *) node;             
                                                                      
    if (bd->waiters == 0)                                             
4000dd28:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
4000dd2c:	80 a0 60 00 	cmp  %g1, 0                                    
4000dd30:	22 80 00 02 	be,a   4000dd38 <rtems_bdbuf_do_purge_dev+0x190>
4000dd34:	b8 10 20 01 	mov  1, %i4                                    
static void                                                           
rtems_bdbuf_discard_buffer (rtems_bdbuf_buffer *bd)                   
{                                                                     
  rtems_bdbuf_make_empty (bd);                                        
                                                                      
  if (bd->waiters == 0)                                               
4000dd38:	80 a0 60 00 	cmp  %g1, 0                                    
4000dd3c:	12 bf ff f4 	bne  4000dd0c <rtems_bdbuf_do_purge_dev+0x164> 
4000dd40:	f2 27 60 20 	st  %i1, [ %i5 + 0x20 ]                        
  {                                                                   
    rtems_bdbuf_remove_from_tree (bd);                                
4000dd44:	7f ff fc b5 	call  4000d018 <rtems_bdbuf_remove_from_tree>  
4000dd48:	90 10 00 1d 	mov  %i5, %o0                                  
    rtems_bdbuf_make_free_and_add_to_lru_list (bd);                   
4000dd4c:	7f ff fb e2 	call  4000ccd4 <rtems_bdbuf_make_free_and_add_to_lru_list>
4000dd50:	90 10 00 1d 	mov  %i5, %o0                                  
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000dd54:	10 bf ff ef 	b  4000dd10 <rtems_bdbuf_do_purge_dev+0x168>   
4000dd58:	fa 07 bf 74 	ld  [ %fp + -140 ], %i5                        
      wake_buffer_waiters = true;                                     
                                                                      
    rtems_bdbuf_discard_buffer (bd);                                  
  }                                                                   
                                                                      
  if (wake_buffer_waiters)                                            
4000dd5c:	02 80 00 04 	be  4000dd6c <rtems_bdbuf_do_purge_dev+0x1c4>  
4000dd60:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
    rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);                   
4000dd64:	7f ff fc 77 	call  4000cf40 <rtems_bdbuf_wake>              
4000dd68:	90 12 20 50 	or  %o0, 0x50, %o0	! 4001c450 <bdbuf_cache+0x74>
4000dd6c:	81 c7 e0 08 	ret                                            
4000dd70:	81 e8 00 00 	restore                                        
                                                                      

4000df90 <rtems_bdbuf_execute_read_request>: static rtems_status_code rtems_bdbuf_execute_read_request (rtems_disk_device *dd, rtems_bdbuf_buffer *bd, uint32_t transfer_count) {
4000df90:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
static size_t                                                         
rtems_bdbuf_read_request_size (uint32_t transfer_count)               
{                                                                     
  return sizeof (rtems_blkdev_request)                                
    + sizeof (rtems_blkdev_sg_buffer) * transfer_count;               
4000df94:	83 2e a0 04 	sll  %i2, 4, %g1                               
  /*                                                                  
   * TODO: This type of request structure is wrong and should be removed.
   */                                                                 
#define bdbuf_alloc(size) __builtin_alloca (size)                     
                                                                      
  req = bdbuf_alloc (rtems_bdbuf_read_request_size (transfer_count)); 
4000df98:	82 00 60 20 	add  %g1, 0x20, %g1                            
4000df9c:	9c 23 80 01 	sub  %sp, %g1, %sp                             
                                                                      
  req->req = RTEMS_BLKDEV_REQ_READ;                                   
  req->done = rtems_bdbuf_transfer_done;                              
4000dfa0:	03 10 00 36 	sethi  %hi(0x4000d800), %g1                    
4000dfa4:	82 10 61 28 	or  %g1, 0x128, %g1	! 4000d928 <rtems_bdbuf_transfer_done>
  /*                                                                  
   * TODO: This type of request structure is wrong and should be removed.
   */                                                                 
#define bdbuf_alloc(size) __builtin_alloca (size)                     
                                                                      
  req = bdbuf_alloc (rtems_bdbuf_read_request_size (transfer_count)); 
4000dfa8:	ba 03 a0 60 	add  %sp, 0x60, %i5                            
rtems_bdbuf_execute_read_request (rtems_disk_device  *dd,             
                                  rtems_bdbuf_buffer *bd,             
                                  uint32_t            transfer_count) 
{                                                                     
  rtems_blkdev_request *req = NULL;                                   
  rtems_blkdev_bnum media_block = bd->block;                          
4000dfac:	f6 06 60 18 	ld  [ %i1 + 0x18 ], %i3                        
  uint32_t media_blocks_per_block = dd->media_blocks_per_block;       
  uint32_t block_size = dd->block_size;                               
4000dfb0:	e0 06 20 24 	ld  [ %i0 + 0x24 ], %l0                        
                                  rtems_bdbuf_buffer *bd,             
                                  uint32_t            transfer_count) 
{                                                                     
  rtems_blkdev_request *req = NULL;                                   
  rtems_blkdev_bnum media_block = bd->block;                          
  uint32_t media_blocks_per_block = dd->media_blocks_per_block;       
4000dfb4:	e2 06 20 2c 	ld  [ %i0 + 0x2c ], %l1                        
#define bdbuf_alloc(size) __builtin_alloca (size)                     
                                                                      
  req = bdbuf_alloc (rtems_bdbuf_read_request_size (transfer_count)); 
                                                                      
  req->req = RTEMS_BLKDEV_REQ_READ;                                   
  req->done = rtems_bdbuf_transfer_done;                              
4000dfb8:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
  req->io_task = rtems_task_self ();                                  
4000dfbc:	40 00 0e 5d 	call  40011930 <rtems_task_self>               
4000dfc0:	c0 27 40 00 	clr  [ %i5 ]                                   
  req->bufnum = 0;                                                    
4000dfc4:	c0 27 60 10 	clr  [ %i5 + 0x10 ]                            
                                                                      
  req = bdbuf_alloc (rtems_bdbuf_read_request_size (transfer_count)); 
                                                                      
  req->req = RTEMS_BLKDEV_REQ_READ;                                   
  req->done = rtems_bdbuf_transfer_done;                              
  req->io_task = rtems_task_self ();                                  
4000dfc8:	d0 27 60 14 	st  %o0, [ %i5 + 0x14 ]                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000dfcc:	82 10 20 09 	mov  9, %g1                                    
4000dfd0:	c2 26 60 20 	st  %g1, [ %i1 + 0x20 ]                        
  req->io_task = rtems_task_self ();                                  
  req->bufnum = 0;                                                    
                                                                      
  rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);             
                                                                      
  req->bufs [0].user   = bd;                                          
4000dfd4:	f2 27 60 24 	st  %i1, [ %i5 + 0x24 ]                        
  req->bufs [0].block  = media_block;                                 
  req->bufs [0].length = block_size;                                  
  req->bufs [0].buffer = bd->buffer;                                  
4000dfd8:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
  req->bufnum = 0;                                                    
                                                                      
  rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);             
                                                                      
  req->bufs [0].user   = bd;                                          
  req->bufs [0].block  = media_block;                                 
4000dfdc:	f6 27 60 18 	st  %i3, [ %i5 + 0x18 ]                        
  req->bufs [0].length = block_size;                                  
4000dfe0:	e0 27 60 1c 	st  %l0, [ %i5 + 0x1c ]                        
  req->bufs [0].buffer = bd->buffer;                                  
4000dfe4:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
4000dfe8:	b8 10 00 1d 	mov  %i5, %i4                                  
{                                                                     
  rtems_blkdev_request *req = NULL;                                   
  rtems_blkdev_bnum media_block = bd->block;                          
  uint32_t media_blocks_per_block = dd->media_blocks_per_block;       
  uint32_t block_size = dd->block_size;                               
  uint32_t transfer_index = 1;                                        
4000dfec:	b2 10 20 01 	mov  1, %i1                                    
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000dff0:	a4 10 20 09 	mov  9, %l2                                    
  req->bufs [0].buffer = bd->buffer;                                  
                                                                      
  if (rtems_bdbuf_tracer)                                             
    rtems_bdbuf_show_users ("read", bd);                              
                                                                      
  while (transfer_index < transfer_count)                             
4000dff4:	80 a6 40 1a 	cmp  %i1, %i2                                  
4000dff8:	1a 80 00 09 	bcc  4000e01c <rtems_bdbuf_execute_read_request+0x8c>
4000dffc:	90 10 00 18 	mov  %i0, %o0                                  
  {                                                                   
    media_block += media_blocks_per_block;                            
4000e000:	b6 06 c0 11 	add  %i3, %l1, %i3                             
                                                                      
    bd = rtems_bdbuf_get_buffer_for_read_ahead (dd, media_block);     
4000e004:	92 10 00 1b 	mov  %i3, %o1                                  
4000e008:	7f ff fe 33 	call  4000d8d4 <rtems_bdbuf_get_buffer_for_read_ahead>
4000e00c:	b8 07 20 10 	add  %i4, 0x10, %i4                            
                                                                      
    if (bd == NULL)                                                   
4000e010:	80 a2 20 00 	cmp  %o0, 0                                    
4000e014:	32 80 00 09 	bne,a   4000e038 <rtems_bdbuf_execute_read_request+0xa8><== ALWAYS TAKEN
4000e018:	e4 22 20 20 	st  %l2, [ %o0 + 0x20 ]                        
      rtems_bdbuf_show_users ("read", bd);                            
                                                                      
    ++transfer_index;                                                 
  }                                                                   
                                                                      
  req->bufnum = transfer_index;                                       
4000e01c:	f2 27 60 10 	st  %i1, [ %i5 + 0x10 ]                        
                                                                      
  return rtems_bdbuf_execute_transfer_request (dd, req, true);        
4000e020:	90 10 00 18 	mov  %i0, %o0                                  
4000e024:	92 10 00 1d 	mov  %i5, %o1                                  
4000e028:	7f ff ff 69 	call  4000ddcc <rtems_bdbuf_execute_transfer_request>
4000e02c:	94 10 20 01 	mov  1, %o2                                    
4000e030:	81 c7 e0 08 	ret                                            
4000e034:	91 e8 00 08 	restore  %g0, %o0, %o0                         
    if (bd == NULL)                                                   
      break;                                                          
                                                                      
    rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_TRANSFER);           
                                                                      
    req->bufs [transfer_index].user   = bd;                           
4000e038:	d0 27 20 24 	st  %o0, [ %i4 + 0x24 ]                        
    req->bufs [transfer_index].block  = media_block;                  
4000e03c:	f6 27 20 18 	st  %i3, [ %i4 + 0x18 ]                        
    req->bufs [transfer_index].length = block_size;                   
4000e040:	e0 27 20 1c 	st  %l0, [ %i4 + 0x1c ]                        
    req->bufs [transfer_index].buffer = bd->buffer;                   
4000e044:	c2 02 20 1c 	ld  [ %o0 + 0x1c ], %g1                        
                                                                      
    if (rtems_bdbuf_tracer)                                           
      rtems_bdbuf_show_users ("read", bd);                            
                                                                      
    ++transfer_index;                                                 
4000e048:	b2 06 60 01 	inc  %i1                                       
    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;                   
4000e04c:	10 bf ff ea 	b  4000dff4 <rtems_bdbuf_execute_read_request+0x64>
4000e050:	c2 27 20 20 	st  %g1, [ %i4 + 0x20 ]                        
                                                                      

4000ccf8 <rtems_bdbuf_fatal>: #define RTEMS_BDBUF_AVL_MAX_HEIGHT (32) #endif static void rtems_bdbuf_fatal (rtems_fatal_code error) {
4000ccf8:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  rtems_fatal (RTEMS_FATAL_SOURCE_BDBUF, error);                      
4000ccfc:	90 10 20 03 	mov  3, %o0                                    <== NOT EXECUTED
4000cd00:	7f ff f1 42 	call  40009208 <rtems_fatal>                   <== NOT EXECUTED
4000cd04:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
                                                                      

4000cd50 <rtems_bdbuf_fatal_with_state>: } static void rtems_bdbuf_fatal_with_state (rtems_bdbuf_buf_state state, rtems_bdbuf_fatal_code error) {
4000cd50:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  rtems_bdbuf_fatal ((((uint32_t) state) << 16) | error);             
4000cd54:	b1 2e 20 10 	sll  %i0, 0x10, %i0                            <== NOT EXECUTED
4000cd58:	7f ff ff e8 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cd5c:	90 16 00 19 	or  %i0, %i1, %o0                              <== NOT EXECUTED
                                                                      

4000ec6c <rtems_bdbuf_get>: rtems_status_code rtems_bdbuf_get (rtems_disk_device *dd, rtems_blkdev_bnum block, rtems_bdbuf_buffer **bd_ptr) {
4000ec6c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code   sc = RTEMS_SUCCESSFUL;                          
  rtems_bdbuf_buffer *bd = NULL;                                      
  rtems_blkdev_bnum   media_block;                                    
                                                                      
  rtems_bdbuf_lock_cache ();                                          
4000ec70:	7f ff fc 41 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000ec74:	ba 10 00 18 	mov  %i0, %i5                                  
                                                                      
  sc = rtems_bdbuf_get_media_block (dd, block, &media_block);         
4000ec78:	90 10 00 18 	mov  %i0, %o0                                  
4000ec7c:	92 10 00 19 	mov  %i1, %o1                                  
4000ec80:	7f ff f8 97 	call  4000cedc <rtems_bdbuf_get_media_block>   
4000ec84:	94 07 bf fc 	add  %fp, -4, %o2                              
  if (sc == RTEMS_SUCCESSFUL)                                         
4000ec88:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000ec8c:	12 80 00 16 	bne  4000ece4 <rtems_bdbuf_get+0x78>           <== NEVER TAKEN
4000ec90:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
     */                                                               
    if (rtems_bdbuf_tracer)                                           
      printf ("bdbuf:get: %" PRIu32 " (%" PRIu32 ") (dev = %08x)\n",  
              media_block, block, (unsigned) dd->dev);                
                                                                      
    bd = rtems_bdbuf_get_buffer_for_access (dd, media_block);         
4000ec94:	7f ff fb 40 	call  4000d994 <rtems_bdbuf_get_buffer_for_access>
4000ec98:	90 10 00 1d 	mov  %i5, %o0                                  
4000ec9c:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    switch (bd->state)                                                
4000eca0:	d0 02 20 20 	ld  [ %o0 + 0x20 ], %o0                        
4000eca4:	80 a2 20 02 	cmp  %o0, 2                                    
4000eca8:	02 80 00 08 	be  4000ecc8 <rtems_bdbuf_get+0x5c>            
4000ecac:	80 a2 20 07 	cmp  %o0, 7                                    
4000ecb0:	02 80 00 08 	be  4000ecd0 <rtems_bdbuf_get+0x64>            
4000ecb4:	80 a2 20 01 	cmp  %o0, 1                                    
4000ecb8:	12 80 00 09 	bne  4000ecdc <rtems_bdbuf_get+0x70>           <== NEVER TAKEN
4000ecbc:	82 10 20 05 	mov  5, %g1                                    
4000ecc0:	10 80 00 0a 	b  4000ece8 <rtems_bdbuf_get+0x7c>             
4000ecc4:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000ecc8:	10 80 00 03 	b  4000ecd4 <rtems_bdbuf_get+0x68>             
4000eccc:	82 10 20 03 	mov  3, %g1                                    
4000ecd0:	82 10 20 04 	mov  4, %g1                                    
4000ecd4:	10 80 00 05 	b  4000ece8 <rtems_bdbuf_get+0x7c>             
4000ecd8:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
         * record of this so just gets the block to fill.             
         */                                                           
        rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_MODIFIED);
        break;                                                        
      default:                                                        
        rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_2);
4000ecdc:	7f ff f8 1d 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000ece0:	92 10 20 0c 	mov  0xc, %o1                                  <== NOT EXECUTED
rtems_bdbuf_get (rtems_disk_device   *dd,                             
                 rtems_blkdev_bnum    block,                          
                 rtems_bdbuf_buffer **bd_ptr)                         
{                                                                     
  rtems_status_code   sc = RTEMS_SUCCESSFUL;                          
  rtems_bdbuf_buffer *bd = NULL;                                      
4000ece4:	ba 10 20 00 	clr  %i5                                       <== NOT EXECUTED
      rtems_bdbuf_show_users ("get", bd);                             
      rtems_bdbuf_show_usage ();                                      
    }                                                                 
  }                                                                   
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000ece8:	7f ff fc 2e 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000ecec:	01 00 00 00 	nop                                            
                                                                      
  *bd_ptr = bd;                                                       
4000ecf0:	fa 26 80 00 	st  %i5, [ %i2 ]                               
                                                                      
  return sc;                                                          
}                                                                     
4000ecf4:	81 c7 e0 08 	ret                                            
4000ecf8:	81 e8 00 00 	restore                                        
                                                                      

4000d994 <rtems_bdbuf_get_buffer_for_access>: } static rtems_bdbuf_buffer * rtems_bdbuf_get_buffer_for_access (rtems_disk_device *dd, rtems_blkdev_bnum block) {
4000d994:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_bdbuf_buffer *bd = NULL;                                      
                                                                      
  do                                                                  
  {                                                                   
    bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dd, block);       
4000d998:	39 10 00 70 	sethi  %hi(0x4001c000), %i4                    
4000d99c:	b8 17 23 dc 	or  %i4, 0x3dc, %i4	! 4001c3dc <bdbuf_cache>   
4000d9a0:	b4 10 00 1c 	mov  %i4, %i2                                  
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_wait_for_buffer (void)                                    
{                                                                     
  if (!rtems_chain_is_empty (&bdbuf_cache.modified))                  
4000d9a4:	a0 07 20 50 	add  %i4, 0x50, %l0                            
           * It is essential that we wait here without a special wait count and
           * without the group in use.  Otherwise we could trigger a wait ping
           * pong with another recycle waiter.  The state of the buffer is
           * arbitrary afterwards.                                    
           */                                                         
          rtems_bdbuf_anonymous_wait (&bdbuf_cache.buffer_waiters);   
4000d9a8:	b6 07 20 74 	add  %i4, 0x74, %i3                            
        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);         
4000d9ac:	a2 07 20 6c 	add  %i4, 0x6c, %l1                            
        }                                                             
      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);           
4000d9b0:	a4 07 20 64 	add  %i4, 0x64, %l2                            
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4000d9b4:	a6 07 20 5c 	add  %i4, 0x5c, %l3                            
{                                                                     
  rtems_bdbuf_buffer *bd = NULL;                                      
                                                                      
  do                                                                  
  {                                                                   
    bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dd, block);       
4000d9b8:	d0 07 20 3c 	ld  [ %i4 + 0x3c ], %o0                        
4000d9bc:	92 10 00 18 	mov  %i0, %o1                                  
4000d9c0:	7f ff fd 2f 	call  4000ce7c <rtems_bdbuf_avl_search.isra.3> 
4000d9c4:	94 10 00 19 	mov  %i1, %o2                                  
                                                                      
    if (bd != NULL)                                                   
4000d9c8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000d9cc:	02 80 00 31 	be  4000da90 <rtems_bdbuf_get_buffer_for_access+0xfc>
4000d9d0:	90 10 00 18 	mov  %i0, %o0                                  
    {                                                                 
      if (bd->group->bds_per_group != dd->bds_per_group)              
4000d9d4:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
4000d9d8:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
4000d9dc:	c2 06 20 34 	ld  [ %i0 + 0x34 ], %g1                        
4000d9e0:	80 a0 80 01 	cmp  %g2, %g1                                  
4000d9e4:	02 80 00 4b 	be  4000db10 <rtems_bdbuf_get_buffer_for_access+0x17c>
4000d9e8:	29 10 00 36 	sethi  %hi(0x4000d800), %l4                    
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000d9ec:	aa 10 20 08 	mov  8, %l5                                    
static bool                                                           
rtems_bdbuf_wait_for_recycle (rtems_bdbuf_buffer *bd)                 
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
4000d9f0:	d0 07 60 20 	ld  [ %i5 + 0x20 ], %o0                        
4000d9f4:	80 a2 20 0a 	cmp  %o0, 0xa                                  
4000d9f8:	18 80 00 24 	bgu  4000da88 <rtems_bdbuf_get_buffer_for_access+0xf4><== NEVER TAKEN
4000d9fc:	82 15 21 68 	or  %l4, 0x168, %g1                            
4000da00:	91 2a 20 02 	sll  %o0, 2, %o0                               
4000da04:	c2 00 40 08 	ld  [ %g1 + %o0 ], %g1                         
4000da08:	81 c0 40 00 	jmp  %g1                                       
4000da0c:	01 00 00 00 	nop                                            
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
4000da10:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4000da14:	c4 07 40 00 	ld  [ %i5 ], %g2                               <== NOT EXECUTED
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000da18:	ea 27 60 20 	st  %l5, [ %i5 + 0x20 ]                        <== NOT EXECUTED
  previous       = the_node->previous;                                
  next->previous = previous;                                          
4000da1c:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           <== NOT EXECUTED
  previous->next = next;                                              
4000da20:	c4 20 40 00 	st  %g2, [ %g1 ]                               <== NOT EXECUTED
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000da24:	c2 06 a0 60 	ld  [ %i2 + 0x60 ], %g1                        <== NOT EXECUTED
                                                                      
  the_node->next = tail;                                              
4000da28:	e6 27 40 00 	st  %l3, [ %i5 ]                               <== NOT EXECUTED
  tail->previous = the_node;                                          
4000da2c:	fa 26 a0 60 	st  %i5, [ %i2 + 0x60 ]                        <== NOT EXECUTED
  old_last->next = the_node;                                          
4000da30:	fa 20 40 00 	st  %i5, [ %g1 ]                               <== 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_unprotected (&bd->link);                        
  rtems_chain_append_unprotected (&bdbuf_cache.sync, &bd->link);      
  rtems_bdbuf_wake_swapper ();                                        
4000da34:	7f ff fc e2 	call  4000cdbc <rtems_bdbuf_wake_swapper>      <== NOT EXECUTED
4000da38:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           <== NOT EXECUTED
static bool                                                           
rtems_bdbuf_wait_for_recycle (rtems_bdbuf_buffer *bd)                 
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
4000da3c:	10 bf ff ee 	b  4000d9f4 <rtems_bdbuf_get_buffer_for_access+0x60><== NOT EXECUTED
4000da40:	d0 07 60 20 	ld  [ %i5 + 0x20 ], %o0                        <== 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)                                         
4000da44:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
4000da48:	80 a0 60 00 	cmp  %g1, 0                                    
4000da4c:	02 80 00 29 	be  4000daf0 <rtems_bdbuf_get_buffer_for_access+0x15c><== NEVER TAKEN
4000da50:	01 00 00 00 	nop                                            
           * It is essential that we wait here without a special wait count and
           * without the group in use.  Otherwise we could trigger a wait ping
           * pong with another recycle waiter.  The state of the buffer is
           * arbitrary afterwards.                                    
           */                                                         
          rtems_bdbuf_anonymous_wait (&bdbuf_cache.buffer_waiters);   
4000da54:	7f ff fc e6 	call  4000cdec <rtems_bdbuf_anonymous_wait>    
4000da58:	90 10 00 1b 	mov  %i3, %o0                                  
{                                                                     
  rtems_bdbuf_buffer *bd = NULL;                                      
                                                                      
  do                                                                  
  {                                                                   
    bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dd, block);       
4000da5c:	10 bf ff d8 	b  4000d9bc <rtems_bdbuf_get_buffer_for_access+0x28>
4000da60:	d0 07 20 3c 	ld  [ %i4 + 0x3c ], %o0                        
        }                                                             
      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);           
4000da64:	90 10 00 1d 	mov  %i5, %o0                                  
4000da68:	10 80 00 04 	b  4000da78 <rtems_bdbuf_get_buffer_for_access+0xe4>
4000da6c:	92 10 00 12 	mov  %l2, %o1                                  
        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);         
4000da70:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4000da74:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
4000da78:	7f ff fc ee 	call  4000ce30 <rtems_bdbuf_wait>              
4000da7c:	01 00 00 00 	nop                                            
static bool                                                           
rtems_bdbuf_wait_for_recycle (rtems_bdbuf_buffer *bd)                 
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
4000da80:	10 bf ff dd 	b  4000d9f4 <rtems_bdbuf_get_buffer_for_access+0x60>
4000da84:	d0 07 60 20 	ld  [ %i5 + 0x20 ], %o0                        
      case RTEMS_BDBUF_STATE_TRANSFER:                                
      case RTEMS_BDBUF_STATE_TRANSFER_PURGED:                         
        rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);         
        break;                                                        
      default:                                                        
        rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_8);
4000da88:	10 80 00 18 	b  4000dae8 <rtems_bdbuf_get_buffer_for_access+0x154><== NOT EXECUTED
4000da8c:	92 10 20 11 	mov  0x11, %o1                                 <== NOT EXECUTED
        bd = NULL;                                                    
      }                                                               
    }                                                                 
    else                                                              
    {                                                                 
      bd = rtems_bdbuf_get_buffer_from_lru_list (dd, block);          
4000da90:	7f ff fe ad 	call  4000d544 <rtems_bdbuf_get_buffer_from_lru_list>
4000da94:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
      if (bd == NULL)                                                 
4000da98:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000da9c:	32 80 00 1e 	bne,a   4000db14 <rtems_bdbuf_get_buffer_for_access+0x180>
4000daa0:	39 10 00 71 	sethi  %hi(0x4001c400), %i4                    
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_wait_for_buffer (void)                                    
{                                                                     
  if (!rtems_chain_is_empty (&bdbuf_cache.modified))                  
4000daa4:	c2 07 20 4c 	ld  [ %i4 + 0x4c ], %g1	! 4001c44c <bdbuf_cache+0x70>
4000daa8:	80 a0 40 10 	cmp  %g1, %l0                                  
4000daac:	02 bf ff ea 	be  4000da54 <rtems_bdbuf_get_buffer_for_access+0xc0>
4000dab0:	01 00 00 00 	nop                                            
    rtems_bdbuf_wake_swapper ();                                      
4000dab4:	7f ff fc c2 	call  4000cdbc <rtems_bdbuf_wake_swapper>      
4000dab8:	01 00 00 00 	nop                                            
4000dabc:	30 bf ff e6 	b,a   4000da54 <rtems_bdbuf_get_buffer_for_access+0xc0>
        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);           
4000dac0:	90 10 00 1d 	mov  %i5, %o0                                  
4000dac4:	92 10 00 1b 	mov  %i3, %o1                                  
        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);         
4000dac8:	7f ff fc da 	call  4000ce30 <rtems_bdbuf_wait>              
4000dacc:	01 00 00 00 	nop                                            
static void                                                           
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)                  
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
4000dad0:	d0 07 60 20 	ld  [ %i5 + 0x20 ], %o0                        
4000dad4:	82 02 3f ff 	add  %o0, -1, %g1                              
4000dad8:	80 a0 60 09 	cmp  %g1, 9                                    
4000dadc:	08 80 00 12 	bleu  4000db24 <rtems_bdbuf_get_buffer_for_access+0x190><== ALWAYS TAKEN
4000dae0:	84 16 a1 40 	or  %i2, 0x140, %g2                            
      case RTEMS_BDBUF_STATE_TRANSFER:                                
      case RTEMS_BDBUF_STATE_TRANSFER_PURGED:                         
        rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);         
        break;                                                        
      default:                                                        
        rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_7);
4000dae4:	92 10 20 10 	mov  0x10, %o1                                 <== NOT EXECUTED
4000dae8:	7f ff fc 9a 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000daec:	01 00 00 00 	nop                                            <== NOT EXECUTED
    {                                                                 
      if (bd->group->bds_per_group != dd->bds_per_group)              
      {                                                               
        if (rtems_bdbuf_wait_for_recycle (bd))                        
        {                                                             
          rtems_bdbuf_remove_from_tree_and_lru_list (bd);             
4000daf0:	7f ff fe 82 	call  4000d4f8 <rtems_bdbuf_remove_from_tree_and_lru_list><== NOT EXECUTED
4000daf4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
          rtems_bdbuf_make_free_and_add_to_lru_list (bd);             
4000daf8:	7f ff fc 77 	call  4000ccd4 <rtems_bdbuf_make_free_and_add_to_lru_list><== NOT EXECUTED
4000dafc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
          rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);             
4000db00:	7f ff fd 10 	call  4000cf40 <rtems_bdbuf_wake>              <== NOT EXECUTED
4000db04:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
{                                                                     
  rtems_bdbuf_buffer *bd = NULL;                                      
                                                                      
  do                                                                  
  {                                                                   
    bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dd, block);       
4000db08:	10 bf ff ad 	b  4000d9bc <rtems_bdbuf_get_buffer_for_access+0x28><== NOT EXECUTED
4000db0c:	d0 07 20 3c 	ld  [ %i4 + 0x3c ], %o0                        <== 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);         
4000db10:	39 10 00 71 	sethi  %hi(0x4001c400), %i4                    
static void                                                           
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)                  
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
4000db14:	35 10 00 36 	sethi  %hi(0x4000d800), %i2                    
        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);         
4000db18:	b8 17 20 48 	or  %i4, 0x48, %i4                             
        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);           
4000db1c:	10 bf ff ed 	b  4000dad0 <rtems_bdbuf_get_buffer_for_access+0x13c>
4000db20:	b6 07 3f f8 	add  %i4, -8, %i3                              
static void                                                           
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)                  
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
4000db24:	83 28 60 02 	sll  %g1, 2, %g1                               
4000db28:	c2 00 80 01 	ld  [ %g2 + %g1 ], %g1                         
4000db2c:	81 c0 40 00 	jmp  %g1                                       
4000db30:	01 00 00 00 	nop                                            
  if (sc != RTEMS_SUCCESSFUL)                                         
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_WAIT_TRANS_EVNT);            
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_wait_for_access (rtems_bdbuf_buffer *bd)                  
4000db34:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)                    
{                                                                     
  --bd->group->users;                                                 
4000db38:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000db3c:	84 00 bf ff 	add  %g2, -1, %g2                              
4000db40:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4000db44:	c4 07 40 00 	ld  [ %i5 ], %g2                               
  previous       = the_node->previous;                                
4000db48:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
  next->previous = previous;                                          
4000db4c:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4000db50:	10 80 00 05 	b  4000db64 <rtems_bdbuf_get_buffer_for_access+0x1d0>
4000db54:	c4 20 40 00 	st  %g2, [ %g1 ]                               
        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);         
4000db58:	90 10 00 1d 	mov  %i5, %o0                                  
4000db5c:	10 bf ff db 	b  4000dac8 <rtems_bdbuf_get_buffer_for_access+0x134>
4000db60:	92 10 00 1c 	mov  %i4, %o1                                  
                                                                      
static rtems_bdbuf_buffer *                                           
rtems_bdbuf_get_buffer_for_access (rtems_disk_device *dd,             
                                   rtems_blkdev_bnum  block)          
{                                                                     
  rtems_bdbuf_buffer *bd = NULL;                                      
4000db64:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)                     
{                                                                     
  ++bd->group->users;                                                 
4000db68:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000db6c:	84 00 a0 01 	inc  %g2                                       
4000db70:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
                                                                      
  rtems_bdbuf_wait_for_access (bd);                                   
  rtems_bdbuf_group_obtain (bd);                                      
                                                                      
  return bd;                                                          
}                                                                     
4000db74:	81 c7 e0 08 	ret                                            
4000db78:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
4000db7c:	40 00 dc 9c 	call  40044dec <__end+0x2775c>                 <== NOT EXECUTED
4000db80:	40 00 dc 9c 	call  40044df0 <__end+0x27760>                 <== NOT EXECUTED
4000db84:	40 00 dc 5c 	call  40044cf4 <__end+0x27664>                 <== NOT EXECUTED
4000db88:	40 00 dc 8c 	call  40044db8 <__end+0x27728>                 <== NOT EXECUTED
4000db8c:	40 00 dc 8c 	call  40044dbc <__end+0x2772c>                 <== NOT EXECUTED
4000db90:	40 00 dc 8c 	call  40044dc0 <__end+0x27730>                 <== NOT EXECUTED
4000db94:	40 00 dc 9c 	call  40044e04 <__end+0x27774>                 <== NOT EXECUTED
4000db98:	40 00 dc 4c 	call  40044cc8 <__end+0x27638>                 <== NOT EXECUTED
4000db9c:	40 00 dc 44 	call  40044cac <__end+0x2761c>                 <== NOT EXECUTED
4000dba0:	40 00 dc 84 	call  40044db0 <__end+0x27720>                 <== NOT EXECUTED
4000dba4:	40 00 dc 9c 	call  40044e14 <__end+0x27784>                 <== NOT EXECUTED
                                                                      

4000d8d4 <rtems_bdbuf_get_buffer_for_read_ahead>: } static rtems_bdbuf_buffer * rtems_bdbuf_get_buffer_for_read_ahead (rtems_disk_device *dd, rtems_blkdev_bnum block) {
4000d8d4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_bdbuf_buffer *bd = NULL;                                      
                                                                      
  bd = rtems_bdbuf_avl_search (&bdbuf_cache.tree, dd, block);         
4000d8d8:	03 10 00 71 	sethi  %hi(0x4001c400), %g1                    
4000d8dc:	d0 00 60 18 	ld  [ %g1 + 0x18 ], %o0	! 4001c418 <bdbuf_cache+0x3c>
4000d8e0:	92 10 00 18 	mov  %i0, %o1                                  
4000d8e4:	7f ff fd 66 	call  4000ce7c <rtems_bdbuf_avl_search.isra.3> 
4000d8e8:	94 10 00 19 	mov  %i1, %o2                                  
                                                                      
  if (bd == NULL)                                                     
4000d8ec:	80 a2 20 00 	cmp  %o0, 0                                    
4000d8f0:	12 80 00 0c 	bne  4000d920 <rtems_bdbuf_get_buffer_for_read_ahead+0x4c><== NEVER TAKEN
4000d8f4:	82 10 20 00 	clr  %g1                                       
  {                                                                   
    bd = rtems_bdbuf_get_buffer_from_lru_list (dd, block);            
4000d8f8:	90 10 00 18 	mov  %i0, %o0                                  
4000d8fc:	7f ff ff 12 	call  4000d544 <rtems_bdbuf_get_buffer_from_lru_list>
4000d900:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
    if (bd != NULL)                                                   
4000d904:	82 92 20 00 	orcc  %o0, 0, %g1                              
4000d908:	02 80 00 06 	be  4000d920 <rtems_bdbuf_get_buffer_for_read_ahead+0x4c><== NEVER TAKEN
4000d90c:	01 00 00 00 	nop                                            
                                                                      
static rtems_bdbuf_buffer *                                           
rtems_bdbuf_get_buffer_for_read_ahead (rtems_disk_device *dd,         
                                       rtems_blkdev_bnum  block)      
{                                                                     
  rtems_bdbuf_buffer *bd = NULL;                                      
4000d910:	c4 00 60 28 	ld  [ %g1 + 0x28 ], %g2                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)                     
{                                                                     
  ++bd->group->users;                                                 
4000d914:	c6 00 a0 0c 	ld  [ %g2 + 0xc ], %g3                         
4000d918:	86 00 e0 01 	inc  %g3                                       
4000d91c:	c6 20 a0 0c 	st  %g3, [ %g2 + 0xc ]                         
     * thus no need for a read ahead.                                 
     */                                                               
    bd = NULL;                                                        
                                                                      
  return bd;                                                          
}                                                                     
4000d920:	81 c7 e0 08 	ret                                            
4000d924:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000d544 <rtems_bdbuf_get_buffer_from_lru_list>: } static rtems_bdbuf_buffer * rtems_bdbuf_get_buffer_from_lru_list (rtems_disk_device *dd, rtems_blkdev_bnum block) {
4000d544:	9d e3 bf 20 	save  %sp, -224, %sp                           
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000d548:	37 10 00 70 	sethi  %hi(0x4001c000), %i3                    
4000d54c:	b6 16 e3 dc 	or  %i3, 0x3dc, %i3	! 4001c3dc <bdbuf_cache>   
4000d550:	f8 06 e0 40 	ld  [ %i3 + 0x40 ], %i4                        
  rtems_chain_node *node = rtems_chain_first (&bdbuf_cache.lru);      
                                                                      
  while (!rtems_chain_is_tail (&bdbuf_cache.lru, node))               
4000d554:	a4 06 e0 44 	add  %i3, 0x44, %l2                            
       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);                   
4000d558:	a6 06 e0 74 	add  %i3, 0x74, %l3                            
rtems_bdbuf_get_buffer_from_lru_list (rtems_disk_device *dd,          
                                      rtems_blkdev_bnum  block)       
{                                                                     
  rtems_chain_node *node = rtems_chain_first (&bdbuf_cache.lru);      
                                                                      
  while (!rtems_chain_is_tail (&bdbuf_cache.lru, node))               
4000d55c:	80 a7 00 12 	cmp  %i4, %l2                                  
4000d560:	02 80 00 db 	be  4000d8cc <rtems_bdbuf_get_buffer_from_lru_list+0x388>
4000d564:	01 00 00 00 	nop                                            
              bd->group->bds_per_group, dd->bds_per_group);           
                                                                      
    /*                                                                
     * If nobody waits for this BD, we may recycle it.                
     */                                                               
    if (bd->waiters == 0)                                             
4000d568:	c2 07 20 24 	ld  [ %i4 + 0x24 ], %g1                        
4000d56c:	80 a0 60 00 	cmp  %g1, 0                                    
4000d570:	32 bf ff fb 	bne,a   4000d55c <rtems_bdbuf_get_buffer_from_lru_list+0x18>
4000d574:	f8 07 00 00 	ld  [ %i4 ], %i4                               
    {                                                                 
      if (bd->group->bds_per_group == dd->bds_per_group)              
4000d578:	fa 07 20 28 	ld  [ %i4 + 0x28 ], %i5                        
4000d57c:	f4 06 20 34 	ld  [ %i0 + 0x34 ], %i2                        
4000d580:	d2 07 60 08 	ld  [ %i5 + 8 ], %o1                           
4000d584:	80 a2 40 1a 	cmp  %o1, %i2                                  
4000d588:	32 80 00 06 	bne,a   4000d5a0 <rtems_bdbuf_get_buffer_from_lru_list+0x5c>
4000d58c:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
      {                                                               
        rtems_bdbuf_remove_from_tree_and_lru_list (bd);               
4000d590:	7f ff ff da 	call  4000d4f8 <rtems_bdbuf_remove_from_tree_and_lru_list>
4000d594:	90 10 00 1c 	mov  %i4, %o0                                  
4000d598:	10 80 00 2f 	b  4000d654 <rtems_bdbuf_get_buffer_from_lru_list+0x110>
4000d59c:	84 10 00 1c 	mov  %i4, %g2                                  
                                                                      
        empty_bd = bd;                                                
      }                                                               
      else if (bd->group->users == 0)                                 
4000d5a0:	80 a0 60 00 	cmp  %g1, 0                                    
4000d5a4:	32 bf ff ee 	bne,a   4000d55c <rtems_bdbuf_get_buffer_from_lru_list+0x18>
4000d5a8:	f8 07 00 00 	ld  [ %i4 ], %i4                               
  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; 
4000d5ac:	d0 06 e0 20 	ld  [ %i3 + 0x20 ], %o0                        
4000d5b0:	40 00 2a 47 	call  40017ecc <.udiv>                         
4000d5b4:	e0 07 60 10 	ld  [ %i5 + 0x10 ], %l0                        
                                                                      
  for (b = 0, bd = group->bdbuf;                                      
4000d5b8:	a2 10 20 00 	clr  %l1                                       
       b < group->bds_per_group;                                      
       b++, bd += bufs_per_bd)                                        
4000d5bc:	83 2a 20 03 	sll  %o0, 3, %g1                               
4000d5c0:	91 2a 20 06 	sll  %o0, 6, %o0                               
4000d5c4:	a8 22 00 01 	sub  %o0, %g1, %l4                             
            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;                                      
4000d5c8:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
4000d5cc:	80 a4 40 01 	cmp  %l1, %g1                                  
4000d5d0:	1a 80 00 06 	bcc  4000d5e8 <rtems_bdbuf_get_buffer_from_lru_list+0xa4>
4000d5d4:	90 10 00 10 	mov  %l0, %o0                                  
       b < group->bds_per_group;                                      
       b++, bd += bufs_per_bd)                                        
    rtems_bdbuf_remove_from_tree_and_lru_list (bd);                   
4000d5d8:	7f ff ff c8 	call  4000d4f8 <rtems_bdbuf_remove_from_tree_and_lru_list>
4000d5dc:	a2 04 60 01 	inc  %l1                                       
                                                                      
  bufs_per_bd = bdbuf_cache.max_bds_per_group / group->bds_per_group; 
                                                                      
  for (b = 0, bd = group->bdbuf;                                      
       b < group->bds_per_group;                                      
       b++, bd += bufs_per_bd)                                        
4000d5e0:	10 bf ff fa 	b  4000d5c8 <rtems_bdbuf_get_buffer_from_lru_list+0x84>
4000d5e4:	a0 04 00 14 	add  %l0, %l4, %l0                             
    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;    
4000d5e8:	d0 06 e0 20 	ld  [ %i3 + 0x20 ], %o0                        
  for (b = 0, bd = group->bdbuf;                                      
       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;                           
4000d5ec:	f4 27 60 08 	st  %i2, [ %i5 + 8 ]                           
  bufs_per_bd = bdbuf_cache.max_bds_per_group / new_bds_per_group;    
4000d5f0:	40 00 2a 37 	call  40017ecc <.udiv>                         
4000d5f4:	92 10 00 1a 	mov  %i2, %o1                                  
                                                                      
  for (b = 1, bd = group->bdbuf + bufs_per_bd;                        
4000d5f8:	e0 07 60 10 	ld  [ %i5 + 0x10 ], %l0                        
4000d5fc:	83 2a 20 03 	sll  %o0, 3, %g1                               
4000d600:	a3 2a 20 06 	sll  %o0, 6, %l1                               
4000d604:	b4 10 20 01 	mov  1, %i2                                    
4000d608:	a2 24 40 01 	sub  %l1, %g1, %l1                             
4000d60c:	a0 04 00 11 	add  %l0, %l1, %l0                             
4000d610:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
4000d614:	80 a6 80 01 	cmp  %i2, %g1                                  
4000d618:	1a 80 00 06 	bcc  4000d630 <rtems_bdbuf_get_buffer_from_lru_list+0xec>
4000d61c:	90 10 00 10 	mov  %l0, %o0                                  
       b < group->bds_per_group;                                      
       b++, bd += bufs_per_bd)                                        
    rtems_bdbuf_make_free_and_add_to_lru_list (bd);                   
4000d620:	7f ff fd ad 	call  4000ccd4 <rtems_bdbuf_make_free_and_add_to_lru_list>
4000d624:	b4 06 a0 01 	inc  %i2                                       
  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;                        
       b < group->bds_per_group;                                      
       b++, bd += bufs_per_bd)                                        
4000d628:	10 bf ff fa 	b  4000d610 <rtems_bdbuf_get_buffer_from_lru_list+0xcc>
4000d62c:	a0 04 00 11 	add  %l0, %l1, %l0                             
    rtems_bdbuf_make_free_and_add_to_lru_list (bd);                   
                                                                      
  if (b > 1)                                                          
4000d630:	80 a6 a0 01 	cmp  %i2, 1                                    
4000d634:	28 80 00 05 	bleu,a   4000d648 <rtems_bdbuf_get_buffer_from_lru_list+0x104>
4000d638:	c4 07 60 10 	ld  [ %i5 + 0x10 ], %g2                        
    rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);                   
4000d63c:	7f ff fe 41 	call  4000cf40 <rtems_bdbuf_wake>              
4000d640:	90 10 00 13 	mov  %l3, %o0                                  
                                                                      
  return group->bdbuf;                                                
4000d644:	c4 07 60 10 	ld  [ %i5 + 0x10 ], %g2                        
      }                                                               
      else if (bd->group->users == 0)                                 
        empty_bd = rtems_bdbuf_group_realloc (bd->group, dd->bds_per_group);
    }                                                                 
                                                                      
    if (empty_bd != NULL)                                             
4000d648:	80 a0 a0 00 	cmp  %g2, 0                                    
4000d64c:	22 bf ff c4 	be,a   4000d55c <rtems_bdbuf_get_buffer_from_lru_list+0x18><== NEVER TAKEN
4000d650:	f8 07 00 00 	ld  [ %i4 ], %i4                               <== NOT EXECUTED
static void                                                           
rtems_bdbuf_setup_empty_buffer (rtems_bdbuf_buffer *bd,               
                                rtems_disk_device  *dd,               
                                rtems_blkdev_bnum   block)            
{                                                                     
  bd->dd        = dd ;                                                
4000d654:	f0 20 a0 14 	st  %i0, [ %g2 + 0x14 ]                        
  bd->block     = block;                                              
  bd->avl.left  = NULL;                                               
4000d658:	c0 20 a0 08 	clr  [ %g2 + 8 ]                               
  bd->avl.right = NULL;                                               
4000d65c:	c0 20 a0 0c 	clr  [ %g2 + 0xc ]                             
                       rtems_bdbuf_buffer*  node)                     
{                                                                     
  const rtems_disk_device *dd = node->dd;                             
  rtems_blkdev_bnum block = node->block;                              
                                                                      
  rtems_bdbuf_buffer*  p = *root;                                     
4000d660:	c2 06 e0 3c 	ld  [ %i3 + 0x3c ], %g1                        
rtems_bdbuf_setup_empty_buffer (rtems_bdbuf_buffer *bd,               
                                rtems_disk_device  *dd,               
                                rtems_blkdev_bnum   block)            
{                                                                     
  bd->dd        = dd ;                                                
  bd->block     = block;                                              
4000d664:	f2 20 a0 18 	st  %i1, [ %g2 + 0x18 ]                        
  rtems_bdbuf_buffer*  buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];         
  rtems_bdbuf_buffer** buf_prev = buf_stack;                          
                                                                      
  bool modified = false;                                              
                                                                      
  if (p == NULL)                                                      
4000d668:	80 a0 60 00 	cmp  %g1, 0                                    
4000d66c:	02 80 00 07 	be  4000d688 <rtems_bdbuf_get_buffer_from_lru_list+0x144>
4000d670:	c0 20 a0 24 	clr  [ %g2 + 0x24 ]                            
4000d674:	ba 07 bf 80 	add  %fp, -128, %i5                            
    *buf_prev++ = p;                                                  
                                                                      
    if (((uintptr_t) p->dd < (uintptr_t) dd)                          
        || ((p->dd == dd) && (p->block < block)))                     
    {                                                                 
      p->avl.cache = 1;                                               
4000d678:	b8 10 20 01 	mov  1, %i4                                    
4000d67c:	9e 10 00 1d 	mov  %i5, %o7                                  
        break;                                                        
      }                                                               
    }                                                                 
    else if ((p->dd != dd) || (p->block != block))                    
    {                                                                 
      p->avl.cache = -1;                                              
4000d680:	10 80 00 09 	b  4000d6a4 <rtems_bdbuf_get_buffer_from_lru_list+0x160>
4000d684:	b4 10 3f ff 	mov  -1, %i2                                   
                                                                      
  bool modified = false;                                              
                                                                      
  if (p == NULL)                                                      
  {                                                                   
    *root = node;                                                     
4000d688:	c4 26 e0 3c 	st  %g2, [ %i3 + 0x3c ]                        
    node->avl.left = NULL;                                            
4000d68c:	c0 20 a0 08 	clr  [ %g2 + 8 ]                               
    node->avl.right = NULL;                                           
4000d690:	c0 20 a0 0c 	clr  [ %g2 + 0xc ]                             
    node->avl.bal = 0;                                                
4000d694:	10 80 00 8a 	b  4000d8bc <rtems_bdbuf_get_buffer_from_lru_list+0x378>
4000d698:	c0 28 a0 11 	clrb  [ %g2 + 0x11 ]                           
  rtems_bdbuf_buffer*  buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];         
  rtems_bdbuf_buffer** buf_prev = buf_stack;                          
                                                                      
  bool modified = false;                                              
                                                                      
  if (p == NULL)                                                      
4000d69c:	ba 10 00 04 	mov  %g4, %i5                                  
4000d6a0:	82 10 00 03 	mov  %g3, %g1                                  
                                                                      
  while (p != NULL)                                                   
  {                                                                   
    *buf_prev++ = p;                                                  
                                                                      
    if (((uintptr_t) p->dd < (uintptr_t) dd)                          
4000d6a4:	c6 00 60 14 	ld  [ %g1 + 0x14 ], %g3                        
    return 0;                                                         
  }                                                                   
                                                                      
  while (p != NULL)                                                   
  {                                                                   
    *buf_prev++ = p;                                                  
4000d6a8:	88 07 60 04 	add  %i5, 4, %g4                               
                                                                      
    if (((uintptr_t) p->dd < (uintptr_t) dd)                          
4000d6ac:	80 a0 c0 18 	cmp  %g3, %i0                                  
4000d6b0:	0a 80 00 09 	bcs  4000d6d4 <rtems_bdbuf_get_buffer_from_lru_list+0x190>
4000d6b4:	c2 21 3f fc 	st  %g1, [ %g4 + -4 ]                          
        || ((p->dd == dd) && (p->block < block)))                     
4000d6b8:	80 a0 c0 18 	cmp  %g3, %i0                                  
4000d6bc:	32 80 00 0f 	bne,a   4000d6f8 <rtems_bdbuf_get_buffer_from_lru_list+0x1b4>
4000d6c0:	c6 00 60 08 	ld  [ %g1 + 8 ], %g3                           
4000d6c4:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
4000d6c8:	80 a0 c0 19 	cmp  %g3, %i1                                  
4000d6cc:	1a 80 00 08 	bcc  4000d6ec <rtems_bdbuf_get_buffer_from_lru_list+0x1a8>
4000d6d0:	01 00 00 00 	nop                                            
    {                                                                 
      p->avl.cache = 1;                                               
      q = p->avl.right;                                               
4000d6d4:	c6 00 60 0c 	ld  [ %g1 + 0xc ], %g3                         
      if (q == NULL)                                                  
4000d6d8:	80 a0 e0 00 	cmp  %g3, 0                                    
4000d6dc:	12 bf ff f0 	bne  4000d69c <rtems_bdbuf_get_buffer_from_lru_list+0x158>
4000d6e0:	f8 28 60 10 	stb  %i4, [ %g1 + 0x10 ]                       
      {                                                               
        q = node;                                                     
        p->avl.right = q = node;                                      
4000d6e4:	10 80 00 09 	b  4000d708 <rtems_bdbuf_get_buffer_from_lru_list+0x1c4>
4000d6e8:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
        break;                                                        
      }                                                               
    }                                                                 
    else if ((p->dd != dd) || (p->block != block))                    
4000d6ec:	02 80 00 72 	be  4000d8b4 <rtems_bdbuf_get_buffer_from_lru_list+0x370><== NEVER TAKEN
4000d6f0:	01 00 00 00 	nop                                            
    {                                                                 
      p->avl.cache = -1;                                              
      q = p->avl.left;                                                
4000d6f4:	c6 00 60 08 	ld  [ %g1 + 8 ], %g3                           
      if (q == NULL)                                                  
4000d6f8:	80 a0 e0 00 	cmp  %g3, 0                                    
4000d6fc:	12 bf ff e8 	bne  4000d69c <rtems_bdbuf_get_buffer_from_lru_list+0x158>
4000d700:	f4 28 60 10 	stb  %i2, [ %g1 + 0x10 ]                       
      {                                                               
        q = node;                                                     
        p->avl.left = q;                                              
4000d704:	c4 20 60 08 	st  %g2, [ %g1 + 8 ]                           
    }                                                                 
                                                                      
    p = q;                                                            
  }                                                                   
                                                                      
  q->avl.left = q->avl.right = NULL;                                  
4000d708:	c0 20 a0 0c 	clr  [ %g2 + 0xc ]                             
4000d70c:	c0 20 a0 08 	clr  [ %g2 + 8 ]                               
  q->avl.bal = 0;                                                     
4000d710:	c0 28 a0 11 	clrb  [ %g2 + 0x11 ]                           
          p->avl.bal = 0;                                             
          modified = false;                                           
          break;                                                      
                                                                      
        case 0:                                                       
          p->avl.bal = 1;                                             
4000d714:	b8 10 20 01 	mov  1, %i4                                    
            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;
4000d718:	b2 10 3f ff 	mov  -1, %i1                                   
  modified = true;                                                    
  buf_prev--;                                                         
                                                                      
  while (modified)                                                    
  {                                                                   
    if (p->avl.cache == -1)                                           
4000d71c:	c8 48 60 10 	ldsb  [ %g1 + 0x10 ], %g4                      
4000d720:	c6 08 60 11 	ldub  [ %g1 + 0x11 ], %g3                      
4000d724:	80 a1 3f ff 	cmp  %g4, -1                                   
    {                                                                 
      switch (p->avl.bal)                                             
4000d728:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
  modified = true;                                                    
  buf_prev--;                                                         
                                                                      
  while (modified)                                                    
  {                                                                   
    if (p->avl.cache == -1)                                           
4000d72c:	12 80 00 27 	bne  4000d7c8 <rtems_bdbuf_get_buffer_from_lru_list+0x284>
4000d730:	87 38 e0 18 	sra  %g3, 0x18, %g3                            
    {                                                                 
      switch (p->avl.bal)                                             
4000d734:	80 a0 e0 00 	cmp  %g3, 0                                    
4000d738:	02 80 00 08 	be  4000d758 <rtems_bdbuf_get_buffer_from_lru_list+0x214>
4000d73c:	80 a0 e0 01 	cmp  %g3, 1                                    
4000d740:	02 80 00 29 	be  4000d7e4 <rtems_bdbuf_get_buffer_from_lru_list+0x2a0>
4000d744:	80 a0 ff ff 	cmp  %g3, -1                                   
4000d748:	32 80 00 4c 	bne,a   4000d878 <rtems_bdbuf_get_buffer_from_lru_list+0x334><== NEVER TAKEN
4000d74c:	86 10 20 01 	mov  1, %g3                                    <== NOT EXECUTED
        case 0:                                                       
          p->avl.bal = -1;                                            
          break;                                                      
                                                                      
        case -1:                                                      
          p1 = p->avl.left;                                           
4000d750:	10 80 00 04 	b  4000d760 <rtems_bdbuf_get_buffer_from_lru_list+0x21c>
4000d754:	c6 00 60 08 	ld  [ %g1 + 8 ], %g3                           
          p->avl.bal = 0;                                             
          modified = false;                                           
          break;                                                      
                                                                      
        case 0:                                                       
          p->avl.bal = -1;                                            
4000d758:	10 80 00 47 	b  4000d874 <rtems_bdbuf_get_buffer_from_lru_list+0x330>
4000d75c:	c8 28 60 11 	stb  %g4, [ %g1 + 0x11 ]                       
          break;                                                      
                                                                      
        case -1:                                                      
          p1 = p->avl.left;                                           
          if (p1->avl.bal == -1) /* simple LL-turn */                 
4000d760:	c8 48 e0 11 	ldsb  [ %g3 + 0x11 ], %g4                      
4000d764:	80 a1 3f ff 	cmp  %g4, -1                                   
4000d768:	12 80 00 05 	bne  4000d77c <rtems_bdbuf_get_buffer_from_lru_list+0x238>
4000d76c:	c8 00 e0 0c 	ld  [ %g3 + 0xc ], %g4                         
          {                                                           
            p->avl.left = p1->avl.right;                              
4000d770:	c8 20 60 08 	st  %g4, [ %g1 + 8 ]                           
            p1->avl.right = p;                                        
4000d774:	10 80 00 27 	b  4000d810 <rtems_bdbuf_get_buffer_from_lru_list+0x2cc>
4000d778:	c2 20 e0 0c 	st  %g1, [ %g3 + 0xc ]                         
            p = p1;                                                   
          }                                                           
          else /* double LR-turn */                                   
          {                                                           
            p2 = p1->avl.right;                                       
            p1->avl.right = p2->avl.left;                             
4000d77c:	f0 01 20 08 	ld  [ %g4 + 8 ], %i0                           
            p->avl.bal = 0;                                           
            p = p1;                                                   
          }                                                           
          else /* double LR-turn */                                   
          {                                                           
            p2 = p1->avl.right;                                       
4000d780:	b4 10 00 04 	mov  %g4, %i2                                  
            p1->avl.right = p2->avl.left;                             
4000d784:	f0 20 e0 0c 	st  %i0, [ %g3 + 0xc ]                         
            p2->avl.left = p1;                                        
            p->avl.left = p2->avl.right;                              
4000d788:	f0 01 20 0c 	ld  [ %g4 + 0xc ], %i0                         
          }                                                           
          else /* double LR-turn */                                   
          {                                                           
            p2 = p1->avl.right;                                       
            p1->avl.right = p2->avl.left;                             
            p2->avl.left = p1;                                        
4000d78c:	c6 21 20 08 	st  %g3, [ %g4 + 8 ]                           
            p->avl.left = p2->avl.right;                              
4000d790:	f0 20 60 08 	st  %i0, [ %g1 + 8 ]                           
            p2->avl.right = p;                                        
            if (p2->avl.bal == -1) p->avl.bal = +1; else p->avl.bal = 0;
4000d794:	f0 49 20 11 	ldsb  [ %g4 + 0x11 ], %i0                      
4000d798:	80 a6 3f ff 	cmp  %i0, -1                                   
4000d79c:	12 80 00 04 	bne  4000d7ac <rtems_bdbuf_get_buffer_from_lru_list+0x268>
4000d7a0:	c2 21 20 0c 	st  %g1, [ %g4 + 0xc ]                         
4000d7a4:	10 80 00 03 	b  4000d7b0 <rtems_bdbuf_get_buffer_from_lru_list+0x26c>
4000d7a8:	f8 28 60 11 	stb  %i4, [ %g1 + 0x11 ]                       
4000d7ac:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
            if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
4000d7b0:	c2 49 20 11 	ldsb  [ %g4 + 0x11 ], %g1                      
4000d7b4:	80 a0 60 01 	cmp  %g1, 1                                    
4000d7b8:	32 80 00 2b 	bne,a   4000d864 <rtems_bdbuf_get_buffer_from_lru_list+0x320>
4000d7bc:	c0 28 e0 11 	clrb  [ %g3 + 0x11 ]                           
4000d7c0:	10 80 00 29 	b  4000d864 <rtems_bdbuf_get_buffer_from_lru_list+0x320>
4000d7c4:	f2 28 e0 11 	stb  %i1, [ %g3 + 0x11 ]                       
          break;                                                      
      }                                                               
    }                                                                 
    else                                                              
    {                                                                 
      switch (p->avl.bal)                                             
4000d7c8:	80 a0 e0 00 	cmp  %g3, 0                                    
4000d7cc:	02 80 00 08 	be  4000d7ec <rtems_bdbuf_get_buffer_from_lru_list+0x2a8>
4000d7d0:	80 a0 e0 01 	cmp  %g3, 1                                    
4000d7d4:	02 80 00 08 	be  4000d7f4 <rtems_bdbuf_get_buffer_from_lru_list+0x2b0>
4000d7d8:	80 a0 ff ff 	cmp  %g3, -1                                   
4000d7dc:	32 80 00 27 	bne,a   4000d878 <rtems_bdbuf_get_buffer_from_lru_list+0x334><== NEVER TAKEN
4000d7e0:	86 10 20 01 	mov  1, %g3                                    <== NOT EXECUTED
      {                                                               
        case -1:                                                      
          p->avl.bal = 0;                                             
4000d7e4:	10 80 00 22 	b  4000d86c <rtems_bdbuf_get_buffer_from_lru_list+0x328>
4000d7e8:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
          modified = false;                                           
          break;                                                      
                                                                      
        case 0:                                                       
          p->avl.bal = 1;                                             
4000d7ec:	10 80 00 22 	b  4000d874 <rtems_bdbuf_get_buffer_from_lru_list+0x330>
4000d7f0:	f8 28 60 11 	stb  %i4, [ %g1 + 0x11 ]                       
          break;                                                      
                                                                      
        case 1:                                                       
          p1 = p->avl.right;                                          
4000d7f4:	c6 00 60 0c 	ld  [ %g1 + 0xc ], %g3                         
          if (p1->avl.bal == 1) /* simple RR-turn */                  
4000d7f8:	c8 48 e0 11 	ldsb  [ %g3 + 0x11 ], %g4                      
4000d7fc:	80 a1 20 01 	cmp  %g4, 1                                    
4000d800:	12 80 00 07 	bne  4000d81c <rtems_bdbuf_get_buffer_from_lru_list+0x2d8>
4000d804:	c8 00 e0 08 	ld  [ %g3 + 8 ], %g4                           
          {                                                           
            p->avl.right = p1->avl.left;                              
4000d808:	c8 20 60 0c 	st  %g4, [ %g1 + 0xc ]                         
            p1->avl.left = p;                                         
4000d80c:	c2 20 e0 08 	st  %g1, [ %g3 + 8 ]                           
            p->avl.bal = 0;                                           
4000d810:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
4000d814:	10 80 00 14 	b  4000d864 <rtems_bdbuf_get_buffer_from_lru_list+0x320>
4000d818:	b4 10 00 03 	mov  %g3, %i2                                  
            p = p1;                                                   
          }                                                           
          else /* double RL-turn */                                   
          {                                                           
            p2 = p1->avl.left;                                        
            p1->avl.left = p2->avl.right;                             
4000d81c:	f0 01 20 0c 	ld  [ %g4 + 0xc ], %i0                         
            p->avl.bal = 0;                                           
            p = p1;                                                   
          }                                                           
          else /* double RL-turn */                                   
          {                                                           
            p2 = p1->avl.left;                                        
4000d820:	b4 10 00 04 	mov  %g4, %i2                                  
            p1->avl.left = p2->avl.right;                             
4000d824:	f0 20 e0 08 	st  %i0, [ %g3 + 8 ]                           
            p2->avl.right = p1;                                       
            p->avl.right = p2->avl.left;                              
4000d828:	f0 01 20 08 	ld  [ %g4 + 8 ], %i0                           
          }                                                           
          else /* double RL-turn */                                   
          {                                                           
            p2 = p1->avl.left;                                        
            p1->avl.left = p2->avl.right;                             
            p2->avl.right = p1;                                       
4000d82c:	c6 21 20 0c 	st  %g3, [ %g4 + 0xc ]                         
            p->avl.right = p2->avl.left;                              
4000d830:	f0 20 60 0c 	st  %i0, [ %g1 + 0xc ]                         
            p2->avl.left = p;                                         
            if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
4000d834:	f0 49 20 11 	ldsb  [ %g4 + 0x11 ], %i0                      
4000d838:	80 a6 20 01 	cmp  %i0, 1                                    
4000d83c:	12 80 00 04 	bne  4000d84c <rtems_bdbuf_get_buffer_from_lru_list+0x308>
4000d840:	c2 21 20 08 	st  %g1, [ %g4 + 8 ]                           
4000d844:	10 80 00 03 	b  4000d850 <rtems_bdbuf_get_buffer_from_lru_list+0x30c>
4000d848:	f2 28 60 11 	stb  %i1, [ %g1 + 0x11 ]                       
4000d84c:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
            if (p2->avl.bal == -1) p1->avl.bal = +1; else p1->avl.bal = 0;
4000d850:	c2 49 20 11 	ldsb  [ %g4 + 0x11 ], %g1                      
4000d854:	80 a0 7f ff 	cmp  %g1, -1                                   
4000d858:	32 80 00 03 	bne,a   4000d864 <rtems_bdbuf_get_buffer_from_lru_list+0x320><== ALWAYS TAKEN
4000d85c:	c0 28 e0 11 	clrb  [ %g3 + 0x11 ]                           
4000d860:	f8 28 e0 11 	stb  %i4, [ %g3 + 0x11 ]                       <== NOT EXECUTED
            p = p2;                                                   
          }                                                           
          p->avl.bal = 0;                                             
4000d864:	c0 2e a0 11 	clrb  [ %i2 + 0x11 ]                           
4000d868:	82 10 00 1a 	mov  %i2, %g1                                  
          modified = false;                                           
4000d86c:	10 80 00 03 	b  4000d878 <rtems_bdbuf_get_buffer_from_lru_list+0x334>
4000d870:	86 10 20 00 	clr  %g3                                       
          break;                                                      
      }                                                               
    }                                                                 
    else                                                              
    {                                                                 
      switch (p->avl.bal)                                             
4000d874:	86 10 20 01 	mov  1, %g3                                    
        default:                                                      
          break;                                                      
      }                                                               
    }                                                                 
    q = p;                                                            
    if (buf_prev > buf_stack)                                         
4000d878:	80 a7 40 0f 	cmp  %i5, %o7                                  
4000d87c:	28 80 00 10 	bleu,a   4000d8bc <rtems_bdbuf_get_buffer_from_lru_list+0x378>
4000d880:	c2 26 e0 3c 	st  %g1, [ %i3 + 0x3c ]                        
    {                                                                 
      p = *--buf_prev;                                                
4000d884:	c8 07 7f fc 	ld  [ %i5 + -4 ], %g4                          
                                                                      
      if (p->avl.cache == -1)                                         
4000d888:	f4 49 20 10 	ldsb  [ %g4 + 0x10 ], %i2                      
4000d88c:	80 a6 bf ff 	cmp  %i2, -1                                   
4000d890:	32 80 00 04 	bne,a   4000d8a0 <rtems_bdbuf_get_buffer_from_lru_list+0x35c>
4000d894:	c2 21 20 0c 	st  %g1, [ %g4 + 0xc ]                         
      {                                                               
        p->avl.left = q;                                              
4000d898:	10 80 00 02 	b  4000d8a0 <rtems_bdbuf_get_buffer_from_lru_list+0x35c>
4000d89c:	c2 21 20 08 	st  %g1, [ %g4 + 8 ]                           
  q->avl.left = q->avl.right = NULL;                                  
  q->avl.bal = 0;                                                     
  modified = true;                                                    
  buf_prev--;                                                         
                                                                      
  while (modified)                                                    
4000d8a0:	80 88 e0 ff 	btst  0xff, %g3                                
4000d8a4:	02 80 00 06 	be  4000d8bc <rtems_bdbuf_get_buffer_from_lru_list+0x378>
4000d8a8:	ba 07 7f fc 	add  %i5, -4, %i5                              
4000d8ac:	10 bf ff 9c 	b  4000d71c <rtems_bdbuf_get_buffer_from_lru_list+0x1d8>
4000d8b0:	82 10 00 04 	mov  %g4, %g1                                  
  bd->avl.left  = NULL;                                               
  bd->avl.right = NULL;                                               
  bd->waiters   = 0;                                                  
                                                                      
  if (rtems_bdbuf_avl_insert (&bdbuf_cache.tree, bd) != 0)            
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_RECYCLE);                    
4000d8b4:	7f ff fd 11 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000d8b8:	90 10 20 08 	mov  8, %o0                                    <== NOT EXECUTED
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000d8bc:	82 10 20 01 	mov  1, %g1                                    
4000d8c0:	c2 20 a0 20 	st  %g1, [ %g2 + 0x20 ]                        
4000d8c4:	81 c7 e0 08 	ret                                            
4000d8c8:	91 e8 00 02 	restore  %g0, %g2, %o0                         
                                                                      
    node = rtems_chain_next (node);                                   
  }                                                                   
                                                                      
  return NULL;                                                        
}                                                                     
4000d8cc:	81 c7 e0 08 	ret                                            
4000d8d0:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000cedc <rtems_bdbuf_get_media_block>: static rtems_status_code rtems_bdbuf_get_media_block (const rtems_disk_device *dd, rtems_blkdev_bnum block, rtems_blkdev_bnum *media_block_ptr) {
4000cedc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  if (block < dd->block_count)                                        
4000cee0:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
                                                                      
static rtems_status_code                                              
rtems_bdbuf_get_media_block (const rtems_disk_device *dd,             
                             rtems_blkdev_bnum        block,          
                             rtems_blkdev_bnum       *media_block_ptr)
{                                                                     
4000cee4:	ba 10 00 18 	mov  %i0, %i5                                  
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  if (block < dd->block_count)                                        
4000cee8:	80 a6 40 01 	cmp  %i1, %g1                                  
4000ceec:	1a 80 00 13 	bcc  4000cf38 <rtems_bdbuf_get_media_block+0x5c>
4000cef0:	b0 10 20 04 	mov  4, %i0                                    
}                                                                     
                                                                      
static rtems_blkdev_bnum                                              
rtems_bdbuf_media_block (const rtems_disk_device *dd, rtems_blkdev_bnum block)
{                                                                     
  if (dd->block_to_media_block_shift >= 0)                            
4000cef4:	d2 07 60 30 	ld  [ %i5 + 0x30 ], %o1                        
4000cef8:	80 a2 60 00 	cmp  %o1, 0                                    
4000cefc:	26 80 00 04 	bl,a   4000cf0c <rtems_bdbuf_get_media_block+0x30><== NEVER TAKEN
4000cf00:	d6 07 60 24 	ld  [ %i5 + 0x24 ], %o3                        <== NOT EXECUTED
    return block << dd->block_to_media_block_shift;                   
4000cf04:	10 80 00 09 	b  4000cf28 <rtems_bdbuf_get_media_block+0x4c> 
4000cf08:	93 2e 40 09 	sll  %i1, %o1, %o1                             
    /*                                                                
     * Change the block number for the block size to the block number for the media
     * block size. We have to use 64bit maths. There is no short cut here.
     */                                                               
    return (rtems_blkdev_bnum)                                        
      ((((uint64_t) block) * dd->block_size) / dd->media_block_size); 
4000cf0c:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4000cf10:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4000cf14:	40 00 2d 46 	call  4001842c <__muldi3>                      <== NOT EXECUTED
4000cf18:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4000cf1c:	d6 07 60 20 	ld  [ %i5 + 0x20 ], %o3                        <== NOT EXECUTED
4000cf20:	40 00 2f 60 	call  40018ca0 <__udivdi3>                     <== NOT EXECUTED
4000cf24:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
    /*                                                                
     * Compute the media block number. Drivers work with media block number not
     * the block number a BD may have as this depends on the block size set by
     * the user.                                                      
     */                                                               
    *media_block_ptr = rtems_bdbuf_media_block (dd, block) + dd->start;
4000cf28:	f2 07 60 18 	ld  [ %i5 + 0x18 ], %i1                        
4000cf2c:	b0 10 20 00 	clr  %i0                                       
4000cf30:	92 02 40 19 	add  %o1, %i1, %o1                             
4000cf34:	d2 26 80 00 	st  %o1, [ %i2 ]                               
  {                                                                   
    sc = RTEMS_INVALID_ID;                                            
  }                                                                   
                                                                      
  return sc;                                                          
}                                                                     
4000cf38:	81 c7 e0 08 	ret                                            
4000cf3c:	81 e8 00 00 	restore                                        
                                                                      

4000ec34 <rtems_bdbuf_init>: bdbuf_cache.init_status = rtems_bdbuf_do_init(); } rtems_status_code rtems_bdbuf_init (void) {
4000ec34:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int eno = pthread_once (&rtems_bdbuf_once_state, rtems_bdbuf_init_once);
4000ec38:	11 10 00 6c 	sethi  %hi(0x4001b000), %o0                    
4000ec3c:	13 10 00 39 	sethi  %hi(0x4000e400), %o1                    
4000ec40:	90 12 21 64 	or  %o0, 0x164, %o0                            
4000ec44:	40 00 0a 6b 	call  400115f0 <pthread_once>                  
4000ec48:	92 12 62 c0 	or  %o1, 0x2c0, %o1                            
                                                                      
  if (eno != 0)                                                       
4000ec4c:	80 a2 20 00 	cmp  %o0, 0                                    
4000ec50:	02 80 00 04 	be  4000ec60 <rtems_bdbuf_init+0x2c>           <== ALWAYS TAKEN
4000ec54:	03 10 00 71 	sethi  %hi(0x4001c400), %g1                    
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_ONCE);                       
4000ec58:	7f ff f8 28 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000ec5c:	90 10 20 1b 	mov  0x1b, %o0                                 <== NOT EXECUTED
                                                                      
  return bdbuf_cache.init_status;                                     
}                                                                     
4000ec60:	f0 00 60 7c 	ld  [ %g1 + 0x7c ], %i0                        
4000ec64:	81 c7 e0 08 	ret                                            
4000ec68:	81 e8 00 00 	restore                                        
                                                                      

4000e6c0 <rtems_bdbuf_init_once>: return RTEMS_UNSATISFIED; } static void rtems_bdbuf_init_once (void) {
4000e6c0:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_status_code   sc;                                             
                                                                      
  if (rtems_bdbuf_tracer)                                             
    printf ("bdbuf:init\n");                                          
                                                                      
  if (rtems_interrupt_is_in_progress())                               
4000e6c4:	c4 01 a0 0c 	ld  [ %g6 + 0xc ], %g2                         
4000e6c8:	31 10 00 70 	sethi  %hi(0x4001c000), %i0                    
    return RTEMS_CALLED_FROM_ISR;                                     
4000e6cc:	82 10 20 12 	mov  0x12, %g1                                 
  rtems_status_code   sc;                                             
                                                                      
  if (rtems_bdbuf_tracer)                                             
    printf ("bdbuf:init\n");                                          
                                                                      
  if (rtems_interrupt_is_in_progress())                               
4000e6d0:	80 a0 a0 00 	cmp  %g2, 0                                    
4000e6d4:	12 80 00 9f 	bne  4000e950 <rtems_bdbuf_init_once+0x290>    <== NEVER TAKEN
4000e6d8:	ba 16 23 dc 	or  %i0, 0x3dc, %i5                            
                                                                      
  /*                                                                  
   * Check the configuration table values.                            
   */                                                                 
                                                                      
  if ((bdbuf_config.buffer_max % bdbuf_config.buffer_min) != 0)       
4000e6dc:	39 10 00 67 	sethi  %hi(0x40019c00), %i4                    
4000e6e0:	b6 17 22 d8 	or  %i4, 0x2d8, %i3	! 40019ed8 <rtems_bdbuf_configuration>
4000e6e4:	f2 06 e0 28 	ld  [ %i3 + 0x28 ], %i1                        
4000e6e8:	f4 06 e0 24 	ld  [ %i3 + 0x24 ], %i2                        
4000e6ec:	90 10 00 19 	mov  %i1, %o0                                  
4000e6f0:	40 00 26 a3 	call  4001817c <.urem>                         
4000e6f4:	92 10 00 1a 	mov  %i2, %o1                                  
4000e6f8:	80 a2 20 00 	cmp  %o0, 0                                    
4000e6fc:	12 80 00 95 	bne  4000e950 <rtems_bdbuf_init_once+0x290>    <== NEVER TAKEN
4000e700:	82 10 20 0a 	mov  0xa, %g1                                  
    return RTEMS_INVALID_NUMBER;                                      
                                                                      
  if (rtems_bdbuf_read_request_size (bdbuf_config.max_read_ahead_blocks)
4000e704:	f8 07 22 d8 	ld  [ %i4 + 0x2d8 ], %i4                       
                                                                      
static size_t                                                         
rtems_bdbuf_read_request_size (uint32_t transfer_count)               
{                                                                     
  return sizeof (rtems_blkdev_request)                                
    + sizeof (rtems_blkdev_sg_buffer) * transfer_count;               
4000e708:	85 2f 20 04 	sll  %i4, 4, %g2                               
}                                                                     
                                                                      
static size_t                                                         
rtems_bdbuf_read_request_size (uint32_t transfer_count)               
{                                                                     
  return sizeof (rtems_blkdev_request)                                
4000e70c:	84 00 a0 18 	add  %g2, 0x18, %g2                            
   */                                                                 
                                                                      
  if ((bdbuf_config.buffer_max % bdbuf_config.buffer_min) != 0)       
    return RTEMS_INVALID_NUMBER;                                      
                                                                      
  if (rtems_bdbuf_read_request_size (bdbuf_config.max_read_ahead_blocks)
4000e710:	80 a0 a2 00 	cmp  %g2, 0x200                                
4000e714:	18 80 00 8f 	bgu  4000e950 <rtems_bdbuf_init_once+0x290>    
4000e718:	f8 27 bf f8 	st  %i4, [ %fp + -8 ]                          
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000e71c:	82 07 60 08 	add  %i5, 8, %g1                               
4000e720:	c2 27 60 10 	st  %g1, [ %i5 + 0x10 ]                        
4000e724:	82 07 60 40 	add  %i5, 0x40, %g1                            
4000e728:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e72c:	82 07 60 50 	add  %i5, 0x50, %g1                            
4000e730:	c2 27 60 4c 	st  %g1, [ %i5 + 0x4c ]                        
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000e734:	82 07 60 4c 	add  %i5, 0x4c, %g1                            
4000e738:	c2 27 60 54 	st  %g1, [ %i5 + 0x54 ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e73c:	82 07 60 5c 	add  %i5, 0x5c, %g1                            
4000e740:	c2 27 60 58 	st  %g1, [ %i5 + 0x58 ]                        
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000e744:	82 07 60 58 	add  %i5, 0x58, %g1                            
4000e748:	c2 27 60 60 	st  %g1, [ %i5 + 0x60 ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e74c:	82 07 60 94 	add  %i5, 0x94, %g1                            
4000e750:	c2 27 60 90 	st  %g1, [ %i5 + 0x90 ]                        
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000e754:	82 07 60 90 	add  %i5, 0x90, %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;                        
4000e758:	c0 27 60 38 	clr  [ %i5 + 0x38 ]                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e75c:	a6 07 60 0c 	add  %i5, 0xc, %l3                             
  head->previous = NULL;                                              
4000e760:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e764:	e6 27 60 08 	st  %l3, [ %i5 + 8 ]                           
4000e768:	ac 07 60 44 	add  %i5, 0x44, %l6                            
  head->previous = NULL;                                              
4000e76c:	c0 27 60 44 	clr  [ %i5 + 0x44 ]                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e770:	ec 27 60 40 	st  %l6, [ %i5 + 0x40 ]                        
  head->previous = NULL;                                              
4000e774:	c0 27 60 50 	clr  [ %i5 + 0x50 ]                            
4000e778:	c0 27 60 5c 	clr  [ %i5 + 0x5c ]                            
4000e77c:	c0 27 60 94 	clr  [ %i5 + 0x94 ]                            
  tail->previous = head;                                              
4000e780:	c2 27 60 98 	st  %g1, [ %i5 + 0x98 ]                        
                                                                      
  /*                                                                  
   * Create the locks for the cache.                                  
   */                                                                 
                                                                      
  sc = rtems_bdbuf_lock_create (rtems_build_name ('B', 'D', 'C', 'l'),
4000e784:	7f ff f9 fd 	call  4000cf78 <rtems_bdbuf_lock_create.isra.14>
4000e788:	90 07 60 28 	add  %i5, 0x28, %o0                            
                                &bdbuf_cache.lock);                   
  if (sc != RTEMS_SUCCESSFUL)                                         
4000e78c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e790:	32 80 00 36 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000e794:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
    goto error;                                                       
                                                                      
  rtems_bdbuf_lock_cache ();                                          
4000e798:	7f ff fd 77 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000e79c:	01 00 00 00 	nop                                            
                                                                      
  sc = rtems_bdbuf_lock_create (rtems_build_name ('B', 'D', 'C', 's'),
4000e7a0:	7f ff f9 f6 	call  4000cf78 <rtems_bdbuf_lock_create.isra.14>
4000e7a4:	90 07 60 2c 	add  %i5, 0x2c, %o0                            
                                &bdbuf_cache.sync_lock);              
  if (sc != RTEMS_SUCCESSFUL)                                         
4000e7a8:	80 a2 20 00 	cmp  %o0, 0                                    
4000e7ac:	32 80 00 2f 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000e7b0:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
                                                                      
static rtems_status_code                                              
rtems_bdbuf_waiter_create (rtems_name name, rtems_bdbuf_waiters *waiter)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_cond_init (&waiter->cond_var, NULL);              
4000e7b4:	90 07 60 68 	add  %i5, 0x68, %o0                            
4000e7b8:	40 00 08 20 	call  40010838 <pthread_cond_init>             
4000e7bc:	92 10 20 00 	clr  %o1                                       
  if (eno != 0)                                                       
4000e7c0:	80 a2 20 00 	cmp  %o0, 0                                    
4000e7c4:	32 80 00 29 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000e7c8:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
                                                                      
static rtems_status_code                                              
rtems_bdbuf_waiter_create (rtems_name name, rtems_bdbuf_waiters *waiter)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_cond_init (&waiter->cond_var, NULL);              
4000e7cc:	90 07 60 70 	add  %i5, 0x70, %o0                            
4000e7d0:	40 00 08 1a 	call  40010838 <pthread_cond_init>             
4000e7d4:	92 10 20 00 	clr  %o1                                       
  if (eno != 0)                                                       
4000e7d8:	80 a2 20 00 	cmp  %o0, 0                                    
4000e7dc:	32 80 00 23 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000e7e0:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
                                                                      
static rtems_status_code                                              
rtems_bdbuf_waiter_create (rtems_name name, rtems_bdbuf_waiters *waiter)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_cond_init (&waiter->cond_var, NULL);              
4000e7e4:	90 07 60 78 	add  %i5, 0x78, %o0                            
4000e7e8:	40 00 08 14 	call  40010838 <pthread_cond_init>             
4000e7ec:	92 10 20 00 	clr  %o1                                       
  if (eno != 0)                                                       
4000e7f0:	80 a2 20 00 	cmp  %o0, 0                                    
4000e7f4:	32 80 00 1d 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000e7f8:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
                                                                      
  /*                                                                  
   * Compute the various number of elements in the cache.             
   */                                                                 
  bdbuf_cache.buffer_min_count =                                      
    bdbuf_config.size / bdbuf_config.buffer_min;                      
4000e7fc:	d0 06 e0 20 	ld  [ %i3 + 0x20 ], %o0                        
4000e800:	40 00 25 b3 	call  40017ecc <.udiv>                         
4000e804:	92 10 00 1a 	mov  %i2, %o1                                  
  bdbuf_cache.max_bds_per_group =                                     
    bdbuf_config.buffer_max / bdbuf_config.buffer_min;                
4000e808:	92 10 00 1a 	mov  %i2, %o1                                  
                                                                      
  /*                                                                  
   * Compute the various number of elements in the cache.             
   */                                                                 
  bdbuf_cache.buffer_min_count =                                      
    bdbuf_config.size / bdbuf_config.buffer_min;                      
4000e80c:	b8 10 00 08 	mov  %o0, %i4                                  
    goto error;                                                       
                                                                      
  /*                                                                  
   * Compute the various number of elements in the cache.             
   */                                                                 
  bdbuf_cache.buffer_min_count =                                      
4000e810:	d0 27 60 1c 	st  %o0, [ %i5 + 0x1c ]                        
    bdbuf_config.size / bdbuf_config.buffer_min;                      
  bdbuf_cache.max_bds_per_group =                                     
    bdbuf_config.buffer_max / bdbuf_config.buffer_min;                
4000e814:	40 00 25 ae 	call  40017ecc <.udiv>                         
4000e818:	90 10 00 19 	mov  %i1, %o0                                  
4000e81c:	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 =                                     
4000e820:	d0 27 60 20 	st  %o0, [ %i5 + 0x20 ]                        
    bdbuf_config.buffer_max / bdbuf_config.buffer_min;                
  bdbuf_cache.group_count =                                           
    bdbuf_cache.buffer_min_count / bdbuf_cache.max_bds_per_group;     
4000e824:	40 00 25 aa 	call  40017ecc <.udiv>                         
4000e828:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
  /*                                                                  
   * Allocate the memory for the buffer descriptors.                  
   */                                                                 
  bdbuf_cache.bds = calloc (sizeof (rtems_bdbuf_buffer),              
4000e82c:	92 10 00 1c 	mov  %i4, %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 =                                           
4000e830:	d0 27 60 84 	st  %o0, [ %i5 + 0x84 ]                        
    bdbuf_cache.buffer_min_count / bdbuf_cache.max_bds_per_group;     
4000e834:	b2 10 00 08 	mov  %o0, %i1                                  
                                                                      
  /*                                                                  
   * Allocate the memory for the buffer descriptors.                  
   */                                                                 
  bdbuf_cache.bds = calloc (sizeof (rtems_bdbuf_buffer),              
4000e838:	7f ff d8 24 	call  400048c8 <calloc>                        
4000e83c:	90 10 20 38 	mov  0x38, %o0                                 
                            bdbuf_cache.buffer_min_count);            
  if (!bdbuf_cache.bds)                                               
4000e840:	80 a2 20 00 	cmp  %o0, 0                                    
4000e844:	02 80 00 08 	be  4000e864 <rtems_bdbuf_init_once+0x1a4>     <== NEVER TAKEN
4000e848:	d0 27 60 14 	st  %o0, [ %i5 + 0x14 ]                        
    goto error;                                                       
                                                                      
  /*                                                                  
   * Allocate the memory for the buffer descriptors.                  
   */                                                                 
  bdbuf_cache.groups = calloc (sizeof (rtems_bdbuf_group),            
4000e84c:	90 10 20 14 	mov  0x14, %o0                                 
4000e850:	7f ff d8 1e 	call  400048c8 <calloc>                        
4000e854:	92 10 00 19 	mov  %i1, %o1                                  
                               bdbuf_cache.group_count);              
  if (!bdbuf_cache.groups)                                            
4000e858:	80 a2 20 00 	cmp  %o0, 0                                    
4000e85c:	12 80 00 40 	bne  4000e95c <rtems_bdbuf_init_once+0x29c>    <== ALWAYS TAKEN
4000e860:	d0 27 60 88 	st  %o0, [ %i5 + 0x88 ]                        
                                                                      
  return RTEMS_SUCCESSFUL;                                            
                                                                      
error:                                                                
                                                                      
  if (bdbuf_cache.read_ahead_task != 0)                               
4000e864:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
4000e868:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4000e86c:	22 80 00 05 	be,a   4000e880 <rtems_bdbuf_init_once+0x1c0>  <== NOT EXECUTED
4000e870:	d0 06 23 dc 	ld  [ %i0 + 0x3dc ], %o0                       <== NOT EXECUTED
    rtems_task_delete (bdbuf_cache.read_ahead_task);                  
4000e874:	7f ff e9 91 	call  40008eb8 <rtems_task_delete>             <== NOT EXECUTED
4000e878:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
  if (bdbuf_cache.swapout != 0)                                       
4000e87c:	d0 06 23 dc 	ld  [ %i0 + 0x3dc ], %o0                       <== NOT EXECUTED
4000e880:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4000e884:	22 80 00 05 	be,a   4000e898 <rtems_bdbuf_init_once+0x1d8>  <== NOT EXECUTED
4000e888:	f8 07 60 80 	ld  [ %i5 + 0x80 ], %i4                        <== NOT EXECUTED
    rtems_task_delete (bdbuf_cache.swapout);                          
4000e88c:	7f ff e9 8b 	call  40008eb8 <rtems_task_delete>             <== NOT EXECUTED
4000e890:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
  if (bdbuf_cache.swapout_workers)                                    
4000e894:	f8 07 60 80 	ld  [ %i5 + 0x80 ], %i4                        <== NOT EXECUTED
4000e898:	80 a7 20 00 	cmp  %i4, 0                                    <== NOT EXECUTED
4000e89c:	32 80 00 1e 	bne,a   4000e914 <rtems_bdbuf_init_once+0x254> <== NOT EXECUTED
4000e8a0:	f2 06 e0 04 	ld  [ %i3 + 4 ], %i1                           <== NOT EXECUTED
        rtems_task_delete (worker->id);                               
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  free (bdbuf_cache.buffers);                                         
4000e8a4:	7f ff d8 41 	call  400049a8 <free>                          <== NOT EXECUTED
4000e8a8:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        <== NOT EXECUTED
  free (bdbuf_cache.groups);                                          
4000e8ac:	7f ff d8 3f 	call  400049a8 <free>                          <== NOT EXECUTED
4000e8b0:	d0 07 60 88 	ld  [ %i5 + 0x88 ], %o0                        <== NOT EXECUTED
  free (bdbuf_cache.bds);                                             
4000e8b4:	7f ff d8 3d 	call  400049a8 <free>                          <== NOT EXECUTED
4000e8b8:	d0 07 60 14 	ld  [ %i5 + 0x14 ], %o0                        <== NOT EXECUTED
  free (bdbuf_cache.swapout_transfer);                                
4000e8bc:	7f ff d8 3b 	call  400049a8 <free>                          <== NOT EXECUTED
4000e8c0:	d0 07 60 7c 	ld  [ %i5 + 0x7c ], %o0                        <== NOT EXECUTED
  free (bdbuf_cache.swapout_workers);                                 
4000e8c4:	7f ff d8 39 	call  400049a8 <free>                          <== NOT EXECUTED
4000e8c8:	d0 07 60 80 	ld  [ %i5 + 0x80 ], %o0                        <== NOT EXECUTED
                                                                      
static void                                                           
rtems_bdbuf_waiter_delete (rtems_bdbuf_waiters *waiter)               
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  pthread_cond_destroy (&waiter->cond_var);                           
4000e8cc:	40 00 07 9e 	call  40010744 <pthread_cond_destroy>          <== NOT EXECUTED
4000e8d0:	90 07 60 78 	add  %i5, 0x78, %o0                            <== NOT EXECUTED
4000e8d4:	40 00 07 9c 	call  40010744 <pthread_cond_destroy>          <== NOT EXECUTED
4000e8d8:	90 07 60 68 	add  %i5, 0x68, %o0                            <== NOT EXECUTED
4000e8dc:	40 00 07 9a 	call  40010744 <pthread_cond_destroy>          <== NOT EXECUTED
4000e8e0:	90 07 60 70 	add  %i5, 0x70, %o0                            <== NOT EXECUTED
                                                                      
static void                                                           
rtems_bdbuf_lock_delete (rtems_bdbuf_lock_type *lock)                 
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  pthread_mutex_destroy (lock);                                       
4000e8e4:	40 00 09 0c 	call  40010d14 <pthread_mutex_destroy>         <== NOT EXECUTED
4000e8e8:	90 07 60 2c 	add  %i5, 0x2c, %o0                            <== NOT EXECUTED
  rtems_bdbuf_waiter_delete (&bdbuf_cache.buffer_waiters);            
  rtems_bdbuf_waiter_delete (&bdbuf_cache.access_waiters);            
  rtems_bdbuf_waiter_delete (&bdbuf_cache.transfer_waiters);          
  rtems_bdbuf_lock_delete (&bdbuf_cache.sync_lock);                   
                                                                      
  if (bdbuf_cache.lock != 0)                                          
4000e8ec:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        <== NOT EXECUTED
4000e8f0:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e8f4:	22 80 00 17 	be,a   4000e950 <rtems_bdbuf_init_once+0x290>  <== NOT EXECUTED
4000e8f8:	82 10 20 0d 	mov  0xd, %g1                                  <== NOT EXECUTED
  {                                                                   
    rtems_bdbuf_unlock_cache ();                                      
4000e8fc:	7f ff fd 29 	call  4000dda0 <rtems_bdbuf_unlock_cache>      <== NOT EXECUTED
4000e900:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
static void                                                           
rtems_bdbuf_lock_delete (rtems_bdbuf_lock_type *lock)                 
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  pthread_mutex_destroy (lock);                                       
4000e904:	40 00 09 04 	call  40010d14 <pthread_mutex_destroy>         <== NOT EXECUTED
4000e908:	90 07 60 28 	add  %i5, 0x28, %o0                            <== NOT EXECUTED
  {                                                                   
    rtems_bdbuf_unlock_cache ();                                      
    rtems_bdbuf_lock_delete (&bdbuf_cache.lock);                      
  }                                                                   
                                                                      
  return RTEMS_UNSATISFIED;                                           
4000e90c:	10 80 00 11 	b  4000e950 <rtems_bdbuf_init_once+0x290>      <== NOT EXECUTED
4000e910:	82 10 20 0d 	mov  0xd, %g1                                  <== NOT EXECUTED
  {                                                                   
    char   *worker_current = (char *) bdbuf_cache.swapout_workers;    
    size_t  worker_size = rtems_bdbuf_swapout_worker_size ();         
    size_t  w;                                                        
                                                                      
    for (w = 0;                                                       
4000e914:	f6 06 e0 14 	ld  [ %i3 + 0x14 ], %i3                        <== NOT EXECUTED
                                                                      
static size_t                                                         
rtems_bdbuf_swapout_worker_size (void)                                
{                                                                     
  return sizeof (rtems_bdbuf_swapout_worker)                          
    + (bdbuf_config.max_write_blocks * sizeof (rtems_blkdev_sg_buffer));
4000e918:	b3 2e 60 04 	sll  %i1, 4, %i1                               <== NOT EXECUTED
  {                                                                   
    char   *worker_current = (char *) bdbuf_cache.swapout_workers;    
    size_t  worker_size = rtems_bdbuf_swapout_worker_size ();         
    size_t  w;                                                        
                                                                      
    for (w = 0;                                                       
4000e91c:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
}                                                                     
                                                                      
static size_t                                                         
rtems_bdbuf_swapout_worker_size (void)                                
{                                                                     
  return sizeof (rtems_bdbuf_swapout_worker)                          
4000e920:	b2 06 60 3c 	add  %i1, 0x3c, %i1                            <== NOT EXECUTED
  {                                                                   
    char   *worker_current = (char *) bdbuf_cache.swapout_workers;    
    size_t  worker_size = rtems_bdbuf_swapout_worker_size ();         
    size_t  w;                                                        
                                                                      
    for (w = 0;                                                       
4000e924:	80 a6 80 1b 	cmp  %i2, %i3                                  <== NOT EXECUTED
4000e928:	1a bf ff df 	bcc  4000e8a4 <rtems_bdbuf_init_once+0x1e4>    <== NOT EXECUTED
4000e92c:	01 00 00 00 	nop                                            <== NOT EXECUTED
         w < bdbuf_config.swapout_workers;                            
         w++, worker_current += worker_size)                          
    {                                                                 
      rtems_bdbuf_swapout_worker *worker = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
      if (worker->id != 0) {                                          
4000e930:	d0 07 20 08 	ld  [ %i4 + 8 ], %o0                           <== NOT EXECUTED
4000e934:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4000e938:	02 80 00 04 	be  4000e948 <rtems_bdbuf_init_once+0x288>     <== NOT EXECUTED
4000e93c:	b4 06 a0 01 	inc  %i2                                       <== NOT EXECUTED
        rtems_task_delete (worker->id);                               
4000e940:	7f ff e9 5e 	call  40008eb8 <rtems_task_delete>             <== NOT EXECUTED
4000e944:	01 00 00 00 	nop                                            <== NOT EXECUTED
    size_t  worker_size = rtems_bdbuf_swapout_worker_size ();         
    size_t  w;                                                        
                                                                      
    for (w = 0;                                                       
         w < bdbuf_config.swapout_workers;                            
         w++, worker_current += worker_size)                          
4000e948:	10 bf ff f7 	b  4000e924 <rtems_bdbuf_init_once+0x264>      <== NOT EXECUTED
4000e94c:	b8 07 00 19 	add  %i4, %i1, %i4                             <== NOT EXECUTED
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_init_once (void)                                          
{                                                                     
  bdbuf_cache.init_status = rtems_bdbuf_do_init();                    
4000e950:	c2 27 60 a0 	st  %g1, [ %i5 + 0xa0 ]                        
4000e954:	81 c7 e0 08 	ret                                            
4000e958:	81 e8 00 00 	restore                                        
   *                                                                  
   * The memory allocate allows a                                     
   */                                                                 
  if (rtems_memalign ((void **) &bdbuf_cache.buffers,                 
                      cache_aligment,                                 
                      bdbuf_cache.buffer_min_count * bdbuf_config.buffer_min) != 0)
4000e95c:	92 10 00 1a 	mov  %i2, %o1                                  
4000e960:	40 00 25 21 	call  40017de4 <.umul>                         
4000e964:	90 10 00 1c 	mov  %i4, %o0                                  
   * 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,                 
4000e968:	92 10 20 20 	mov  0x20, %o1                                 
                      cache_aligment,                                 
                      bdbuf_cache.buffer_min_count * bdbuf_config.buffer_min) != 0)
4000e96c:	94 10 00 08 	mov  %o0, %o2                                  
   * 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,                 
4000e970:	11 10 00 70 	sethi  %hi(0x4001c000), %o0                    
4000e974:	40 00 06 62 	call  400102fc <rtems_memalign>                
4000e978:	90 12 23 f4 	or  %o0, 0x3f4, %o0	! 4001c3f4 <bdbuf_cache+0x18>
4000e97c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e980:	32 bf ff ba 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000e984:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
                                                                      
  /*                                                                  
   * 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,                             
4000e988:	f2 07 60 88 	ld  [ %i5 + 0x88 ], %i1                        
         bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;          
4000e98c:	e2 07 60 14 	ld  [ %i5 + 0x14 ], %l1                        
    bd->group  = group;                                               
    bd->buffer = buffer;                                              
                                                                      
    rtems_chain_append_unprotected (&bdbuf_cache.lru, &bd->link);     
                                                                      
    if ((b % bdbuf_cache.max_bds_per_group) ==                        
4000e990:	ee 07 60 20 	ld  [ %i5 + 0x20 ], %l7                        
  /*                                                                  
   * 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;          
4000e994:	ea 07 60 18 	ld  [ %i5 + 0x18 ], %l5                        
       b < bdbuf_cache.buffer_min_count;                              
4000e998:	e0 07 60 1c 	ld  [ %i5 + 0x1c ], %l0                        
    bd->buffer = buffer;                                              
                                                                      
    rtems_chain_append_unprotected (&bdbuf_cache.lru, &bd->link);     
                                                                      
    if ((b % bdbuf_cache.max_bds_per_group) ==                        
        (bdbuf_cache.max_bds_per_group - 1))                          
4000e99c:	86 05 ff ff 	add  %l7, -1, %g3                              
  /*                                                                  
   * 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;          
4000e9a0:	b8 10 00 11 	mov  %l1, %i4                                  
                                                                      
  /*                                                                  
   * 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,                             
4000e9a4:	a8 10 00 19 	mov  %i1, %l4                                  
4000e9a8:	a4 10 20 00 	clr  %l2                                       
4000e9ac:	80 a4 80 10 	cmp  %l2, %l0                                  
4000e9b0:	02 80 00 15 	be  4000ea04 <rtems_bdbuf_init_once+0x344>     
4000e9b4:	90 10 00 12 	mov  %l2, %o0                                  
         bd = bdbuf_cache.bds, buffer = bdbuf_cache.buffers;          
       b < bdbuf_cache.buffer_min_count;                              
       b++, bd++, buffer += bdbuf_config.buffer_min)                  
  {                                                                   
    bd->dd    = BDBUF_INVALID_DEV;                                    
4000e9b8:	c0 27 20 14 	clr  [ %i4 + 0x14 ]                            
    bd->group  = group;                                               
4000e9bc:	e8 27 20 28 	st  %l4, [ %i4 + 0x28 ]                        
    bd->buffer = buffer;                                              
4000e9c0:	ea 27 20 1c 	st  %l5, [ %i4 + 0x1c ]                        
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000e9c4:	c2 07 60 48 	ld  [ %i5 + 0x48 ], %g1                        
                                                                      
  the_node->next = tail;                                              
4000e9c8:	ec 27 00 00 	st  %l6, [ %i4 ]                               
  tail->previous = the_node;                                          
4000e9cc:	f8 27 60 48 	st  %i4, [ %i5 + 0x48 ]                        
  old_last->next = the_node;                                          
4000e9d0:	f8 20 40 00 	st  %i4, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000e9d4:	c2 27 20 04 	st  %g1, [ %i4 + 4 ]                           
                                                                      
    rtems_chain_append_unprotected (&bdbuf_cache.lru, &bd->link);     
                                                                      
    if ((b % bdbuf_cache.max_bds_per_group) ==                        
4000e9d8:	c6 27 bf f4 	st  %g3, [ %fp + -12 ]                         
4000e9dc:	40 00 25 e8 	call  4001817c <.urem>                         
4000e9e0:	92 10 00 17 	mov  %l7, %o1                                  
4000e9e4:	c6 07 bf f4 	ld  [ %fp + -12 ], %g3                         
4000e9e8:	80 a2 00 03 	cmp  %o0, %g3                                  
4000e9ec:	22 80 00 02 	be,a   4000e9f4 <rtems_bdbuf_init_once+0x334>  
4000e9f0:	a8 05 20 14 	add  %l4, 0x14, %l4                            
   * 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)                  
4000e9f4:	a4 04 a0 01 	inc  %l2                                       
4000e9f8:	b8 07 20 38 	add  %i4, 0x38, %i4                            
4000e9fc:	10 bf ff ec 	b  4000e9ac <rtems_bdbuf_init_once+0x2ec>      
4000ea00:	aa 05 40 1a 	add  %l5, %i2, %l5                             
       b < bdbuf_cache.group_count;                                   
       b++,                                                           
         group++,                                                     
         bd += bdbuf_cache.max_bds_per_group)                         
  {                                                                   
    group->bds_per_group = bdbuf_cache.max_bds_per_group;             
4000ea04:	c4 07 60 20 	ld  [ %i5 + 0x20 ], %g2                        
  }                                                                   
                                                                      
  for (b = 0,                                                         
         group = bdbuf_cache.groups,                                  
         bd = bdbuf_cache.bds;                                        
       b < bdbuf_cache.group_count;                                   
4000ea08:	c6 07 60 84 	ld  [ %i5 + 0x84 ], %g3                        
       b++,                                                           
         group++,                                                     
         bd += bdbuf_cache.max_bds_per_group)                         
4000ea0c:	83 28 a0 03 	sll  %g2, 3, %g1                               
4000ea10:	89 28 a0 06 	sll  %g2, 6, %g4                               
4000ea14:	88 21 00 01 	sub  %g4, %g1, %g4                             
4000ea18:	82 10 20 00 	clr  %g1                                       
    if ((b % bdbuf_cache.max_bds_per_group) ==                        
        (bdbuf_cache.max_bds_per_group - 1))                          
      group++;                                                        
  }                                                                   
                                                                      
  for (b = 0,                                                         
4000ea1c:	80 a0 40 03 	cmp  %g1, %g3                                  
4000ea20:	02 80 00 07 	be  4000ea3c <rtems_bdbuf_init_once+0x37c>     
4000ea24:	82 00 60 01 	inc  %g1                                       
       b++,                                                           
         group++,                                                     
         bd += bdbuf_cache.max_bds_per_group)                         
  {                                                                   
    group->bds_per_group = bdbuf_cache.max_bds_per_group;             
    group->bdbuf = bd;                                                
4000ea28:	e2 26 60 10 	st  %l1, [ %i1 + 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;             
4000ea2c:	c4 26 60 08 	st  %g2, [ %i1 + 8 ]                           
  for (b = 0,                                                         
         group = bdbuf_cache.groups,                                  
         bd = bdbuf_cache.bds;                                        
       b < bdbuf_cache.group_count;                                   
       b++,                                                           
         group++,                                                     
4000ea30:	b2 06 60 14 	add  %i1, 0x14, %i1                            
         bd += bdbuf_cache.max_bds_per_group)                         
4000ea34:	10 bf ff fa 	b  4000ea1c <rtems_bdbuf_init_once+0x35c>      
4000ea38:	a2 04 40 04 	add  %l1, %g4, %l1                             
   * 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.                         
   */                                                                 
  size_t transfer_size = sizeof (rtems_bdbuf_swapout_transfer)        
    + (bdbuf_config.max_write_blocks * sizeof (rtems_blkdev_sg_buffer));
4000ea3c:	e2 06 e0 04 	ld  [ %i3 + 4 ], %l1                           
  return calloc (1, transfer_size);                                   
4000ea40:	90 10 20 01 	mov  1, %o0                                    
   * 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.                         
   */                                                                 
  size_t transfer_size = sizeof (rtems_bdbuf_swapout_transfer)        
    + (bdbuf_config.max_write_blocks * sizeof (rtems_blkdev_sg_buffer));
4000ea44:	a3 2c 60 04 	sll  %l1, 4, %l1                               
  return calloc (1, transfer_size);                                   
4000ea48:	7f ff d7 a0 	call  400048c8 <calloc>                        
4000ea4c:	92 04 60 2c 	add  %l1, 0x2c, %o1                            
  /*                                                                  
   * Create and start swapout task.                                   
   */                                                                 
                                                                      
  bdbuf_cache.swapout_transfer = rtems_bdbuf_swapout_transfer_alloc ();
  if (!bdbuf_cache.swapout_transfer)                                  
4000ea50:	80 a2 20 00 	cmp  %o0, 0                                    
4000ea54:	02 bf ff 84 	be  4000e864 <rtems_bdbuf_init_once+0x1a4>     <== NEVER TAKEN
4000ea58:	d0 27 60 7c 	st  %o0, [ %i5 + 0x7c ]                        
    goto error;                                                       
                                                                      
  bdbuf_cache.swapout_enabled = true;                                 
                                                                      
  sc = rtems_bdbuf_create_task (rtems_build_name('B', 'S', 'W', 'P'), 
4000ea5c:	d2 06 e0 08 	ld  [ %i3 + 8 ], %o1                           
                                                                      
  bdbuf_cache.swapout_transfer = rtems_bdbuf_swapout_transfer_alloc ();
  if (!bdbuf_cache.swapout_transfer)                                  
    goto error;                                                       
                                                                      
  bdbuf_cache.swapout_enabled = true;                                 
4000ea60:	82 10 20 01 	mov  1, %g1                                    
                                                                      
  sc = rtems_bdbuf_create_task (rtems_build_name('B', 'S', 'W', 'P'), 
4000ea64:	11 10 94 d5 	sethi  %hi(0x42535400), %o0                    
                                                                      
  bdbuf_cache.swapout_transfer = rtems_bdbuf_swapout_transfer_alloc ();
  if (!bdbuf_cache.swapout_transfer)                                  
    goto error;                                                       
                                                                      
  bdbuf_cache.swapout_enabled = true;                                 
4000ea68:	c2 2f 60 04 	stb  %g1, [ %i5 + 4 ]                          
                                                                      
  sc = rtems_bdbuf_create_task (rtems_build_name('B', 'S', 'W', 'P'), 
4000ea6c:	90 12 23 50 	or  %o0, 0x350, %o0                            
4000ea70:	7f ff f9 5c 	call  4000cfe0 <rtems_bdbuf_create_task.constprop.15>
4000ea74:	94 10 00 1d 	mov  %i5, %o2                                  
                                bdbuf_config.swapout_priority,        
                                RTEMS_BDBUF_SWAPOUT_TASK_PRIORITY_DEFAULT,
                                &bdbuf_cache.swapout);                
  if (sc != RTEMS_SUCCESSFUL)                                         
4000ea78:	80 a2 20 00 	cmp  %o0, 0                                    
4000ea7c:	32 bf ff 7b 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000ea80:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
    goto error;                                                       
                                                                      
  rtems_bdbuf_swapout_transfer_init (bdbuf_cache.swapout_transfer, bdbuf_cache.swapout);
4000ea84:	d4 07 60 7c 	ld  [ %i5 + 0x7c ], %o2                        
4000ea88:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
4000ea8c:	d0 00 63 dc 	ld  [ %g1 + 0x3dc ], %o0	! 4001c3dc <bdbuf_cache>
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000ea90:	82 02 a0 04 	add  %o2, 4, %g1                               
                                                                      
  head->next = tail;                                                  
4000ea94:	c2 22 80 00 	st  %g1, [ %o2 ]                               
                                   rtems_id id)                       
{                                                                     
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
  transfer->syncing = false;                                          
  transfer->write_req.req = RTEMS_BLKDEV_REQ_WRITE;                   
4000ea98:	82 10 20 01 	mov  1, %g1                                    
  head->previous = NULL;                                              
4000ea9c:	c0 22 a0 04 	clr  [ %o2 + 4 ]                               
  tail->previous = head;                                              
4000eaa0:	d4 22 a0 08 	st  %o2, [ %o2 + 8 ]                           
static void                                                           
rtems_bdbuf_swapout_transfer_init (rtems_bdbuf_swapout_transfer* transfer,
                                   rtems_id id)                       
{                                                                     
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
4000eaa4:	c0 22 a0 0c 	clr  [ %o2 + 0xc ]                             
  transfer->syncing = false;                                          
4000eaa8:	c0 2a a0 10 	clrb  [ %o2 + 0x10 ]                           
  transfer->write_req.req = RTEMS_BLKDEV_REQ_WRITE;                   
4000eaac:	c2 22 a0 14 	st  %g1, [ %o2 + 0x14 ]                        
  transfer->write_req.done = rtems_bdbuf_transfer_done;               
4000eab0:	29 10 00 36 	sethi  %hi(0x4000d800), %l4                    
  transfer->write_req.io_task = id;                                   
4000eab4:	d0 22 a0 28 	st  %o0, [ %o2 + 0x28 ]                        
{                                                                     
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
  transfer->syncing = false;                                          
  transfer->write_req.req = RTEMS_BLKDEV_REQ_WRITE;                   
  transfer->write_req.done = rtems_bdbuf_transfer_done;               
4000eab8:	a8 15 21 28 	or  %l4, 0x128, %l4                            
  if (sc != RTEMS_SUCCESSFUL)                                         
    goto error;                                                       
                                                                      
  rtems_bdbuf_swapout_transfer_init (bdbuf_cache.swapout_transfer, bdbuf_cache.swapout);
                                                                      
  sc = rtems_task_start (bdbuf_cache.swapout,                         
4000eabc:	13 10 00 38 	sethi  %hi(0x4000e000), %o1                    
{                                                                     
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
  transfer->syncing = false;                                          
  transfer->write_req.req = RTEMS_BLKDEV_REQ_WRITE;                   
  transfer->write_req.done = rtems_bdbuf_transfer_done;               
4000eac0:	e8 22 a0 18 	st  %l4, [ %o2 + 0x18 ]                        
  if (sc != RTEMS_SUCCESSFUL)                                         
    goto error;                                                       
                                                                      
  rtems_bdbuf_swapout_transfer_init (bdbuf_cache.swapout_transfer, bdbuf_cache.swapout);
                                                                      
  sc = rtems_task_start (bdbuf_cache.swapout,                         
4000eac4:	7f ff e9 38 	call  40008fa4 <rtems_task_start>              
4000eac8:	92 12 62 c8 	or  %o1, 0x2c8, %o1                            
                         rtems_bdbuf_swapout_task,                    
                         (rtems_task_argument) bdbuf_cache.swapout_transfer);
  if (sc != RTEMS_SUCCESSFUL)                                         
4000eacc:	b4 92 20 00 	orcc  %o0, 0, %i2                              
4000ead0:	32 bf ff 66 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000ead4:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
    goto error;                                                       
                                                                      
  if (bdbuf_config.swapout_workers > 0)                               
4000ead8:	c2 06 e0 14 	ld  [ %i3 + 0x14 ], %g1                        
4000eadc:	80 a0 60 00 	cmp  %g1, 0                                    
4000eae0:	12 80 00 07 	bne  4000eafc <rtems_bdbuf_init_once+0x43c>    <== NEVER TAKEN
4000eae4:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
    sc = rtems_bdbuf_swapout_workers_create ();                       
    if (sc != RTEMS_SUCCESSFUL)                                       
      goto error;                                                     
  }                                                                   
                                                                      
  if (bdbuf_config.max_read_ahead_blocks > 0)                         
4000eae8:	c6 07 bf f8 	ld  [ %fp + -8 ], %g3                          
4000eaec:	80 a0 e0 00 	cmp  %g3, 0                                    
4000eaf0:	32 80 00 3d 	bne,a   4000ebe4 <rtems_bdbuf_init_once+0x524> 
4000eaf4:	d2 06 e0 2c 	ld  [ %i3 + 0x2c ], %o1                        
4000eaf8:	30 80 00 4b 	b,a   4000ec24 <rtems_bdbuf_init_once+0x564>   
  size_t             w;                                               
  size_t             worker_size;                                     
  char              *worker_current;                                  
                                                                      
  worker_size = rtems_bdbuf_swapout_worker_size ();                   
  worker_current = calloc (1, bdbuf_config.swapout_workers * worker_size);
4000eafc:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          <== NOT EXECUTED
}                                                                     
                                                                      
static size_t                                                         
rtems_bdbuf_swapout_worker_size (void)                                
{                                                                     
  return sizeof (rtems_bdbuf_swapout_worker)                          
4000eb00:	a2 04 60 3c 	add  %l1, 0x3c, %l1                            <== NOT EXECUTED
  size_t             w;                                               
  size_t             worker_size;                                     
  char              *worker_current;                                  
                                                                      
  worker_size = rtems_bdbuf_swapout_worker_size ();                   
  worker_current = calloc (1, bdbuf_config.swapout_workers * worker_size);
4000eb04:	40 00 24 b8 	call  40017de4 <.umul>                         <== NOT EXECUTED
4000eb08:	90 10 00 11 	mov  %l1, %o0                                  <== NOT EXECUTED
4000eb0c:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4000eb10:	7f ff d7 6e 	call  400048c8 <calloc>                        <== NOT EXECUTED
4000eb14:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
  sc = worker_current != NULL ? RTEMS_SUCCESSFUL : RTEMS_NO_MEMORY;   
4000eb18:	b2 92 20 00 	orcc  %o0, 0, %i1                              <== NOT EXECUTED
4000eb1c:	22 80 00 02 	be,a   4000eb24 <rtems_bdbuf_init_once+0x464>  <== NOT EXECUTED
4000eb20:	b4 10 20 1a 	mov  0x1a, %i2                                 <== NOT EXECUTED
       sc == RTEMS_SUCCESSFUL && w < bdbuf_config.swapout_workers;    
       w++, worker_current += worker_size)                            
  {                                                                   
    rtems_bdbuf_swapout_worker *worker = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
    sc = rtems_bdbuf_create_task (rtems_build_name('B', 'D', 'o', 'a' + w),
4000eb24:	2b 10 91 1b 	sethi  %hi(0x42446c00), %l5                    <== NOT EXECUTED
      rtems_bdbuf_swapout_transfer_init (&worker->transfer, worker->id);
                                                                      
      rtems_chain_append_unprotected (&bdbuf_cache.swapout_free_workers, &worker->link);
      worker->enabled = true;                                         
                                                                      
      sc = rtems_task_start (worker->id,                              
4000eb28:	2f 10 00 39 	sethi  %hi(0x4000e400), %l7                    <== NOT EXECUTED
                                                                      
  worker_size = rtems_bdbuf_swapout_worker_size ();                   
  worker_current = calloc (1, bdbuf_config.swapout_workers * worker_size);
  sc = worker_current != NULL ? RTEMS_SUCCESSFUL : RTEMS_NO_MEMORY;   
                                                                      
  bdbuf_cache.swapout_workers = (rtems_bdbuf_swapout_worker *) worker_current;
4000eb2c:	f2 27 60 80 	st  %i1, [ %i5 + 0x80 ]                        <== NOT EXECUTED
  size_t             w;                                               
  size_t             worker_size;                                     
  char              *worker_current;                                  
                                                                      
  worker_size = rtems_bdbuf_swapout_worker_size ();                   
  worker_current = calloc (1, bdbuf_config.swapout_workers * worker_size);
4000eb30:	b8 10 00 19 	mov  %i1, %i4                                  <== NOT EXECUTED
  sc = worker_current != NULL ? RTEMS_SUCCESSFUL : RTEMS_NO_MEMORY;   
                                                                      
  bdbuf_cache.swapout_workers = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
  for (w = 0;                                                         
4000eb34:	a0 10 20 00 	clr  %l0                                       <== NOT EXECUTED
       sc == RTEMS_SUCCESSFUL && w < bdbuf_config.swapout_workers;    
       w++, worker_current += worker_size)                            
  {                                                                   
    rtems_bdbuf_swapout_worker *worker = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
    sc = rtems_bdbuf_create_task (rtems_build_name('B', 'D', 'o', 'a' + w),
4000eb38:	aa 15 63 00 	or  %l5, 0x300, %l5                            <== NOT EXECUTED
4000eb3c:	ac 06 60 10 	add  %i1, 0x10, %l6                            <== NOT EXECUTED
                                   rtems_id id)                       
{                                                                     
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
  transfer->syncing = false;                                          
  transfer->write_req.req = RTEMS_BLKDEV_REQ_WRITE;                   
4000eb40:	a4 10 20 01 	mov  1, %l2                                    <== NOT EXECUTED
      rtems_bdbuf_swapout_transfer_init (&worker->transfer, worker->id);
                                                                      
      rtems_chain_append_unprotected (&bdbuf_cache.swapout_free_workers, &worker->link);
      worker->enabled = true;                                         
                                                                      
      sc = rtems_task_start (worker->id,                              
4000eb44:	ae 15 e1 10 	or  %l7, 0x110, %l7                            <== NOT EXECUTED
  worker_current = calloc (1, bdbuf_config.swapout_workers * worker_size);
  sc = worker_current != NULL ? RTEMS_SUCCESSFUL : RTEMS_NO_MEMORY;   
                                                                      
  bdbuf_cache.swapout_workers = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
  for (w = 0;                                                         
4000eb48:	80 a6 a0 00 	cmp  %i2, 0                                    <== NOT EXECUTED
4000eb4c:	12 bf ff 46 	bne  4000e864 <rtems_bdbuf_init_once+0x1a4>    <== NOT EXECUTED
4000eb50:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          <== NOT EXECUTED
       sc == RTEMS_SUCCESSFUL && w < bdbuf_config.swapout_workers;    
4000eb54:	80 a4 00 01 	cmp  %l0, %g1                                  <== NOT EXECUTED
4000eb58:	02 bf ff e4 	be  4000eae8 <rtems_bdbuf_init_once+0x428>     <== NOT EXECUTED
4000eb5c:	90 04 20 61 	add  %l0, 0x61, %o0                            <== NOT EXECUTED
       w++, worker_current += worker_size)                            
  {                                                                   
    rtems_bdbuf_swapout_worker *worker = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
    sc = rtems_bdbuf_create_task (rtems_build_name('B', 'D', 'o', 'a' + w),
4000eb60:	d2 06 e0 18 	ld  [ %i3 + 0x18 ], %o1                        <== NOT EXECUTED
4000eb64:	94 07 20 08 	add  %i4, 8, %o2                               <== NOT EXECUTED
4000eb68:	7f ff f9 1e 	call  4000cfe0 <rtems_bdbuf_create_task.constprop.15><== NOT EXECUTED
4000eb6c:	90 12 00 15 	or  %o0, %l5, %o0                              <== NOT EXECUTED
                                  bdbuf_config.swapout_worker_priority,
                                  RTEMS_BDBUF_SWAPOUT_WORKER_TASK_PRIORITY_DEFAULT,
                                  &worker->id);                       
    if (sc == RTEMS_SUCCESSFUL)                                       
4000eb70:	b4 92 20 00 	orcc  %o0, 0, %i2                              <== NOT EXECUTED
4000eb74:	32 80 00 1a 	bne,a   4000ebdc <rtems_bdbuf_init_once+0x51c> <== NOT EXECUTED
4000eb78:	a0 04 20 01 	inc  %l0                                       <== NOT EXECUTED
4000eb7c:	86 07 20 14 	add  %i4, 0x14, %g3                            <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000eb80:	c6 27 20 10 	st  %g3, [ %i4 + 0x10 ]                        <== NOT EXECUTED
4000eb84:	86 07 20 10 	add  %i4, 0x10, %g3                            <== NOT EXECUTED
    {                                                                 
      rtems_bdbuf_swapout_transfer_init (&worker->transfer, worker->id);
4000eb88:	d0 07 20 08 	ld  [ %i4 + 8 ], %o0                           <== NOT EXECUTED
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000eb8c:	c6 27 20 18 	st  %g3, [ %i4 + 0x18 ]                        <== NOT EXECUTED
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
4000eb90:	c0 27 20 14 	clr  [ %i4 + 0x14 ]                            <== NOT EXECUTED
static void                                                           
rtems_bdbuf_swapout_transfer_init (rtems_bdbuf_swapout_transfer* transfer,
                                   rtems_id id)                       
{                                                                     
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
4000eb94:	c0 27 20 1c 	clr  [ %i4 + 0x1c ]                            <== NOT EXECUTED
4000eb98:	86 27 00 19 	sub  %i4, %i1, %g3                             <== NOT EXECUTED
4000eb9c:	86 00 c0 16 	add  %g3, %l6, %g3                             <== NOT EXECUTED
  transfer->syncing = false;                                          
4000eba0:	c0 28 e0 10 	clrb  [ %g3 + 0x10 ]                           <== NOT EXECUTED
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000eba4:	c6 07 60 10 	ld  [ %i5 + 0x10 ], %g3                        <== NOT EXECUTED
  transfer->write_req.req = RTEMS_BLKDEV_REQ_WRITE;                   
4000eba8:	e4 27 20 24 	st  %l2, [ %i4 + 0x24 ]                        <== NOT EXECUTED
  transfer->write_req.done = rtems_bdbuf_transfer_done;               
4000ebac:	e8 27 20 28 	st  %l4, [ %i4 + 0x28 ]                        <== NOT EXECUTED
  transfer->write_req.io_task = id;                                   
4000ebb0:	d0 27 20 38 	st  %o0, [ %i4 + 0x38 ]                        <== NOT EXECUTED
                                                                      
  the_node->next = tail;                                              
4000ebb4:	e6 27 00 00 	st  %l3, [ %i4 ]                               <== NOT EXECUTED
  tail->previous = the_node;                                          
4000ebb8:	f8 27 60 10 	st  %i4, [ %i5 + 0x10 ]                        <== NOT EXECUTED
  old_last->next = the_node;                                          
4000ebbc:	f8 20 c0 00 	st  %i4, [ %g3 ]                               <== NOT EXECUTED
  the_node->previous = old_last;                                      
4000ebc0:	c6 27 20 04 	st  %g3, [ %i4 + 4 ]                           <== NOT EXECUTED
    if (sc == RTEMS_SUCCESSFUL)                                       
    {                                                                 
      rtems_bdbuf_swapout_transfer_init (&worker->transfer, worker->id);
                                                                      
      rtems_chain_append_unprotected (&bdbuf_cache.swapout_free_workers, &worker->link);
      worker->enabled = true;                                         
4000ebc4:	e4 2f 20 0c 	stb  %l2, [ %i4 + 0xc ]                        <== NOT EXECUTED
                                                                      
      sc = rtems_task_start (worker->id,                              
4000ebc8:	92 10 00 17 	mov  %l7, %o1                                  <== NOT EXECUTED
4000ebcc:	7f ff e8 f6 	call  40008fa4 <rtems_task_start>              <== NOT EXECUTED
4000ebd0:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4000ebd4:	b4 10 00 08 	mov  %o0, %i2                                  <== NOT EXECUTED
                                                                      
  bdbuf_cache.swapout_workers = (rtems_bdbuf_swapout_worker *) worker_current;
                                                                      
  for (w = 0;                                                         
       sc == RTEMS_SUCCESSFUL && w < bdbuf_config.swapout_workers;    
       w++, worker_current += worker_size)                            
4000ebd8:	a0 04 20 01 	inc  %l0                                       <== NOT EXECUTED
4000ebdc:	10 bf ff db 	b  4000eb48 <rtems_bdbuf_init_once+0x488>      <== NOT EXECUTED
4000ebe0:	b8 07 00 11 	add  %i4, %l1, %i4                             <== NOT EXECUTED
      goto error;                                                     
  }                                                                   
                                                                      
  if (bdbuf_config.max_read_ahead_blocks > 0)                         
  {                                                                   
    bdbuf_cache.read_ahead_enabled = true;                            
4000ebe4:	82 10 20 01 	mov  1, %g1                                    
    sc = rtems_bdbuf_create_task (rtems_build_name('B', 'R', 'D', 'A'),
4000ebe8:	11 10 94 91 	sethi  %hi(0x42524400), %o0                    
      goto error;                                                     
  }                                                                   
                                                                      
  if (bdbuf_config.max_read_ahead_blocks > 0)                         
  {                                                                   
    bdbuf_cache.read_ahead_enabled = true;                            
4000ebec:	c2 2f 60 9c 	stb  %g1, [ %i5 + 0x9c ]                       
    sc = rtems_bdbuf_create_task (rtems_build_name('B', 'R', 'D', 'A'),
4000ebf0:	90 12 20 41 	or  %o0, 0x41, %o0                             
4000ebf4:	7f ff f8 fb 	call  4000cfe0 <rtems_bdbuf_create_task.constprop.15>
4000ebf8:	94 07 60 8c 	add  %i5, 0x8c, %o2                            
                                  bdbuf_config.read_ahead_priority,   
                                  RTEMS_BDBUF_READ_AHEAD_TASK_PRIORITY_DEFAULT,
                                  &bdbuf_cache.read_ahead_task);      
    if (sc != RTEMS_SUCCESSFUL)                                       
4000ebfc:	80 a2 20 00 	cmp  %o0, 0                                    
4000ec00:	12 bf ff 1a 	bne  4000e868 <rtems_bdbuf_init_once+0x1a8>    <== NEVER TAKEN
4000ec04:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        
      goto error;                                                     
                                                                      
    sc = rtems_task_start (bdbuf_cache.read_ahead_task,               
4000ec08:	13 10 00 38 	sethi  %hi(0x4000e000), %o1                    
4000ec0c:	94 10 20 00 	clr  %o2                                       
4000ec10:	7f ff e8 e5 	call  40008fa4 <rtems_task_start>              
4000ec14:	92 12 61 b4 	or  %o1, 0x1b4, %o1                            
                           rtems_bdbuf_read_ahead_task,               
                           0);                                        
    if (sc != RTEMS_SUCCESSFUL)                                       
4000ec18:	80 a2 20 00 	cmp  %o0, 0                                    
4000ec1c:	32 bf ff 13 	bne,a   4000e868 <rtems_bdbuf_init_once+0x1a8> <== NEVER TAKEN
4000ec20:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        <== NOT EXECUTED
      goto error;                                                     
  }                                                                   
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000ec24:	7f ff fc 5f 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000ec28:	01 00 00 00 	nop                                            
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000ec2c:	10 bf ff 49 	b  4000e950 <rtems_bdbuf_init_once+0x290>      
4000ec30:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
                                                                      

4000dd74 <rtems_bdbuf_lock_cache>: /** * Lock the cache. A single task can nest calls. */ static void rtems_bdbuf_lock_cache (void) {
4000dd74:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
static void                                                           
rtems_bdbuf_lock (rtems_bdbuf_lock_type *lock, uint32_t fatal_error_code)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_mutex_lock (lock);                                
4000dd78:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
4000dd7c:	40 00 0c 99 	call  40010fe0 <pthread_mutex_lock>            
4000dd80:	90 12 20 04 	or  %o0, 4, %o0	! 4001c404 <bdbuf_cache+0x28>  
  if (eno != 0)                                                       
4000dd84:	80 a2 20 00 	cmp  %o0, 0                                    
4000dd88:	02 80 00 04 	be  4000dd98 <rtems_bdbuf_lock_cache+0x24>     <== ALWAYS TAKEN
4000dd8c:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (fatal_error_code);                             
4000dd90:	7f ff fb da 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000dd94:	90 10 20 00 	clr  %o0	! 0 <_TLS_BSS_size>                   <== NOT EXECUTED
4000dd98:	81 c7 e0 08 	ret                                            
4000dd9c:	81 e8 00 00 	restore                                        
                                                                      

4000cf78 <rtems_bdbuf_lock_create.isra.14>: { rtems_bdbuf_fatal ((((uint32_t) state) << 16) | error); } static rtems_status_code rtems_bdbuf_lock_create (rtems_name name, rtems_bdbuf_lock_type *lock)
4000cf78:	9d e3 bf 88 	save  %sp, -120, %sp                           
  int                 eno;                                            
  pthread_mutexattr_t attr;                                           
                                                                      
  (void) name;                                                        
                                                                      
  eno = pthread_mutexattr_init (&attr);                               
4000cf7c:	40 00 0f 4c 	call  40010cac <pthread_mutexattr_init>        
4000cf80:	90 07 bf e8 	add  %fp, -24, %o0                             
  if (eno != 0)                                                       
4000cf84:	80 a2 20 00 	cmp  %o0, 0                                    
4000cf88:	22 80 00 04 	be,a   4000cf98 <rtems_bdbuf_lock_create.isra.14+0x20><== ALWAYS TAKEN
4000cf8c:	90 07 bf e8 	add  %fp, -24, %o0                             
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_MTX_ATTR_INIT);              
4000cf90:	10 80 00 08 	b  4000cfb0 <rtems_bdbuf_lock_create.isra.14+0x38><== NOT EXECUTED
4000cf94:	90 10 20 1c 	mov  0x1c, %o0                                 <== NOT EXECUTED
                                                                      
  eno = pthread_mutexattr_setprotocol (&attr, PTHREAD_PRIO_INHERIT);  
4000cf98:	40 00 0f 51 	call  40010cdc <pthread_mutexattr_setprotocol> 
4000cf9c:	92 10 20 01 	mov  1, %o1                                    
  if (eno != 0)                                                       
4000cfa0:	80 a2 20 00 	cmp  %o0, 0                                    
4000cfa4:	02 80 00 05 	be  4000cfb8 <rtems_bdbuf_lock_create.isra.14+0x40><== ALWAYS TAKEN
4000cfa8:	92 07 bf e8 	add  %fp, -24, %o1                             
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_MTX_ATTR_SETPROTO);          
4000cfac:	90 10 20 1d 	mov  0x1d, %o0                                 <== NOT EXECUTED
4000cfb0:	7f ff ff 52 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cfb4:	01 00 00 00 	nop                                            <== NOT EXECUTED
                                                                      
  eno = pthread_mutex_init (lock, &attr);                             
4000cfb8:	40 00 0f af 	call  40010e74 <pthread_mutex_init>            
4000cfbc:	90 10 00 18 	mov  %i0, %o0                                  
4000cfc0:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  pthread_mutexattr_destroy (&attr);                                  
4000cfc4:	40 00 0f 2e 	call  40010c7c <pthread_mutexattr_destroy>     
4000cfc8:	90 07 bf e8 	add  %fp, -24, %o0                             
                                                                      
  if (eno != 0)                                                       
    return RTEMS_UNSATISFIED;                                         
4000cfcc:	80 a0 00 1d 	cmp  %g0, %i5                                  
4000cfd0:	b0 40 3f ff 	addx  %g0, -1, %i0                             
4000cfd4:	b0 0e 3f f3 	and  %i0, -13, %i0                             
    RTEMS_BDBUF_CACHE_LOCK_ATTRIBS,                                   
    0,                                                                
    lock                                                              
  );                                                                  
#endif                                                                
}                                                                     
4000cfd8:	81 c7 e0 08 	ret                                            
4000cfdc:	91 ee 20 0d 	restore  %i0, 0xd, %o0                         
                                                                      

4000cd64 <rtems_bdbuf_lock_sync>: /** * Lock the cache's sync. A single task can nest calls. */ static void rtems_bdbuf_lock_sync (void) {
4000cd64:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
static void                                                           
rtems_bdbuf_lock (rtems_bdbuf_lock_type *lock, uint32_t fatal_error_code)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_mutex_lock (lock);                                
4000cd68:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
4000cd6c:	40 00 10 9d 	call  40010fe0 <pthread_mutex_lock>            
4000cd70:	90 12 20 08 	or  %o0, 8, %o0	! 4001c408 <bdbuf_cache+0x2c>  
  if (eno != 0)                                                       
4000cd74:	80 a2 20 00 	cmp  %o0, 0                                    
4000cd78:	02 80 00 04 	be  4000cd88 <rtems_bdbuf_lock_sync+0x24>      <== ALWAYS TAKEN
4000cd7c:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (fatal_error_code);                             
4000cd80:	7f ff ff de 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cd84:	90 10 20 16 	mov  0x16, %o0	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
4000cd88:	81 c7 e0 08 	ret                                            
4000cd8c:	81 e8 00 00 	restore                                        
                                                                      

4000ecfc <rtems_bdbuf_read>: rtems_status_code rtems_bdbuf_read (rtems_disk_device *dd, rtems_blkdev_bnum block, rtems_bdbuf_buffer **bd_ptr) {
4000ecfc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code     sc = RTEMS_SUCCESSFUL;                        
  rtems_bdbuf_buffer   *bd = NULL;                                    
  rtems_blkdev_bnum     media_block;                                  
                                                                      
  rtems_bdbuf_lock_cache ();                                          
4000ed00:	7f ff fc 1d 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000ed04:	ba 10 00 18 	mov  %i0, %i5                                  
                                                                      
  sc = rtems_bdbuf_get_media_block (dd, block, &media_block);         
4000ed08:	90 10 00 18 	mov  %i0, %o0                                  
4000ed0c:	92 10 00 19 	mov  %i1, %o1                                  
4000ed10:	7f ff f8 73 	call  4000cedc <rtems_bdbuf_get_media_block>   
4000ed14:	94 07 bf fc 	add  %fp, -4, %o2                              
  if (sc == RTEMS_SUCCESSFUL)                                         
4000ed18:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000ed1c:	12 80 00 61 	bne  4000eea0 <rtems_bdbuf_read+0x1a4>         <== NEVER TAKEN
4000ed20:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
  {                                                                   
    if (rtems_bdbuf_tracer)                                           
      printf ("bdbuf:read: %" PRIu32 " (%" PRIu32 ") (dev = %08x)\n", 
              media_block, block, (unsigned) dd->dev);                
                                                                      
    bd = rtems_bdbuf_get_buffer_for_access (dd, media_block);         
4000ed24:	7f ff fb 1c 	call  4000d994 <rtems_bdbuf_get_buffer_for_access>
4000ed28:	90 10 00 1d 	mov  %i5, %o0                                  
4000ed2c:	b8 10 00 08 	mov  %o0, %i4                                  
    switch (bd->state)                                                
4000ed30:	d0 02 20 20 	ld  [ %o0 + 0x20 ], %o0                        
4000ed34:	80 a2 20 02 	cmp  %o0, 2                                    
4000ed38:	02 80 00 08 	be  4000ed58 <rtems_bdbuf_read+0x5c>           
4000ed3c:	80 a2 20 07 	cmp  %o0, 7                                    
4000ed40:	02 80 00 0b 	be  4000ed6c <rtems_bdbuf_read+0x70>           
4000ed44:	80 a2 20 01 	cmp  %o0, 1                                    
4000ed48:	12 80 00 33 	bne  4000ee14 <rtems_bdbuf_read+0x118>         <== NEVER TAKEN
4000ed4c:	01 00 00 00 	nop                                            
      case RTEMS_BDBUF_STATE_MODIFIED:                                
        ++dd->stats.read_hits;                                        
        rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_MODIFIED);
        break;                                                        
      case RTEMS_BDBUF_STATE_EMPTY:                                   
        ++dd->stats.read_misses;                                      
4000ed50:	10 80 00 0d 	b  4000ed84 <rtems_bdbuf_read+0x88>            
4000ed54:	c2 07 60 48 	ld  [ %i5 + 0x48 ], %g1                        
                                                                      
    bd = rtems_bdbuf_get_buffer_for_access (dd, media_block);         
    switch (bd->state)                                                
    {                                                                 
      case RTEMS_BDBUF_STATE_CACHED:                                  
        ++dd->stats.read_hits;                                        
4000ed58:	c2 07 60 44 	ld  [ %i5 + 0x44 ], %g1                        
4000ed5c:	82 00 60 01 	inc  %g1                                       
4000ed60:	c2 27 60 44 	st  %g1, [ %i5 + 0x44 ]                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000ed64:	10 80 00 06 	b  4000ed7c <rtems_bdbuf_read+0x80>            
4000ed68:	82 10 20 03 	mov  3, %g1                                    
      case RTEMS_BDBUF_STATE_CACHED:                                  
        ++dd->stats.read_hits;                                        
        rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_CACHED);  
        break;                                                        
      case RTEMS_BDBUF_STATE_MODIFIED:                                
        ++dd->stats.read_hits;                                        
4000ed6c:	c2 07 60 44 	ld  [ %i5 + 0x44 ], %g1                        
4000ed70:	82 00 60 01 	inc  %g1                                       
4000ed74:	c2 27 60 44 	st  %g1, [ %i5 + 0x44 ]                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000ed78:	82 10 20 04 	mov  4, %g1                                    
4000ed7c:	10 80 00 28 	b  4000ee1c <rtems_bdbuf_read+0x120>           
4000ed80:	c2 27 20 20 	st  %g1, [ %i4 + 0x20 ]                        
      case RTEMS_BDBUF_STATE_MODIFIED:                                
        ++dd->stats.read_hits;                                        
        rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_MODIFIED);
        break;                                                        
      case RTEMS_BDBUF_STATE_EMPTY:                                   
        ++dd->stats.read_misses;                                      
4000ed84:	82 00 60 01 	inc  %g1                                       
4000ed88:	c2 27 60 48 	st  %g1, [ %i5 + 0x48 ]                        
                                                                      
static void                                                           
rtems_bdbuf_set_read_ahead_trigger (rtems_disk_device *dd,            
                                    rtems_blkdev_bnum  block)         
{                                                                     
  if (dd->read_ahead.trigger != block)                                
4000ed8c:	c2 07 60 6c 	ld  [ %i5 + 0x6c ], %g1                        
4000ed90:	80 a0 40 19 	cmp  %g1, %i1                                  
4000ed94:	02 80 00 0f 	be  4000edd0 <rtems_bdbuf_read+0xd4>           
4000ed98:	90 10 00 1d 	mov  %i5, %o0                                  
 *                                                                    
 * @retval true The node is off chain.                                
 * @retval false The node is not off chain.                           
 */                                                                   
RTEMS_INLINE_ROUTINE bool rtems_chain_is_node_off_chain(              
  const rtems_chain_node *node                                        
4000ed9c:	c2 07 60 64 	ld  [ %i5 + 0x64 ], %g1                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_read_ahead_cancel (rtems_disk_device *dd)                 
{                                                                     
  if (rtems_bdbuf_is_read_ahead_active (dd))                          
4000eda0:	80 a0 60 00 	cmp  %g1, 0                                    
4000eda4:	22 80 00 07 	be,a   4000edc0 <rtems_bdbuf_read+0xc4>        <== ALWAYS TAKEN
4000eda8:	82 06 60 01 	add  %i1, 1, %g1                               
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
4000edac:	c4 07 60 68 	ld  [ %i5 + 0x68 ], %g2                        <== NOT EXECUTED
  next->previous = previous;                                          
4000edb0:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           <== NOT EXECUTED
  previous->next = next;                                              
4000edb4:	c2 20 80 00 	st  %g1, [ %g2 ]                               <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
4000edb8:	c0 27 60 64 	clr  [ %i5 + 0x64 ]                            <== NOT EXECUTED
                                    rtems_blkdev_bnum  block)         
{                                                                     
  if (dd->read_ahead.trigger != block)                                
  {                                                                   
    rtems_bdbuf_read_ahead_cancel (dd);                               
    dd->read_ahead.trigger = block + 1;                               
4000edbc:	82 06 60 01 	add  %i1, 1, %g1                               <== NOT EXECUTED
4000edc0:	c2 27 60 6c 	st  %g1, [ %i5 + 0x6c ]                        
    dd->read_ahead.next = block + 2;                                  
4000edc4:	82 06 60 02 	add  %i1, 2, %g1                               
4000edc8:	c2 27 60 70 	st  %g1, [ %i5 + 0x70 ]                        
        rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_ACCESS_MODIFIED);
        break;                                                        
      case RTEMS_BDBUF_STATE_EMPTY:                                   
        ++dd->stats.read_misses;                                      
        rtems_bdbuf_set_read_ahead_trigger (dd, block);               
        sc = rtems_bdbuf_execute_read_request (dd, bd, 1);            
4000edcc:	90 10 00 1d 	mov  %i5, %o0                                  
4000edd0:	92 10 00 1c 	mov  %i4, %o1                                  
4000edd4:	7f ff fc 6f 	call  4000df90 <rtems_bdbuf_execute_read_request>
4000edd8:	94 10 20 01 	mov  1, %o2                                    
        if (sc == RTEMS_SUCCESSFUL)                                   
4000eddc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000ede0:	32 80 00 0f 	bne,a   4000ee1c <rtems_bdbuf_read+0x120>      
4000ede4:	b8 10 20 00 	clr  %i4                                       
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000ede8:	82 10 20 03 	mov  3, %g1                                    
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4000edec:	c4 07 00 00 	ld  [ %i4 ], %g2                               
4000edf0:	c2 27 20 20 	st  %g1, [ %i4 + 0x20 ]                        
  previous       = the_node->previous;                                
4000edf4:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
  next->previous = previous;                                          
4000edf8:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4000edfc:	c4 20 40 00 	st  %g2, [ %g1 ]                               
rtems_bdbuf_read (rtems_disk_device   *dd,                            
                  rtems_blkdev_bnum    block,                         
                  rtems_bdbuf_buffer **bd_ptr)                        
{                                                                     
  rtems_status_code     sc = RTEMS_SUCCESSFUL;                        
  rtems_bdbuf_buffer   *bd = NULL;                                    
4000ee00:	c2 07 20 28 	ld  [ %i4 + 0x28 ], %g1                        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_group_obtain (rtems_bdbuf_buffer *bd)                     
{                                                                     
  ++bd->group->users;                                                 
4000ee04:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000ee08:	84 00 a0 01 	inc  %g2                                       
4000ee0c:	10 80 00 04 	b  4000ee1c <rtems_bdbuf_read+0x120>           
4000ee10:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
        {                                                             
          bd = NULL;                                                  
        }                                                             
        break;                                                        
      default:                                                        
        rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_4);
4000ee14:	7f ff f7 cf 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000ee18:	92 10 20 0d 	mov  0xd, %o1                                  <== NOT EXECUTED
                                                                      
static void                                                           
rtems_bdbuf_check_read_ahead_trigger (rtems_disk_device *dd,          
                                      rtems_blkdev_bnum  block)       
{                                                                     
  if (bdbuf_cache.read_ahead_task != 0                                
4000ee1c:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
4000ee20:	82 10 63 dc 	or  %g1, 0x3dc, %g1	! 4001c3dc <bdbuf_cache>   
4000ee24:	d0 00 60 8c 	ld  [ %g1 + 0x8c ], %o0                        
4000ee28:	80 a2 20 00 	cmp  %o0, 0                                    
4000ee2c:	02 80 00 1e 	be  4000eea4 <rtems_bdbuf_read+0x1a8>          
4000ee30:	b6 10 00 01 	mov  %g1, %i3                                  
      && dd->read_ahead.trigger == block                              
4000ee34:	c4 07 60 6c 	ld  [ %i5 + 0x6c ], %g2                        
4000ee38:	80 a0 80 19 	cmp  %g2, %i1                                  
4000ee3c:	12 80 00 1a 	bne  4000eea4 <rtems_bdbuf_read+0x1a8>         
4000ee40:	01 00 00 00 	nop                                            
      && !rtems_bdbuf_is_read_ahead_active (dd))                      
4000ee44:	c4 07 60 64 	ld  [ %i5 + 0x64 ], %g2                        
4000ee48:	80 a0 a0 00 	cmp  %g2, 0                                    
4000ee4c:	12 80 00 16 	bne  4000eea4 <rtems_bdbuf_read+0x1a8>         <== NEVER TAKEN
4000ee50:	01 00 00 00 	nop                                            
  {                                                                   
    rtems_status_code sc;                                             
    rtems_chain_control *chain = &bdbuf_cache.read_ahead_chain;       
                                                                      
    if (rtems_chain_is_empty (chain))                                 
4000ee54:	c4 00 60 90 	ld  [ %g1 + 0x90 ], %g2                        
4000ee58:	82 00 60 94 	add  %g1, 0x94, %g1                            
4000ee5c:	80 a0 80 01 	cmp  %g2, %g1                                  
4000ee60:	12 80 00 09 	bne  4000ee84 <rtems_bdbuf_read+0x188>         <== NEVER TAKEN
4000ee64:	b2 10 00 01 	mov  %g1, %i1                                  
    {                                                                 
      sc = rtems_event_send (bdbuf_cache.read_ahead_task,             
4000ee68:	7f ff e6 0d 	call  4000869c <rtems_event_send>              
4000ee6c:	92 10 20 02 	mov  2, %o1                                    
                             RTEMS_BDBUF_READ_AHEAD_WAKE_UP);         
      if (sc != RTEMS_SUCCESSFUL)                                     
4000ee70:	80 a2 20 00 	cmp  %o0, 0                                    
4000ee74:	22 80 00 05 	be,a   4000ee88 <rtems_bdbuf_read+0x18c>       <== ALWAYS TAKEN
4000ee78:	c4 06 e0 98 	ld  [ %i3 + 0x98 ], %g2                        
        rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_RA_WAKE_UP);             
4000ee7c:	7f ff f7 9f 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000ee80:	90 10 20 07 	mov  7, %o0                                    <== NOT EXECUTED
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000ee84:	c4 06 e0 98 	ld  [ %i3 + 0x98 ], %g2                        <== NOT EXECUTED
                                                                      
  the_node->next = tail;                                              
4000ee88:	f2 27 60 64 	st  %i1, [ %i5 + 0x64 ]                        
    }                                                                 
                                                                      
    rtems_chain_append_unprotected (chain, &dd->read_ahead.node);     
4000ee8c:	86 07 60 64 	add  %i5, 0x64, %g3                            
  tail->previous = the_node;                                          
4000ee90:	c6 26 e0 98 	st  %g3, [ %i3 + 0x98 ]                        
  old_last->next = the_node;                                          
4000ee94:	c6 20 80 00 	st  %g3, [ %g2 ]                               
  the_node->previous = old_last;                                      
4000ee98:	10 80 00 03 	b  4000eea4 <rtems_bdbuf_read+0x1a8>           
4000ee9c:	c4 27 60 68 	st  %g2, [ %i5 + 0x68 ]                        
rtems_bdbuf_read (rtems_disk_device   *dd,                            
                  rtems_blkdev_bnum    block,                         
                  rtems_bdbuf_buffer **bd_ptr)                        
{                                                                     
  rtems_status_code     sc = RTEMS_SUCCESSFUL;                        
  rtems_bdbuf_buffer   *bd = NULL;                                    
4000eea0:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
    }                                                                 
                                                                      
    rtems_bdbuf_check_read_ahead_trigger (dd, block);                 
  }                                                                   
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000eea4:	7f ff fb bf 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000eea8:	01 00 00 00 	nop                                            
                                                                      
  *bd_ptr = bd;                                                       
4000eeac:	f8 26 80 00 	st  %i4, [ %i2 ]                               
                                                                      
  return sc;                                                          
}                                                                     
4000eeb0:	81 c7 e0 08 	ret                                            
4000eeb4:	81 e8 00 00 	restore                                        
                                                                      

4000e1b4 <rtems_bdbuf_read_ahead_task>: return sc; } static rtems_task rtems_bdbuf_read_ahead_task (rtems_task_argument arg) {
4000e1b4:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_chain_control *chain = &bdbuf_cache.read_ahead_chain;         
                                                                      
  while (bdbuf_cache.read_ahead_enabled)                              
4000e1b8:	39 10 00 70 	sethi  %hi(0x4001c000), %i4                    
          rtems_bdbuf_get_buffer_for_read_ahead (dd, media_block);    
                                                                      
        if (bd != NULL)                                               
        {                                                             
          uint32_t transfer_count = dd->block_count - block;          
          uint32_t max_transfer_count = bdbuf_config.max_read_ahead_blocks;
4000e1bc:	25 10 00 67 	sethi  %hi(0x40019c00), %l2                    
static rtems_task                                                     
rtems_bdbuf_read_ahead_task (rtems_task_argument arg)                 
{                                                                     
  rtems_chain_control *chain = &bdbuf_cache.read_ahead_chain;         
                                                                      
  while (bdbuf_cache.read_ahead_enabled)                              
4000e1c0:	b8 17 23 dc 	or  %i4, 0x3dc, %i4                            
4000e1c4:	b2 10 00 1c 	mov  %i4, %i1                                  
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000e1c8:	b0 10 00 1c 	mov  %i4, %i0                                  
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000e1cc:	a0 07 20 94 	add  %i4, 0x94, %l0                            
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
                                                                      
  head->next = new_first;                                             
  new_first->previous = head;                                         
4000e1d0:	a2 07 20 90 	add  %i4, 0x90, %l1                            
4000e1d4:	c2 0f 20 9c 	ldub  [ %i4 + 0x9c ], %g1                      
4000e1d8:	80 a0 60 00 	cmp  %g1, 0                                    
4000e1dc:	02 80 00 33 	be  4000e2a8 <rtems_bdbuf_read_ahead_task+0xf4><== NEVER TAKEN
4000e1e0:	01 00 00 00 	nop                                            
  {                                                                   
    rtems_chain_node *node;                                           
                                                                      
    rtems_bdbuf_wait_for_event (RTEMS_BDBUF_READ_AHEAD_WAKE_UP);      
4000e1e4:	7f ff fa ca 	call  4000cd0c <rtems_bdbuf_wait_for_event>    
4000e1e8:	90 10 20 02 	mov  2, %o0	! 2 <_TLS_Alignment+0x1>           
    rtems_bdbuf_lock_cache ();                                        
4000e1ec:	7f ff fe e2 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000e1f0:	01 00 00 00 	nop                                            
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000e1f4:	fa 06 60 90 	ld  [ %i1 + 0x90 ], %i5                        
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000e1f8:	80 a7 40 10 	cmp  %i5, %l0                                  
4000e1fc:	02 80 00 2f 	be  4000e2b8 <rtems_bdbuf_read_ahead_task+0x104>
4000e200:	b4 07 7f 9c 	add  %i5, -100, %i2                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4000e204:	c2 07 40 00 	ld  [ %i5 ], %g1                               
                                                                      
    while ((node = rtems_chain_get_unprotected (chain)) != NULL)      
    {                                                                 
      rtems_disk_device *dd = (rtems_disk_device *)                   
        ((char *) node - offsetof (rtems_disk_device, read_ahead.node));
      rtems_blkdev_bnum block = dd->read_ahead.next;                  
4000e208:	f6 07 60 0c 	ld  [ %i5 + 0xc ], %i3                         
                                                                      
  head->next = new_first;                                             
4000e20c:	c2 26 20 90 	st  %g1, [ %i0 + 0x90 ]                        
  new_first->previous = head;                                         
4000e210:	e2 20 60 04 	st  %l1, [ %g1 + 4 ]                           
      rtems_blkdev_bnum media_block = 0;                              
4000e214:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
      rtems_status_code sc =                                          
4000e218:	90 10 00 1a 	mov  %i2, %o0                                  
4000e21c:	92 10 00 1b 	mov  %i3, %o1                                  
4000e220:	7f ff fb 2f 	call  4000cedc <rtems_bdbuf_get_media_block>   
4000e224:	94 07 bf fc 	add  %fp, -4, %o2                              
        rtems_bdbuf_get_media_block (dd, block, &media_block);        
                                                                      
      rtems_chain_set_off_chain (&dd->read_ahead.node);               
                                                                      
      if (sc == RTEMS_SUCCESSFUL)                                     
4000e228:	80 a2 20 00 	cmp  %o0, 0                                    
4000e22c:	12 80 00 1c 	bne  4000e29c <rtems_bdbuf_read_ahead_task+0xe8>
4000e230:	c0 27 40 00 	clr  [ %i5 ]                                   
      {                                                               
        rtems_bdbuf_buffer *bd =                                      
4000e234:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
4000e238:	7f ff fd a7 	call  4000d8d4 <rtems_bdbuf_get_buffer_for_read_ahead>
4000e23c:	90 10 00 1a 	mov  %i2, %o0                                  
          rtems_bdbuf_get_buffer_for_read_ahead (dd, media_block);    
                                                                      
        if (bd != NULL)                                               
4000e240:	92 92 20 00 	orcc  %o0, 0, %o1                              
4000e244:	02 bf ff ec 	be  4000e1f4 <rtems_bdbuf_read_ahead_task+0x40><== NEVER TAKEN
4000e248:	d4 04 a2 d8 	ld  [ %l2 + 0x2d8 ], %o2                       
        {                                                             
          uint32_t transfer_count = dd->block_count - block;          
4000e24c:	c2 07 7f c4 	ld  [ %i5 + -60 ], %g1                         
4000e250:	82 20 40 1b 	sub  %g1, %i3, %g1                             
          uint32_t max_transfer_count = bdbuf_config.max_read_ahead_blocks;
                                                                      
          if (transfer_count >= max_transfer_count)                   
4000e254:	80 a0 40 0a 	cmp  %g1, %o2                                  
4000e258:	0a 80 00 08 	bcs  4000e278 <rtems_bdbuf_read_ahead_task+0xc4>
4000e25c:	84 10 3f ff 	mov  -1, %g2                                   
          {                                                           
            transfer_count = max_transfer_count;                      
            dd->read_ahead.trigger = block + transfer_count / 2;      
4000e260:	83 32 a0 01 	srl  %o2, 1, %g1                               
4000e264:	82 00 40 1b 	add  %g1, %i3, %g1                             
            dd->read_ahead.next = block + transfer_count;             
4000e268:	b6 02 80 1b 	add  %o2, %i3, %i3                             
          uint32_t max_transfer_count = bdbuf_config.max_read_ahead_blocks;
                                                                      
          if (transfer_count >= max_transfer_count)                   
          {                                                           
            transfer_count = max_transfer_count;                      
            dd->read_ahead.trigger = block + transfer_count / 2;      
4000e26c:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
4000e270:	10 80 00 04 	b  4000e280 <rtems_bdbuf_read_ahead_task+0xcc> 
4000e274:	f6 27 60 0c 	st  %i3, [ %i5 + 0xc ]                         
            dd->read_ahead.next = block + transfer_count;             
          }                                                           
          else                                                        
          {                                                           
            dd->read_ahead.trigger = RTEMS_DISK_READ_AHEAD_NO_TRIGGER;
4000e278:	94 10 00 01 	mov  %g1, %o2                                  
4000e27c:	c4 27 60 08 	st  %g2, [ %i5 + 8 ]                           
          }                                                           
                                                                      
          ++dd->stats.read_ahead_transfers;                           
4000e280:	c2 07 7f e8 	ld  [ %i5 + -24 ], %g1                         
          rtems_bdbuf_execute_read_request (dd, bd, transfer_count);  
4000e284:	90 10 00 1a 	mov  %i2, %o0                                  
          else                                                        
          {                                                           
            dd->read_ahead.trigger = RTEMS_DISK_READ_AHEAD_NO_TRIGGER;
          }                                                           
                                                                      
          ++dd->stats.read_ahead_transfers;                           
4000e288:	82 00 60 01 	inc  %g1                                       
          rtems_bdbuf_execute_read_request (dd, bd, transfer_count);  
4000e28c:	7f ff ff 41 	call  4000df90 <rtems_bdbuf_execute_read_request>
4000e290:	c2 27 7f e8 	st  %g1, [ %i5 + -24 ]                         
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000e294:	10 bf ff d9 	b  4000e1f8 <rtems_bdbuf_read_ahead_task+0x44> 
4000e298:	fa 06 60 90 	ld  [ %i1 + 0x90 ], %i5                        
        }                                                             
      }                                                               
      else                                                            
      {                                                               
        dd->read_ahead.trigger = RTEMS_DISK_READ_AHEAD_NO_TRIGGER;    
4000e29c:	82 10 3f ff 	mov  -1, %g1                                   
4000e2a0:	10 bf ff d5 	b  4000e1f4 <rtems_bdbuf_read_ahead_task+0x40> 
4000e2a4:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
    }                                                                 
                                                                      
    rtems_bdbuf_unlock_cache ();                                      
  }                                                                   
                                                                      
  rtems_task_delete (RTEMS_SELF);                                     
4000e2a8:	7f ff eb 04 	call  40008eb8 <rtems_task_delete>             <== NOT EXECUTED
4000e2ac:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4000e2b0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e2b4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
      {                                                               
        dd->read_ahead.trigger = RTEMS_DISK_READ_AHEAD_NO_TRIGGER;    
      }                                                               
    }                                                                 
                                                                      
    rtems_bdbuf_unlock_cache ();                                      
4000e2b8:	7f ff fe ba 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000e2bc:	01 00 00 00 	nop                                            
static rtems_task                                                     
rtems_bdbuf_read_ahead_task (rtems_task_argument arg)                 
{                                                                     
  rtems_chain_control *chain = &bdbuf_cache.read_ahead_chain;         
                                                                      
  while (bdbuf_cache.read_ahead_enabled)                              
4000e2c0:	10 bf ff c6 	b  4000e1d8 <rtems_bdbuf_read_ahead_task+0x24> 
4000e2c4:	c2 0f 20 9c 	ldub  [ %i4 + 0x9c ], %g1                      
                                                                      

4000eeb8 <rtems_bdbuf_release>: return RTEMS_SUCCESSFUL; } rtems_status_code rtems_bdbuf_release (rtems_bdbuf_buffer *bd) {
4000eeb8:	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 (bd == NULL)                                                     
4000eebc:	80 a6 20 00 	cmp  %i0, 0                                    
4000eec0:	02 80 00 31 	be  4000ef84 <rtems_bdbuf_release+0xcc>        <== NEVER TAKEN
4000eec4:	01 00 00 00 	nop                                            
  if (rtems_bdbuf_tracer)                                             
  {                                                                   
    printf ("bdbuf:%s: %" PRIu32 "\n", kind, bd->block);              
    rtems_bdbuf_show_users (kind, bd);                                
  }                                                                   
  rtems_bdbuf_lock_cache();                                           
4000eec8:	7f ff fb ab 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000eecc:	01 00 00 00 	nop                                            
                                                                      
  sc = rtems_bdbuf_check_bd_and_lock_cache (bd, "release");           
  if (sc != RTEMS_SUCCESSFUL)                                         
    return sc;                                                        
                                                                      
  switch (bd->state)                                                  
4000eed0:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
4000eed4:	80 a2 20 04 	cmp  %o0, 4                                    
4000eed8:	02 80 00 22 	be  4000ef60 <rtems_bdbuf_release+0xa8>        
4000eedc:	01 00 00 00 	nop                                            
4000eee0:	18 80 00 06 	bgu  4000eef8 <rtems_bdbuf_release+0x40>       
4000eee4:	80 a2 20 06 	cmp  %o0, 6                                    
4000eee8:	80 a2 20 03 	cmp  %o0, 3                                    
4000eeec:	22 80 00 08 	be,a   4000ef0c <rtems_bdbuf_release+0x54>     <== ALWAYS TAKEN
4000eef0:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
4000eef4:	30 80 00 1e 	b,a   4000ef6c <rtems_bdbuf_release+0xb4>      <== NOT EXECUTED
4000eef8:	18 80 00 1d 	bgu  4000ef6c <rtems_bdbuf_release+0xb4>       <== NEVER TAKEN
4000eefc:	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);                   
4000ef00:	7f ff fd d7 	call  4000e65c <rtems_bdbuf_discard_buffer_after_access>
4000ef04:	90 10 00 18 	mov  %i0, %o0                                  
      break;                                                          
4000ef08:	30 80 00 1b 	b,a   4000ef74 <rtems_bdbuf_release+0xbc>      
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000ef0c:	11 10 00 70 	sethi  %hi(0x4001c000), %o0                    
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_group_release (rtems_bdbuf_buffer *bd)                    
{                                                                     
  --bd->group->users;                                                 
4000ef10:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000ef14:	90 12 23 dc 	or  %o0, 0x3dc, %o0                            
4000ef18:	84 00 bf ff 	add  %g2, -1, %g2                              
4000ef1c:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
4000ef20:	82 10 20 02 	mov  2, %g1                                    
                                                                      
  the_node->next = tail;                                              
4000ef24:	84 02 20 44 	add  %o0, 0x44, %g2                            
4000ef28:	c2 26 20 20 	st  %g1, [ %i0 + 0x20 ]                        
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000ef2c:	c2 02 20 48 	ld  [ %o0 + 0x48 ], %g1                        
                                                                      
  the_node->next = tail;                                              
4000ef30:	c4 26 00 00 	st  %g2, [ %i0 ]                               
  tail->previous = the_node;                                          
4000ef34:	f0 22 20 48 	st  %i0, [ %o0 + 0x48 ]                        
  old_last->next = the_node;                                          
4000ef38:	f0 20 40 00 	st  %i0, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000ef3c:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
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)                                                    
4000ef40:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
4000ef44:	80 a0 60 00 	cmp  %g1, 0                                    
4000ef48:	22 80 00 03 	be,a   4000ef54 <rtems_bdbuf_release+0x9c>     
4000ef4c:	90 02 20 74 	add  %o0, 0x74, %o0                            
4000ef50:	90 02 20 64 	add  %o0, 0x64, %o0                            
    rtems_bdbuf_wake (&bdbuf_cache.access_waiters);                   
  else                                                                
    rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);                   
4000ef54:	7f ff f7 fb 	call  4000cf40 <rtems_bdbuf_wake>              
4000ef58:	01 00 00 00 	nop                                            
4000ef5c:	30 80 00 06 	b,a   4000ef74 <rtems_bdbuf_release+0xbc>      
    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);             
4000ef60:	7f ff fd 8c 	call  4000e590 <rtems_bdbuf_add_to_modified_list_after_access>
4000ef64:	90 10 00 18 	mov  %i0, %o0                                  
      break;                                                          
4000ef68:	30 80 00 03 	b,a   4000ef74 <rtems_bdbuf_release+0xbc>      
    default:                                                          
      rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_0);
4000ef6c:	7f ff f7 79 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000ef70:	92 10 20 0b 	mov  0xb, %o1                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  if (rtems_bdbuf_tracer)                                             
    rtems_bdbuf_show_usage ();                                        
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000ef74:	7f ff fb 8b 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000ef78:	b0 10 20 00 	clr  %i0                                       
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000ef7c:	81 c7 e0 08 	ret                                            
4000ef80:	81 e8 00 00 	restore                                        
}                                                                     
4000ef84:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000ef88:	91 e8 20 09 	restore  %g0, 9, %o0                           <== NOT EXECUTED
                                                                      

4000ef8c <rtems_bdbuf_release_modified>: rtems_status_code rtems_bdbuf_release_modified (rtems_bdbuf_buffer *bd) {
4000ef8c:	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 (bd == NULL)                                                     
4000ef90:	80 a6 20 00 	cmp  %i0, 0                                    
4000ef94:	02 80 00 18 	be  4000eff4 <rtems_bdbuf_release_modified+0x68><== NEVER TAKEN
4000ef98:	01 00 00 00 	nop                                            
  if (rtems_bdbuf_tracer)                                             
  {                                                                   
    printf ("bdbuf:%s: %" PRIu32 "\n", kind, bd->block);              
    rtems_bdbuf_show_users (kind, bd);                                
  }                                                                   
  rtems_bdbuf_lock_cache();                                           
4000ef9c:	7f ff fb 76 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000efa0:	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)                                                  
4000efa4:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
4000efa8:	80 a2 20 03 	cmp  %o0, 3                                    
4000efac:	0a 80 00 0c 	bcs  4000efdc <rtems_bdbuf_release_modified+0x50><== NEVER TAKEN
4000efb0:	80 a2 20 05 	cmp  %o0, 5                                    
4000efb4:	08 80 00 07 	bleu  4000efd0 <rtems_bdbuf_release_modified+0x44>
4000efb8:	80 a2 20 06 	cmp  %o0, 6                                    
4000efbc:	12 80 00 08 	bne  4000efdc <rtems_bdbuf_release_modified+0x50><== NEVER TAKEN
4000efc0:	01 00 00 00 	nop                                            
    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);                   
4000efc4:	7f ff fd a6 	call  4000e65c <rtems_bdbuf_discard_buffer_after_access>
4000efc8:	90 10 00 18 	mov  %i0, %o0                                  
      break;                                                          
4000efcc:	30 80 00 06 	b,a   4000efe4 <rtems_bdbuf_release_modified+0x58>
  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);             
4000efd0:	7f ff fd 70 	call  4000e590 <rtems_bdbuf_add_to_modified_list_after_access>
4000efd4:	90 10 00 18 	mov  %i0, %o0                                  
      break;                                                          
4000efd8:	30 80 00 03 	b,a   4000efe4 <rtems_bdbuf_release_modified+0x58>
    case RTEMS_BDBUF_STATE_ACCESS_PURGED:                             
      rtems_bdbuf_discard_buffer_after_access (bd);                   
      break;                                                          
    default:                                                          
      rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_6);
4000efdc:	7f ff f7 5d 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000efe0:	92 10 20 0f 	mov  0xf, %o1                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  if (rtems_bdbuf_tracer)                                             
    rtems_bdbuf_show_usage ();                                        
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000efe4:	7f ff fb 6f 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000efe8:	b0 10 20 00 	clr  %i0                                       
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000efec:	81 c7 e0 08 	ret                                            
4000eff0:	81 e8 00 00 	restore                                        
}                                                                     
4000eff4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000eff8:	91 e8 20 09 	restore  %g0, 9, %o0                           <== NOT EXECUTED
                                                                      

4000d018 <rtems_bdbuf_remove_from_tree>: return bdbuf_cache.buffer_waiters.count; } static void rtems_bdbuf_remove_from_tree (rtems_bdbuf_buffer *bd) {
4000d018:	9d e3 bf 20 	save  %sp, -224, %sp                           
                       const rtems_bdbuf_buffer* node)                
{                                                                     
  const rtems_disk_device *dd = node->dd;                             
  rtems_blkdev_bnum block = node->block;                              
                                                                      
  rtems_bdbuf_buffer*  p = *root;                                     
4000d01c:	33 10 00 70 	sethi  %hi(0x4001c000), %i1                    
  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));                           
4000d020:	b8 07 bf 80 	add  %fp, -128, %i4                            
 */                                                                   
static int                                                            
rtems_bdbuf_avl_remove(rtems_bdbuf_buffer**      root,                
                       const rtems_bdbuf_buffer* node)                
{                                                                     
  const rtems_disk_device *dd = node->dd;                             
4000d024:	f6 06 20 14 	ld  [ %i0 + 0x14 ], %i3                        
  rtems_blkdev_bnum block = node->block;                              
4000d028:	f4 06 20 18 	ld  [ %i0 + 0x18 ], %i2                        
                                                                      
  rtems_bdbuf_buffer*  p = *root;                                     
4000d02c:	b2 16 63 dc 	or  %i1, 0x3dc, %i1                            
  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));                           
4000d030:	90 10 00 1c 	mov  %i4, %o0                                  
                       const rtems_bdbuf_buffer* node)                
{                                                                     
  const rtems_disk_device *dd = node->dd;                             
  rtems_blkdev_bnum block = node->block;                              
                                                                      
  rtems_bdbuf_buffer*  p = *root;                                     
4000d034:	fa 06 60 3c 	ld  [ %i1 + 0x3c ], %i5                        
  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));                           
4000d038:	92 10 20 00 	clr  %o1                                       
4000d03c:	40 00 1d 9b 	call  400146a8 <memset>                        
4000d040:	94 10 20 80 	mov  0x80, %o2                                 
  rtems_bdbuf_buffer*  r;                                             
  rtems_bdbuf_buffer*  s;                                             
  rtems_bdbuf_buffer*  p1;                                            
  rtems_bdbuf_buffer*  p2;                                            
  rtems_bdbuf_buffer*  buf_stack[RTEMS_BDBUF_AVL_MAX_HEIGHT];         
  rtems_bdbuf_buffer** buf_prev = buf_stack;                          
4000d044:	88 10 00 1c 	mov  %i4, %g4                                  
    *buf_prev++ = p;                                                  
                                                                      
    if (((uintptr_t) p->dd < (uintptr_t) dd)                          
        || ((p->dd == dd) && (p->block < block)))                     
    {                                                                 
      p->avl.cache = 1;                                               
4000d048:	84 10 20 01 	mov  1, %g2                                    
      p = p->avl.right;                                               
    }                                                                 
    else if ((p->dd != dd) || (p->block != block))                    
    {                                                                 
      p->avl.cache = -1;                                              
4000d04c:	9e 10 3f ff 	mov  -1, %o7                                   
                                                                      
  bool modified = false;                                              
                                                                      
  memset (buf_stack, 0, sizeof(buf_stack));                           
                                                                      
  while (p != NULL)                                                   
4000d050:	80 a7 60 00 	cmp  %i5, 0                                    
4000d054:	02 80 00 16 	be  4000d0ac <rtems_bdbuf_remove_from_tree+0x94><== NEVER TAKEN
4000d058:	86 01 20 04 	add  %g4, 4, %g3                               
  {                                                                   
    *buf_prev++ = p;                                                  
                                                                      
    if (((uintptr_t) p->dd < (uintptr_t) dd)                          
4000d05c:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000d060:	80 a0 40 1b 	cmp  %g1, %i3                                  
4000d064:	0a 80 00 09 	bcs  4000d088 <rtems_bdbuf_remove_from_tree+0x70>
4000d068:	fa 20 ff fc 	st  %i5, [ %g3 + -4 ]                          
        || ((p->dd == dd) && (p->block < block)))                     
4000d06c:	80 a0 40 1b 	cmp  %g1, %i3                                  
4000d070:	32 80 00 0c 	bne,a   4000d0a0 <rtems_bdbuf_remove_from_tree+0x88>
4000d074:	de 2f 60 10 	stb  %o7, [ %i5 + 0x10 ]                       
4000d078:	c2 07 60 18 	ld  [ %i5 + 0x18 ], %g1                        
4000d07c:	80 a0 40 1a 	cmp  %g1, %i2                                  
4000d080:	1a 80 00 05 	bcc  4000d094 <rtems_bdbuf_remove_from_tree+0x7c>
4000d084:	01 00 00 00 	nop                                            
    {                                                                 
      p->avl.cache = 1;                                               
4000d088:	c4 2f 60 10 	stb  %g2, [ %i5 + 0x10 ]                       
      p = p->avl.right;                                               
4000d08c:	10 80 00 06 	b  4000d0a4 <rtems_bdbuf_remove_from_tree+0x8c>
4000d090:	fa 07 60 0c 	ld  [ %i5 + 0xc ], %i5                         
    }                                                                 
    else if ((p->dd != dd) || (p->block != block))                    
4000d094:	22 80 00 09 	be,a   4000d0b8 <rtems_bdbuf_remove_from_tree+0xa0>
4000d098:	b0 10 00 03 	mov  %g3, %i0                                  
    {                                                                 
      p->avl.cache = -1;                                              
4000d09c:	de 2f 60 10 	stb  %o7, [ %i5 + 0x10 ]                       
      p = p->avl.left;                                                
4000d0a0:	fa 07 60 08 	ld  [ %i5 + 8 ], %i5                           
                                                                      
  memset (buf_stack, 0, sizeof(buf_stack));                           
                                                                      
  while (p != NULL)                                                   
  {                                                                   
    *buf_prev++ = p;                                                  
4000d0a4:	10 bf ff eb 	b  4000d050 <rtems_bdbuf_remove_from_tree+0x38>
4000d0a8:	88 10 00 03 	mov  %g3, %g4                                  
                                                                      
static void                                                           
rtems_bdbuf_remove_from_tree (rtems_bdbuf_buffer *bd)                 
{                                                                     
  if (rtems_bdbuf_avl_remove (&bdbuf_cache.tree, bd) != 0)            
    rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_TREE_RM);
4000d0ac:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        <== NOT EXECUTED
4000d0b0:	7f ff ff 28 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000d0b4:	92 10 20 18 	mov  0x18, %o1                                 <== NOT EXECUTED
  }                                                                   
                                                                      
  q = p;                                                              
                                                                      
  buf_prev--;                                                         
  if (buf_prev > buf_stack)                                           
4000d0b8:	80 a1 00 1c 	cmp  %g4, %i4                                  
4000d0bc:	08 80 00 03 	bleu  4000d0c8 <rtems_bdbuf_remove_from_tree+0xb0>
4000d0c0:	b6 10 20 00 	clr  %i3                                       
  {                                                                   
    p = *(buf_prev - 1);                                              
4000d0c4:	f6 00 ff f8 	ld  [ %g3 + -8 ], %i3                          
  {                                                                   
    p = NULL;                                                         
  }                                                                   
                                                                      
  /* at this moment q - is a node to delete, p is q's parent */       
  if (q->avl.right == NULL)                                           
4000d0c8:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4000d0cc:	80 a0 60 00 	cmp  %g1, 0                                    
4000d0d0:	32 80 00 08 	bne,a   4000d0f0 <rtems_bdbuf_remove_from_tree+0xd8>
4000d0d4:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
  {                                                                   
    r = q->avl.left;                                                  
4000d0d8:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
    if (r != NULL)                                                    
4000d0dc:	80 a0 60 00 	cmp  %g1, 0                                    
4000d0e0:	32 80 00 28 	bne,a   4000d180 <rtems_bdbuf_remove_from_tree+0x168>
4000d0e4:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
                                                                      
      *t = q = s;                                                     
    }                                                                 
  }                                                                   
                                                                      
  if (p != NULL)                                                      
4000d0e8:	10 80 00 27 	b  4000d184 <rtems_bdbuf_remove_from_tree+0x16c>
4000d0ec:	80 a6 e0 00 	cmp  %i3, 0                                    
  {                                                                   
    rtems_bdbuf_buffer **t;                                           
                                                                      
    r = q->avl.right;                                                 
                                                                      
    if (r->avl.left == NULL)                                          
4000d0f0:	80 a0 a0 00 	cmp  %g2, 0                                    
4000d0f4:	02 80 00 05 	be  4000d108 <rtems_bdbuf_remove_from_tree+0xf0>
4000d0f8:	84 10 00 01 	mov  %g1, %g2                                  
4000d0fc:	88 10 00 01 	mov  %g1, %g4                                  
                                                                      
      while (s->avl.left != NULL)                                     
      {                                                               
        *buf_prev++ = r = s;                                          
        s = r->avl.left;                                              
        r->avl.cache = -1;                                            
4000d100:	10 80 00 0b 	b  4000d12c <rtems_bdbuf_remove_from_tree+0x114>
4000d104:	9e 10 3f ff 	mov  -1, %o7                                   
                                                                      
    r = q->avl.right;                                                 
                                                                      
    if (r->avl.left == NULL)                                          
    {                                                                 
      r->avl.left = q->avl.left;                                      
4000d108:	c4 07 60 08 	ld  [ %i5 + 8 ], %g2                           
      r->avl.bal = q->avl.bal;                                        
      r->avl.cache = 1;                                               
      *buf_prev++ = q = r;                                            
4000d10c:	c2 20 ff fc 	st  %g1, [ %g3 + -4 ]                          
                                                                      
    r = q->avl.right;                                                 
                                                                      
    if (r->avl.left == NULL)                                          
    {                                                                 
      r->avl.left = q->avl.left;                                      
4000d110:	c4 20 60 08 	st  %g2, [ %g1 + 8 ]                           
      r->avl.bal = q->avl.bal;                                        
4000d114:	c4 0f 60 11 	ldub  [ %i5 + 0x11 ], %g2                      
      r->avl.cache = 1;                                               
      *buf_prev++ = q = r;                                            
4000d118:	88 10 00 03 	mov  %g3, %g4                                  
    r = q->avl.right;                                                 
                                                                      
    if (r->avl.left == NULL)                                          
    {                                                                 
      r->avl.left = q->avl.left;                                      
      r->avl.bal = q->avl.bal;                                        
4000d11c:	c4 28 60 11 	stb  %g2, [ %g1 + 0x11 ]                       
      r->avl.cache = 1;                                               
4000d120:	84 10 20 01 	mov  1, %g2                                    
4000d124:	10 80 00 17 	b  4000d180 <rtems_bdbuf_remove_from_tree+0x168>
4000d128:	c4 28 60 10 	stb  %g2, [ %g1 + 0x10 ]                       
    else                                                              
    {                                                                 
      t = buf_prev++;                                                 
      s = r;                                                          
                                                                      
      while (s->avl.left != NULL)                                     
4000d12c:	f4 00 a0 08 	ld  [ %g2 + 8 ], %i2                           
4000d130:	80 a6 a0 00 	cmp  %i2, 0                                    
4000d134:	22 80 00 08 	be,a   4000d154 <rtems_bdbuf_remove_from_tree+0x13c>
4000d138:	f4 07 60 08 	ld  [ %i5 + 8 ], %i2                           
      {                                                               
        *buf_prev++ = r = s;                                          
4000d13c:	86 00 e0 04 	add  %g3, 4, %g3                               
        s = r->avl.left;                                              
        r->avl.cache = -1;                                            
4000d140:	de 28 a0 10 	stb  %o7, [ %g2 + 0x10 ]                       
      t = buf_prev++;                                                 
      s = r;                                                          
                                                                      
      while (s->avl.left != NULL)                                     
      {                                                               
        *buf_prev++ = r = s;                                          
4000d144:	c4 20 ff fc 	st  %g2, [ %g3 + -4 ]                          
        s = r->avl.left;                                              
4000d148:	88 10 00 02 	mov  %g2, %g4                                  
4000d14c:	10 bf ff f8 	b  4000d12c <rtems_bdbuf_remove_from_tree+0x114>
4000d150:	84 10 00 1a 	mov  %i2, %g2                                  
      r->avl.left = s->avl.right;                                     
      s->avl.right = q->avl.right;                                    
      s->avl.bal = q->avl.bal;                                        
      s->avl.cache = 1;                                               
                                                                      
      *t = q = s;                                                     
4000d154:	c4 26 3f fc 	st  %g2, [ %i0 + -4 ]                          
        *buf_prev++ = r = s;                                          
        s = r->avl.left;                                              
        r->avl.cache = -1;                                            
      }                                                               
                                                                      
      s->avl.left = q->avl.left;                                      
4000d158:	f4 20 a0 08 	st  %i2, [ %g2 + 8 ]                           
      r->avl.left = s->avl.right;                                     
4000d15c:	f4 00 a0 0c 	ld  [ %g2 + 0xc ], %i2                         
4000d160:	f4 21 20 08 	st  %i2, [ %g4 + 8 ]                           
      s->avl.right = q->avl.right;                                    
4000d164:	c2 20 a0 0c 	st  %g1, [ %g2 + 0xc ]                         
      s->avl.bal = q->avl.bal;                                        
4000d168:	c2 0f 60 11 	ldub  [ %i5 + 0x11 ], %g1                      
      s->avl.cache = 1;                                               
                                                                      
      *t = q = s;                                                     
4000d16c:	88 10 00 03 	mov  %g3, %g4                                  
      }                                                               
                                                                      
      s->avl.left = q->avl.left;                                      
      r->avl.left = s->avl.right;                                     
      s->avl.right = q->avl.right;                                    
      s->avl.bal = q->avl.bal;                                        
4000d170:	c2 28 a0 11 	stb  %g1, [ %g2 + 0x11 ]                       
      s->avl.cache = 1;                                               
4000d174:	82 10 20 01 	mov  1, %g1                                    
4000d178:	c2 28 a0 10 	stb  %g1, [ %g2 + 0x10 ]                       
                                                                      
      *t = q = s;                                                     
4000d17c:	82 10 00 02 	mov  %g2, %g1                                  
    }                                                                 
  }                                                                   
                                                                      
  if (p != NULL)                                                      
4000d180:	80 a6 e0 00 	cmp  %i3, 0                                    
4000d184:	22 80 00 07 	be,a   4000d1a0 <rtems_bdbuf_remove_from_tree+0x188>
4000d188:	c2 26 60 3c 	st  %g1, [ %i1 + 0x3c ]                        
  {                                                                   
    if (p->avl.cache == -1)                                           
4000d18c:	c4 4e e0 10 	ldsb  [ %i3 + 0x10 ], %g2                      
4000d190:	80 a0 bf ff 	cmp  %g2, -1                                   
4000d194:	32 80 00 03 	bne,a   4000d1a0 <rtems_bdbuf_remove_from_tree+0x188>
4000d198:	c2 26 e0 0c 	st  %g1, [ %i3 + 0xc ]                         
    {                                                                 
      p->avl.left = q;                                                
4000d19c:	c2 26 e0 08 	st  %g1, [ %i3 + 8 ]                           
      {                                                               
        case -1:                                                      
          p->avl.bal = 0;                                             
          break;                                                      
        case  0:                                                      
          p->avl.bal = 1;                                             
4000d1a0:	ba 10 20 01 	mov  1, %i5                                    
                                                                      
  modified = true;                                                    
                                                                      
  while (modified)                                                    
  {                                                                   
    if (buf_prev > buf_stack)                                         
4000d1a4:	80 a1 00 1c 	cmp  %g4, %i4                                  
4000d1a8:	08 80 00 70 	bleu  4000d368 <rtems_bdbuf_remove_from_tree+0x350>
4000d1ac:	b4 10 3f ff 	mov  -1, %i2                                   
    {                                                                 
      p = *--buf_prev;                                                
4000d1b0:	c2 01 3f fc 	ld  [ %g4 + -4 ], %g1                          
    else                                                              
    {                                                                 
      break;                                                          
    }                                                                 
                                                                      
    if (p->avl.cache == -1)                                           
4000d1b4:	f6 48 60 10 	ldsb  [ %g1 + 0x10 ], %i3                      
4000d1b8:	c4 08 60 11 	ldub  [ %g1 + 0x11 ], %g2                      
4000d1bc:	80 a6 ff ff 	cmp  %i3, -1                                   
    {                                                                 
      /* rebalance left branch */                                     
      switch (p->avl.bal)                                             
4000d1c0:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
    else                                                              
    {                                                                 
      break;                                                          
    }                                                                 
                                                                      
    if (p->avl.cache == -1)                                           
4000d1c4:	12 80 00 2c 	bne  4000d274 <rtems_bdbuf_remove_from_tree+0x25c>
4000d1c8:	85 38 a0 18 	sra  %g2, 0x18, %g2                            
    {                                                                 
      /* rebalance left branch */                                     
      switch (p->avl.bal)                                             
4000d1cc:	80 a0 a0 00 	cmp  %g2, 0                                    
4000d1d0:	02 80 00 08 	be  4000d1f0 <rtems_bdbuf_remove_from_tree+0x1d8>
4000d1d4:	80 a0 a0 01 	cmp  %g2, 1                                    
4000d1d8:	02 80 00 08 	be  4000d1f8 <rtems_bdbuf_remove_from_tree+0x1e0>
4000d1dc:	80 a0 bf ff 	cmp  %g2, -1                                   
4000d1e0:	12 80 00 54 	bne  4000d330 <rtems_bdbuf_remove_from_tree+0x318><== NEVER TAKEN
4000d1e4:	84 10 20 01 	mov  1, %g2                                    
    {                                                                 
      /* rebalance right branch */                                    
      switch (p->avl.bal)                                             
      {                                                               
        case +1:                                                      
          p->avl.bal = 0;                                             
4000d1e8:	10 80 00 52 	b  4000d330 <rtems_bdbuf_remove_from_tree+0x318>
4000d1ec:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
      {                                                               
        case -1:                                                      
          p->avl.bal = 0;                                             
          break;                                                      
        case  0:                                                      
          p->avl.bal = 1;                                             
4000d1f0:	10 80 00 0d 	b  4000d224 <rtems_bdbuf_remove_from_tree+0x20c>
4000d1f4:	fa 28 60 11 	stb  %i5, [ %g1 + 0x11 ]                       
          modified = false;                                           
          break;                                                      
                                                                      
        case +1:                                                      
          p1 = p->avl.right;                                          
4000d1f8:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
                                                                      
          if (p1->avl.bal >= 0) /* simple RR-turn */                  
4000d1fc:	f0 48 a0 11 	ldsb  [ %g2 + 0x11 ], %i0                      
4000d200:	80 a6 20 00 	cmp  %i0, 0                                    
4000d204:	06 80 00 0a 	bl  4000d22c <rtems_bdbuf_remove_from_tree+0x214>
4000d208:	c6 00 a0 08 	ld  [ %g2 + 8 ], %g3                           
          {                                                           
            p->avl.right = p1->avl.left;                              
4000d20c:	c6 20 60 0c 	st  %g3, [ %g1 + 0xc ]                         
            p1->avl.left = p;                                         
                                                                      
            if (p1->avl.bal == 0)                                     
4000d210:	80 a6 20 00 	cmp  %i0, 0                                    
4000d214:	12 80 00 2f 	bne  4000d2d0 <rtems_bdbuf_remove_from_tree+0x2b8>
4000d218:	c2 20 a0 08 	st  %g1, [ %g2 + 8 ]                           
            {                                                         
              p1->avl.bal = -1;                                       
4000d21c:	f6 28 a0 11 	stb  %i3, [ %g2 + 0x11 ]                       
4000d220:	82 10 00 02 	mov  %g2, %g1                                  
              modified = false;                                       
4000d224:	10 80 00 43 	b  4000d330 <rtems_bdbuf_remove_from_tree+0x318>
4000d228:	84 10 20 00 	clr  %g2                                       
          }                                                           
          else /* double RL-turn */                                   
          {                                                           
            p2 = p1->avl.left;                                        
                                                                      
            p1->avl.left = p2->avl.right;                             
4000d22c:	f0 00 e0 0c 	ld  [ %g3 + 0xc ], %i0                         
4000d230:	f0 20 a0 08 	st  %i0, [ %g2 + 8 ]                           
            p2->avl.right = p1;                                       
            p->avl.right = p2->avl.left;                              
4000d234:	f0 00 e0 08 	ld  [ %g3 + 8 ], %i0                           
          else /* double RL-turn */                                   
          {                                                           
            p2 = p1->avl.left;                                        
                                                                      
            p1->avl.left = p2->avl.right;                             
            p2->avl.right = p1;                                       
4000d238:	c4 20 e0 0c 	st  %g2, [ %g3 + 0xc ]                         
            p->avl.right = p2->avl.left;                              
4000d23c:	f0 20 60 0c 	st  %i0, [ %g1 + 0xc ]                         
            p2->avl.left = p;                                         
                                                                      
            if (p2->avl.bal == +1) p->avl.bal = -1; else p->avl.bal = 0;
4000d240:	f0 48 e0 11 	ldsb  [ %g3 + 0x11 ], %i0                      
4000d244:	80 a6 20 01 	cmp  %i0, 1                                    
4000d248:	12 80 00 04 	bne  4000d258 <rtems_bdbuf_remove_from_tree+0x240>
4000d24c:	c2 20 e0 08 	st  %g1, [ %g3 + 8 ]                           
4000d250:	10 80 00 03 	b  4000d25c <rtems_bdbuf_remove_from_tree+0x244>
4000d254:	f6 28 60 11 	stb  %i3, [ %g1 + 0x11 ]                       
4000d258:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
            if (p2->avl.bal == -1) p1->avl.bal = 1; else p1->avl.bal = 0;
4000d25c:	c2 48 e0 11 	ldsb  [ %g3 + 0x11 ], %g1                      
4000d260:	80 a0 7f ff 	cmp  %g1, -1                                   
4000d264:	32 80 00 30 	bne,a   4000d324 <rtems_bdbuf_remove_from_tree+0x30c><== ALWAYS TAKEN
4000d268:	c0 28 a0 11 	clrb  [ %g2 + 0x11 ]                           
4000d26c:	10 80 00 2e 	b  4000d324 <rtems_bdbuf_remove_from_tree+0x30c><== NOT EXECUTED
4000d270:	fa 28 a0 11 	stb  %i5, [ %g2 + 0x11 ]                       <== NOT EXECUTED
      }                                                               
    }                                                                 
    else                                                              
    {                                                                 
      /* rebalance right branch */                                    
      switch (p->avl.bal)                                             
4000d274:	80 a0 a0 00 	cmp  %g2, 0                                    
4000d278:	02 80 00 0a 	be  4000d2a0 <rtems_bdbuf_remove_from_tree+0x288>
4000d27c:	80 a0 a0 01 	cmp  %g2, 1                                    
4000d280:	02 80 00 06 	be  4000d298 <rtems_bdbuf_remove_from_tree+0x280>
4000d284:	80 a0 bf ff 	cmp  %g2, -1                                   
4000d288:	32 80 00 2a 	bne,a   4000d330 <rtems_bdbuf_remove_from_tree+0x318><== NEVER TAKEN
4000d28c:	84 10 20 01 	mov  1, %g2                                    <== NOT EXECUTED
          p->avl.bal = -1;                                            
          modified = false;                                           
          break;                                                      
                                                                      
        case -1:                                                      
          p1 = p->avl.left;                                           
4000d290:	10 80 00 06 	b  4000d2a8 <rtems_bdbuf_remove_from_tree+0x290>
4000d294:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
    {                                                                 
      /* rebalance right branch */                                    
      switch (p->avl.bal)                                             
      {                                                               
        case +1:                                                      
          p->avl.bal = 0;                                             
4000d298:	10 80 00 25 	b  4000d32c <rtems_bdbuf_remove_from_tree+0x314>
4000d29c:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
          break;                                                      
                                                                      
        case  0:                                                      
          p->avl.bal = -1;                                            
4000d2a0:	10 bf ff e1 	b  4000d224 <rtems_bdbuf_remove_from_tree+0x20c>
4000d2a4:	f4 28 60 11 	stb  %i2, [ %g1 + 0x11 ]                       
          break;                                                      
                                                                      
        case -1:                                                      
          p1 = p->avl.left;                                           
                                                                      
          if (p1->avl.bal <= 0) /* simple LL-turn */                  
4000d2a8:	f6 48 a0 11 	ldsb  [ %g2 + 0x11 ], %i3                      
4000d2ac:	80 a6 e0 00 	cmp  %i3, 0                                    
4000d2b0:	14 80 00 0c 	bg  4000d2e0 <rtems_bdbuf_remove_from_tree+0x2c8>
4000d2b4:	c6 00 a0 0c 	ld  [ %g2 + 0xc ], %g3                         
          {                                                           
            p->avl.left = p1->avl.right;                              
4000d2b8:	c6 20 60 08 	st  %g3, [ %g1 + 8 ]                           
            p1->avl.right = p;                                        
            if (p1->avl.bal == 0)                                     
4000d2bc:	80 a6 e0 00 	cmp  %i3, 0                                    
4000d2c0:	12 80 00 04 	bne  4000d2d0 <rtems_bdbuf_remove_from_tree+0x2b8>
4000d2c4:	c2 20 a0 0c 	st  %g1, [ %g2 + 0xc ]                         
            {                                                         
              p1->avl.bal = 1;                                        
4000d2c8:	10 bf ff d6 	b  4000d220 <rtems_bdbuf_remove_from_tree+0x208>
4000d2cc:	fa 28 a0 11 	stb  %i5, [ %g2 + 0x11 ]                       
              modified = false;                                       
            }                                                         
            else                                                      
            {                                                         
              p->avl.bal = 0;                                         
4000d2d0:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
              p1->avl.bal = 0;                                        
4000d2d4:	c0 28 a0 11 	clrb  [ %g2 + 0x11 ]                           
4000d2d8:	10 80 00 15 	b  4000d32c <rtems_bdbuf_remove_from_tree+0x314>
4000d2dc:	82 10 00 02 	mov  %g2, %g1                                  
          }                                                           
          else /* double LR-turn */                                   
          {                                                           
            p2 = p1->avl.right;                                       
                                                                      
            p1->avl.right = p2->avl.left;                             
4000d2e0:	f6 00 e0 08 	ld  [ %g3 + 8 ], %i3                           
4000d2e4:	f6 20 a0 0c 	st  %i3, [ %g2 + 0xc ]                         
            p2->avl.left = p1;                                        
            p->avl.left = p2->avl.right;                              
4000d2e8:	f6 00 e0 0c 	ld  [ %g3 + 0xc ], %i3                         
          else /* double LR-turn */                                   
          {                                                           
            p2 = p1->avl.right;                                       
                                                                      
            p1->avl.right = p2->avl.left;                             
            p2->avl.left = p1;                                        
4000d2ec:	c4 20 e0 08 	st  %g2, [ %g3 + 8 ]                           
            p->avl.left = p2->avl.right;                              
4000d2f0:	f6 20 60 08 	st  %i3, [ %g1 + 8 ]                           
            p2->avl.right = p;                                        
                                                                      
            if (p2->avl.bal == -1) p->avl.bal = 1; else p->avl.bal = 0;
4000d2f4:	f6 48 e0 11 	ldsb  [ %g3 + 0x11 ], %i3                      
4000d2f8:	80 a6 ff ff 	cmp  %i3, -1                                   
4000d2fc:	12 80 00 04 	bne  4000d30c <rtems_bdbuf_remove_from_tree+0x2f4>
4000d300:	c2 20 e0 0c 	st  %g1, [ %g3 + 0xc ]                         
4000d304:	10 80 00 03 	b  4000d310 <rtems_bdbuf_remove_from_tree+0x2f8>
4000d308:	fa 28 60 11 	stb  %i5, [ %g1 + 0x11 ]                       
4000d30c:	c0 28 60 11 	clrb  [ %g1 + 0x11 ]                           
            if (p2->avl.bal == +1) p1->avl.bal = -1; else p1->avl.bal = 0;
4000d310:	c2 48 e0 11 	ldsb  [ %g3 + 0x11 ], %g1                      
4000d314:	80 a0 60 01 	cmp  %g1, 1                                    
4000d318:	32 80 00 03 	bne,a   4000d324 <rtems_bdbuf_remove_from_tree+0x30c>
4000d31c:	c0 28 a0 11 	clrb  [ %g2 + 0x11 ]                           
4000d320:	f4 28 a0 11 	stb  %i2, [ %g2 + 0x11 ]                       
                                                                      
            p = p2;                                                   
            p2->avl.bal = 0;                                          
4000d324:	c0 28 e0 11 	clrb  [ %g3 + 0x11 ]                           
4000d328:	82 10 00 03 	mov  %g3, %g1                                  
      }                                                               
    }                                                                 
    else                                                              
    {                                                                 
      /* rebalance right branch */                                    
      switch (p->avl.bal)                                             
4000d32c:	84 10 20 01 	mov  1, %g2                                    
4000d330:	b6 01 3f fc 	add  %g4, -4, %i3                              
        default:                                                      
          break;                                                      
      }                                                               
    }                                                                 
                                                                      
    if (buf_prev > buf_stack)                                         
4000d334:	80 a6 c0 1c 	cmp  %i3, %i4                                  
4000d338:	28 80 00 0c 	bleu,a   4000d368 <rtems_bdbuf_remove_from_tree+0x350>
4000d33c:	c2 26 60 3c 	st  %g1, [ %i1 + 0x3c ]                        
    {                                                                 
      q = *(buf_prev - 1);                                            
4000d340:	c6 01 3f f8 	ld  [ %g4 + -8 ], %g3                          
                                                                      
      if (q->avl.cache == -1)                                         
4000d344:	c8 48 e0 10 	ldsb  [ %g3 + 0x10 ], %g4                      
4000d348:	80 a1 3f ff 	cmp  %g4, -1                                   
4000d34c:	32 80 00 04 	bne,a   4000d35c <rtems_bdbuf_remove_from_tree+0x344>
4000d350:	c2 20 e0 0c 	st  %g1, [ %g3 + 0xc ]                         
      {                                                               
        q->avl.left = p;                                              
4000d354:	10 80 00 02 	b  4000d35c <rtems_bdbuf_remove_from_tree+0x344>
4000d358:	c2 20 e0 08 	st  %g1, [ %g3 + 8 ]                           
    *root = q;                                                        
  }                                                                   
                                                                      
  modified = true;                                                    
                                                                      
  while (modified)                                                    
4000d35c:	80 88 a0 ff 	btst  0xff, %g2                                
4000d360:	12 bf ff 94 	bne  4000d1b0 <rtems_bdbuf_remove_from_tree+0x198>
4000d364:	88 10 00 1b 	mov  %i3, %g4                                  
4000d368:	81 c7 e0 08 	ret                                            
4000d36c:	81 e8 00 00 	restore                                        
                                                                      

4000d4f8 <rtems_bdbuf_remove_from_tree_and_lru_list>: rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_TREE_RM); } static void rtems_bdbuf_remove_from_tree_and_lru_list (rtems_bdbuf_buffer *bd) {
4000d4f8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  switch (bd->state)                                                  
4000d4fc:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
4000d500:	80 a2 20 00 	cmp  %o0, 0                                    
4000d504:	02 80 00 0a 	be  4000d52c <rtems_bdbuf_remove_from_tree_and_lru_list+0x34>
4000d508:	80 a2 20 02 	cmp  %o0, 2                                    
4000d50c:	12 80 00 06 	bne  4000d524 <rtems_bdbuf_remove_from_tree_and_lru_list+0x2c><== NEVER TAKEN
4000d510:	01 00 00 00 	nop                                            
  {                                                                   
    case RTEMS_BDBUF_STATE_FREE:                                      
      break;                                                          
    case RTEMS_BDBUF_STATE_CACHED:                                    
      rtems_bdbuf_remove_from_tree (bd);                              
4000d514:	7f ff fe c1 	call  4000d018 <rtems_bdbuf_remove_from_tree>  
4000d518:	90 10 00 18 	mov  %i0, %o0                                  
      break;                                                          
4000d51c:	10 80 00 05 	b  4000d530 <rtems_bdbuf_remove_from_tree_and_lru_list+0x38>
4000d520:	c4 06 00 00 	ld  [ %i0 ], %g2                               
    default:                                                          
      rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_10);
4000d524:	7f ff fe 0b 	call  4000cd50 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000d528:	92 10 20 13 	mov  0x13, %o1                                 <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4000d52c:	c4 06 00 00 	ld  [ %i0 ], %g2                               
  previous       = the_node->previous;                                
4000d530:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
  next->previous = previous;                                          
4000d534:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4000d538:	c4 20 40 00 	st  %g2, [ %g1 ]                               
4000d53c:	81 c7 e0 08 	ret                                            
4000d540:	81 e8 00 00 	restore                                        
                                                                      

4000f068 <rtems_bdbuf_set_block_size>: rtems_status_code rtems_bdbuf_set_block_size (rtems_disk_device *dd, uint32_t block_size, bool sync) {
4000f068:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
  /*                                                                  
   * We do not care about the synchronization status since we will purge the
   * device later.                                                    
   */                                                                 
  if (sync)                                                           
4000f06c:	80 a6 a0 00 	cmp  %i2, 0                                    
4000f070:	02 80 00 04 	be  4000f080 <rtems_bdbuf_set_block_size+0x18> 
4000f074:	ba 10 00 18 	mov  %i0, %i5                                  
    rtems_bdbuf_syncdev (dd);                                         
4000f078:	7f ff ff e1 	call  4000effc <rtems_bdbuf_syncdev>           
4000f07c:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  rtems_bdbuf_lock_cache ();                                          
4000f080:	7f ff fb 3d 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000f084:	b0 10 20 0a 	mov  0xa, %i0                                  
                                                                      
  if (block_size > 0)                                                 
4000f088:	80 a6 60 00 	cmp  %i1, 0                                    
4000f08c:	02 80 00 32 	be  4000f154 <rtems_bdbuf_set_block_size+0xec> 
4000f090:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
rtems_bdbuf_bds_per_group (size_t size)                               
{                                                                     
  size_t bufs_per_size;                                               
  size_t bds_per_size;                                                
                                                                      
  if (size > bdbuf_config.buffer_max)                                 
4000f094:	82 10 62 d8 	or  %g1, 0x2d8, %g1	! 40019ed8 <rtems_bdbuf_configuration>
4000f098:	c4 00 60 28 	ld  [ %g1 + 0x28 ], %g2                        
4000f09c:	80 a6 40 02 	cmp  %i1, %g2                                  
4000f0a0:	18 80 00 2d 	bgu  4000f154 <rtems_bdbuf_set_block_size+0xec><== NEVER TAKEN
4000f0a4:	01 00 00 00 	nop                                            
    return 0;                                                         
                                                                      
  bufs_per_size = ((size - 1) / bdbuf_config.buffer_min) + 1;         
4000f0a8:	d2 00 60 24 	ld  [ %g1 + 0x24 ], %o1                        
4000f0ac:	40 00 23 88 	call  40017ecc <.udiv>                         
4000f0b0:	90 06 7f ff 	add  %i1, -1, %o0                              
                                                                      
  for (bds_per_size = 1;                                              
4000f0b4:	92 10 20 01 	mov  1, %o1                                    
  size_t bds_per_size;                                                
                                                                      
  if (size > bdbuf_config.buffer_max)                                 
    return 0;                                                         
                                                                      
  bufs_per_size = ((size - 1) / bdbuf_config.buffer_min) + 1;         
4000f0b8:	90 02 20 01 	inc  %o0                                       
                                                                      
  for (bds_per_size = 1;                                              
4000f0bc:	80 a2 40 08 	cmp  %o1, %o0                                  
4000f0c0:	1a 80 00 04 	bcc  4000f0d0 <rtems_bdbuf_set_block_size+0x68>
4000f0c4:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
       bds_per_size < bufs_per_size;                                  
       bds_per_size <<= 1)                                            
4000f0c8:	10 bf ff fd 	b  4000f0bc <rtems_bdbuf_set_block_size+0x54>  
4000f0cc:	93 2a 60 01 	sll  %o1, 1, %o1                               
    ;                                                                 
                                                                      
  return bdbuf_cache.max_bds_per_group / bds_per_size;                
4000f0d0:	d0 00 63 fc 	ld  [ %g1 + 0x3fc ], %o0                       
4000f0d4:	40 00 23 7e 	call  40017ecc <.udiv>                         
4000f0d8:	b0 10 20 0a 	mov  0xa, %i0                                  
                                                                      
  if (block_size > 0)                                                 
  {                                                                   
    size_t bds_per_group = rtems_bdbuf_bds_per_group (block_size);    
                                                                      
    if (bds_per_group != 0)                                           
4000f0dc:	80 a2 20 00 	cmp  %o0, 0                                    
4000f0e0:	02 80 00 1d 	be  4000f154 <rtems_bdbuf_set_block_size+0xec> <== NEVER TAKEN
4000f0e4:	b4 10 00 08 	mov  %o0, %i2                                  
    {                                                                 
      int block_to_media_block_shift = 0;                             
      uint32_t media_blocks_per_block = block_size / dd->media_block_size;
4000f0e8:	f0 07 60 20 	ld  [ %i5 + 0x20 ], %i0                        
4000f0ec:	90 10 00 19 	mov  %i1, %o0                                  
4000f0f0:	40 00 23 77 	call  40017ecc <.udiv>                         
4000f0f4:	92 10 00 18 	mov  %i0, %o1                                  
  {                                                                   
    size_t bds_per_group = rtems_bdbuf_bds_per_group (block_size);    
                                                                      
    if (bds_per_group != 0)                                           
    {                                                                 
      int block_to_media_block_shift = 0;                             
4000f0f8:	b8 10 20 00 	clr  %i4                                       
      uint32_t media_blocks_per_block = block_size / dd->media_block_size;
4000f0fc:	b6 10 00 08 	mov  %o0, %i3                                  
      uint32_t one = 1;                                               
                                                                      
      while ((one << block_to_media_block_shift) < media_blocks_per_block)
4000f100:	84 10 20 01 	mov  1, %g2                                    
4000f104:	83 28 80 1c 	sll  %g2, %i4, %g1                             
4000f108:	80 a0 40 1b 	cmp  %g1, %i3                                  
4000f10c:	3a 80 00 04 	bcc,a   4000f11c <rtems_bdbuf_set_block_size+0xb4>
4000f110:	b1 2e 00 1c 	sll  %i0, %i4, %i0                             
      {                                                               
        ++block_to_media_block_shift;                                 
4000f114:	10 bf ff fc 	b  4000f104 <rtems_bdbuf_set_block_size+0x9c>  
4000f118:	b8 07 20 01 	inc  %i4                                       
      }                                                               
                                                                      
      if ((dd->media_block_size << block_to_media_block_shift) != block_size)
4000f11c:	80 a6 00 19 	cmp  %i0, %i1                                  
4000f120:	32 80 00 02 	bne,a   4000f128 <rtems_bdbuf_set_block_size+0xc0><== NEVER TAKEN
4000f124:	b8 10 3f ff 	mov  -1, %i4                                   <== NOT EXECUTED
        block_to_media_block_shift = -1;                              
                                                                      
      dd->block_size = block_size;                                    
      dd->block_count = dd->size / media_blocks_per_block;            
4000f128:	d0 07 60 1c 	ld  [ %i5 + 0x1c ], %o0                        
4000f12c:	92 10 00 1b 	mov  %i3, %o1                                  
4000f130:	40 00 23 67 	call  40017ecc <.udiv>                         
4000f134:	f2 27 60 24 	st  %i1, [ %i5 + 0x24 ]                        
rtems_status_code                                                     
rtems_bdbuf_set_block_size (rtems_disk_device *dd,                    
                            uint32_t           block_size,            
                            bool               sync)                  
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
4000f138:	b0 10 20 00 	clr  %i0                                       
                                                                      
      if ((dd->media_block_size << block_to_media_block_shift) != block_size)
        block_to_media_block_shift = -1;                              
                                                                      
      dd->block_size = block_size;                                    
      dd->block_count = dd->size / media_blocks_per_block;            
4000f13c:	d0 27 60 28 	st  %o0, [ %i5 + 0x28 ]                        
      dd->media_blocks_per_block = media_blocks_per_block;            
4000f140:	f6 27 60 2c 	st  %i3, [ %i5 + 0x2c ]                        
      dd->block_to_media_block_shift = block_to_media_block_shift;    
4000f144:	f8 27 60 30 	st  %i4, [ %i5 + 0x30 ]                        
      dd->bds_per_group = bds_per_group;                              
4000f148:	f4 27 60 34 	st  %i2, [ %i5 + 0x34 ]                        
                                                                      
      rtems_bdbuf_do_purge_dev (dd);                                  
4000f14c:	7f ff fa 97 	call  4000dba8 <rtems_bdbuf_do_purge_dev>      
4000f150:	90 10 00 1d 	mov  %i5, %o0                                  
  else                                                                
  {                                                                   
    sc = RTEMS_INVALID_NUMBER;                                        
  }                                                                   
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000f154:	7f ff fb 13 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000f158:	01 00 00 00 	nop                                            
                                                                      
  return sc;                                                          
}                                                                     
4000f15c:	81 c7 e0 08 	ret                                            
4000f160:	81 e8 00 00 	restore                                        
                                                                      

4000e2c8 <rtems_bdbuf_swapout_task>: * not this. * @return rtems_task Not used. */ static rtems_task rtems_bdbuf_swapout_task (rtems_task_argument arg) {
4000e2c8:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_bdbuf_swapout_transfer* transfer = (rtems_bdbuf_swapout_transfer *) arg;
  uint32_t                      period_in_ticks;                      
  const uint32_t                period_in_msecs = bdbuf_config.swapout_period;
4000e2cc:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
4000e2d0:	f4 00 62 e4 	ld  [ %g1 + 0x2e4 ], %i2	! 40019ee4 <rtems_bdbuf_configuration+0xc>
  /*                                                                  
   * This is temporary. Needs to be changed to use the real time clock.
   */                                                                 
  timer_delta = period_in_msecs;                                      
                                                                      
  while (bdbuf_cache.swapout_enabled)                                 
4000e2d4:	39 10 00 70 	sethi  %hi(0x4001c000), %i4                    
  uint32_t                      timer_delta;                          
                                                                      
  /*                                                                  
   * Localise the period.                                             
   */                                                                 
  period_in_ticks = RTEMS_MICROSECONDS_TO_TICKS (period_in_msecs * 1000);
4000e2d8:	83 2e a0 02 	sll  %i2, 2, %g1                               
4000e2dc:	91 2e a0 07 	sll  %i2, 7, %o0                               
4000e2e0:	90 22 00 01 	sub  %o0, %g1, %o0                             
4000e2e4:	03 10 00 67 	sethi  %hi(0x40019c00), %g1                    
4000e2e8:	d2 00 62 14 	ld  [ %g1 + 0x214 ], %o1	! 40019e14 <Configuration+0x14>
  /*                                                                  
   * This is temporary. Needs to be changed to use the real time clock.
   */                                                                 
  timer_delta = period_in_msecs;                                      
                                                                      
  while (bdbuf_cache.swapout_enabled)                                 
4000e2ec:	b8 17 23 dc 	or  %i4, 0x3dc, %i4                            
  uint32_t                      timer_delta;                          
                                                                      
  /*                                                                  
   * Localise the period.                                             
   */                                                                 
  period_in_ticks = RTEMS_MICROSECONDS_TO_TICKS (period_in_msecs * 1000);
4000e2f0:	90 02 00 1a 	add  %o0, %i2, %o0                             
4000e2f4:	a0 10 00 1c 	mov  %i4, %l0                                  
4000e2f8:	91 2a 20 03 	sll  %o0, 3, %o0                               
4000e2fc:	40 00 26 f4 	call  40017ecc <.udiv>                         
4000e300:	b2 10 00 1c 	mov  %i4, %i1                                  
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000e304:	a4 07 20 0c 	add  %i4, 0xc, %l2                             
4000e308:	a2 10 00 08 	mov  %o0, %l1                                  
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
                                                                      
  head->next = new_first;                                             
  new_first->previous = head;                                         
4000e30c:	a6 07 20 08 	add  %i4, 8, %l3                               
                                                                      
  /*                                                                  
   * 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->dd,             
4000e310:	a8 07 20 58 	add  %i4, 0x58, %l4                            
                                           timer_delta);              
                                                                      
  /*                                                                  
   * Process the cache's modified list.                               
   */                                                                 
  rtems_bdbuf_swapout_modified_processing (&transfer->dd,             
4000e314:	aa 07 20 4c 	add  %i4, 0x4c, %l5                            
  /*                                                                  
   * This is temporary. Needs to be changed to use the real time clock.
   */                                                                 
  timer_delta = period_in_msecs;                                      
                                                                      
  while (bdbuf_cache.swapout_enabled)                                 
4000e318:	c2 0f 20 04 	ldub  [ %i4 + 4 ], %g1                         
4000e31c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e320:	02 80 00 68 	be  4000e4c0 <rtems_bdbuf_swapout_task+0x1f8>  <== NEVER TAKEN
4000e324:	ac 10 20 01 	mov  1, %l6                                    
                                rtems_bdbuf_swapout_transfer* transfer)
{                                                                     
  rtems_bdbuf_swapout_worker* worker;                                 
  bool                        transfered_buffers = false;             
                                                                      
  rtems_bdbuf_lock_cache ();                                          
4000e328:	7f ff fe 93 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000e32c:	ba 10 00 18 	mov  %i0, %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)                                        
4000e330:	c2 0c 20 30 	ldub  [ %l0 + 0x30 ], %g1                      
4000e334:	86 88 60 ff 	andcc  %g1, 0xff, %g3                          
4000e338:	12 80 00 0c 	bne  4000e368 <rtems_bdbuf_swapout_task+0xa0>  
4000e33c:	b6 10 20 00 	clr  %i3                                       
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000e340:	f6 06 60 08 	ld  [ %i1 + 8 ], %i3                           
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000e344:	80 a6 c0 12 	cmp  %i3, %l2                                  
4000e348:	02 80 00 06 	be  4000e360 <rtems_bdbuf_swapout_task+0x98>   <== ALWAYS TAKEN
4000e34c:	ba 06 e0 10 	add  %i3, 0x10, %i5                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4000e350:	c4 06 c0 00 	ld  [ %i3 ], %g2                               <== NOT EXECUTED
                                                                      
  head->next = new_first;                                             
4000e354:	c4 26 60 08 	st  %g2, [ %i1 + 8 ]                           <== NOT EXECUTED
  new_first->previous = head;                                         
4000e358:	10 80 00 04 	b  4000e368 <rtems_bdbuf_swapout_task+0xa0>    <== NOT EXECUTED
4000e35c:	e6 20 a0 04 	st  %l3, [ %g2 + 4 ]                           <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000e360:	ba 10 00 18 	mov  %i0, %i5                                  
    return _Chain_Get_first_unprotected(the_chain);                   
  else                                                                
    return NULL;                                                      
4000e364:	b6 10 20 00 	clr  %i3                                       
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000e368:	ae 07 60 04 	add  %i5, 4, %l7                               
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
4000e36c:	c0 27 60 04 	clr  [ %i5 + 4 ]                               
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e370:	ee 27 40 00 	st  %l7, [ %i5 ]                               
  head->previous = NULL;                                              
  tail->previous = head;                                              
4000e374:	fa 27 60 08 	st  %i5, [ %i5 + 8 ]                           
    if (worker)                                                       
      transfer = &worker->transfer;                                   
  }                                                                   
                                                                      
  rtems_chain_initialize_empty (&transfer->bds);                      
  transfer->dd = BDBUF_INVALID_DEV;                                   
4000e378:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
  /*                                                                  
   * 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)                                        
4000e37c:	80 a0 e0 00 	cmp  %g3, 0                                    
4000e380:	02 80 00 04 	be  4000e390 <rtems_bdbuf_swapout_task+0xc8>   
4000e384:	c2 2f 60 10 	stb  %g1, [ %i5 + 0x10 ]                       
    transfer->dd = bdbuf_cache.sync_device;                           
4000e388:	c2 04 20 38 	ld  [ %l0 + 0x38 ], %g1                        
4000e38c:	c2 27 60 0c 	st  %g1, [ %i5 + 0xc ]                         
                                                                      
  /*                                                                  
   * 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->dd,             
4000e390:	82 07 60 0c 	add  %i5, 0xc, %g1                             
4000e394:	92 10 00 14 	mov  %l4, %o1                                  
4000e398:	90 10 00 01 	mov  %g1, %o0                                  
4000e39c:	94 10 00 1d 	mov  %i5, %o2                                  
4000e3a0:	96 10 20 01 	mov  1, %o3                                    
4000e3a4:	98 10 20 00 	clr  %o4                                       
4000e3a8:	9a 10 00 1a 	mov  %i2, %o5                                  
4000e3ac:	7f ff fb fe 	call  4000d3a4 <rtems_bdbuf_swapout_modified_processing>
4000e3b0:	c2 27 bf f4 	st  %g1, [ %fp + -12 ]                         
                                           timer_delta);              
                                                                      
  /*                                                                  
   * Process the cache's modified list.                               
   */                                                                 
  rtems_bdbuf_swapout_modified_processing (&transfer->dd,             
4000e3b4:	c2 07 bf f4 	ld  [ %fp + -12 ], %g1                         
4000e3b8:	d6 0c 20 30 	ldub  [ %l0 + 0x30 ], %o3                      
4000e3bc:	90 10 00 01 	mov  %g1, %o0                                  
4000e3c0:	92 10 00 15 	mov  %l5, %o1                                  
4000e3c4:	94 10 00 1d 	mov  %i5, %o2                                  
4000e3c8:	98 0d a0 01 	and  %l6, 1, %o4                               
4000e3cc:	7f ff fb f6 	call  4000d3a4 <rtems_bdbuf_swapout_modified_processing>
4000e3d0:	9a 10 00 1a 	mov  %i2, %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 ();                                        
4000e3d4:	7f ff fe 73 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000e3d8:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   * If there are buffers to transfer to the media transfer them.     
   */                                                                 
  if (!rtems_chain_is_empty (&transfer->bds))                         
4000e3dc:	c2 07 40 00 	ld  [ %i5 ], %g1                               
4000e3e0:	80 a0 40 17 	cmp  %g1, %l7                                  
4000e3e4:	02 80 00 10 	be  4000e424 <rtems_bdbuf_swapout_task+0x15c>  
4000e3e8:	80 a6 e0 00 	cmp  %i3, 0                                    
  {                                                                   
    if (worker)                                                       
4000e3ec:	02 80 00 0a 	be  4000e414 <rtems_bdbuf_swapout_task+0x14c>  <== ALWAYS TAKEN
4000e3f0:	01 00 00 00 	nop                                            
    {                                                                 
      rtems_status_code sc = rtems_event_send (worker->id,            
4000e3f4:	d0 06 e0 08 	ld  [ %i3 + 8 ], %o0                           <== NOT EXECUTED
4000e3f8:	7f ff e8 a9 	call  4000869c <rtems_event_send>              <== NOT EXECUTED
4000e3fc:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
                                               RTEMS_BDBUF_SWAPOUT_SYNC);
      if (sc != RTEMS_SUCCESSFUL)                                     
4000e400:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4000e404:	02 80 00 09 	be  4000e428 <rtems_bdbuf_swapout_task+0x160>  <== NOT EXECUTED
4000e408:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
        rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_SO_WAKE_2);              
4000e40c:	10 80 00 2b 	b  4000e4b8 <rtems_bdbuf_swapout_task+0x1f0>   <== NOT EXECUTED
4000e410:	90 10 20 0a 	mov  0xa, %o0                                  <== NOT EXECUTED
    }                                                                 
    else                                                              
    {                                                                 
      rtems_bdbuf_swapout_write (transfer);                           
4000e414:	7f ff ff 10 	call  4000e054 <rtems_bdbuf_swapout_write>     
4000e418:	90 10 00 1d 	mov  %i5, %o0                                  
    }                                                                 
                                                                      
    transfered_buffers = true;                                        
4000e41c:	10 80 00 03 	b  4000e428 <rtems_bdbuf_swapout_task+0x160>   
4000e420:	82 10 20 01 	mov  1, %g1                                    
4000e424:	82 10 20 00 	clr  %g1                                       
  }                                                                   
                                                                      
  if (bdbuf_cache.sync_active && !transfered_buffers)                 
4000e428:	c4 0c 20 30 	ldub  [ %l0 + 0x30 ], %g2                      
4000e42c:	80 a0 a0 00 	cmp  %g2, 0                                    
4000e430:	02 80 00 13 	be  4000e47c <rtems_bdbuf_swapout_task+0x1b4>  
4000e434:	82 08 60 ff 	and  %g1, 0xff, %g1                            
4000e438:	80 a0 60 00 	cmp  %g1, 0                                    
4000e43c:	12 bf ff bb 	bne  4000e328 <rtems_bdbuf_swapout_task+0x60>  
4000e440:	ac 10 20 00 	clr  %l6                                       
  {                                                                   
    rtems_id sync_requester;                                          
    rtems_bdbuf_lock_cache ();                                        
4000e444:	7f ff fe 4c 	call  4000dd74 <rtems_bdbuf_lock_cache>        
4000e448:	01 00 00 00 	nop                                            
    sync_requester = bdbuf_cache.sync_requester;                      
4000e44c:	fa 06 60 34 	ld  [ %i1 + 0x34 ], %i5                        
    bdbuf_cache.sync_active = false;                                  
4000e450:	c0 2e 60 30 	clrb  [ %i1 + 0x30 ]                           
    bdbuf_cache.sync_requester = 0;                                   
    rtems_bdbuf_unlock_cache ();                                      
4000e454:	7f ff fe 53 	call  4000dda0 <rtems_bdbuf_unlock_cache>      
4000e458:	c0 26 60 34 	clr  [ %i1 + 0x34 ]                            
    if (sync_requester)                                               
4000e45c:	80 a7 60 00 	cmp  %i5, 0                                    
4000e460:	22 80 00 0b 	be,a   4000e48c <rtems_bdbuf_swapout_task+0x1c4><== NEVER TAKEN
4000e464:	90 10 20 04 	mov  4, %o0                                    <== NOT EXECUTED
4000e468:	90 10 00 1d 	mov  %i5, %o0                                  
4000e46c:	7f ff ea 30 	call  40008d2c <rtems_event_system_send>       
4000e470:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
       */                                                             
      update_timers = false;                                          
    }                                                                 
    while (transfered_buffers);                                       
                                                                      
    sc = rtems_event_receive (RTEMS_BDBUF_SWAPOUT_SYNC,               
4000e474:	10 80 00 06 	b  4000e48c <rtems_bdbuf_swapout_task+0x1c4>   
4000e478:	90 10 20 04 	mov  4, %o0                                    
      /*                                                              
       * 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,                
4000e47c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e480:	12 bf ff aa 	bne  4000e328 <rtems_bdbuf_swapout_task+0x60>  
4000e484:	ac 10 20 00 	clr  %l6                                       
       */                                                             
      update_timers = false;                                          
    }                                                                 
    while (transfered_buffers);                                       
                                                                      
    sc = rtems_event_receive (RTEMS_BDBUF_SWAPOUT_SYNC,               
4000e488:	90 10 20 04 	mov  4, %o0                                    
4000e48c:	92 10 20 00 	clr  %o1                                       
4000e490:	94 10 00 11 	mov  %l1, %o2                                  
4000e494:	7f ff e8 22 	call  4000851c <rtems_event_receive>           
4000e498:	96 07 bf fc 	add  %fp, -4, %o3                              
                              RTEMS_EVENT_ALL | RTEMS_WAIT,           
                              period_in_ticks,                        
                              &out);                                  
                                                                      
    if ((sc != RTEMS_SUCCESSFUL) && (sc != RTEMS_TIMEOUT))            
4000e49c:	80 a2 20 06 	cmp  %o0, 6                                    
4000e4a0:	22 bf ff 9f 	be,a   4000e31c <rtems_bdbuf_swapout_task+0x54>
4000e4a4:	c2 0f 20 04 	ldub  [ %i4 + 4 ], %g1                         
4000e4a8:	80 a2 20 00 	cmp  %o0, 0                                    
4000e4ac:	22 bf ff 9c 	be,a   4000e31c <rtems_bdbuf_swapout_task+0x54><== ALWAYS TAKEN
4000e4b0:	c2 0f 20 04 	ldub  [ %i4 + 4 ], %g1                         
      rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_SWAPOUT_RE);               
4000e4b4:	90 10 20 15 	mov  0x15, %o0                                 <== NOT EXECUTED
4000e4b8:	7f ff fa 10 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000e4bc:	01 00 00 00 	nop                                            <== NOT EXECUTED
static void                                                           
rtems_bdbuf_swapout_workers_close (void)                              
{                                                                     
  rtems_chain_node* node;                                             
                                                                      
  rtems_bdbuf_lock_cache ();                                          
4000e4c0:	7f ff fe 2d 	call  4000dd74 <rtems_bdbuf_lock_cache>        <== NOT EXECUTED
4000e4c4:	b8 07 20 0c 	add  %i4, 0xc, %i4                             <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000e4c8:	fa 07 3f fc 	ld  [ %i4 + -4 ], %i5                          <== NOT EXECUTED
                                                                      
  node = rtems_chain_first (&bdbuf_cache.swapout_free_workers);       
  while (!rtems_chain_is_tail (&bdbuf_cache.swapout_free_workers, node))
4000e4cc:	80 a7 40 1c 	cmp  %i5, %i4                                  <== NOT EXECUTED
4000e4d0:	02 80 00 08 	be  4000e4f0 <rtems_bdbuf_swapout_task+0x228>  <== NOT EXECUTED
4000e4d4:	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);          
4000e4d8:	d0 07 60 08 	ld  [ %i5 + 8 ], %o0                           <== NOT EXECUTED
                                                                      
  node = rtems_chain_first (&bdbuf_cache.swapout_free_workers);       
  while (!rtems_chain_is_tail (&bdbuf_cache.swapout_free_workers, node))
  {                                                                   
    rtems_bdbuf_swapout_worker* worker = (rtems_bdbuf_swapout_worker*) node;
    worker->enabled = false;                                          
4000e4dc:	c0 2f 60 0c 	clrb  [ %i5 + 0xc ]                            <== NOT EXECUTED
    rtems_event_send (worker->id, RTEMS_BDBUF_SWAPOUT_SYNC);          
4000e4e0:	7f ff e8 6f 	call  4000869c <rtems_event_send>              <== NOT EXECUTED
4000e4e4:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
4000e4e8:	10 bf ff f9 	b  4000e4cc <rtems_bdbuf_swapout_task+0x204>   <== NOT EXECUTED
4000e4ec:	fa 07 40 00 	ld  [ %i5 ], %i5                               <== NOT EXECUTED
    node = rtems_chain_next (node);                                   
  }                                                                   
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
4000e4f0:	7f ff fe 2c 	call  4000dda0 <rtems_bdbuf_unlock_cache>      <== NOT EXECUTED
4000e4f4:	01 00 00 00 	nop                                            <== NOT EXECUTED
      rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_SWAPOUT_RE);               
  }                                                                   
                                                                      
  rtems_bdbuf_swapout_workers_close ();                               
                                                                      
  free (transfer);                                                    
4000e4f8:	7f ff d9 2c 	call  400049a8 <free>                          <== NOT EXECUTED
4000e4fc:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
                                                                      
  rtems_task_delete (RTEMS_SELF);                                     
4000e500:	7f ff ea 6e 	call  40008eb8 <rtems_task_delete>             <== NOT EXECUTED
4000e504:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4000e508:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e50c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e510 <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) {
4000e510:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000e514:	3b 10 00 70 	sethi  %hi(0x4001c000), %i5                    <== NOT EXECUTED
                                                                      
  while (worker->enabled)                                             
  {                                                                   
    rtems_bdbuf_wait_for_event (RTEMS_BDBUF_SWAPOUT_SYNC);            
                                                                      
    rtems_bdbuf_swapout_write (&worker->transfer);                    
4000e518:	b8 06 20 10 	add  %i0, 0x10, %i4                            <== NOT EXECUTED
4000e51c:	ba 17 63 dc 	or  %i5, 0x3dc, %i5                            <== NOT EXECUTED
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4000e520:	b6 06 20 14 	add  %i0, 0x14, %i3                            <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4000e524:	b4 07 60 0c 	add  %i5, 0xc, %i2                             <== 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)                                             
4000e528:	c2 0e 20 0c 	ldub  [ %i0 + 0xc ], %g1                       <== NOT EXECUTED
4000e52c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000e530:	02 80 00 14 	be  4000e580 <rtems_bdbuf_swapout_worker_task+0x70><== NOT EXECUTED
4000e534:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
  {                                                                   
    rtems_bdbuf_wait_for_event (RTEMS_BDBUF_SWAPOUT_SYNC);            
4000e538:	7f ff f9 f5 	call  4000cd0c <rtems_bdbuf_wait_for_event>    <== NOT EXECUTED
4000e53c:	90 10 20 04 	mov  4, %o0                                    <== NOT EXECUTED
                                                                      
    rtems_bdbuf_swapout_write (&worker->transfer);                    
4000e540:	7f ff fe c5 	call  4000e054 <rtems_bdbuf_swapout_write>     <== NOT EXECUTED
4000e544:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
                                                                      
    rtems_bdbuf_lock_cache ();                                        
4000e548:	7f ff fe 0b 	call  4000dd74 <rtems_bdbuf_lock_cache>        <== NOT EXECUTED
4000e54c:	01 00 00 00 	nop                                            <== NOT EXECUTED
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000e550:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4000e554:	f6 26 20 10 	st  %i3, [ %i0 + 0x10 ]                        <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4000e558:	f4 26 00 00 	st  %i2, [ %i0 ]                               <== NOT EXECUTED
  tail->previous = the_node;                                          
4000e55c:	f0 27 60 10 	st  %i0, [ %i5 + 0x10 ]                        <== NOT EXECUTED
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
4000e560:	c0 26 20 14 	clr  [ %i0 + 0x14 ]                            <== NOT EXECUTED
  tail->previous = head;                                              
4000e564:	f8 26 20 18 	st  %i4, [ %i0 + 0x18 ]                        <== NOT EXECUTED
                                                                      
    rtems_chain_initialize_empty (&worker->transfer.bds);             
    worker->transfer.dd = BDBUF_INVALID_DEV;                          
4000e568:	c0 26 20 1c 	clr  [ %i0 + 0x1c ]                            <== NOT EXECUTED
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
  tail->previous = the_node;                                          
  old_last->next = the_node;                                          
4000e56c:	f0 20 40 00 	st  %i0, [ %g1 ]                               <== NOT EXECUTED
                                                                      
    rtems_chain_append_unprotected (&bdbuf_cache.swapout_free_workers, &worker->link);
                                                                      
    rtems_bdbuf_unlock_cache ();                                      
4000e570:	7f ff fe 0c 	call  4000dda0 <rtems_bdbuf_unlock_cache>      <== NOT EXECUTED
4000e574:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           <== 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)                                             
4000e578:	10 bf ff ed 	b  4000e52c <rtems_bdbuf_swapout_worker_task+0x1c><== NOT EXECUTED
4000e57c:	c2 0e 20 0c 	ldub  [ %i0 + 0xc ], %g1                       <== NOT EXECUTED
    rtems_chain_append_unprotected (&bdbuf_cache.swapout_free_workers, &worker->link);
                                                                      
    rtems_bdbuf_unlock_cache ();                                      
  }                                                                   
                                                                      
  free (worker);                                                      
4000e580:	7f ff d9 0a 	call  400049a8 <free>                          <== NOT EXECUTED
4000e584:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
                                                                      
  rtems_task_delete (RTEMS_SELF);                                     
4000e588:	7f ff ea 4c 	call  40008eb8 <rtems_task_delete>             <== NOT EXECUTED
4000e58c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000e054 <rtems_bdbuf_swapout_write>: * * @param transfer The transfer transaction. */ static void rtems_bdbuf_swapout_write (rtems_bdbuf_swapout_transfer* transfer) {
4000e054:	9d e3 bf a0 	save  %sp, -96, %sp                            
    printf ("bdbuf:swapout transfer: %08x\n", (unsigned) transfer->dd->dev);
                                                                      
  /*                                                                  
   * If there are buffers to transfer to the media transfer them.     
   */                                                                 
  if (!rtems_chain_is_empty (&transfer->bds))                         
4000e058:	c2 06 00 00 	ld  [ %i0 ], %g1                               
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4000e05c:	b8 06 20 04 	add  %i0, 4, %i4                               
4000e060:	80 a0 40 1c 	cmp  %g1, %i4                                  
4000e064:	02 80 00 50 	be  4000e1a4 <rtems_bdbuf_swapout_write+0x150> <== NEVER TAKEN
4000e068:	b6 10 20 00 	clr  %i3                                       
     * The last block number used when the driver only supports       
     * continuous blocks in a single request.                         
     */                                                               
    uint32_t last_block = 0;                                          
                                                                      
    rtems_disk_device *dd = transfer->dd;                             
4000e06c:	fa 06 20 0c 	ld  [ %i0 + 0xc ], %i5                         
    uint32_t media_blocks_per_block = dd->media_blocks_per_block;     
    bool need_continuous_blocks =                                     
      (dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_MULTISECTOR_CONT) != 0;
4000e070:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
     * continuous blocks in a single request.                         
     */                                                               
    uint32_t last_block = 0;                                          
                                                                      
    rtems_disk_device *dd = transfer->dd;                             
    uint32_t media_blocks_per_block = dd->media_blocks_per_block;     
4000e074:	f2 07 60 2c 	ld  [ %i5 + 0x2c ], %i1                        
    bool need_continuous_blocks =                                     
      (dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_MULTISECTOR_CONT) != 0;
4000e078:	e0 00 60 0c 	ld  [ %g1 + 0xc ], %l0                         
          (transfer->write_req.bufnum >= bdbuf_config.max_write_blocks))
        write = true;                                                 
                                                                      
      if (write)                                                      
      {                                                               
        rtems_bdbuf_execute_transfer_request (dd, &transfer->write_req, false);
4000e07c:	a2 06 20 14 	add  %i0, 0x14, %l1                            
     * 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;               
4000e080:	82 10 20 0c 	mov  0xc, %g1                                  
    uint32_t last_block = 0;                                          
                                                                      
    rtems_disk_device *dd = transfer->dd;                             
    uint32_t media_blocks_per_block = dd->media_blocks_per_block;     
    bool need_continuous_blocks =                                     
      (dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_MULTISECTOR_CONT) != 0;
4000e084:	a0 0c 20 01 	and  %l0, 1, %l0                               
     * 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;               
4000e088:	c2 26 20 20 	st  %g1, [ %i0 + 0x20 ]                        
    transfer->write_req.bufnum = 0;                                   
4000e08c:	c0 26 20 24 	clr  [ %i0 + 0x24 ]                            
                                                                      
      if (write)                                                      
      {                                                               
        rtems_bdbuf_execute_transfer_request (dd, &transfer->write_req, false);
                                                                      
        transfer->write_req.status = RTEMS_RESOURCE_IN_USE;           
4000e090:	a4 10 20 0c 	mov  0xc, %l2                                  
       * 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))
4000e094:	27 10 00 67 	sethi  %hi(0x40019c00), %l3                    
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4000e098:	c2 06 00 00 	ld  [ %i0 ], %g1                               
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4000e09c:	80 a0 40 1c 	cmp  %g1, %i4                                  
4000e0a0:	02 80 00 35 	be  4000e174 <rtems_bdbuf_swapout_write+0x120> 
4000e0a4:	80 a4 20 00 	cmp  %l0, 0                                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4000e0a8:	c4 00 40 00 	ld  [ %g1 ], %g2                               
                                                                      
  head->next = new_first;                                             
4000e0ac:	c4 26 00 00 	st  %g2, [ %i0 ]                               
  new_first->previous = head;                                         
4000e0b0:	f0 20 a0 04 	st  %i0, [ %g2 + 4 ]                           
4000e0b4:	c6 06 20 24 	ld  [ %i0 + 0x24 ], %g3                        
      if (rtems_bdbuf_tracer)                                         
        printf ("bdbuf:swapout write: bd:%" PRIu32 ", bufnum:%" PRIu32 " mode:%s\n",
                bd->block, transfer->write_req.bufnum,                
                need_continuous_blocks ? "MULTI" : "SCAT");           
                                                                      
      if (need_continuous_blocks && transfer->write_req.bufnum &&     
4000e0b8:	02 80 00 0f 	be  4000e0f4 <rtems_bdbuf_swapout_write+0xa0>  
4000e0bc:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4000e0c0:	80 a0 e0 00 	cmp  %g3, 0                                    
4000e0c4:	02 80 00 0d 	be  4000e0f8 <rtems_bdbuf_swapout_write+0xa4>  
4000e0c8:	b5 28 e0 04 	sll  %g3, 4, %i2                               
          bd->block != last_block + media_blocks_per_block)           
4000e0cc:	b4 06 c0 19 	add  %i3, %i1, %i2                             
      if (rtems_bdbuf_tracer)                                         
        printf ("bdbuf:swapout write: bd:%" PRIu32 ", bufnum:%" PRIu32 " mode:%s\n",
                bd->block, transfer->write_req.bufnum,                
                need_continuous_blocks ? "MULTI" : "SCAT");           
                                                                      
      if (need_continuous_blocks && transfer->write_req.bufnum &&     
4000e0d0:	80 a1 00 1a 	cmp  %g4, %i2                                  
4000e0d4:	02 80 00 09 	be  4000e0f8 <rtems_bdbuf_swapout_write+0xa4>  
4000e0d8:	b5 28 e0 04 	sll  %g3, 4, %i2                               
  Chain_Node *the_node                                                
)                                                                     
{                                                                     
  Chain_Node *before_node;                                            
                                                                      
  the_node->previous    = after_node;                                 
4000e0dc:	f0 20 60 04 	st  %i0, [ %g1 + 4 ]                           
  before_node           = after_node->next;                           
  after_node->next      = the_node;                                   
4000e0e0:	c2 26 00 00 	st  %g1, [ %i0 ]                               
  the_node->next        = before_node;                                
4000e0e4:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  before_node->previous = the_node;                                   
4000e0e8:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
          bd->block != last_block + media_blocks_per_block)           
      {                                                               
        rtems_chain_prepend_unprotected (&transfer->bds, &bd->link);  
        write = true;                                                 
4000e0ec:	10 80 00 0f 	b  4000e128 <rtems_bdbuf_swapout_write+0xd4>   
4000e0f0:	82 10 20 01 	mov  1, %g1                                    
      }                                                               
      else                                                            
      {                                                               
        rtems_blkdev_sg_buffer* buf;                                  
        buf = &transfer->write_req.bufs[transfer->write_req.bufnum];  
4000e0f4:	b5 28 e0 04 	sll  %g3, 4, %i2                               
        transfer->write_req.bufnum++;                                 
4000e0f8:	86 00 e0 01 	inc  %g3                                       
4000e0fc:	c6 26 20 24 	st  %g3, [ %i0 + 0x24 ]                        
        write = true;                                                 
      }                                                               
      else                                                            
      {                                                               
        rtems_blkdev_sg_buffer* buf;                                  
        buf = &transfer->write_req.bufs[transfer->write_req.bufnum];  
4000e100:	b4 06 a0 28 	add  %i2, 0x28, %i2                            
        transfer->write_req.bufnum++;                                 
        buf->user   = bd;                                             
        buf->block  = bd->block;                                      
        buf->length = dd->block_size;                                 
4000e104:	c6 07 60 24 	ld  [ %i5 + 0x24 ], %g3                        
        write = true;                                                 
      }                                                               
      else                                                            
      {                                                               
        rtems_blkdev_sg_buffer* buf;                                  
        buf = &transfer->write_req.bufs[transfer->write_req.bufnum];  
4000e108:	b4 06 00 1a 	add  %i0, %i2, %i2                             
        transfer->write_req.bufnum++;                                 
        buf->user   = bd;                                             
4000e10c:	c2 26 a0 10 	st  %g1, [ %i2 + 0x10 ]                        
        buf->block  = bd->block;                                      
        buf->length = dd->block_size;                                 
        buf->buffer = bd->buffer;                                     
4000e110:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
      {                                                               
        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;                                      
4000e114:	b6 10 00 04 	mov  %g4, %i3                                  
        buf->length = dd->block_size;                                 
        buf->buffer = bd->buffer;                                     
4000e118:	c2 26 a0 0c 	st  %g1, [ %i2 + 0xc ]                         
      {                                                               
        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;                                      
4000e11c:	c8 26 a0 04 	st  %g4, [ %i2 + 4 ]                           
        buf->length = dd->block_size;                                 
4000e120:	c6 26 a0 08 	st  %g3, [ %i2 + 8 ]                           
    transfer->write_req.bufnum = 0;                                   
                                                                      
    while ((node = rtems_chain_get_unprotected(&transfer->bds)) != NULL)
    {                                                                 
      rtems_bdbuf_buffer* bd = (rtems_bdbuf_buffer*) node;            
      bool                write = false;                              
4000e124:	82 10 20 00 	clr  %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) ||                    
4000e128:	c4 06 00 00 	ld  [ %i0 ], %g2                               
4000e12c:	80 a0 80 1c 	cmp  %g2, %i4                                  
4000e130:	02 80 00 0a 	be  4000e158 <rtems_bdbuf_swapout_write+0x104> 
4000e134:	84 14 e2 d8 	or  %l3, 0x2d8, %g2                            
4000e138:	c6 06 20 24 	ld  [ %i0 + 0x24 ], %g3                        
4000e13c:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
4000e140:	80 a0 c0 02 	cmp  %g3, %g2                                  
4000e144:	1a 80 00 06 	bcc  4000e15c <rtems_bdbuf_swapout_write+0x108>
4000e148:	90 10 00 1d 	mov  %i5, %o0                                  
          (transfer->write_req.bufnum >= bdbuf_config.max_write_blocks))
        write = true;                                                 
                                                                      
      if (write)                                                      
4000e14c:	80 88 60 ff 	btst  0xff, %g1                                
4000e150:	22 bf ff d3 	be,a   4000e09c <rtems_bdbuf_swapout_write+0x48>
4000e154:	c2 06 00 00 	ld  [ %i0 ], %g1                               
      {                                                               
        rtems_bdbuf_execute_transfer_request (dd, &transfer->write_req, false);
4000e158:	90 10 00 1d 	mov  %i5, %o0                                  
4000e15c:	92 10 00 11 	mov  %l1, %o1                                  
4000e160:	7f ff ff 1b 	call  4000ddcc <rtems_bdbuf_execute_transfer_request>
4000e164:	94 10 20 00 	clr  %o2                                       
                                                                      
        transfer->write_req.status = RTEMS_RESOURCE_IN_USE;           
4000e168:	e4 26 20 20 	st  %l2, [ %i0 + 0x20 ]                        
        transfer->write_req.bufnum = 0;                               
4000e16c:	10 bf ff cb 	b  4000e098 <rtems_bdbuf_swapout_write+0x44>   
4000e170:	c0 26 20 24 	clr  [ %i0 + 0x24 ]                            
                                                                      
    /*                                                                
     * If sync'ing and the deivce is capability of handling a sync IO control
     * call perform the call.                                         
     */                                                               
    if (transfer->syncing &&                                          
4000e174:	c2 0e 20 10 	ldub  [ %i0 + 0x10 ], %g1                      
4000e178:	80 a0 60 00 	cmp  %g1, 0                                    
4000e17c:	02 80 00 0c 	be  4000e1ac <rtems_bdbuf_swapout_write+0x158> 
4000e180:	01 00 00 00 	nop                                            
        (dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_SYNC))         
4000e184:	d0 07 60 08 	ld  [ %i5 + 8 ], %o0                           
4000e188:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
                                                                      
    /*                                                                
     * If sync'ing and the deivce is capability of handling a sync IO control
     * call perform the call.                                         
     */                                                               
    if (transfer->syncing &&                                          
4000e18c:	80 88 60 02 	btst  2, %g1                                   
4000e190:	02 80 00 05 	be  4000e1a4 <rtems_bdbuf_swapout_write+0x150> <== ALWAYS TAKEN
4000e194:	92 10 20 02 	mov  2, %o1                                    
        (dd->phys_dev->capabilities & RTEMS_BLKDEV_CAP_SYNC))         
    {                                                                 
      /* int result = */ dd->ioctl (dd->phys_dev, RTEMS_BLKDEV_REQ_SYNC, NULL);
4000e198:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        <== NOT EXECUTED
4000e19c:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
4000e1a0:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4000e1a4:	81 c7 e0 08 	ret                                            
4000e1a8:	81 e8 00 00 	restore                                        
4000e1ac:	81 c7 e0 08 	ret                                            
4000e1b0:	81 e8 00 00 	restore                                        
                                                                      

40005574 <rtems_bdbuf_sync>: rtems_status_code rtems_bdbuf_sync (rtems_bdbuf_buffer *bd) {
40005574:	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 (bd == NULL)                                                     
40005578:	80 a6 20 00 	cmp  %i0, 0                                    
4000557c:	02 80 00 49 	be  400056a0 <rtems_bdbuf_sync+0x12c>          <== NEVER TAKEN
40005580:	01 00 00 00 	nop                                            
  if (rtems_bdbuf_tracer)                                             
  {                                                                   
    printf ("bdbuf:%s: %" PRIu32 "\n", kind, bd->block);              
    rtems_bdbuf_show_users (kind, bd);                                
  }                                                                   
  rtems_bdbuf_lock_cache();                                           
40005584:	7f ff fb 5a 	call  400042ec <rtems_bdbuf_lock_cache>        
40005588:	01 00 00 00 	nop                                            
                                                                      
  sc = rtems_bdbuf_check_bd_and_lock_cache (bd, "sync");              
  if (sc != RTEMS_SUCCESSFUL)                                         
    return sc;                                                        
                                                                      
  switch (bd->state)                                                  
4000558c:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
40005590:	80 a2 20 03 	cmp  %o0, 3                                    
40005594:	0a 80 00 3c 	bcs  40005684 <rtems_bdbuf_sync+0x110>         <== NEVER TAKEN
40005598:	80 a2 20 05 	cmp  %o0, 5                                    
4000559c:	08 80 00 07 	bleu  400055b8 <rtems_bdbuf_sync+0x44>         
400055a0:	80 a2 20 06 	cmp  %o0, 6                                    
400055a4:	12 80 00 39 	bne  40005688 <rtems_bdbuf_sync+0x114>         <== NEVER TAKEN
400055a8:	92 10 20 0e 	mov  0xe, %o1                                  
    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);                   
400055ac:	7f ff fd 8a 	call  40004bd4 <rtems_bdbuf_discard_buffer_after_access>
400055b0:	90 10 00 18 	mov  %i0, %o0                                  
      break;                                                          
400055b4:	30 80 00 37 	b,a   40005690 <rtems_bdbuf_sync+0x11c>        
}                                                                     
                                                                      
static void                                                           
rtems_bdbuf_set_state (rtems_bdbuf_buffer *bd, rtems_bdbuf_buf_state state)
{                                                                     
  bd->state = state;                                                  
400055b8:	82 10 20 08 	mov  8, %g1                                    
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
400055bc:	11 10 00 6e 	sethi  %hi(0x4001b800), %o0                    
400055c0:	c2 26 20 20 	st  %g1, [ %i0 + 0x20 ]                        
400055c4:	90 12 22 d0 	or  %o0, 0x2d0, %o0                            
400055c8:	c2 02 20 60 	ld  [ %o0 + 0x60 ], %g1                        
                                                                      
  the_node->next = tail;                                              
400055cc:	84 02 20 5c 	add  %o0, 0x5c, %g2                            
400055d0:	c4 26 00 00 	st  %g2, [ %i0 ]                               
  tail->previous = the_node;                                          
400055d4:	f0 22 20 60 	st  %i0, [ %o0 + 0x60 ]                        
  old_last->next = the_node;                                          
400055d8:	f0 20 40 00 	st  %i0, [ %g1 ]                               
  the_node->previous = old_last;                                      
400055dc:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
{                                                                     
  rtems_bdbuf_set_state (bd, RTEMS_BDBUF_STATE_SYNC);                 
                                                                      
  rtems_chain_append_unprotected (&bdbuf_cache.sync, &bd->link);      
                                                                      
  if (bd->waiters)                                                    
400055e0:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
400055e4:	80 a0 60 00 	cmp  %g1, 0                                    
400055e8:	02 80 00 04 	be  400055f8 <rtems_bdbuf_sync+0x84>           
400055ec:	01 00 00 00 	nop                                            
    rtems_bdbuf_wake (&bdbuf_cache.access_waiters);                   
400055f0:	7f ff f7 b2 	call  400034b8 <rtems_bdbuf_wake>              
400055f4:	90 02 20 64 	add  %o0, 0x64, %o0                            
                                                                      
  rtems_bdbuf_wake_swapper ();                                        
400055f8:	7f ff f7 4f 	call  40003334 <rtems_bdbuf_wake_swapper>      
400055fc:	3b 10 00 6e 	sethi  %hi(0x4001b800), %i5                    
      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);         
40005600:	ba 17 63 3c 	or  %i5, 0x33c, %i5	! 4001bb3c <bdbuf_cache+0x6c>
static void                                                           
rtems_bdbuf_wait_for_sync_done (rtems_bdbuf_buffer *bd)               
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
40005604:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
40005608:	80 a2 20 01 	cmp  %o0, 1                                    
4000560c:	0a 80 00 0b 	bcs  40005638 <rtems_bdbuf_sync+0xc4>          <== NEVER TAKEN
40005610:	80 a2 20 07 	cmp  %o0, 7                                    
40005614:	08 80 00 0b 	bleu  40005640 <rtems_bdbuf_sync+0xcc>         
40005618:	80 a2 20 0a 	cmp  %o0, 0xa                                  
4000561c:	18 80 00 1b 	bgu  40005688 <rtems_bdbuf_sync+0x114>         <== NEVER TAKEN
40005620:	92 10 20 12 	mov  0x12, %o1                                 
      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);         
40005624:	90 10 00 18 	mov  %i0, %o0                                  
40005628:	7f ff f7 60 	call  400033a8 <rtems_bdbuf_wait>              
4000562c:	92 10 00 1d 	mov  %i5, %o1                                  
static void                                                           
rtems_bdbuf_wait_for_sync_done (rtems_bdbuf_buffer *bd)               
{                                                                     
  while (true)                                                        
  {                                                                   
    switch (bd->state)                                                
40005630:	10 bf ff f6 	b  40005608 <rtems_bdbuf_sync+0x94>            
40005634:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
      case RTEMS_BDBUF_STATE_TRANSFER:                                
      case RTEMS_BDBUF_STATE_TRANSFER_PURGED:                         
        rtems_bdbuf_wait (bd, &bdbuf_cache.transfer_waiters);         
        break;                                                        
      default:                                                        
        rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_9);
40005638:	10 80 00 14 	b  40005688 <rtems_bdbuf_sync+0x114>           <== NOT EXECUTED
4000563c:	92 10 20 12 	mov  0x12, %o1                                 <== NOT EXECUTED
  rtems_bdbuf_wait_for_sync_done (bd);                                
                                                                      
  /*                                                                  
   * We may have created a cached or empty buffer which may be recycled.
   */                                                                 
  if (bd->waiters == 0                                                
40005640:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
40005644:	80 a0 60 00 	cmp  %g1, 0                                    
40005648:	12 80 00 12 	bne  40005690 <rtems_bdbuf_sync+0x11c>         
4000564c:	82 02 3f ff 	add  %o0, -1, %g1                              
        && (bd->state == RTEMS_BDBUF_STATE_CACHED                     
40005650:	80 a0 60 01 	cmp  %g1, 1                                    
40005654:	18 80 00 0f 	bgu  40005690 <rtems_bdbuf_sync+0x11c>         <== NEVER TAKEN
40005658:	80 a2 20 01 	cmp  %o0, 1                                    
          || bd->state == RTEMS_BDBUF_STATE_EMPTY))                   
  {                                                                   
    if (bd->state == RTEMS_BDBUF_STATE_EMPTY)                         
4000565c:	32 80 00 07 	bne,a   40005678 <rtems_bdbuf_sync+0x104>      
40005660:	11 10 00 6e 	sethi  %hi(0x4001b800), %o0                    
    {                                                                 
      rtems_bdbuf_remove_from_tree (bd);                              
40005664:	7f ff f7 cb 	call  40003590 <rtems_bdbuf_remove_from_tree>  
40005668:	90 10 00 18 	mov  %i0, %o0                                  
      rtems_bdbuf_make_free_and_add_to_lru_list (bd);                 
4000566c:	7f ff f6 f8 	call  4000324c <rtems_bdbuf_make_free_and_add_to_lru_list>
40005670:	90 10 00 18 	mov  %i0, %o0                                  
    }                                                                 
    rtems_bdbuf_wake (&bdbuf_cache.buffer_waiters);                   
40005674:	11 10 00 6e 	sethi  %hi(0x4001b800), %o0                    
40005678:	7f ff f7 90 	call  400034b8 <rtems_bdbuf_wake>              
4000567c:	90 12 23 44 	or  %o0, 0x344, %o0	! 4001bb44 <bdbuf_cache+0x74>
40005680:	30 80 00 04 	b,a   40005690 <rtems_bdbuf_sync+0x11c>        
      break;                                                          
    case RTEMS_BDBUF_STATE_ACCESS_PURGED:                             
      rtems_bdbuf_discard_buffer_after_access (bd);                   
      break;                                                          
    default:                                                          
      rtems_bdbuf_fatal_with_state (bd->state, RTEMS_BDBUF_FATAL_STATE_5);
40005684:	92 10 20 0e 	mov  0xe, %o1                                  <== NOT EXECUTED
40005688:	7f ff f7 10 	call  400032c8 <rtems_bdbuf_fatal_with_state>  <== NOT EXECUTED
4000568c:	01 00 00 00 	nop                                            <== NOT EXECUTED
  }                                                                   
                                                                      
  if (rtems_bdbuf_tracer)                                             
    rtems_bdbuf_show_usage ();                                        
                                                                      
  rtems_bdbuf_unlock_cache ();                                        
40005690:	7f ff fb 22 	call  40004318 <rtems_bdbuf_unlock_cache>      
40005694:	b0 10 20 00 	clr  %i0	! 0 <_TLS_BSS_size>                   
                                                                      
  return RTEMS_SUCCESSFUL;                                            
40005698:	81 c7 e0 08 	ret                                            
4000569c:	81 e8 00 00 	restore                                        
}                                                                     
400056a0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400056a4:	91 e8 20 09 	restore  %g0, 9, %o0                           <== NOT EXECUTED
                                                                      

4000d928 <rtems_bdbuf_transfer_done>: * @param status I/O completion status */ static void rtems_bdbuf_transfer_done (rtems_blkdev_request* req, rtems_status_code status) { req->status = status;
4000d928:	d2 22 20 0c 	st  %o1, [ %o0 + 0xc ]                         
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_status_code rtems_event_transient_send(    
  rtems_id id                                                         
)                                                                     
{                                                                     
  return rtems_event_system_send( id, RTEMS_EVENT_SYSTEM_TRANSIENT ); 
4000d92c:	d0 02 20 14 	ld  [ %o0 + 0x14 ], %o0                        
4000d930:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
4000d934:	82 13 c0 00 	mov  %o7, %g1                                  
4000d938:	7f ff ec fd 	call  40008d2c <rtems_event_system_send>       
4000d93c:	9e 10 40 00 	mov  %g1, %o7                                  
4000d940:	40 00 db 64 	call  400446d0 <__end+0x27040>                 <== NOT EXECUTED
4000d944:	40 00 db 44 	call  40044654 <__end+0x26fc4>                 <== NOT EXECUTED
4000d948:	40 00 da c0 	call  40044448 <__end+0x26db8>                 <== NOT EXECUTED
4000d94c:	40 00 da c0 	call  4004444c <__end+0x26dbc>                 <== NOT EXECUTED
4000d950:	40 00 da c0 	call  40044450 <__end+0x26dc0>                 <== NOT EXECUTED
4000d954:	40 00 da c0 	call  40044454 <__end+0x26dc4>                 <== NOT EXECUTED
4000d958:	40 00 db 34 	call  40044628 <__end+0x26f98>                 <== NOT EXECUTED
4000d95c:	40 00 db 58 	call  400446bc <__end+0x2702c>                 <== NOT EXECUTED
4000d960:	40 00 db 58 	call  400446c0 <__end+0x27030>                 <== NOT EXECUTED
4000d964:	40 00 db 58 	call  400446c4 <__end+0x27034>                 <== NOT EXECUTED
4000d968:	40 00 da f0 	call  40044528 <__end+0x26e98>                 <== NOT EXECUTED
4000d96c:	40 00 da 44 	call  4004427c <__end+0x26bec>                 <== NOT EXECUTED
4000d970:	40 00 da 44 	call  40044280 <__end+0x26bf0>                 <== NOT EXECUTED
4000d974:	40 00 da 64 	call  40044304 <__end+0x26c74>                 <== NOT EXECUTED
4000d978:	40 00 da 64 	call  40044308 <__end+0x26c78>                 <== NOT EXECUTED
4000d97c:	40 00 da 64 	call  4004430c <__end+0x26c7c>                 <== NOT EXECUTED
4000d980:	40 00 da 64 	call  40044310 <__end+0x26c80>                 <== NOT EXECUTED
4000d984:	40 00 da 10 	call  400441c4 <__end+0x26b34>                 <== NOT EXECUTED
4000d988:	40 00 da 70 	call  40044348 <__end+0x26cb8>                 <== NOT EXECUTED
4000d98c:	40 00 da 70 	call  4004434c <__end+0x26cbc>                 <== NOT EXECUTED
4000d990:	40 00 da 70 	call  40044350 <__end+0x26cc0>                 <== NOT EXECUTED
                                                                      

4000dda0 <rtems_bdbuf_unlock_cache>: /** * Unlock the cache. */ static void rtems_bdbuf_unlock_cache (void) {
4000dda0:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
static void                                                           
rtems_bdbuf_unlock (rtems_bdbuf_lock_type *lock, uint32_t fatal_error_code)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_mutex_unlock (lock);                              
4000dda4:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
4000dda8:	40 00 0c c8 	call  400110c8 <pthread_mutex_unlock>          
4000ddac:	90 12 20 04 	or  %o0, 4, %o0	! 4001c404 <bdbuf_cache+0x28>  
  if (eno != 0)                                                       
4000ddb0:	80 a2 20 00 	cmp  %o0, 0                                    
4000ddb4:	02 80 00 04 	be  4000ddc4 <rtems_bdbuf_unlock_cache+0x24>   <== ALWAYS TAKEN
4000ddb8:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (fatal_error_code);                             
4000ddbc:	7f ff fb cf 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000ddc0:	90 10 20 01 	mov  1, %o0	! 1 <_TLS_Alignment>               <== NOT EXECUTED
4000ddc4:	81 c7 e0 08 	ret                                            
4000ddc8:	81 e8 00 00 	restore                                        
                                                                      

4000cd90 <rtems_bdbuf_unlock_sync>: /** * Unlock the cache's sync lock. Any blocked writers are woken. */ static void rtems_bdbuf_unlock_sync (void) {
4000cd90:	9d e3 bf a0 	save  %sp, -96, %sp                            
 */                                                                   
static void                                                           
rtems_bdbuf_unlock (rtems_bdbuf_lock_type *lock, uint32_t fatal_error_code)
{                                                                     
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
  int eno = pthread_mutex_unlock (lock);                              
4000cd94:	11 10 00 71 	sethi  %hi(0x4001c400), %o0                    
4000cd98:	40 00 10 cc 	call  400110c8 <pthread_mutex_unlock>          
4000cd9c:	90 12 20 08 	or  %o0, 8, %o0	! 4001c408 <bdbuf_cache+0x2c>  
  if (eno != 0)                                                       
4000cda0:	80 a2 20 00 	cmp  %o0, 0                                    
4000cda4:	02 80 00 04 	be  4000cdb4 <rtems_bdbuf_unlock_sync+0x24>    <== ALWAYS TAKEN
4000cda8:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (fatal_error_code);                             
4000cdac:	7f ff ff d3 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cdb0:	90 10 20 17 	mov  0x17, %o0	! 17 <_TLS_Alignment+0x16>      <== NOT EXECUTED
4000cdb4:	81 c7 e0 08 	ret                                            
4000cdb8:	81 e8 00 00 	restore                                        
                                                                      

4000cd0c <rtems_bdbuf_wait_for_event>: return bdbuf_cache.init_status; } static void rtems_bdbuf_wait_for_event (rtems_event_set event) {
4000cd0c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_event_set   out = 0;                                          
                                                                      
  sc = rtems_event_receive (event,                                    
4000cd10:	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;                                          
4000cd14:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
  sc = rtems_event_receive (event,                                    
4000cd18:	90 10 00 18 	mov  %i0, %o0                                  
4000cd1c:	94 10 20 00 	clr  %o2                                       
4000cd20:	7f ff ed ff 	call  4000851c <rtems_event_receive>           
4000cd24:	96 07 bf fc 	add  %fp, -4, %o3                              
                            RTEMS_EVENT_ALL | RTEMS_WAIT,             
                            RTEMS_NO_TIMEOUT,                         
                            &out);                                    
                                                                      
  if (sc != RTEMS_SUCCESSFUL || out != event)                         
4000cd28:	80 a2 20 00 	cmp  %o0, 0                                    
4000cd2c:	12 80 00 05 	bne  4000cd40 <rtems_bdbuf_wait_for_event+0x34><== NEVER TAKEN
4000cd30:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000cd34:	80 a0 40 18 	cmp  %g1, %i0                                  
4000cd38:	02 80 00 04 	be  4000cd48 <rtems_bdbuf_wait_for_event+0x3c> <== ALWAYS TAKEN
4000cd3c:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_WAIT_EVNT);                  
4000cd40:	7f ff ff ee 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cd44:	90 10 20 19 	mov  0x19, %o0	! 19 <_TLS_Alignment+0x18>      <== NOT EXECUTED
4000cd48:	81 c7 e0 08 	ret                                            
4000cd4c:	81 e8 00 00 	restore                                        
                                                                      

4000d370 <rtems_bdbuf_wait_for_transient_event>: rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_WAIT_EVNT); } static void rtems_bdbuf_wait_for_transient_event (void) {
4000d370:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_interval ticks                                                
)                                                                     
{                                                                     
  rtems_event_set event_out;                                          
                                                                      
  return rtems_event_system_receive(                                  
4000d374:	11 20 00 00 	sethi  %hi(0x80000000), %o0                    
4000d378:	92 10 20 00 	clr  %o1                                       
4000d37c:	94 10 20 00 	clr  %o2                                       
4000d380:	40 00 11 4c 	call  400118b0 <rtems_event_system_receive>    
4000d384:	96 07 bf fc 	add  %fp, -4, %o3                              
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  sc = rtems_event_transient_receive (RTEMS_WAIT, RTEMS_NO_TIMEOUT);  
  if (sc != RTEMS_SUCCESSFUL)                                         
4000d388:	80 a2 20 00 	cmp  %o0, 0                                    
4000d38c:	02 80 00 04 	be  4000d39c <rtems_bdbuf_wait_for_transient_event+0x2c><== ALWAYS TAKEN
4000d390:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_WAIT_TRANS_EVNT);            
4000d394:	7f ff fe 59 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000d398:	90 10 20 1a 	mov  0x1a, %o0	! 1a <_TLS_Alignment+0x19>      <== NOT EXECUTED
4000d39c:	81 c7 e0 08 	ret                                            
4000d3a0:	81 e8 00 00 	restore                                        
                                                                      

4000cf40 <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 (rtems_bdbuf_waiters *waiters) {
4000cf40:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (waiters->count > 0)                                             
4000cf44:	c2 06 00 00 	ld  [ %i0 ], %g1                               
4000cf48:	80 a0 60 00 	cmp  %g1, 0                                    
4000cf4c:	02 80 00 09 	be  4000cf70 <rtems_bdbuf_wake+0x30>           
4000cf50:	01 00 00 00 	nop                                            
  {                                                                   
#if defined(RTEMS_BDBUF_USE_PTHREAD)                                  
    int eno = pthread_cond_broadcast (&waiters->cond_var);            
4000cf54:	40 00 0d f8 	call  40010734 <pthread_cond_broadcast>        
4000cf58:	90 06 20 04 	add  %i0, 4, %o0                               
    if (eno != 0)                                                     
4000cf5c:	80 a2 20 00 	cmp  %o0, 0                                    
4000cf60:	02 80 00 04 	be  4000cf70 <rtems_bdbuf_wake+0x30>           <== ALWAYS TAKEN
4000cf64:	01 00 00 00 	nop                                            
      rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_CV_BROADCAST);             
4000cf68:	7f ff ff 64 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cf6c:	90 10 20 1f 	mov  0x1f, %o0	! 1f <_TLS_Alignment+0x1e>      <== NOT EXECUTED
4000cf70:	81 c7 e0 08 	ret                                            
4000cf74:	81 e8 00 00 	restore                                        
                                                                      

4000cdbc <rtems_bdbuf_wake_swapper>: } } static void rtems_bdbuf_wake_swapper (void) {
4000cdbc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = rtems_event_send (bdbuf_cache.swapout,       
4000cdc0:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
4000cdc4:	d0 00 63 dc 	ld  [ %g1 + 0x3dc ], %o0	! 4001c3dc <bdbuf_cache>
4000cdc8:	7f ff ee 35 	call  4000869c <rtems_event_send>              
4000cdcc:	92 10 20 04 	mov  4, %o1                                    
                                           RTEMS_BDBUF_SWAPOUT_SYNC); 
  if (sc != RTEMS_SUCCESSFUL)                                         
4000cdd0:	80 a2 20 00 	cmp  %o0, 0                                    
4000cdd4:	02 80 00 04 	be  4000cde4 <rtems_bdbuf_wake_swapper+0x28>   <== ALWAYS TAKEN
4000cdd8:	01 00 00 00 	nop                                            
    rtems_bdbuf_fatal (RTEMS_BDBUF_FATAL_SO_WAKE_1);                  
4000cddc:	7f ff ff c7 	call  4000ccf8 <rtems_bdbuf_fatal>             <== NOT EXECUTED
4000cde0:	90 10 20 09 	mov  9, %o0	! 9 <_TLS_Alignment+0x8>           <== NOT EXECUTED
4000cde4:	81 c7 e0 08 	ret                                            
4000cde8:	81 e8 00 00 	restore                                        
                                                                      

4000332c <rtems_bdpart_create>: const rtems_bdpart_format *format, rtems_bdpart_partition *pt, const unsigned *dist, size_t count ) {
4000332c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  bool dos_compatibility = format != NULL                             
    && format->type == RTEMS_BDPART_FORMAT_MBR                        
    && format->mbr.dos_compatibility;                                 
40003330:	80 a6 60 00 	cmp  %i1, 0                                    
40003334:	02 80 00 08 	be  40003354 <rtems_bdpart_create+0x28>        <== NEVER TAKEN
40003338:	90 10 00 18 	mov  %i0, %o0                                  
  size_t count                                                        
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  bool dos_compatibility = format != NULL                             
    && format->type == RTEMS_BDPART_FORMAT_MBR                        
4000333c:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40003340:	80 a0 60 00 	cmp  %g1, 0                                    
40003344:	12 80 00 05 	bne  40003358 <rtems_bdpart_create+0x2c>       <== NEVER TAKEN
40003348:	a2 10 20 00 	clr  %l1                                       
4000334c:	10 80 00 03 	b  40003358 <rtems_bdpart_create+0x2c>         
40003350:	e2 0e 60 08 	ldub  [ %i1 + 8 ], %l1                         
    && format->mbr.dos_compatibility;                                 
40003354:	a2 10 20 00 	clr  %l1                                       <== NOT EXECUTED
  rtems_blkdev_bnum disk_end = 0;                                     
  rtems_blkdev_bnum pos = 0;                                          
  rtems_blkdev_bnum dist_sum = 0;                                     
  rtems_blkdev_bnum record_space =                                    
40003358:	a2 0c 60 01 	and  %l1, 1, %l1                               
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  bool dos_compatibility = format != NULL                             
    && format->type == RTEMS_BDPART_FORMAT_MBR                        
    && format->mbr.dos_compatibility;                                 
  rtems_blkdev_bnum disk_end = 0;                                     
4000335c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
  rtems_blkdev_bnum pos = 0;                                          
  rtems_blkdev_bnum dist_sum = 0;                                     
  rtems_blkdev_bnum record_space =                                    
40003360:	80 a0 00 11 	cmp  %g0, %l1                                  
  size_t i = 0;                                                       
                                                                      
  /* Check if we have something to do */                              
  if (count == 0) {                                                   
    /* Nothing to do */                                               
    return RTEMS_SUCCESSFUL;                                          
40003364:	b0 10 20 00 	clr  %i0                                       
    && format->type == RTEMS_BDPART_FORMAT_MBR                        
    && format->mbr.dos_compatibility;                                 
  rtems_blkdev_bnum disk_end = 0;                                     
  rtems_blkdev_bnum pos = 0;                                          
  rtems_blkdev_bnum dist_sum = 0;                                     
  rtems_blkdev_bnum record_space =                                    
40003368:	ba 40 3f ff 	addx  %g0, -1, %i5                             
  rtems_blkdev_bnum overhead = 0;                                     
  rtems_blkdev_bnum free_space = 0;                                   
  size_t i = 0;                                                       
                                                                      
  /* Check if we have something to do */                              
  if (count == 0) {                                                   
4000336c:	80 a7 20 00 	cmp  %i4, 0                                    
    && format->type == RTEMS_BDPART_FORMAT_MBR                        
    && format->mbr.dos_compatibility;                                 
  rtems_blkdev_bnum disk_end = 0;                                     
  rtems_blkdev_bnum pos = 0;                                          
  rtems_blkdev_bnum dist_sum = 0;                                     
  rtems_blkdev_bnum record_space =                                    
40003370:	ba 0f 7f c2 	and  %i5, -62, %i5                             
  rtems_blkdev_bnum overhead = 0;                                     
  rtems_blkdev_bnum free_space = 0;                                   
  size_t i = 0;                                                       
                                                                      
  /* Check if we have something to do */                              
  if (count == 0) {                                                   
40003374:	02 80 00 11 	be  400033b8 <rtems_bdpart_create+0x8c>        <== NEVER TAKEN
40003378:	ba 07 60 3f 	add  %i5, 0x3f, %i5                            
    /* Nothing to do */                                               
    return RTEMS_SUCCESSFUL;                                          
  }                                                                   
                                                                      
  /* Check parameter */                                               
  if (format == NULL || pt == NULL || dist == NULL) {                 
4000337c:	80 a6 60 00 	cmp  %i1, 0                                    
40003380:	02 80 00 0e 	be  400033b8 <rtems_bdpart_create+0x8c>        <== NEVER TAKEN
40003384:	b0 10 20 09 	mov  9, %i0                                    
40003388:	80 a6 a0 00 	cmp  %i2, 0                                    
4000338c:	02 80 00 0b 	be  400033b8 <rtems_bdpart_create+0x8c>        <== NEVER TAKEN
40003390:	80 a6 e0 00 	cmp  %i3, 0                                    
40003394:	02 80 00 09 	be  400033b8 <rtems_bdpart_create+0x8c>        <== NEVER TAKEN
40003398:	92 10 20 00 	clr  %o1                                       
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  /* Get disk data */                                                 
  sc = rtems_bdpart_get_disk_data( disk_name, NULL, NULL, &disk_end); 
4000339c:	94 10 20 00 	clr  %o2                                       
400033a0:	40 00 01 25 	call  40003834 <rtems_bdpart_get_disk_data>    
400033a4:	96 07 bf fc 	add  %fp, -4, %o3                              
  if (sc != RTEMS_SUCCESSFUL) {                                       
400033a8:	82 10 20 00 	clr  %g1                                       
400033ac:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400033b0:	02 80 00 09 	be  400033d4 <rtems_bdpart_create+0xa8>        <== ALWAYS TAKEN
400033b4:	84 10 20 00 	clr  %g2                                       
400033b8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400033bc:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    if (dist_sum < prev_sum) {                                        
      return RTEMS_INVALID_NUMBER;                                    
    }                                                                 
                                                                      
    if (dist [i] == 0) {                                              
400033c0:	02 80 00 0b 	be  400033ec <rtems_bdpart_create+0xc0>        <== NEVER TAKEN
400033c4:	82 00 60 01 	inc  %g1                                       
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
                                                                      
  /* Get distribution sum and check for overflow */                   
  for (i = 0; i < count; ++i) {                                       
400033c8:	80 a0 40 1c 	cmp  %g1, %i4                                  
400033cc:	02 80 00 0a 	be  400033f4 <rtems_bdpart_create+0xc8>        
400033d0:	84 10 00 13 	mov  %l3, %g2                                  
400033d4:	87 28 60 02 	sll  %g1, 2, %g3                               
    unsigned prev_sum = dist_sum;                                     
                                                                      
    dist_sum += dist [i];                                             
400033d8:	c6 06 c0 03 	ld  [ %i3 + %g3 ], %g3                         
400033dc:	a6 00 c0 02 	add  %g3, %g2, %l3                             
                                                                      
    if (dist_sum < prev_sum) {                                        
400033e0:	80 a4 c0 02 	cmp  %l3, %g2                                  
400033e4:	1a bf ff f7 	bcc  400033c0 <rtems_bdpart_create+0x94>       <== ALWAYS TAKEN
400033e8:	80 a0 e0 00 	cmp  %g3, 0                                    
      return RTEMS_INVALID_NUMBER;                                    
400033ec:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400033f0:	91 e8 20 0a 	restore  %g0, 0xa, %o0                         <== NOT EXECUTED
      return RTEMS_INVALID_NUMBER;                                    
    }                                                                 
  }                                                                   
                                                                      
  /* Check format */                                                  
  if (format->type != RTEMS_BDPART_FORMAT_MBR) {                      
400033f4:	c2 06 40 00 	ld  [ %i1 ], %g1                               
400033f8:	80 a0 60 00 	cmp  %g1, 0                                    
400033fc:	12 bf ff ef 	bne  400033b8 <rtems_bdpart_create+0x8c>       <== NEVER TAKEN
40003400:	b0 10 20 18 	mov  0x18, %i0                                 
    return RTEMS_NOT_IMPLEMENTED;                                     
  }                                                                   
                                                                      
  /* Align end of disk on cylinder boundary if necessary */           
  if (dos_compatibility) {                                            
40003404:	80 a4 60 00 	cmp  %l1, 0                                    
40003408:	02 80 00 09 	be  4000342c <rtems_bdpart_create+0x100>       <== NEVER TAKEN
4000340c:	80 a7 20 04 	cmp  %i4, 4                                    
    disk_end -= (disk_end % record_space);                            
40003410:	f2 07 bf fc 	ld  [ %fp + -4 ], %i1                          
40003414:	92 10 00 1d 	mov  %i5, %o1                                  
40003418:	40 00 7e 7d 	call  40022e0c <.urem>                         
4000341c:	90 10 00 19 	mov  %i1, %o0                                  
40003420:	90 26 40 08 	sub  %i1, %o0, %o0                             
40003424:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          
                                                                      
  /*                                                                  
   * In case we need an extended partition and logical partitions we have to
   * account for the space of each EBR.                               
   */                                                                 
  if (count > 4) {                                                    
40003428:	80 a7 20 04 	cmp  %i4, 4                                    
4000342c:	08 80 00 06 	bleu  40003444 <rtems_bdpart_create+0x118>     <== NEVER TAKEN
40003430:	a0 10 00 1d 	mov  %i5, %l0                                  
    overhead += (count - 3) * record_space;                           
40003434:	90 10 00 1d 	mov  %i5, %o0                                  
40003438:	40 00 7d 8f 	call  40022a74 <.umul>                         
4000343c:	92 07 3f fd 	add  %i4, -3, %o1                              
40003440:	a0 02 00 1d 	add  %o0, %i5, %l0                             
                                                                      
  /*                                                                  
   * Account space to align every partition on cylinder boundaries if 
   * necessary.                                                       
   */                                                                 
  if (dos_compatibility) {                                            
40003444:	80 a4 60 00 	cmp  %l1, 0                                    
40003448:	02 80 00 07 	be  40003464 <rtems_bdpart_create+0x138>       <== NEVER TAKEN
4000344c:	e8 07 bf fc 	ld  [ %fp + -4 ], %l4                          
    overhead += (count - 1) * record_space;                           
40003450:	90 10 00 1d 	mov  %i5, %o0                                  
40003454:	40 00 7d 88 	call  40022a74 <.umul>                         
40003458:	92 07 3f ff 	add  %i4, -1, %o1                              
4000345c:	a0 04 00 08 	add  %l0, %o0, %l0                             
  }                                                                   
                                                                      
  /* Check disk space */                                              
  if ((overhead + count) > disk_end) {                                
40003460:	e8 07 bf fc 	ld  [ %fp + -4 ], %l4                          
40003464:	82 04 00 1c 	add  %l0, %i4, %g1                             
40003468:	80 a0 40 14 	cmp  %g1, %l4                                  
4000346c:	18 bf ff d3 	bgu  400033b8 <rtems_bdpart_create+0x8c>       <== NEVER TAKEN
40003470:	b0 10 20 1b 	mov  0x1b, %i0                                 
                                                                      
  /* Begin of first primary partition */                              
  pos = record_space;                                                 
                                                                      
  /* Space for partitions */                                          
  free_space = disk_end - overhead;                                   
40003474:	a0 25 00 10 	sub  %l4, %l0, %l0                             
40003478:	a2 10 00 1a 	mov  %i2, %l1                                  
  if ((overhead + count) > disk_end) {                                
    return RTEMS_IO_ERROR;                                            
  }                                                                   
                                                                      
  /* Begin of first primary partition */                              
  pos = record_space;                                                 
4000347c:	b0 10 00 1d 	mov  %i5, %i0                                  
                                                                      
  /* Space for partitions */                                          
  free_space = disk_end - overhead;                                   
                                                                      
  for (i = 0; i < count; ++i) {                                       
40003480:	b2 10 20 00 	clr  %i1                                       
40003484:	83 2e 60 02 	sll  %i1, 2, %g1                               
    rtems_bdpart_partition *p = pt + i;                               
                                                                      
    /* Partition size */                                              
    rtems_blkdev_bnum s = free_space * dist [i];                      
40003488:	e4 06 c0 01 	ld  [ %i3 + %g1 ], %l2                         
4000348c:	92 10 00 10 	mov  %l0, %o1                                  
40003490:	40 00 7d 79 	call  40022a74 <.umul>                         
40003494:	90 10 00 12 	mov  %l2, %o0                                  
    if (s < free_space || s < dist [i]) {                             
40003498:	80 a2 00 10 	cmp  %o0, %l0                                  
4000349c:	0a bf ff d4 	bcs  400033ec <rtems_bdpart_create+0xc0>       <== NEVER TAKEN
400034a0:	80 a2 00 12 	cmp  %o0, %l2                                  
400034a4:	0a bf ff d2 	bcs  400033ec <rtems_bdpart_create+0xc0>       <== NEVER TAKEN
400034a8:	01 00 00 00 	nop                                            
      /* TODO: Calculate without overflow */                          
      return RTEMS_INVALID_NUMBER;                                    
    }                                                                 
    s /= dist_sum;                                                    
400034ac:	40 00 7d ac 	call  40022b5c <.udiv>                         
400034b0:	92 10 00 13 	mov  %l3, %o1                                  
                                                                      
    /* Ensure that the partition is not empty */                      
    if (s == 0) {                                                     
400034b4:	a4 92 20 00 	orcc  %o0, 0, %l2                              
400034b8:	22 80 00 02 	be,a   400034c0 <rtems_bdpart_create+0x194>    <== NEVER TAKEN
400034bc:	a4 10 20 01 	mov  1, %l2                                    <== NOT EXECUTED
      s = 1;                                                          
    }                                                                 
                                                                      
    /* Align partition upwards */                                     
    s += record_space - (s % record_space);                           
400034c0:	90 10 00 12 	mov  %l2, %o0                                  
400034c4:	40 00 7e 52 	call  40022e0c <.urem>                         
400034c8:	92 10 00 1d 	mov  %i5, %o1                                  
400034cc:	a4 04 80 1d 	add  %l2, %i5, %l2                             
                                                                      
    /* Reserve space for the EBR if necessary */                      
    if (count > 4 && i > 2) {                                         
400034d0:	82 10 20 01 	mov  1, %g1                                    
400034d4:	80 a6 60 02 	cmp  %i1, 2                                    
400034d8:	18 80 00 03 	bgu  400034e4 <rtems_bdpart_create+0x1b8>      
400034dc:	90 24 80 08 	sub  %l2, %o0, %o0                             
400034e0:	82 10 20 00 	clr  %g1                                       
400034e4:	80 88 60 ff 	btst  0xff, %g1                                
400034e8:	22 80 00 0a 	be,a   40003510 <rtems_bdpart_create+0x1e4>    
400034ec:	f0 24 40 00 	st  %i0, [ %l1 ]                               
400034f0:	80 a7 20 04 	cmp  %i4, 4                                    
400034f4:	18 80 00 03 	bgu  40003500 <rtems_bdpart_create+0x1d4>      <== ALWAYS TAKEN
400034f8:	82 10 20 01 	mov  1, %g1                                    
400034fc:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
40003500:	80 88 60 ff 	btst  0xff, %g1                                
40003504:	32 80 00 02 	bne,a   4000350c <rtems_bdpart_create+0x1e0>   <== ALWAYS TAKEN
40003508:	b0 06 00 1d 	add  %i0, %i5, %i0                             
      pos += record_space;                                            
    }                                                                 
                                                                      
    /* Partition begin and end */                                     
    p->begin = pos;                                                   
4000350c:	f0 24 40 00 	st  %i0, [ %l1 ]                               
    pos += s;                                                         
40003510:	b0 06 00 08 	add  %i0, %o0, %i0                             
    p->end = pos;                                                     
40003514:	f0 24 60 04 	st  %i0, [ %l1 + 4 ]                           
  pos = record_space;                                                 
                                                                      
  /* Space for partitions */                                          
  free_space = disk_end - overhead;                                   
                                                                      
  for (i = 0; i < count; ++i) {                                       
40003518:	b2 06 60 01 	inc  %i1                                       
4000351c:	80 a6 40 1c 	cmp  %i1, %i4                                  
40003520:	12 bf ff d9 	bne  40003484 <rtems_bdpart_create+0x158>      
40003524:	a2 04 60 30 	add  %l1, 0x30, %l1                            
    pos += s;                                                         
    p->end = pos;                                                     
  }                                                                   
                                                                      
  /* Expand the last partition to the disk end */                     
  pt [count - 1].end = disk_end;                                      
40003528:	83 2e 60 04 	sll  %i1, 4, %g1                               
4000352c:	b3 2e 60 06 	sll  %i1, 6, %i1                               
40003530:	b2 26 40 01 	sub  %i1, %g1, %i1                             
40003534:	b4 06 80 19 	add  %i2, %i1, %i2                             
40003538:	e8 26 bf d4 	st  %l4, [ %i2 + -44 ]                         
4000353c:	b0 10 20 00 	clr  %i0                                       
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003540:	81 c7 e0 08 	ret                                            
40003544:	81 e8 00 00 	restore                                        
                                                                      

40003548 <rtems_bdpart_dump>: { uuid_unparse_lower( type, str); } void rtems_bdpart_dump( const rtems_bdpart_partition *pt, size_t count) {
40003548:	9d e3 bf 60 	save  %sp, -160, %sp                           
  size_t i = 0;                                                       
                                                                      
  printf(                                                             
4000354c:	11 10 00 98 	sethi  %hi(0x40026000), %o0                    
          break;                                                      
        case RTEMS_BDPART_MBR_DATA:                                   
          type = "DATA";                                              
          break;                                                      
        default:                                                      
          snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
40003550:	37 10 00 98 	sethi  %hi(0x40026000), %i3                    
                                                                      
void rtems_bdpart_dump( const rtems_bdpart_partition *pt, size_t count)
{                                                                     
  size_t i = 0;                                                       
                                                                      
  printf(                                                             
40003554:	90 12 20 c0 	or  %o0, 0xc0, %o0                             
40003558:	40 00 4c 08 	call  40016578 <puts>                          
4000355c:	25 10 00 98 	sethi  %hi(0x40026000), %l2                    
40003560:	b0 06 20 08 	add  %i0, 8, %i0                               
    "------------+------------+-----------------------------------------------------\n"
    " BEGIN      | LAST       | TYPE\n"                               
    "------------+------------+-----------------------------------------------------\n"
  );                                                                  
                                                                      
  for (i = 0; i < count; ++i) {                                       
40003564:	ba 10 20 00 	clr  %i5                                       
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_16_LBA:                             
          type = "FAT 16 LBA";                                        
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_32:                                 
          type = "FAT 32";                                            
40003568:	39 10 00 98 	sethi  %hi(0x40026000), %i4                    
          break;                                                      
        case RTEMS_BDPART_MBR_DATA:                                   
          type = "DATA";                                              
          break;                                                      
        default:                                                      
          snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
4000356c:	b6 16 e2 00 	or  %i3, 0x200, %i3                            
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_16:                                 
          type = "FAT 16";                                            
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_16_LBA:                             
          type = "FAT 16 LBA";                                        
40003570:	35 10 00 98 	sethi  %hi(0x40026000), %i2                    
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_32_LBA:                             
          type = "FAT 32 LBA";                                        
          break;                                                      
        case RTEMS_BDPART_MBR_DATA:                                   
          type = "DATA";                                              
40003574:	21 10 00 98 	sethi  %hi(0x40026000), %l0                    
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_32:                                 
          type = "FAT 32";                                            
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_32_LBA:                             
          type = "FAT 32 LBA";                                        
40003578:	23 10 00 98 	sethi  %hi(0x40026000), %l1                    
    } else {                                                          
      rtems_bdpart_type_to_string( p->type, type_buffer);             
      type = type_buffer;                                             
    }                                                                 
                                                                      
    printf(                                                           
4000357c:	a4 14 a2 08 	or  %l2, 0x208, %l2                            
    "------------+------------+-----------------------------------------------------\n"
    " BEGIN      | LAST       | TYPE\n"                               
    "------------+------------+-----------------------------------------------------\n"
  );                                                                  
                                                                      
  for (i = 0; i < count; ++i) {                                       
40003580:	80 a7 40 19 	cmp  %i5, %i1                                  
40003584:	02 80 00 37 	be  40003660 <rtems_bdpart_dump+0x118>         
40003588:	11 10 00 98 	sethi  %hi(0x40026000), %o0                    
    const rtems_bdpart_partition *p = pt + i;                         
    const char *type = NULL;                                          
    char type_buffer [52];                                            
    uint8_t type_mbr = 0;                                             
4000358c:	c0 2f bf c7 	clrb  [ %fp + -57 ]                            
                                                                      
    if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {    
40003590:	90 10 00 18 	mov  %i0, %o0                                  
40003594:	40 00 00 9c 	call  40003804 <rtems_bdpart_to_mbr_partition_type>
40003598:	92 07 bf c7 	add  %fp, -57, %o1                             
4000359c:	80 a2 20 00 	cmp  %o0, 0                                    
400035a0:	22 80 00 23 	be,a   4000362c <rtems_bdpart_dump+0xe4>       <== NEVER TAKEN
400035a4:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
      switch (type_mbr) {                                             
400035a8:	d6 0f bf c7 	ldub  [ %fp + -57 ], %o3                       
400035ac:	80 a2 e0 0b 	cmp  %o3, 0xb                                  
400035b0:	22 80 00 24 	be,a   40003640 <rtems_bdpart_dump+0xf8>       <== ALWAYS TAKEN
400035b4:	96 17 20 a8 	or  %i4, 0xa8, %o3                             
400035b8:	18 80 00 09 	bgu  400035dc <rtems_bdpart_dump+0x94>         <== NOT EXECUTED
400035bc:	80 a2 e0 0e 	cmp  %o3, 0xe                                  <== NOT EXECUTED
400035c0:	80 a2 e0 01 	cmp  %o3, 1                                    <== NOT EXECUTED
400035c4:	02 80 00 0e 	be  400035fc <rtems_bdpart_dump+0xb4>          <== NOT EXECUTED
400035c8:	80 a2 e0 04 	cmp  %o3, 4                                    <== NOT EXECUTED
400035cc:	22 80 00 1c 	be,a   4000363c <rtems_bdpart_dump+0xf4>       <== NOT EXECUTED
400035d0:	17 10 00 98 	sethi  %hi(0x40026000), %o3                    <== NOT EXECUTED
          break;                                                      
        case RTEMS_BDPART_MBR_DATA:                                   
          type = "DATA";                                              
          break;                                                      
        default:                                                      
          snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
400035d4:	10 80 00 11 	b  40003618 <rtems_bdpart_dump+0xd0>           <== NOT EXECUTED
400035d8:	90 07 bf c8 	add  %fp, -56, %o0                             <== 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) {                                             
400035dc:	02 80 00 0b 	be  40003608 <rtems_bdpart_dump+0xc0>          <== NOT EXECUTED
400035e0:	80 a2 e0 da 	cmp  %o3, 0xda                                 <== NOT EXECUTED
400035e4:	02 80 00 0b 	be  40003610 <rtems_bdpart_dump+0xc8>          <== NOT EXECUTED
400035e8:	80 a2 e0 0c 	cmp  %o3, 0xc                                  <== NOT EXECUTED
400035ec:	12 80 00 0b 	bne  40003618 <rtems_bdpart_dump+0xd0>         <== NOT EXECUTED
400035f0:	90 07 bf c8 	add  %fp, -56, %o0                             <== NOT EXECUTED
        case RTEMS_BDPART_MBR_FAT_32:                                 
          type = "FAT 32";                                            
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_32_LBA:                             
          type = "FAT 32 LBA";                                        
          break;                                                      
400035f4:	10 80 00 13 	b  40003640 <rtems_bdpart_dump+0xf8>           <== NOT EXECUTED
400035f8:	96 14 60 98 	or  %l1, 0x98, %o3                             <== NOT EXECUTED
    uint8_t type_mbr = 0;                                             
                                                                      
    if (rtems_bdpart_to_mbr_partition_type( p->type, &type_mbr)) {    
      switch (type_mbr) {                                             
        case RTEMS_BDPART_MBR_FAT_12:                                 
          type = "FAT 12";                                            
400035fc:	17 10 00 98 	sethi  %hi(0x40026000), %o3                    <== NOT EXECUTED
40003600:	10 80 00 10 	b  40003640 <rtems_bdpart_dump+0xf8>           <== NOT EXECUTED
40003604:	96 12 e0 88 	or  %o3, 0x88, %o3	! 40026088 <__FUNCTION__.6501+0x130><== NOT EXECUTED
        case RTEMS_BDPART_MBR_FAT_16:                                 
          type = "FAT 16";                                            
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_16_LBA:                             
          type = "FAT 16 LBA";                                        
          break;                                                      
40003608:	10 80 00 0e 	b  40003640 <rtems_bdpart_dump+0xf8>           <== NOT EXECUTED
4000360c:	96 16 a0 b0 	or  %i2, 0xb0, %o3                             <== NOT EXECUTED
        case RTEMS_BDPART_MBR_FAT_32_LBA:                             
          type = "FAT 32 LBA";                                        
          break;                                                      
        case RTEMS_BDPART_MBR_DATA:                                   
          type = "DATA";                                              
          break;                                                      
40003610:	10 80 00 0c 	b  40003640 <rtems_bdpart_dump+0xf8>           <== NOT EXECUTED
40003614:	96 14 20 90 	or  %l0, 0x90, %o3                             <== NOT EXECUTED
        default:                                                      
          snprintf( type_buffer, sizeof( type_buffer), "0x%02" PRIx8, type_mbr);
40003618:	92 10 20 34 	mov  0x34, %o1                                 <== NOT EXECUTED
4000361c:	40 00 4c 55 	call  40016770 <snprintf>                      <== NOT EXECUTED
40003620:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
          type = type_buffer;                                         
          break;                                                      
      }                                                               
    } else {                                                          
      rtems_bdpart_type_to_string( p->type, type_buffer);             
      type = type_buffer;                                             
40003624:	10 80 00 07 	b  40003640 <rtems_bdpart_dump+0xf8>           <== NOT EXECUTED
40003628:	96 07 bf c8 	add  %fp, -56, %o3                             <== NOT EXECUTED
static void rtems_bdpart_type_to_string(                              
  const uuid_t type,                                                  
  char str [37]                                                       
)                                                                     
{                                                                     
  uuid_unparse_lower( type, str);                                     
4000362c:	40 00 2d 53 	call  4000eb78 <uuid_unparse_lower>            <== NOT EXECUTED
40003630:	92 07 bf c8 	add  %fp, -56, %o1                             <== NOT EXECUTED
          type = type_buffer;                                         
          break;                                                      
      }                                                               
    } else {                                                          
      rtems_bdpart_type_to_string( p->type, type_buffer);             
      type = type_buffer;                                             
40003634:	10 80 00 03 	b  40003640 <rtems_bdpart_dump+0xf8>           <== NOT EXECUTED
40003638:	96 07 bf c8 	add  %fp, -56, %o3                             <== NOT EXECUTED
      switch (type_mbr) {                                             
        case RTEMS_BDPART_MBR_FAT_12:                                 
          type = "FAT 12";                                            
          break;                                                      
        case RTEMS_BDPART_MBR_FAT_16:                                 
          type = "FAT 16";                                            
4000363c:	96 12 e0 80 	or  %o3, 0x80, %o3                             <== NOT EXECUTED
    } else {                                                          
      rtems_bdpart_type_to_string( p->type, type_buffer);             
      type = type_buffer;                                             
    }                                                                 
                                                                      
    printf(                                                           
40003640:	d4 06 3f fc 	ld  [ %i0 + -4 ], %o2                          
40003644:	d2 06 3f f8 	ld  [ %i0 + -8 ], %o1                          
40003648:	90 10 00 12 	mov  %l2, %o0                                  
4000364c:	94 02 bf ff 	add  %o2, -1, %o2                              
40003650:	40 00 4b 99 	call  400164b4 <printf>                        
40003654:	ba 07 60 01 	inc  %i5                                       
40003658:	10 bf ff ca 	b  40003580 <rtems_bdpart_dump+0x38>           
4000365c:	b0 06 20 30 	add  %i0, 0x30, %i0                            
      p->end - 1U,                                                    
      type                                                            
    );                                                                
  }                                                                   
                                                                      
  puts( "------------+------------+-----------------------------------------------------");
40003660:	40 00 4b c6 	call  40016578 <puts>                          
40003664:	90 12 21 b0 	or  %o0, 0x1b0, %o0                            
40003668:	81 c7 e0 08 	ret                                            
4000366c:	81 e8 00 00 	restore                                        
                                                                      

40003834 <rtems_bdpart_get_disk_data>: const char *disk_name, int *fd_ptr, rtems_disk_device **dd_ptr, rtems_blkdev_bnum *disk_end ) {
40003834:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_disk_device *dd = NULL;                                       
  rtems_blkdev_bnum disk_begin = 0;                                   
  rtems_blkdev_bnum block_size = 0;                                   
                                                                      
  /* Open device file */                                              
  fd = open( disk_name, O_RDWR);                                      
40003838:	92 10 20 02 	mov  2, %o1                                    
4000383c:	90 10 00 18 	mov  %i0, %o0                                  
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  int rv = 0;                                                         
  int fd;                                                             
  rtems_disk_device *dd = NULL;                                       
40003840:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
  rtems_blkdev_bnum disk_begin = 0;                                   
  rtems_blkdev_bnum block_size = 0;                                   
                                                                      
  /* Open device file */                                              
  fd = open( disk_name, O_RDWR);                                      
40003844:	40 00 0d d5 	call  40006f98 <open>                          
40003848:	b0 10 20 03 	mov  3, %i0                                    
  if (fd < 0) {                                                       
4000384c:	80 a2 20 00 	cmp  %o0, 0                                    
40003850:	06 80 00 1c 	bl  400038c0 <rtems_bdpart_get_disk_data+0x8c> <== NEVER TAKEN
40003854:	ba 10 00 08 	mov  %o0, %i5                                  
static inline int rtems_disk_fd_get_disk_device(                      
  int fd,                                                             
  rtems_disk_device **dd_ptr                                          
)                                                                     
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_GETDISKDEV, dd_ptr);                   
40003858:	13 10 01 10 	sethi  %hi(0x40044000), %o1                    
4000385c:	94 07 bf fc 	add  %fp, -4, %o2                              
40003860:	40 00 0b 37 	call  4000653c <ioctl>                         
40003864:	92 12 62 09 	or  %o1, 0x209, %o1                            
    goto out;                                                         
  }                                                                   
                                                                      
  /* Get disk handle */                                               
  rv = rtems_disk_fd_get_disk_device( fd, &dd);                       
  if (rv != 0) {                                                      
40003868:	80 a2 20 00 	cmp  %o0, 0                                    
4000386c:	12 80 00 0d 	bne  400038a0 <rtems_bdpart_get_disk_data+0x6c><== NEVER TAKEN
40003870:	80 a6 20 00 	cmp  %i0, 0                                    
    sc = RTEMS_INVALID_NAME;                                          
    goto error;                                                       
  }                                                                   
                                                                      
  /* Get disk begin, end and block size */                            
  disk_begin = dd->start;                                             
40003874:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
  *disk_end = dd->size;                                               
40003878:	c4 18 60 18 	ldd  [ %g1 + 0x18 ], %g2                       
4000387c:	c6 26 c0 00 	st  %g3, [ %i3 ]                               
  block_size = dd->block_size;                                        
                                                                      
  /* Check block size */                                              
  if (block_size < RTEMS_BDPART_BLOCK_SIZE) {                         
40003880:	c2 00 60 24 	ld  [ %g1 + 0x24 ], %g1                        
40003884:	80 a0 61 ff 	cmp  %g1, 0x1ff                                
40003888:	08 80 00 05 	bleu  4000389c <rtems_bdpart_get_disk_data+0x68><== NEVER TAKEN
4000388c:	b0 10 20 1b 	mov  0x1b, %i0                                 
  int *fd_ptr,                                                        
  rtems_disk_device **dd_ptr,                                         
  rtems_blkdev_bnum *disk_end                                         
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
40003890:	80 a0 00 02 	cmp  %g0, %g2                                  
40003894:	b0 60 20 00 	subx  %g0, 0, %i0                              
40003898:	b0 0e 20 1b 	and  %i0, 0x1b, %i0                            
    goto error;                                                       
  }                                                                   
                                                                      
error:                                                                
                                                                      
  if (sc == RTEMS_SUCCESSFUL && fd_ptr != NULL && dd_ptr != NULL) {   
4000389c:	80 a6 20 00 	cmp  %i0, 0                                    
400038a0:	12 80 00 0a 	bne  400038c8 <rtems_bdpart_get_disk_data+0x94><== NEVER TAKEN
400038a4:	80 a6 60 00 	cmp  %i1, 0                                    
400038a8:	02 80 00 08 	be  400038c8 <rtems_bdpart_get_disk_data+0x94> 
400038ac:	80 a6 a0 00 	cmp  %i2, 0                                    
400038b0:	02 80 00 06 	be  400038c8 <rtems_bdpart_get_disk_data+0x94> <== NEVER TAKEN
400038b4:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
    *fd_ptr = fd;                                                     
400038b8:	fa 26 40 00 	st  %i5, [ %i1 ]                               
    *dd_ptr = dd;                                                     
400038bc:	c2 26 80 00 	st  %g1, [ %i2 ]                               
400038c0:	81 c7 e0 08 	ret                                            
400038c4:	81 e8 00 00 	restore                                        
  } else {                                                            
    close( fd);                                                       
400038c8:	40 00 0a 80 	call  400062c8 <close>                         
400038cc:	90 10 00 1d 	mov  %i5, %o0                                  
  }                                                                   
                                                                      
out:                                                                  
  return sc;                                                          
}                                                                     
400038d0:	81 c7 e0 08 	ret                                            
400038d4:	81 e8 00 00 	restore                                        
                                                                      

40003d60 <rtems_bdpart_new_record>: static rtems_status_code rtems_bdpart_new_record( rtems_disk_device *dd, rtems_blkdev_bnum index, rtems_bdbuf_buffer **block ) {
40003d60:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  /* Synchronize previous block if necessary */                       
  if (*block != NULL) {                                               
40003d64:	d0 06 80 00 	ld  [ %i2 ], %o0                               
40003d68:	80 a2 20 00 	cmp  %o0, 0                                    
40003d6c:	12 80 00 0b 	bne  40003d98 <rtems_bdpart_new_record+0x38>   
40003d70:	01 00 00 00 	nop                                            
      return sc;                                                      
    }                                                                 
  }                                                                   
                                                                      
  /* Read the new record block (this accounts for disk block sizes > 512) */
  sc = rtems_bdbuf_read( dd, index, block);                           
40003d74:	90 10 00 18 	mov  %i0, %o0                                  
40003d78:	92 10 00 19 	mov  %i1, %o1                                  
40003d7c:	40 00 33 8e 	call  40010bb4 <rtems_bdbuf_read>              
40003d80:	94 10 00 1a 	mov  %i2, %o2                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003d84:	80 a2 20 00 	cmp  %o0, 0                                    
40003d88:	22 80 00 0b 	be,a   40003db4 <rtems_bdpart_new_record+0x54> <== ALWAYS TAKEN
40003d8c:	c2 06 80 00 	ld  [ %i2 ], %g1                               
    RTEMS_BDPART_MBR_SIGNATURE_0;                                     
  (*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_1] =            
    RTEMS_BDPART_MBR_SIGNATURE_1;                                     
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003d90:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003d94:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  /* Synchronize previous block if necessary */                       
  if (*block != NULL) {                                               
    sc = rtems_bdbuf_sync( *block);                                   
40003d98:	40 00 34 47 	call  40010eb4 <rtems_bdbuf_sync>              
40003d9c:	01 00 00 00 	nop                                            
    if (sc != RTEMS_SUCCESSFUL) {                                     
40003da0:	80 a2 20 00 	cmp  %o0, 0                                    
40003da4:	22 bf ff f5 	be,a   40003d78 <rtems_bdpart_new_record+0x18> <== ALWAYS TAKEN
40003da8:	90 10 00 18 	mov  %i0, %o0                                  
    RTEMS_BDPART_MBR_SIGNATURE_0;                                     
  (*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_1] =            
    RTEMS_BDPART_MBR_SIGNATURE_1;                                     
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003dac:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003db0:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
                                                                      
  /* just in case block did not get filled in */                      
  if ( *block == NULL ) {                                             
40003db4:	80 a0 60 00 	cmp  %g1, 0                                    
40003db8:	02 80 00 0f 	be  40003df4 <rtems_bdpart_new_record+0x94>    <== NEVER TAKEN
40003dbc:	90 10 20 09 	mov  9, %o0                                    
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  /* Clear record */                                                  
  memset( (*block)->buffer, 0, RTEMS_BDPART_BLOCK_SIZE);              
40003dc0:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40003dc4:	92 10 20 00 	clr  %o1                                       
40003dc8:	40 00 49 66 	call  40016360 <memset>                        
40003dcc:	94 10 22 00 	mov  0x200, %o2                                
                                                                      
  /* Write signature */                                               
  (*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_0] =            
40003dd0:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40003dd4:	84 10 20 55 	mov  0x55, %g2                                 
40003dd8:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
    RTEMS_BDPART_MBR_SIGNATURE_0;                                     
  (*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_1] =            
    RTEMS_BDPART_MBR_SIGNATURE_1;                                     
                                                                      
  return RTEMS_SUCCESSFUL;                                            
40003ddc:	90 10 20 00 	clr  %o0                                       
                                                                      
  /* Clear record */                                                  
  memset( (*block)->buffer, 0, RTEMS_BDPART_BLOCK_SIZE);              
                                                                      
  /* Write signature */                                               
  (*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_0] =            
40003de0:	c4 28 61 fe 	stb  %g2, [ %g1 + 0x1fe ]                      
    RTEMS_BDPART_MBR_SIGNATURE_0;                                     
  (*block)->buffer [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_1] =            
40003de4:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40003de8:	84 10 3f aa 	mov  -86, %g2                                  
40003dec:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
40003df0:	c4 28 61 ff 	stb  %g2, [ %g1 + 0x1ff ]                      
    RTEMS_BDPART_MBR_SIGNATURE_1;                                     
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003df4:	b0 10 00 08 	mov  %o0, %i0                                  
40003df8:	81 c7 e0 08 	ret                                            
40003dfc:	81 e8 00 00 	restore                                        
                                                                      

400038d8 <rtems_bdpart_read>: const char *disk_name, rtems_bdpart_format *format, rtems_bdpart_partition *pt, size_t *count ) {
400038d8:	9d e3 bf 88 	save  %sp, -120, %sp                           
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  rtems_bdbuf_buffer *block = NULL;                                   
  rtems_bdpart_partition *p = pt - 1;                                 
400038dc:	82 06 bf d0 	add  %i2, -48, %g1                             
  size_t *count                                                       
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  rtems_bdbuf_buffer *block = NULL;                                   
400038e0:	c0 27 bf e8 	clr  [ %fp + -24 ]                             
  rtems_bdpart_partition *p = pt - 1;                                 
400038e4:	c2 27 bf ec 	st  %g1, [ %fp + -20 ]                         
  const rtems_bdpart_partition *p_end = pt + (count != NULL ? *count : 0);
400038e8:	80 a6 e0 00 	cmp  %i3, 0                                    
400038ec:	02 80 00 07 	be  40003908 <rtems_bdpart_read+0x30>          <== NEVER TAKEN
400038f0:	90 10 00 18 	mov  %i0, %o0                                  
400038f4:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
400038f8:	85 28 60 04 	sll  %g1, 4, %g2                               
400038fc:	b9 28 60 06 	sll  %g1, 6, %i4                               
40003900:	10 80 00 03 	b  4000390c <rtems_bdpart_read+0x34>           
40003904:	b8 27 00 02 	sub  %i4, %g2, %i4                             
40003908:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
  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;                                     
  size_t i = 0;                                                       
  const uint8_t *data = NULL;                                         
  int fd = -1;                                                        
4000390c:	82 10 3f ff 	mov  -1, %g1                                   
  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 */      
40003910:	c0 27 bf f0 	clr  [ %fp + -16 ]                             
  rtems_blkdev_bnum ebr = 0; /* Extended boot record block index */   
  rtems_blkdev_bnum disk_end = 0;                                     
40003914:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
  size_t i = 0;                                                       
  const uint8_t *data = NULL;                                         
  int fd = -1;                                                        
40003918:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  rtems_disk_device *dd = NULL;                                       
4000391c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
  /* Check parameter */                                               
  if (format == NULL || pt == NULL || count == NULL) {                
40003920:	80 a6 60 00 	cmp  %i1, 0                                    
40003924:	02 80 00 86 	be  40003b3c <rtems_bdpart_read+0x264>         <== NEVER TAKEN
40003928:	b0 10 20 09 	mov  9, %i0                                    
4000392c:	80 a6 a0 00 	cmp  %i2, 0                                    
40003930:	02 80 00 83 	be  40003b3c <rtems_bdpart_read+0x264>         <== NEVER TAKEN
40003934:	80 a6 e0 00 	cmp  %i3, 0                                    
40003938:	02 80 00 81 	be  40003b3c <rtems_bdpart_read+0x264>         <== NEVER TAKEN
4000393c:	92 07 bf f8 	add  %fp, -8, %o1                              
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  /* Set count to a save value */                                     
  *count = 0;                                                         
40003940:	c0 26 c0 00 	clr  [ %i3 ]                                   
                                                                      
  /* Get disk data */                                                 
  sc = rtems_bdpart_get_disk_data( disk_name, &fd, &dd, &disk_end);   
40003944:	94 07 bf fc 	add  %fp, -4, %o2                              
40003948:	7f ff ff bb 	call  40003834 <rtems_bdpart_get_disk_data>    
4000394c:	96 07 bf f4 	add  %fp, -12, %o3                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003950:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40003954:	12 80 00 7a 	bne  40003b3c <rtems_bdpart_read+0x264>        <== NEVER TAKEN
40003958:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
    return sc;                                                        
  }                                                                   
                                                                      
  /* Read MBR */                                                      
  sc = rtems_bdpart_read_record( dd, 0, &block);                      
4000395c:	92 10 20 00 	clr  %o1                                       
40003960:	7f ff ff 4f 	call  4000369c <rtems_bdpart_read_record>      
40003964:	94 07 bf e8 	add  %fp, -24, %o2                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003968:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000396c:	12 80 00 69 	bne  40003b10 <rtems_bdpart_read+0x238>        <== NEVER TAKEN
40003970:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
    esc = sc;                                                         
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Read the first partition entry */                                
  data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;             
40003974:	c2 07 bf e8 	ld  [ %fp + -24 ], %g1                         
{                                                                     
  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);
40003978:	b8 06 80 1c 	add  %i2, %i4, %i4                             
    esc = sc;                                                         
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Read the first partition entry */                                
  data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;             
4000397c:	e0 00 60 1c 	ld  [ %g1 + 0x1c ], %l0                        
  sc = rtems_bdpart_read_mbr_partition( data, &p, p_end, &ep_begin);  
40003980:	92 07 bf ec 	add  %fp, -20, %o1                             
    esc = sc;                                                         
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Read the first partition entry */                                
  data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;             
40003984:	ba 04 21 be 	add  %l0, 0x1be, %i5                           
  sc = rtems_bdpart_read_mbr_partition( data, &p, p_end, &ep_begin);  
40003988:	94 10 00 1c 	mov  %i4, %o2                                  
4000398c:	90 10 00 1d 	mov  %i5, %o0                                  
40003990:	7f ff ff 72 	call  40003758 <rtems_bdpart_read_mbr_partition>
40003994:	96 07 bf f0 	add  %fp, -16, %o3                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003998:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000399c:	32 80 00 5d 	bne,a   40003b10 <rtems_bdpart_read+0x238>     <== NEVER TAKEN
400039a0:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          <== 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) {
400039a4:	c2 07 bf ec 	ld  [ %fp + -20 ], %g1                         
400039a8:	c2 08 60 08 	ldub  [ %g1 + 8 ], %g1                         
400039ac:	80 a0 60 ee 	cmp  %g1, 0xee                                 
400039b0:	02 80 00 57 	be  40003b0c <rtems_bdpart_read+0x234>         <== NEVER TAKEN
400039b4:	b0 10 20 18 	mov  0x18, %i0                                 
  }                                                                   
                                                                      
  /* Set format */                                                    
  format->type = RTEMS_BDPART_FORMAT_MBR;                             
  format->mbr.disk_id = rtems_uint32_from_little_endian(              
    block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID                   
400039b8:	c2 07 bf e8 	ld  [ %fp + -24 ], %g1                         
    esc = RTEMS_NOT_IMPLEMENTED;                                      
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Set format */                                                    
  format->type = RTEMS_BDPART_FORMAT_MBR;                             
400039bc:	c0 26 40 00 	clr  [ %i1 ]                                   
  format->mbr.disk_id = rtems_uint32_from_little_endian(              
400039c0:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
400039c4:	a0 04 21 ee 	add  %l0, 0x1ee, %l0                           
400039c8:	7f ff ff 2a 	call  40003670 <rtems_uint32_from_little_endian>
400039cc:	90 02 21 b8 	add  %o0, 0x1b8, %o0                           
    block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID                   
  );                                                                  
  format->mbr.dos_compatibility = true;                               
400039d0:	82 10 20 01 	mov  1, %g1                                    
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Set format */                                                    
  format->type = RTEMS_BDPART_FORMAT_MBR;                             
  format->mbr.disk_id = rtems_uint32_from_little_endian(              
400039d4:	d0 26 60 04 	st  %o0, [ %i1 + 4 ]                           
    block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID                   
  );                                                                  
  format->mbr.dos_compatibility = true;                               
400039d8:	c2 2e 60 08 	stb  %g1, [ %i1 + 8 ]                          
                                                                      
  /* Iterate through the rest of the primary partition table */       
  for (i = 1; i < 4; ++i) {                                           
    data += RTEMS_BDPART_MBR_TABLE_ENTRY_SIZE;                        
400039dc:	ba 07 60 10 	add  %i5, 0x10, %i5                            
                                                                      
    sc = rtems_bdpart_read_mbr_partition( data, &p, p_end, &ep_begin);
400039e0:	92 07 bf ec 	add  %fp, -20, %o1                             
400039e4:	90 10 00 1d 	mov  %i5, %o0                                  
400039e8:	94 10 00 1c 	mov  %i4, %o2                                  
400039ec:	7f ff ff 5b 	call  40003758 <rtems_bdpart_read_mbr_partition>
400039f0:	96 07 bf f0 	add  %fp, -16, %o3                             
    if (sc != RTEMS_SUCCESSFUL) {                                     
400039f4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400039f8:	12 80 00 45 	bne  40003b0c <rtems_bdpart_read+0x234>        <== NEVER TAKEN
400039fc:	80 a7 40 10 	cmp  %i5, %l0                                  
    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) {                                           
40003a00:	12 bf ff f8 	bne  400039e0 <rtems_bdpart_read+0x108>        
40003a04:	ba 07 60 10 	add  %i5, 0x10, %i5                            
      goto cleanup;                                                   
    }                                                                 
  }                                                                   
                                                                      
  /* Iterate through the logical partitions within the extended partition */
  ebr = ep_begin;                                                     
40003a08:	fa 07 bf f0 	ld  [ %fp + -16 ], %i5                         
  while (ebr != 0) {                                                  
40003a0c:	80 a7 60 00 	cmp  %i5, 0                                    
40003a10:	02 80 00 2f 	be  40003acc <rtems_bdpart_read+0x1f4>         <== NEVER TAKEN
40003a14:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
    rtems_blkdev_bnum tmp = 0;                                        
                                                                      
    /* Read EBR */                                                    
    sc = rtems_bdpart_read_record( dd, ebr, &block);                  
40003a18:	92 10 00 1d 	mov  %i5, %o1                                  
40003a1c:	7f ff ff 20 	call  4000369c <rtems_bdpart_read_record>      
40003a20:	94 07 bf e8 	add  %fp, -24, %o2                             
    if (sc != RTEMS_SUCCESSFUL) {                                     
40003a24:	80 a2 20 00 	cmp  %o0, 0                                    
40003a28:	12 80 00 38 	bne  40003b08 <rtems_bdpart_read+0x230>        <== NEVER TAKEN
40003a2c:	c2 07 bf e8 	ld  [ %fp + -24 ], %g1                         
      esc = sc;                                                       
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Read first partition entry */                                  
    sc = rtems_bdpart_read_mbr_partition(                             
40003a30:	92 07 bf ec 	add  %fp, -20, %o1                             
40003a34:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40003a38:	94 10 00 1c 	mov  %i4, %o2                                  
40003a3c:	90 02 21 be 	add  %o0, 0x1be, %o0                           
40003a40:	7f ff ff 46 	call  40003758 <rtems_bdpart_read_mbr_partition>
40003a44:	96 10 20 00 	clr  %o3                                       
      block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0,                
      &p,                                                             
      p_end,                                                          
      NULL                                                            
    );                                                                
    if (sc != RTEMS_SUCCESSFUL) {                                     
40003a48:	80 a2 20 00 	cmp  %o0, 0                                    
40003a4c:	12 80 00 2f 	bne  40003b08 <rtems_bdpart_read+0x230>        <== NEVER TAKEN
40003a50:	c2 07 bf ec 	ld  [ %fp + -20 ], %g1                         
      esc = sc;                                                       
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Adjust partition begin */                                      
    tmp = p->begin + ebr;                                             
40003a54:	c6 00 40 00 	ld  [ %g1 ], %g3                               
40003a58:	84 07 40 03 	add  %i5, %g3, %g2                             
    if (tmp > p->begin) {                                             
40003a5c:	80 a0 80 03 	cmp  %g2, %g3                                  
40003a60:	38 80 00 04 	bgu,a   40003a70 <rtems_bdpart_read+0x198>     <== ALWAYS TAKEN
40003a64:	c4 20 40 00 	st  %g2, [ %g1 ]                               
      p->begin = tmp;                                                 
    } else {                                                          
      esc = RTEMS_IO_ERROR;                                           
40003a68:	10 80 00 29 	b  40003b0c <rtems_bdpart_read+0x234>          <== NOT EXECUTED
40003a6c:	b0 10 20 1b 	mov  0x1b, %i0                                 <== NOT EXECUTED
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Adjust partition end */                                        
    tmp = p->end + ebr;                                               
40003a70:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
40003a74:	ba 07 40 02 	add  %i5, %g2, %i5                             
    if (tmp > p->end) {                                               
40003a78:	80 a7 40 02 	cmp  %i5, %g2                                  
40003a7c:	28 80 00 24 	bleu,a   40003b0c <rtems_bdpart_read+0x234>    <== NEVER TAKEN
40003a80:	b0 10 20 1b 	mov  0x1b, %i0                                 <== NOT EXECUTED
      p->end = tmp;                                                   
40003a84:	fa 20 60 04 	st  %i5, [ %g1 + 4 ]                           
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Read second partition entry for next EBR block */              
    ebr = rtems_bdpart_next_ebr(                                      
      block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_1                 
40003a88:	c2 07 bf e8 	ld  [ %fp + -24 ], %g1                         
40003a8c:	fa 00 60 1c 	ld  [ %g1 + 0x1c ], %i5                        
      == RTEMS_BDPART_MBR_SIGNATURE_1;                                
}                                                                     
                                                                      
static rtems_blkdev_bnum rtems_bdpart_next_ebr( const uint8_t *data)  
{                                                                     
  rtems_blkdev_bnum begin =                                           
40003a90:	7f ff fe f8 	call  40003670 <rtems_uint32_from_little_endian>
40003a94:	90 07 61 d6 	add  %i5, 0x1d6, %o0                           
    rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
  uint8_t type = data [RTEMS_BDPART_MBR_OFFSET_TYPE];                 
                                                                      
  if (type == RTEMS_BDPART_MBR_EXTENDED) {                            
40003a98:	c2 0f 61 d2 	ldub  [ %i5 + 0x1d2 ], %g1                     
40003a9c:	80 a0 60 05 	cmp  %g1, 5                                    
40003aa0:	32 80 00 0c 	bne,a   40003ad0 <rtems_bdpart_read+0x1f8>     
40003aa4:	c2 07 bf ec 	ld  [ %fp + -20 ], %g1                         
                                                                      
    /* Read second partition entry for next EBR block */              
    ebr = rtems_bdpart_next_ebr(                                      
      block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_1                 
    );                                                                
    if (ebr != 0) {                                                   
40003aa8:	80 a2 20 00 	cmp  %o0, 0                                    
40003aac:	02 80 00 08 	be  40003acc <rtems_bdpart_read+0x1f4>         <== NEVER TAKEN
40003ab0:	fa 07 bf f0 	ld  [ %fp + -16 ], %i5                         
      /* Adjust partition EBR block index */                          
      tmp = ebr + ep_begin;                                           
40003ab4:	ba 02 00 1d 	add  %o0, %i5, %i5                             
      if (tmp > ebr) {                                                
40003ab8:	80 a7 40 08 	cmp  %i5, %o0                                  
40003abc:	18 bf ff d5 	bgu  40003a10 <rtems_bdpart_read+0x138>        <== ALWAYS TAKEN
40003ac0:	80 a7 60 00 	cmp  %i5, 0                                    
40003ac4:	10 80 00 12 	b  40003b0c <rtems_bdpart_read+0x234>          <== NOT EXECUTED
40003ac8:	b0 10 20 1b 	mov  0x1b, %i0                                 <== NOT EXECUTED
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  /* Return partition count */                                        
  *count = (size_t) (p - pt + 1);                                     
40003acc:	c2 07 bf ec 	ld  [ %fp + -20 ], %g1                         <== NOT EXECUTED
40003ad0:	b4 20 40 1a 	sub  %g1, %i2, %i2                             
40003ad4:	b5 3e a0 04 	sra  %i2, 4, %i2                               
40003ad8:	83 2e a0 02 	sll  %i2, 2, %g1                               
40003adc:	82 00 40 1a 	add  %g1, %i2, %g1                             
40003ae0:	85 28 60 04 	sll  %g1, 4, %g2                               
40003ae4:	82 00 40 02 	add  %g1, %g2, %g1                             
40003ae8:	85 28 60 08 	sll  %g1, 8, %g2                               
40003aec:	82 00 40 02 	add  %g1, %g2, %g1                             
40003af0:	85 28 60 10 	sll  %g1, 0x10, %g2                            
40003af4:	82 00 40 02 	add  %g1, %g2, %g1                             
40003af8:	82 20 00 01 	neg  %g1                                       
40003afc:	82 00 60 01 	inc  %g1                                       
40003b00:	10 80 00 03 	b  40003b0c <rtems_bdpart_read+0x234>          
40003b04:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
      esc = sc;                                                       
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Read first partition entry */                                  
    sc = rtems_bdpart_read_mbr_partition(                             
40003b08:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
  /* Return partition count */                                        
  *count = (size_t) (p - pt + 1);                                     
                                                                      
cleanup:                                                              
                                                                      
  if (fd >= 0) {                                                      
40003b0c:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
40003b10:	80 a2 20 00 	cmp  %o0, 0                                    
40003b14:	26 80 00 05 	bl,a   40003b28 <rtems_bdpart_read+0x250>      <== NEVER TAKEN
40003b18:	d0 07 bf e8 	ld  [ %fp + -24 ], %o0                         <== NOT EXECUTED
    close( fd);                                                       
40003b1c:	40 00 09 eb 	call  400062c8 <close>                         
40003b20:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  if (block != NULL) {                                                
40003b24:	d0 07 bf e8 	ld  [ %fp + -24 ], %o0                         
40003b28:	80 a2 20 00 	cmp  %o0, 0                                    
40003b2c:	02 80 00 06 	be  40003b44 <rtems_bdpart_read+0x26c>         <== NEVER TAKEN
40003b30:	01 00 00 00 	nop                                            
    rtems_bdbuf_release( block);                                      
40003b34:	40 00 34 8f 	call  40010d70 <rtems_bdbuf_release>           
40003b38:	01 00 00 00 	nop                                            
40003b3c:	81 c7 e0 08 	ret                                            
40003b40:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return esc;                                                         
}                                                                     
40003b44:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003b48:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40003758 <rtems_bdpart_read_mbr_partition>: const uint8_t *data, rtems_bdpart_partition **p, const rtems_bdpart_partition *p_end, rtems_blkdev_bnum *ep_begin ) {
40003758:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_blkdev_bnum begin =                                           
4000375c:	7f ff ff c5 	call  40003670 <rtems_uint32_from_little_endian>
40003760:	90 06 20 08 	add  %i0, 8, %o0                               
40003764:	ba 10 00 08 	mov  %o0, %i5                                  
    rtems_uint32_from_little_endian( data + RTEMS_BDPART_MBR_OFFSET_BEGIN);
  rtems_blkdev_bnum size =                                            
40003768:	7f ff ff c2 	call  40003670 <rtems_uint32_from_little_endian>
4000376c:	90 06 20 0c 	add  %i0, 0xc, %o0                             
    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) {                               
40003770:	f8 0e 20 04 	ldub  [ %i0 + 4 ], %i4                         
40003774:	80 a7 20 00 	cmp  %i4, 0                                    
40003778:	02 80 00 21 	be  400037fc <rtems_bdpart_read_mbr_partition+0xa4><== NEVER TAKEN
4000377c:	82 10 20 00 	clr  %g1                                       
    return RTEMS_SUCCESSFUL;                                          
  } else if (*p == p_end) {                                           
40003780:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40003784:	80 a0 80 1a 	cmp  %g2, %i2                                  
40003788:	02 80 00 1d 	be  400037fc <rtems_bdpart_read_mbr_partition+0xa4><== NEVER TAKEN
4000378c:	82 10 20 05 	mov  5, %g1                                    
{                                                                     
  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;                               
40003790:	b4 02 00 1d 	add  %o0, %i5, %i2                             
                                                                      
  if (type == RTEMS_BDPART_MBR_EMPTY) {                               
    return RTEMS_SUCCESSFUL;                                          
  } else if (*p == p_end) {                                           
    return RTEMS_TOO_MANY;                                            
  } else if (begin >= end) {                                          
40003794:	80 a7 40 1a 	cmp  %i5, %i2                                  
40003798:	1a 80 00 19 	bcc  400037fc <rtems_bdpart_read_mbr_partition+0xa4><== NEVER TAKEN
4000379c:	82 10 20 1b 	mov  0x1b, %g1                                 
    return RTEMS_IO_ERROR;                                            
  } else if (type == RTEMS_BDPART_MBR_EXTENDED) {                     
400037a0:	80 a7 20 05 	cmp  %i4, 5                                    
400037a4:	32 80 00 07 	bne,a   400037c0 <rtems_bdpart_read_mbr_partition+0x68>
400037a8:	90 00 a0 30 	add  %g2, 0x30, %o0                            
    if (ep_begin != NULL) {                                           
400037ac:	80 a6 e0 00 	cmp  %i3, 0                                    
400037b0:	32 80 00 12 	bne,a   400037f8 <rtems_bdpart_read_mbr_partition+0xa0><== ALWAYS TAKEN
400037b4:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
    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) {                               
    return RTEMS_SUCCESSFUL;                                          
400037b8:	10 80 00 11 	b  400037fc <rtems_bdpart_read_mbr_partition+0xa4><== NOT EXECUTED
400037bc:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
  } else {                                                            
    /* Increment partition index */                                   
    ++(*p);                                                           
                                                                      
    /* Clear partition */                                             
    memset( *p, 0, sizeof( rtems_bdpart_partition));                  
400037c0:	92 10 20 00 	clr  %o1                                       
400037c4:	94 10 20 30 	mov  0x30, %o2                                 
400037c8:	40 00 4a e6 	call  40016360 <memset>                        
400037cc:	d0 26 40 00 	st  %o0, [ %i1 ]                               
                                                                      
    /* Set values */                                                  
    (*p)->begin = begin;                                              
400037d0:	d2 06 40 00 	ld  [ %i1 ], %o1                               
    (*p)->end = end;                                                  
    rtems_bdpart_to_partition_type( type, (*p)->type);                
400037d4:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
    /* Clear partition */                                             
    memset( *p, 0, sizeof( rtems_bdpart_partition));                  
                                                                      
    /* Set values */                                                  
    (*p)->begin = begin;                                              
400037d8:	fa 22 40 00 	st  %i5, [ %o1 ]                               
    (*p)->end = end;                                                  
400037dc:	f4 22 60 04 	st  %i2, [ %o1 + 4 ]                           
    rtems_bdpart_to_partition_type( type, (*p)->type);                
400037e0:	7f ff ff d6 	call  40003738 <rtems_bdpart_to_partition_type>
400037e4:	92 02 60 08 	add  %o1, 8, %o1                               
    (*p)->flags = data [RTEMS_BDPART_MBR_OFFSET_FLAGS];               
400037e8:	c2 06 40 00 	ld  [ %i1 ], %g1                               
400037ec:	c4 0e 00 00 	ldub  [ %i0 ], %g2                             
400037f0:	c0 20 60 28 	clr  [ %g1 + 0x28 ]                            
400037f4:	c4 20 60 2c 	st  %g2, [ %g1 + 0x2c ]                        
    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) {                               
    return RTEMS_SUCCESSFUL;                                          
400037f8:	82 10 20 00 	clr  %g1                                       
    rtems_bdpart_to_partition_type( type, (*p)->type);                
    (*p)->flags = data [RTEMS_BDPART_MBR_OFFSET_FLAGS];               
  }                                                                   
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
400037fc:	81 c7 e0 08 	ret                                            
40003800:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000369c <rtems_bdpart_read_record>: static rtems_status_code rtems_bdpart_read_record( rtems_disk_device *dd, rtems_blkdev_bnum index, rtems_bdbuf_buffer **block ) {
4000369c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  /* Release previous block if necessary */                           
  if (*block != NULL) {                                               
400036a0:	d0 06 80 00 	ld  [ %i2 ], %o0                               
400036a4:	80 a2 20 00 	cmp  %o0, 0                                    
400036a8:	12 80 00 0b 	bne  400036d4 <rtems_bdpart_read_record+0x38>  
400036ac:	01 00 00 00 	nop                                            
      return sc;                                                      
    }                                                                 
  }                                                                   
                                                                      
  /* Read the record block */                                         
  sc = rtems_bdbuf_read( dd, index, block);                           
400036b0:	90 10 00 18 	mov  %i0, %o0                                  
400036b4:	92 10 00 19 	mov  %i1, %o1                                  
400036b8:	40 00 35 3f 	call  40010bb4 <rtems_bdbuf_read>              
400036bc:	94 10 00 1a 	mov  %i2, %o2                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
400036c0:	80 a2 20 00 	cmp  %o0, 0                                    
400036c4:	22 80 00 0b 	be,a   400036f0 <rtems_bdpart_read_record+0x54><== ALWAYS TAKEN
400036c8:	c2 06 80 00 	ld  [ %i2 ], %g1                               
  if (!rtems_bdpart_is_valid_record( (*block)->buffer)) {             
    return RTEMS_IO_ERROR;                                            
  }                                                                   
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
400036cc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400036d0:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
                                                                      
  /* Release previous block if necessary */                           
  if (*block != NULL) {                                               
    sc = rtems_bdbuf_release( *block);                                
400036d4:	40 00 35 a7 	call  40010d70 <rtems_bdbuf_release>           
400036d8:	01 00 00 00 	nop                                            
    if (sc != RTEMS_SUCCESSFUL) {                                     
400036dc:	80 a2 20 00 	cmp  %o0, 0                                    
400036e0:	22 bf ff f5 	be,a   400036b4 <rtems_bdpart_read_record+0x18><== ALWAYS TAKEN
400036e4:	90 10 00 18 	mov  %i0, %o0                                  
  if (!rtems_bdpart_is_valid_record( (*block)->buffer)) {             
    return RTEMS_IO_ERROR;                                            
  }                                                                   
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
400036e8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400036ec:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
                                                                      
  /* just in case block did not get filled in */                      
  if ( *block == NULL ) {                                             
400036f0:	80 a0 60 00 	cmp  %g1, 0                                    
400036f4:	02 80 00 0e 	be  4000372c <rtems_bdpart_read_record+0x90>   <== NEVER TAKEN
400036f8:	90 10 20 09 	mov  9, %o0                                    
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  /* Check MBR signature */                                           
  if (!rtems_bdpart_is_valid_record( (*block)->buffer)) {             
400036fc:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
                                                                      
static bool rtems_bdpart_is_valid_record( const uint8_t *data)        
{                                                                     
  return data [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_0]                   
      == RTEMS_BDPART_MBR_SIGNATURE_0                                 
    && data [RTEMS_BDPART_MBR_OFFSET_SIGNATURE_1]                     
40003700:	c4 08 61 fe 	ldub  [ %g1 + 0x1fe ], %g2                     
40003704:	80 a0 a0 55 	cmp  %g2, 0x55                                 
40003708:	12 80 00 06 	bne  40003720 <rtems_bdpart_read_record+0x84>  <== NEVER TAKEN
4000370c:	90 10 20 00 	clr  %o0                                       
40003710:	c2 08 61 ff 	ldub  [ %g1 + 0x1ff ], %g1                     
40003714:	82 18 60 aa 	xor  %g1, 0xaa, %g1                            
40003718:	80 a0 00 01 	cmp  %g0, %g1                                  
4000371c:	90 60 3f ff 	subx  %g0, -1, %o0                             
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  /* Check MBR signature */                                           
  if (!rtems_bdpart_is_valid_record( (*block)->buffer)) {             
    return RTEMS_IO_ERROR;                                            
40003720:	90 20 00 08 	neg  %o0                                       
40003724:	90 0a 3f e5 	and  %o0, -27, %o0                             
40003728:	90 02 20 1b 	add  %o0, 0x1b, %o0                            
  }                                                                   
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
4000372c:	b0 10 00 08 	mov  %o0, %i0                                  
40003730:	81 c7 e0 08 	ret                                            
40003734:	81 e8 00 00 	restore                                        
                                                                      

40003b88 <rtems_bdpart_register>: rtems_status_code rtems_bdpart_register( const char *disk_name, const rtems_bdpart_partition *pt, size_t count ) {
40003b88:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  rtems_blkdev_bnum disk_end = 0;                                     
  char *logical_disk_name = NULL;                                     
  char *logical_disk_marker = NULL;                                   
  size_t i = 0;                                                       
  int fd = -1;                                                        
40003b8c:	82 10 3f ff 	mov  -1, %g1                                   
  rtems_disk_device *dd = NULL;                                       
                                                                      
  /* Get disk data */                                                 
  sc = rtems_bdpart_get_disk_data( disk_name, &fd, &dd, &disk_end);   
40003b90:	90 10 00 18 	mov  %i0, %o0                                  
rtems_status_code rtems_bdpart_register(                              
  const char *disk_name,                                              
  const rtems_bdpart_partition *pt,                                   
  size_t count                                                        
)                                                                     
{                                                                     
40003b94:	b6 10 00 18 	mov  %i0, %i3                                  
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  rtems_blkdev_bnum disk_end = 0;                                     
40003b98:	c0 27 bf f0 	clr  [ %fp + -16 ]                             
  char *logical_disk_name = NULL;                                     
  char *logical_disk_marker = NULL;                                   
40003b9c:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
  size_t i = 0;                                                       
  int fd = -1;                                                        
40003ba0:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  rtems_disk_device *dd = NULL;                                       
40003ba4:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
  /* Get disk data */                                                 
  sc = rtems_bdpart_get_disk_data( disk_name, &fd, &dd, &disk_end);   
40003ba8:	92 07 bf f8 	add  %fp, -8, %o1                              
40003bac:	94 07 bf fc 	add  %fp, -4, %o2                              
40003bb0:	7f ff ff 21 	call  40003834 <rtems_bdpart_get_disk_data>    
40003bb4:	96 07 bf f0 	add  %fp, -16, %o3                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003bb8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40003bbc:	12 80 00 26 	bne  40003c54 <rtems_bdpart_register+0xcc>     <== NEVER TAKEN
40003bc0:	90 10 00 1b 	mov  %i3, %o0                                  
    return sc;                                                        
  }                                                                   
                                                                      
  /* Create logical disk name */                                      
  logical_disk_name = create_logical_disk_name(                       
40003bc4:	92 07 bf f4 	add  %fp, -12, %o1                             
40003bc8:	7f ff ff e1 	call  40003b4c <create_logical_disk_name>      
40003bcc:	21 10 00 98 	sethi  %hi(0x40026000), %l0                    
    disk_name,                                                        
    &logical_disk_marker                                              
  );                                                                  
  if (logical_disk_name == NULL) {                                    
40003bd0:	ba 10 20 00 	clr  %i5                                       
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
                                                                      
  /* Create logical disk name */                                      
  logical_disk_name = create_logical_disk_name(                       
40003bd4:	b0 10 00 08 	mov  %o0, %i0                                  
    disk_name,                                                        
    &logical_disk_marker                                              
  );                                                                  
  if (logical_disk_name == NULL) {                                    
40003bd8:	80 a2 20 00 	cmp  %o0, 0                                    
40003bdc:	12 80 00 0d 	bne  40003c10 <rtems_bdpart_register+0x88>     <== ALWAYS TAKEN
40003be0:	a0 14 22 30 	or  %l0, 0x230, %l0                            
40003be4:	10 80 00 17 	b  40003c40 <rtems_bdpart_register+0xb8>       
40003be8:	b8 10 20 00 	clr  %i4                                       
      esc = sc;                                                       
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Create logical disk */                                         
    sc = rtems_blkdev_create_partition(                               
40003bec:	d6 06 60 04 	ld  [ %i1 + 4 ], %o3                           
40003bf0:	90 10 00 18 	mov  %i0, %o0                                  
40003bf4:	92 10 00 1b 	mov  %i3, %o1                                  
40003bf8:	96 22 c0 0a 	sub  %o3, %o2, %o3                             
40003bfc:	40 00 02 44 	call  4000450c <rtems_blkdev_create_partition> 
40003c00:	b2 06 60 30 	add  %i1, 0x30, %i1                            
      logical_disk_name,                                              
      disk_name,                                                      
      p->begin,                                                       
      p->end - p->begin                                               
    );                                                                
    if (sc != RTEMS_SUCCESSFUL) {                                     
40003c04:	80 a2 20 00 	cmp  %o0, 0                                    
40003c08:	12 80 00 0e 	bne  40003c40 <rtems_bdpart_register+0xb8>     <== NEVER TAKEN
40003c0c:	b8 10 00 08 	mov  %o0, %i4                                  
    esc = sc;                                                         
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Create a logical disk for each partition */                      
  for (i = 0; i < count; ++i) {                                       
40003c10:	80 a7 40 1a 	cmp  %i5, %i2                                  
40003c14:	02 bf ff f4 	be  40003be4 <rtems_bdpart_register+0x5c>      
40003c18:	d0 07 bf f4 	ld  [ %fp + -12 ], %o0                         
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  int rv = 0;                                                         
                                                                      
  rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
40003c1c:	ba 07 60 01 	inc  %i5                                       
40003c20:	92 10 20 04 	mov  4, %o1                                    
40003c24:	94 10 00 10 	mov  %l0, %o2                                  
40003c28:	40 00 4a d2 	call  40016770 <snprintf>                      
40003c2c:	96 10 00 1d 	mov  %i5, %o3                                  
  if (rv >= RTEMS_BDPART_NUMBER_SIZE) {                               
40003c30:	80 a2 20 03 	cmp  %o0, 3                                    
40003c34:	24 bf ff ee 	ble,a   40003bec <rtems_bdpart_register+0x64>  <== ALWAYS TAKEN
40003c38:	d4 06 40 00 	ld  [ %i1 ], %o2                               
    sc = RTEMS_INVALID_NAME;                                          
40003c3c:	b8 10 20 03 	mov  3, %i4                                    <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
cleanup:                                                              
                                                                      
  free( logical_disk_name);                                           
40003c40:	40 00 09 c5 	call  40006354 <free>                          
40003c44:	90 10 00 18 	mov  %i0, %o0                                  
  close( fd);                                                         
40003c48:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
40003c4c:	40 00 09 9f 	call  400062c8 <close>                         
40003c50:	b0 10 00 1c 	mov  %i4, %i0                                  
                                                                      
  return esc;                                                         
40003c54:	81 c7 e0 08 	ret                                            
40003c58:	81 e8 00 00 	restore                                        
                                                                      

40003c5c <rtems_bdpart_register_from_disk>: } rtems_status_code rtems_bdpart_register_from_disk( const char *disk_name) {
40003c5c:	9d e3 bc 88 	save  %sp, -888, %sp                           
  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;                  
40003c60:	82 10 20 10 	mov  0x10, %g1                                 
                                                                      
  /* Read partitions */                                               
  sc = rtems_bdpart_read( disk_name, &format, pt, &count);            
40003c64:	90 10 00 18 	mov  %i0, %o0                                  
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;                  
40003c68:	c2 27 bc e8 	st  %g1, [ %fp + -792 ]                        
                                                                      
  /* Read partitions */                                               
  sc = rtems_bdpart_read( disk_name, &format, pt, &count);            
40003c6c:	92 07 bc ec 	add  %fp, -788, %o1                            
40003c70:	94 07 bd 00 	add  %fp, -768, %o2                            
40003c74:	7f ff ff 19 	call  400038d8 <rtems_bdpart_read>             
40003c78:	96 07 bc e8 	add  %fp, -792, %o3                            
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003c7c:	80 a2 20 00 	cmp  %o0, 0                                    
40003c80:	12 80 00 05 	bne  40003c94 <rtems_bdpart_register_from_disk+0x38><== NEVER TAKEN
40003c84:	d4 07 bc e8 	ld  [ %fp + -792 ], %o2                        
    return sc;                                                        
  }                                                                   
                                                                      
  /* Register partitions */                                           
  return rtems_bdpart_register( disk_name, pt, count);                
40003c88:	90 10 00 18 	mov  %i0, %o0                                  
40003c8c:	7f ff ff bf 	call  40003b88 <rtems_bdpart_register>         
40003c90:	92 07 bd 00 	add  %fp, -768, %o1                            
}                                                                     
40003c94:	81 c7 e0 08 	ret                                            
40003c98:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40003c9c <rtems_bdpart_unregister>: rtems_status_code rtems_bdpart_unregister( const char *disk_name, const rtems_bdpart_partition *pt __attribute__((unused)), size_t count ) {
40003c9c:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  rtems_blkdev_bnum disk_end = 0;                                     
  char *logical_disk_name = NULL;                                     
  char *logical_disk_marker = NULL;                                   
  size_t i = 0;                                                       
  int fd = -1;                                                        
40003ca0:	82 10 3f ff 	mov  -1, %g1                                   
  size_t count                                                        
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  rtems_blkdev_bnum disk_end = 0;                                     
40003ca4:	c0 27 bf f0 	clr  [ %fp + -16 ]                             
  char *logical_disk_name = NULL;                                     
  char *logical_disk_marker = NULL;                                   
40003ca8:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
  size_t i = 0;                                                       
  int fd = -1;                                                        
40003cac:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  rtems_disk_device *dd = NULL;                                       
40003cb0:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
  /* Get disk data */                                                 
  sc = rtems_bdpart_get_disk_data( disk_name, &fd, &dd, &disk_end);   
40003cb4:	90 10 00 18 	mov  %i0, %o0                                  
40003cb8:	92 07 bf f8 	add  %fp, -8, %o1                              
40003cbc:	94 07 bf fc 	add  %fp, -4, %o2                              
40003cc0:	7f ff fe dd 	call  40003834 <rtems_bdpart_get_disk_data>    
40003cc4:	96 07 bf f0 	add  %fp, -16, %o3                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003cc8:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40003ccc:	32 80 00 23 	bne,a   40003d58 <rtems_bdpart_unregister+0xbc><== NEVER TAKEN
40003cd0:	b0 10 00 1c 	mov  %i4, %i0                                  <== NOT EXECUTED
    return sc;                                                        
  }                                                                   
                                                                      
  /* Create logical disk name */                                      
  logical_disk_name = create_logical_disk_name(                       
40003cd4:	90 10 00 18 	mov  %i0, %o0                                  
40003cd8:	92 07 bf f4 	add  %fp, -12, %o1                             
40003cdc:	7f ff ff 9c 	call  40003b4c <create_logical_disk_name>      
40003ce0:	33 10 00 98 	sethi  %hi(0x40026000), %i1                    
    disk_name,                                                        
    &logical_disk_marker                                              
  );                                                                  
  if (logical_disk_name == NULL) {                                    
40003ce4:	ba 10 20 00 	clr  %i5                                       
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
                                                                      
  /* Create logical disk name */                                      
  logical_disk_name = create_logical_disk_name(                       
40003ce8:	b6 10 00 08 	mov  %o0, %i3                                  
    disk_name,                                                        
    &logical_disk_marker                                              
  );                                                                  
  if (logical_disk_name == NULL) {                                    
40003cec:	80 a2 20 00 	cmp  %o0, 0                                    
40003cf0:	02 80 00 0e 	be  40003d28 <rtems_bdpart_unregister+0x8c>    <== NEVER TAKEN
40003cf4:	b2 16 62 30 	or  %i1, 0x230, %i1                            
    esc = sc;                                                         
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Delete the logical disk for each partition */                    
  for (i = 0; i < count; ++i) {                                       
40003cf8:	80 a7 40 1a 	cmp  %i5, %i2                                  
40003cfc:	02 80 00 0b 	be  40003d28 <rtems_bdpart_unregister+0x8c>    
40003d00:	d0 07 bf f4 	ld  [ %fp + -12 ], %o0                         
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  int rv = 0;                                                         
                                                                      
  rv = snprintf( logical_disk_marker, RTEMS_BDPART_NUMBER_SIZE, "%zu", i + 1);
40003d04:	ba 07 60 01 	inc  %i5                                       
40003d08:	92 10 20 04 	mov  4, %o1                                    
40003d0c:	94 10 00 19 	mov  %i1, %o2                                  
40003d10:	40 00 4a 98 	call  40016770 <snprintf>                      
40003d14:	96 10 00 1d 	mov  %i5, %o3                                  
  if (rv >= RTEMS_BDPART_NUMBER_SIZE) {                               
40003d18:	80 a2 20 03 	cmp  %o0, 3                                    
40003d1c:	04 80 00 09 	ble  40003d40 <rtems_bdpart_unregister+0xa4>   <== ALWAYS TAKEN
40003d20:	01 00 00 00 	nop                                            
    sc = RTEMS_INVALID_NAME;                                          
40003d24:	b8 10 20 03 	mov  3, %i4	! 3 <_TLS_Alignment+0x2>           <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
cleanup:                                                              
                                                                      
  free( logical_disk_name);                                           
40003d28:	40 00 09 8b 	call  40006354 <free>                          
40003d2c:	90 10 00 1b 	mov  %i3, %o0                                  
  close( fd);                                                         
40003d30:	40 00 09 66 	call  400062c8 <close>                         
40003d34:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
                                                                      
  return esc;                                                         
40003d38:	81 c7 e0 08 	ret                                            
40003d3c:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
      esc = sc;                                                       
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Delete logical disk */                                         
    rv = unlink( logical_disk_name);                                  
40003d40:	40 00 17 8c 	call  40009b70 <unlink>                        
40003d44:	90 10 00 1b 	mov  %i3, %o0                                  
    if (rv != 0) {                                                    
40003d48:	80 a2 20 00 	cmp  %o0, 0                                    
40003d4c:	02 bf ff ec 	be  40003cfc <rtems_bdpart_unregister+0x60>    <== ALWAYS TAKEN
40003d50:	80 a7 40 1a 	cmp  %i5, %i2                                  
40003d54:	30 bf ff f5 	b,a   40003d28 <rtems_bdpart_unregister+0x8c>  <== NOT EXECUTED
                                                                      
  free( logical_disk_name);                                           
  close( fd);                                                         
                                                                      
  return esc;                                                         
}                                                                     
40003d58:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003d5c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40003e44 <rtems_bdpart_write>: const char *disk_name, const rtems_bdpart_format *format, const rtems_bdpart_partition *pt, size_t count ) {
40003e44:	9d e3 bf 88 	save  %sp, -120, %sp                           
  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;                                 
40003e48:	80 a6 60 00 	cmp  %i1, 0                                    
40003e4c:	02 80 00 08 	be  40003e6c <rtems_bdpart_write+0x28>         <== NEVER TAKEN
40003e50:	90 10 00 18 	mov  %i0, %o0                                  
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_status_code esc = RTEMS_SUCCESSFUL;                           
  bool dos_compatibility = format != NULL                             
    && format->type == RTEMS_BDPART_FORMAT_MBR                        
40003e54:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40003e58:	80 a0 60 00 	cmp  %g1, 0                                    
40003e5c:	12 80 00 05 	bne  40003e70 <rtems_bdpart_write+0x2c>        <== NEVER TAKEN
40003e60:	a0 10 20 00 	clr  %l0                                       
40003e64:	10 80 00 03 	b  40003e70 <rtems_bdpart_write+0x2c>          
40003e68:	e0 0e 60 08 	ldub  [ %i1 + 8 ], %l0                         
    && format->mbr.dos_compatibility;                                 
40003e6c:	a0 10 20 00 	clr  %l0                                       <== NOT EXECUTED
  rtems_bdbuf_buffer *block = NULL;                                   
  rtems_blkdev_bnum disk_end = 0;                                     
  rtems_blkdev_bnum record_space =                                    
40003e70:	a0 0c 20 01 	and  %l0, 1, %l0                               
    dos_compatibility ? RTEMS_BDPART_MBR_CYLINDER_SIZE : 1;           
  size_t ppc = 0; /* Primary partition count */                       
  size_t i = 0;                                                       
  uint8_t *data = NULL;                                               
  int fd = -1;                                                        
40003e74:	82 10 3f ff 	mov  -1, %g1                                   
  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;                                     
  rtems_blkdev_bnum record_space =                                    
40003e78:	80 a0 00 10 	cmp  %g0, %l0                                  
  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;                                 
  rtems_bdbuf_buffer *block = NULL;                                   
40003e7c:	c0 27 bf f0 	clr  [ %fp + -16 ]                             
  rtems_blkdev_bnum disk_end = 0;                                     
40003e80:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
  rtems_blkdev_bnum record_space =                                    
    dos_compatibility ? RTEMS_BDPART_MBR_CYLINDER_SIZE : 1;           
  size_t ppc = 0; /* Primary partition count */                       
  size_t i = 0;                                                       
  uint8_t *data = NULL;                                               
  int fd = -1;                                                        
40003e84:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  rtems_disk_device *dd = NULL;                                       
40003e88:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
  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;                                     
  rtems_blkdev_bnum record_space =                                    
40003e8c:	ba 40 3f ff 	addx  %g0, -1, %i5                             
  rtems_disk_device *dd = NULL;                                       
                                                                      
  /* Check if we have something to do */                              
  if (count == 0) {                                                   
    /* Nothing to do */                                               
    return RTEMS_SUCCESSFUL;                                          
40003e90:	b0 10 20 00 	clr  %i0                                       
  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;                                     
  rtems_blkdev_bnum record_space =                                    
40003e94:	ba 0f 7f c2 	and  %i5, -62, %i5                             
  uint8_t *data = NULL;                                               
  int fd = -1;                                                        
  rtems_disk_device *dd = NULL;                                       
                                                                      
  /* Check if we have something to do */                              
  if (count == 0) {                                                   
40003e98:	80 a6 e0 00 	cmp  %i3, 0                                    
40003e9c:	02 80 00 c8 	be  400041bc <rtems_bdpart_write+0x378>        <== NEVER TAKEN
40003ea0:	ba 07 60 3f 	add  %i5, 0x3f, %i5                            
    /* Nothing to do */                                               
    return RTEMS_SUCCESSFUL;                                          
  }                                                                   
                                                                      
  /* Check parameter */                                               
  if (format == NULL || pt == NULL) {                                 
40003ea4:	80 a6 60 00 	cmp  %i1, 0                                    
40003ea8:	02 80 00 c5 	be  400041bc <rtems_bdpart_write+0x378>        <== NEVER TAKEN
40003eac:	b0 10 20 09 	mov  9, %i0                                    
40003eb0:	80 a6 a0 00 	cmp  %i2, 0                                    
40003eb4:	02 80 00 c2 	be  400041bc <rtems_bdpart_write+0x378>        <== NEVER TAKEN
40003eb8:	92 07 bf f8 	add  %fp, -8, %o1                              
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  /* Get disk data */                                                 
  sc = rtems_bdpart_get_disk_data( disk_name, &fd, &dd, &disk_end);   
40003ebc:	94 07 bf fc 	add  %fp, -4, %o2                              
40003ec0:	7f ff fe 5d 	call  40003834 <rtems_bdpart_get_disk_data>    
40003ec4:	96 07 bf f4 	add  %fp, -12, %o3                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003ec8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40003ecc:	12 80 00 bc 	bne  400041bc <rtems_bdpart_write+0x378>       <== NEVER TAKEN
40003ed0:	80 a4 20 00 	cmp  %l0, 0                                    
    return sc;                                                        
  }                                                                   
                                                                      
  /* Align end of disk on cylinder boundary if necessary */           
  if (dos_compatibility) {                                            
40003ed4:	02 80 00 09 	be  40003ef8 <rtems_bdpart_write+0xb4>         <== NEVER TAKEN
40003ed8:	c8 07 bf f4 	ld  [ %fp + -12 ], %g4                         
    disk_end -= (disk_end % record_space);                            
40003edc:	f8 07 bf f4 	ld  [ %fp + -12 ], %i4                         
40003ee0:	92 10 00 1d 	mov  %i5, %o1                                  
40003ee4:	40 00 7b ca 	call  40022e0c <.urem>                         
40003ee8:	90 10 00 1c 	mov  %i4, %o0                                  
40003eec:	90 27 00 08 	sub  %i4, %o0, %o0                             
40003ef0:	d0 27 bf f4 	st  %o0, [ %fp + -12 ]                         
  /* 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) {                  
40003ef4:	c8 07 bf f4 	ld  [ %fp + -12 ], %g4                         
40003ef8:	82 10 00 1a 	mov  %i2, %g1                                  
  if (dos_compatibility) {                                            
    disk_end -= (disk_end % record_space);                            
  }                                                                   
                                                                      
  /* Check that we have a consistent partition table */               
  for (i = 0; i < count; ++i) {                                       
40003efc:	84 10 20 00 	clr  %g2                                       
    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) {                  
40003f00:	c6 00 40 00 	ld  [ %g1 ], %g3                               
40003f04:	80 a0 c0 04 	cmp  %g3, %g4                                  
40003f08:	3a 80 00 a1 	bcc,a   4000418c <rtems_bdpart_write+0x348>    <== NEVER TAKEN
40003f0c:	b0 10 20 0a 	mov  0xa, %i0                                  <== NOT EXECUTED
40003f10:	f8 00 60 04 	ld  [ %g1 + 4 ], %i4                           
40003f14:	80 a7 00 04 	cmp  %i4, %g4                                  
40003f18:	18 80 00 9a 	bgu  40004180 <rtems_bdpart_write+0x33c>       <== NEVER TAKEN
40003f1c:	80 a0 c0 1c 	cmp  %g3, %i4                                  
      esc = RTEMS_INVALID_NUMBER;                                     
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Check that begin and end are valid */                          
    if (p->begin >= p->end) {                                         
40003f20:	1a 80 00 98 	bcc  40004180 <rtems_bdpart_write+0x33c>       <== NEVER TAKEN
40003f24:	80 a0 a0 00 	cmp  %g2, 0                                    
      esc = RTEMS_INVALID_NUMBER;                                     
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Check that partitions do not overlap */                        
    if (i > 0 && pt [i - 1].end > p->begin) {                         
40003f28:	02 80 00 06 	be  40003f40 <rtems_bdpart_write+0xfc>         
40003f2c:	84 00 a0 01 	inc  %g2                                       
40003f30:	f8 00 7f d4 	ld  [ %g1 + -44 ], %i4                         
40003f34:	80 a7 00 03 	cmp  %i4, %g3                                  
40003f38:	38 80 00 95 	bgu,a   4000418c <rtems_bdpart_write+0x348>    <== NEVER TAKEN
40003f3c:	b0 10 20 0a 	mov  0xa, %i0                                  <== 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) {                                       
40003f40:	80 a0 80 1b 	cmp  %g2, %i3                                  
40003f44:	12 bf ff ef 	bne  40003f00 <rtems_bdpart_write+0xbc>        
40003f48:	82 00 60 30 	add  %g1, 0x30, %g1                            
      goto cleanup;                                                   
    }                                                                 
  }                                                                   
                                                                      
  /* Check format */                                                  
  if (format->type != RTEMS_BDPART_FORMAT_MBR) {                      
40003f4c:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40003f50:	80 a0 60 00 	cmp  %g1, 0                                    
40003f54:	12 80 00 8e 	bne  4000418c <rtems_bdpart_write+0x348>       <== NEVER TAKEN
40003f58:	b0 10 20 18 	mov  0x18, %i0                                 
   * 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;                                       
40003f5c:	80 a6 e0 04 	cmp  %i3, 4                                    
40003f60:	08 80 00 03 	bleu  40003f6c <rtems_bdpart_write+0x128>      <== NEVER TAKEN
40003f64:	b8 10 00 1b 	mov  %i3, %i4                                  
40003f68:	b8 10 20 03 	mov  3, %i4                                    
                                                                      
  /*                                                                  
   * 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) {
40003f6c:	80 a4 20 00 	cmp  %l0, 0                                    
40003f70:	32 80 00 09 	bne,a   40003f94 <rtems_bdpart_write+0x150>    <== ALWAYS TAKEN
40003f74:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40003f78:	a7 2f 20 04 	sll  %i4, 4, %l3                               <== NOT EXECUTED
40003f7c:	a5 2f 20 06 	sll  %i4, 6, %l2                               
   * 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;                                       
40003f80:	84 10 00 1c 	mov  %i4, %g2                                  
40003f84:	a4 24 80 13 	sub  %l2, %l3, %l2                             
40003f88:	82 10 20 00 	clr  %g1                                       
40003f8c:	10 80 00 0e 	b  40003fc4 <rtems_bdpart_write+0x180>         
40003f90:	a2 06 80 12 	add  %i2, %l2, %l1                             
                                                                      
  /*                                                                  
   * 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) {
40003f94:	80 a0 60 3f 	cmp  %g1, 0x3f                                 
40003f98:	12 80 00 7d 	bne  4000418c <rtems_bdpart_write+0x348>       <== NEVER TAKEN
40003f9c:	b0 10 20 0a 	mov  0xa, %i0                                  
40003fa0:	10 bf ff f7 	b  40003f7c <rtems_bdpart_write+0x138>         
40003fa4:	a7 2f 20 04 	sll  %i4, 4, %l3                               
   * 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) {                                     
    if ((pt [i].begin - pt [i - 1].end) < record_space) {             
40003fa8:	c8 04 40 01 	ld  [ %l1 + %g1 ], %g4                         
40003fac:	c6 00 ff d4 	ld  [ %g3 + -44 ], %g3                         
40003fb0:	86 21 00 03 	sub  %g4, %g3, %g3                             
40003fb4:	80 a0 c0 1d 	cmp  %g3, %i5                                  
40003fb8:	0a 80 00 72 	bcs  40004180 <rtems_bdpart_write+0x33c>       <== NEVER TAKEN
40003fbc:	82 00 60 30 	add  %g1, 0x30, %g1                            
   * 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) {                                     
40003fc0:	84 00 a0 01 	inc  %g2                                       
40003fc4:	80 a0 80 1b 	cmp  %g2, %i3                                  
40003fc8:	0a bf ff f8 	bcs  40003fa8 <rtems_bdpart_write+0x164>       
40003fcc:	86 04 40 01 	add  %l1, %g1, %g3                             
40003fd0:	b0 06 a0 08 	add  %i2, 8, %i0                               
40003fd4:	a0 10 20 00 	clr  %l0                                       
    }                                                                 
  }                                                                   
                                                                      
  /* Check that we can convert the parition descriptions to the MBR format */
  for (i = 0; i < count; ++i) {                                       
    uint8_t type = 0;                                                 
40003fd8:	c0 2f bf ef 	clrb  [ %fp + -17 ]                            
                                                                      
    const rtems_bdpart_partition *p = pt + i;                         
                                                                      
    /* Check type */                                                  
    if (!rtems_bdpart_to_mbr_partition_type( p->type, &type)) {       
40003fdc:	90 10 00 18 	mov  %i0, %o0                                  
40003fe0:	7f ff fe 09 	call  40003804 <rtems_bdpart_to_mbr_partition_type>
40003fe4:	92 07 bf ef 	add  %fp, -17, %o1                             
40003fe8:	80 a2 20 00 	cmp  %o0, 0                                    
40003fec:	22 80 00 68 	be,a   4000418c <rtems_bdpart_write+0x348>     <== NEVER TAKEN
40003ff0:	b0 10 20 04 	mov  4, %i0                                    <== NOT EXECUTED
40003ff4:	b0 06 20 30 	add  %i0, 0x30, %i0                            
      esc =  RTEMS_INVALID_ID;                                        
      goto cleanup;                                                   
    }                                                                 
                                                                      
    /* Check flags */                                                 
    if (p->flags > 0xffU) {                                           
40003ff8:	c2 06 3f f0 	ld  [ %i0 + -16 ], %g1                         
40003ffc:	80 a0 60 00 	cmp  %g1, 0                                    
40004000:	32 80 00 63 	bne,a   4000418c <rtems_bdpart_write+0x348>    <== NEVER TAKEN
40004004:	b0 10 20 04 	mov  4, %i0                                    <== NOT EXECUTED
40004008:	c2 06 3f f4 	ld  [ %i0 + -12 ], %g1                         
4000400c:	80 a0 60 ff 	cmp  %g1, 0xff                                 
40004010:	18 80 00 07 	bgu  4000402c <rtems_bdpart_write+0x1e8>       <== NEVER TAKEN
40004014:	a0 04 20 01 	inc  %l0                                       
      goto cleanup;                                                   
    }                                                                 
  }                                                                   
                                                                      
  /* Check that we can convert the parition descriptions to the MBR format */
  for (i = 0; i < count; ++i) {                                       
40004018:	80 a4 00 1b 	cmp  %l0, %i3                                  
4000401c:	32 bf ff f0 	bne,a   40003fdc <rtems_bdpart_write+0x198>    
40004020:	c0 2f bf ef 	clrb  [ %fp + -17 ]                            
    /* Check ID */                                                    
    /* TODO */                                                        
  }                                                                   
                                                                      
  /* New MBR */                                                       
  sc = rtems_bdpart_new_record( dd, 0, &block);                       
40004024:	10 80 00 04 	b  40004034 <rtems_bdpart_write+0x1f0>         
40004028:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
    const rtems_bdpart_partition *p = pt + i;                         
                                                                      
    /* Check type */                                                  
    if (!rtems_bdpart_to_mbr_partition_type( p->type, &type)) {       
      esc =  RTEMS_INVALID_ID;                                        
      goto cleanup;                                                   
4000402c:	10 80 00 58 	b  4000418c <rtems_bdpart_write+0x348>         <== NOT EXECUTED
40004030:	b0 10 20 04 	mov  4, %i0                                    <== NOT EXECUTED
    /* Check ID */                                                    
    /* TODO */                                                        
  }                                                                   
                                                                      
  /* New MBR */                                                       
  sc = rtems_bdpart_new_record( dd, 0, &block);                       
40004034:	92 10 20 00 	clr  %o1                                       
40004038:	7f ff ff 4a 	call  40003d60 <rtems_bdpart_new_record>       
4000403c:	94 07 bf f0 	add  %fp, -16, %o2                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
40004040:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40004044:	12 80 00 53 	bne  40004190 <rtems_bdpart_write+0x34c>       <== NEVER TAKEN
40004048:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
  }                                                                   
                                                                      
  /* Write disk ID */                                                 
  rtems_uint32_to_little_endian(                                      
    format->mbr.disk_id,                                              
    block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID                   
4000404c:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
    esc = sc;                                                         
    goto cleanup;                                                     
  }                                                                   
                                                                      
  /* Write disk ID */                                                 
  rtems_uint32_to_little_endian(                                      
40004050:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           
    format->mbr.disk_id,                                              
    block->buffer + RTEMS_BDPART_MBR_OFFSET_DISK_ID                   
40004054:	c8 00 60 1c 	ld  [ %g1 + 0x1c ], %g4                        
40004058:	82 10 20 00 	clr  %g1                                       
4000405c:	86 01 00 01 	add  %g4, %g1, %g3                             
    data [i] = (uint8_t) value;                                       
40004060:	c4 28 e1 b8 	stb  %g2, [ %g3 + 0x1b8 ]                      
                                                                      
static inline void rtems_uint32_to_little_endian( uint32_t value, uint8_t *data)
{                                                                     
  size_t i = 0;                                                       
                                                                      
  for (i = 0; i < 4; ++i) {                                           
40004064:	82 00 60 01 	inc  %g1                                       
40004068:	80 a0 60 04 	cmp  %g1, 4                                    
4000406c:	12 bf ff fc 	bne  4000405c <rtems_bdpart_write+0x218>       
40004070:	85 30 a0 08 	srl  %g2, 8, %g2                               
  );                                                                  
                                                                      
  /* Write primary partition table */                                 
  data = block->buffer + RTEMS_BDPART_MBR_OFFSET_TABLE_0;             
40004074:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
  for (i = 0; i < ppc; ++i) {                                         
40004078:	b2 10 00 1a 	mov  %i2, %i1                                  
    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;             
4000407c:	ea 00 60 1c 	ld  [ %g1 + 0x1c ], %l5                        
  for (i = 0; i < ppc; ++i) {                                         
40004080:	a0 10 20 00 	clr  %l0                                       
    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;             
40004084:	aa 05 61 be 	add  %l5, 0x1be, %l5                           
40004088:	a8 10 00 15 	mov  %l5, %l4                                  
  for (i = 0; i < ppc; ++i) {                                         
4000408c:	80 a4 00 1c 	cmp  %l0, %i4                                  
40004090:	02 80 00 0d 	be  400040c4 <rtems_bdpart_write+0x280>        
40004094:	80 a7 00 1b 	cmp  %i4, %i3                                  
                                                                      
    /* Write partition entry */                                       
    rtems_bdpart_write_mbr_partition(                                 
      data,                                                           
      p->begin,                                                       
      p->end - p->begin,                                              
40004098:	d2 06 40 00 	ld  [ %i1 ], %o1                               
  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(                                 
4000409c:	d4 06 60 04 	ld  [ %i1 + 4 ], %o2                           
400040a0:	d6 0e 60 08 	ldub  [ %i1 + 8 ], %o3                         
400040a4:	d8 0e 60 2f 	ldub  [ %i1 + 0x2f ], %o4                      
400040a8:	90 10 00 14 	mov  %l4, %o0                                  
400040ac:	94 22 80 09 	sub  %o2, %o1, %o2                             
400040b0:	7f ff ff 54 	call  40003e00 <rtems_bdpart_write_mbr_partition>
400040b4:	a8 05 20 10 	add  %l4, 0x10, %l4                            
    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) {                                         
400040b8:	a0 04 20 01 	inc  %l0                                       
400040bc:	10 bf ff f4 	b  4000408c <rtems_bdpart_write+0x248>         
400040c0:	b2 06 60 30 	add  %i1, 0x30, %i1                            
                                                                      
    data += RTEMS_BDPART_MBR_TABLE_ENTRY_SIZE;                        
  }                                                                   
                                                                      
  /* Write extended partition with logical partitions if necessary */ 
  if (ppc != count) {                                                 
400040c4:	02 80 00 32 	be  4000418c <rtems_bdpart_write+0x348>        <== NEVER TAKEN
400040c8:	90 05 40 13 	add  %l5, %l3, %o0                             
    rtems_blkdev_bnum ebr = 0; /* Extended boot record block index */ 
                                                                      
    /* Begin of extended partition */                                 
    rtems_blkdev_bnum ep_begin = pt [ppc].begin - record_space;       
400040cc:	e0 06 80 12 	ld  [ %i2 + %l2 ], %l0                         
                                                                      
    /* Write extended partition */                                    
    rtems_bdpart_write_mbr_partition(                                 
400040d0:	d4 07 bf f4 	ld  [ %fp + -12 ], %o2                         
  /* 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;       
400040d4:	a0 24 00 1d 	sub  %l0, %i5, %l0                             
                                                                      
    /* Write extended partition */                                    
    rtems_bdpart_write_mbr_partition(                                 
400040d8:	96 10 20 05 	mov  5, %o3                                    
400040dc:	92 10 00 10 	mov  %l0, %o1                                  
400040e0:	94 22 80 10 	sub  %o2, %l0, %o2                             
400040e4:	98 10 20 00 	clr  %o4                                       
400040e8:	7f ff ff 46 	call  40003e00 <rtems_bdpart_write_mbr_partition>
400040ec:	b4 10 00 11 	mov  %l1, %i2                                  
      RTEMS_BDPART_MBR_EXTENDED,                                      
      0                                                               
    );                                                                
                                                                      
    /* Write logical partitions */                                    
    for (i = ppc; i < count; ++i) {                                   
400040f0:	b2 10 00 1c 	mov  %i4, %i1                                  
400040f4:	80 a6 40 1b 	cmp  %i1, %i3                                  
400040f8:	1a 80 00 25 	bcc  4000418c <rtems_bdpart_write+0x348>       
400040fc:	80 a6 40 1c 	cmp  %i1, %i4                                  
      const rtems_bdpart_partition *p = pt + i;                       
                                                                      
      /* Write second partition entry */                              
      if (i > ppc) {                                                  
40004100:	08 80 00 0c 	bleu  40004130 <rtems_bdpart_write+0x2ec>      
40004104:	c4 07 bf f0 	ld  [ %fp + -16 ], %g2                         
        rtems_blkdev_bnum begin = p->begin - record_space;            
40004108:	c2 06 80 00 	ld  [ %i2 ], %g1                               
                                                                      
        rtems_bdpart_write_mbr_partition(                             
4000410c:	d0 00 a0 1c 	ld  [ %g2 + 0x1c ], %o0                        
40004110:	d4 07 bf f4 	ld  [ %fp + -12 ], %o2                         
    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;            
40004114:	82 20 40 1d 	sub  %g1, %i5, %g1                             
                                                                      
        rtems_bdpart_write_mbr_partition(                             
40004118:	90 02 21 ce 	add  %o0, 0x1ce, %o0                           
4000411c:	92 20 40 10 	sub  %g1, %l0, %o1                             
40004120:	94 22 80 01 	sub  %o2, %g1, %o2                             
40004124:	96 10 20 05 	mov  5, %o3                                    
40004128:	7f ff ff 36 	call  40003e00 <rtems_bdpart_write_mbr_partition>
4000412c:	98 10 20 00 	clr  %o4                                       
          0                                                           
        );                                                            
      }                                                               
                                                                      
      /* New EBR */                                                   
      ebr = p->begin - record_space;                                  
40004130:	d2 06 80 00 	ld  [ %i2 ], %o1                               
      sc = rtems_bdpart_new_record( dd, ebr, &block);                 
40004134:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
40004138:	92 22 40 1d 	sub  %o1, %i5, %o1                             
4000413c:	7f ff ff 09 	call  40003d60 <rtems_bdpart_new_record>       
40004140:	94 07 bf f0 	add  %fp, -16, %o2                             
      if (sc != RTEMS_SUCCESSFUL) {                                   
40004144:	80 a2 20 00 	cmp  %o0, 0                                    
40004148:	12 80 00 10 	bne  40004188 <rtems_bdpart_write+0x344>       <== NEVER TAKEN
4000414c:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
        esc = sc;                                                     
        goto cleanup;                                                 
      }                                                               
                                                                      
      /* Write first partition entry */                               
      rtems_bdpart_write_mbr_partition(                               
40004150:	d4 06 a0 04 	ld  [ %i2 + 4 ], %o2                           
40004154:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40004158:	d6 0e a0 08 	ldub  [ %i2 + 8 ], %o3                         
4000415c:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40004160:	d8 0e a0 2f 	ldub  [ %i2 + 0x2f ], %o4                      
40004164:	90 02 21 be 	add  %o0, 0x1be, %o0                           
40004168:	92 10 00 1d 	mov  %i5, %o1                                  
4000416c:	94 22 80 01 	sub  %o2, %g1, %o2                             
40004170:	7f ff ff 24 	call  40003e00 <rtems_bdpart_write_mbr_partition>
40004174:	b2 06 60 01 	inc  %i1                                       
40004178:	10 bf ff df 	b  400040f4 <rtems_bdpart_write+0x2b0>         
4000417c:	b4 06 a0 30 	add  %i2, 0x30, %i2                            
  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) {                  
      esc = RTEMS_INVALID_NUMBER;                                     
40004180:	10 80 00 03 	b  4000418c <rtems_bdpart_write+0x348>         <== NOT EXECUTED
40004184:	b0 10 20 0a 	mov  0xa, %i0                                  <== NOT EXECUTED
        );                                                            
      }                                                               
                                                                      
      /* New EBR */                                                   
      ebr = p->begin - record_space;                                  
      sc = rtems_bdpart_new_record( dd, ebr, &block);                 
40004188:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
cleanup:                                                              
                                                                      
  if (fd >= 0) {                                                      
4000418c:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
40004190:	80 a2 20 00 	cmp  %o0, 0                                    
40004194:	26 80 00 05 	bl,a   400041a8 <rtems_bdpart_write+0x364>     <== NEVER TAKEN
40004198:	d0 07 bf f0 	ld  [ %fp + -16 ], %o0                         <== NOT EXECUTED
    close( fd);                                                       
4000419c:	40 00 08 4b 	call  400062c8 <close>                         
400041a0:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  if (block != NULL) {                                                
400041a4:	d0 07 bf f0 	ld  [ %fp + -16 ], %o0                         
400041a8:	80 a2 20 00 	cmp  %o0, 0                                    
400041ac:	02 80 00 06 	be  400041c4 <rtems_bdpart_write+0x380>        <== NEVER TAKEN
400041b0:	01 00 00 00 	nop                                            
    rtems_bdbuf_sync( block);                                         
400041b4:	40 00 33 40 	call  40010eb4 <rtems_bdbuf_sync>              
400041b8:	01 00 00 00 	nop                                            
400041bc:	81 c7 e0 08 	ret                                            
400041c0:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return esc;                                                         
}                                                                     
400041c4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400041c8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000407c <rtems_blkdev_create_partition>: const char *partition, const char *parent_block_device, rtems_blkdev_bnum media_block_begin, rtems_blkdev_bnum media_block_count ) {
4000407c:	9d e3 bf 50 	save  %sp, -176, %sp                           
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  int fd = open(parent_block_device, O_RDWR);                         
40004080:	92 10 20 02 	mov  2, %o1                                    
40004084:	90 10 00 19 	mov  %i1, %o0                                  
40004088:	40 00 07 07 	call  40005ca4 <open>                          
4000408c:	ba 10 20 04 	mov  4, %i5                                    
                                                                      
  if (fd >= 0) {                                                      
40004090:	80 a2 20 00 	cmp  %o0, 0                                    
40004094:	06 80 00 33 	bl  40004160 <rtems_blkdev_create_partition+0xe4>
40004098:	b2 10 00 08 	mov  %o0, %i1                                  
    int rv;                                                           
    struct stat st;                                                   
                                                                      
    rv = fstat(fd, &st);                                              
4000409c:	40 00 04 07 	call  400050b8 <fstat>                         
400040a0:	92 07 bf b8 	add  %fp, -72, %o1                             
    if (rv == 0 && S_ISBLK(st.st_mode)) {                             
400040a4:	80 a2 20 00 	cmp  %o0, 0                                    
400040a8:	12 80 00 2c 	bne  40004158 <rtems_blkdev_create_partition+0xdc><== NEVER TAKEN
400040ac:	ba 10 20 15 	mov  0x15, %i5                                 
400040b0:	e0 07 bf c4 	ld  [ %fp + -60 ], %l0                         
400040b4:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
400040b8:	a0 0c 00 01 	and  %l0, %g1, %l0                             
400040bc:	03 00 00 18 	sethi  %hi(0x6000), %g1                        
400040c0:	80 a4 00 01 	cmp  %l0, %g1                                  
400040c4:	12 80 00 25 	bne  40004158 <rtems_blkdev_create_partition+0xdc>
400040c8:	90 10 00 19 	mov  %i1, %o0                                  
static inline int rtems_disk_fd_get_disk_device(                      
  int fd,                                                             
  rtems_disk_device **dd_ptr                                          
)                                                                     
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_GETDISKDEV, dd_ptr);                   
400040cc:	13 10 01 10 	sethi  %hi(0x40044000), %o1                    
400040d0:	94 07 bf b4 	add  %fp, -76, %o2                             
400040d4:	92 12 62 09 	or  %o1, 0x209, %o1                            
400040d8:	40 00 04 48 	call  400051f8 <ioctl>                         
400040dc:	ba 10 20 18 	mov  0x18, %i5                                 
      rtems_disk_device *phys_dd;                                     
                                                                      
      rv = rtems_disk_fd_get_disk_device(fd, &phys_dd);               
      if (rv == 0) {                                                  
400040e0:	80 a2 20 00 	cmp  %o0, 0                                    
400040e4:	12 80 00 1d 	bne  40004158 <rtems_blkdev_create_partition+0xdc>
400040e8:	01 00 00 00 	nop                                            
        rtems_blkdev_imfs_context *ctx = malloc(sizeof(*ctx));        
400040ec:	40 00 05 55 	call  40005640 <malloc>                        
400040f0:	90 10 20 80 	mov  0x80, %o0	! 80 <_TLS_Alignment+0x7f>      
                                                                      
        if (ctx != NULL) {                                            
400040f4:	b8 92 20 00 	orcc  %o0, 0, %i4                              
400040f8:	02 80 00 17 	be  40004154 <rtems_blkdev_create_partition+0xd8>
400040fc:	d2 07 bf b4 	ld  [ %fp + -76 ], %o1                         
          sc = rtems_disk_init_log(                                   
40004100:	94 10 00 1a 	mov  %i2, %o2                                  
40004104:	40 00 00 cb 	call  40004430 <rtems_disk_init_log>           
40004108:	96 10 00 1b 	mov  %i3, %o3                                  
            phys_dd,                                                  
            media_block_begin,                                        
            media_block_count                                         
          );                                                          
                                                                      
          if (sc == RTEMS_SUCCESSFUL) {                               
4000410c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40004110:	12 80 00 0e 	bne  40004148 <rtems_blkdev_create_partition+0xcc>
40004114:	90 10 00 18 	mov  %i0, %o0                                  
            ctx->fd = fd;                                             
40004118:	f2 27 20 78 	st  %i1, [ %i4 + 0x78 ]                        
                                                                      
            rv = IMFS_make_generic_node(                              
4000411c:	92 14 21 ff 	or  %l0, 0x1ff, %o1                            
40004120:	15 10 00 69 	sethi  %hi(0x4001a400), %o2                    
40004124:	96 10 00 1c 	mov  %i4, %o3                                  
40004128:	40 00 01 fe 	call  40004920 <IMFS_make_generic_node>        
4000412c:	94 12 a2 f0 	or  %o2, 0x2f0, %o2                            
              S_IFBLK | S_IRWXU | S_IRWXG | S_IRWXO,                  
              &rtems_blkdev_imfs_control,                             
              ctx                                                     
            );                                                        
                                                                      
            if (rv != 0) {                                            
40004130:	80 a2 20 00 	cmp  %o0, 0                                    
40004134:	02 80 00 0b 	be  40004160 <rtems_blkdev_create_partition+0xe4>
40004138:	90 10 00 1c 	mov  %i4, %o0                                  
              free(ctx);                                              
4000413c:	40 00 03 b5 	call  40005010 <free>                          
40004140:	ba 10 20 0d 	mov  0xd, %i5                                  
40004144:	30 80 00 05 	b,a   40004158 <rtems_blkdev_create_partition+0xdc>
              sc = RTEMS_UNSATISFIED;                                 
            }                                                         
          } else {                                                    
            free(ctx);                                                
40004148:	40 00 03 b2 	call  40005010 <free>                          
4000414c:	90 10 00 1c 	mov  %i4, %o0                                  
40004150:	30 80 00 02 	b,a   40004158 <rtems_blkdev_create_partition+0xdc>
40004154:	ba 10 20 1a 	mov  0x1a, %i5                                 
    } else {                                                          
      sc = RTEMS_INVALID_NODE;                                        
    }                                                                 
                                                                      
    if (sc != RTEMS_SUCCESSFUL) {                                     
      close(fd);                                                      
40004158:	40 00 03 8b 	call  40004f84 <close>                         
4000415c:	90 10 00 19 	mov  %i1, %o0                                  
  } else {                                                            
    sc = RTEMS_INVALID_ID;                                            
  }                                                                   
                                                                      
  return sc;                                                          
}                                                                     
40004160:	81 c7 e0 08 	ret                                            
40004164:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

4000f514 <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) {
4000f514:	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;                               
4000f518:	c2 06 80 00 	ld  [ %i2 ], %g1                               
                                                                      
    if (args->command != RTEMS_BLKIO_REQUEST)                         
4000f51c:	d2 06 a0 04 	ld  [ %i2 + 4 ], %o1                           
    rtems_device_minor_number minor __attribute__((unused)),          
    void                    * arg)                                    
{                                                                     
    rtems_libio_ioctl_args_t *args = arg;                             
    rtems_libio_t *iop = args->iop;                                   
    rtems_disk_device *dd = iop->data1;                               
4000f520:	d0 00 60 30 	ld  [ %g1 + 0x30 ], %o0                        
                                                                      
    if (args->command != RTEMS_BLKIO_REQUEST)                         
4000f524:	03 30 06 10 	sethi  %hi(0xc0184000), %g1                    
4000f528:	82 10 62 01 	or  %g1, 0x201, %g1	! c0184201 <RAM_END+0x7fd84201>
4000f52c:	80 a2 40 01 	cmp  %o1, %g1                                  
4000f530:	02 80 00 07 	be  4000f54c <rtems_blkdev_generic_ioctl+0x38> <== NEVER TAKEN
4000f534:	82 10 3f ff 	mov  -1, %g1                                   
    {                                                                 
        args->ioctl_return = dd->ioctl(dd,                            
4000f538:	c2 02 20 38 	ld  [ %o0 + 0x38 ], %g1                        
4000f53c:	9f c0 40 00 	call  %g1                                      
4000f540:	d4 06 a0 08 	ld  [ %i2 + 8 ], %o2                           
4000f544:	10 80 00 03 	b  4000f550 <rtems_blkdev_generic_ioctl+0x3c>  
4000f548:	d0 26 a0 0c 	st  %o0, [ %i2 + 0xc ]                         
    {                                                                 
        /*                                                            
         * It is not allowed to directly access the driver circumventing the
         * cache.                                                     
         */                                                           
        args->ioctl_return = -1;                                      
4000f54c:	c2 26 a0 0c 	st  %g1, [ %i2 + 0xc ]                         <== NOT EXECUTED
    }                                                                 
                                                                      
    return RTEMS_SUCCESSFUL;                                          
}                                                                     
4000f550:	81 c7 e0 08 	ret                                            
4000f554:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000f2f4 <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) {
4000f2f4:	9d e3 bf 98 	save  %sp, -104, %sp                           
    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;                               
4000f2f8:	c2 06 80 00 	ld  [ %i2 ], %g1                               
    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);
4000f2fc:	f8 1e a0 08 	ldd  [ %i2 + 8 ], %i4                          
    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;                               
4000f300:	e4 00 60 30 	ld  [ %g1 + 0x30 ], %l2                        
    uint32_t block_size = dd->block_size;                             
    char *buf = args->buffer;                                         
4000f304:	f2 06 a0 10 	ld  [ %i2 + 0x10 ], %i1                        
{                                                                     
    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;                             
4000f308:	e0 04 a0 24 	ld  [ %l2 + 0x24 ], %l0                        
    char *buf = args->buffer;                                         
    uint32_t count = args->count;                                     
4000f30c:	f6 06 a0 14 	ld  [ %i2 + 0x14 ], %i3                        
    rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
4000f310:	90 10 00 1c 	mov  %i4, %o0                                  
4000f314:	94 10 20 00 	clr  %o2                                       
4000f318:	96 10 00 10 	mov  %l0, %o3                                  
4000f31c:	40 00 24 76 	call  400184f4 <__divdi3>                      
4000f320:	92 10 00 1d 	mov  %i5, %o1                                  
    uint32_t blkofs = (uint32_t) (args->offset % block_size);         
4000f324:	90 10 00 1c 	mov  %i4, %o0                                  
    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);
4000f328:	a6 10 00 09 	mov  %o1, %l3                                  
    uint32_t blkofs = (uint32_t) (args->offset % block_size);         
4000f32c:	94 10 20 00 	clr  %o2                                       
4000f330:	92 10 00 1d 	mov  %i5, %o1                                  
4000f334:	96 10 00 10 	mov  %l0, %o3                                  
4000f338:	40 00 25 61 	call  400188bc <__moddi3>                      
4000f33c:	b8 10 20 00 	clr  %i4                                       
                                                                      
    args->bytes_moved = 0;                                            
4000f340:	c0 26 a0 1c 	clr  [ %i2 + 0x1c ]                            
    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);
    uint32_t blkofs = (uint32_t) (args->offset % block_size);         
4000f344:	a2 10 00 09 	mov  %o1, %l1                                  
                                                                      
    args->bytes_moved = 0;                                            
                                                                      
    while (count > 0)                                                 
4000f348:	80 a6 e0 00 	cmp  %i3, 0                                    
4000f34c:	02 80 00 1d 	be  4000f3c0 <rtems_blkdev_generic_read+0xcc>  
4000f350:	92 07 00 13 	add  %i4, %l3, %o1                             
    {                                                                 
        rtems_bdbuf_buffer *diskbuf;                                  
        uint32_t            copy;                                     
                                                                      
        rc = rtems_bdbuf_read(dd, block, &diskbuf);                   
4000f354:	90 10 00 12 	mov  %l2, %o0                                  
4000f358:	7f ff fe 69 	call  4000ecfc <rtems_bdbuf_read>              
4000f35c:	94 07 bf fc 	add  %fp, -4, %o2                              
        if (rc != RTEMS_SUCCESSFUL)                                   
4000f360:	80 a2 20 00 	cmp  %o0, 0                                    
4000f364:	12 80 00 18 	bne  4000f3c4 <rtems_blkdev_generic_read+0xd0> <== NEVER TAKEN
4000f368:	ba 24 00 11 	sub  %l0, %l1, %i5                             
4000f36c:	80 a7 40 1b 	cmp  %i5, %i3                                  
4000f370:	38 80 00 02 	bgu,a   4000f378 <rtems_blkdev_generic_read+0x84>
4000f374:	ba 10 00 1b 	mov  %i3, %i5                                  
            break;                                                    
        copy = block_size - blkofs;                                   
        if (copy > count)                                             
            copy = count;                                             
        memcpy(buf, (char *)diskbuf->buffer + blkofs, copy);          
4000f378:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000f37c:	94 10 00 1d 	mov  %i5, %o2                                  
4000f380:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1                        
4000f384:	90 10 00 19 	mov  %i1, %o0                                  
4000f388:	40 00 14 89 	call  400145ac <memcpy>                        
4000f38c:	92 02 40 11 	add  %o1, %l1, %o1                             
        rc = rtems_bdbuf_release(diskbuf);                            
4000f390:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
4000f394:	7f ff fe c9 	call  4000eeb8 <rtems_bdbuf_release>           
4000f398:	b8 07 20 01 	inc  %i4                                       
        args->bytes_moved += copy;                                    
4000f39c:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
        if (rc != RTEMS_SUCCESSFUL)                                   
4000f3a0:	80 a2 20 00 	cmp  %o0, 0                                    
        copy = block_size - blkofs;                                   
        if (copy > count)                                             
            copy = count;                                             
        memcpy(buf, (char *)diskbuf->buffer + blkofs, copy);          
        rc = rtems_bdbuf_release(diskbuf);                            
        args->bytes_moved += copy;                                    
4000f3a4:	82 00 40 1d 	add  %g1, %i5, %g1                             
        if (rc != RTEMS_SUCCESSFUL)                                   
4000f3a8:	12 80 00 07 	bne  4000f3c4 <rtems_blkdev_generic_read+0xd0> <== NEVER TAKEN
4000f3ac:	c2 26 a0 1c 	st  %g1, [ %i2 + 0x1c ]                        
            break;                                                    
        count -= copy;                                                
4000f3b0:	b6 26 c0 1d 	sub  %i3, %i5, %i3                             
        buf += copy;                                                  
4000f3b4:	b2 06 40 1d 	add  %i1, %i5, %i1                             
4000f3b8:	10 bf ff e4 	b  4000f348 <rtems_blkdev_generic_read+0x54>   
4000f3bc:	a2 10 20 00 	clr  %l1                                       
4000f3c0:	90 10 20 00 	clr  %o0                                       
        blkofs = 0;                                                   
        block++;                                                      
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
4000f3c4:	81 c7 e0 08 	ret                                            
4000f3c8:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000f3cc <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) {
4000f3cc:	9d e3 bf 98 	save  %sp, -104, %sp                           
    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;                               
4000f3d0:	c2 06 80 00 	ld  [ %i2 ], %g1                               
    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);
4000f3d4:	f8 1e a0 08 	ldd  [ %i2 + 8 ], %i4                          
    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;                               
4000f3d8:	e2 00 60 30 	ld  [ %g1 + 0x30 ], %l1                        
    uint32_t block_size = dd->block_size;                             
    char *buf = args->buffer;                                         
4000f3dc:	e0 06 a0 10 	ld  [ %i2 + 0x10 ], %l0                        
{                                                                     
    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;                             
4000f3e0:	f2 04 60 24 	ld  [ %l1 + 0x24 ], %i1                        
    char *buf = args->buffer;                                         
    uint32_t count = args->count;                                     
4000f3e4:	f6 06 a0 14 	ld  [ %i2 + 0x14 ], %i3                        
    rtems_blkdev_bnum block = (rtems_blkdev_bnum) (args->offset / block_size);
4000f3e8:	90 10 00 1c 	mov  %i4, %o0                                  
4000f3ec:	94 10 20 00 	clr  %o2                                       
4000f3f0:	96 10 00 19 	mov  %i1, %o3                                  
4000f3f4:	40 00 24 40 	call  400184f4 <__divdi3>                      
4000f3f8:	92 10 00 1d 	mov  %i5, %o1                                  
    uint32_t blkofs = (uint32_t) (args->offset % block_size);         
4000f3fc:	90 10 00 1c 	mov  %i4, %o0                                  
    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);
4000f400:	a4 10 00 09 	mov  %o1, %l2                                  
    uint32_t blkofs = (uint32_t) (args->offset % block_size);         
4000f404:	94 10 20 00 	clr  %o2                                       
4000f408:	92 10 00 1d 	mov  %i5, %o1                                  
4000f40c:	96 10 00 19 	mov  %i1, %o3                                  
4000f410:	40 00 25 2b 	call  400188bc <__moddi3>                      
4000f414:	b0 10 20 00 	clr  %i0                                       
                                                                      
    args->bytes_moved = 0;                                            
4000f418:	c0 26 a0 1c 	clr  [ %i2 + 0x1c ]                            
    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);
    uint32_t blkofs = (uint32_t) (args->offset % block_size);         
4000f41c:	b8 10 00 09 	mov  %o1, %i4                                  
                                                                      
    args->bytes_moved = 0;                                            
                                                                      
    while (count > 0)                                                 
4000f420:	80 a6 e0 00 	cmp  %i3, 0                                    
4000f424:	02 80 00 27 	be  4000f4c0 <rtems_blkdev_generic_write+0xf4> 
4000f428:	92 06 00 12 	add  %i0, %l2, %o1                             
    {                                                                 
        rtems_bdbuf_buffer *diskbuf;                                  
        uint32_t            copy;                                     
                                                                      
        if ((blkofs == 0) && (count >= block_size))                   
            rc = rtems_bdbuf_get(dd, block, &diskbuf);                
4000f42c:	90 10 00 11 	mov  %l1, %o0                                  
    while (count > 0)                                                 
    {                                                                 
        rtems_bdbuf_buffer *diskbuf;                                  
        uint32_t            copy;                                     
                                                                      
        if ((blkofs == 0) && (count >= block_size))                   
4000f430:	80 a6 c0 19 	cmp  %i3, %i1                                  
4000f434:	0a 80 00 09 	bcs  4000f458 <rtems_blkdev_generic_write+0x8c>
4000f438:	94 07 bf fc 	add  %fp, -4, %o2                              
4000f43c:	80 a7 20 00 	cmp  %i4, 0                                    
4000f440:	12 80 00 06 	bne  4000f458 <rtems_blkdev_generic_write+0x8c><== NEVER TAKEN
4000f444:	01 00 00 00 	nop                                            
            rc = rtems_bdbuf_get(dd, block, &diskbuf);                
4000f448:	7f ff fe 09 	call  4000ec6c <rtems_bdbuf_get>               
4000f44c:	01 00 00 00 	nop                                            
4000f450:	10 80 00 05 	b  4000f464 <rtems_blkdev_generic_write+0x98>  
4000f454:	80 a2 20 00 	cmp  %o0, 0                                    
        else                                                          
            rc = rtems_bdbuf_read(dd, block, &diskbuf);               
4000f458:	7f ff fe 29 	call  4000ecfc <rtems_bdbuf_read>              
4000f45c:	01 00 00 00 	nop                                            
        if (rc != RTEMS_SUCCESSFUL)                                   
4000f460:	80 a2 20 00 	cmp  %o0, 0                                    
4000f464:	12 80 00 18 	bne  4000f4c4 <rtems_blkdev_generic_write+0xf8><== NEVER TAKEN
4000f468:	ba 26 40 1c 	sub  %i1, %i4, %i5                             
4000f46c:	80 a7 40 1b 	cmp  %i5, %i3                                  
4000f470:	38 80 00 02 	bgu,a   4000f478 <rtems_blkdev_generic_write+0xac>
4000f474:	ba 10 00 1b 	mov  %i3, %i5                                  
            break;                                                    
                                                                      
        copy = block_size - blkofs;                                   
        if (copy > count)                                             
            copy = count;                                             
        memcpy((char *)diskbuf->buffer + blkofs, buf, copy);          
4000f478:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000f47c:	92 10 00 10 	mov  %l0, %o1                                  
4000f480:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
4000f484:	94 10 00 1d 	mov  %i5, %o2                                  
4000f488:	40 00 14 49 	call  400145ac <memcpy>                        
4000f48c:	90 02 00 1c 	add  %o0, %i4, %o0                             
        args->bytes_moved += copy;                                    
4000f490:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
                                                                      
        rc = rtems_bdbuf_release_modified(diskbuf);                   
4000f494:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
                                                                      
        copy = block_size - blkofs;                                   
        if (copy > count)                                             
            copy = count;                                             
        memcpy((char *)diskbuf->buffer + blkofs, buf, copy);          
        args->bytes_moved += copy;                                    
4000f498:	82 00 40 1d 	add  %g1, %i5, %g1                             
4000f49c:	b0 06 20 01 	inc  %i0                                       
                                                                      
        rc = rtems_bdbuf_release_modified(diskbuf);                   
4000f4a0:	7f ff fe bb 	call  4000ef8c <rtems_bdbuf_release_modified>  
4000f4a4:	c2 26 a0 1c 	st  %g1, [ %i2 + 0x1c ]                        
        if (rc != RTEMS_SUCCESSFUL)                                   
4000f4a8:	80 a2 20 00 	cmp  %o0, 0                                    
4000f4ac:	12 80 00 06 	bne  4000f4c4 <rtems_blkdev_generic_write+0xf8><== NEVER TAKEN
4000f4b0:	b6 26 c0 1d 	sub  %i3, %i5, %i3                             
            break;                                                    
                                                                      
        count -= copy;                                                
        buf += copy;                                                  
4000f4b4:	a0 04 00 1d 	add  %l0, %i5, %l0                             
4000f4b8:	10 bf ff da 	b  4000f420 <rtems_blkdev_generic_write+0x54>  
4000f4bc:	b8 10 20 00 	clr  %i4                                       
4000f4c0:	90 10 20 00 	clr  %o0                                       
        blkofs = 0;                                                   
        block++;                                                      
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
4000f4c4:	81 c7 e0 08 	ret                                            
4000f4c8:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40003f70 <rtems_blkdev_imfs_fsync_or_fdatasync>: } static int rtems_blkdev_imfs_fsync_or_fdatasync( rtems_libio_t *iop ) {
40003f70:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  rtems_status_code sc = rtems_bdbuf_syncdev(dd);                     
40003f74:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
40003f78:	40 00 2e c4 	call  4000fa88 <rtems_bdbuf_syncdev>           
40003f7c:	b0 10 20 00 	clr  %i0                                       
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003f80:	80 a2 20 00 	cmp  %o0, 0                                    
40003f84:	02 80 00 06 	be  40003f9c <rtems_blkdev_imfs_fsync_or_fdatasync+0x2c><== ALWAYS TAKEN
40003f88:	01 00 00 00 	nop                                            
    errno = EIO;                                                      
40003f8c:	40 00 42 7b 	call  40014978 <__errno>                       <== NOT EXECUTED
40003f90:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
40003f94:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40003f98:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40003f9c:	81 c7 e0 08 	ret                                            
40003fa0:	81 e8 00 00 	restore                                        
                                                                      

40003fa4 <rtems_blkdev_imfs_ioctl>: static int rtems_blkdev_imfs_ioctl( rtems_libio_t *iop, uint32_t request, void *buffer ) {
40003fa4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
                                                                      
  if (request != RTEMS_BLKIO_REQUEST) {                               
40003fa8:	03 30 06 10 	sethi  %hi(0xc0184000), %g1                    
40003fac:	82 10 62 01 	or  %g1, 0x201, %g1	! c0184201 <RAM_END+0x7fd84201>
40003fb0:	80 a6 40 01 	cmp  %i1, %g1                                  
40003fb4:	02 80 00 08 	be  40003fd4 <rtems_blkdev_imfs_ioctl+0x30>    <== NEVER TAKEN
40003fb8:	92 10 00 19 	mov  %i1, %o1                                  
40003fbc:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
    rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
    rtems_disk_device *dd = &ctx->dd;                                 
                                                                      
    rv = (*dd->ioctl)(dd, request, buffer);                           
40003fc0:	c2 02 20 38 	ld  [ %o0 + 0x38 ], %g1                        
40003fc4:	9f c0 40 00 	call  %g1                                      
40003fc8:	94 10 00 1a 	mov  %i2, %o2                                  
40003fcc:	81 c7 e0 08 	ret                                            
40003fd0:	91 e8 00 08 	restore  %g0, %o0, %o0                         
  } else {                                                            
    /*                                                                
     * It is not allowed to directly access the driver circumventing the cache.
     */                                                               
    errno = EINVAL;                                                   
40003fd4:	40 00 42 69 	call  40014978 <__errno>                       <== NOT EXECUTED
40003fd8:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40003fdc:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
40003fe0:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40003fe4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003fe8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40003e84 <rtems_blkdev_imfs_read>: static ssize_t rtems_blkdev_imfs_read( rtems_libio_t *iop, void *buffer, size_t count ) {
40003e84:	9d e3 bf 98 	save  %sp, -104, %sp                           
40003e88:	e6 06 20 20 	ld  [ %i0 + 0x20 ], %l3                        
  int rv;                                                             
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  ssize_t remaining = (ssize_t) count;                                
  off_t offset = iop->offset;                                         
40003e8c:	f8 1e 20 08 	ldd  [ %i0 + 8 ], %i4                          
  ssize_t block_size = (ssize_t) rtems_disk_get_block_size(dd);       
40003e90:	f6 04 e0 24 	ld  [ %l3 + 0x24 ], %i3                        
  rtems_blkdev_bnum block = (rtems_blkdev_bnum) (offset / block_size);
40003e94:	92 10 00 1d 	mov  %i5, %o1                                  
40003e98:	a5 3e e0 1f 	sra  %i3, 0x1f, %l2                            
40003e9c:	96 10 00 1b 	mov  %i3, %o3                                  
40003ea0:	94 10 00 12 	mov  %l2, %o2                                  
40003ea4:	40 00 53 54 	call  40018bf4 <__divdi3>                      
40003ea8:	90 10 00 1c 	mov  %i4, %o0                                  
  ssize_t block_offset = (ssize_t) (offset % block_size);             
40003eac:	94 10 00 12 	mov  %l2, %o2                                  
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  ssize_t remaining = (ssize_t) count;                                
  off_t offset = iop->offset;                                         
  ssize_t block_size = (ssize_t) rtems_disk_get_block_size(dd);       
  rtems_blkdev_bnum block = (rtems_blkdev_bnum) (offset / block_size);
40003eb0:	a0 10 00 09 	mov  %o1, %l0                                  
  ssize_t block_offset = (ssize_t) (offset % block_size);             
40003eb4:	90 10 00 1c 	mov  %i4, %o0                                  
40003eb8:	92 10 00 1d 	mov  %i5, %o1                                  
40003ebc:	96 10 00 1b 	mov  %i3, %o3                                  
40003ec0:	40 00 54 3f 	call  40018fbc <__moddi3>                      
40003ec4:	a2 10 00 1a 	mov  %i2, %l1                                  
)                                                                     
{                                                                     
  int rv;                                                             
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  ssize_t remaining = (ssize_t) count;                                
40003ec8:	ba 10 00 1a 	mov  %i2, %i5                                  
  off_t offset = iop->offset;                                         
  ssize_t block_size = (ssize_t) rtems_disk_get_block_size(dd);       
  rtems_blkdev_bnum block = (rtems_blkdev_bnum) (offset / block_size);
  ssize_t block_offset = (ssize_t) (offset % block_size);             
40003ecc:	a4 10 00 09 	mov  %o1, %l2                                  
  char *dst = buffer;                                                 
                                                                      
  while (remaining > 0) {                                             
40003ed0:	80 a7 60 00 	cmp  %i5, 0                                    
40003ed4:	04 80 00 1a 	ble  40003f3c <rtems_blkdev_imfs_read+0xb8>    
40003ed8:	90 10 00 13 	mov  %l3, %o0                                  
    rtems_bdbuf_buffer *bd;                                           
    rtems_status_code sc = rtems_bdbuf_read(dd, block, &bd);          
40003edc:	92 10 00 10 	mov  %l0, %o1                                  
40003ee0:	40 00 2e 2a 	call  4000f788 <rtems_bdbuf_read>              
40003ee4:	94 07 bf fc 	add  %fp, -4, %o2                              
                                                                      
    if (sc == RTEMS_SUCCESSFUL) {                                     
40003ee8:	80 a2 20 00 	cmp  %o0, 0                                    
40003eec:	12 80 00 1b 	bne  40003f58 <rtems_blkdev_imfs_read+0xd4>    <== NEVER TAKEN
40003ef0:	b8 26 c0 12 	sub  %i3, %l2, %i4                             
40003ef4:	80 a7 00 1d 	cmp  %i4, %i5                                  
40003ef8:	34 80 00 02 	bg,a   40003f00 <rtems_blkdev_imfs_read+0x7c>  
40003efc:	b8 10 00 1d 	mov  %i5, %i4                                  
                                                                      
      if (copy > remaining) {                                         
        copy = remaining;                                             
      }                                                               
                                                                      
      memcpy(dst, (char *) bd->buffer + block_offset, (size_t) copy); 
40003f00:	e8 07 bf fc 	ld  [ %fp + -4 ], %l4                          
40003f04:	94 10 00 1c 	mov  %i4, %o2                                  
40003f08:	d2 05 20 1c 	ld  [ %l4 + 0x1c ], %o1                        
40003f0c:	90 10 00 19 	mov  %i1, %o0                                  
40003f10:	40 00 42 f2 	call  40014ad8 <memcpy>                        
40003f14:	92 02 40 12 	add  %o1, %l2, %o1                             
                                                                      
      sc = rtems_bdbuf_release(bd);                                   
40003f18:	40 00 2e 8b 	call  4000f944 <rtems_bdbuf_release>           
40003f1c:	90 10 00 14 	mov  %l4, %o0                                  
      if (sc == RTEMS_SUCCESSFUL) {                                   
40003f20:	80 a2 20 00 	cmp  %o0, 0                                    
40003f24:	12 80 00 0d 	bne  40003f58 <rtems_blkdev_imfs_read+0xd4>    <== NEVER TAKEN
40003f28:	ba 27 40 1c 	sub  %i5, %i4, %i5                             
        block_offset = 0;                                             
        remaining -= copy;                                            
        dst += copy;                                                  
40003f2c:	b2 06 40 1c 	add  %i1, %i4, %i1                             
        ++block;                                                      
40003f30:	a0 04 20 01 	inc  %l0                                       
40003f34:	10 bf ff e7 	b  40003ed0 <rtems_blkdev_imfs_read+0x4c>      
40003f38:	a4 10 20 00 	clr  %l2                                       
    } else {                                                          
      remaining = -1;                                                 
    }                                                                 
  }                                                                   
                                                                      
  if (remaining >= 0) {                                               
40003f3c:	12 80 00 07 	bne  40003f58 <rtems_blkdev_imfs_read+0xd4>    <== NEVER TAKEN
40003f40:	01 00 00 00 	nop                                            
    iop->offset += count;                                             
40003f44:	c4 1e 20 08 	ldd  [ %i0 + 8 ], %g2                          
40003f48:	86 80 c0 1a 	addcc  %g3, %i2, %g3                           
40003f4c:	84 40 a0 00 	addx  %g2, 0, %g2                              
40003f50:	10 80 00 06 	b  40003f68 <rtems_blkdev_imfs_read+0xe4>      
40003f54:	c4 3e 20 08 	std  %g2, [ %i0 + 8 ]                          
    rv = (ssize_t) count;                                             
  } else {                                                            
    errno = EIO;                                                      
40003f58:	40 00 42 88 	call  40014978 <__errno>                       <== NOT EXECUTED
40003f5c:	a2 10 3f ff 	mov  -1, %l1                                   <== NOT EXECUTED
40003f60:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40003f64:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40003f68:	81 c7 e0 08 	ret                                            
40003f6c:	91 e8 00 11 	restore  %g0, %l1, %o0                         
                                                                      

40003d5c <rtems_blkdev_imfs_write>: static ssize_t rtems_blkdev_imfs_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
40003d5c:	9d e3 bf 98 	save  %sp, -104, %sp                           
                                                                      
static inline void *IMFS_generic_get_context_by_iop(                  
  const rtems_libio_t *iop                                            
)                                                                     
{                                                                     
  return IMFS_generic_get_context_by_location( &iop->pathinfo );      
40003d60:	e6 06 20 20 	ld  [ %i0 + 0x20 ], %l3                        
  int rv;                                                             
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  ssize_t remaining = (ssize_t) count;                                
  off_t offset = iop->offset;                                         
40003d64:	f8 1e 20 08 	ldd  [ %i0 + 8 ], %i4                          
  ssize_t block_size = (ssize_t) rtems_disk_get_block_size(dd);       
40003d68:	f6 04 e0 24 	ld  [ %l3 + 0x24 ], %i3                        
  rtems_blkdev_bnum block = (rtems_blkdev_bnum) (offset / block_size);
40003d6c:	92 10 00 1d 	mov  %i5, %o1                                  
40003d70:	a3 3e e0 1f 	sra  %i3, 0x1f, %l1                            
40003d74:	96 10 00 1b 	mov  %i3, %o3                                  
40003d78:	94 10 00 11 	mov  %l1, %o2                                  
40003d7c:	40 00 53 9e 	call  40018bf4 <__divdi3>                      
40003d80:	90 10 00 1c 	mov  %i4, %o0                                  
  ssize_t block_offset = (ssize_t) (offset % block_size);             
40003d84:	94 10 00 11 	mov  %l1, %o2                                  
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  ssize_t remaining = (ssize_t) count;                                
  off_t offset = iop->offset;                                         
  ssize_t block_size = (ssize_t) rtems_disk_get_block_size(dd);       
  rtems_blkdev_bnum block = (rtems_blkdev_bnum) (offset / block_size);
40003d88:	a0 10 00 09 	mov  %o1, %l0                                  
  ssize_t block_offset = (ssize_t) (offset % block_size);             
40003d8c:	90 10 00 1c 	mov  %i4, %o0                                  
40003d90:	92 10 00 1d 	mov  %i5, %o1                                  
40003d94:	96 10 00 1b 	mov  %i3, %o3                                  
40003d98:	40 00 54 89 	call  40018fbc <__moddi3>                      
40003d9c:	a4 10 00 1a 	mov  %i2, %l2                                  
)                                                                     
{                                                                     
  int rv;                                                             
  rtems_blkdev_imfs_context *ctx = IMFS_generic_get_context_by_iop(iop);
  rtems_disk_device *dd = &ctx->dd;                                   
  ssize_t remaining = (ssize_t) count;                                
40003da0:	ba 10 00 1a 	mov  %i2, %i5                                  
  off_t offset = iop->offset;                                         
  ssize_t block_size = (ssize_t) rtems_disk_get_block_size(dd);       
  rtems_blkdev_bnum block = (rtems_blkdev_bnum) (offset / block_size);
  ssize_t block_offset = (ssize_t) (offset % block_size);             
40003da4:	a2 10 00 09 	mov  %o1, %l1                                  
  const char *src = buffer;                                           
                                                                      
  while (remaining > 0) {                                             
40003da8:	80 a7 60 00 	cmp  %i5, 0                                    
40003dac:	04 80 00 28 	ble  40003e4c <rtems_blkdev_imfs_write+0xf0>   
40003db0:	80 a7 40 1b 	cmp  %i5, %i3                                  
    rtems_status_code sc;                                             
    rtems_bdbuf_buffer *bd;                                           
                                                                      
    if (block_offset == 0 && remaining >= block_size) {               
40003db4:	16 80 00 03 	bge  40003dc0 <rtems_blkdev_imfs_write+0x64>   
40003db8:	82 10 20 01 	mov  1, %g1                                    
40003dbc:	82 10 20 00 	clr  %g1                                       
       sc = rtems_bdbuf_get(dd, block, &bd);                          
40003dc0:	90 10 00 13 	mov  %l3, %o0                                  
40003dc4:	92 10 00 10 	mov  %l0, %o1                                  
                                                                      
  while (remaining > 0) {                                             
    rtems_status_code sc;                                             
    rtems_bdbuf_buffer *bd;                                           
                                                                      
    if (block_offset == 0 && remaining >= block_size) {               
40003dc8:	80 88 60 ff 	btst  0xff, %g1                                
40003dcc:	02 80 00 09 	be  40003df0 <rtems_blkdev_imfs_write+0x94>    
40003dd0:	94 07 bf fc 	add  %fp, -4, %o2                              
40003dd4:	80 a4 60 00 	cmp  %l1, 0                                    
40003dd8:	12 80 00 06 	bne  40003df0 <rtems_blkdev_imfs_write+0x94>   
40003ddc:	01 00 00 00 	nop                                            
       sc = rtems_bdbuf_get(dd, block, &bd);                          
40003de0:	40 00 2e 46 	call  4000f6f8 <rtems_bdbuf_get>               
40003de4:	01 00 00 00 	nop                                            
40003de8:	10 80 00 05 	b  40003dfc <rtems_blkdev_imfs_write+0xa0>     
40003dec:	80 a2 20 00 	cmp  %o0, 0                                    
    } else {                                                          
       sc = rtems_bdbuf_read(dd, block, &bd);                         
40003df0:	40 00 2e 66 	call  4000f788 <rtems_bdbuf_read>              
40003df4:	01 00 00 00 	nop                                            
    }                                                                 
                                                                      
    if (sc == RTEMS_SUCCESSFUL) {                                     
40003df8:	80 a2 20 00 	cmp  %o0, 0                                    
40003dfc:	12 80 00 1c 	bne  40003e6c <rtems_blkdev_imfs_write+0x110>  <== NEVER TAKEN
40003e00:	b8 26 c0 11 	sub  %i3, %l1, %i4                             
40003e04:	80 a7 00 1d 	cmp  %i4, %i5                                  
40003e08:	34 80 00 02 	bg,a   40003e10 <rtems_blkdev_imfs_write+0xb4> 
40003e0c:	b8 10 00 1d 	mov  %i5, %i4                                  
                                                                      
      if (copy > remaining) {                                         
        copy = remaining;                                             
      }                                                               
                                                                      
      memcpy((char *) bd->buffer + block_offset, src, (size_t) copy); 
40003e10:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40003e14:	92 10 00 19 	mov  %i1, %o1                                  
40003e18:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40003e1c:	94 10 00 1c 	mov  %i4, %o2                                  
40003e20:	40 00 43 2e 	call  40014ad8 <memcpy>                        
40003e24:	90 02 00 11 	add  %o0, %l1, %o0                             
                                                                      
      sc = rtems_bdbuf_release_modified(bd);                          
40003e28:	40 00 2e fc 	call  4000fa18 <rtems_bdbuf_release_modified>  
40003e2c:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
      if (sc == RTEMS_SUCCESSFUL) {                                   
40003e30:	80 a2 20 00 	cmp  %o0, 0                                    
40003e34:	12 80 00 0e 	bne  40003e6c <rtems_blkdev_imfs_write+0x110>  <== NEVER TAKEN
40003e38:	ba 27 40 1c 	sub  %i5, %i4, %i5                             
        block_offset = 0;                                             
        remaining -= copy;                                            
        src += copy;                                                  
40003e3c:	b2 06 40 1c 	add  %i1, %i4, %i1                             
        ++block;                                                      
40003e40:	a0 04 20 01 	inc  %l0                                       
40003e44:	10 bf ff d9 	b  40003da8 <rtems_blkdev_imfs_write+0x4c>     
40003e48:	a2 10 20 00 	clr  %l1                                       
    } else {                                                          
      remaining = -1;                                                 
    }                                                                 
  }                                                                   
                                                                      
  if (remaining >= 0) {                                               
40003e4c:	80 a7 60 00 	cmp  %i5, 0                                    
40003e50:	12 80 00 07 	bne  40003e6c <rtems_blkdev_imfs_write+0x110>  <== NEVER TAKEN
40003e54:	01 00 00 00 	nop                                            
    iop->offset += count;                                             
40003e58:	c4 1e 20 08 	ldd  [ %i0 + 8 ], %g2                          
40003e5c:	86 80 c0 1a 	addcc  %g3, %i2, %g3                           
40003e60:	84 40 a0 00 	addx  %g2, 0, %g2                              
40003e64:	10 80 00 06 	b  40003e7c <rtems_blkdev_imfs_write+0x120>    
40003e68:	c4 3e 20 08 	std  %g2, [ %i0 + 8 ]                          
    rv = (ssize_t) count;                                             
  } else {                                                            
    errno = EIO;                                                      
40003e6c:	40 00 42 c3 	call  40014978 <__errno>                       <== NOT EXECUTED
40003e70:	a4 10 3f ff 	mov  -1, %l2                                   <== NOT EXECUTED
40003e74:	82 10 20 05 	mov  5, %g1                                    <== NOT EXECUTED
40003e78:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
    rv = -1;                                                          
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40003e7c:	81 c7 e0 08 	ret                                            
40003e80:	91 e8 00 12 	restore  %g0, %l2, %o0                         
                                                                      

4000f1ac <rtems_blkdev_ioctl>: #include <rtems/blkdev.h> #include <rtems/bdbuf.h> int rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp) {
4000f1ac:	9d e3 bf a0 	save  %sp, -96, %sp                            
    rtems_status_code  sc;                                            
    int                rc = 0;                                        
                                                                      
    switch (req)                                                      
4000f1b0:	03 10 01 10 	sethi  %hi(0x40044000), %g1                    
4000f1b4:	84 10 62 03 	or  %g1, 0x203, %g2	! 40044203 <__end+0x26b73> 
4000f1b8:	80 a6 40 02 	cmp  %i1, %g2                                  
4000f1bc:	02 80 00 33 	be  4000f288 <rtems_blkdev_ioctl+0xdc>         
4000f1c0:	90 10 00 18 	mov  %i0, %o0                                  
4000f1c4:	80 a6 40 02 	cmp  %i1, %g2                                  
4000f1c8:	18 80 00 19 	bgu  4000f22c <rtems_blkdev_ioctl+0x80>        
4000f1cc:	84 10 62 09 	or  %g1, 0x209, %g2                            
4000f1d0:	05 08 00 10 	sethi  %hi(0x20004000), %g2                    
4000f1d4:	86 10 a2 0a 	or  %g2, 0x20a, %g3	! 2000420a <RAM_SIZE+0x1fc0420a>
4000f1d8:	80 a6 40 03 	cmp  %i1, %g3                                  
4000f1dc:	02 80 00 34 	be  4000f2ac <rtems_blkdev_ioctl+0x100>        
4000f1e0:	01 00 00 00 	nop                                            
4000f1e4:	38 80 00 0a 	bgu,a   4000f20c <rtems_blkdev_ioctl+0x60>     
4000f1e8:	84 10 a2 0c 	or  %g2, 0x20c, %g2                            
4000f1ec:	84 10 a2 06 	or  %g2, 0x206, %g2                            
4000f1f0:	80 a6 40 02 	cmp  %i1, %g2                                  
4000f1f4:	12 80 00 39 	bne  4000f2d8 <rtems_blkdev_ioctl+0x12c>       
4000f1f8:	01 00 00 00 	nop                                            
        case RTEMS_BLKIO_GETSIZE:                                     
            *(rtems_blkdev_bnum *) argp = dd->size;                   
            break;                                                    
                                                                      
        case RTEMS_BLKIO_SYNCDEV:                                     
            sc = rtems_bdbuf_syncdev(dd);                             
4000f1fc:	7f ff ff 80 	call  4000effc <rtems_bdbuf_syncdev>           
4000f200:	01 00 00 00 	nop                                            
            if (sc != RTEMS_SUCCESSFUL) {                             
4000f204:	10 80 00 24 	b  4000f294 <rtems_blkdev_ioctl+0xe8>          
4000f208:	80 a2 20 00 	cmp  %o0, 0                                    
rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)   
{                                                                     
    rtems_status_code  sc;                                            
    int                rc = 0;                                        
                                                                      
    switch (req)                                                      
4000f20c:	80 a6 40 02 	cmp  %i1, %g2                                  
4000f210:	02 80 00 2e 	be  4000f2c8 <rtems_blkdev_ioctl+0x11c>        
4000f214:	82 10 62 02 	or  %g1, 0x202, %g1                            
4000f218:	80 a6 40 01 	cmp  %i1, %g1                                  
4000f21c:	12 80 00 2f 	bne  4000f2d8 <rtems_blkdev_ioctl+0x12c>       <== NEVER TAKEN
4000f220:	01 00 00 00 	nop                                            
    {                                                                 
        case RTEMS_BLKIO_GETMEDIABLKSIZE:                             
            *(uint32_t *) argp = dd->media_block_size;                
4000f224:	10 80 00 1a 	b  4000f28c <rtems_blkdev_ioctl+0xe0>          
4000f228:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)   
{                                                                     
    rtems_status_code  sc;                                            
    int                rc = 0;                                        
                                                                      
    switch (req)                                                      
4000f22c:	80 a6 40 02 	cmp  %i1, %g2                                  
4000f230:	22 80 00 28 	be,a   4000f2d0 <rtems_blkdev_ioctl+0x124>     
4000f234:	f0 26 80 00 	st  %i0, [ %i2 ]                               
4000f238:	38 80 00 08 	bgu,a   4000f258 <rtems_blkdev_ioctl+0xac>     
4000f23c:	82 10 62 0b 	or  %g1, 0x20b, %g1                            
4000f240:	82 10 62 05 	or  %g1, 0x205, %g1                            
4000f244:	80 a6 40 01 	cmp  %i1, %g1                                  
4000f248:	12 80 00 24 	bne  4000f2d8 <rtems_blkdev_ioctl+0x12c>       <== NEVER TAKEN
4000f24c:	01 00 00 00 	nop                                            
                rc = -1;                                              
            }                                                         
            break;                                                    
                                                                      
        case RTEMS_BLKIO_GETSIZE:                                     
            *(rtems_blkdev_bnum *) argp = dd->size;                   
4000f250:	10 80 00 0f 	b  4000f28c <rtems_blkdev_ioctl+0xe0>          
4000f254:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        
rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)   
{                                                                     
    rtems_status_code  sc;                                            
    int                rc = 0;                                        
                                                                      
    switch (req)                                                      
4000f258:	80 a6 40 01 	cmp  %i1, %g1                                  
4000f25c:	02 80 00 17 	be  4000f2b8 <rtems_blkdev_ioctl+0x10c>        
4000f260:	03 20 01 10 	sethi  %hi(0x80044000), %g1                    
4000f264:	82 10 62 04 	or  %g1, 0x204, %g1	! 80044204 <RAM_END+0x3fc44204>
4000f268:	80 a6 40 01 	cmp  %i1, %g1                                  
4000f26c:	12 80 00 1b 	bne  4000f2d8 <rtems_blkdev_ioctl+0x12c>       <== NEVER TAKEN
4000f270:	01 00 00 00 	nop                                            
        case RTEMS_BLKIO_GETBLKSIZE:                                  
            *(uint32_t *) argp = dd->block_size;                      
            break;                                                    
                                                                      
        case RTEMS_BLKIO_SETBLKSIZE:                                  
            sc = rtems_bdbuf_set_block_size(dd, *(uint32_t *) argp, true);
4000f274:	d2 06 80 00 	ld  [ %i2 ], %o1                               
4000f278:	7f ff ff 7c 	call  4000f068 <rtems_bdbuf_set_block_size>    
4000f27c:	94 10 20 01 	mov  1, %o2                                    
            *(rtems_blkdev_bnum *) argp = dd->size;                   
            break;                                                    
                                                                      
        case RTEMS_BLKIO_SYNCDEV:                                     
            sc = rtems_bdbuf_syncdev(dd);                             
            if (sc != RTEMS_SUCCESSFUL) {                             
4000f280:	10 80 00 05 	b  4000f294 <rtems_blkdev_ioctl+0xe8>          
4000f284:	80 a2 20 00 	cmp  %o0, 0                                    
        case RTEMS_BLKIO_GETMEDIABLKSIZE:                             
            *(uint32_t *) argp = dd->media_block_size;                
            break;                                                    
                                                                      
        case RTEMS_BLKIO_GETBLKSIZE:                                  
            *(uint32_t *) argp = dd->block_size;                      
4000f288:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
                rc = -1;                                              
            }                                                         
            break;                                                    
                                                                      
        case RTEMS_BLKIO_GETSIZE:                                     
            *(rtems_blkdev_bnum *) argp = dd->size;                   
4000f28c:	10 80 00 11 	b  4000f2d0 <rtems_blkdev_ioctl+0x124>         
4000f290:	c2 26 80 00 	st  %g1, [ %i2 ]                               
            break;                                                    
                                                                      
        case RTEMS_BLKIO_SYNCDEV:                                     
            sc = rtems_bdbuf_syncdev(dd);                             
            if (sc != RTEMS_SUCCESSFUL) {                             
4000f294:	22 80 00 16 	be,a   4000f2ec <rtems_blkdev_ioctl+0x140>     <== ALWAYS TAKEN
4000f298:	b0 10 20 00 	clr  %i0                                       
                errno = EIO;                                          
4000f29c:	40 00 14 96 	call  400144f4 <__errno>                       <== NOT EXECUTED
4000f2a0:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000f2a4:	10 80 00 10 	b  4000f2e4 <rtems_blkdev_ioctl+0x138>         <== NOT EXECUTED
4000f2a8:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
        case RTEMS_BLKIO_GETDISKDEV:                                  
            *(rtems_disk_device **) argp = dd;                        
            break;                                                    
                                                                      
        case RTEMS_BLKIO_PURGEDEV:                                    
            rtems_bdbuf_purge_dev(dd);                                
4000f2ac:	7f ff ff 68 	call  4000f04c <rtems_bdbuf_purge_dev>         
4000f2b0:	b0 10 20 00 	clr  %i0                                       
4000f2b4:	30 80 00 0e 	b,a   4000f2ec <rtems_blkdev_ioctl+0x140>      
            break;                                                    
                                                                      
        case RTEMS_BLKIO_GETDEVSTATS:                                 
            rtems_bdbuf_get_device_stats(dd, (rtems_blkdev_stats *) argp);
4000f2b8:	7f ff ff ab 	call  4000f164 <rtems_bdbuf_get_device_stats>  
4000f2bc:	92 10 00 1a 	mov  %i2, %o1                                  
                                                                      
int                                                                   
rtems_blkdev_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)   
{                                                                     
    rtems_status_code  sc;                                            
    int                rc = 0;                                        
4000f2c0:	81 c7 e0 08 	ret                                            
4000f2c4:	91 e8 20 00 	restore  %g0, 0, %o0                           
        case RTEMS_BLKIO_GETDEVSTATS:                                 
            rtems_bdbuf_get_device_stats(dd, (rtems_blkdev_stats *) argp);
            break;                                                    
                                                                      
        case RTEMS_BLKIO_RESETDEVSTATS:                               
            rtems_bdbuf_reset_device_stats(dd);                       
4000f2c8:	7f ff ff b0 	call  4000f188 <rtems_bdbuf_reset_device_stats>
4000f2cc:	01 00 00 00 	nop                                            
            break;                                                    
4000f2d0:	81 c7 e0 08 	ret                                            
4000f2d4:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      
        default:                                                      
            errno = EINVAL;                                           
4000f2d8:	40 00 14 87 	call  400144f4 <__errno>                       
4000f2dc:	01 00 00 00 	nop                                            
4000f2e0:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
4000f2e4:	c2 22 00 00 	st  %g1, [ %o0 ]                               
            rc = -1;                                                  
4000f2e8:	b0 10 3f ff 	mov  -1, %i0                                   
            break;                                                    
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
4000f2ec:	81 c7 e0 08 	ret                                            
4000f2f0:	81 e8 00 00 	restore                                        
                                                                      

400085e4 <rtems_chain_get_with_wait>: rtems_chain_control *chain, rtems_event_set events, rtems_interval timeout, rtems_chain_node **node_ptr ) {
400085e4:	9d e3 bf 98 	save  %sp, -104, %sp                           
#else                                                                 
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get(               
  rtems_chain_control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Get( the_chain );                                     
400085e8:	40 00 01 80 	call  40008be8 <_Chain_Get>                    
400085ec:	90 10 00 18 	mov  %i0, %o0                                  
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_chain_node *node = NULL;                                      
                                                                      
  while (                                                             
    sc == RTEMS_SUCCESSFUL                                            
      && (node = rtems_chain_get( chain )) == NULL                    
400085f0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400085f4:	12 80 00 0b 	bne  40008620 <rtems_chain_get_with_wait+0x3c> 
400085f8:	90 10 00 19 	mov  %i1, %o0                                  
  ) {                                                                 
    rtems_event_set out;                                              
    sc = rtems_event_receive(                                         
400085fc:	92 10 20 00 	clr  %o1                                       
40008600:	94 10 00 1a 	mov  %i2, %o2                                  
40008604:	7f ff fd 06 	call  40007a1c <rtems_event_receive>           
40008608:	96 07 bf fc 	add  %fp, -4, %o3                              
)                                                                     
{                                                                     
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_chain_node *node = NULL;                                      
                                                                      
  while (                                                             
4000860c:	80 a2 20 00 	cmp  %o0, 0                                    
40008610:	02 bf ff f6 	be  400085e8 <rtems_chain_get_with_wait+0x4>   <== NEVER TAKEN
40008614:	01 00 00 00 	nop                                            
40008618:	10 80 00 04 	b  40008628 <rtems_chain_get_with_wait+0x44>   
4000861c:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
40008620:	90 10 20 00 	clr  %o0                                       
      timeout,                                                        
      &out                                                            
    );                                                                
  }                                                                   
                                                                      
  *node_ptr = node;                                                   
40008624:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
                                                                      
  return sc;                                                          
}                                                                     
40008628:	81 c7 e0 08 	ret                                            
4000862c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40006f90 <rtems_clock_tick>: #include <rtems/score/threadimpl.h> #include <rtems/score/todimpl.h> #include <rtems/score/watchdogimpl.h> rtems_status_code rtems_clock_tick( void ) {
40006f90:	9d e3 bf a0 	save  %sp, -96, %sp                            
#if defined( RTEMS_SMP )                                              
  _Thread_Disable_dispatch();                                         
#endif                                                                
                                                                      
  _TOD_Tickle_ticks();                                                
40006f94:	40 00 05 6b 	call  40008540 <_TOD_Tickle_ticks>             
40006f98:	01 00 00 00 	nop                                            
 */                                                                   
                                                                      
RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_ticks( void )              
{                                                                     
                                                                      
  _Watchdog_Tickle( &_Watchdog_Ticks_chain );                         
40006f9c:	11 10 00 61 	sethi  %hi(0x40018400), %o0                    
40006fa0:	40 00 10 66 	call  4000b138 <_Watchdog_Tickle>              
40006fa4:	90 12 20 b0 	or  %o0, 0xb0, %o0	! 400184b0 <_Watchdog_Ticks_chain>
  uint32_t cpu_index;                                                 
                                                                      
  for ( cpu_index = 0 ; cpu_index < cpu_count ; ++cpu_index ) {       
    const Per_CPU_Control *cpu = _Per_CPU_Get_by_index( cpu_index );  
    const Scheduler_Control *scheduler = _Scheduler_Get_by_CPU( cpu );
    Thread_Control *executing = cpu->executing;                       
40006fa8:	03 10 00 63 	sethi  %hi(0x40018c00), %g1                    
40006fac:	d2 00 61 18 	ld  [ %g1 + 0x118 ], %o1	! 40018d18 <_Per_CPU_Information+0x18>
                                                                      
    if ( scheduler != NULL && executing != NULL ) {                   
40006fb0:	80 a2 60 00 	cmp  %o1, 0                                    
40006fb4:	02 80 00 06 	be  40006fcc <rtems_clock_tick+0x3c>           <== NEVER TAKEN
40006fb8:	11 10 00 55 	sethi  %hi(0x40015400), %o0                    
      ( *scheduler->Operations.tick )( scheduler, executing );        
40006fbc:	90 12 22 6c 	or  %o0, 0x26c, %o0	! 4001566c <_Scheduler_Table>
40006fc0:	c2 02 20 30 	ld  [ %o0 + 0x30 ], %g1                        
40006fc4:	9f c0 40 00 	call  %g1                                      
40006fc8:	01 00 00 00 	nop                                            
  _Scheduler_Tick();                                                  
                                                                      
#if defined( RTEMS_SMP )                                              
  _Thread_Enable_dispatch();                                          
#else                                                                 
  if ( _Thread_Is_context_switch_necessary() &&                       
40006fcc:	c4 09 a0 14 	ldub  [ %g6 + 0x14 ], %g2                      
40006fd0:	80 a0 a0 00 	cmp  %g2, 0                                    
40006fd4:	02 80 00 08 	be  40006ff4 <rtems_clock_tick+0x64>           
40006fd8:	01 00 00 00 	nop                                            
  ISR_Level level;                                                    
                                                                      
  _ISR_Disable_without_giant( level );                                
#endif                                                                
                                                                      
  enabled = _Thread_Dispatch_disable_level == 0;                      
40006fdc:	c2 01 a0 10 	ld  [ %g6 + 0x10 ], %g1                        
40006fe0:	80 a0 60 00 	cmp  %g1, 0                                    
40006fe4:	12 80 00 04 	bne  40006ff4 <rtems_clock_tick+0x64>          
40006fe8:	01 00 00 00 	nop                                            
       _Thread_Dispatch_is_enabled() )                                
    _Thread_Dispatch();                                               
40006fec:	40 00 0b 2e 	call  40009ca4 <_Thread_Dispatch>              
40006ff0:	01 00 00 00 	nop                                            
#endif                                                                
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40006ff4:	81 c7 e0 08 	ret                                            
40006ff8:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40003f4c <rtems_cpu_usage_report_with_plugin>: */ void rtems_cpu_usage_report_with_plugin( void *context, rtems_printk_plugin_t print ) {
40003f4c:	9d e3 bf 70 	save  %sp, -144, %sp                           
    uint32_t seconds, nanoseconds;                                    
  #else                                                               
    uint32_t           total_units = 0;                               
  #endif                                                              
                                                                      
  if ( !print )                                                       
40003f50:	80 a6 60 00 	cmp  %i1, 0                                    
40003f54:	02 80 00 33 	be  40004020 <rtems_cpu_usage_report_with_plugin+0xd4><== NEVER TAKEN
40003f58:	03 10 00 6c 	sethi  %hi(0x4001b000), %g1                    
                                                                      
static inline void _Timestamp64_implementation_Set_to_zero(           
  Timestamp64_Control *_time                                          
)                                                                     
{                                                                     
  *_time = 0;                                                         
40003f5c:	c0 27 bf e0 	clr  [ %fp + -32 ]                             
40003f60:	c0 27 bf e4 	clr  [ %fp + -28 ]                             
   *  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__                          
    _Timestamp_Set_to_zero( &total );                                 
    uptime_at_last_reset = CPU_usage_Uptime_at_last_reset;            
40003f64:	f8 18 62 28 	ldd  [ %g1 + 0x228 ], %i4                      
        }                                                             
      }                                                               
    }                                                                 
  #endif                                                              
                                                                      
  (*print)(                                                           
40003f68:	90 10 00 18 	mov  %i0, %o0                                  
40003f6c:	13 10 00 5d 	sethi  %hi(0x40017400), %o1                    
        if ( !the_thread )                                            
          continue;                                                   
                                                                      
        rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
                                                                      
        (*print)(                                                     
40003f70:	29 10 00 5e 	sethi  %hi(0x40017800), %l4                    
        }                                                             
      }                                                               
    }                                                                 
  #endif                                                              
                                                                      
  (*print)(                                                           
40003f74:	92 12 63 58 	or  %o1, 0x358, %o1                            
40003f78:	27 10 00 6a 	sethi  %hi(0x4001a800), %l3                    
40003f7c:	9f c6 40 00 	call  %i1                                      
40003f80:	2b 10 00 5e 	sethi  %hi(0x40017800), %l5                    
       " ID         | NAME                                   | TICKS         | PERCENT\n"
     #endif                                                           
     "------------+----------------------------------------+---------------+---------\n"
  );                                                                  
                                                                      
  for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
40003f84:	a2 10 20 01 	mov  1, %l1                                    
        if ( !the_thread )                                            
          continue;                                                   
                                                                      
        rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
                                                                      
        (*print)(                                                     
40003f88:	a8 15 20 d0 	or  %l4, 0xd0, %l4                             
 */                                                                   
static inline void _TOD_Get_uptime(                                   
  Timestamp_Control *time                                             
)                                                                     
{                                                                     
  _TOD_Get_with_nanoseconds( time, &_TOD.uptime );                    
40003f8c:	a6 14 e0 c8 	or  %l3, 0xc8, %l3                             
           */                                                         
                                                                      
          seconds = _Timestamp_Get_seconds( &ran );                   
          nanoseconds = _Timestamp_Get_nanoseconds( &ran ) /          
            TOD_NANOSECONDS_PER_MICROSECOND;                          
          (*print)( context,                                          
40003f90:	aa 15 60 e8 	or  %l5, 0xe8, %l5                             
40003f94:	83 2c 60 02 	sll  %l1, 2, %g1                               
    #if !defined(RTEMS_POSIX_API) || defined(RTEMS_DEBUG)             
      if ( !_Objects_Information_table[ api_index ] )                 
        continue;                                                     
    #endif                                                            
                                                                      
    information = _Objects_Information_table[ api_index ][ 1 ];       
40003f98:	05 10 00 6a 	sethi  %hi(0x4001a800), %g2                    
40003f9c:	84 10 a0 e0 	or  %g2, 0xe0, %g2	! 4001a8e0 <_Objects_Information_table>
40003fa0:	c2 00 80 01 	ld  [ %g2 + %g1 ], %g1                         
40003fa4:	e4 00 60 04 	ld  [ %g1 + 4 ], %l2                           
    if ( information ) {                                              
40003fa8:	80 a4 a0 00 	cmp  %l2, 0                                    
40003fac:	12 80 00 25 	bne  40004040 <rtems_cpu_usage_report_with_plugin+0xf4><== ALWAYS TAKEN
40003fb0:	a0 10 20 01 	mov  1, %l0                                    
       " ID         | NAME                                   | TICKS         | PERCENT\n"
     #endif                                                           
     "------------+----------------------------------------+---------------+---------\n"
  );                                                                  
                                                                      
  for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
40003fb4:	a2 04 60 01 	inc  %l1                                       <== NOT EXECUTED
40003fb8:	80 a4 60 04 	cmp  %l1, 4                                    
40003fbc:	12 bf ff f7 	bne  40003f98 <rtems_cpu_usage_report_with_plugin+0x4c>
40003fc0:	83 2c 60 02 	sll  %l1, 2, %g1                               
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    seconds = _Timestamp_Get_seconds( &total );                       
40003fc4:	f8 1f bf e0 	ldd  [ %fp + -32 ], %i4                        
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_seconds(       
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time / 1000000000L);                           
40003fc8:	94 10 20 00 	clr  %o2                                       
40003fcc:	90 10 00 1c 	mov  %i4, %o0                                  
40003fd0:	92 10 00 1d 	mov  %i5, %o1                                  
40003fd4:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40003fd8:	40 00 45 5b 	call  40015544 <__divdi3>                      
40003fdc:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_nanoseconds(   
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time % 1000000000L);                           
40003fe0:	94 10 20 00 	clr  %o2                                       
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_seconds(       
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time / 1000000000L);                           
40003fe4:	b6 10 00 09 	mov  %o1, %i3                                  
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_nanoseconds(   
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time % 1000000000L);                           
40003fe8:	90 10 00 1c 	mov  %i4, %o0                                  
40003fec:	92 10 00 1d 	mov  %i5, %o1                                  
40003ff0:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40003ff4:	40 00 46 46 	call  4001590c <__moddi3>                      
40003ff8:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
    nanoseconds = _Timestamp_Get_nanoseconds( &total ) /              
40003ffc:	90 10 00 09 	mov  %o1, %o0                                  
40004000:	40 00 43 f9 	call  40014fe4 <.udiv>                         
40004004:	92 10 23 e8 	mov  0x3e8, %o1                                
      TOD_NANOSECONDS_PER_MICROSECOND;                                
    (*print)(                                                         
40004008:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
    }                                                                 
  }                                                                   
                                                                      
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    seconds = _Timestamp_Get_seconds( &total );                       
    nanoseconds = _Timestamp_Get_nanoseconds( &total ) /              
4000400c:	96 10 00 08 	mov  %o0, %o3                                  
      TOD_NANOSECONDS_PER_MICROSECOND;                                
    (*print)(                                                         
40004010:	92 12 61 00 	or  %o1, 0x100, %o1                            
40004014:	90 10 00 18 	mov  %i0, %o0                                  
40004018:	9f c6 40 00 	call  %i1                                      
4000401c:	94 10 00 1b 	mov  %i3, %o2                                  
40004020:	81 c7 e0 08 	ret                                            
40004024:	81 e8 00 00 	restore                                        
    #endif                                                            
                                                                      
    information = _Objects_Information_table[ api_index ][ 1 ];       
    if ( information ) {                                              
      for ( i=1 ; i <= information->maximum ; i++ ) {                 
        the_thread = (Thread_Control *)information->local_table[ i ]; 
40004028:	83 2c 20 02 	sll  %l0, 2, %g1                               
4000402c:	f6 00 80 01 	ld  [ %g2 + %g1 ], %i3                         
                                                                      
        if ( !the_thread )                                            
40004030:	80 a6 e0 00 	cmp  %i3, 0                                    
40004034:	32 80 00 09 	bne,a   40004058 <rtems_cpu_usage_report_with_plugin+0x10c><== ALWAYS TAKEN
40004038:	d0 06 e0 08 	ld  [ %i3 + 8 ], %o0                           
        continue;                                                     
    #endif                                                            
                                                                      
    information = _Objects_Information_table[ api_index ][ 1 ];       
    if ( information ) {                                              
      for ( i=1 ; i <= information->maximum ; i++ ) {                 
4000403c:	a0 04 20 01 	inc  %l0                                       <== NOT EXECUTED
40004040:	c2 14 a0 10 	lduh  [ %l2 + 0x10 ], %g1                      
40004044:	80 a4 00 01 	cmp  %l0, %g1                                  
40004048:	28 bf ff f8 	bleu,a   40004028 <rtems_cpu_usage_report_with_plugin+0xdc>
4000404c:	c4 04 a0 1c 	ld  [ %l2 + 0x1c ], %g2                        
       " ID         | NAME                                   | TICKS         | PERCENT\n"
     #endif                                                           
     "------------+----------------------------------------+---------------+---------\n"
  );                                                                  
                                                                      
  for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
40004050:	10 bf ff da 	b  40003fb8 <rtems_cpu_usage_report_with_plugin+0x6c>
40004054:	a2 04 60 01 	inc  %l1                                       
        the_thread = (Thread_Control *)information->local_table[ i ]; 
                                                                      
        if ( !the_thread )                                            
          continue;                                                   
                                                                      
        rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
40004058:	92 10 20 0d 	mov  0xd, %o1                                  
4000405c:	40 00 12 74 	call  40008a2c <rtems_object_get_name>         
40004060:	94 07 bf f0 	add  %fp, -16, %o2                             
                                                                      
        (*print)(                                                     
40004064:	d4 06 e0 08 	ld  [ %i3 + 8 ], %o2                           
40004068:	90 10 00 18 	mov  %i0, %o0                                  
4000406c:	92 10 00 14 	mov  %l4, %o1                                  
40004070:	9f c6 40 00 	call  %i1                                      
40004074:	96 07 bf f0 	add  %fp, -16, %o3                             
                                                                      
          /*                                                          
           * If this is the currently executing thread, account for time
           * since the last context switch.                           
           */                                                         
          ran = the_thread->cpu_time_used;                            
40004078:	c4 1e e0 80 	ldd  [ %i3 + 0x80 ], %g2                       
4000407c:	c4 3f bf e8 	std  %g2, [ %fp + -24 ]                        
    Thread_Control    *the_thread,                                    
    Timestamp_Control *time_of_context_switch                         
  )                                                                   
  {                                                                   
    #ifndef RTEMS_SMP                                                 
      if ( _Thread_Executing->Object.id == the_thread->Object.id ) {  
40004080:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
40004084:	c6 00 a0 08 	ld  [ %g2 + 8 ], %g3                           
40004088:	c4 06 e0 08 	ld  [ %i3 + 8 ], %g2                           
4000408c:	80 a0 c0 02 	cmp  %g3, %g2                                  
40004090:	12 80 00 2e 	bne  40004148 <rtems_cpu_usage_report_with_plugin+0x1fc>
40004094:	90 07 bf d8 	add  %fp, -40, %o0                             
        *time_of_context_switch = _Thread_Time_of_last_context_switch;
40004098:	f4 19 a0 20 	ldd  [ %g6 + 0x20 ], %i2                       
4000409c:	40 00 17 5d 	call  40009e10 <_TOD_Get_with_nanoseconds>     
400040a0:	92 10 00 13 	mov  %l3, %o1                                  
static inline void _Timestamp64_implementation_Add_to(                
  Timestamp64_Control       *_time,                                   
  const Timestamp64_Control *_add                                     
)                                                                     
{                                                                     
  *_time += *_add;                                                    
400040a4:	d8 1f bf e8 	ldd  [ %fp + -24 ], %o4                        
  const Timestamp64_Control *_start,                                  
  const Timestamp64_Control *_end,                                    
  Timestamp64_Control       *_result                                  
)                                                                     
{                                                                     
  *_result = *_end - *_start;                                         
400040a8:	c4 1f bf d8 	ldd  [ %fp + -40 ], %g2                        
400040ac:	86 a0 c0 1b 	subcc  %g3, %i3, %g3                           
400040b0:	84 60 80 1a 	subx  %g2, %i2, %g2                            
static inline void _Timestamp64_implementation_Add_to(                
  Timestamp64_Control       *_time,                                   
  const Timestamp64_Control *_add                                     
)                                                                     
{                                                                     
  *_time += *_add;                                                    
400040b4:	96 83 40 03 	addcc  %o5, %g3, %o3                           
400040b8:	94 43 00 02 	addx  %o4, %g2, %o2                            
400040bc:	d4 3f bf e8 	std  %o2, [ %fp + -24 ]                        
  const Timestamp64_Control *_start,                                  
  const Timestamp64_Control *_end,                                    
  Timestamp64_Control       *_result                                  
)                                                                     
{                                                                     
  *_result = *_end - *_start;                                         
400040c0:	c4 1f bf d8 	ldd  [ %fp + -40 ], %g2                        
            _Timestamp_Add_to( &ran, &used );                         
          } else {                                                    
            _TOD_Get_uptime( &uptime );                               
          }                                                           
          _Timestamp_Subtract( &uptime_at_last_reset, &uptime, &total );
          _Timestamp_Divide( &ran, &total, &ival, &fval );            
400040c4:	90 07 bf e8 	add  %fp, -24, %o0                             
400040c8:	86 a0 c0 1d 	subcc  %g3, %i5, %g3                           
400040cc:	84 60 80 1c 	subx  %g2, %i4, %g2                            
400040d0:	92 07 bf e0 	add  %fp, -32, %o1                             
400040d4:	c4 3f bf e0 	std  %g2, [ %fp + -32 ]                        
400040d8:	94 07 bf d0 	add  %fp, -48, %o2                             
400040dc:	40 00 21 d6 	call  4000c834 <_Timestamp64_Divide>           
400040e0:	96 07 bf d4 	add  %fp, -44, %o3                             
                                                                      
          /*                                                          
           * Print the information                                    
           */                                                         
                                                                      
          seconds = _Timestamp_Get_seconds( &ran );                   
400040e4:	f4 1f bf e8 	ldd  [ %fp + -24 ], %i2                        
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_seconds(       
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time / 1000000000L);                           
400040e8:	94 10 20 00 	clr  %o2                                       
400040ec:	90 10 00 1a 	mov  %i2, %o0                                  
400040f0:	92 10 00 1b 	mov  %i3, %o1                                  
400040f4:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
400040f8:	40 00 45 13 	call  40015544 <__divdi3>                      
400040fc:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_nanoseconds(   
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time % 1000000000L);                           
40004100:	94 10 20 00 	clr  %o2                                       
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_seconds(       
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time / 1000000000L);                           
40004104:	ac 10 00 09 	mov  %o1, %l6                                  
                                                                      
static inline uint32_t _Timestamp64_implementation_Get_nanoseconds(   
  const Timestamp64_Control *_time                                    
)                                                                     
{                                                                     
  return (uint32_t) (*_time % 1000000000L);                           
40004108:	90 10 00 1a 	mov  %i2, %o0                                  
4000410c:	92 10 00 1b 	mov  %i3, %o1                                  
40004110:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40004114:	40 00 45 fe 	call  4001590c <__moddi3>                      
40004118:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
          nanoseconds = _Timestamp_Get_nanoseconds( &ran ) /          
4000411c:	90 10 00 09 	mov  %o1, %o0                                  
40004120:	40 00 43 b1 	call  40014fe4 <.udiv>                         
40004124:	92 10 23 e8 	mov  0x3e8, %o1                                
            TOD_NANOSECONDS_PER_MICROSECOND;                          
          (*print)( context,                                          
40004128:	d8 1f bf d0 	ldd  [ %fp + -48 ], %o4                        
          /*                                                          
           * Print the information                                    
           */                                                         
                                                                      
          seconds = _Timestamp_Get_seconds( &ran );                   
          nanoseconds = _Timestamp_Get_nanoseconds( &ran ) /          
4000412c:	96 10 00 08 	mov  %o0, %o3                                  
            TOD_NANOSECONDS_PER_MICROSECOND;                          
          (*print)( context,                                          
40004130:	92 10 00 15 	mov  %l5, %o1                                  
40004134:	90 10 00 18 	mov  %i0, %o0                                  
40004138:	9f c6 40 00 	call  %i1                                      
4000413c:	94 10 00 16 	mov  %l6, %o2                                  
        continue;                                                     
    #endif                                                            
                                                                      
    information = _Objects_Information_table[ api_index ][ 1 ];       
    if ( information ) {                                              
      for ( i=1 ; i <= information->maximum ; i++ ) {                 
40004140:	10 bf ff c0 	b  40004040 <rtems_cpu_usage_report_with_plugin+0xf4>
40004144:	a0 04 20 01 	inc  %l0                                       
40004148:	40 00 17 32 	call  40009e10 <_TOD_Get_with_nanoseconds>     
4000414c:	92 10 00 13 	mov  %l3, %o1                                  
  const Timestamp64_Control *_start,                                  
  const Timestamp64_Control *_end,                                    
  Timestamp64_Control       *_result                                  
)                                                                     
{                                                                     
  *_result = *_end - *_start;                                         
40004150:	10 bf ff dd 	b  400040c4 <rtems_cpu_usage_report_with_plugin+0x178>
40004154:	c4 1f bf d8 	ldd  [ %fp + -40 ], %g2                        
                                                                      

40003ed0 <rtems_disk_create_log>: dev_t phys, rtems_blkdev_bnum block_begin, rtems_blkdev_bnum block_count, const char *name ) {
40003ed0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_disk_device *phys_dd = NULL;                                  
  rtems_disk_device *dd = NULL;                                       
40003ed4:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
  char *alloc_name = NULL;                                            
                                                                      
  sc = disk_lock();                                                   
40003ed8:	7f ff fe ce 	call  40003a10 <disk_lock>                     
40003edc:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003ee0:	a0 92 20 00 	orcc  %o0, 0, %l0                              
40003ee4:	32 80 00 33 	bne,a   40003fb0 <rtems_disk_create_log+0xe0>  <== NEVER TAKEN
40003ee8:	b0 10 00 10 	mov  %l0, %i0                                  <== NOT EXECUTED
    return sc;                                                        
  }                                                                   
                                                                      
  phys_dd = get_disk_entry(phys, true);                               
40003eec:	92 10 00 1b 	mov  %i3, %o1                                  
40003ef0:	90 10 00 1a 	mov  %i2, %o0                                  
40003ef4:	7f ff fe 9e 	call  4000396c <get_disk_entry>                
40003ef8:	94 10 20 01 	mov  1, %o2                                    
  if (phys_dd == NULL) {                                              
40003efc:	b6 92 20 00 	orcc  %o0, 0, %i3                              
40003f00:	12 80 00 06 	bne  40003f18 <rtems_disk_create_log+0x48>     
40003f04:	d4 07 a0 5c 	ld  [ %fp + 0x5c ], %o2                        
    disk_unlock();                                                    
40003f08:	7f ff ff 36 	call  40003be0 <disk_unlock>                   
40003f0c:	a0 10 20 04 	mov  4, %l0                                    
                                                                      
    return RTEMS_INVALID_ID;                                          
40003f10:	81 c7 e0 08 	ret                                            
40003f14:	91 e8 00 10 	restore  %g0, %l0, %o0                         
  }                                                                   
                                                                      
  sc = create_disk(dev, name, &dd, &alloc_name);                      
40003f18:	90 10 00 18 	mov  %i0, %o0                                  
40003f1c:	92 10 00 19 	mov  %i1, %o1                                  
40003f20:	96 07 bf f8 	add  %fp, -8, %o3                              
40003f24:	7f ff fe ca 	call  40003a4c <create_disk>                   
40003f28:	98 07 bf fc 	add  %fp, -4, %o4                              
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003f2c:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40003f30:	02 80 00 06 	be  40003f48 <rtems_disk_create_log+0x78>      
40003f34:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
    disk_unlock();                                                    
40003f38:	7f ff ff 2a 	call  40003be0 <disk_unlock>                   
40003f3c:	a0 10 00 1a 	mov  %i2, %l0                                  
                                                                      
    return sc;                                                        
40003f40:	81 c7 e0 08 	ret                                            
40003f44:	91 e8 00 10 	restore  %g0, %l0, %o0                         
  }                                                                   
                                                                      
  sc = rtems_disk_init_log(                                           
40003f48:	96 10 00 1d 	mov  %i5, %o3                                  
40003f4c:	92 10 00 1b 	mov  %i3, %o1                                  
40003f50:	40 00 2e 2b 	call  4000f7fc <rtems_disk_init_log>           
40003f54:	94 10 00 1c 	mov  %i4, %o2                                  
    phys_dd,                                                          
    block_begin,                                                      
    block_count                                                       
  );                                                                  
                                                                      
  dd->dev = dev;                                                      
40003f58:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
  dd->name = alloc_name;                                              
40003f5c:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    phys_dd,                                                          
    block_begin,                                                      
    block_count                                                       
  );                                                                  
                                                                      
  dd->dev = dev;                                                      
40003f60:	f0 38 40 00 	std  %i0, [ %g1 ]                              
  dd->name = alloc_name;                                              
40003f64:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
                                                                      
  ++phys_dd->uses;                                                    
40003f68:	c4 06 e0 14 	ld  [ %i3 + 0x14 ], %g2                        
    disk_unlock();                                                    
                                                                      
    return sc;                                                        
  }                                                                   
                                                                      
  sc = rtems_disk_init_log(                                           
40003f6c:	ba 10 00 08 	mov  %o0, %i5                                  
  );                                                                  
                                                                      
  dd->dev = dev;                                                      
  dd->name = alloc_name;                                              
                                                                      
  ++phys_dd->uses;                                                    
40003f70:	84 00 a0 01 	inc  %g2                                       
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003f74:	80 a2 20 00 	cmp  %o0, 0                                    
40003f78:	02 80 00 0c 	be  40003fa8 <rtems_disk_create_log+0xd8>      
40003f7c:	c4 26 e0 14 	st  %g2, [ %i3 + 0x14 ]                        
    dd->ioctl = null_handler;                                         
    rtems_disk_delete(dev);                                           
40003f80:	92 10 00 19 	mov  %i1, %o1                                  
  dd->name = alloc_name;                                              
                                                                      
  ++phys_dd->uses;                                                    
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
    dd->ioctl = null_handler;                                         
40003f84:	05 10 00 0e 	sethi  %hi(0x40003800), %g2                    
40003f88:	84 10 a2 08 	or  %g2, 0x208, %g2	! 40003a08 <null_handler>  
    rtems_disk_delete(dev);                                           
40003f8c:	90 10 00 18 	mov  %i0, %o0                                  
  dd->name = alloc_name;                                              
                                                                      
  ++phys_dd->uses;                                                    
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
    dd->ioctl = null_handler;                                         
40003f90:	c4 20 60 38 	st  %g2, [ %g1 + 0x38 ]                        
    rtems_disk_delete(dev);                                           
40003f94:	7f ff ff 35 	call  40003c68 <rtems_disk_delete>             
40003f98:	a0 10 00 1d 	mov  %i5, %l0                                  
    disk_unlock();                                                    
40003f9c:	7f ff ff 11 	call  40003be0 <disk_unlock>                   
40003fa0:	b0 10 00 10 	mov  %l0, %i0                                  
                                                                      
    return sc;                                                        
40003fa4:	30 80 00 03 	b,a   40003fb0 <rtems_disk_create_log+0xe0>    
  }                                                                   
                                                                      
  disk_unlock();                                                      
40003fa8:	7f ff ff 0e 	call  40003be0 <disk_unlock>                   
40003fac:	b0 10 00 10 	mov  %l0, %i0                                  
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003fb0:	81 c7 e0 08 	ret                                            
40003fb4:	81 e8 00 00 	restore                                        
                                                                      

40003e04 <rtems_disk_create_phys>: rtems_blkdev_bnum block_count, rtems_block_device_ioctl handler, void *driver_data, const char *name ) {
40003e04:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_disk_device *dd = NULL;                                       
40003e08:	c0 27 bf f8 	clr  [ %fp + -8 ]                              
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  char *alloc_name = NULL;                                            
40003e0c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
  if (handler == NULL) {                                              
40003e10:	80 a7 20 00 	cmp  %i4, 0                                    
40003e14:	02 80 00 2c 	be  40003ec4 <rtems_disk_create_phys+0xc0>     
40003e18:	a0 10 20 09 	mov  9, %l0                                    
    return RTEMS_INVALID_ADDRESS;                                     
  }                                                                   
                                                                      
  sc = disk_lock();                                                   
40003e1c:	7f ff fe fd 	call  40003a10 <disk_lock>                     
40003e20:	01 00 00 00 	nop                                            
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003e24:	a0 92 20 00 	orcc  %o0, 0, %l0                              
40003e28:	32 80 00 28 	bne,a   40003ec8 <rtems_disk_create_phys+0xc4> <== NEVER TAKEN
40003e2c:	b0 10 00 10 	mov  %l0, %i0                                  <== NOT EXECUTED
    return sc;                                                        
  }                                                                   
                                                                      
  sc = create_disk(dev, name, &dd, &alloc_name);                      
40003e30:	d4 07 a0 5c 	ld  [ %fp + 0x5c ], %o2                        
40003e34:	90 10 00 18 	mov  %i0, %o0                                  
40003e38:	92 10 00 19 	mov  %i1, %o1                                  
40003e3c:	96 07 bf f8 	add  %fp, -8, %o3                              
40003e40:	7f ff ff 03 	call  40003a4c <create_disk>                   
40003e44:	98 07 bf fc 	add  %fp, -4, %o4                              
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003e48:	a2 92 20 00 	orcc  %o0, 0, %l1                              
40003e4c:	02 80 00 06 	be  40003e64 <rtems_disk_create_phys+0x60>     
40003e50:	d0 07 bf f8 	ld  [ %fp + -8 ], %o0                          
    disk_unlock();                                                    
40003e54:	7f ff ff 63 	call  40003be0 <disk_unlock>                   
40003e58:	a0 10 00 11 	mov  %l1, %l0                                  
                                                                      
    return sc;                                                        
40003e5c:	81 c7 e0 08 	ret                                            
40003e60:	91 e8 00 10 	restore  %g0, %l0, %o0                         
  }                                                                   
                                                                      
  sc = rtems_disk_init_phys(                                          
40003e64:	98 10 00 1d 	mov  %i5, %o4                                  
40003e68:	92 10 00 1a 	mov  %i2, %o1                                  
40003e6c:	94 10 00 1b 	mov  %i3, %o2                                  
40003e70:	40 00 2e 49 	call  4000f794 <rtems_disk_init_phys>          
40003e74:	96 10 00 1c 	mov  %i4, %o3                                  
    block_count,                                                      
    handler,                                                          
    driver_data                                                       
  );                                                                  
                                                                      
  dd->dev = dev;                                                      
40003e78:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
  dd->name = alloc_name;                                              
40003e7c:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    block_count,                                                      
    handler,                                                          
    driver_data                                                       
  );                                                                  
                                                                      
  dd->dev = dev;                                                      
40003e80:	f0 38 40 00 	std  %i0, [ %g1 ]                              
  dd->name = alloc_name;                                              
40003e84:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003e88:	80 a2 20 00 	cmp  %o0, 0                                    
40003e8c:	02 80 00 0c 	be  40003ebc <rtems_disk_create_phys+0xb8>     
40003e90:	ba 10 00 08 	mov  %o0, %i5                                  
    dd->ioctl = null_handler;                                         
    rtems_disk_delete(dev);                                           
40003e94:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  dd->dev = dev;                                                      
  dd->name = alloc_name;                                              
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
    dd->ioctl = null_handler;                                         
40003e98:	05 10 00 0e 	sethi  %hi(0x40003800), %g2                    
40003e9c:	84 10 a2 08 	or  %g2, 0x208, %g2	! 40003a08 <null_handler>  
    rtems_disk_delete(dev);                                           
40003ea0:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  dd->dev = dev;                                                      
  dd->name = alloc_name;                                              
                                                                      
  if (sc != RTEMS_SUCCESSFUL) {                                       
    dd->ioctl = null_handler;                                         
40003ea4:	c4 20 60 38 	st  %g2, [ %g1 + 0x38 ]                        
    rtems_disk_delete(dev);                                           
40003ea8:	7f ff ff 70 	call  40003c68 <rtems_disk_delete>             
40003eac:	a0 10 00 1d 	mov  %i5, %l0                                  
    disk_unlock();                                                    
40003eb0:	7f ff ff 4c 	call  40003be0 <disk_unlock>                   
40003eb4:	b0 10 00 10 	mov  %l0, %i0                                  
                                                                      
    return sc;                                                        
40003eb8:	30 80 00 04 	b,a   40003ec8 <rtems_disk_create_phys+0xc4>   
  }                                                                   
                                                                      
  disk_unlock();                                                      
40003ebc:	7f ff ff 49 	call  40003be0 <disk_unlock>                   
40003ec0:	01 00 00 00 	nop                                            
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003ec4:	b0 10 00 10 	mov  %l0, %i0                                  
40003ec8:	81 c7 e0 08 	ret                                            
40003ecc:	81 e8 00 00 	restore                                        
                                                                      

40003c68 <rtems_disk_delete>: } } rtems_status_code rtems_disk_delete(dev_t dev) {
40003c68:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_disk_device *dd = NULL;                                       
                                                                      
  sc = disk_lock();                                                   
40003c6c:	7f ff ff 69 	call  40003a10 <disk_lock>                     
40003c70:	b8 10 00 18 	mov  %i0, %i4                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
40003c74:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40003c78:	12 80 00 0a 	bne  40003ca0 <rtems_disk_delete+0x38>         <== NEVER TAKEN
40003c7c:	90 10 00 1c 	mov  %i4, %o0                                  
    return sc;                                                        
  }                                                                   
                                                                      
  dd = get_disk_entry(dev, true);                                     
40003c80:	92 10 00 19 	mov  %i1, %o1                                  
40003c84:	7f ff ff 3a 	call  4000396c <get_disk_entry>                
40003c88:	94 10 20 01 	mov  1, %o2                                    
  if (dd == NULL) {                                                   
40003c8c:	82 92 20 00 	orcc  %o0, 0, %g1                              
40003c90:	32 80 00 06 	bne,a   40003ca8 <rtems_disk_delete+0x40>      <== ALWAYS TAKEN
40003c94:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    disk_unlock();                                                    
40003c98:	7f ff ff d2 	call  40003be0 <disk_unlock>                   <== NOT EXECUTED
40003c9c:	b0 10 20 04 	mov  4, %i0                                    <== NOT EXECUTED
40003ca0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003ca4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
    return RTEMS_INVALID_ID;                                          
  }                                                                   
                                                                      
  dd->deleted = true;                                                 
40003ca8:	84 10 20 01 	mov  1, %g2                                    
40003cac:	c4 28 60 40 	stb  %g2, [ %g1 + 0x40 ]                       
{                                                                     
  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) {                                       
40003cb0:	c4 0f 60 40 	ldub  [ %i5 + 0x40 ], %g2                      
40003cb4:	80 a0 a0 00 	cmp  %g2, 0                                    
40003cb8:	22 80 00 40 	be,a   40003db8 <rtems_disk_delete+0x150>      
40003cbc:	c4 00 60 14 	ld  [ %g1 + 0x14 ], %g2                        
    dev_t dev = physical_disk->dev;                                   
40003cc0:	e0 1f 40 00 	ldd  [ %i5 ], %l0                              
    unsigned deleted_count = 0;                                       
40003cc4:	b4 10 20 00 	clr  %i2                                       
                                                                      
    for (major = 0; major < disktab_size; ++major) {                  
40003cc8:	b8 10 20 00 	clr  %i4                                       
40003ccc:	31 10 00 70 	sethi  %hi(0x4001c000), %i0                    
      rtems_disk_device_table *dtab = disktab + major;                
40003cd0:	25 10 00 70 	sethi  %hi(0x4001c000), %l2                    
          if (dd->uses == 0) {                                        
            ++deleted_count;                                          
            dtab->minor [minor] = NULL;                               
            free_disk_device(dd);                                     
          } else {                                                    
            dd->deleted = true;                                       
40003cd4:	a6 10 20 01 	mov  1, %l3                                    
                                                                      
  if (physical_disk->deleted) {                                       
    dev_t dev = physical_disk->dev;                                   
    unsigned deleted_count = 0;                                       
                                                                      
    for (major = 0; major < disktab_size; ++major) {                  
40003cd8:	c2 06 22 80 	ld  [ %i0 + 0x280 ], %g1                       
40003cdc:	80 a7 00 01 	cmp  %i4, %g1                                  
40003ce0:	1a 80 00 27 	bcc  40003d7c <rtems_disk_delete+0x114>        
40003ce4:	c2 04 a2 84 	ld  [ %l2 + 0x284 ], %g1                       
40003ce8:	b3 2f 20 03 	sll  %i4, 3, %i1                               
      rtems_disk_device_table *dtab = disktab + major;                
                                                                      
      for (minor = 0; minor < dtab->size; ++minor) {                  
40003cec:	b6 10 20 00 	clr  %i3                                       
  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;                
40003cf0:	b2 00 40 19 	add  %g1, %i1, %i1                             
                                                                      
      for (minor = 0; minor < dtab->size; ++minor) {                  
40003cf4:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
40003cf8:	80 a6 c0 01 	cmp  %i3, %g1                                  
40003cfc:	1a 80 00 1e 	bcc  40003d74 <rtems_disk_delete+0x10c>        
40003d00:	83 2e e0 02 	sll  %i3, 2, %g1                               
        rtems_disk_device *dd = dtab->minor [minor];                  
40003d04:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40003d08:	d0 00 80 01 	ld  [ %g2 + %g1 ], %o0                         
                                                                      
        if (dd != NULL && dd->phys_dev->dev == dev && dd != physical_disk) {
40003d0c:	80 a2 20 00 	cmp  %o0, 0                                    
40003d10:	22 bf ff f9 	be,a   40003cf4 <rtems_disk_delete+0x8c>       
40003d14:	b6 06 e0 01 	inc  %i3                                       
40003d18:	c6 02 20 08 	ld  [ %o0 + 8 ], %g3                           
40003d1c:	c8 00 c0 00 	ld  [ %g3 ], %g4                               
40003d20:	80 a1 00 10 	cmp  %g4, %l0                                  
40003d24:	32 bf ff f4 	bne,a   40003cf4 <rtems_disk_delete+0x8c>      <== NEVER TAKEN
40003d28:	b6 06 e0 01 	inc  %i3                                       <== NOT EXECUTED
40003d2c:	c6 00 e0 04 	ld  [ %g3 + 4 ], %g3                           
40003d30:	80 a0 c0 11 	cmp  %g3, %l1                                  
40003d34:	32 bf ff f0 	bne,a   40003cf4 <rtems_disk_delete+0x8c>      <== NEVER TAKEN
40003d38:	b6 06 e0 01 	inc  %i3                                       <== NOT EXECUTED
40003d3c:	80 a2 00 1d 	cmp  %o0, %i5                                  
40003d40:	22 bf ff ed 	be,a   40003cf4 <rtems_disk_delete+0x8c>       
40003d44:	b6 06 e0 01 	inc  %i3                                       
          if (dd->uses == 0) {                                        
40003d48:	c6 02 20 14 	ld  [ %o0 + 0x14 ], %g3                        
40003d4c:	80 a0 e0 00 	cmp  %g3, 0                                    
40003d50:	32 80 00 07 	bne,a   40003d6c <rtems_disk_delete+0x104>     
40003d54:	e6 2a 20 40 	stb  %l3, [ %o0 + 0x40 ]                       
            ++deleted_count;                                          
40003d58:	b4 06 a0 01 	inc  %i2                                       
            dtab->minor [minor] = NULL;                               
            free_disk_device(dd);                                     
40003d5c:	7f ff ff ae 	call  40003c14 <free_disk_device>              
40003d60:	c0 20 80 01 	clr  [ %g2 + %g1 ]                             
    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) {                  
40003d64:	10 bf ff e4 	b  40003cf4 <rtems_disk_delete+0x8c>           
40003d68:	b6 06 e0 01 	inc  %i3                                       
40003d6c:	10 bf ff e2 	b  40003cf4 <rtems_disk_delete+0x8c>           
40003d70:	b6 06 e0 01 	inc  %i3                                       
                                                                      
  if (physical_disk->deleted) {                                       
    dev_t dev = physical_disk->dev;                                   
    unsigned deleted_count = 0;                                       
                                                                      
    for (major = 0; major < disktab_size; ++major) {                  
40003d74:	10 bf ff d9 	b  40003cd8 <rtems_disk_delete+0x70>           
40003d78:	b8 07 20 01 	inc  %i4                                       
          }                                                           
        }                                                             
      }                                                               
    }                                                                 
                                                                      
    physical_disk->uses -= deleted_count;                             
40003d7c:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
40003d80:	b4 20 40 1a 	sub  %g1, %i2, %i2                             
    if (physical_disk->uses == 0) {                                   
40003d84:	80 a6 a0 00 	cmp  %i2, 0                                    
40003d88:	12 80 00 1b 	bne  40003df4 <rtems_disk_delete+0x18c>        
40003d8c:	f4 27 60 14 	st  %i2, [ %i5 + 0x14 ]                        
      rtems_filesystem_split_dev_t(physical_disk->dev, major, minor); 
40003d90:	c4 07 40 00 	ld  [ %i5 ], %g2                               
      disktab [major].minor [minor] = NULL;                           
40003d94:	07 10 00 70 	sethi  %hi(0x4001c000), %g3                    
40003d98:	c6 00 e2 84 	ld  [ %g3 + 0x284 ], %g3	! 4001c284 <disktab>  
      }                                                               
    }                                                                 
                                                                      
    physical_disk->uses -= deleted_count;                             
    if (physical_disk->uses == 0) {                                   
      rtems_filesystem_split_dev_t(physical_disk->dev, major, minor); 
40003d9c:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
      disktab [major].minor [minor] = NULL;                           
40003da0:	85 28 a0 03 	sll  %g2, 3, %g2                               
40003da4:	c4 00 c0 02 	ld  [ %g3 + %g2 ], %g2                         
40003da8:	83 28 60 02 	sll  %g1, 2, %g1                               
      free_disk_device(physical_disk);                                
40003dac:	90 10 00 1d 	mov  %i5, %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;                           
40003db0:	10 80 00 0f 	b  40003dec <rtems_disk_delete+0x184>          
40003db4:	c0 20 80 01 	clr  [ %g2 + %g1 ]                             
      free_disk_device(physical_disk);                                
    }                                                                 
  } else {                                                            
    if (disk_to_remove->uses == 0) {                                  
40003db8:	80 a0 a0 00 	cmp  %g2, 0                                    
40003dbc:	12 80 00 0e 	bne  40003df4 <rtems_disk_delete+0x18c>        <== NEVER TAKEN
40003dc0:	07 10 00 70 	sethi  %hi(0x4001c000), %g3                    
      --physical_disk->uses;                                          
40003dc4:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        
40003dc8:	84 00 bf ff 	add  %g2, -1, %g2                              
      rtems_filesystem_split_dev_t(disk_to_remove->dev, major, minor);
      disktab [major].minor [minor] = NULL;                           
40003dcc:	c6 00 e2 84 	ld  [ %g3 + 0x284 ], %g3                       
      disktab [major].minor [minor] = NULL;                           
      free_disk_device(physical_disk);                                
    }                                                                 
  } else {                                                            
    if (disk_to_remove->uses == 0) {                                  
      --physical_disk->uses;                                          
40003dd0:	c4 27 60 14 	st  %g2, [ %i5 + 0x14 ]                        
      rtems_filesystem_split_dev_t(disk_to_remove->dev, major, minor);
40003dd4:	c4 00 40 00 	ld  [ %g1 ], %g2                               
40003dd8:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
      disktab [major].minor [minor] = NULL;                           
40003ddc:	85 28 a0 03 	sll  %g2, 3, %g2                               
40003de0:	c4 00 c0 02 	ld  [ %g3 + %g2 ], %g2                         
40003de4:	83 28 60 02 	sll  %g1, 2, %g1                               
40003de8:	c0 20 80 01 	clr  [ %g2 + %g1 ]                             
      free_disk_device(disk_to_remove);                               
40003dec:	7f ff ff 8a 	call  40003c14 <free_disk_device>              
40003df0:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  dd->deleted = true;                                                 
  rtems_disk_cleanup(dd);                                             
                                                                      
  disk_unlock();                                                      
40003df4:	7f ff ff 7b 	call  40003be0 <disk_unlock>                   
40003df8:	b0 10 20 00 	clr  %i0	! 0 <_TLS_BSS_size>                   
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40003dfc:	81 c7 e0 08 	ret                                            
40003e00:	81 e8 00 00 	restore                                        
                                                                      

4000407c <rtems_disk_io_initialize>: } } rtems_status_code rtems_disk_io_initialize(void) {
4000407c:	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) {                                             
40004080:	39 10 00 70 	sethi  %hi(0x4001c000), %i4                    
40004084:	c2 07 22 80 	ld  [ %i4 + 0x280 ], %g1	! 4001c280 <disktab_size>
40004088:	80 a0 60 00 	cmp  %g1, 0                                    
4000408c:	12 80 00 19 	bne  400040f0 <rtems_disk_io_initialize+0x74>  
40004090:	b0 10 20 00 	clr  %i0                                       
    return RTEMS_SUCCESSFUL;                                          
  }                                                                   
                                                                      
  disktab = calloc(size, sizeof(rtems_disk_device_table));            
40004094:	90 10 20 08 	mov  8, %o0                                    
40004098:	92 10 20 08 	mov  8, %o1                                    
4000409c:	40 00 02 0b 	call  400048c8 <calloc>                        
400040a0:	3b 10 00 70 	sethi  %hi(0x4001c000), %i5                    
400040a4:	d0 27 62 84 	st  %o0, [ %i5 + 0x284 ]	! 4001c284 <disktab>  
  if (disktab == NULL) {                                              
400040a8:	80 a2 20 00 	cmp  %o0, 0                                    
400040ac:	02 80 00 11 	be  400040f0 <rtems_disk_io_initialize+0x74>   <== NEVER TAKEN
400040b0:	b0 10 20 1a 	mov  0x1a, %i0                                 
    return RTEMS_NO_MEMORY;                                           
  }                                                                   
                                                                      
  diskdevs_protected = false;                                         
400040b4:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
  sc = rtems_semaphore_create(                                        
400040b8:	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;                                         
400040bc:	c0 28 62 78 	clrb  [ %g1 + 0x278 ]                          
  sc = rtems_semaphore_create(                                        
400040c0:	90 12 21 56 	or  %o0, 0x156, %o0                            
400040c4:	92 10 20 01 	mov  1, %o1                                    
400040c8:	94 10 20 10 	mov  0x10, %o2                                 
400040cc:	96 10 20 00 	clr  %o3                                       
400040d0:	37 10 00 70 	sethi  %hi(0x4001c000), %i3                    
400040d4:	40 00 11 f8 	call  400088b4 <rtems_semaphore_create>        
400040d8:	98 16 e2 7c 	or  %i3, 0x27c, %o4	! 4001c27c <diskdevs_mutex>
    RTEMS_FIFO | RTEMS_BINARY_SEMAPHORE | RTEMS_NO_INHERIT_PRIORITY   
      | RTEMS_NO_PRIORITY_CEILING | RTEMS_LOCAL,                      
    0,                                                                
    &diskdevs_mutex                                                   
  );                                                                  
  if (sc != RTEMS_SUCCESSFUL) {                                       
400040dc:	80 a2 20 00 	cmp  %o0, 0                                    
400040e0:	02 80 00 06 	be  400040f8 <rtems_disk_io_initialize+0x7c>   <== ALWAYS TAKEN
400040e4:	01 00 00 00 	nop                                            
    free(disktab);                                                    
400040e8:	40 00 02 30 	call  400049a8 <free>                          <== NOT EXECUTED
400040ec:	d0 07 62 84 	ld  [ %i5 + 0x284 ], %o0                       <== NOT EXECUTED
                                                                      
    return RTEMS_NO_MEMORY;                                           
400040f0:	81 c7 e0 08 	ret                                            
400040f4:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  sc = rtems_bdbuf_init();                                            
400040f8:	40 00 2a cf 	call  4000ec34 <rtems_bdbuf_init>              
400040fc:	01 00 00 00 	nop                                            
  if (sc != RTEMS_SUCCESSFUL) {                                       
40004100:	80 a2 20 00 	cmp  %o0, 0                                    
40004104:	02 80 00 09 	be  40004128 <rtems_disk_io_initialize+0xac>   <== ALWAYS TAKEN
40004108:	82 10 20 08 	mov  8, %g1                                    
    rtems_semaphore_delete(diskdevs_mutex);                           
4000410c:	d0 06 e2 7c 	ld  [ %i3 + 0x27c ], %o0                       <== NOT EXECUTED
40004110:	40 00 12 64 	call  40008aa0 <rtems_semaphore_delete>        <== NOT EXECUTED
40004114:	b0 10 20 0d 	mov  0xd, %i0                                  <== NOT EXECUTED
    free(disktab);                                                    
40004118:	40 00 02 24 	call  400049a8 <free>                          <== NOT EXECUTED
4000411c:	d0 07 62 84 	ld  [ %i5 + 0x284 ], %o0                       <== NOT EXECUTED
                                                                      
    return RTEMS_UNSATISFIED;                                         
40004120:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40004124:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  disktab_size = size;                                                
                                                                      
  return RTEMS_SUCCESSFUL;                                            
40004128:	b0 10 20 00 	clr  %i0                                       
    free(disktab);                                                    
                                                                      
    return RTEMS_UNSATISFIED;                                         
  }                                                                   
                                                                      
  disktab_size = size;                                                
4000412c:	c2 27 22 80 	st  %g1, [ %i4 + 0x280 ]                       
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
40004130:	81 c7 e0 08 	ret                                            
40004134:	81 e8 00 00 	restore                                        
                                                                      

4000ad80 <rtems_disk_next>: rtems_disk_device * rtems_disk_next(dev_t dev) {
4000ad80:	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) {                                            
4000ad84:	80 a6 3f ff 	cmp  %i0, -1                                   
4000ad88:	12 80 00 05 	bne  4000ad9c <rtems_disk_next+0x1c>           
4000ad8c:	b8 06 60 01 	add  %i1, 1, %i4                               
4000ad90:	80 a6 7f ff 	cmp  %i1, -1                                   
4000ad94:	22 80 00 0b 	be,a   4000adc0 <rtems_disk_next+0x40>         <== ALWAYS TAKEN
4000ad98:	b8 10 20 00 	clr  %i4                                       
    rtems_filesystem_split_dev_t(dev, major, minor);                  
                                                                      
    /* If minor wraps around */                                       
    if ((minor + 1) < minor) {                                        
4000ad9c:	80 a7 00 19 	cmp  %i4, %i1                                  
4000ada0:	1a 80 00 09 	bcc  4000adc4 <rtems_disk_next+0x44>           <== ALWAYS TAKEN
4000ada4:	ba 10 00 18 	mov  %i0, %i5                                  
      /* If major wraps around */                                     
      if ((major + 1) < major) {                                      
4000ada8:	ba 06 20 01 	add  %i0, 1, %i5                               <== NOT EXECUTED
4000adac:	80 a7 40 18 	cmp  %i5, %i0                                  <== NOT EXECUTED
4000adb0:	1a 80 00 05 	bcc  4000adc4 <rtems_disk_next+0x44>           <== NOT EXECUTED
4000adb4:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
4000adb8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000adbc:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
4000adc0:	ba 10 20 00 	clr  %i5                                       
    } else {                                                          
      ++minor;                                                        
    }                                                                 
  }                                                                   
                                                                      
  sc = disk_lock();                                                   
4000adc4:	7f ff fe 8e 	call  4000a7fc <disk_lock>                     
4000adc8:	01 00 00 00 	nop                                            
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000adcc:	80 a2 20 00 	cmp  %o0, 0                                    
4000add0:	12 80 00 08 	bne  4000adf0 <rtems_disk_next+0x70>           <== NEVER TAKEN
4000add4:	03 10 00 a0 	sethi  %hi(0x40028000), %g1                    
    return NULL;                                                      
  }                                                                   
                                                                      
  if (major >= disktab_size) {                                        
4000add8:	c4 00 61 94 	ld  [ %g1 + 0x194 ], %g2	! 40028194 <disktab_size>
4000addc:	80 a7 40 02 	cmp  %i5, %g2                                  
4000ade0:	0a 80 00 06 	bcs  4000adf8 <rtems_disk_next+0x78>           <== ALWAYS TAKEN
4000ade4:	03 10 00 a0 	sethi  %hi(0x40028000), %g1                    
    disk_unlock();                                                    
4000ade8:	7f ff fe f9 	call  4000a9cc <disk_unlock>                   
4000adec:	01 00 00 00 	nop                                            
                                                                      
    return NULL;                                                      
4000adf0:	81 c7 e0 08 	ret                                            
4000adf4:	91 e8 20 00 	restore  %g0, 0, %o0                           
  }                                                                   
                                                                      
  dtab = disktab + major;                                             
4000adf8:	c6 00 61 98 	ld  [ %g1 + 0x198 ], %g3                       
4000adfc:	b7 2f 60 03 	sll  %i5, 3, %i3                               
4000ae00:	b6 00 c0 1b 	add  %g3, %i3, %i3                             
  while (true) {                                                      
    if (dtab->minor == NULL || minor >= dtab->size) {                 
4000ae04:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
4000ae08:	80 a0 60 00 	cmp  %g1, 0                                    
4000ae0c:	22 80 00 07 	be,a   4000ae28 <rtems_disk_next+0xa8>         
4000ae10:	ba 07 60 01 	inc  %i5                                       
4000ae14:	c8 06 e0 04 	ld  [ %i3 + 4 ], %g4                           
4000ae18:	80 a7 00 04 	cmp  %i4, %g4                                  
4000ae1c:	0a 80 00 09 	bcs  4000ae40 <rtems_disk_next+0xc0>           
4000ae20:	b5 2f 20 02 	sll  %i4, 2, %i2                               
       minor = 0;                                                     
       ++major;                                                       
4000ae24:	ba 07 60 01 	inc  %i5                                       
       if (major >= disktab_size) {                                   
4000ae28:	80 a7 40 02 	cmp  %i5, %g2                                  
4000ae2c:	1a bf ff ef 	bcc  4000ade8 <rtems_disk_next+0x68>           
4000ae30:	b7 2f 60 03 	sll  %i5, 3, %i3                               
  }                                                                   
                                                                      
  dtab = disktab + major;                                             
  while (true) {                                                      
    if (dtab->minor == NULL || minor >= dtab->size) {                 
       minor = 0;                                                     
4000ae34:	b8 10 20 00 	clr  %i4                                       
       if (major >= disktab_size) {                                   
         disk_unlock();                                               
                                                                      
         return NULL;                                                 
       }                                                              
       dtab = disktab + major;                                        
4000ae38:	10 bf ff f3 	b  4000ae04 <rtems_disk_next+0x84>             
4000ae3c:	b6 00 c0 1b 	add  %g3, %i3, %i3                             
    } else if (dtab->minor [minor] == NULL) {                         
4000ae40:	c2 00 40 1a 	ld  [ %g1 + %i2 ], %g1                         
4000ae44:	80 a0 60 00 	cmp  %g1, 0                                    
4000ae48:	02 bf ff ef 	be  4000ae04 <rtems_disk_next+0x84>            
4000ae4c:	b8 07 20 01 	inc  %i4                                       
      ++minor;                                                        
    } else {                                                          
      ++dtab->minor [minor]->uses;                                    
4000ae50:	c4 00 60 14 	ld  [ %g1 + 0x14 ], %g2                        
4000ae54:	84 00 a0 01 	inc  %g2                                       
      disk_unlock();                                                  
4000ae58:	7f ff fe dd 	call  4000a9cc <disk_unlock>                   
4000ae5c:	c4 20 60 14 	st  %g2, [ %g1 + 0x14 ]                        
                                                                      
      return dtab->minor [minor];                                     
4000ae60:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
4000ae64:	f0 00 40 1a 	ld  [ %g1 + %i2 ], %i0                         
    }                                                                 
  }                                                                   
}                                                                     
4000ae68:	81 c7 e0 08 	ret                                            
4000ae6c:	81 e8 00 00 	restore                                        
                                                                      

40003fb8 <rtems_disk_obtain>: return RTEMS_SUCCESSFUL; } rtems_disk_device * rtems_disk_obtain(dev_t dev) {
40003fb8:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
40003fbc:	7f ff fb 1e 	call  40002c34 <sparc_disable_interrupts>      
40003fc0:	b8 10 00 18 	mov  %i0, %i4                                  
40003fc4:	b6 10 00 08 	mov  %o0, %i3                                  
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_disk_device *dd = NULL;                                       
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  rtems_interrupt_lock_acquire(&diskdevs_lock, &lock_context);        
  if (!diskdevs_protected) {                                          
40003fc8:	03 10 00 70 	sethi  %hi(0x4001c000), %g1                    
40003fcc:	c2 08 62 78 	ldub  [ %g1 + 0x278 ], %g1	! 4001c278 <diskdevs_protected>
40003fd0:	80 a0 60 00 	cmp  %g1, 0                                    
40003fd4:	12 80 00 0a 	bne  40003ffc <rtems_disk_obtain+0x44>         <== NEVER TAKEN
40003fd8:	92 10 00 19 	mov  %i1, %o1                                  
    /* Frequent and quickest case */                                  
    dd = get_disk_entry(dev, false);                                  
40003fdc:	90 10 00 18 	mov  %i0, %o0                                  
40003fe0:	7f ff fe 63 	call  4000396c <get_disk_entry>                
40003fe4:	94 10 20 00 	clr  %o2                                       
40003fe8:	b0 10 00 08 	mov  %o0, %i0                                  
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
40003fec:	7f ff fb 15 	call  40002c40 <sparc_enable_interrupts>       
40003ff0:	90 10 00 1b 	mov  %i3, %o0                                  
40003ff4:	81 c7 e0 08 	ret                                            
40003ff8:	81 e8 00 00 	restore                                        
40003ffc:	7f ff fb 11 	call  40002c40 <sparc_enable_interrupts>       <== NOT EXECUTED
40004000:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
    rtems_interrupt_lock_release(&diskdevs_lock, &lock_context);      
  } else {                                                            
    rtems_interrupt_lock_release(&diskdevs_lock, &lock_context);      
                                                                      
    sc = disk_lock();                                                 
40004004:	7f ff fe 83 	call  40003a10 <disk_lock>                     <== NOT EXECUTED
40004008:	01 00 00 00 	nop                                            <== NOT EXECUTED
    if (sc == RTEMS_SUCCESSFUL) {                                     
4000400c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40004010:	12 bf ff f9 	bne  40003ff4 <rtems_disk_obtain+0x3c>         <== NOT EXECUTED
40004014:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
      dd = get_disk_entry(dev, false);                                
40004018:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4000401c:	7f ff fe 54 	call  4000396c <get_disk_entry>                <== NOT EXECUTED
40004020:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
      disk_unlock();                                                  
40004024:	7f ff fe ef 	call  40003be0 <disk_unlock>                   <== NOT EXECUTED
40004028:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
  return dd;                                                          
}                                                                     
4000402c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40004030:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40017d38 <rtems_dosfs_create_default_converter>: rtems_dosfs_convert_control super; uint8_t buffer[MSDOS_NAME_MAX_LFN_BYTES]; } msdos_default_convert_control; rtems_dosfs_convert_control *rtems_dosfs_create_default_converter(void) {
40017d38:	9d e3 bf a0 	save  %sp, -96, %sp                            
  msdos_default_convert_control *self = malloc( sizeof( *self ) );    
40017d3c:	7f ff b5 58 	call  4000529c <malloc>                        
40017d40:	90 10 22 14 	mov  0x214, %o0                                
                                                                      
  if ( self != NULL ) {                                               
40017d44:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40017d48:	02 80 00 08 	be  40017d68 <rtems_dosfs_create_default_converter+0x30><== NEVER TAKEN
40017d4c:	03 10 00 b4 	sethi  %hi(0x4002d000), %g1                    
    rtems_dosfs_convert_control *super = &self->super;                
                                                                      
    super->handler = &msdos_default_convert_handler;                  
40017d50:	82 10 62 60 	or  %g1, 0x260, %g1	! 4002d260 <msdos_default_convert_handler>
40017d54:	c2 26 00 00 	st  %g1, [ %i0 ]                               
    super->buffer.data = &self->buffer;                               
40017d58:	82 06 20 0c 	add  %i0, 0xc, %g1                             
40017d5c:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
    super->buffer.size = sizeof( self->buffer );                      
40017d60:	82 10 22 08 	mov  0x208, %g1                                
40017d64:	c2 26 20 08 	st  %g1, [ %i0 + 8 ]                           
  }                                                                   
                                                                      
  return &self->super;                                                
}                                                                     
40017d68:	81 c7 e0 08 	ret                                            
40017d6c:	81 e8 00 00 	restore                                        
                                                                      

4000ebdc <rtems_dosfs_create_utf8_converter>: }; rtems_dosfs_convert_control *rtems_dosfs_create_utf8_converter( const char *codepage ) {
4000ebdc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  msdos_utf8_convert_control *self = malloc( sizeof( *self ) );       
4000ebe0:	7f ff de 76 	call  400065b8 <malloc>                        
4000ebe4:	90 10 24 2c 	mov  0x42c, %o0                                
                                                                      
  if ( self != NULL ) {                                               
4000ebe8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000ebec:	02 80 00 2a 	be  4000ec94 <rtems_dosfs_create_utf8_converter+0xb8><== NEVER TAKEN
4000ebf0:	39 10 00 e4 	sethi  %hi(0x40039000), %i4                    
    self->desc_codepage_to_utf8 = iconv_open( "UTF-8", codepage );    
4000ebf4:	92 10 00 18 	mov  %i0, %o1                                  
4000ebf8:	40 00 43 6f 	call  4001f9b4 <iconv_open>                    
4000ebfc:	90 17 21 e0 	or  %i4, 0x1e0, %o0                            
    self->desc_utf8_to_codepage = iconv_open( codepage, "UTF-8" );    
4000ec00:	92 17 21 e0 	or  %i4, 0x1e0, %o1                            
)                                                                     
{                                                                     
  msdos_utf8_convert_control *self = malloc( sizeof( *self ) );       
                                                                      
  if ( self != NULL ) {                                               
    self->desc_codepage_to_utf8 = iconv_open( "UTF-8", codepage );    
4000ec04:	d0 27 60 0c 	st  %o0, [ %i5 + 0xc ]                         
    self->desc_utf8_to_codepage = iconv_open( codepage, "UTF-8" );    
4000ec08:	40 00 43 6b 	call  4001f9b4 <iconv_open>                    
4000ec0c:	90 10 00 18 	mov  %i0, %o0                                  
    self->desc_utf16_to_utf8    = iconv_open( "UTF-8", "UTF-16LE" );  
4000ec10:	37 10 00 e4 	sethi  %hi(0x40039000), %i3                    
{                                                                     
  msdos_utf8_convert_control *self = malloc( sizeof( *self ) );       
                                                                      
  if ( self != NULL ) {                                               
    self->desc_codepage_to_utf8 = iconv_open( "UTF-8", codepage );    
    self->desc_utf8_to_codepage = iconv_open( codepage, "UTF-8" );    
4000ec14:	d0 27 60 10 	st  %o0, [ %i5 + 0x10 ]                        
    self->desc_utf16_to_utf8    = iconv_open( "UTF-8", "UTF-16LE" );  
4000ec18:	92 16 e1 e8 	or  %i3, 0x1e8, %o1                            
4000ec1c:	40 00 43 66 	call  4001f9b4 <iconv_open>                    
4000ec20:	90 17 21 e0 	or  %i4, 0x1e0, %o0                            
    self->desc_utf8_to_utf16    = iconv_open( "UTF-16LE", "UTF-8" );  
4000ec24:	92 17 21 e0 	or  %i4, 0x1e0, %o1                            
  msdos_utf8_convert_control *self = malloc( sizeof( *self ) );       
                                                                      
  if ( self != NULL ) {                                               
    self->desc_codepage_to_utf8 = iconv_open( "UTF-8", codepage );    
    self->desc_utf8_to_codepage = iconv_open( codepage, "UTF-8" );    
    self->desc_utf16_to_utf8    = iconv_open( "UTF-8", "UTF-16LE" );  
4000ec28:	d0 27 60 14 	st  %o0, [ %i5 + 0x14 ]                        
    self->desc_utf8_to_utf16    = iconv_open( "UTF-16LE", "UTF-8" );  
4000ec2c:	40 00 43 62 	call  4001f9b4 <iconv_open>                    
4000ec30:	90 16 e1 e8 	or  %i3, 0x1e8, %o0                            
                                                                      
    if (                                                              
4000ec34:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000ec38:	80 a0 7f ff 	cmp  %g1, -1                                   
4000ec3c:	02 80 00 13 	be  4000ec88 <rtems_dosfs_create_utf8_converter+0xac><== NEVER TAKEN
4000ec40:	d0 27 60 18 	st  %o0, [ %i5 + 0x18 ]                        
      self->desc_utf16_to_utf8 != INVALID_ICONV_DESC                  
        && self->desc_utf8_to_codepage != INVALID_ICONV_DESC          
4000ec44:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
4000ec48:	80 a0 7f ff 	cmp  %g1, -1                                   
4000ec4c:	22 80 00 10 	be,a   4000ec8c <rtems_dosfs_create_utf8_converter+0xb0><== NEVER TAKEN
4000ec50:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        && self->desc_codepage_to_utf8 != INVALID_ICONV_DESC          
4000ec54:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4000ec58:	80 a0 7f ff 	cmp  %g1, -1                                   
4000ec5c:	02 80 00 0b 	be  4000ec88 <rtems_dosfs_create_utf8_converter+0xac><== NEVER TAKEN
4000ec60:	80 a2 3f ff 	cmp  %o0, -1                                   
        && self->desc_utf8_to_utf16 != INVALID_ICONV_DESC             
4000ec64:	02 80 00 09 	be  4000ec88 <rtems_dosfs_create_utf8_converter+0xac><== NEVER TAKEN
4000ec68:	03 10 00 e4 	sethi  %hi(0x40039000), %g1                    
    ) {                                                               
      rtems_dosfs_convert_control *super = &self->super;              
                                                                      
      super->handler = &msdos_utf8_convert_handler;                   
4000ec6c:	82 10 62 18 	or  %g1, 0x218, %g1	! 40039218 <msdos_utf8_convert_handler>
4000ec70:	c2 27 40 00 	st  %g1, [ %i5 ]                               
      super->buffer.data = &self->buffer;                             
4000ec74:	82 07 60 1c 	add  %i5, 0x1c, %g1                            
4000ec78:	c2 27 60 04 	st  %g1, [ %i5 + 4 ]                           
      super->buffer.size = sizeof( self->buffer );                    
4000ec7c:	82 10 24 10 	mov  0x410, %g1                                
    if (                                                              
      self->desc_utf16_to_utf8 != INVALID_ICONV_DESC                  
        && self->desc_utf8_to_codepage != INVALID_ICONV_DESC          
        && self->desc_codepage_to_utf8 != INVALID_ICONV_DESC          
        && self->desc_utf8_to_utf16 != INVALID_ICONV_DESC             
    ) {                                                               
4000ec80:	10 80 00 05 	b  4000ec94 <rtems_dosfs_create_utf8_converter+0xb8>
4000ec84:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
                                                                      
      super->handler = &msdos_utf8_convert_handler;                   
      super->buffer.data = &self->buffer;                             
      super->buffer.size = sizeof( self->buffer );                    
    } else {                                                          
      msdos_utf8_destroy( &self->super );                             
4000ec88:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4000ec8c:	7f ff ff 73 	call  4000ea58 <msdos_utf8_destroy>            <== NOT EXECUTED
4000ec90:	ba 10 20 00 	clr  %i5                                       <== NOT EXECUTED
      self = NULL;                                                    
    }                                                                 
  }                                                                   
                                                                      
  return &self->super;                                                
}                                                                     
4000ec94:	81 c7 e0 08 	ret                                            
4000ec98:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

4000e3b0 <rtems_dosfs_initialize>: */ int rtems_dosfs_initialize( rtems_filesystem_mount_table_entry_t *mt_entry, const void *data ) {
4000e3b0:	9d e3 bf a0 	save  %sp, -96, %sp                            
    int                                rc = 0;                        
    const rtems_dosfs_mount_options   *mount_options = data;          
    rtems_dosfs_convert_control       *converter;                     
                                                                      
                                                                      
    if (mount_options == NULL || mount_options->converter == NULL) {  
4000e3b4:	80 a6 60 00 	cmp  %i1, 0                                    
4000e3b8:	02 80 00 06 	be  4000e3d0 <rtems_dosfs_initialize+0x20>     
4000e3bc:	01 00 00 00 	nop                                            
4000e3c0:	f8 06 40 00 	ld  [ %i1 ], %i4                               
4000e3c4:	80 a7 20 00 	cmp  %i4, 0                                    
4000e3c8:	12 80 00 07 	bne  4000e3e4 <rtems_dosfs_initialize+0x34>    <== ALWAYS TAKEN
4000e3cc:	33 10 00 b3 	sethi  %hi(0x4002cc00), %i1                    
        converter = rtems_dosfs_create_default_converter();           
4000e3d0:	40 00 26 5a 	call  40017d38 <rtems_dosfs_create_default_converter>
4000e3d4:	01 00 00 00 	nop                                            
    } else {                                                          
        converter = mount_options->converter;                         
    }                                                                 
                                                                      
    if (converter != NULL) {                                          
4000e3d8:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4000e3dc:	02 80 00 08 	be  4000e3fc <rtems_dosfs_initialize+0x4c>     <== NEVER TAKEN
4000e3e0:	33 10 00 b3 	sethi  %hi(0x4002cc00), %i1                    
        rc = msdos_initialize_support(mt_entry,                       
4000e3e4:	35 10 00 b4 	sethi  %hi(0x4002d000), %i2                    
4000e3e8:	37 10 00 b4 	sethi  %hi(0x4002d000), %i3                    
4000e3ec:	b2 16 60 9c 	or  %i1, 0x9c, %i1                             
4000e3f0:	b4 16 a2 bc 	or  %i2, 0x2bc, %i2                            
4000e3f4:	40 00 00 08 	call  4000e414 <msdos_initialize_support>      
4000e3f8:	97 ee e2 80 	restore  %i3, 0x280, %o3                       
                                      &msdos_ops,                     
                                      &msdos_file_handlers,           
                                      &msdos_dir_handlers,            
                                      converter);                     
    } else {                                                          
        errno = ENOMEM;                                               
4000e3fc:	40 00 38 24 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000e400:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4000e404:	82 10 20 0c 	mov  0xc, %g1                                  <== NOT EXECUTED
4000e408:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
        rc = -1;                                                      
    }                                                                 
                                                                      
    return rc;                                                        
}                                                                     
4000e40c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000e410:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000517c <rtems_fdisk_abort.constprop.9>: * * @param format The format string. See printf for details. * @param ... The arguments for the format text. */ static void rtems_fdisk_abort (const char *format, ...)
4000517c:	9d e3 bf 98 	save  %sp, -104, %sp                           <== NOT EXECUTED
{                                                                     
  va_list args;                                                       
  va_start (args, format);                                            
40005180:	82 07 a0 48 	add  %fp, 0x48, %g1                            <== NOT EXECUTED
40005184:	f2 27 a0 48 	st  %i1, [ %fp + 0x48 ]                        <== NOT EXECUTED
40005188:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          <== NOT EXECUTED
4000518c:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        <== NOT EXECUTED
40005190:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        <== NOT EXECUTED
40005194:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        <== NOT EXECUTED
  fprintf (stderr, "fdisk:abort:");                                   
40005198:	7f ff f0 b8 	call  40001478 <__getreent>                    <== NOT EXECUTED
4000519c:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        <== NOT EXECUTED
400051a0:	d2 02 20 0c 	ld  [ %o0 + 0xc ], %o1                         <== NOT EXECUTED
400051a4:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
400051a8:	40 00 71 2b 	call  40021654 <fputs>                         <== NOT EXECUTED
400051ac:	90 12 21 b8 	or  %o0, 0x1b8, %o0	! 400321b8 <__FUNCTION__.6501+0x150><== NOT EXECUTED
  vfprintf (stderr, format, args);                                    
400051b0:	7f ff f0 b2 	call  40001478 <__getreent>                    <== NOT EXECUTED
400051b4:	01 00 00 00 	nop                                            <== NOT EXECUTED
400051b8:	d2 02 20 0c 	ld  [ %o0 + 0xc ], %o1                         <== NOT EXECUTED
400051bc:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
400051c0:	40 00 71 25 	call  40021654 <fputs>                         <== NOT EXECUTED
400051c4:	90 12 21 c8 	or  %o0, 0x1c8, %o0	! 400321c8 <__FUNCTION__.6501+0x160><== NOT EXECUTED
  fprintf (stderr, "\n");                                             
400051c8:	7f ff f0 ac 	call  40001478 <__getreent>                    <== NOT EXECUTED
400051cc:	01 00 00 00 	nop                                            <== NOT EXECUTED
400051d0:	d2 02 20 0c 	ld  [ %o0 + 0xc ], %o1                         <== NOT EXECUTED
400051d4:	40 00 70 ec 	call  40021584 <fputc>                         <== NOT EXECUTED
400051d8:	90 10 20 0a 	mov  0xa, %o0                                  <== NOT EXECUTED
  fflush (stderr);                                                    
400051dc:	7f ff f0 a7 	call  40001478 <__getreent>                    <== NOT EXECUTED
400051e0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400051e4:	40 00 6f ed 	call  40021198 <fflush>                        <== NOT EXECUTED
400051e8:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         <== NOT EXECUTED
  va_end (args);                                                      
  exit (1);                                                           
400051ec:	40 00 6f 31 	call  40020eb0 <exit>                          <== NOT EXECUTED
400051f0:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
                                                                      

40005df0 <rtems_fdisk_compact>: * used segments that will fit. The used queue is sorted on the least * number of active pages. */ static int rtems_fdisk_compact (rtems_flashdisk* fd) {
40005df0:	9d e3 bf 98 	save  %sp, -104, %sp                           
static bool                                                           
rtems_fdisk_is_erased_blocks_starvation (rtems_flashdisk* fd)         
{                                                                     
  bool starvation = fd->erased_blocks < fd->starvation_threshold;     
                                                                      
  if (starvation)                                                     
40005df4:	c4 06 20 28 	ld  [ %i0 + 0x28 ], %g2                        
40005df8:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
40005dfc:	80 a0 80 01 	cmp  %g2, %g1                                  
40005e00:	1a 80 00 28 	bcc  40005ea0 <rtems_fdisk_compact+0xb0>       
40005e04:	ba 10 00 18 	mov  %i0, %i5                                  
    fd->starvations++;                                                
40005e08:	c2 06 20 70 	ld  [ %i0 + 0x70 ], %g1                        
  uint32_t pages;                                                     
                                                                      
  if (rtems_fdisk_is_erased_blocks_starvation (fd))                   
  {                                                                   
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " resolve starvation");                   
40005e0c:	90 10 00 18 	mov  %i0, %o0                                  
rtems_fdisk_is_erased_blocks_starvation (rtems_flashdisk* fd)         
{                                                                     
  bool starvation = fd->erased_blocks < fd->starvation_threshold;     
                                                                      
  if (starvation)                                                     
    fd->starvations++;                                                
40005e10:	82 00 60 01 	inc  %g1                                       
  uint32_t pages;                                                     
                                                                      
  if (rtems_fdisk_is_erased_blocks_starvation (fd))                   
  {                                                                   
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " resolve starvation");                   
40005e14:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
rtems_fdisk_is_erased_blocks_starvation (rtems_flashdisk* fd)         
{                                                                     
  bool starvation = fd->erased_blocks < fd->starvation_threshold;     
                                                                      
  if (starvation)                                                     
    fd->starvations++;                                                
40005e18:	c2 26 20 70 	st  %g1, [ %i0 + 0x70 ]                        
  uint32_t pages;                                                     
                                                                      
  if (rtems_fdisk_is_erased_blocks_starvation (fd))                   
  {                                                                   
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " resolve starvation");                   
40005e1c:	7f ff fc 3d 	call  40004f10 <rtems_fdisk_printf>            
40005e20:	92 12 61 90 	or  %o1, 0x190, %o1                            
#endif                                                                
                                                                      
    ssc = rtems_fdisk_segment_queue_pop_head (&fd->used);             
40005e24:	7f ff fb c3 	call  40004d30 <rtems_fdisk_segment_queue_pop_head>
40005e28:	90 06 20 40 	add  %i0, 0x40, %o0                            
    if (!ssc)                                                         
40005e2c:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40005e30:	12 80 00 07 	bne  40005e4c <rtems_fdisk_compact+0x5c>       <== ALWAYS TAKEN
40005e34:	01 00 00 00 	nop                                            
      ssc = rtems_fdisk_segment_queue_pop_head (&fd->available);      
40005e38:	7f ff fb be 	call  40004d30 <rtems_fdisk_segment_queue_pop_head><== NOT EXECUTED
40005e3c:	90 06 20 34 	add  %i0, 0x34, %o0                            <== NOT EXECUTED
                                                                      
    if (ssc)                                                          
40005e40:	b8 92 20 00 	orcc  %o0, 0, %i4                              <== NOT EXECUTED
40005e44:	02 80 00 12 	be  40005e8c <rtems_fdisk_compact+0x9c>        <== NOT EXECUTED
40005e48:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
    {                                                                 
      dsc = rtems_fdisk_seg_most_available (&fd->available);          
40005e4c:	7f ff fc bb 	call  40005138 <rtems_fdisk_seg_most_available.isra.8>
40005e50:	d0 07 60 34 	ld  [ %i5 + 0x34 ], %o0                        
      if (dsc)                                                        
40005e54:	94 92 20 00 	orcc  %o0, 0, %o2                              
40005e58:	02 80 00 0a 	be  40005e80 <rtems_fdisk_compact+0x90>        <== NEVER TAKEN
40005e5c:	92 10 00 1c 	mov  %i4, %o1                                  
      {                                                               
        ret = rtems_fdisk_recycle_segment (fd, ssc, dsc, &pages);     
40005e60:	90 10 00 1d 	mov  %i5, %o0                                  
40005e64:	7f ff fe f9 	call  40005a48 <rtems_fdisk_recycle_segment>   
40005e68:	96 07 bf fc 	add  %fp, -4, %o3                              
        if (ret)                                                      
40005e6c:	80 a2 20 00 	cmp  %o0, 0                                    
40005e70:	02 80 00 0d 	be  40005ea4 <rtems_fdisk_compact+0xb4>        <== ALWAYS TAKEN
40005e74:	33 10 00 c9 	sethi  %hi(0x40032400), %i1                    
                                                                      
    compacted_segs += segments;                                       
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40005e78:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005e7c:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
        if (ret)                                                      
          return ret;                                                 
      }                                                               
      else                                                            
      {                                                               
        rtems_fdisk_error ("compacting: starvation");                 
40005e80:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
40005e84:	10 80 00 03 	b  40005e90 <rtems_fdisk_compact+0xa0>         <== NOT EXECUTED
40005e88:	90 12 21 a8 	or  %o0, 0x1a8, %o0	! 400325a8 <__FUNCTION__.6501+0x540><== NOT EXECUTED
        return EIO;                                                   
      }                                                               
    }                                                                 
    else                                                              
    {                                                                 
      rtems_fdisk_error ("compacting: nothing to recycle");           
40005e8c:	90 12 21 c0 	or  %o0, 0x1c0, %o0                            <== NOT EXECUTED
40005e90:	7f ff fc 83 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005e94:	01 00 00 00 	nop                                            <== NOT EXECUTED
      return EIO;                                                     
40005e98:	10 80 00 5c 	b  40006008 <rtems_fdisk_compact+0x218>        <== NOT EXECUTED
40005e9c:	90 10 20 05 	mov  5, %o0	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
  {                                                                   
    uint32_t                 dst_pages;                               
    uint32_t                 segments;                                
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " compacting");                           
40005ea0:	33 10 00 c9 	sethi  %hi(0x40032400), %i1                    
    dst_pages = rtems_fdisk_seg_pages_available (dsc);                
    segments = 0;                                                     
    pages = 0;                                                        
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " dsc:%02d-%03d: most available",         
40005ea4:	31 10 00 c9 	sethi  %hi(0x40032400), %i0                    
#endif                                                                
      break;                                                          
    }                                                                 
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " ssc scan: %d-%d: p=%ld, seg=%ld",       
40005ea8:	21 10 00 c9 	sethi  %hi(0x40032400), %l0                    
40005eac:	b4 10 20 00 	clr  %i2                                       
  {                                                                   
    uint32_t                 dst_pages;                               
    uint32_t                 segments;                                
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " compacting");                           
40005eb0:	b2 16 61 e0 	or  %i1, 0x1e0, %i1                            
    dst_pages = rtems_fdisk_seg_pages_available (dsc);                
    segments = 0;                                                     
    pages = 0;                                                        
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " dsc:%02d-%03d: most available",         
40005eb4:	b0 16 22 28 	or  %i0, 0x228, %i0                            
#endif                                                                
      break;                                                          
    }                                                                 
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " ssc scan: %d-%d: p=%ld, seg=%ld",       
40005eb8:	a0 14 22 60 	or  %l0, 0x260, %l0                            
                        ssc->device, ssc->segment,                    
                        pages, segments);                             
#endif                                                                
                                                                      
    rtems_fdisk_segment_queue_remove (&fd->available, dsc);           
40005ebc:	a2 07 60 34 	add  %i5, 0x34, %l1                            
     * We now copy the pages to the new segment.                      
     */                                                               
                                                                      
    while (pages)                                                     
    {                                                                 
      ssc = rtems_fdisk_segment_queue_pop_head (&fd->used);           
40005ec0:	a4 07 60 40 	add  %i5, 0x40, %l2                            
      rtems_fdisk_error ("compacting: nothing to recycle");           
      return EIO;                                                     
    }                                                                 
  }                                                                   
                                                                      
  while (fd->used.head)                                               
40005ec4:	c2 07 60 40 	ld  [ %i5 + 0x40 ], %g1                        
40005ec8:	80 a0 60 00 	cmp  %g1, 0                                    
40005ecc:	02 80 00 2e 	be  40005f84 <rtems_fdisk_compact+0x194>       
40005ed0:	92 10 00 19 	mov  %i1, %o1                                  
  {                                                                   
    uint32_t                 dst_pages;                               
    uint32_t                 segments;                                
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " compacting");                           
40005ed4:	7f ff fc 0f 	call  40004f10 <rtems_fdisk_printf>            
40005ed8:	90 10 00 1d 	mov  %i5, %o0                                  
#endif                                                                
                                                                      
    dsc = rtems_fdisk_seg_most_available (&fd->available);            
40005edc:	7f ff fc 97 	call  40005138 <rtems_fdisk_seg_most_available.isra.8>
40005ee0:	d0 07 60 34 	ld  [ %i5 + 0x34 ], %o0                        
                                                                      
    if (dsc == 0)                                                     
40005ee4:	b6 92 20 00 	orcc  %o0, 0, %i3                              
40005ee8:	12 80 00 05 	bne  40005efc <rtems_fdisk_compact+0x10c>      <== ALWAYS TAKEN
40005eec:	01 00 00 00 	nop                                            
    {                                                                 
      rtems_fdisk_error ("compacting: no available segments to compact too");
40005ef0:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
40005ef4:	10 bf ff e7 	b  40005e90 <rtems_fdisk_compact+0xa0>         <== NOT EXECUTED
40005ef8:	90 12 21 f0 	or  %o0, 0x1f0, %o0	! 400325f0 <__FUNCTION__.6501+0x588><== NOT EXECUTED
      return EIO;                                                     
    }                                                                 
                                                                      
    ssc = fd->used.head;                                              
    dst_pages = rtems_fdisk_seg_pages_available (dsc);                
40005efc:	7f ff fb eb 	call  40004ea8 <rtems_fdisk_seg_pages_available>
40005f00:	01 00 00 00 	nop                                            
    segments = 0;                                                     
    pages = 0;                                                        
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " dsc:%02d-%03d: most available",         
40005f04:	d4 06 e0 08 	ld  [ %i3 + 8 ], %o2                           
40005f08:	d6 06 e0 0c 	ld  [ %i3 + 0xc ], %o3                         
    {                                                                 
      rtems_fdisk_error ("compacting: no available segments to compact too");
      return EIO;                                                     
    }                                                                 
                                                                      
    ssc = fd->used.head;                                              
40005f0c:	f8 07 60 40 	ld  [ %i5 + 0x40 ], %i4                        
    dst_pages = rtems_fdisk_seg_pages_available (dsc);                
40005f10:	a6 10 00 08 	mov  %o0, %l3                                  
    segments = 0;                                                     
    pages = 0;                                                        
40005f14:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " dsc:%02d-%03d: most available",         
40005f18:	90 10 00 1d 	mov  %i5, %o0                                  
40005f1c:	7f ff fb fd 	call  40004f10 <rtems_fdisk_printf>            
40005f20:	92 10 00 18 	mov  %i0, %o1                                  
40005f24:	d8 07 bf fc 	ld  [ %fp + -4 ], %o4                          
      return EIO;                                                     
    }                                                                 
                                                                      
    ssc = fd->used.head;                                              
    dst_pages = rtems_fdisk_seg_pages_available (dsc);                
    segments = 0;                                                     
40005f28:	9a 10 20 00 	clr  %o5                                       
     * we handle during one compaction. A lower number means less aggressive
     * compaction or less delay when compacting but it may mean the disk
     * will fill.                                                     
     */                                                               
                                                                      
    while (ssc &&                                                     
40005f2c:	80 a7 20 00 	cmp  %i4, 0                                    
40005f30:	32 80 00 09 	bne,a   40005f54 <rtems_fdisk_compact+0x164>   
40005f34:	c2 07 20 1c 	ld  [ %i4 + 0x1c ], %g1                        
40005f38:	d8 27 bf fc 	st  %o4, [ %fp + -4 ]                          
     */                                                               
                                                                      
    if (!ssc || (pages == 0) || ((compacted_segs + segments) == 1))   
    {                                                                 
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_printf (fd, " nothing to compact");                 
40005f3c:	90 10 00 1d 	mov  %i5, %o0                                  
40005f40:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
40005f44:	7f ff fb f3 	call  40004f10 <rtems_fdisk_printf>            
40005f48:	92 12 62 48 	or  %o1, 0x248, %o1	! 40032648 <__FUNCTION__.6501+0x5e0>
    }                                                                 
                                                                      
    compacted_segs += segments;                                       
  }                                                                   
                                                                      
  return 0;                                                           
40005f4c:	10 80 00 2f 	b  40006008 <rtems_fdisk_compact+0x218>        
40005f50:	90 10 20 00 	clr  %o0                                       
     * compaction or less delay when compacting but it may mean the disk
     * will fill.                                                     
     */                                                               
                                                                      
    while (ssc &&                                                     
           ((pages + ssc->pages_active) < dst_pages) &&               
40005f54:	82 03 00 01 	add  %o4, %g1, %g1                             
     * we handle during one compaction. A lower number means less aggressive
     * compaction or less delay when compacting but it may mean the disk
     * will fill.                                                     
     */                                                               
                                                                      
    while (ssc &&                                                     
40005f58:	80 a0 40 13 	cmp  %g1, %l3                                  
40005f5c:	1a 80 00 0c 	bcc  40005f8c <rtems_fdisk_compact+0x19c>      
40005f60:	86 03 40 1a 	add  %o5, %i2, %g3                             
           ((pages + ssc->pages_active) < dst_pages) &&               
40005f64:	c4 07 60 0c 	ld  [ %i5 + 0xc ], %g2                         
40005f68:	80 a0 c0 02 	cmp  %g3, %g2                                  
40005f6c:	1a 80 00 09 	bcc  40005f90 <rtems_fdisk_compact+0x1a0>      <== NEVER TAKEN
40005f70:	80 a3 20 00 	cmp  %o4, 0                                    
           ((compacted_segs + segments) < fd->compact_segs))          
    {                                                                 
      pages += ssc->pages_active;                                     
      segments++;                                                     
40005f74:	9a 03 60 01 	inc  %o5                                       
      ssc = ssc->next;                                                
40005f78:	f8 07 00 00 	ld  [ %i4 ], %i4                               
                                                                      
    while (ssc &&                                                     
           ((pages + ssc->pages_active) < dst_pages) &&               
           ((compacted_segs + segments) < fd->compact_segs))          
    {                                                                 
      pages += ssc->pages_active;                                     
40005f7c:	10 bf ff ec 	b  40005f2c <rtems_fdisk_compact+0x13c>        
40005f80:	98 10 00 01 	mov  %g1, %o4                                  
40005f84:	10 80 00 21 	b  40006008 <rtems_fdisk_compact+0x218>        
40005f88:	90 10 20 00 	clr  %o0                                       
     * We need a source segment and have pages to copy and            
     * compacting one segment to another is silly. Compaction needs   
     * to free at least one more segment.                             
     */                                                               
                                                                      
    if (!ssc || (pages == 0) || ((compacted_segs + segments) == 1))   
40005f8c:	80 a3 20 00 	cmp  %o4, 0                                    
40005f90:	02 bf ff eb 	be  40005f3c <rtems_fdisk_compact+0x14c>       
40005f94:	d8 27 bf fc 	st  %o4, [ %fp + -4 ]                          
40005f98:	b4 06 80 0d 	add  %i2, %o5, %i2                             
40005f9c:	80 a6 a0 01 	cmp  %i2, 1                                    
40005fa0:	02 bf ff e8 	be  40005f40 <rtems_fdisk_compact+0x150>       
40005fa4:	90 10 00 1d 	mov  %i5, %o0                                  
#endif                                                                
      break;                                                          
    }                                                                 
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_printf (fd, " ssc scan: %d-%d: p=%ld, seg=%ld",       
40005fa8:	d4 07 20 08 	ld  [ %i4 + 8 ], %o2                           
40005fac:	d6 07 20 0c 	ld  [ %i4 + 0xc ], %o3                         
40005fb0:	92 10 00 10 	mov  %l0, %o1                                  
40005fb4:	7f ff fb d7 	call  40004f10 <rtems_fdisk_printf>            
40005fb8:	90 10 00 1d 	mov  %i5, %o0                                  
                        ssc->device, ssc->segment,                    
                        pages, segments);                             
#endif                                                                
                                                                      
    rtems_fdisk_segment_queue_remove (&fd->available, dsc);           
40005fbc:	90 10 00 11 	mov  %l1, %o0                                  
40005fc0:	7f ff fb 7e 	call  40004db8 <rtems_fdisk_segment_queue_remove>
40005fc4:	92 10 00 1b 	mov  %i3, %o1                                  
                                                                      
    /*                                                                
     * We now copy the pages to the new segment.                      
     */                                                               
                                                                      
    while (pages)                                                     
40005fc8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40005fcc:	80 a0 60 00 	cmp  %g1, 0                                    
40005fd0:	22 bf ff be 	be,a   40005ec8 <rtems_fdisk_compact+0xd8>     
40005fd4:	c2 07 60 40 	ld  [ %i5 + 0x40 ], %g1                        
    {                                                                 
      ssc = rtems_fdisk_segment_queue_pop_head (&fd->used);           
40005fd8:	7f ff fb 56 	call  40004d30 <rtems_fdisk_segment_queue_pop_head>
40005fdc:	90 10 00 12 	mov  %l2, %o0                                  
                                                                      
      if (ssc)                                                        
40005fe0:	92 92 20 00 	orcc  %o0, 0, %o1                              
40005fe4:	02 bf ff fa 	be  40005fcc <rtems_fdisk_compact+0x1dc>       <== NEVER TAKEN
40005fe8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
      {                                                               
        ret = rtems_fdisk_recycle_segment (fd, ssc, dsc, &pages);     
40005fec:	90 10 00 1d 	mov  %i5, %o0                                  
40005ff0:	94 10 00 1b 	mov  %i3, %o2                                  
40005ff4:	7f ff fe 95 	call  40005a48 <rtems_fdisk_recycle_segment>   
40005ff8:	96 07 bf fc 	add  %fp, -4, %o3                              
        if (ret)                                                      
40005ffc:	80 a2 20 00 	cmp  %o0, 0                                    
40006000:	02 bf ff f3 	be  40005fcc <rtems_fdisk_compact+0x1dc>       <== ALWAYS TAKEN
40006004:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
                                                                      
    compacted_segs += segments;                                       
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40006008:	b0 10 00 08 	mov  %o0, %i0                                  
4000600c:	81 c7 e0 08 	ret                                            
40006010:	81 e8 00 00 	restore                                        
                                                                      

400053e0 <rtems_fdisk_erase_segment>: /** * Erase the segment. */ static int rtems_fdisk_erase_segment (rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc) {
400053e0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int                                ret;                             
  uint32_t                           device;                          
  uint32_t                           segment;                         
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
400053e4:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           
  segment = sc->segment;                                              
400053e8:	d4 06 60 0c 	ld  [ %i1 + 0xc ], %o2                         
static const rtems_fdisk_segment_desc*                                
rtems_fdisk_seg_descriptor (const rtems_flashdisk* fd,                
                            uint32_t               device,            
                            uint32_t               segment)           
{                                                                     
  return fd->devices[device].segments[segment].descriptor;            
400053ec:	85 2a 60 04 	sll  %o1, 4, %g2                               
400053f0:	83 2a 60 02 	sll  %o1, 2, %g1                               
400053f4:	82 20 80 01 	sub  %g2, %g1, %g1                             
400053f8:	c4 06 20 2c 	ld  [ %i0 + 0x2c ], %g2                        
400053fc:	89 2a a0 06 	sll  %o2, 6, %g4                               
40005400:	86 00 80 01 	add  %g2, %g1, %g3                             
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
  segment = sc->segment;                                              
  sd = rtems_fdisk_seg_descriptor (fd, device, segment);              
  ops = fd->devices[device].descriptor->flash_ops;                    
40005404:	c6 00 e0 08 	ld  [ %g3 + 8 ], %g3                           
static const rtems_fdisk_segment_desc*                                
rtems_fdisk_seg_descriptor (const rtems_flashdisk* fd,                
                            uint32_t               device,            
                            uint32_t               segment)           
{                                                                     
  return fd->devices[device].segments[segment].descriptor;            
40005408:	c2 00 80 01 	ld  [ %g2 + %g1 ], %g1                         
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
  segment = sc->segment;                                              
  sd = rtems_fdisk_seg_descriptor (fd, device, segment);              
  ops = fd->devices[device].descriptor->flash_ops;                    
  ret = ops->erase (sd, device, segment);                             
4000540c:	c6 00 e0 08 	ld  [ %g3 + 8 ], %g3                           
static const rtems_fdisk_segment_desc*                                
rtems_fdisk_seg_descriptor (const rtems_flashdisk* fd,                
                            uint32_t               device,            
                            uint32_t               segment)           
{                                                                     
  return fd->devices[device].segments[segment].descriptor;            
40005410:	85 2a a0 04 	sll  %o2, 4, %g2                               
40005414:	84 21 00 02 	sub  %g4, %g2, %g2                             
40005418:	84 00 40 02 	add  %g1, %g2, %g2                             
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
  segment = sc->segment;                                              
  sd = rtems_fdisk_seg_descriptor (fd, device, segment);              
  ops = fd->devices[device].descriptor->flash_ops;                    
  ret = ops->erase (sd, device, segment);                             
4000541c:	c2 00 e0 10 	ld  [ %g3 + 0x10 ], %g1                        
40005420:	9f c0 40 00 	call  %g1                                      
40005424:	d0 00 a0 04 	ld  [ %g2 + 4 ], %o0                           
  if (ret)                                                            
40005428:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4000542c:	22 80 00 16 	be,a   40005484 <rtems_fdisk_erase_segment+0xa4><== ALWAYS TAKEN
40005430:	c4 06 20 28 	ld  [ %i0 + 0x28 ], %g2                        
  {                                                                   
    rtems_fdisk_error (" erase-segment:%02d-%03d: "      \            
40005434:	f6 06 60 08 	ld  [ %i1 + 8 ], %i3                           <== NOT EXECUTED
40005438:	40 00 77 d5 	call  4002338c <strerror>                      <== NOT EXECUTED
4000543c:	f8 06 60 0c 	ld  [ %i1 + 0xc ], %i4                         <== NOT EXECUTED
40005440:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
40005444:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
40005448:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4000544c:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
40005450:	98 10 00 1d 	mov  %i5, %o4                                  <== NOT EXECUTED
40005454:	7f ff ff 12 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005458:	90 12 22 60 	or  %o0, 0x260, %o0                            <== NOT EXECUTED
                       "segment erase failed: %s (%d)",               
                       sc->device, sc->segment, strerror (ret), ret); 
    sc->failed = true;                                                
4000545c:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
40005460:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        <== NOT EXECUTED
    if (!rtems_fdisk_segment_queue_present (&fd->failed, sc))         
40005464:	c2 06 20 58 	ld  [ %i0 + 0x58 ], %g1                        <== NOT EXECUTED
rtems_fdisk_segment_queue_present (rtems_fdisk_segment_ctl_queue* queue,
                                   rtems_fdisk_segment_ctl*       sc) 
{                                                                     
  rtems_fdisk_segment_ctl*  it = queue->head;                         
                                                                      
  while (it)                                                          
40005468:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000546c:	02 80 00 1e 	be  400054e4 <rtems_fdisk_erase_segment+0x104> <== NOT EXECUTED
40005470:	80 a0 40 19 	cmp  %g1, %i1                                  <== NOT EXECUTED
  {                                                                   
    if (it == sc)                                                     
40005474:	02 80 00 1f 	be  400054f0 <rtems_fdisk_erase_segment+0x110> <== NOT EXECUTED
40005478:	01 00 00 00 	nop                                            <== NOT EXECUTED
      return true;                                                    
    it = it->next;                                                    
4000547c:	10 bf ff fb 	b  40005468 <rtems_fdisk_erase_segment+0x88>   <== NOT EXECUTED
40005480:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
    if (!rtems_fdisk_segment_queue_present (&fd->failed, sc))         
      rtems_fdisk_segment_queue_push_tail (&fd->failed, sc);          
    return ret;                                                       
  }                                                                   
                                                                      
  fd->erased_blocks += sc->pages;                                     
40005484:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        
  sc->erased++;                                                       
                                                                      
  memset (sc->page_descriptors, 0xff, sc->pages_desc * fd->block_size);
40005488:	d2 06 60 18 	ld  [ %i1 + 0x18 ], %o1                        
    if (!rtems_fdisk_segment_queue_present (&fd->failed, sc))         
      rtems_fdisk_segment_queue_push_tail (&fd->failed, sc);          
    return ret;                                                       
  }                                                                   
                                                                      
  fd->erased_blocks += sc->pages;                                     
4000548c:	82 00 80 01 	add  %g2, %g1, %g1                             
40005490:	c2 26 20 28 	st  %g1, [ %i0 + 0x28 ]                        
  sc->erased++;                                                       
40005494:	c2 06 60 2c 	ld  [ %i1 + 0x2c ], %g1                        
                                                                      
  memset (sc->page_descriptors, 0xff, sc->pages_desc * fd->block_size);
40005498:	d0 06 20 14 	ld  [ %i0 + 0x14 ], %o0                        
      rtems_fdisk_segment_queue_push_tail (&fd->failed, sc);          
    return ret;                                                       
  }                                                                   
                                                                      
  fd->erased_blocks += sc->pages;                                     
  sc->erased++;                                                       
4000549c:	82 00 60 01 	inc  %g1                                       
                                                                      
  memset (sc->page_descriptors, 0xff, sc->pages_desc * fd->block_size);
400054a0:	fa 06 60 10 	ld  [ %i1 + 0x10 ], %i5                        
400054a4:	7f ff f4 32 	call  4000256c <.umul>                         
400054a8:	c2 26 60 2c 	st  %g1, [ %i1 + 0x2c ]                        
400054ac:	92 10 20 ff 	mov  0xff, %o1                                 
400054b0:	94 10 00 08 	mov  %o0, %o2                                  
400054b4:	40 00 72 fc 	call  400220a4 <memset>                        
400054b8:	90 10 00 1d 	mov  %i5, %o0                                  
  /*                                                                  
   * Push to the tail of the available queue. It is a very            
   * simple type of wear reduction. Every other available             
   * segment will now get a go.                                       
   */                                                                 
  rtems_fdisk_segment_queue_push_tail (&fd->available, sc);           
400054bc:	90 06 20 34 	add  %i0, 0x34, %o0                            
  fd->erased_blocks += sc->pages;                                     
  sc->erased++;                                                       
                                                                      
  memset (sc->page_descriptors, 0xff, sc->pages_desc * fd->block_size);
                                                                      
  sc->pages_active = 0;                                               
400054c0:	c0 26 60 1c 	clr  [ %i1 + 0x1c ]                            
  sc->pages_used   = 0;                                               
400054c4:	c0 26 60 20 	clr  [ %i1 + 0x20 ]                            
  sc->pages_bad    = 0;                                               
400054c8:	c0 26 60 24 	clr  [ %i1 + 0x24 ]                            
                                                                      
  sc->failed = false;                                                 
400054cc:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            
  /*                                                                  
   * Push to the tail of the available queue. It is a very            
   * simple type of wear reduction. Every other available             
   * segment will now get a go.                                       
   */                                                                 
  rtems_fdisk_segment_queue_push_tail (&fd->available, sc);           
400054d0:	92 10 00 19 	mov  %i1, %o1                                  
400054d4:	7f ff fe 27 	call  40004d70 <rtems_fdisk_segment_queue_push_tail>
400054d8:	b0 10 20 00 	clr  %i0                                       
                                                                      
  return 0;                                                           
400054dc:	81 c7 e0 08 	ret                                            
400054e0:	81 e8 00 00 	restore                                        
    rtems_fdisk_error (" erase-segment:%02d-%03d: "      \            
                       "segment erase failed: %s (%d)",               
                       sc->device, sc->segment, strerror (ret), ret); 
    sc->failed = true;                                                
    if (!rtems_fdisk_segment_queue_present (&fd->failed, sc))         
      rtems_fdisk_segment_queue_push_tail (&fd->failed, sc);          
400054e4:	90 06 20 58 	add  %i0, 0x58, %o0                            <== NOT EXECUTED
400054e8:	7f ff fe 22 	call  40004d70 <rtems_fdisk_segment_queue_push_tail><== NOT EXECUTED
400054ec:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
   * segment will now get a go.                                       
   */                                                                 
  rtems_fdisk_segment_queue_push_tail (&fd->available, sc);           
                                                                      
  return 0;                                                           
}                                                                     
400054f0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400054f4:	91 e8 00 1d 	restore  %g0, %i5, %o0                         <== NOT EXECUTED
                                                                      

4000509c <rtems_fdisk_error>: * @param ... The arguments for the format text. * @return int The number of bytes written to the output. */ static int rtems_fdisk_error (const char *format, ...) {
4000509c:	9d e3 bf 98 	save  %sp, -104, %sp                           <== NOT EXECUTED
  int ret;                                                            
  va_list args;                                                       
  va_start (args, format);                                            
400050a0:	82 07 a0 48 	add  %fp, 0x48, %g1                            <== NOT EXECUTED
400050a4:	f2 27 a0 48 	st  %i1, [ %fp + 0x48 ]                        <== NOT EXECUTED
400050a8:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          <== NOT EXECUTED
400050ac:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        <== NOT EXECUTED
400050b0:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        <== NOT EXECUTED
400050b4:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        <== NOT EXECUTED
  fprintf (stderr, "fdisk:error:");                                   
400050b8:	7f ff f0 f0 	call  40001478 <__getreent>                    <== NOT EXECUTED
400050bc:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        <== NOT EXECUTED
400050c0:	d2 02 20 0c 	ld  [ %o0 + 0xc ], %o1                         <== NOT EXECUTED
400050c4:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
400050c8:	40 00 71 63 	call  40021654 <fputs>                         <== NOT EXECUTED
400050cc:	90 12 21 a8 	or  %o0, 0x1a8, %o0	! 400321a8 <__FUNCTION__.6501+0x140><== NOT EXECUTED
  ret =  vfprintf (stderr, format, args);                             
400050d0:	7f ff f0 ea 	call  40001478 <__getreent>                    <== NOT EXECUTED
400050d4:	01 00 00 00 	nop                                            <== NOT EXECUTED
400050d8:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          <== NOT EXECUTED
400050dc:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         <== NOT EXECUTED
400050e0:	40 00 94 3c 	call  4002a1d0 <vfprintf>                      <== NOT EXECUTED
400050e4:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
  fprintf (stderr, "\n");                                             
400050e8:	7f ff f0 e4 	call  40001478 <__getreent>                    <== NOT EXECUTED
400050ec:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
400050f0:	d2 02 20 0c 	ld  [ %o0 + 0xc ], %o1                         <== NOT EXECUTED
400050f4:	40 00 71 24 	call  40021584 <fputc>                         <== NOT EXECUTED
400050f8:	90 10 20 0a 	mov  0xa, %o0                                  <== NOT EXECUTED
  fflush (stderr);                                                    
400050fc:	7f ff f0 df 	call  40001478 <__getreent>                    <== NOT EXECUTED
40005100:	01 00 00 00 	nop                                            <== NOT EXECUTED
40005104:	40 00 70 25 	call  40021198 <fflush>                        <== NOT EXECUTED
40005108:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         <== NOT EXECUTED
  va_end (args);                                                      
  return ret;                                                         
}                                                                     
4000510c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005110:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40004f94 <rtems_fdisk_info>: * @param ... The arguments for the format text. * @return int The number of bytes written to the output. */ static int rtems_fdisk_info (const rtems_flashdisk* fd, const char *format, ...) {
40004f94:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int ret = 0;                                                        
  if (fd->info_level >= 2)                                            
  {                                                                   
    va_list args;                                                     
    va_start (args, format);                                          
40004f98:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        
40004f9c:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
40004fa0:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        
40004fa4:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        
 */                                                                   
static int                                                            
rtems_fdisk_info (const rtems_flashdisk* fd, const char *format, ...) 
{                                                                     
  int ret = 0;                                                        
  if (fd->info_level >= 2)                                            
40004fa8:	c2 06 20 6c 	ld  [ %i0 + 0x6c ], %g1                        
40004fac:	80 a0 60 01 	cmp  %g1, 1                                    
40004fb0:	08 80 00 18 	bleu  40005010 <rtems_fdisk_info+0x7c>         <== ALWAYS TAKEN
40004fb4:	b0 10 20 00 	clr  %i0                                       
  {                                                                   
    va_list args;                                                     
    va_start (args, format);                                          
40004fb8:	82 07 a0 4c 	add  %fp, 0x4c, %g1                            <== NOT EXECUTED
    fprintf (stdout, "fdisk:");                                       
40004fbc:	7f ff f1 2f 	call  40001478 <__getreent>                    <== NOT EXECUTED
40004fc0:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          <== NOT EXECUTED
40004fc4:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           <== NOT EXECUTED
40004fc8:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
40004fcc:	40 00 71 a2 	call  40021654 <fputs>                         <== NOT EXECUTED
40004fd0:	90 12 21 90 	or  %o0, 0x190, %o0	! 40032190 <__FUNCTION__.6501+0x128><== NOT EXECUTED
    ret =  vfprintf (stdout, format, args);                           
40004fd4:	7f ff f1 29 	call  40001478 <__getreent>                    <== NOT EXECUTED
40004fd8:	01 00 00 00 	nop                                            <== NOT EXECUTED
40004fdc:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          <== NOT EXECUTED
40004fe0:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
40004fe4:	40 00 94 7b 	call  4002a1d0 <vfprintf>                      <== NOT EXECUTED
40004fe8:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
    fprintf (stdout, "\n");                                           
40004fec:	7f ff f1 23 	call  40001478 <__getreent>                    <== NOT EXECUTED
40004ff0:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
40004ff4:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           <== NOT EXECUTED
40004ff8:	40 00 71 63 	call  40021584 <fputc>                         <== NOT EXECUTED
40004ffc:	90 10 20 0a 	mov  0xa, %o0                                  <== NOT EXECUTED
    fflush (stdout);                                                  
40005000:	7f ff f1 1e 	call  40001478 <__getreent>                    <== NOT EXECUTED
40005004:	01 00 00 00 	nop                                            <== NOT EXECUTED
40005008:	40 00 70 64 	call  40021198 <fflush>                        <== NOT EXECUTED
4000500c:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
    va_end (args);                                                    
  }                                                                   
  return ret;                                                         
}                                                                     
40005010:	81 c7 e0 08 	ret                                            
40005014:	81 e8 00 00 	restore                                        
                                                                      

400071c4 <rtems_fdisk_initialize>: */ rtems_device_driver rtems_fdisk_initialize (rtems_device_major_number major, rtems_device_minor_number minor, void* arg __attribute__((unused))) {
400071c4:	9d e3 bf 60 	save  %sp, -160, %sp                           
  const rtems_flashdisk_config* c = rtems_flashdisk_configuration;    
  rtems_flashdisk*              fd;                                   
  rtems_status_code             sc;                                   
                                                                      
  sc = rtems_disk_io_initialize ();                                   
400071c8:	7f ff f6 9c 	call  40004c38 <rtems_disk_io_initialize>      
400071cc:	b4 10 00 18 	mov  %i0, %i2                                  
  if (sc != RTEMS_SUCCESSFUL)                                         
400071d0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400071d4:	12 80 01 36 	bne  400076ac <rtems_fdisk_initialize+0x4e8>   <== NEVER TAKEN
400071d8:	01 00 00 00 	nop                                            
static rtems_status_code                                              
rtems_fdisk_crc16_gen_factors (uint16_t pattern)                      
{                                                                     
  uint32_t b;                                                         
                                                                      
  rtems_fdisk_crc16_factor = malloc (sizeof (uint16_t) * 256);        
400071dc:	40 00 04 e2 	call  40008564 <malloc>                        
400071e0:	90 10 22 00 	mov  0x200, %o0	! 200 <_TLS_Alignment+0x1ff>   
400071e4:	03 10 01 1f 	sethi  %hi(0x40047c00), %g1                    
400071e8:	d0 20 63 a0 	st  %o0, [ %g1 + 0x3a0 ]	! 40047fa0 <rtems_fdisk_crc16_factor>
  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;                        
400071ec:	09 3f ff e1 	sethi  %hi(0xffff8400), %g4                    
rtems_fdisk_crc16_gen_factors (uint16_t pattern)                      
{                                                                     
  uint32_t b;                                                         
                                                                      
  rtems_fdisk_crc16_factor = malloc (sizeof (uint16_t) * 256);        
  if (!rtems_fdisk_crc16_factor)                                      
400071f0:	82 10 20 00 	clr  %g1                                       
400071f4:	80 a2 20 00 	cmp  %o0, 0                                    
400071f8:	02 80 00 18 	be  40007258 <rtems_fdisk_initialize+0x94>     <== NEVER TAKEN
400071fc:	88 11 20 08 	or  %g4, 8, %g4                                
    return RTEMS_NO_MEMORY;                                           
                                                                      
  for (b = 0; b < 256; b++)                                           
  {                                                                   
    uint32_t i;                                                       
    uint16_t v = b;                                                   
40007200:	84 10 00 01 	mov  %g1, %g2                                  
40007204:	86 10 20 09 	mov  9, %g3                                    
    for (i = 8; i--;)                                                 
40007208:	86 80 ff ff 	addcc  %g3, -1, %g3                            
4000720c:	02 80 00 07 	be  40007228 <rtems_fdisk_initialize+0x64>     
40007210:	80 88 a0 01 	btst  1, %g2                                   
40007214:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
      v = v & 1 ? (v >> 1) ^ pattern : v >> 1;                        
40007218:	02 bf ff fc 	be  40007208 <rtems_fdisk_initialize+0x44>     
4000721c:	85 30 a0 11 	srl  %g2, 0x11, %g2                            
40007220:	10 bf ff fa 	b  40007208 <rtems_fdisk_initialize+0x44>      
40007224:	84 18 80 04 	xor  %g2, %g4, %g2                             
40007228:	87 28 60 01 	sll  %g1, 1, %g3                               
                                                                      
  rtems_fdisk_crc16_factor = malloc (sizeof (uint16_t) * 256);        
  if (!rtems_fdisk_crc16_factor)                                      
    return RTEMS_NO_MEMORY;                                           
                                                                      
  for (b = 0; b < 256; b++)                                           
4000722c:	82 00 60 01 	inc  %g1                                       
40007230:	80 a0 61 00 	cmp  %g1, 0x100                                
40007234:	12 bf ff f3 	bne  40007200 <rtems_fdisk_initialize+0x3c>    
40007238:	c4 32 00 03 	sth  %g2, [ %o0 + %g3 ]                        
                                                                      
  sc = rtems_fdisk_crc16_gen_factors (0x8408);                        
  if (sc != RTEMS_SUCCESSFUL)                                         
      return sc;                                                      
                                                                      
  rtems_flashdisks = calloc (rtems_flashdisk_configuration_size,      
4000723c:	10 80 00 09 	b  40007260 <rtems_fdisk_initialize+0x9c>      
40007240:	3b 10 00 db 	sethi  %hi(0x40036c00), %i5                    
                                              c->block_size);         
                                                                      
    /*                                                                
     * One copy buffer of a page size.                                
     */                                                               
    fd->copy_buffer = malloc (c->block_size);                         
40007244:	40 00 04 c8 	call  40008564 <malloc>                        
40007248:	90 10 00 11 	mov  %l1, %o0                                  
    if (!fd->copy_buffer)                                             
4000724c:	80 a2 20 00 	cmp  %o0, 0                                    
40007250:	12 80 00 5f 	bne  400073cc <rtems_fdisk_initialize+0x208>   <== ALWAYS TAKEN
40007254:	d0 27 60 68 	st  %o0, [ %i5 + 0x68 ]                        
      return RTEMS_NO_MEMORY;                                         
40007258:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000725c:	91 e8 20 1a 	restore  %g0, 0x1a, %o0                        <== NOT EXECUTED
                                                                      
  sc = rtems_fdisk_crc16_gen_factors (0x8408);                        
  if (sc != RTEMS_SUCCESSFUL)                                         
      return sc;                                                      
                                                                      
  rtems_flashdisks = calloc (rtems_flashdisk_configuration_size,      
40007260:	d0 07 61 60 	ld  [ %i5 + 0x160 ], %o0                       
40007264:	92 10 20 74 	mov  0x74, %o1                                 
40007268:	40 00 02 ce 	call  40007da0 <calloc>                        
4000726c:	27 10 01 1f 	sethi  %hi(0x40047c00), %l3                    
                             sizeof (rtems_flashdisk));               
                                                                      
  if (!rtems_flashdisks)                                              
40007270:	80 a2 20 00 	cmp  %o0, 0                                    
40007274:	02 bf ff f9 	be  40007258 <rtems_fdisk_initialize+0x94>     <== NEVER TAKEN
40007278:	d0 24 e3 a8 	st  %o0, [ %l3 + 0x3a8 ]                       
4000727c:	39 10 00 c6 	sethi  %hi(0x40031800), %i4                    
                                                                      
    fd->devices = calloc (c->device_count, sizeof (rtems_fdisk_device_ctl));
    if (!fd->devices)                                                 
      return RTEMS_NO_MEMORY;                                         
                                                                      
    sc = rtems_semaphore_create (rtems_build_name ('F', 'D', 'S', 'K'), 1,
40007280:	2b 11 91 14 	sethi  %hi(0x46445000), %l5                    
      free (fd->blocks);                                              
      free (fd->devices);                                             
      return sc;                                                      
    }                                                                 
                                                                      
    sc = rtems_disk_create_phys(dev, c->block_size,                   
40007284:	2f 10 00 18 	sethi  %hi(0x40006000), %l7                    
      return sc;                                                      
                                                                      
  rtems_flashdisks = calloc (rtems_flashdisk_configuration_size,      
                             sizeof (rtems_flashdisk));               
                                                                      
  if (!rtems_flashdisks)                                              
40007288:	a0 10 20 00 	clr  %l0                                       
4000728c:	b8 17 23 7c 	or  %i4, 0x37c, %i4                            
40007290:	b6 10 20 00 	clr  %i3                                       
                                                                      
    fd->devices = calloc (c->device_count, sizeof (rtems_fdisk_device_ctl));
    if (!fd->devices)                                                 
      return RTEMS_NO_MEMORY;                                         
                                                                      
    sc = rtems_semaphore_create (rtems_build_name ('F', 'D', 'S', 'K'), 1,
40007294:	aa 15 63 4b 	or  %l5, 0x34b, %l5                            
      free (fd->blocks);                                              
      free (fd->devices);                                             
      return sc;                                                      
    }                                                                 
                                                                      
    sc = rtems_disk_create_phys(dev, c->block_size,                   
40007298:	ac 07 bf f0 	add  %fp, -16, %l6                             
4000729c:	ae 15 e0 bc 	or  %l7, 0xbc, %l7                             
                             sizeof (rtems_flashdisk));               
                                                                      
  if (!rtems_flashdisks)                                              
    return RTEMS_NO_MEMORY;                                           
                                                                      
  for (minor = 0; minor < rtems_flashdisk_configuration_size; minor++, c++)
400072a0:	05 10 00 db 	sethi  %hi(0x40036c00), %g2                    
400072a4:	c2 00 a1 60 	ld  [ %g2 + 0x160 ], %g1	! 40036d60 <rtems_flashdisk_configuration_size>
400072a8:	80 a6 c0 01 	cmp  %i3, %g1                                  
400072ac:	1a 80 00 fd 	bcc  400076a0 <rtems_fdisk_initialize+0x4dc>   
400072b0:	07 0b d9 99 	sethi  %hi(0x2f666400), %g3                    
  {                                                                   
    char     name[] = RTEMS_FLASHDISK_DEVICE_BASE_NAME "a";           
400072b4:	86 10 e0 64 	or  %g3, 0x64, %g3	! 2f666464 <RAM_SIZE+0x2f266464>
    dev_t    dev = rtems_filesystem_make_dev_t (major, minor);        
    uint32_t device;                                                  
    uint32_t blocks = 0;                                              
    int      ret;                                                     
                                                                      
    fd = &rtems_flashdisks[minor];                                    
400072b8:	c2 04 e3 a8 	ld  [ %l3 + 0x3a8 ], %g1                       
  if (!rtems_flashdisks)                                              
    return RTEMS_NO_MEMORY;                                           
                                                                      
  for (minor = 0; minor < rtems_flashdisk_configuration_size; minor++, c++)
  {                                                                   
    char     name[] = RTEMS_FLASHDISK_DEVICE_BASE_NAME "a";           
400072bc:	05 0b d9 19 	sethi  %hi(0x2f646400), %g2                    
400072c0:	84 10 a1 76 	or  %g2, 0x176, %g2	! 2f646576 <RAM_SIZE+0x2f246576>
400072c4:	c4 3f bf f0 	std  %g2, [ %fp + -16 ]                        
400072c8:	07 00 00 18 	sethi  %hi(0x6000), %g3                        
400072cc:	86 10 e1 00 	or  %g3, 0x100, %g3	! 6100 <_TLS_Alignment+0x60ff>
400072d0:	c6 37 bf f8 	sth  %g3, [ %fp + -8 ]                         
    uint32_t blocks = 0;                                              
    int      ret;                                                     
                                                                      
    fd = &rtems_flashdisks[minor];                                    
                                                                      
    name [sizeof(RTEMS_FLASHDISK_DEVICE_BASE_NAME)] += minor;         
400072d4:	f6 2f bf f9 	stb  %i3, [ %fp + -7 ]                         
    dev_t    dev = rtems_filesystem_make_dev_t (major, minor);        
    uint32_t device;                                                  
    uint32_t blocks = 0;                                              
    int      ret;                                                     
                                                                      
    fd = &rtems_flashdisks[minor];                                    
400072d8:	ba 00 40 10 	add  %g1, %l0, %i5                             
                                                                      
    name [sizeof(RTEMS_FLASHDISK_DEVICE_BASE_NAME)] += minor;         
                                                                      
    fd->major              = major;                                   
400072dc:	f4 20 40 10 	st  %i2, [ %g1 + %l0 ]                         
    fd->minor              = minor;                                   
    fd->flags              = c->flags;                                
400072e0:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
    fd->compact_segs       = c->compact_segs;                         
    fd->avail_compact_segs = c->avail_compact_segs;                   
    fd->block_size         = c->block_size;                           
400072e4:	e2 07 00 00 	ld  [ %i4 ], %l1                               
                                                                      
    name [sizeof(RTEMS_FLASHDISK_DEVICE_BASE_NAME)] += minor;         
                                                                      
    fd->major              = major;                                   
    fd->minor              = minor;                                   
    fd->flags              = c->flags;                                
400072e8:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
    fd->compact_segs       = c->compact_segs;                         
400072ec:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
    fd->avail_compact_segs = c->avail_compact_segs;                   
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
    fd->info_level         = c->info_level;                           
                                                                      
    for (device = 0; device < c->device_count; device++)              
400072f0:	da 07 20 04 	ld  [ %i4 + 4 ], %o5                           
    name [sizeof(RTEMS_FLASHDISK_DEVICE_BASE_NAME)] += minor;         
                                                                      
    fd->major              = major;                                   
    fd->minor              = minor;                                   
    fd->flags              = c->flags;                                
    fd->compact_segs       = c->compact_segs;                         
400072f4:	c2 27 60 0c 	st  %g1, [ %i5 + 0xc ]                         
    fd->avail_compact_segs = c->avail_compact_segs;                   
400072f8:	c2 07 20 18 	ld  [ %i4 + 0x18 ], %g1                        
    fd = &rtems_flashdisks[minor];                                    
                                                                      
    name [sizeof(RTEMS_FLASHDISK_DEVICE_BASE_NAME)] += minor;         
                                                                      
    fd->major              = major;                                   
    fd->minor              = minor;                                   
400072fc:	f6 27 60 04 	st  %i3, [ %i5 + 4 ]                           
    fd->flags              = c->flags;                                
    fd->compact_segs       = c->compact_segs;                         
    fd->avail_compact_segs = c->avail_compact_segs;                   
40007300:	c2 27 60 10 	st  %g1, [ %i5 + 0x10 ]                        
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
40007304:	c2 07 20 10 	ld  [ %i4 + 0x10 ], %g1                        
    fd->major              = major;                                   
    fd->minor              = minor;                                   
    fd->flags              = c->flags;                                
    fd->compact_segs       = c->compact_segs;                         
    fd->avail_compact_segs = c->avail_compact_segs;                   
    fd->block_size         = c->block_size;                           
40007308:	e2 27 60 14 	st  %l1, [ %i5 + 0x14 ]                        
    fd->unavail_blocks     = c->unavail_blocks;                       
4000730c:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
    fd->info_level         = c->info_level;                           
40007310:	c2 07 20 1c 	ld  [ %i4 + 0x1c ], %g1                        
                                                                      
    for (device = 0; device < c->device_count; device++)              
40007314:	a4 10 20 00 	clr  %l2                                       
    fd->flags              = c->flags;                                
    fd->compact_segs       = c->compact_segs;                         
    fd->avail_compact_segs = c->avail_compact_segs;                   
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
    fd->info_level         = c->info_level;                           
40007318:	c2 27 60 6c 	st  %g1, [ %i5 + 0x6c ]                        
  for (minor = 0; minor < rtems_flashdisk_configuration_size; minor++, c++)
  {                                                                   
    char     name[] = RTEMS_FLASHDISK_DEVICE_BASE_NAME "a";           
    dev_t    dev = rtems_filesystem_make_dev_t (major, minor);        
    uint32_t device;                                                  
    uint32_t blocks = 0;                                              
4000731c:	b2 10 20 00 	clr  %i1                                       
    fd->avail_compact_segs = c->avail_compact_segs;                   
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
    fd->info_level         = c->info_level;                           
                                                                      
    for (device = 0; device < c->device_count; device++)              
40007320:	b0 10 20 00 	clr  %i0                                       
40007324:	80 a6 00 0d 	cmp  %i0, %o5                                  
40007328:	02 bf ff c7 	be  40007244 <rtems_fdisk_initialize+0x80>     
4000732c:	a8 10 20 00 	clr  %l4                                       
      blocks += rtems_fdisk_blocks_in_device (&c->devices[device],    
40007330:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           
rtems_fdisk_blocks_in_device (const rtems_fdisk_device_desc* dd,      
                              uint32_t                       page_size)
{                                                                     
  uint32_t count = 0;                                                 
  uint32_t s;                                                         
  for (s = 0; s < dd->segment_count; s++)                             
40007334:	d8 00 40 12 	ld  [ %g1 + %l2 ], %o4                         
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
    fd->info_level         = c->info_level;                           
                                                                      
    for (device = 0; device < c->device_count; device++)              
      blocks += rtems_fdisk_blocks_in_device (&c->devices[device],    
40007338:	96 00 40 12 	add  %g1, %l2, %o3                             
rtems_fdisk_blocks_in_device (const rtems_fdisk_device_desc* dd,      
                              uint32_t                       page_size)
{                                                                     
  uint32_t count = 0;                                                 
  uint32_t s;                                                         
  for (s = 0; s < dd->segment_count; s++)                             
4000733c:	86 10 20 00 	clr  %g3                                       
 */                                                                   
static uint32_t                                                       
rtems_fdisk_blocks_in_device (const rtems_fdisk_device_desc* dd,      
                              uint32_t                       page_size)
{                                                                     
  uint32_t count = 0;                                                 
40007340:	84 10 20 00 	clr  %g2                                       
  uint32_t s;                                                         
  for (s = 0; s < dd->segment_count; s++)                             
40007344:	80 a0 c0 0c 	cmp  %g3, %o4                                  
40007348:	02 80 00 1d 	be  400073bc <rtems_fdisk_initialize+0x1f8>    
4000734c:	92 10 00 11 	mov  %l1, %o1                                  
  {                                                                   
    const rtems_fdisk_segment_desc* sd = &dd->segments[s];            
40007350:	c8 02 e0 04 	ld  [ %o3 + 4 ], %g4                           
40007354:	9e 01 00 14 	add  %g4, %l4, %o7                             
 */                                                                   
static uint32_t                                                       
rtems_fdisk_pages_in_segment (const rtems_fdisk_segment_desc* sd,     
                              uint32_t                        page_size)
{                                                                     
  return sd->size / page_size;                                        
40007358:	d0 03 e0 08 	ld  [ %o7 + 8 ], %o0                           
4000735c:	c4 3f bf e0 	std  %g2, [ %fp + -32 ]                        
40007360:	d8 3f bf c8 	std  %o4, [ %fp + -56 ]                        
40007364:	c8 27 bf dc 	st  %g4, [ %fp + -36 ]                         
40007368:	7f ff ec bb 	call  40002654 <.udiv>                         
4000736c:	d6 27 bf d4 	st  %o3, [ %fp + -44 ]                         
rtems_fdisk_page_desc_pages (const rtems_fdisk_segment_desc* sd,      
                             uint32_t                        page_size)
{                                                                     
  uint32_t pages = rtems_fdisk_pages_in_segment (sd, page_size);      
  uint32_t bytes = pages * sizeof (rtems_fdisk_page_desc);            
  return ((bytes - 1) / page_size) + 1;                               
40007370:	94 02 3f ff 	add  %o0, -1, %o2                              
40007374:	92 10 00 11 	mov  %l1, %o1                                  
40007378:	d4 27 bf d0 	st  %o2, [ %fp + -48 ]                         
static uint32_t                                                       
rtems_fdisk_page_desc_pages (const rtems_fdisk_segment_desc* sd,      
                             uint32_t                        page_size)
{                                                                     
  uint32_t pages = rtems_fdisk_pages_in_segment (sd, page_size);      
  uint32_t bytes = pages * sizeof (rtems_fdisk_page_desc);            
4000737c:	91 2a 20 03 	sll  %o0, 3, %o0                               
  return ((bytes - 1) / page_size) + 1;                               
40007380:	7f ff ec b5 	call  40002654 <.udiv>                         
40007384:	90 02 3f ff 	add  %o0, -1, %o0                              
  for (s = 0; s < dd->segment_count; s++)                             
  {                                                                   
    const rtems_fdisk_segment_desc* sd = &dd->segments[s];            
    count +=                                                          
      (rtems_fdisk_pages_in_segment (sd, page_size) -                 
       rtems_fdisk_page_desc_pages (sd, page_size)) * sd->count;      
40007388:	c8 07 bf dc 	ld  [ %fp + -36 ], %g4                         
4000738c:	d4 1f bf d0 	ldd  [ %fp + -48 ], %o2                        
40007390:	d2 11 00 14 	lduh  [ %g4 + %l4 ], %o1                       
40007394:	90 22 80 08 	sub  %o2, %o0, %o0                             
40007398:	7f ff ec 75 	call  4000256c <.umul>                         
4000739c:	d6 27 bf d4 	st  %o3, [ %fp + -44 ]                         
  uint32_t count = 0;                                                 
  uint32_t s;                                                         
  for (s = 0; s < dd->segment_count; s++)                             
  {                                                                   
    const rtems_fdisk_segment_desc* sd = &dd->segments[s];            
    count +=                                                          
400073a0:	c4 1f bf e0 	ldd  [ %fp + -32 ], %g2                        
400073a4:	a8 05 20 0c 	add  %l4, 0xc, %l4                             
400073a8:	84 00 80 08 	add  %g2, %o0, %g2                             
rtems_fdisk_blocks_in_device (const rtems_fdisk_device_desc* dd,      
                              uint32_t                       page_size)
{                                                                     
  uint32_t count = 0;                                                 
  uint32_t s;                                                         
  for (s = 0; s < dd->segment_count; s++)                             
400073ac:	86 00 e0 01 	inc  %g3                                       
400073b0:	d8 1f bf c8 	ldd  [ %fp + -56 ], %o4                        
400073b4:	10 bf ff e4 	b  40007344 <rtems_fdisk_initialize+0x180>     
400073b8:	d6 07 bf d4 	ld  [ %fp + -44 ], %o3                         
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
    fd->info_level         = c->info_level;                           
                                                                      
    for (device = 0; device < c->device_count; device++)              
      blocks += rtems_fdisk_blocks_in_device (&c->devices[device],    
400073bc:	b2 06 40 02 	add  %i1, %g2, %i1                             
    fd->avail_compact_segs = c->avail_compact_segs;                   
    fd->block_size         = c->block_size;                           
    fd->unavail_blocks     = c->unavail_blocks;                       
    fd->info_level         = c->info_level;                           
                                                                      
    for (device = 0; device < c->device_count; device++)              
400073c0:	b0 06 20 01 	inc  %i0                                       
400073c4:	10 bf ff d8 	b  40007324 <rtems_fdisk_initialize+0x160>     
400073c8:	a4 04 a0 0c 	add  %l2, 0xc, %l2                             
     */                                                               
    fd->copy_buffer = malloc (c->block_size);                         
    if (!fd->copy_buffer)                                             
      return RTEMS_NO_MEMORY;                                         
                                                                      
    fd->blocks = calloc (blocks, sizeof (rtems_fdisk_block_ctl));     
400073cc:	90 10 00 19 	mov  %i1, %o0                                  
400073d0:	40 00 02 74 	call  40007da0 <calloc>                        
400073d4:	92 10 20 08 	mov  8, %o1                                    
    if (!fd->blocks)                                                  
400073d8:	80 a2 20 00 	cmp  %o0, 0                                    
400073dc:	02 bf ff 9f 	be  40007258 <rtems_fdisk_initialize+0x94>     <== NEVER TAKEN
400073e0:	d0 27 60 18 	st  %o0, [ %i5 + 0x18 ]                        
      return RTEMS_NO_MEMORY;                                         
                                                                      
    fd->block_count = blocks;                                         
400073e4:	f2 27 60 1c 	st  %i1, [ %i5 + 0x1c ]                        
                                                                      
    fd->devices = calloc (c->device_count, sizeof (rtems_fdisk_device_ctl));
400073e8:	90 10 00 18 	mov  %i0, %o0                                  
400073ec:	40 00 02 6d 	call  40007da0 <calloc>                        
400073f0:	92 10 20 0c 	mov  0xc, %o1                                  
    if (!fd->devices)                                                 
400073f4:	80 a2 20 00 	cmp  %o0, 0                                    
400073f8:	02 bf ff 98 	be  40007258 <rtems_fdisk_initialize+0x94>     <== NEVER TAKEN
400073fc:	d0 27 60 2c 	st  %o0, [ %i5 + 0x2c ]                        
      return RTEMS_NO_MEMORY;                                         
                                                                      
    sc = rtems_semaphore_create (rtems_build_name ('F', 'D', 'S', 'K'), 1,
40007400:	90 10 00 15 	mov  %l5, %o0                                  
40007404:	92 10 20 01 	mov  1, %o1                                    
40007408:	94 10 20 54 	mov  0x54, %o2                                 
4000740c:	96 10 20 00 	clr  %o3                                       
40007410:	40 00 14 94 	call  4000c660 <rtems_semaphore_create>        
40007414:	98 07 60 64 	add  %i5, 0x64, %o4                            
                                 RTEMS_PRIORITY | RTEMS_BINARY_SEMAPHORE |
                                 RTEMS_INHERIT_PRIORITY, 0, &fd->lock);
    if (sc != RTEMS_SUCCESSFUL)                                       
40007418:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4000741c:	22 80 00 0d 	be,a   40007450 <rtems_fdisk_initialize+0x28c> <== ALWAYS TAKEN
40007420:	d6 07 60 20 	ld  [ %i5 + 0x20 ], %o3                        
    {                                                                 
      rtems_fdisk_error ("disk lock create failed");                  
40007424:	11 10 00 cb 	sethi  %hi(0x40032c00), %o0                    <== NOT EXECUTED
40007428:	7f ff f7 1d 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
4000742c:	90 12 20 b8 	or  %o0, 0xb8, %o0	! 40032cb8 <__FUNCTION__.6501+0xc50><== NOT EXECUTED
      free (fd->copy_buffer);                                         
40007430:	40 00 02 bf 	call  40007f2c <free>                          <== NOT EXECUTED
40007434:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        <== NOT EXECUTED
      free (fd->blocks);                                              
40007438:	40 00 02 bd 	call  40007f2c <free>                          <== NOT EXECUTED
4000743c:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        <== NOT EXECUTED
      free (fd->devices);                                             
40007440:	40 00 02 bb 	call  40007f2c <free>                          <== NOT EXECUTED
40007444:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        <== NOT EXECUTED
      return sc;                                                      
40007448:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000744c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    }                                                                 
                                                                      
    sc = rtems_disk_create_phys(dev, c->block_size,                   
40007450:	d4 07 00 00 	ld  [ %i4 ], %o2                               
40007454:	90 10 00 1a 	mov  %i2, %o0                                  
40007458:	ec 23 a0 5c 	st  %l6, [ %sp + 0x5c ]                        
4000745c:	92 10 00 1b 	mov  %i3, %o1                                  
40007460:	96 26 40 0b 	sub  %i1, %o3, %o3                             
40007464:	98 10 00 17 	mov  %l7, %o4                                  
40007468:	7f ff f5 90 	call  40004aa8 <rtems_disk_create_phys>        
4000746c:	9a 10 20 00 	clr  %o5                                       
                                blocks - fd->unavail_blocks,          
                                rtems_fdisk_ioctl, NULL, name);       
    if (sc != RTEMS_SUCCESSFUL)                                       
40007470:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40007474:	02 80 00 16 	be  400074cc <rtems_fdisk_initialize+0x308>    <== ALWAYS TAKEN
40007478:	b2 10 20 00 	clr  %i1                                       
    {                                                                 
      rtems_semaphore_delete (fd->lock);                              
4000747c:	40 00 14 f4 	call  4000c84c <rtems_semaphore_delete>        <== NOT EXECUTED
40007480:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        <== NOT EXECUTED
      rtems_disk_delete (dev);                                        
40007484:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
40007488:	7f ff f5 21 	call  4000490c <rtems_disk_delete>             <== NOT EXECUTED
4000748c:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
      free (fd->copy_buffer);                                         
40007490:	40 00 02 a7 	call  40007f2c <free>                          <== NOT EXECUTED
40007494:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        <== NOT EXECUTED
      free (fd->blocks);                                              
40007498:	40 00 02 a5 	call  40007f2c <free>                          <== NOT EXECUTED
4000749c:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        <== NOT EXECUTED
      free (fd->devices);                                             
400074a0:	40 00 02 a3 	call  40007f2c <free>                          <== NOT EXECUTED
400074a4:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        <== NOT EXECUTED
      rtems_fdisk_error ("disk create phy failed");                   
400074a8:	11 10 00 cb 	sethi  %hi(0x40032c00), %o0                    <== NOT EXECUTED
400074ac:	7f ff f6 fc 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
400074b0:	90 12 20 d0 	or  %o0, 0xd0, %o0	! 40032cd0 <__FUNCTION__.6501+0xc68><== NOT EXECUTED
      return sc;                                                      
400074b4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400074b8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
          sc->segment    = seg_segment;                               
          sc->erased     = 0;                                         
        }                                                             
      }                                                               
                                                                      
      fd->devices[device].segment_count = segment_count;              
400074bc:	e2 23 60 04 	st  %l1, [ %o5 + 4 ]                           
      fd->devices[device].descriptor    = &c->devices[device];        
400074c0:	e4 23 60 08 	st  %l2, [ %o5 + 8 ]                           
      free (fd->devices);                                             
      rtems_fdisk_error ("disk create phy failed");                   
      return sc;                                                      
    }                                                                 
                                                                      
    for (device = 0; device < c->device_count; device++)              
400074c4:	b0 06 20 01 	inc  %i0                                       
400074c8:	b2 06 60 0c 	add  %i1, 0xc, %i1                             
400074cc:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
400074d0:	80 a6 00 01 	cmp  %i0, %g1                                  
400074d4:	1a 80 00 40 	bcc  400075d4 <rtems_fdisk_initialize+0x410>   
400074d8:	84 10 20 00 	clr  %g2                                       
    {                                                                 
      rtems_fdisk_segment_ctl* sc;                                    
      uint32_t                 segment_count;                         
      uint32_t                 segment;                               
                                                                      
      segment_count = rtems_fdisk_count_segments (&c->devices[device]);
400074dc:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           
400074e0:	a4 00 40 19 	add  %g1, %i1, %l2                             
static uint32_t                                                       
rtems_fdisk_count_segments (const rtems_fdisk_device_desc* dd)        
{                                                                     
  uint32_t count = 0;                                                 
  uint32_t segment;                                                   
  for (segment = 0; segment < dd->segment_count; segment++)           
400074e4:	d8 00 40 19 	ld  [ %g1 + %i1 ], %o4                         
 * Count the segments for a device.                                   
 */                                                                   
static uint32_t                                                       
rtems_fdisk_count_segments (const rtems_fdisk_device_desc* dd)        
{                                                                     
  uint32_t count = 0;                                                 
400074e8:	a2 10 20 00 	clr  %l1                                       
  uint32_t segment;                                                   
  for (segment = 0; segment < dd->segment_count; segment++)           
400074ec:	82 10 20 00 	clr  %g1                                       
400074f0:	80 a0 40 0c 	cmp  %g1, %o4                                  
400074f4:	02 80 00 07 	be  40007510 <rtems_fdisk_initialize+0x34c>    
400074f8:	82 00 60 01 	inc  %g1                                       
    count += dd->segments[segment].count;                             
400074fc:	c6 04 a0 04 	ld  [ %l2 + 4 ], %g3                           
40007500:	c6 10 c0 02 	lduh  [ %g3 + %g2 ], %g3                       
40007504:	84 00 a0 0c 	add  %g2, 0xc, %g2                             
40007508:	10 bf ff fa 	b  400074f0 <rtems_fdisk_initialize+0x32c>     
4000750c:	a2 04 40 03 	add  %l1, %g3, %l1                             
      uint32_t                 segment_count;                         
      uint32_t                 segment;                               
                                                                      
      segment_count = rtems_fdisk_count_segments (&c->devices[device]);
                                                                      
      fd->devices[device].segments = calloc (segment_count,           
40007510:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        
40007514:	90 10 00 11 	mov  %l1, %o0                                  
40007518:	9a 00 40 19 	add  %g1, %i1, %o5                             
4000751c:	c2 27 bf ec 	st  %g1, [ %fp + -20 ]                         
40007520:	d8 3f bf c8 	std  %o4, [ %fp + -56 ]                        
40007524:	40 00 02 1f 	call  40007da0 <calloc>                        
40007528:	92 10 20 30 	mov  0x30, %o1                                 
4000752c:	c2 07 bf ec 	ld  [ %fp + -20 ], %g1                         
                                             sizeof (rtems_fdisk_segment_ctl));
      if (!fd->devices[device].segments)                              
40007530:	80 a2 20 00 	cmp  %o0, 0                                    
      uint32_t                 segment_count;                         
      uint32_t                 segment;                               
                                                                      
      segment_count = rtems_fdisk_count_segments (&c->devices[device]);
                                                                      
      fd->devices[device].segments = calloc (segment_count,           
40007534:	d0 20 40 19 	st  %o0, [ %g1 + %i1 ]                         
                                             sizeof (rtems_fdisk_segment_ctl));
      if (!fd->devices[device].segments)                              
40007538:	02 80 00 05 	be  4000754c <rtems_fdisk_initialize+0x388>    <== NEVER TAKEN
4000753c:	d8 1f bf c8 	ldd  [ %fp + -56 ], %o4                        
40007540:	84 10 20 00 	clr  %g2                                       
40007544:	10 80 00 13 	b  40007590 <rtems_fdisk_initialize+0x3cc>     
40007548:	88 10 20 00 	clr  %g4                                       
      {                                                               
        rtems_disk_delete (dev);                                      
4000754c:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
40007550:	7f ff f4 ef 	call  4000490c <rtems_disk_delete>             <== NOT EXECUTED
40007554:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
        rtems_semaphore_delete (fd->lock);                            
40007558:	40 00 14 bd 	call  4000c84c <rtems_semaphore_delete>        <== NOT EXECUTED
4000755c:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        <== NOT EXECUTED
        free (fd->copy_buffer);                                       
40007560:	40 00 02 73 	call  40007f2c <free>                          <== NOT EXECUTED
40007564:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        <== NOT EXECUTED
        free (fd->blocks);                                            
40007568:	40 00 02 71 	call  40007f2c <free>                          <== NOT EXECUTED
4000756c:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        <== NOT EXECUTED
        free (fd->devices);                                           
40007570:	40 00 02 6f 	call  40007f2c <free>                          <== NOT EXECUTED
40007574:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        <== NOT EXECUTED
40007578:	30 bf ff 38 	b,a   40007258 <rtems_fdisk_initialize+0x94>   <== NOT EXECUTED
        return RTEMS_NO_MEMORY;                                       
      }                                                               
                                                                      
      sc = fd->devices[device].segments;                              
                                                                      
      for (segment = 0; segment < c->devices[device].segment_count; segment++)
4000757c:	88 01 20 01 	inc  %g4                                       
40007580:	9f 2b e0 06 	sll  %o7, 6, %o7                               
40007584:	84 00 a0 0c 	add  %g2, 0xc, %g2                             
40007588:	9e 23 c0 01 	sub  %o7, %g1, %o7                             
4000758c:	90 02 00 0f 	add  %o0, %o7, %o0                             
40007590:	80 a1 00 0c 	cmp  %g4, %o4                                  
40007594:	02 bf ff ca 	be  400074bc <rtems_fdisk_initialize+0x2f8>    
40007598:	86 10 20 00 	clr  %g3                                       
      {                                                               
        const rtems_fdisk_segment_desc* sd;                           
        uint32_t                        seg_segment;                  
                                                                      
        sd = &c->devices[device].segments[segment];                   
4000759c:	c2 04 a0 04 	ld  [ %l2 + 4 ], %g1                           
400075a0:	96 00 40 02 	add  %g1, %g2, %o3                             
                                                                      
        for (seg_segment = 0; seg_segment < sd->count; seg_segment++, sc++)
400075a4:	de 10 40 02 	lduh  [ %g1 + %g2 ], %o7                       
400075a8:	82 10 00 08 	mov  %o0, %g1                                  
400075ac:	80 a0 c0 0f 	cmp  %g3, %o7                                  
400075b0:	3a bf ff f3 	bcc,a   4000757c <rtems_fdisk_initialize+0x3b8>
400075b4:	83 2b e0 04 	sll  %o7, 4, %g1                               
        {                                                             
          sc->descriptor = sd;                                        
          sc->device     = device;                                    
          sc->segment    = seg_segment;                               
400075b8:	c6 20 60 0c 	st  %g3, [ %g1 + 0xc ]                         
                                                                      
        sd = &c->devices[device].segments[segment];                   
                                                                      
        for (seg_segment = 0; seg_segment < sd->count; seg_segment++, sc++)
        {                                                             
          sc->descriptor = sd;                                        
400075bc:	d6 20 60 04 	st  %o3, [ %g1 + 4 ]                           
          sc->device     = device;                                    
400075c0:	f0 20 60 08 	st  %i0, [ %g1 + 8 ]                           
          sc->segment    = seg_segment;                               
          sc->erased     = 0;                                         
400075c4:	c0 20 60 2c 	clr  [ %g1 + 0x2c ]                            
        const rtems_fdisk_segment_desc* sd;                           
        uint32_t                        seg_segment;                  
                                                                      
        sd = &c->devices[device].segments[segment];                   
                                                                      
        for (seg_segment = 0; seg_segment < sd->count; seg_segment++, sc++)
400075c8:	86 00 e0 01 	inc  %g3                                       
400075cc:	10 bf ff f8 	b  400075ac <rtems_fdisk_initialize+0x3e8>     
400075d0:	82 00 60 30 	add  %g1, 0x30, %g1                            
                                                                      
      fd->devices[device].segment_count = segment_count;              
      fd->devices[device].descriptor    = &c->devices[device];        
    }                                                                 
                                                                      
    fd->device_count = c->device_count;                               
400075d4:	c2 27 60 30 	st  %g1, [ %i5 + 0x30 ]                        
                                                                      
    ret = rtems_fdisk_recover_block_mappings (fd);                    
400075d8:	7f ff f8 28 	call  40005678 <rtems_fdisk_recover_block_mappings>
400075dc:	90 10 00 1d 	mov  %i5, %o0                                  
    if (ret)                                                          
400075e0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400075e4:	22 80 00 13 	be,a   40007630 <rtems_fdisk_initialize+0x46c> <== ALWAYS TAKEN
400075e8:	90 10 00 1d 	mov  %i5, %o0                                  
    {                                                                 
      rtems_disk_delete (dev);                                        
400075ec:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
400075f0:	7f ff f4 c7 	call  4000490c <rtems_disk_delete>             <== NOT EXECUTED
400075f4:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
      rtems_semaphore_delete (fd->lock);                              
400075f8:	40 00 14 95 	call  4000c84c <rtems_semaphore_delete>        <== NOT EXECUTED
400075fc:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        <== NOT EXECUTED
      free (fd->copy_buffer);                                         
40007600:	40 00 02 4b 	call  40007f2c <free>                          <== NOT EXECUTED
40007604:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        <== NOT EXECUTED
      free (fd->blocks);                                              
40007608:	40 00 02 49 	call  40007f2c <free>                          <== NOT EXECUTED
4000760c:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        <== NOT EXECUTED
      free (fd->devices);                                             
40007610:	40 00 02 47 	call  40007f2c <free>                          <== NOT EXECUTED
40007614:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        <== NOT EXECUTED
      rtems_fdisk_error ("recovery of disk failed: %s (%d)",          
40007618:	40 00 6f 5d 	call  4002338c <strerror>                      <== NOT EXECUTED
4000761c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40007620:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
40007624:	11 10 00 cb 	sethi  %hi(0x40032c00), %o0                    <== NOT EXECUTED
40007628:	10 80 00 17 	b  40007684 <rtems_fdisk_initialize+0x4c0>     <== NOT EXECUTED
4000762c:	90 12 20 e8 	or  %o0, 0xe8, %o0	! 40032ce8 <__FUNCTION__.6501+0xc80><== NOT EXECUTED
                         strerror (ret), ret);                        
      return ret;                                                     
    }                                                                 
                                                                      
    ret = rtems_fdisk_compact (fd);                                   
40007630:	7f ff f9 f0 	call  40005df0 <rtems_fdisk_compact>           
40007634:	a0 04 20 74 	add  %l0, 0x74, %l0                            
    if (ret)                                                          
40007638:	80 a2 20 00 	cmp  %o0, 0                                    
4000763c:	02 80 00 16 	be  40007694 <rtems_fdisk_initialize+0x4d0>    <== ALWAYS TAKEN
40007640:	b0 10 00 08 	mov  %o0, %i0                                  
    {                                                                 
      rtems_disk_delete (dev);                                        
40007644:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
40007648:	7f ff f4 b1 	call  4000490c <rtems_disk_delete>             <== NOT EXECUTED
4000764c:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
      rtems_semaphore_delete (fd->lock);                              
40007650:	40 00 14 7f 	call  4000c84c <rtems_semaphore_delete>        <== NOT EXECUTED
40007654:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        <== NOT EXECUTED
      free (fd->copy_buffer);                                         
40007658:	40 00 02 35 	call  40007f2c <free>                          <== NOT EXECUTED
4000765c:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        <== NOT EXECUTED
      free (fd->blocks);                                              
40007660:	40 00 02 33 	call  40007f2c <free>                          <== NOT EXECUTED
40007664:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        <== NOT EXECUTED
      free (fd->devices);                                             
40007668:	40 00 02 31 	call  40007f2c <free>                          <== NOT EXECUTED
4000766c:	d0 07 60 2c 	ld  [ %i5 + 0x2c ], %o0                        <== NOT EXECUTED
      rtems_fdisk_error ("compacting of disk failed: %s (%d)",        
40007670:	40 00 6f 47 	call  4002338c <strerror>                      <== NOT EXECUTED
40007674:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40007678:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4000767c:	11 10 00 cb 	sethi  %hi(0x40032c00), %o0                    <== NOT EXECUTED
40007680:	90 12 21 10 	or  %o0, 0x110, %o0	! 40032d10 <__FUNCTION__.6501+0xca8><== NOT EXECUTED
40007684:	7f ff f6 86 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40007688:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
                         strerror (ret), ret);                        
      return ret;                                                     
4000768c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40007690:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                             sizeof (rtems_flashdisk));               
                                                                      
  if (!rtems_flashdisks)                                              
    return RTEMS_NO_MEMORY;                                           
                                                                      
  for (minor = 0; minor < rtems_flashdisk_configuration_size; minor++, c++)
40007694:	b6 06 e0 01 	inc  %i3                                       
40007698:	10 bf ff 02 	b  400072a0 <rtems_fdisk_initialize+0xdc>      
4000769c:	b8 07 20 20 	add  %i4, 0x20, %i4                            
                         strerror (ret), ret);                        
      return ret;                                                     
    }                                                                 
  }                                                                   
                                                                      
  rtems_flashdisk_count = rtems_flashdisk_configuration_size;         
400076a0:	05 10 01 1f 	sethi  %hi(0x40047c00), %g2                    
400076a4:	c2 20 a3 a4 	st  %g1, [ %g2 + 0x3a4 ]	! 40047fa4 <rtems_flashdisk_count>
400076a8:	b0 10 20 00 	clr  %i0                                       
                                                                      
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
400076ac:	81 c7 e0 08 	ret                                            
400076b0:	81 e8 00 00 	restore                                        
                                                                      

400060bc <rtems_fdisk_ioctl>: * @param argp IOCTL argument. * @retval The IOCTL return value */ static int rtems_fdisk_ioctl (rtems_disk_device *dd, uint32_t req, void* argp) {
400060bc:	9d e3 bf 48 	save  %sp, -184, %sp                           
  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;                                       
                                                                      
  errno = 0;                                                          
400060c0:	40 00 6b 77 	call  40020e9c <__errno>                       
400060c4:	f8 06 20 04 	ld  [ %i0 + 4 ], %i4                           
                                                                      
  sc = rtems_semaphore_obtain (rtems_flashdisks[minor].lock, RTEMS_WAIT, 0);
400060c8:	83 2f 20 02 	sll  %i4, 2, %g1                               
400060cc:	b7 2f 20 05 	sll  %i4, 5, %i3                               
400060d0:	3b 10 01 1f 	sethi  %hi(0x40047c00), %i5                    
400060d4:	b6 26 c0 01 	sub  %i3, %g1, %i3                             
400060d8:	c2 07 63 a8 	ld  [ %i5 + 0x3a8 ], %g1                       
  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;                                       
                                                                      
  errno = 0;                                                          
400060dc:	c0 22 00 00 	clr  [ %o0 ]                                   
                                                                      
  sc = rtems_semaphore_obtain (rtems_flashdisks[minor].lock, RTEMS_WAIT, 0);
400060e0:	b6 06 c0 1c 	add  %i3, %i4, %i3                             
400060e4:	b7 2e e0 02 	sll  %i3, 2, %i3                               
400060e8:	82 00 40 1b 	add  %g1, %i3, %g1                             
400060ec:	d0 00 60 64 	ld  [ %g1 + 0x64 ], %o0                        
400060f0:	92 10 20 00 	clr  %o1                                       
400060f4:	40 00 1a 0e 	call  4000c92c <rtems_semaphore_obtain>        
400060f8:	94 10 20 00 	clr  %o2                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
400060fc:	80 a2 20 00 	cmp  %o0, 0                                    
40006100:	12 80 04 24 	bne  40007190 <rtems_fdisk_ioctl+0x10d4>       <== NEVER TAKEN
40006104:	01 00 00 00 	nop                                            
    errno = EIO;                                                      
  else                                                                
  {                                                                   
    errno = 0;                                                        
40006108:	40 00 6b 65 	call  40020e9c <__errno>                       
4000610c:	01 00 00 00 	nop                                            
    switch (req)                                                      
40006110:	03 08 00 10 	sethi  %hi(0x20004000), %g1                    
40006114:	84 10 62 83 	or  %g1, 0x283, %g2	! 20004283 <RAM_SIZE+0x1fc04283>
40006118:	80 a6 40 02 	cmp  %i1, %g2                                  
4000611c:	02 80 02 b0 	be  40006bdc <rtems_fdisk_ioctl+0xb20>         <== NEVER TAKEN
40006120:	c0 22 00 00 	clr  [ %o0 ]                                   
40006124:	80 a6 40 02 	cmp  %i1, %g2                                  
40006128:	38 80 00 1a 	bgu,a   40006190 <rtems_fdisk_ioctl+0xd4>      
4000612c:	82 10 62 85 	or  %g1, 0x285, %g1                            
40006130:	84 10 62 81 	or  %g1, 0x281, %g2                            
40006134:	80 a6 40 02 	cmp  %i1, %g2                                  
40006138:	02 80 02 8d 	be  40006b6c <rtems_fdisk_ioctl+0xab0>         <== NEVER TAKEN
4000613c:	01 00 00 00 	nop                                            
40006140:	18 80 02 93 	bgu  40006b8c <rtems_fdisk_ioctl+0xad0>        <== NEVER TAKEN
40006144:	82 10 62 80 	or  %g1, 0x280, %g1                            
40006148:	80 a6 40 01 	cmp  %i1, %g1                                  
4000614c:	32 80 04 06 	bne,a   40007164 <rtems_fdisk_ioctl+0x10a8>    <== ALWAYS TAKEN
40006150:	90 10 00 18 	mov  %i0, %o0                                  
          }                                                           
        }                                                             
        break;                                                        
                                                                      
      case RTEMS_FDISK_IOCTL_ERASE_DISK:                              
        errno = rtems_fdisk_erase_disk (&rtems_flashdisks[minor]);    
40006154:	40 00 6b 52 	call  40020e9c <__errno>                       <== NOT EXECUTED
40006158:	21 10 00 ca 	sethi  %hi(0x40032800), %l0                    <== NOT EXECUTED
4000615c:	fa 07 63 a8 	ld  [ %i5 + 0x3a8 ], %i5                       <== NOT EXECUTED
40006160:	b2 10 00 08 	mov  %o0, %i1                                  <== NOT EXECUTED
40006164:	ba 07 40 1b 	add  %i5, %i3, %i5                             <== NOT EXECUTED
{                                                                     
  uint32_t device;                                                    
  int      ret;                                                       
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd, "erase-disk");                                
40006168:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    <== NOT EXECUTED
4000616c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40006170:	92 12 62 a8 	or  %o1, 0x2a8, %o1                            <== NOT EXECUTED
40006174:	7f ff fb 88 	call  40004f94 <rtems_fdisk_info>              <== NOT EXECUTED
40006178:	31 10 00 ca 	sethi  %hi(0x40032800), %i0                    <== NOT EXECUTED
4000617c:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_erase_flash (const rtems_flashdisk* fd)                   
{                                                                     
  uint32_t device;                                                    
  for (device = 0; device < fd->device_count; device++)               
40006180:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
  {                                                                   
    int ret;                                                          
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_info (fd, " erase-flash:%02d", device);               
40006184:	a0 14 22 b8 	or  %l0, 0x2b8, %l0                            <== NOT EXECUTED
rtems_fdisk_device_erase (const rtems_flashdisk* fd, uint32_t device) 
{                                                                     
  const rtems_fdisk_driver_handlers* ops;                             
  ops = fd->devices[device].descriptor->flash_ops;                    
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, " device-erase: %02d", device);             
40006188:	10 80 02 62 	b  40006b10 <rtems_fdisk_ioctl+0xa54>          <== NOT EXECUTED
4000618c:	b0 16 22 d0 	or  %i0, 0x2d0, %i0                            <== NOT EXECUTED
  if (sc != RTEMS_SUCCESSFUL)                                         
    errno = EIO;                                                      
  else                                                                
  {                                                                   
    errno = 0;                                                        
    switch (req)                                                      
40006190:	80 a6 40 01 	cmp  %i1, %g1                                  
40006194:	02 80 02 f3 	be  40006d60 <rtems_fdisk_ioctl+0xca4>         
40006198:	01 00 00 00 	nop                                            
4000619c:	0a 80 02 ed 	bcs  40006d50 <rtems_fdisk_ioctl+0xc94>        <== NEVER TAKEN
400061a0:	03 30 06 10 	sethi  %hi(0xc0184000), %g1                    
400061a4:	82 10 62 01 	or  %g1, 0x201, %g1	! c0184201 <RAM_END+0x7fd84201>
400061a8:	80 a6 40 01 	cmp  %i1, %g1                                  
400061ac:	12 80 03 ed 	bne  40007160 <rtems_fdisk_ioctl+0x10a4>       
400061b0:	03 10 01 1f 	sethi  %hi(0x40047c00), %g1                    
    {                                                                 
      case RTEMS_BLKIO_REQUEST:                                       
        if ((minor >= rtems_flashdisk_count) ||                       
400061b4:	c2 00 63 a4 	ld  [ %g1 + 0x3a4 ], %g1	! 40047fa4 <rtems_flashdisk_count>
400061b8:	80 a7 00 01 	cmp  %i4, %g1                                  
400061bc:	1a 80 00 08 	bcc  400061dc <rtems_fdisk_ioctl+0x120>        <== NEVER TAKEN
400061c0:	01 00 00 00 	nop                                            
            (rtems_flashdisks[minor].device_count == 0))              
400061c4:	c2 07 63 a8 	ld  [ %i5 + 0x3a8 ], %g1                       
400061c8:	82 00 40 1b 	add  %g1, %i3, %g1                             
  {                                                                   
    errno = 0;                                                        
    switch (req)                                                      
    {                                                                 
      case RTEMS_BLKIO_REQUEST:                                       
        if ((minor >= rtems_flashdisk_count) ||                       
400061cc:	c2 00 60 30 	ld  [ %g1 + 0x30 ], %g1                        
400061d0:	80 a0 60 00 	cmp  %g1, 0                                    
400061d4:	32 80 00 06 	bne,a   400061ec <rtems_fdisk_ioctl+0x130>     <== ALWAYS TAKEN
400061d8:	c2 06 80 00 	ld  [ %i2 ], %g1                               
            (rtems_flashdisks[minor].device_count == 0))              
        {                                                             
          errno = ENODEV;                                             
400061dc:	40 00 6b 30 	call  40020e9c <__errno>                       <== NOT EXECUTED
400061e0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400061e4:	10 80 02 34 	b  40006ab4 <rtems_fdisk_ioctl+0x9f8>          <== NOT EXECUTED
400061e8:	82 10 20 13 	mov  0x13, %g1	! 13 <_TLS_Alignment+0x12>      <== NOT EXECUTED
        }                                                             
        else                                                          
        {                                                             
          switch (r->req)                                             
400061ec:	80 a0 60 00 	cmp  %g1, 0                                    
400061f0:	02 80 00 0b 	be  4000621c <rtems_fdisk_ioctl+0x160>         
400061f4:	80 a0 60 01 	cmp  %g1, 1                                    
400061f8:	12 80 02 2c 	bne  40006aa8 <rtems_fdisk_ioctl+0x9ec>        <== NEVER TAKEN
400061fc:	01 00 00 00 	nop                                            
            case RTEMS_BLKDEV_REQ_READ:                               
              errno = rtems_fdisk_read (&rtems_flashdisks[minor], r); 
              break;                                                  
                                                                      
            case RTEMS_BLKDEV_REQ_WRITE:                              
              errno = rtems_fdisk_write (&rtems_flashdisks[minor], r);
40006200:	40 00 6b 27 	call  40020e9c <__errno>                       
40006204:	a0 06 a0 18 	add  %i2, 0x18, %l0                            
40006208:	fa 07 63 a8 	ld  [ %i5 + 0x3a8 ], %i5                       
4000620c:	d0 27 bf f0 	st  %o0, [ %fp + -16 ]                         
40006210:	ba 07 40 1b 	add  %i5, %i3, %i5                             
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
40006214:	10 80 00 aa 	b  400064bc <rtems_fdisk_ioctl+0x400>          
40006218:	c0 27 bf f4 	clr  [ %fp + -12 ]                             
        else                                                          
        {                                                             
          switch (r->req)                                             
          {                                                           
            case RTEMS_BLKDEV_REQ_READ:                               
              errno = rtems_fdisk_read (&rtems_flashdisks[minor], r); 
4000621c:	40 00 6b 20 	call  40020e9c <__errno>                       
40006220:	b2 06 a0 18 	add  %i2, 0x18, %i1                            
40006224:	f8 07 63 a8 	ld  [ %i5 + 0x3a8 ], %i4                       
40006228:	d0 27 bf f4 	st  %o0, [ %fp + -12 ]                         
4000622c:	b8 07 00 1b 	add  %i4, %i3, %i4                             
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
40006230:	a2 10 20 00 	clr  %l1                                       
40006234:	c2 06 a0 10 	ld  [ %i2 + 0x10 ], %g1                        
40006238:	80 a4 40 01 	cmp  %l1, %g1                                  
4000623c:	1a 80 00 9b 	bcc  400064a8 <rtems_fdisk_ioctl+0x3ec>        
40006240:	92 10 20 00 	clr  %o1                                       
  {                                                                   
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
40006244:	d0 06 60 04 	ld  [ %i1 + 4 ], %o0                           
40006248:	d2 07 20 14 	ld  [ %i4 + 0x14 ], %o1                        
4000624c:	7f ff f1 02 	call  40002654 <.udiv>                         
40006250:	a0 10 20 00 	clr  %l0                                       
    data = sg->buffer;                                                
40006254:	f0 06 60 08 	ld  [ %i1 + 8 ], %i0                           
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
  {                                                                   
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
40006258:	d0 27 bf f0 	st  %o0, [ %fp + -16 ]                         
                                                                      
  sc = fd->blocks[block].segment;                                     
  pd = &sc->page_descriptors[bc->page];                               
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd,                                               
4000625c:	2d 10 00 c8 	sethi  %hi(0x40032000), %l6                    
40006260:	2f 10 00 c8 	sethi  %hi(0x40032000), %l7                    
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
40006264:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
40006268:	80 a4 00 01 	cmp  %l0, %g1                                  
4000626c:	02 80 00 89 	be  40006490 <rtems_fdisk_ioctl+0x3d4>         
40006270:	90 10 00 1c 	mov  %i4, %o0                                  
    {                                                                 
      ret = rtems_fdisk_read_block (fd, sg->block + b, data);         
40006274:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40006278:	a8 04 00 01 	add  %l0, %g1, %l4                             
  rtems_fdisk_block_ctl*   bc;                                        
  rtems_fdisk_segment_ctl* sc;                                        
  rtems_fdisk_page_desc*   pd;                                        
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd, "read-block:%d", block);                      
4000627c:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
40006280:	94 10 00 14 	mov  %l4, %o2                                  
40006284:	7f ff fb 44 	call  40004f94 <rtems_fdisk_info>              
40006288:	92 12 62 98 	or  %o1, 0x298, %o1                            
                                                                      
  /*                                                                  
   * Broken out to allow info messages when testing.                  
   */                                                                 
                                                                      
  if (block >= (fd->block_count - fd->unavail_blocks))                
4000628c:	c6 07 20 1c 	ld  [ %i4 + 0x1c ], %g3                        
40006290:	c4 07 20 20 	ld  [ %i4 + 0x20 ], %g2                        
40006294:	84 20 c0 02 	sub  %g3, %g2, %g2                             
40006298:	80 a5 00 02 	cmp  %l4, %g2                                  
4000629c:	2a 80 00 08 	bcs,a   400062bc <rtems_fdisk_ioctl+0x200>     <== ALWAYS TAKEN
400062a0:	c8 07 20 18 	ld  [ %i4 + 0x18 ], %g4                        
  {                                                                   
    rtems_fdisk_error ("read-block: block out of range: %d", block);  
400062a4:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
400062a8:	92 10 00 14 	mov  %l4, %o1                                  <== NOT EXECUTED
400062ac:	7f ff fb 7c 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
400062b0:	90 12 22 a8 	or  %o0, 0x2a8, %o0                            <== NOT EXECUTED
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
400062b4:	10 80 00 78 	b  40006494 <rtems_fdisk_ioctl+0x3d8>          <== NOT EXECUTED
400062b8:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
  {                                                                   
    rtems_fdisk_error ("read-block: block out of range: %d", block);  
    return EIO;                                                       
  }                                                                   
                                                                      
  bc = &fd->blocks[block];                                            
400062bc:	87 2d 20 03 	sll  %l4, 3, %g3                               
                                                                      
  if (!bc->segment)                                                   
400062c0:	fa 01 00 03 	ld  [ %g4 + %g3 ], %i5                         
400062c4:	80 a7 60 00 	cmp  %i5, 0                                    
400062c8:	12 80 00 0d 	bne  400062fc <rtems_fdisk_ioctl+0x240>        
400062cc:	aa 01 00 03 	add  %g4, %g3, %l5                             
  {                                                                   
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_info (fd, "read-block: no segment mapping: %d", block);
400062d0:	94 10 00 14 	mov  %l4, %o2                                  
400062d4:	90 10 00 1c 	mov  %i4, %o0                                  
400062d8:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
400062dc:	7f ff fb 2e 	call  40004f94 <rtems_fdisk_info>              
400062e0:	92 12 62 d0 	or  %o1, 0x2d0, %o1	! 400326d0 <__FUNCTION__.6501+0x668>
#endif                                                                
    memset (buffer, 0xff, fd->block_size);                            
400062e4:	d4 07 20 14 	ld  [ %i4 + 0x14 ], %o2                        
400062e8:	90 10 00 18 	mov  %i0, %o0                                  
400062ec:	40 00 6f 6e 	call  400220a4 <memset>                        
400062f0:	92 10 20 ff 	mov  0xff, %o1                                 
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
400062f4:	10 80 00 64 	b  40006484 <rtems_fdisk_ioctl+0x3c8>          
400062f8:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
    memset (buffer, 0xff, fd->block_size);                            
    return 0;                                                         
  }                                                                   
                                                                      
  sc = fd->blocks[block].segment;                                     
  pd = &sc->page_descriptors[bc->page];                               
400062fc:	da 05 60 04 	ld  [ %l5 + 4 ], %o5                           
40006300:	e6 07 60 10 	ld  [ %i5 + 0x10 ], %l3                        
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd,                                               
40006304:	c8 07 40 00 	ld  [ %i5 ], %g4                               
    memset (buffer, 0xff, fd->block_size);                            
    return 0;                                                         
  }                                                                   
                                                                      
  sc = fd->blocks[block].segment;                                     
  pd = &sc->page_descriptors[bc->page];                               
40006308:	a5 2b 60 03 	sll  %o5, 3, %l2                               
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd,                                               
4000630c:	d6 07 60 08 	ld  [ %i5 + 8 ], %o3                           
    memset (buffer, 0xff, fd->block_size);                            
    return 0;                                                         
  }                                                                   
                                                                      
  sc = fd->blocks[block].segment;                                     
  pd = &sc->page_descriptors[bc->page];                               
40006310:	86 04 c0 12 	add  %l3, %l2, %g3                             
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd,                                               
40006314:	d8 07 60 0c 	ld  [ %i5 + 0xc ], %o4                         
40006318:	d0 07 60 14 	ld  [ %i5 + 0x14 ], %o0                        
4000631c:	d2 07 60 1c 	ld  [ %i5 + 0x1c ], %o1                        
40006320:	d4 07 60 20 	ld  [ %i5 + 0x20 ], %o2                        
40006324:	80 a1 20 00 	cmp  %g4, 0                                    
40006328:	02 80 00 04 	be  40006338 <rtems_fdisk_ioctl+0x27c>         
4000632c:	de 07 60 24 	ld  [ %i5 + 0x24 ], %o7                        
40006330:	10 80 00 03 	b  4000633c <rtems_fdisk_ioctl+0x280>          
40006334:	88 15 e2 a8 	or  %l7, 0x2a8, %g4                            
40006338:	88 15 a2 b0 	or  %l6, 0x2b0, %g4                            
4000633c:	d0 23 a0 5c 	st  %o0, [ %sp + 0x5c ]                        
40006340:	d2 23 a0 60 	st  %o1, [ %sp + 0x60 ]                        
40006344:	d4 23 a0 64 	st  %o2, [ %sp + 0x64 ]                        
40006348:	de 23 a0 68 	st  %o7, [ %sp + 0x68 ]                        
4000634c:	c8 23 a0 6c 	st  %g4, [ %sp + 0x6c ]                        
40006350:	c8 10 e0 02 	lduh  [ %g3 + 2 ], %g4                         
40006354:	90 10 00 1c 	mov  %i4, %o0                                  
40006358:	c8 23 a0 70 	st  %g4, [ %sp + 0x70 ]                        
4000635c:	c8 14 c0 12 	lduh  [ %l3 + %l2 ], %g4                       
40006360:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
40006364:	c8 23 a0 74 	st  %g4, [ %sp + 0x74 ]                        
40006368:	c8 00 e0 04 	ld  [ %g3 + 4 ], %g4                           
4000636c:	92 12 62 f8 	or  %o1, 0x2f8, %o1                            
40006370:	c6 27 bf dc 	st  %g3, [ %fp + -36 ]                         
40006374:	c8 23 a0 78 	st  %g4, [ %sp + 0x78 ]                        
40006378:	7f ff fb 07 	call  40004f94 <rtems_fdisk_info>              
4000637c:	94 10 00 14 	mov  %l4, %o2                                  
                        uint32_t         block,                       
                        uint8_t*         buffer)                      
{                                                                     
  rtems_fdisk_block_ctl*   bc;                                        
  rtems_fdisk_segment_ctl* sc;                                        
  rtems_fdisk_page_desc*   pd;                                        
40006380:	c6 07 bf dc 	ld  [ %fp + -36 ], %g3                         
40006384:	c6 10 e0 02 	lduh  [ %g3 + 2 ], %g3                         
                    sc->pages, sc->pages_active, sc->pages_used, sc->pages_bad,
                    sc->next ? "set" : "null",                        
                    pd->flags, pd->crc, pd->block);                   
#endif                                                                
                                                                      
  if (rtems_fdisk_page_desc_flags_set (pd, RTEMS_FDISK_PAGE_ACTIVE))  
40006388:	80 88 e0 01 	btst  1, %g3                                   
4000638c:	12 80 00 35 	bne  40006460 <rtems_fdisk_ioctl+0x3a4>        <== NEVER TAKEN
40006390:	d8 05 60 04 	ld  [ %l5 + 4 ], %o4                           
  {                                                                   
    if (rtems_fdisk_page_desc_flags_clear (pd, RTEMS_FDISK_PAGE_USED))
40006394:	80 88 e0 02 	btst  2, %g3                                   
40006398:	02 80 00 30 	be  40006458 <rtems_fdisk_ioctl+0x39c>         <== NEVER TAKEN
4000639c:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    
                           rtems_fdisk_segment_ctl* sc,               
                           uint32_t                 page,             
                           void*                    buffer)           
{                                                                     
  return rtems_fdisk_seg_read (fd, sc,                                
                               page * fd->block_size, buffer, fd->block_size);
400063a0:	c6 07 20 14 	ld  [ %i4 + 0x14 ], %g3                        
                                                                      
      /*                                                              
       * We use the segment page offset not the page number used in the
       * driver. This skips the page descriptors.                     
       */                                                             
      int ret = rtems_fdisk_seg_read_page (fd, sc,                    
400063a4:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
rtems_fdisk_seg_read_page (const rtems_flashdisk*   fd,               
                           rtems_fdisk_segment_ctl* sc,               
                           uint32_t                 page,             
                           void*                    buffer)           
{                                                                     
  return rtems_fdisk_seg_read (fd, sc,                                
400063a8:	92 10 00 03 	mov  %g3, %o1                                  
400063ac:	90 02 00 0c 	add  %o0, %o4, %o0                             
400063b0:	7f ff f0 6f 	call  4000256c <.umul>                         
400063b4:	c6 27 bf dc 	st  %g3, [ %fp + -36 ]                         
400063b8:	c6 07 bf dc 	ld  [ %fp + -36 ], %g3                         
400063bc:	94 10 00 08 	mov  %o0, %o2                                  
400063c0:	98 10 00 03 	mov  %g3, %o4                                  
400063c4:	90 10 00 1c 	mov  %i4, %o0                                  
400063c8:	92 10 00 1d 	mov  %i5, %o1                                  
400063cc:	7f ff fb ac 	call  4000527c <rtems_fdisk_seg_read>          
400063d0:	96 10 00 18 	mov  %i0, %o3                                  
       * driver. This skips the page descriptors.                     
       */                                                             
      int ret = rtems_fdisk_seg_read_page (fd, sc,                    
                                           bc->page + sc->pages_desc, buffer);
                                                                      
      if (ret)                                                        
400063d4:	86 92 20 00 	orcc  %o0, 0, %g3                              
400063d8:	22 80 00 13 	be,a   40006424 <rtems_fdisk_ioctl+0x368>      <== ALWAYS TAKEN
400063dc:	d2 07 20 14 	ld  [ %i4 + 0x14 ], %o1                        
      {                                                               
#if RTEMS_FDISK_TRACE                                                 
        rtems_fdisk_info (fd,                                         
400063e0:	e0 07 60 08 	ld  [ %i5 + 8 ], %l0                           <== NOT EXECUTED
400063e4:	f0 07 60 0c 	ld  [ %i5 + 0xc ], %i0                         <== NOT EXECUTED
400063e8:	fa 05 60 04 	ld  [ %l5 + 4 ], %i5                           <== NOT EXECUTED
400063ec:	40 00 73 e8 	call  4002338c <strerror>                      <== NOT EXECUTED
400063f0:	c6 27 bf dc 	st  %g3, [ %fp + -36 ]                         <== NOT EXECUTED
400063f4:	c6 07 bf dc 	ld  [ %fp + -36 ], %g3                         <== NOT EXECUTED
400063f8:	9a 10 00 08 	mov  %o0, %o5                                  <== NOT EXECUTED
400063fc:	c6 23 a0 5c 	st  %g3, [ %sp + 0x5c ]                        <== NOT EXECUTED
40006400:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
40006404:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    <== NOT EXECUTED
40006408:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
4000640c:	92 12 63 40 	or  %o1, 0x340, %o1                            <== NOT EXECUTED
40006410:	96 10 00 18 	mov  %i0, %o3                                  <== NOT EXECUTED
40006414:	7f ff fa e0 	call  40004f94 <rtems_fdisk_info>              <== NOT EXECUTED
40006418:	98 10 00 1d 	mov  %i5, %o4                                  <== NOT EXECUTED
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
4000641c:	10 80 00 1e 	b  40006494 <rtems_fdisk_ioctl+0x3d8>          <== NOT EXECUTED
40006420:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
                          strerror (ret), ret);                       
#endif                                                                
        return ret;                                                   
      }                                                               
                                                                      
      cs = rtems_fdisk_page_checksum (buffer, fd->block_size);        
40006424:	7f ff fa a9 	call  40004ec8 <rtems_fdisk_page_checksum>     
40006428:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
      if (cs == pd->crc)                                              
4000642c:	d6 14 c0 12 	lduh  [ %l3 + %l2 ], %o3                       
40006430:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
40006434:	95 32 20 10 	srl  %o0, 0x10, %o2                            
40006438:	80 a2 80 0b 	cmp  %o2, %o3                                  
4000643c:	02 80 00 11 	be  40006480 <rtems_fdisk_ioctl+0x3c4>         <== ALWAYS TAKEN
40006440:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    
        return 0;                                                     
                                                                      
      rtems_fdisk_error ("read-block: crc failure: %d: buffer:%04x page:%04x",
40006444:	92 10 00 14 	mov  %l4, %o1                                  <== NOT EXECUTED
40006448:	7f ff fb 15 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
4000644c:	90 12 23 78 	or  %o0, 0x378, %o0                            <== NOT EXECUTED
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
40006450:	10 80 00 11 	b  40006494 <rtems_fdisk_ioctl+0x3d8>          <== NOT EXECUTED
40006454:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
      rtems_fdisk_error ("read-block: crc failure: %d: buffer:%04x page:%04x",
                         block, cs, pd->crc);                         
    }                                                                 
    else                                                              
    {                                                                 
      rtems_fdisk_error ("read-block: block points to used page: %d: %d-%d-%d",
40006458:	10 80 00 04 	b  40006468 <rtems_fdisk_ioctl+0x3ac>          <== NOT EXECUTED
4000645c:	90 12 23 b0 	or  %o0, 0x3b0, %o0                            <== NOT EXECUTED
                         block, sc->device, sc->segment, bc->page);   
    }                                                                 
  }                                                                   
  else                                                                
  {                                                                   
    rtems_fdisk_error ("read-block: block page not active: %d: %d-%d-%d",
40006460:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
40006464:	90 12 23 e8 	or  %o0, 0x3e8, %o0	! 400327e8 <__FUNCTION__.6501+0x780><== NOT EXECUTED
40006468:	d4 07 60 08 	ld  [ %i5 + 8 ], %o2                           <== NOT EXECUTED
4000646c:	d6 07 60 0c 	ld  [ %i5 + 0xc ], %o3                         <== NOT EXECUTED
40006470:	7f ff fb 0b 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40006474:	92 10 00 14 	mov  %l4, %o1                                  <== NOT EXECUTED
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
40006478:	10 80 03 51 	b  400071bc <rtems_fdisk_ioctl+0x1100>         <== NOT EXECUTED
4000647c:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
40006480:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
40006484:	a0 04 20 01 	inc  %l0                                       
40006488:	10 bf ff 77 	b  40006264 <rtems_fdisk_ioctl+0x1a8>          
4000648c:	b0 06 00 01 	add  %i0, %g1, %i0                             
40006490:	82 10 20 00 	clr  %g1                                       
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
40006494:	a2 04 60 01 	inc  %l1                                       
40006498:	80 a0 60 00 	cmp  %g1, 0                                    
4000649c:	02 bf ff 66 	be  40006234 <rtems_fdisk_ioctl+0x178>         <== ALWAYS TAKEN
400064a0:	b2 06 60 10 	add  %i1, 0x10, %i1                            
400064a4:	92 10 20 1b 	mov  0x1b, %o1                                 <== NOT EXECUTED
static inline void rtems_blkdev_request_done(                         
  rtems_blkdev_request *req,                                          
  rtems_status_code status                                            
)                                                                     
{                                                                     
  (*req->done)(req, status);                                          
400064a8:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
400064ac:	9f c0 40 00 	call  %g1                                      
400064b0:	90 10 00 1a 	mov  %i2, %o0                                  
      case RTEMS_FDISK_IOCTL_INFO_LEVEL:                              
        rtems_flashdisks[minor].info_level = (uintptr_t) argp;        
        break;                                                        
                                                                      
      case RTEMS_FDISK_IOCTL_PRINT_STATUS:                            
        errno = rtems_fdisk_print_status (&rtems_flashdisks[minor]);  
400064b4:	10 80 03 29 	b  40007158 <rtems_fdisk_ioctl+0x109c>         
400064b8:	c4 07 bf f4 	ld  [ %fp + -12 ], %g2                         
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
400064bc:	c2 06 a0 10 	ld  [ %i2 + 0x10 ], %g1                        
400064c0:	c4 07 bf f4 	ld  [ %fp + -12 ], %g2                         
400064c4:	80 a0 80 01 	cmp  %g2, %g1                                  
400064c8:	1a 80 01 72 	bcc  40006a90 <rtems_fdisk_ioctl+0x9d4>        
400064cc:	92 10 20 00 	clr  %o1                                       
  {                                                                   
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
400064d0:	d0 04 20 04 	ld  [ %l0 + 4 ], %o0                           
400064d4:	d2 07 60 14 	ld  [ %i5 + 0x14 ], %o1                        
400064d8:	7f ff f0 5f 	call  40002654 <.udiv>                         
400064dc:	a4 10 20 00 	clr  %l2                                       
    data = sg->buffer;                                                
400064e0:	e2 04 20 08 	ld  [ %l0 + 8 ], %l1                           
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
  {                                                                   
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
400064e4:	d0 27 bf ec 	st  %o0, [ %fp + -20 ]                         
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
400064e8:	c2 07 bf ec 	ld  [ %fp + -20 ], %g1                         
400064ec:	80 a4 80 01 	cmp  %l2, %g1                                  
400064f0:	02 80 01 60 	be  40006a70 <rtems_fdisk_ioctl+0x9b4>         
400064f4:	90 10 00 1d 	mov  %i5, %o0                                  
    {                                                                 
      ret = rtems_fdisk_write_block (fd, sg->block + b, data);        
400064f8:	f2 04 00 00 	ld  [ %l0 ], %i1                               
400064fc:	b2 04 80 19 	add  %l2, %i1, %i1                             
  rtems_fdisk_page_desc*   pd;                                        
  uint32_t                 page;                                      
  int                      ret;                                       
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd, "write-block:%d", block);                     
40006500:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006504:	94 10 00 19 	mov  %i1, %o2                                  
40006508:	7f ff fa a3 	call  40004f94 <rtems_fdisk_info>              
4000650c:	92 12 60 18 	or  %o1, 0x18, %o1                             
                                                                      
  /*                                                                  
   * Broken out to allow info messages when testing.                  
   */                                                                 
                                                                      
  if (block >= (fd->block_count - fd->unavail_blocks))                
40006510:	c4 07 60 1c 	ld  [ %i5 + 0x1c ], %g2                        
40006514:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
40006518:	82 20 80 01 	sub  %g2, %g1, %g1                             
4000651c:	80 a6 40 01 	cmp  %i1, %g1                                  
40006520:	2a 80 00 08 	bcs,a   40006540 <rtems_fdisk_ioctl+0x484>     <== ALWAYS TAKEN
40006524:	ec 07 60 18 	ld  [ %i5 + 0x18 ], %l6                        
  {                                                                   
    rtems_fdisk_error ("write-block: block out of range: %d", block); 
40006528:	11 10 00 ca 	sethi  %hi(0x40032800), %o0                    <== NOT EXECUTED
4000652c:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
40006530:	7f ff fa db 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40006534:	90 12 20 28 	or  %o0, 0x28, %o0                             <== NOT EXECUTED
                     sc->device, sc->segment);                        
                                                                      
  sc->failed = true;                                                  
  rtems_fdisk_queue_segment (fd, sc);                                 
                                                                      
  return EIO;                                                         
40006538:	10 80 01 4f 	b  40006a74 <rtems_fdisk_ioctl+0x9b8>          <== NOT EXECUTED
4000653c:	b8 10 20 05 	mov  5, %i4                                    <== NOT EXECUTED
  {                                                                   
    rtems_fdisk_error ("write-block: block out of range: %d", block); 
    return EIO;                                                       
  }                                                                   
                                                                      
  bc = &fd->blocks[block];                                            
40006540:	ab 2e 60 03 	sll  %i1, 3, %l5                               
                                                                      
  /*                                                                  
   * Does the page exist in flash ?                                   
   */                                                                 
  if (bc->segment)                                                    
40006544:	f8 05 80 15 	ld  [ %l6 + %l5 ], %i4                         
40006548:	80 a7 20 00 	cmp  %i4, 0                                    
4000654c:	02 80 00 96 	be  400067a4 <rtems_fdisk_ioctl+0x6e8>         
40006550:	b0 05 80 15 	add  %l6, %l5, %i0                             
  {                                                                   
    sc = bc->segment;                                                 
    pd = &sc->page_descriptors[bc->page];                             
40006554:	c2 07 20 10 	ld  [ %i4 + 0x10 ], %g1                        
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_info (fd, " write:%02d-%03d-%03d: flag used",         
40006558:	d4 07 20 08 	ld  [ %i4 + 8 ], %o2                           
4000655c:	d6 07 20 0c 	ld  [ %i4 + 0xc ], %o3                         
   * Does the page exist in flash ?                                   
   */                                                                 
  if (bc->segment)                                                    
  {                                                                   
    sc = bc->segment;                                                 
    pd = &sc->page_descriptors[bc->page];                             
40006560:	c2 27 bf e8 	st  %g1, [ %fp + -24 ]                         
40006564:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_info (fd, " write:%02d-%03d-%03d: flag used",         
40006568:	90 10 00 1d 	mov  %i5, %o0                                  
4000656c:	98 10 00 01 	mov  %g1, %o4                                  
40006570:	c2 27 bf e4 	st  %g1, [ %fp + -28 ]                         
40006574:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006578:	7f ff fa 87 	call  40004f94 <rtems_fdisk_info>              
4000657c:	92 12 60 50 	or  %o1, 0x50, %o1	! 40032850 <__FUNCTION__.6501+0x7e8>
#endif                                                                
                                                                      
    /*                                                                
     * The page exists in flash so see if the page has been changed.  
     */                                                               
    if (rtems_fdisk_seg_verify_page (fd, sc->device, sc->segment,     
40006580:	c4 06 20 04 	ld  [ %i0 + 4 ], %g2                           
                             uint32_t               segment,          
                             uint32_t               page,             
                             const void*            buffer)           
{                                                                     
  return rtems_fdisk_seg_verify (fd, device, segment,                 
                                 page * fd->block_size, buffer, fd->block_size);
40006584:	ee 07 60 14 	ld  [ %i5 + 0x14 ], %l7                        
#endif                                                                
                                                                      
    /*                                                                
     * The page exists in flash so see if the page has been changed.  
     */                                                               
    if (rtems_fdisk_seg_verify_page (fd, sc->device, sc->segment,     
40006588:	d0 07 20 18 	ld  [ %i4 + 0x18 ], %o0                        
4000658c:	e8 07 20 08 	ld  [ %i4 + 8 ], %l4                           
                             uint32_t               device,           
                             uint32_t               segment,          
                             uint32_t               page,             
                             const void*            buffer)           
{                                                                     
  return rtems_fdisk_seg_verify (fd, device, segment,                 
40006590:	90 02 00 02 	add  %o0, %g2, %o0                             
40006594:	7f ff ef f6 	call  4000256c <.umul>                         
40006598:	92 10 00 17 	mov  %l7, %o1                                  
static const rtems_fdisk_segment_desc*                                
rtems_fdisk_seg_descriptor (const rtems_flashdisk* fd,                
                            uint32_t               device,            
                            uint32_t               segment)           
{                                                                     
  return fd->devices[device].segments[segment].descriptor;            
4000659c:	89 2d 20 04 	sll  %l4, 4, %g4                               
400065a0:	87 2d 20 02 	sll  %l4, 2, %g3                               
400065a4:	86 21 00 03 	sub  %g4, %g3, %g3                             
400065a8:	c8 07 60 2c 	ld  [ %i5 + 0x2c ], %g4                        
#endif                                                                
                                                                      
    /*                                                                
     * The page exists in flash so see if the page has been changed.  
     */                                                               
    if (rtems_fdisk_seg_verify_page (fd, sc->device, sc->segment,     
400065ac:	e6 07 20 0c 	ld  [ %i4 + 0xc ], %l3                         
static const rtems_fdisk_segment_desc*                                
rtems_fdisk_seg_descriptor (const rtems_flashdisk* fd,                
                            uint32_t               device,            
                            uint32_t               segment)           
{                                                                     
  return fd->devices[device].segments[segment].descriptor;            
400065b0:	9e 01 00 03 	add  %g4, %g3, %o7                             
400065b4:	c8 01 00 03 	ld  [ %g4 + %g3 ], %g4                         
400065b8:	9b 2c e0 06 	sll  %l3, 6, %o5                               
400065bc:	87 2c e0 04 	sll  %l3, 4, %g3                               
400065c0:	86 23 40 03 	sub  %o5, %g3, %g3                             
400065c4:	86 01 00 03 	add  %g4, %g3, %g3                             
400065c8:	c8 00 e0 04 	ld  [ %g3 + 4 ], %g4                           
                        uint32_t               size)                  
{                                                                     
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  sd  = rtems_fdisk_seg_descriptor (fd, device, segment);             
  ops = fd->devices[device].descriptor->flash_ops;                    
400065cc:	c6 03 e0 08 	ld  [ %o7 + 8 ], %g3                           
                             uint32_t               device,           
                             uint32_t               segment,          
                             uint32_t               page,             
                             const void*            buffer)           
{                                                                     
  return rtems_fdisk_seg_verify (fd, device, segment,                 
400065d0:	84 10 00 08 	mov  %o0, %g2                                  
                        uint32_t               size)                  
{                                                                     
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  sd  = rtems_fdisk_seg_descriptor (fd, device, segment);             
  ops = fd->devices[device].descriptor->flash_ops;                    
400065d4:	c6 00 e0 08 	ld  [ %g3 + 8 ], %g3                           
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, "  seg-verify: %02d-%03d: o=%08x s=%d",     
400065d8:	94 10 00 14 	mov  %l4, %o2                                  
400065dc:	98 10 00 02 	mov  %g2, %o4                                  
400065e0:	c4 3f bf d8 	std  %g2, [ %fp + -40 ]                        
400065e4:	96 10 00 13 	mov  %l3, %o3                                  
400065e8:	9a 10 00 17 	mov  %l7, %o5                                  
400065ec:	c8 27 bf d4 	st  %g4, [ %fp + -44 ]                         
400065f0:	90 10 00 1d 	mov  %i5, %o0                                  
400065f4:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
400065f8:	7f ff fa 46 	call  40004f10 <rtems_fdisk_printf>            
400065fc:	92 12 60 78 	or  %o1, 0x78, %o1	! 40032878 <__FUNCTION__.6501+0x810>
                      device, segment, offset, size);                 
#endif                                                                
  return ops->verify (sd, device, segment, offset, buffer, size);     
40006600:	c6 07 bf dc 	ld  [ %fp + -36 ], %g3                         
40006604:	c8 07 bf d4 	ld  [ %fp + -44 ], %g4                         
40006608:	c4 07 bf d8 	ld  [ %fp + -40 ], %g2                         
4000660c:	c6 00 e0 0c 	ld  [ %g3 + 0xc ], %g3                         
40006610:	92 10 00 14 	mov  %l4, %o1                                  
40006614:	90 10 00 04 	mov  %g4, %o0                                  
40006618:	94 10 00 13 	mov  %l3, %o2                                  
4000661c:	96 10 00 02 	mov  %g2, %o3                                  
40006620:	98 10 00 11 	mov  %l1, %o4                                  
40006624:	9f c0 c0 00 	call  %g3                                      
40006628:	9a 10 00 17 	mov  %l7, %o5                                  
#endif                                                                
                                                                      
    /*                                                                
     * The page exists in flash so see if the page has been changed.  
     */                                                               
    if (rtems_fdisk_seg_verify_page (fd, sc->device, sc->segment,     
4000662c:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
40006630:	80 a2 20 00 	cmp  %o0, 0                                    
40006634:	12 80 00 0c 	bne  40006664 <rtems_fdisk_ioctl+0x5a8>        
40006638:	e8 06 20 04 	ld  [ %i0 + 4 ], %l4                           
                                     bc->page + sc->pages_desc, buffer) == 0)
    {                                                                 
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "write-block:%d=>%02d-%03d-%03d: page verified",
4000663c:	d6 07 20 08 	ld  [ %i4 + 8 ], %o3                           
40006640:	d8 07 20 0c 	ld  [ %i4 + 0xc ], %o4                         
40006644:	90 10 00 1d 	mov  %i5, %o0                                  
40006648:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
4000664c:	94 10 00 19 	mov  %i1, %o2                                  
40006650:	92 12 60 a0 	or  %o1, 0xa0, %o1                             
40006654:	7f ff fa 50 	call  40004f94 <rtems_fdisk_info>              
40006658:	9a 10 00 14 	mov  %l4, %o5                                  
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
4000665c:	10 80 01 02 	b  40006a64 <rtems_fdisk_ioctl+0x9a8>          
40006660:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
   * Does the page exist in flash ?                                   
   */                                                                 
  if (bc->segment)                                                    
  {                                                                   
    sc = bc->segment;                                                 
    pd = &sc->page_descriptors[bc->page];                             
40006664:	c4 07 bf e8 	ld  [ %fp + -24 ], %g2                         
40006668:	83 28 60 03 	sll  %g1, 3, %g1                               
4000666c:	a6 00 80 01 	add  %g2, %g1, %l3                             
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
40006670:	c2 14 e0 02 	lduh  [ %l3 + 2 ], %g1                         
                                       uint32_t                     page,
                                       const rtems_fdisk_page_desc* page_desc)
{                                                                     
  uint32_t offset = ((page * sizeof (rtems_fdisk_page_desc)) +        
                     ((uint8_t*) &page_desc->flags) - ((uint8_t*) page_desc));
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
40006674:	c4 07 60 08 	ld  [ %i5 + 8 ], %g2                           
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
40006678:	82 08 7f fd 	and  %g1, -3, %g1                              
4000667c:	c2 34 e0 02 	sth  %g1, [ %l3 + 2 ]                          
                                       uint32_t                     page,
                                       const rtems_fdisk_page_desc* page_desc)
{                                                                     
  uint32_t offset = ((page * sizeof (rtems_fdisk_page_desc)) +        
                     ((uint8_t*) &page_desc->flags) - ((uint8_t*) page_desc));
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
40006680:	80 88 a0 08 	btst  8, %g2                                   
rtems_fdisk_seg_write_page_desc_flags (const rtems_flashdisk*       fd,
                                       rtems_fdisk_segment_ctl*     sc,
                                       uint32_t                     page,
                                       const rtems_fdisk_page_desc* page_desc)
{                                                                     
  uint32_t offset = ((page * sizeof (rtems_fdisk_page_desc)) +        
40006684:	83 2d 20 03 	sll  %l4, 3, %g1                               
                     ((uint8_t*) &page_desc->flags) - ((uint8_t*) page_desc));
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
40006688:	02 80 00 1e 	be  40006700 <rtems_fdisk_ioctl+0x644>         <== NEVER TAKEN
4000668c:	82 00 60 02 	add  %g1, 2, %g1                               
  {                                                                   
    uint16_t flash_flags;                                             
    int      ret;                                                     
    ret = rtems_fdisk_seg_read (fd, sc, offset,                       
40006690:	94 10 00 01 	mov  %g1, %o2                                  
40006694:	c2 27 bf e4 	st  %g1, [ %fp + -28 ]                         
40006698:	90 10 00 1d 	mov  %i5, %o0                                  
4000669c:	92 10 00 1c 	mov  %i4, %o1                                  
400066a0:	96 07 bf f8 	add  %fp, -8, %o3                              
400066a4:	7f ff fa f6 	call  4000527c <rtems_fdisk_seg_read>          
400066a8:	98 10 20 02 	mov  2, %o4                                    
                                &flash_flags, sizeof (flash_flags));  
    if (ret)                                                          
400066ac:	ae 92 20 00 	orcc  %o0, 0, %l7                              
400066b0:	12 80 00 12 	bne  400066f8 <rtems_fdisk_ioctl+0x63c>        <== NEVER TAKEN
400066b4:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
      return ret;                                                     
    if ((flash_flags & page_desc->flags) != page_desc->flags)         
400066b8:	c4 14 e0 02 	lduh  [ %l3 + 2 ], %g2                         
400066bc:	d8 17 bf f8 	lduh  [ %fp + -8 ], %o4                        
400066c0:	86 08 80 0c 	and  %g2, %o4, %g3                             
400066c4:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
400066c8:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
400066cc:	80 a0 c0 02 	cmp  %g3, %g2                                  
400066d0:	02 80 00 0c 	be  40006700 <rtems_fdisk_ioctl+0x644>         <== ALWAYS TAKEN
400066d4:	9b 30 a0 10 	srl  %g2, 0x10, %o5                            
    {                                                                 
      rtems_fdisk_error ("  seg-write-page-flags: %02d-%03d-%03d: "   
400066d8:	d2 07 20 08 	ld  [ %i4 + 8 ], %o1                           <== NOT EXECUTED
400066dc:	d4 07 20 0c 	ld  [ %i4 + 0xc ], %o2                         <== NOT EXECUTED
400066e0:	99 2b 20 10 	sll  %o4, 0x10, %o4                            <== NOT EXECUTED
400066e4:	11 10 00 ca 	sethi  %hi(0x40032800), %o0                    <== NOT EXECUTED
400066e8:	96 10 00 14 	mov  %l4, %o3                                  <== NOT EXECUTED
400066ec:	90 12 20 d0 	or  %o0, 0xd0, %o0                             <== NOT EXECUTED
400066f0:	7f ff fa 6b 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
400066f4:	99 33 20 10 	srl  %o4, 0x10, %o4                            <== NOT EXECUTED
                     ((uint8_t*) &page_desc->flags) - ((uint8_t*) page_desc));
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
  {                                                                   
    uint16_t flash_flags;                                             
    int      ret;                                                     
    ret = rtems_fdisk_seg_read (fd, sc, offset,                       
400066f8:	10 80 00 09 	b  4000671c <rtems_fdisk_ioctl+0x660>          <== NOT EXECUTED
400066fc:	a6 10 00 17 	mov  %l7, %l3                                  <== NOT EXECUTED
                         sc->device, sc->segment, page,               
                         flash_flags, page_desc->flags);              
      return ret;                                                     
    }                                                                 
  }                                                                   
  return rtems_fdisk_seg_write (fd, sc, offset,                       
40006700:	96 04 e0 02 	add  %l3, 2, %o3                               
40006704:	90 10 00 1d 	mov  %i5, %o0                                  
40006708:	92 10 00 1c 	mov  %i4, %o1                                  
4000670c:	94 10 00 01 	mov  %g1, %o2                                  
40006710:	7f ff fa fd 	call  40005304 <rtems_fdisk_seg_write>         
40006714:	98 10 20 02 	mov  2, %o4                                    
40006718:	a6 10 00 08 	mov  %o0, %l3                                  
                                                                      
    rtems_fdisk_page_desc_set_flags (pd, RTEMS_FDISK_PAGE_USED);      
                                                                      
    ret = rtems_fdisk_seg_write_page_desc_flags (fd, sc, bc->page, pd);
                                                                      
    if (ret)                                                          
4000671c:	80 a4 e0 00 	cmp  %l3, 0                                    
40006720:	22 80 00 13 	be,a   4000676c <rtems_fdisk_ioctl+0x6b0>      <== ALWAYS TAKEN
40006724:	c2 07 20 1c 	ld  [ %i4 + 0x1c ], %g1                        
    {                                                                 
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, " write:%02d-%03d-%03d: "      \          
40006728:	d4 07 20 08 	ld  [ %i4 + 8 ], %o2                           <== NOT EXECUTED
4000672c:	ee 07 20 0c 	ld  [ %i4 + 0xc ], %l7                         <== NOT EXECUTED
40006730:	e8 06 20 04 	ld  [ %i0 + 4 ], %l4                           <== NOT EXECUTED
40006734:	90 10 00 13 	mov  %l3, %o0                                  <== NOT EXECUTED
40006738:	40 00 73 15 	call  4002338c <strerror>                      <== NOT EXECUTED
4000673c:	d4 27 bf d0 	st  %o2, [ %fp + -48 ]                         <== NOT EXECUTED
40006740:	d4 07 bf d0 	ld  [ %fp + -48 ], %o2                         <== NOT EXECUTED
40006744:	9a 10 00 08 	mov  %o0, %o5                                  <== NOT EXECUTED
40006748:	e6 23 a0 5c 	st  %l3, [ %sp + 0x5c ]                        <== NOT EXECUTED
4000674c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40006750:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    <== NOT EXECUTED
40006754:	96 10 00 17 	mov  %l7, %o3                                  <== NOT EXECUTED
40006758:	92 12 61 20 	or  %o1, 0x120, %o1                            <== NOT EXECUTED
4000675c:	7f ff fa 0e 	call  40004f94 <rtems_fdisk_info>              <== NOT EXECUTED
40006760:	98 10 00 14 	mov  %l4, %o4                                  <== NOT EXECUTED
    /*                                                                
     * If possible reuse this segment. This will mean the segment     
     * needs to be removed from the available list and placed         
     * back if space is still available.                              
     */                                                               
    rtems_fdisk_queue_segment (fd, sc);                               
40006764:	10 80 00 08 	b  40006784 <rtems_fdisk_ioctl+0x6c8>          <== NOT EXECUTED
40006768:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                        strerror (ret), ret);                         
#endif                                                                
    }                                                                 
    else                                                              
    {                                                                 
      sc->pages_active--;                                             
4000676c:	82 00 7f ff 	add  %g1, -1, %g1                              
40006770:	c2 27 20 1c 	st  %g1, [ %i4 + 0x1c ]                        
      sc->pages_used++;                                               
40006774:	c2 07 20 20 	ld  [ %i4 + 0x20 ], %g1                        
40006778:	82 00 60 01 	inc  %g1                                       
4000677c:	c2 27 20 20 	st  %g1, [ %i4 + 0x20 ]                        
    /*                                                                
     * If possible reuse this segment. This will mean the segment     
     * needs to be removed from the available list and placed         
     * back if space is still available.                              
     */                                                               
    rtems_fdisk_queue_segment (fd, sc);                               
40006780:	90 10 00 1d 	mov  %i5, %o0                                  
40006784:	7f ff fb 5d 	call  400054f8 <rtems_fdisk_queue_segment>     
40006788:	92 10 00 1c 	mov  %i4, %o1                                  
    /*                                                                
     * If no background compacting then compact in the forground.     
     * If we compact we ignore the error as there is little we        
     * can do from here. The write may will work.                     
     */                                                               
    if ((fd->flags & RTEMS_FDISK_BACKGROUND_COMPACT) == 0)            
4000678c:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
40006790:	80 88 60 02 	btst  2, %g1                                   
40006794:	12 80 00 04 	bne  400067a4 <rtems_fdisk_ioctl+0x6e8>        <== NEVER TAKEN
40006798:	01 00 00 00 	nop                                            
      rtems_fdisk_compact (fd);                                       
4000679c:	7f ff fd 95 	call  40005df0 <rtems_fdisk_compact>           
400067a0:	90 10 00 1d 	mov  %i5, %o0                                  
  /*                                                                  
   * Is it time to compact the disk ?                                 
   *                                                                  
   * We override the background compaction configruation.             
   */                                                                 
  if (rtems_fdisk_segment_count_queue (&fd->available) <=             
400067a4:	7f ff fa 5c 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1>
400067a8:	d0 07 60 34 	ld  [ %i5 + 0x34 ], %o0                        
400067ac:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
400067b0:	80 a2 00 01 	cmp  %o0, %g1                                  
400067b4:	18 80 00 05 	bgu  400067c8 <rtems_fdisk_ioctl+0x70c>        
400067b8:	b8 07 60 34 	add  %i5, 0x34, %i4                            
      fd->avail_compact_segs)                                         
    rtems_fdisk_compact (fd);                                         
400067bc:	7f ff fd 8d 	call  40005df0 <rtems_fdisk_compact>           
400067c0:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  /*                                                                  
   * Get the next avaliable segment.                                  
   */                                                                 
  sc = rtems_fdisk_segment_queue_pop_head (&fd->available);           
400067c4:	b8 07 60 34 	add  %i5, 0x34, %i4                            
400067c8:	7f ff f9 5a 	call  40004d30 <rtems_fdisk_segment_queue_pop_head>
400067cc:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
  /*                                                                  
   * Is the flash disk full ?                                         
   */                                                                 
  if (!sc)                                                            
400067d0:	a6 92 20 00 	orcc  %o0, 0, %l3                              
400067d4:	32 80 00 13 	bne,a   40006820 <rtems_fdisk_ioctl+0x764>     <== ALWAYS TAKEN
400067d8:	c2 07 60 6c 	ld  [ %i5 + 0x6c ], %g1                        
  {                                                                   
    /*                                                                
     * If compacting is configured for the background do it now       
     * to see if we can get some space back.                          
     */                                                               
    if ((fd->flags & RTEMS_FDISK_BACKGROUND_COMPACT))                 
400067dc:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           <== NOT EXECUTED
400067e0:	80 88 60 02 	btst  2, %g1                                   <== NOT EXECUTED
400067e4:	02 80 00 04 	be  400067f4 <rtems_fdisk_ioctl+0x738>         <== NOT EXECUTED
400067e8:	01 00 00 00 	nop                                            <== NOT EXECUTED
      rtems_fdisk_compact (fd);                                       
400067ec:	7f ff fd 81 	call  40005df0 <rtems_fdisk_compact>           <== NOT EXECUTED
400067f0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                                                                      
    /*                                                                
     * Try again for some free space.                                 
     */                                                               
    sc = rtems_fdisk_segment_queue_pop_head (&fd->available);         
400067f4:	7f ff f9 4f 	call  40004d30 <rtems_fdisk_segment_queue_pop_head><== NOT EXECUTED
400067f8:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
                                                                      
    if (!sc)                                                          
400067fc:	a6 92 20 00 	orcc  %o0, 0, %l3                              <== NOT EXECUTED
40006800:	32 80 00 08 	bne,a   40006820 <rtems_fdisk_ioctl+0x764>     <== NOT EXECUTED
40006804:	c2 07 60 6c 	ld  [ %i5 + 0x6c ], %g1                        <== NOT EXECUTED
    {                                                                 
      rtems_fdisk_error ("write-block: no available pages");          
40006808:	11 10 00 ca 	sethi  %hi(0x40032800), %o0                    <== NOT EXECUTED
      return ENOSPC;                                                  
4000680c:	b8 10 20 1c 	mov  0x1c, %i4                                 <== NOT EXECUTED
     */                                                               
    sc = rtems_fdisk_segment_queue_pop_head (&fd->available);         
                                                                      
    if (!sc)                                                          
    {                                                                 
      rtems_fdisk_error ("write-block: no available pages");          
40006810:	7f ff fa 23 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40006814:	90 12 21 60 	or  %o0, 0x160, %o0                            <== NOT EXECUTED
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
40006818:	10 80 00 98 	b  40006a78 <rtems_fdisk_ioctl+0x9bc>          <== NOT EXECUTED
4000681c:	c4 07 bf f4 	ld  [ %fp + -12 ], %g2                         <== NOT EXECUTED
      return ENOSPC;                                                  
    }                                                                 
  }                                                                   
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  if (fd->info_level >= 3)                                            
40006820:	80 a0 60 02 	cmp  %g1, 2                                    
40006824:	28 80 00 0f 	bleu,a   40006860 <rtems_fdisk_ioctl+0x7a4>    <== ALWAYS TAKEN
40006828:	c2 04 e0 10 	ld  [ %l3 + 0x10 ], %g1                        
  {                                                                   
    char queues[5];                                                   
    rtems_fdisk_queue_status (fd, sc, queues);                        
4000682c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40006830:	92 10 00 13 	mov  %l3, %o1                                  <== NOT EXECUTED
40006834:	7f ff fd f8 	call  40006014 <rtems_fdisk_queue_status>      <== NOT EXECUTED
40006838:	94 07 bf f8 	add  %fp, -8, %o2                              <== NOT EXECUTED
    rtems_fdisk_info (fd, " write:%d=>%02d-%03d: queue check: %s",    
4000683c:	d6 04 e0 08 	ld  [ %l3 + 8 ], %o3                           <== NOT EXECUTED
40006840:	d8 04 e0 0c 	ld  [ %l3 + 0xc ], %o4                         <== NOT EXECUTED
40006844:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    <== NOT EXECUTED
40006848:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4000684c:	92 12 61 80 	or  %o1, 0x180, %o1                            <== NOT EXECUTED
40006850:	94 10 00 19 	mov  %i1, %o2                                  <== NOT EXECUTED
40006854:	7f ff f9 d0 	call  40004f94 <rtems_fdisk_info>              <== NOT EXECUTED
40006858:	9a 07 bf f8 	add  %fp, -8, %o5                              <== NOT EXECUTED
                                                                      
  /*                                                                  
   * Find the next avaliable page in the segment.                     
   */                                                                 
                                                                      
  pd = sc->page_descriptors;                                          
4000685c:	c2 04 e0 10 	ld  [ %l3 + 0x10 ], %g1                        <== NOT EXECUTED
                                                                      
  for (page = 0; page < sc->pages; page++, pd++)                      
40006860:	f8 04 e0 14 	ld  [ %l3 + 0x14 ], %i4                        
40006864:	a8 10 20 00 	clr  %l4                                       
40006868:	af 2d 20 03 	sll  %l4, 3, %l7                               
4000686c:	80 a5 00 1c 	cmp  %l4, %i4                                  
40006870:	02 80 00 6d 	be  40006a24 <rtems_fdisk_ioctl+0x968>         <== NEVER TAKEN
40006874:	ae 00 40 17 	add  %g1, %l7, %l7                             
  {                                                                   
    if (rtems_fdisk_page_desc_erased (pd))                            
40006878:	c2 27 bf e4 	st  %g1, [ %fp + -28 ]                         
4000687c:	7f ff f9 81 	call  40004e80 <rtems_fdisk_page_desc_erased>  
40006880:	90 10 00 17 	mov  %l7, %o0                                  
40006884:	80 a2 20 00 	cmp  %o0, 0                                    
40006888:	02 80 00 65 	be  40006a1c <rtems_fdisk_ioctl+0x960>         
4000688c:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
    {                                                                 
      pd->crc   = rtems_fdisk_page_checksum (buffer, fd->block_size); 
40006890:	d2 07 60 14 	ld  [ %i5 + 0x14 ], %o1                        
40006894:	7f ff f9 8d 	call  40004ec8 <rtems_fdisk_page_checksum>     
40006898:	90 10 00 11 	mov  %l1, %o0                                  
      pd->block = block;                                              
4000689c:	f2 25 e0 04 	st  %i1, [ %l7 + 4 ]                           
                                                                      
  for (page = 0; page < sc->pages; page++, pd++)                      
  {                                                                   
    if (rtems_fdisk_page_desc_erased (pd))                            
    {                                                                 
      pd->crc   = rtems_fdisk_page_checksum (buffer, fd->block_size); 
400068a0:	d0 35 c0 00 	sth  %o0, [ %l7 ]                              
      pd->block = block;                                              
                                                                      
      bc->segment = sc;                                               
400068a4:	e6 25 80 15 	st  %l3, [ %l6 + %l5 ]                         
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
400068a8:	c2 15 e0 02 	lduh  [ %l7 + 2 ], %g1                         
    {                                                                 
      pd->crc   = rtems_fdisk_page_checksum (buffer, fd->block_size); 
      pd->block = block;                                              
                                                                      
      bc->segment = sc;                                               
      bc->page    = page;                                             
400068ac:	e8 26 20 04 	st  %l4, [ %i0 + 4 ]                           
                                                                      
      rtems_fdisk_page_desc_set_flags (pd, RTEMS_FDISK_PAGE_ACTIVE);  
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, " write:%d=>%02d-%03d-%03d: write: " \    
400068b0:	c4 04 c0 00 	ld  [ %l3 ], %g2                               
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
400068b4:	82 08 7f fe 	and  %g1, -2, %g1                              
400068b8:	c2 35 e0 02 	sth  %g1, [ %l7 + 2 ]                          
      bc->page    = page;                                             
                                                                      
      rtems_fdisk_page_desc_set_flags (pd, RTEMS_FDISK_PAGE_ACTIVE);  
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, " write:%d=>%02d-%03d-%03d: write: " \    
400068bc:	d6 04 e0 08 	ld  [ %l3 + 8 ], %o3                           
400068c0:	d8 04 e0 0c 	ld  [ %l3 + 0xc ], %o4                         
400068c4:	de 04 e0 1c 	ld  [ %l3 + 0x1c ], %o7                        
400068c8:	c8 04 e0 20 	ld  [ %l3 + 0x20 ], %g4                        
400068cc:	80 a0 a0 00 	cmp  %g2, 0                                    
400068d0:	02 80 00 05 	be  400068e4 <rtems_fdisk_ioctl+0x828>         <== ALWAYS TAKEN
400068d4:	c6 04 e0 24 	ld  [ %l3 + 0x24 ], %g3                        
400068d8:	05 10 00 c8 	sethi  %hi(0x40032000), %g2                    <== NOT EXECUTED
400068dc:	10 80 00 04 	b  400068ec <rtems_fdisk_ioctl+0x830>          <== NOT EXECUTED
400068e0:	84 10 a2 a8 	or  %g2, 0x2a8, %g2	! 400322a8 <__FUNCTION__.6501+0x240><== NOT EXECUTED
400068e4:	05 10 00 c8 	sethi  %hi(0x40032000), %g2                    
400068e8:	84 10 a2 b0 	or  %g2, 0x2b0, %g2	! 400322b0 <__FUNCTION__.6501+0x248>
400068ec:	83 28 60 10 	sll  %g1, 0x10, %g1                            
400068f0:	83 30 60 10 	srl  %g1, 0x10, %g1                            
400068f4:	f8 23 a0 5c 	st  %i4, [ %sp + 0x5c ]                        
400068f8:	de 23 a0 60 	st  %o7, [ %sp + 0x60 ]                        
400068fc:	c8 23 a0 64 	st  %g4, [ %sp + 0x64 ]                        
40006900:	c6 23 a0 68 	st  %g3, [ %sp + 0x68 ]                        
40006904:	c4 23 a0 6c 	st  %g2, [ %sp + 0x6c ]                        
40006908:	c2 23 a0 70 	st  %g1, [ %sp + 0x70 ]                        
4000690c:	d0 23 a0 74 	st  %o0, [ %sp + 0x74 ]                        
40006910:	94 10 00 19 	mov  %i1, %o2                                  
40006914:	9a 10 00 14 	mov  %l4, %o5                                  
40006918:	f2 23 a0 78 	st  %i1, [ %sp + 0x78 ]                        
4000691c:	90 10 00 1d 	mov  %i5, %o0                                  
40006920:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006924:	7f ff f9 9c 	call  40004f94 <rtems_fdisk_info>              
40006928:	92 12 61 a8 	or  %o1, 0x1a8, %o1	! 400329a8 <__FUNCTION__.6501+0x940>
                                                                      
      /*                                                              
       * We use the segment page offset not the page number used in the
       * driver. This skips the page descriptors.                     
       */                                                             
      ret = rtems_fdisk_seg_write_page (fd, sc, page + sc->pages_desc, buffer);
4000692c:	d4 04 e0 18 	ld  [ %l3 + 0x18 ], %o2                        
40006930:	90 10 00 1d 	mov  %i5, %o0                                  
40006934:	92 10 00 13 	mov  %l3, %o1                                  
40006938:	94 05 00 0a 	add  %l4, %o2, %o2                             
4000693c:	7f ff fc 28 	call  400059dc <rtems_fdisk_seg_write_page>    
40006940:	96 10 00 11 	mov  %l1, %o3                                  
      if (ret)                                                        
40006944:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40006948:	22 80 00 0e 	be,a   40006980 <rtems_fdisk_ioctl+0x8c4>      <== ALWAYS TAKEN
4000694c:	90 10 00 1d 	mov  %i5, %o0                                  
      {                                                               
#if RTEMS_FDISK_TRACE                                                 
        rtems_fdisk_info (fd, "write-block:%02d-%03d-%03d: write page failed: " \
40006950:	f0 04 e0 08 	ld  [ %l3 + 8 ], %i0                           <== NOT EXECUTED
40006954:	40 00 72 8e 	call  4002338c <strerror>                      <== NOT EXECUTED
40006958:	f2 04 e0 0c 	ld  [ %l3 + 0xc ], %i1                         <== NOT EXECUTED
4000695c:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    <== NOT EXECUTED
40006960:	9a 10 00 08 	mov  %o0, %o5                                  <== NOT EXECUTED
40006964:	f8 23 a0 5c 	st  %i4, [ %sp + 0x5c ]                        <== NOT EXECUTED
40006968:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4000696c:	92 12 61 f8 	or  %o1, 0x1f8, %o1                            <== NOT EXECUTED
40006970:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
40006974:	96 10 00 19 	mov  %i1, %o3                                  <== NOT EXECUTED
40006978:	10 80 00 15 	b  400069cc <rtems_fdisk_ioctl+0x910>          <== NOT EXECUTED
4000697c:	98 10 00 14 	mov  %l4, %o4                                  <== NOT EXECUTED
                          strerror (ret), ret);                       
#endif                                                                
      }                                                               
      else                                                            
      {                                                               
        ret = rtems_fdisk_seg_write_page_desc (fd, sc, page, pd);     
40006980:	92 10 00 13 	mov  %l3, %o1                                  
40006984:	94 10 00 14 	mov  %l4, %o2                                  
40006988:	7f ff fa 85 	call  4000539c <rtems_fdisk_seg_write_page_desc>
4000698c:	96 10 00 17 	mov  %l7, %o3                                  
        if (ret)                                                      
40006990:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40006994:	22 80 00 12 	be,a   400069dc <rtems_fdisk_ioctl+0x920>      <== ALWAYS TAKEN
40006998:	c2 04 e0 1c 	ld  [ %l3 + 0x1c ], %g1                        
        {                                                             
#if RTEMS_FDISK_TRACE                                                 
          rtems_fdisk_info (fd, "write-block:%02d-%03d-%03d: "  \     
4000699c:	ea 04 e0 08 	ld  [ %l3 + 8 ], %l5                           <== NOT EXECUTED
400069a0:	e8 04 e0 0c 	ld  [ %l3 + 0xc ], %l4                         <== NOT EXECUTED
400069a4:	40 00 72 7a 	call  4002338c <strerror>                      <== NOT EXECUTED
400069a8:	f2 06 20 04 	ld  [ %i0 + 4 ], %i1                           <== NOT EXECUTED
400069ac:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    <== NOT EXECUTED
400069b0:	9a 10 00 08 	mov  %o0, %o5                                  <== NOT EXECUTED
400069b4:	f8 23 a0 5c 	st  %i4, [ %sp + 0x5c ]                        <== NOT EXECUTED
400069b8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
400069bc:	92 12 62 30 	or  %o1, 0x230, %o1                            <== NOT EXECUTED
400069c0:	94 10 00 15 	mov  %l5, %o2                                  <== NOT EXECUTED
400069c4:	96 10 00 14 	mov  %l4, %o3                                  <== NOT EXECUTED
400069c8:	98 10 00 19 	mov  %i1, %o4                                  <== NOT EXECUTED
400069cc:	7f ff f9 72 	call  40004f94 <rtems_fdisk_info>              <== NOT EXECUTED
400069d0:	01 00 00 00 	nop                                            <== NOT EXECUTED
        {                                                             
          sc->pages_active++;                                         
        }                                                             
      }                                                               
                                                                      
      rtems_fdisk_queue_segment (fd, sc);                             
400069d4:	10 80 00 05 	b  400069e8 <rtems_fdisk_ioctl+0x92c>          <== NOT EXECUTED
400069d8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                            strerror (ret), ret);                     
#endif                                                                
        }                                                             
        else                                                          
        {                                                             
          sc->pages_active++;                                         
400069dc:	82 00 60 01 	inc  %g1                                       
400069e0:	c2 24 e0 1c 	st  %g1, [ %l3 + 0x1c ]                        
        }                                                             
      }                                                               
                                                                      
      rtems_fdisk_queue_segment (fd, sc);                             
400069e4:	90 10 00 1d 	mov  %i5, %o0                                  
400069e8:	7f ff fa c4 	call  400054f8 <rtems_fdisk_queue_segment>     
400069ec:	92 10 00 13 	mov  %l3, %o1                                  
static bool                                                           
rtems_fdisk_is_erased_blocks_starvation (rtems_flashdisk* fd)         
{                                                                     
  bool starvation = fd->erased_blocks < fd->starvation_threshold;     
                                                                      
  if (starvation)                                                     
400069f0:	c4 07 60 28 	ld  [ %i5 + 0x28 ], %g2                        
400069f4:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
400069f8:	80 a0 80 01 	cmp  %g2, %g1                                  
400069fc:	1a 80 00 16 	bcc  40006a54 <rtems_fdisk_ioctl+0x998>        
40006a00:	90 10 00 1d 	mov  %i5, %o0                                  
    fd->starvations++;                                                
40006a04:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
40006a08:	82 00 60 01 	inc  %g1                                       
      }                                                               
                                                                      
      rtems_fdisk_queue_segment (fd, sc);                             
                                                                      
      if (rtems_fdisk_is_erased_blocks_starvation (fd))               
        rtems_fdisk_compact (fd);                                     
40006a0c:	7f ff fc f9 	call  40005df0 <rtems_fdisk_compact>           
40006a10:	c2 27 60 70 	st  %g1, [ %i5 + 0x70 ]                        
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
    {                                                                 
      ret = rtems_fdisk_write_block (fd, sg->block + b, data);        
      if (ret)                                                        
40006a14:	10 80 00 11 	b  40006a58 <rtems_fdisk_ioctl+0x99c>          
40006a18:	80 a7 20 00 	cmp  %i4, 0                                    
   * Find the next avaliable page in the segment.                     
   */                                                                 
                                                                      
  pd = sc->page_descriptors;                                          
                                                                      
  for (page = 0; page < sc->pages; page++, pd++)                      
40006a1c:	10 bf ff 93 	b  40006868 <rtems_fdisk_ioctl+0x7ac>          
40006a20:	a8 05 20 01 	inc  %l4                                       
                                                                      
      return ret;                                                     
    }                                                                 
  }                                                                   
                                                                      
  rtems_fdisk_error ("write-block: no erased page descs in segment: %d-%d",
40006a24:	d2 04 e0 08 	ld  [ %l3 + 8 ], %o1                           <== NOT EXECUTED
40006a28:	d4 04 e0 0c 	ld  [ %l3 + 0xc ], %o2                         <== NOT EXECUTED
40006a2c:	11 10 00 ca 	sethi  %hi(0x40032800), %o0                    <== NOT EXECUTED
40006a30:	7f ff f9 9b 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40006a34:	90 12 22 70 	or  %o0, 0x270, %o0	! 40032a70 <__FUNCTION__.6501+0xa08><== NOT EXECUTED
                     sc->device, sc->segment);                        
                                                                      
  sc->failed = true;                                                  
40006a38:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
  rtems_fdisk_queue_segment (fd, sc);                                 
40006a3c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  rtems_fdisk_error ("write-block: no erased page descs in segment: %d-%d",
                     sc->device, sc->segment);                        
                                                                      
  sc->failed = true;                                                  
40006a40:	c2 24 e0 28 	st  %g1, [ %l3 + 0x28 ]                        <== NOT EXECUTED
  rtems_fdisk_queue_segment (fd, sc);                                 
40006a44:	7f ff fa ad 	call  400054f8 <rtems_fdisk_queue_segment>     <== NOT EXECUTED
40006a48:	92 10 00 13 	mov  %l3, %o1                                  <== NOT EXECUTED
                                                                      
  return EIO;                                                         
40006a4c:	10 80 00 0a 	b  40006a74 <rtems_fdisk_ioctl+0x9b8>          <== NOT EXECUTED
40006a50:	b8 10 20 05 	mov  5, %i4                                    <== NOT EXECUTED
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
    {                                                                 
      ret = rtems_fdisk_write_block (fd, sg->block + b, data);        
      if (ret)                                                        
40006a54:	80 a7 20 00 	cmp  %i4, 0                                    
40006a58:	12 80 00 08 	bne  40006a78 <rtems_fdisk_ioctl+0x9bc>        <== NEVER TAKEN
40006a5c:	c4 07 bf f4 	ld  [ %fp + -12 ], %g2                         
    uint8_t* data;                                                    
    uint32_t fb;                                                      
    uint32_t b;                                                       
    fb = sg->length / fd->block_size;                                 
    data = sg->buffer;                                                
    for (b = 0; b < fb; b++, data += fd->block_size)                  
40006a60:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
40006a64:	a4 04 a0 01 	inc  %l2                                       
40006a68:	10 bf fe a0 	b  400064e8 <rtems_fdisk_ioctl+0x42c>          
40006a6c:	a2 04 40 01 	add  %l1, %g1, %l1                             
40006a70:	b8 10 20 00 	clr  %i4                                       
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
40006a74:	c4 07 bf f4 	ld  [ %fp + -12 ], %g2                         
40006a78:	a0 04 20 10 	add  %l0, 0x10, %l0                            
40006a7c:	84 00 a0 01 	inc  %g2                                       
40006a80:	80 a7 20 00 	cmp  %i4, 0                                    
40006a84:	02 bf fe 8e 	be  400064bc <rtems_fdisk_ioctl+0x400>         <== ALWAYS TAKEN
40006a88:	c4 27 bf f4 	st  %g2, [ %fp + -12 ]                         
40006a8c:	92 10 20 1b 	mov  0x1b, %o1                                 <== NOT EXECUTED
40006a90:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
40006a94:	9f c0 40 00 	call  %g1                                      
40006a98:	90 10 00 1a 	mov  %i2, %o0                                  
            case RTEMS_BLKDEV_REQ_READ:                               
              errno = rtems_fdisk_read (&rtems_flashdisks[minor], r); 
              break;                                                  
                                                                      
            case RTEMS_BLKDEV_REQ_WRITE:                              
              errno = rtems_fdisk_write (&rtems_flashdisks[minor], r);
40006a9c:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
              break;                                                  
40006aa0:	10 80 01 b4 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         
40006aa4:	c0 20 40 00 	clr  [ %g1 ]                                   
                                                                      
            default:                                                  
              errno = EINVAL;                                         
40006aa8:	40 00 68 fd 	call  40020e9c <__errno>                       <== NOT EXECUTED
40006aac:	01 00 00 00 	nop                                            <== NOT EXECUTED
40006ab0:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
              break;                                                  
40006ab4:	10 80 01 af 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         <== NOT EXECUTED
40006ab8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
  for (device = 0; device < fd->device_count; device++)               
  {                                                                   
    int ret;                                                          
                                                                      
#if RTEMS_FDISK_TRACE                                                 
    rtems_fdisk_info (fd, " erase-flash:%02d", device);               
40006abc:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
40006ac0:	7f ff f9 35 	call  40004f94 <rtems_fdisk_info>              <== NOT EXECUTED
40006ac4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_device_erase (const rtems_flashdisk* fd, uint32_t device) 
{                                                                     
  const rtems_fdisk_driver_handlers* ops;                             
  ops = fd->devices[device].descriptor->flash_ops;                    
40006ac8:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        <== NOT EXECUTED
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, " device-erase: %02d", device);             
40006acc:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_device_erase (const rtems_flashdisk* fd, uint32_t device) 
{                                                                     
  const rtems_fdisk_driver_handlers* ops;                             
  ops = fd->devices[device].descriptor->flash_ops;                    
40006ad0:	82 00 40 1a 	add  %g1, %i2, %g1                             <== NOT EXECUTED
40006ad4:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           <== NOT EXECUTED
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, " device-erase: %02d", device);             
40006ad8:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_device_erase (const rtems_flashdisk* fd, uint32_t device) 
{                                                                     
  const rtems_fdisk_driver_handlers* ops;                             
  ops = fd->devices[device].descriptor->flash_ops;                    
40006adc:	e2 00 60 08 	ld  [ %g1 + 8 ], %l1                           <== NOT EXECUTED
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, " device-erase: %02d", device);             
40006ae0:	7f ff f9 0c 	call  40004f10 <rtems_fdisk_printf>            <== NOT EXECUTED
40006ae4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
#endif                                                                
  return ops->erase_device (fd->devices[device].descriptor, device);  
40006ae8:	c4 07 60 2c 	ld  [ %i5 + 0x2c ], %g2                        <== NOT EXECUTED
40006aec:	c2 04 60 14 	ld  [ %l1 + 0x14 ], %g1                        <== NOT EXECUTED
40006af0:	84 00 80 1a 	add  %g2, %i2, %g2                             <== NOT EXECUTED
40006af4:	d0 00 a0 08 	ld  [ %g2 + 8 ], %o0                           <== NOT EXECUTED
40006af8:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
40006afc:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40006b00:	b4 06 a0 0c 	add  %i2, 0xc, %i2                             <== NOT EXECUTED
    rtems_fdisk_info (fd, " erase-flash:%02d", device);               
#endif                                                                
                                                                      
    ret = rtems_fdisk_device_erase (fd, device);                      
                                                                      
    if (ret != 0)                                                     
40006b04:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40006b08:	12 80 00 17 	bne  40006b64 <rtems_fdisk_ioctl+0xaa8>        <== NOT EXECUTED
40006b0c:	b8 07 20 01 	inc  %i4                                       <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_erase_flash (const rtems_flashdisk* fd)                   
{                                                                     
  uint32_t device;                                                    
  for (device = 0; device < fd->device_count; device++)               
40006b10:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        <== NOT EXECUTED
40006b14:	80 a7 00 01 	cmp  %i4, %g1                                  <== NOT EXECUTED
40006b18:	0a bf ff e9 	bcs  40006abc <rtems_fdisk_ioctl+0xa00>        <== NOT EXECUTED
40006b1c:	92 10 00 10 	mov  %l0, %o1                                  <== NOT EXECUTED
40006b20:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
40006b24:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
                                                                      
  ret = rtems_fdisk_erase_flash (fd);                                 
                                                                      
  if (ret == 0)                                                       
  {                                                                   
    for (device = 0; device < fd->device_count; device++)             
40006b28:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        <== NOT EXECUTED
40006b2c:	80 a7 00 01 	cmp  %i4, %g1                                  <== NOT EXECUTED
40006b30:	3a 80 00 0d 	bcc,a   40006b64 <rtems_fdisk_ioctl+0xaa8>     <== NOT EXECUTED
40006b34:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
    {                                                                 
      if (!fd->devices[device].segments)                              
40006b38:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        <== NOT EXECUTED
40006b3c:	c2 00 40 1a 	ld  [ %g1 + %i2 ], %g1                         <== NOT EXECUTED
40006b40:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40006b44:	02 80 00 08 	be  40006b64 <rtems_fdisk_ioctl+0xaa8>         <== NOT EXECUTED
40006b48:	90 10 20 0c 	mov  0xc, %o0                                  <== NOT EXECUTED
        return ENOMEM;                                                
                                                                      
      ret = rtems_fdisk_recover_block_mappings (fd);                  
40006b4c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40006b50:	7f ff fa ca 	call  40005678 <rtems_fdisk_recover_block_mappings><== NOT EXECUTED
40006b54:	b4 06 a0 0c 	add  %i2, 0xc, %i2                             <== NOT EXECUTED
      if (ret)                                                        
40006b58:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40006b5c:	02 bf ff f3 	be  40006b28 <rtems_fdisk_ioctl+0xa6c>         <== NOT EXECUTED
40006b60:	b8 07 20 01 	inc  %i4                                       <== NOT EXECUTED
        }                                                             
        break;                                                        
                                                                      
      case RTEMS_FDISK_IOCTL_ERASE_DISK:                              
        errno = rtems_fdisk_erase_disk (&rtems_flashdisks[minor]);    
        break;                                                        
40006b64:	10 80 01 83 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         <== NOT EXECUTED
40006b68:	d0 26 40 00 	st  %o0, [ %i1 ]                               <== NOT EXECUTED
                                                                      
      case RTEMS_FDISK_IOCTL_COMPACT:                                 
        errno = rtems_fdisk_compact (&rtems_flashdisks[minor]);       
40006b6c:	40 00 68 cc 	call  40020e9c <__errno>                       <== NOT EXECUTED
40006b70:	01 00 00 00 	nop                                            <== NOT EXECUTED
40006b74:	b8 10 00 08 	mov  %o0, %i4                                  <== NOT EXECUTED
40006b78:	d0 07 63 a8 	ld  [ %i5 + 0x3a8 ], %o0                       <== NOT EXECUTED
40006b7c:	7f ff fc 9d 	call  40005df0 <rtems_fdisk_compact>           <== NOT EXECUTED
40006b80:	90 02 00 1b 	add  %o0, %i3, %o0                             <== NOT EXECUTED
        break;                                                        
40006b84:	10 80 01 7b 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         <== NOT EXECUTED
40006b88:	d0 27 00 00 	st  %o0, [ %i4 ]                               <== NOT EXECUTED
                                                                      
      case RTEMS_FDISK_IOCTL_ERASE_USED:                              
        errno = rtems_fdisk_erase_used (&rtems_flashdisks[minor]);    
40006b8c:	40 00 68 c4 	call  40020e9c <__errno>                       <== NOT EXECUTED
40006b90:	01 00 00 00 	nop                                            <== NOT EXECUTED
40006b94:	f8 07 63 a8 	ld  [ %i5 + 0x3a8 ], %i4                       <== NOT EXECUTED
40006b98:	b4 10 00 08 	mov  %o0, %i2                                  <== NOT EXECUTED
40006b9c:	b8 07 00 1b 	add  %i4, %i3, %i4                             <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_erase_used (rtems_flashdisk* fd)                          
{                                                                     
  rtems_fdisk_segment_ctl* sc;                                        
  int                      latched_ret = 0;                           
40006ba0:	ba 10 20 00 	clr  %i5                                       <== NOT EXECUTED
                                                                      
  while ((sc = rtems_fdisk_segment_queue_pop_head (&fd->erase)))      
40006ba4:	b2 07 20 4c 	add  %i4, 0x4c, %i1                            <== NOT EXECUTED
40006ba8:	7f ff f8 62 	call  40004d30 <rtems_fdisk_segment_queue_pop_head><== NOT EXECUTED
40006bac:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40006bb0:	92 92 20 00 	orcc  %o0, 0, %o1                              <== NOT EXECUTED
40006bb4:	22 80 01 6f 	be,a   40007170 <rtems_fdisk_ioctl+0x10b4>     <== NOT EXECUTED
40006bb8:	fa 26 80 00 	st  %i5, [ %i2 ]                               <== NOT EXECUTED
  {                                                                   
    /*                                                                
     * The segment will either end up on the available queue or       
     * the failed queue.                                              
     */                                                               
    int ret = rtems_fdisk_erase_segment (fd, sc);                     
40006bbc:	7f ff fa 09 	call  400053e0 <rtems_fdisk_erase_segment>     <== NOT EXECUTED
40006bc0:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
    if (ret && !latched_ret)                                          
40006bc4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40006bc8:	02 bf ff f8 	be  40006ba8 <rtems_fdisk_ioctl+0xaec>         <== NOT EXECUTED
40006bcc:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
40006bd0:	22 bf ff f6 	be,a   40006ba8 <rtems_fdisk_ioctl+0xaec>      <== NOT EXECUTED
40006bd4:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
40006bd8:	30 bf ff f4 	b,a   40006ba8 <rtems_fdisk_ioctl+0xaec>       <== NOT EXECUTED
      case RTEMS_FDISK_IOCTL_ERASE_USED:                              
        errno = rtems_fdisk_erase_used (&rtems_flashdisks[minor]);    
        break;                                                        
                                                                      
      case RTEMS_FDISK_IOCTL_MONITORING:                              
        errno = rtems_fdisk_monitoring_data (&rtems_flashdisks[minor],
40006bdc:	40 00 68 b0 	call  40020e9c <__errno>                       <== NOT EXECUTED
40006be0:	01 00 00 00 	nop                                            <== NOT EXECUTED
40006be4:	fa 07 63 a8 	ld  [ %i5 + 0x3a8 ], %i5                       <== NOT EXECUTED
40006be8:	a0 10 00 08 	mov  %o0, %l0                                  <== NOT EXECUTED
40006bec:	ba 07 40 1b 	add  %i5, %i3, %i5                             <== NOT EXECUTED
                             rtems_fdisk_monitor_data* data)          
{                                                                     
  uint32_t i;                                                         
  uint32_t j;                                                         
                                                                      
  data->block_size     = fd->block_size;                              
40006bf0:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        <== NOT EXECUTED
  data->block_count    = fd->block_count;                             
40006bf4:	c4 07 60 1c 	ld  [ %i5 + 0x1c ], %g2                        <== NOT EXECUTED
  data->unavail_blocks = fd->unavail_blocks;                          
  data->device_count   = fd->device_count;                            
40006bf8:	f2 07 60 30 	ld  [ %i5 + 0x30 ], %i1                        <== NOT EXECUTED
                             rtems_fdisk_monitor_data* data)          
{                                                                     
  uint32_t i;                                                         
  uint32_t j;                                                         
                                                                      
  data->block_size     = fd->block_size;                              
40006bfc:	c2 26 80 00 	st  %g1, [ %i2 ]                               <== NOT EXECUTED
  data->block_count    = fd->block_count;                             
  data->unavail_blocks = fd->unavail_blocks;                          
40006c00:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        <== NOT EXECUTED
{                                                                     
  uint32_t i;                                                         
  uint32_t j;                                                         
                                                                      
  data->block_size     = fd->block_size;                              
  data->block_count    = fd->block_count;                             
40006c04:	c4 26 a0 04 	st  %g2, [ %i2 + 4 ]                           <== NOT EXECUTED
  data->unavail_blocks = fd->unavail_blocks;                          
40006c08:	c2 26 a0 08 	st  %g1, [ %i2 + 8 ]                           <== NOT EXECUTED
  data->device_count   = fd->device_count;                            
40006c0c:	f2 26 a0 0c 	st  %i1, [ %i2 + 0xc ]                         <== NOT EXECUTED
                                                                      
  data->blocks_used = 0;                                              
40006c10:	c0 26 a0 18 	clr  [ %i2 + 0x18 ]                            <== NOT EXECUTED
  for (i = 0; i < fd->block_count; i++)                               
40006c14:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
40006c18:	80 a0 40 02 	cmp  %g1, %g2                                  <== NOT EXECUTED
40006c1c:	02 80 00 0b 	be  40006c48 <rtems_fdisk_ioctl+0xb8c>         <== NOT EXECUTED
40006c20:	87 28 60 03 	sll  %g1, 3, %g3                               <== NOT EXECUTED
    if (fd->blocks[i].segment)                                        
40006c24:	c8 07 60 18 	ld  [ %i5 + 0x18 ], %g4                        <== NOT EXECUTED
40006c28:	c6 01 00 03 	ld  [ %g4 + %g3 ], %g3                         <== NOT EXECUTED
40006c2c:	80 a0 e0 00 	cmp  %g3, 0                                    <== NOT EXECUTED
40006c30:	02 bf ff fa 	be  40006c18 <rtems_fdisk_ioctl+0xb5c>         <== NOT EXECUTED
40006c34:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
      data->blocks_used++;                                            
40006c38:	c6 06 a0 18 	ld  [ %i2 + 0x18 ], %g3                        <== NOT EXECUTED
40006c3c:	86 00 e0 01 	inc  %g3                                       <== NOT EXECUTED
40006c40:	10 bf ff f6 	b  40006c18 <rtems_fdisk_ioctl+0xb5c>          <== NOT EXECUTED
40006c44:	c6 26 a0 18 	st  %g3, [ %i2 + 0x18 ]                        <== NOT EXECUTED
                                                                      
  data->segs_available = rtems_fdisk_segment_count_queue (&fd->available);
40006c48:	7f ff f9 33 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1><== NOT EXECUTED
40006c4c:	d0 07 60 34 	ld  [ %i5 + 0x34 ], %o0                        <== NOT EXECUTED
40006c50:	d0 26 a0 1c 	st  %o0, [ %i2 + 0x1c ]                        <== NOT EXECUTED
  data->segs_used      = rtems_fdisk_segment_count_queue (&fd->used); 
40006c54:	7f ff f9 30 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1><== NOT EXECUTED
40006c58:	d0 07 60 40 	ld  [ %i5 + 0x40 ], %o0                        <== NOT EXECUTED
40006c5c:	d0 26 a0 20 	st  %o0, [ %i2 + 0x20 ]                        <== NOT EXECUTED
  data->segs_failed    = rtems_fdisk_segment_count_queue (&fd->failed);
40006c60:	7f ff f9 2d 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1><== NOT EXECUTED
40006c64:	d0 07 60 58 	ld  [ %i5 + 0x58 ], %o0                        <== NOT EXECUTED
  data->page_count    = 0;                                            
  data->pages_desc    = 0;                                            
  data->pages_active  = 0;                                            
  data->pages_used    = 0;                                            
  data->pages_bad     = 0;                                            
  data->seg_erases    = 0;                                            
40006c68:	86 10 20 00 	clr  %g3                                       <== NOT EXECUTED
    if (fd->blocks[i].segment)                                        
      data->blocks_used++;                                            
                                                                      
  data->segs_available = rtems_fdisk_segment_count_queue (&fd->available);
  data->segs_used      = rtems_fdisk_segment_count_queue (&fd->used); 
  data->segs_failed    = rtems_fdisk_segment_count_queue (&fd->failed);
40006c6c:	d0 26 a0 24 	st  %o0, [ %i2 + 0x24 ]                        <== NOT EXECUTED
                                                                      
  data->segment_count = 0;                                            
40006c70:	c0 26 a0 10 	clr  [ %i2 + 0x10 ]                            <== NOT EXECUTED
  data->page_count    = 0;                                            
40006c74:	c0 26 a0 14 	clr  [ %i2 + 0x14 ]                            <== NOT EXECUTED
  data->pages_desc    = 0;                                            
40006c78:	c0 26 a0 2c 	clr  [ %i2 + 0x2c ]                            <== NOT EXECUTED
  data->pages_active  = 0;                                            
40006c7c:	c0 26 a0 30 	clr  [ %i2 + 0x30 ]                            <== NOT EXECUTED
  data->pages_used    = 0;                                            
40006c80:	c0 26 a0 34 	clr  [ %i2 + 0x34 ]                            <== NOT EXECUTED
  data->pages_bad     = 0;                                            
40006c84:	c0 26 a0 38 	clr  [ %i2 + 0x38 ]                            <== NOT EXECUTED
  data->seg_erases    = 0;                                            
40006c88:	c0 26 a0 28 	clr  [ %i2 + 0x28 ]                            <== NOT EXECUTED
                                                                      
  for (i = 0; i < fd->device_count; i++)                              
40006c8c:	84 10 20 00 	clr  %g2                                       <== NOT EXECUTED
40006c90:	80 a0 80 19 	cmp  %g2, %i1                                  <== NOT EXECUTED
40006c94:	02 80 00 2b 	be  40006d40 <rtems_fdisk_ioctl+0xc84>         <== NOT EXECUTED
40006c98:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
  {                                                                   
    data->segment_count += fd->devices[i].segment_count;              
40006c9c:	de 07 60 2c 	ld  [ %i5 + 0x2c ], %o7                        <== NOT EXECUTED
40006ca0:	c2 06 a0 10 	ld  [ %i2 + 0x10 ], %g1                        <== NOT EXECUTED
40006ca4:	9e 03 c0 03 	add  %o7, %g3, %o7                             <== NOT EXECUTED
40006ca8:	f0 03 e0 04 	ld  [ %o7 + 4 ], %i0                           <== NOT EXECUTED
40006cac:	82 00 40 18 	add  %g1, %i0, %g1                             <== NOT EXECUTED
                                                                      
    for (j = 0; j < fd->devices[i].segment_count; j++)                
40006cb0:	88 10 20 00 	clr  %g4                                       <== NOT EXECUTED
  data->pages_bad     = 0;                                            
  data->seg_erases    = 0;                                            
                                                                      
  for (i = 0; i < fd->device_count; i++)                              
  {                                                                   
    data->segment_count += fd->devices[i].segment_count;              
40006cb4:	c2 26 a0 10 	st  %g1, [ %i2 + 0x10 ]                        <== NOT EXECUTED
                                                                      
    for (j = 0; j < fd->devices[i].segment_count; j++)                
40006cb8:	80 a1 00 18 	cmp  %g4, %i0                                  <== NOT EXECUTED
40006cbc:	02 80 00 1e 	be  40006d34 <rtems_fdisk_ioctl+0xc78>         <== NOT EXECUTED
40006cc0:	88 01 20 01 	inc  %g4                                       <== NOT EXECUTED
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[i].segments[j];      
40006cc4:	c2 03 c0 00 	ld  [ %o7 ], %g1                               <== NOT EXECUTED
                                                                      
      data->page_count   += sc->pages;                                
40006cc8:	d8 06 a0 14 	ld  [ %i2 + 0x14 ], %o4                        <== NOT EXECUTED
  {                                                                   
    data->segment_count += fd->devices[i].segment_count;              
                                                                      
    for (j = 0; j < fd->devices[i].segment_count; j++)                
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[i].segments[j];      
40006ccc:	82 00 40 1c 	add  %g1, %i4, %g1                             <== NOT EXECUTED
                                                                      
      data->page_count   += sc->pages;                                
40006cd0:	da 00 60 14 	ld  [ %g1 + 0x14 ], %o5                        <== NOT EXECUTED
40006cd4:	9a 03 00 0d 	add  %o4, %o5, %o5                             <== NOT EXECUTED
      data->pages_desc   += sc->pages_desc;                           
40006cd8:	d8 06 a0 2c 	ld  [ %i2 + 0x2c ], %o4                        <== NOT EXECUTED
                                                                      
    for (j = 0; j < fd->devices[i].segment_count; j++)                
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[i].segments[j];      
                                                                      
      data->page_count   += sc->pages;                                
40006cdc:	da 26 a0 14 	st  %o5, [ %i2 + 0x14 ]                        <== NOT EXECUTED
      data->pages_desc   += sc->pages_desc;                           
40006ce0:	da 00 60 18 	ld  [ %g1 + 0x18 ], %o5                        <== NOT EXECUTED
40006ce4:	b8 07 20 30 	add  %i4, 0x30, %i4                            <== NOT EXECUTED
40006ce8:	9a 03 00 0d 	add  %o4, %o5, %o5                             <== NOT EXECUTED
      data->pages_active += sc->pages_active;                         
40006cec:	d8 06 a0 30 	ld  [ %i2 + 0x30 ], %o4                        <== NOT EXECUTED
    for (j = 0; j < fd->devices[i].segment_count; j++)                
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[i].segments[j];      
                                                                      
      data->page_count   += sc->pages;                                
      data->pages_desc   += sc->pages_desc;                           
40006cf0:	da 26 a0 2c 	st  %o5, [ %i2 + 0x2c ]                        <== NOT EXECUTED
      data->pages_active += sc->pages_active;                         
40006cf4:	da 00 60 1c 	ld  [ %g1 + 0x1c ], %o5                        <== NOT EXECUTED
40006cf8:	9a 03 00 0d 	add  %o4, %o5, %o5                             <== NOT EXECUTED
      data->pages_used   += sc->pages_used;                           
40006cfc:	d8 06 a0 34 	ld  [ %i2 + 0x34 ], %o4                        <== NOT EXECUTED
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[i].segments[j];      
                                                                      
      data->page_count   += sc->pages;                                
      data->pages_desc   += sc->pages_desc;                           
      data->pages_active += sc->pages_active;                         
40006d00:	da 26 a0 30 	st  %o5, [ %i2 + 0x30 ]                        <== NOT EXECUTED
      data->pages_used   += sc->pages_used;                           
40006d04:	da 00 60 20 	ld  [ %g1 + 0x20 ], %o5                        <== NOT EXECUTED
40006d08:	9a 03 00 0d 	add  %o4, %o5, %o5                             <== NOT EXECUTED
      data->pages_bad    += sc->pages_bad;                            
40006d0c:	d8 06 a0 38 	ld  [ %i2 + 0x38 ], %o4                        <== NOT EXECUTED
      rtems_fdisk_segment_ctl* sc = &fd->devices[i].segments[j];      
                                                                      
      data->page_count   += sc->pages;                                
      data->pages_desc   += sc->pages_desc;                           
      data->pages_active += sc->pages_active;                         
      data->pages_used   += sc->pages_used;                           
40006d10:	da 26 a0 34 	st  %o5, [ %i2 + 0x34 ]                        <== NOT EXECUTED
      data->pages_bad    += sc->pages_bad;                            
40006d14:	da 00 60 24 	ld  [ %g1 + 0x24 ], %o5                        <== NOT EXECUTED
      data->seg_erases   += sc->erased;                               
40006d18:	c2 00 60 2c 	ld  [ %g1 + 0x2c ], %g1                        <== NOT EXECUTED
                                                                      
      data->page_count   += sc->pages;                                
      data->pages_desc   += sc->pages_desc;                           
      data->pages_active += sc->pages_active;                         
      data->pages_used   += sc->pages_used;                           
      data->pages_bad    += sc->pages_bad;                            
40006d1c:	9a 03 00 0d 	add  %o4, %o5, %o5                             <== NOT EXECUTED
40006d20:	da 26 a0 38 	st  %o5, [ %i2 + 0x38 ]                        <== NOT EXECUTED
      data->seg_erases   += sc->erased;                               
40006d24:	da 06 a0 28 	ld  [ %i2 + 0x28 ], %o5                        <== NOT EXECUTED
40006d28:	82 03 40 01 	add  %o5, %g1, %g1                             <== NOT EXECUTED
40006d2c:	10 bf ff e3 	b  40006cb8 <rtems_fdisk_ioctl+0xbfc>          <== NOT EXECUTED
40006d30:	c2 26 a0 28 	st  %g1, [ %i2 + 0x28 ]                        <== NOT EXECUTED
  data->pages_active  = 0;                                            
  data->pages_used    = 0;                                            
  data->pages_bad     = 0;                                            
  data->seg_erases    = 0;                                            
                                                                      
  for (i = 0; i < fd->device_count; i++)                              
40006d34:	84 00 a0 01 	inc  %g2                                       <== NOT EXECUTED
40006d38:	10 bf ff d6 	b  40006c90 <rtems_fdisk_ioctl+0xbd4>          <== NOT EXECUTED
40006d3c:	86 00 e0 0c 	add  %g3, 0xc, %g3                             <== NOT EXECUTED
      data->pages_bad    += sc->pages_bad;                            
      data->seg_erases   += sc->erased;                               
    }                                                                 
  }                                                                   
                                                                      
  data->info_level = fd->info_level;                                  
40006d40:	c2 07 60 6c 	ld  [ %i5 + 0x6c ], %g1                        <== NOT EXECUTED
40006d44:	c2 26 a0 3c 	st  %g1, [ %i2 + 0x3c ]                        <== NOT EXECUTED
        break;                                                        
                                                                      
      case RTEMS_FDISK_IOCTL_MONITORING:                              
        errno = rtems_fdisk_monitoring_data (&rtems_flashdisks[minor],
                                             (rtems_fdisk_monitor_data*) argp);
        break;                                                        
40006d48:	10 80 01 0a 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         <== NOT EXECUTED
40006d4c:	c0 24 00 00 	clr  [ %l0 ]                                   <== NOT EXECUTED
                                                                      
      case RTEMS_FDISK_IOCTL_INFO_LEVEL:                              
        rtems_flashdisks[minor].info_level = (uintptr_t) argp;        
40006d50:	c2 07 63 a8 	ld  [ %i5 + 0x3a8 ], %g1                       <== NOT EXECUTED
40006d54:	82 00 40 1b 	add  %g1, %i3, %g1                             <== NOT EXECUTED
        break;                                                        
40006d58:	10 80 01 06 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         <== NOT EXECUTED
40006d5c:	f4 20 60 6c 	st  %i2, [ %g1 + 0x6c ]                        <== NOT EXECUTED
                                                                      
      case RTEMS_FDISK_IOCTL_PRINT_STATUS:                            
        errno = rtems_fdisk_print_status (&rtems_flashdisks[minor]);  
40006d60:	40 00 68 4f 	call  40020e9c <__errno>                       
40006d64:	01 00 00 00 	nop                                            
40006d68:	c2 07 63 a8 	ld  [ %i5 + 0x3a8 ], %g1                       
40006d6c:	d0 27 bf f4 	st  %o0, [ %fp + -12 ]                         
40006d70:	ba 00 40 1b 	add  %g1, %i3, %i5                             
 */                                                                   
static int                                                            
rtems_fdisk_print_status (rtems_flashdisk* fd)                        
{                                                                     
#if RTEMS_FDISK_TRACE                                                 
  uint32_t current_info_level = fd->info_level;                       
40006d74:	c4 07 60 6c 	ld  [ %i5 + 0x6c ], %g2                        
  uint32_t count;                                                     
  uint32_t device;                                                    
                                                                      
  fd->info_level = 3;                                                 
                                                                      
  rtems_fdisk_printf (fd,                                             
40006d78:	d4 00 40 1b 	ld  [ %g1 + %i3 ], %o2                         
40006d7c:	d6 07 60 04 	ld  [ %i5 + 4 ], %o3                           
 */                                                                   
static int                                                            
rtems_fdisk_print_status (rtems_flashdisk* fd)                        
{                                                                     
#if RTEMS_FDISK_TRACE                                                 
  uint32_t current_info_level = fd->info_level;                       
40006d80:	c4 27 bf f0 	st  %g2, [ %fp + -16 ]                         
  uint32_t total;                                                     
  uint32_t count;                                                     
  uint32_t device;                                                    
                                                                      
  fd->info_level = 3;                                                 
40006d84:	84 10 20 03 	mov  3, %g2                                    
                                                                      
  rtems_fdisk_printf (fd,                                             
40006d88:	90 10 00 1d 	mov  %i5, %o0                                  
  uint32_t current_info_level = fd->info_level;                       
  uint32_t total;                                                     
  uint32_t count;                                                     
  uint32_t device;                                                    
                                                                      
  fd->info_level = 3;                                                 
40006d8c:	c4 27 60 6c 	st  %g2, [ %i5 + 0x6c ]                        
                                                                      
  rtems_fdisk_printf (fd,                                             
40006d90:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006d94:	7f ff f8 5f 	call  40004f10 <rtems_fdisk_printf>            
40006d98:	92 12 62 e8 	or  %o1, 0x2e8, %o1	! 40032ae8 <__FUNCTION__.6501+0xa80>
                      "Flash Disk Driver Status : %d.%d", fd->major, fd->minor);
                                                                      
  rtems_fdisk_printf (fd, "Block count\t%d", fd->block_count);        
40006d9c:	d4 07 60 1c 	ld  [ %i5 + 0x1c ], %o2                        
40006da0:	90 10 00 1d 	mov  %i5, %o0                                  
40006da4:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006da8:	7f ff f8 5a 	call  40004f10 <rtems_fdisk_printf>            
40006dac:	92 12 63 10 	or  %o1, 0x310, %o1	! 40032b10 <__FUNCTION__.6501+0xaa8>
  rtems_fdisk_printf (fd, "Unavail blocks\t%d", fd->unavail_blocks);  
40006db0:	d4 07 60 20 	ld  [ %i5 + 0x20 ], %o2                        
40006db4:	90 10 00 1d 	mov  %i5, %o0                                  
40006db8:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006dbc:	7f ff f8 55 	call  40004f10 <rtems_fdisk_printf>            
40006dc0:	92 12 63 20 	or  %o1, 0x320, %o1	! 40032b20 <__FUNCTION__.6501+0xab8>
  rtems_fdisk_printf (fd, "Starvation threshold\t%d", fd->starvation_threshold);
40006dc4:	d4 07 60 24 	ld  [ %i5 + 0x24 ], %o2                        
40006dc8:	90 10 00 1d 	mov  %i5, %o0                                  
40006dcc:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006dd0:	7f ff f8 50 	call  40004f10 <rtems_fdisk_printf>            
40006dd4:	92 12 63 38 	or  %o1, 0x338, %o1	! 40032b38 <__FUNCTION__.6501+0xad0>
  rtems_fdisk_printf (fd, "Starvations\t%d", fd->starvations);        
40006dd8:	d4 07 60 70 	ld  [ %i5 + 0x70 ], %o2                        
40006ddc:	90 10 00 1d 	mov  %i5, %o0                                  
40006de0:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006de4:	7f ff f8 4b 	call  40004f10 <rtems_fdisk_printf>            
40006de8:	92 12 63 50 	or  %o1, 0x350, %o1	! 40032b50 <__FUNCTION__.6501+0xae8>
  count = rtems_fdisk_segment_count_queue (&fd->available);           
40006dec:	7f ff f8 ca 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1>
40006df0:	d0 07 60 34 	ld  [ %i5 + 0x34 ], %o0                        
  total = count;                                                      
  rtems_fdisk_printf (fd, "Available queue\t%ld (%ld)",               
40006df4:	d6 07 60 3c 	ld  [ %i5 + 0x3c ], %o3                        
                                                                      
  rtems_fdisk_printf (fd, "Block count\t%d", fd->block_count);        
  rtems_fdisk_printf (fd, "Unavail blocks\t%d", fd->unavail_blocks);  
  rtems_fdisk_printf (fd, "Starvation threshold\t%d", fd->starvation_threshold);
  rtems_fdisk_printf (fd, "Starvations\t%d", fd->starvations);        
  count = rtems_fdisk_segment_count_queue (&fd->available);           
40006df8:	b8 10 00 08 	mov  %o0, %i4                                  
  total = count;                                                      
  rtems_fdisk_printf (fd, "Available queue\t%ld (%ld)",               
40006dfc:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006e00:	94 10 00 1c 	mov  %i4, %o2                                  
40006e04:	92 12 63 60 	or  %o1, 0x360, %o1                            
40006e08:	7f ff f8 42 	call  40004f10 <rtems_fdisk_printf>            
40006e0c:	90 10 00 1d 	mov  %i5, %o0                                  
                      count, rtems_fdisk_segment_queue_count (&fd->available));
  count = rtems_fdisk_segment_count_queue (&fd->used);                
40006e10:	7f ff f8 c1 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1>
40006e14:	d0 07 60 40 	ld  [ %i5 + 0x40 ], %o0                        
  total += count;                                                     
  rtems_fdisk_printf (fd, "Used queue\t%ld (%ld)",                    
40006e18:	d6 07 60 48 	ld  [ %i5 + 0x48 ], %o3                        
  rtems_fdisk_printf (fd, "Starvations\t%d", fd->starvations);        
  count = rtems_fdisk_segment_count_queue (&fd->available);           
  total = count;                                                      
  rtems_fdisk_printf (fd, "Available queue\t%ld (%ld)",               
                      count, rtems_fdisk_segment_queue_count (&fd->available));
  count = rtems_fdisk_segment_count_queue (&fd->used);                
40006e1c:	94 10 00 08 	mov  %o0, %o2                                  
  total += count;                                                     
40006e20:	b8 02 00 1c 	add  %o0, %i4, %i4                             
  rtems_fdisk_printf (fd, "Used queue\t%ld (%ld)",                    
40006e24:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006e28:	90 10 00 1d 	mov  %i5, %o0                                  
40006e2c:	7f ff f8 39 	call  40004f10 <rtems_fdisk_printf>            
40006e30:	92 12 63 80 	or  %o1, 0x380, %o1                            
                      count, rtems_fdisk_segment_queue_count (&fd->used));
  count = rtems_fdisk_segment_count_queue (&fd->erase);               
40006e34:	7f ff f8 b8 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1>
40006e38:	d0 07 60 4c 	ld  [ %i5 + 0x4c ], %o0                        
  total += count;                                                     
  rtems_fdisk_printf (fd, "Erase queue\t%ld (%ld)",                   
40006e3c:	d6 07 60 54 	ld  [ %i5 + 0x54 ], %o3                        
                      count, rtems_fdisk_segment_queue_count (&fd->available));
  count = rtems_fdisk_segment_count_queue (&fd->used);                
  total += count;                                                     
  rtems_fdisk_printf (fd, "Used queue\t%ld (%ld)",                    
                      count, rtems_fdisk_segment_queue_count (&fd->used));
  count = rtems_fdisk_segment_count_queue (&fd->erase);               
40006e40:	94 10 00 08 	mov  %o0, %o2                                  
  total += count;                                                     
40006e44:	b8 07 00 08 	add  %i4, %o0, %i4                             
  rtems_fdisk_printf (fd, "Erase queue\t%ld (%ld)",                   
40006e48:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006e4c:	90 10 00 1d 	mov  %i5, %o0                                  
40006e50:	7f ff f8 30 	call  40004f10 <rtems_fdisk_printf>            
40006e54:	92 12 63 98 	or  %o1, 0x398, %o1                            
                      count, rtems_fdisk_segment_queue_count (&fd->erase));
  count = rtems_fdisk_segment_count_queue (&fd->failed);              
40006e58:	7f ff f8 af 	call  40005114 <rtems_fdisk_segment_count_queue.isra.1>
40006e5c:	d0 07 60 58 	ld  [ %i5 + 0x58 ], %o0                        
  total += count;                                                     
  rtems_fdisk_printf (fd, "Failed queue\t%ld (%ld)",                  
40006e60:	d6 07 60 60 	ld  [ %i5 + 0x60 ], %o3                        
                      count, rtems_fdisk_segment_queue_count (&fd->used));
  count = rtems_fdisk_segment_count_queue (&fd->erase);               
  total += count;                                                     
  rtems_fdisk_printf (fd, "Erase queue\t%ld (%ld)",                   
                      count, rtems_fdisk_segment_queue_count (&fd->erase));
  count = rtems_fdisk_segment_count_queue (&fd->failed);              
40006e64:	94 10 00 08 	mov  %o0, %o2                                  
  total += count;                                                     
40006e68:	b8 07 00 08 	add  %i4, %o0, %i4                             
  rtems_fdisk_printf (fd, "Failed queue\t%ld (%ld)",                  
40006e6c:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006e70:	90 10 00 1d 	mov  %i5, %o0                                  
40006e74:	7f ff f8 27 	call  40004f10 <rtems_fdisk_printf>            
40006e78:	92 12 63 b0 	or  %o1, 0x3b0, %o1                            
                      count, rtems_fdisk_segment_queue_count (&fd->failed));
                                                                      
  count = 0;                                                          
  for (device = 0; device < fd->device_count; device++)               
40006e7c:	c6 07 60 30 	ld  [ %i5 + 0x30 ], %g3                        
40006e80:	84 10 20 00 	clr  %g2                                       
40006e84:	82 10 20 00 	clr  %g1                                       
  count = rtems_fdisk_segment_count_queue (&fd->failed);              
  total += count;                                                     
  rtems_fdisk_printf (fd, "Failed queue\t%ld (%ld)",                  
                      count, rtems_fdisk_segment_queue_count (&fd->failed));
                                                                      
  count = 0;                                                          
40006e88:	96 10 20 00 	clr  %o3                                       
  for (device = 0; device < fd->device_count; device++)               
40006e8c:	80 a0 40 03 	cmp  %g1, %g3                                  
40006e90:	02 80 00 08 	be  40006eb0 <rtems_fdisk_ioctl+0xdf4>         
40006e94:	82 00 60 01 	inc  %g1                                       
    count += fd->devices[device].segment_count;                       
40006e98:	c8 07 60 2c 	ld  [ %i5 + 0x2c ], %g4                        
40006e9c:	88 01 00 02 	add  %g4, %g2, %g4                             
40006ea0:	c8 01 20 04 	ld  [ %g4 + 4 ], %g4                           
40006ea4:	84 00 a0 0c 	add  %g2, 0xc, %g2                             
40006ea8:	10 bf ff f9 	b  40006e8c <rtems_fdisk_ioctl+0xdd0>          
40006eac:	96 02 c0 04 	add  %o3, %g4, %o3                             
                                                                      
  rtems_fdisk_printf (fd, "Queue total\t%ld of %ld, %s", total, count,
40006eb0:	19 10 00 c9 	sethi  %hi(0x40032400), %o4                    
40006eb4:	80 a7 00 0b 	cmp  %i4, %o3                                  
40006eb8:	12 80 00 04 	bne  40006ec8 <rtems_fdisk_ioctl+0xe0c>        <== NEVER TAKEN
40006ebc:	98 13 22 90 	or  %o4, 0x290, %o4                            
40006ec0:	19 10 00 c9 	sethi  %hi(0x40032400), %o4                    
40006ec4:	98 13 22 88 	or  %o4, 0x288, %o4	! 40032688 <__FUNCTION__.6501+0x620>
40006ec8:	94 10 00 1c 	mov  %i4, %o2                                  
40006ecc:	90 10 00 1d 	mov  %i5, %o0                                  
40006ed0:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006ed4:	7f ff f8 0f 	call  40004f10 <rtems_fdisk_printf>            
40006ed8:	92 12 63 c8 	or  %o1, 0x3c8, %o1	! 40032bc8 <__FUNCTION__.6501+0xb60>
                      total == count ? "ok" : "MISSING");             
                                                                      
  rtems_fdisk_printf (fd, "Device count\t%d", fd->device_count);      
40006edc:	d4 07 60 30 	ld  [ %i5 + 0x30 ], %o2                        
40006ee0:	90 10 00 1d 	mov  %i5, %o0                                  
40006ee4:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
                                                                      
        for (block = 0; block < fd->block_count; block++)             
        {                                                             
          if ((fd->blocks[block].segment == sc) &&                    
              (fd->blocks[block].page == page) && !is_active)         
            rtems_fdisk_printf (fd,                                   
40006ee8:	2d 10 00 cb 	sethi  %hi(0x40032c00), %l6                    
    count += fd->devices[device].segment_count;                       
                                                                      
  rtems_fdisk_printf (fd, "Queue total\t%ld of %ld, %s", total, count,
                      total == count ? "ok" : "MISSING");             
                                                                      
  rtems_fdisk_printf (fd, "Device count\t%d", fd->device_count);      
40006eec:	92 12 63 e8 	or  %o1, 0x3e8, %o1                            
40006ef0:	7f ff f8 08 	call  40004f10 <rtems_fdisk_printf>            
40006ef4:	2f 10 00 cb 	sethi  %hi(0x40032c00), %l7                    
40006ef8:	b4 10 20 00 	clr  %i2                                       
                                                                      
  for (device = 0; device < fd->device_count; device++)               
40006efc:	b2 10 20 00 	clr  %i1                                       
                                                                      
        for (block = 0; block < fd->block_count; block++)             
        {                                                             
          if ((fd->blocks[block].segment == sc) &&                    
              (fd->blocks[block].page == page) && !is_active)         
            rtems_fdisk_printf (fd,                                   
40006f00:	ac 15 a0 20 	or  %l6, 0x20, %l6                             
      {                                                               
        if (fd->blocks[block].segment == sc)                          
          count++;                                                    
      }                                                               
                                                                      
      rtems_fdisk_printf (fd, "  %3ld %s p:%3ld a:%3ld/%3ld" \        
40006f04:	ae 15 e0 50 	or  %l7, 0x50, %l7                             
  rtems_fdisk_printf (fd, "Queue total\t%ld of %ld, %s", total, count,
                      total == count ? "ok" : "MISSING");             
                                                                      
  rtems_fdisk_printf (fd, "Device count\t%d", fd->device_count);      
                                                                      
  for (device = 0; device < fd->device_count; device++)               
40006f08:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        
40006f0c:	80 a6 40 01 	cmp  %i1, %g1                                  
40006f10:	1a 80 00 7b 	bcc  400070fc <rtems_fdisk_ioctl+0x1040>       
40006f14:	94 10 00 19 	mov  %i1, %o2                                  
  {                                                                   
    uint32_t block;                                                   
    uint32_t seg;                                                     
                                                                      
    rtems_fdisk_printf (fd, " Device\t\t%ld", device);                
40006f18:	90 10 00 1d 	mov  %i5, %o0                                  
40006f1c:	13 10 00 ca 	sethi  %hi(0x40032800), %o1                    
40006f20:	7f ff f7 fc 	call  40004f10 <rtems_fdisk_printf>            
40006f24:	92 12 63 f8 	or  %o1, 0x3f8, %o1	! 40032bf8 <__FUNCTION__.6501+0xb90>
    rtems_fdisk_printf (fd, "  Segment count\t%ld",                   
40006f28:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        
40006f2c:	90 10 00 1d 	mov  %i5, %o0                                  
40006f30:	82 00 40 1a 	add  %g1, %i2, %g1                             
40006f34:	d4 00 60 04 	ld  [ %g1 + 4 ], %o2                           
40006f38:	13 10 00 cb 	sethi  %hi(0x40032c00), %o1                    
40006f3c:	a0 10 20 00 	clr  %l0                                       
40006f40:	92 12 60 08 	or  %o1, 8, %o1                                
40006f44:	7f ff f7 f3 	call  40004f10 <rtems_fdisk_printf>            
40006f48:	b0 10 20 00 	clr  %i0                                       
                        fd->devices[device].segment_count);           
                                                                      
    for (seg = 0; seg < fd->devices[device].segment_count; seg++)     
40006f4c:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        
40006f50:	84 00 40 1a 	add  %g1, %i2, %g2                             
40006f54:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
40006f58:	80 a6 00 02 	cmp  %i0, %g2                                  
40006f5c:	1a 80 00 65 	bcc  400070f0 <rtems_fdisk_ioctl+0x1034>       
40006f60:	90 10 00 1d 	mov  %i5, %o0                                  
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[device].segments[seg];
40006f64:	f8 00 40 1a 	ld  [ %g1 + %i2 ], %i4                         
40006f68:	b8 07 00 10 	add  %i4, %l0, %i4                             
      uint32_t                 active = 0;                            
      uint32_t                 used = 0;                              
      bool                     is_active = false;                     
      char                     queues[5];                             
                                                                      
      rtems_fdisk_queue_status (fd, sc, queues);                      
40006f6c:	94 07 bf f8 	add  %fp, -8, %o2                              
40006f70:	92 10 00 1c 	mov  %i4, %o1                                  
40006f74:	7f ff fc 28 	call  40006014 <rtems_fdisk_queue_status>      
40006f78:	a2 10 20 00 	clr  %l1                                       
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[device].segments[seg];
      uint32_t                 page;                                  
      uint32_t                 erased = 0;                            
      uint32_t                 active = 0;                            
      uint32_t                 used = 0;                              
40006f7c:	a6 10 20 00 	clr  %l3                                       
    for (seg = 0; seg < fd->devices[device].segment_count; seg++)     
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[device].segments[seg];
      uint32_t                 page;                                  
      uint32_t                 erased = 0;                            
      uint32_t                 active = 0;                            
40006f80:	a8 10 20 00 	clr  %l4                                       
                                                                      
    for (seg = 0; seg < fd->devices[device].segment_count; seg++)     
    {                                                                 
      rtems_fdisk_segment_ctl* sc = &fd->devices[device].segments[seg];
      uint32_t                 page;                                  
      uint32_t                 erased = 0;                            
40006f84:	a4 10 20 00 	clr  %l2                                       
      bool                     is_active = false;                     
      char                     queues[5];                             
                                                                      
      rtems_fdisk_queue_status (fd, sc, queues);                      
                                                                      
      for (page = 0; page < sc->pages; page++)                        
40006f88:	aa 10 20 00 	clr  %l5                                       
40006f8c:	d8 07 20 14 	ld  [ %i4 + 0x14 ], %o4                        
40006f90:	80 a5 40 0c 	cmp  %l5, %o4                                  
40006f94:	1a 80 00 36 	bcc  4000706c <rtems_fdisk_ioctl+0xfb0>        
40006f98:	85 2d 60 03 	sll  %l5, 3, %g2                               
      {                                                               
        if (rtems_fdisk_page_desc_erased (&sc->page_descriptors[page]))
40006f9c:	de 07 20 10 	ld  [ %i4 + 0x10 ], %o7                        
40006fa0:	84 03 c0 02 	add  %o7, %g2, %g2                             
40006fa4:	90 10 00 02 	mov  %g2, %o0                                  
40006fa8:	7f ff f7 b6 	call  40004e80 <rtems_fdisk_page_desc_erased>  
40006fac:	c4 27 bf d8 	st  %g2, [ %fp + -40 ]                         
40006fb0:	80 a2 20 00 	cmp  %o0, 0                                    
40006fb4:	02 80 00 04 	be  40006fc4 <rtems_fdisk_ioctl+0xf08>         
40006fb8:	c4 07 bf d8 	ld  [ %fp + -40 ], %g2                         
          erased++;                                                   
40006fbc:	10 80 00 0c 	b  40006fec <rtems_fdisk_ioctl+0xf30>          
40006fc0:	a4 04 a0 01 	inc  %l2                                       
        else if (rtems_fdisk_page_desc_flags_set (&sc->page_descriptors[page],
40006fc4:	c4 10 a0 02 	lduh  [ %g2 + 2 ], %g2                         
40006fc8:	80 88 a0 01 	btst  1, %g2                                   
40006fcc:	32 80 00 09 	bne,a   40006ff0 <rtems_fdisk_ioctl+0xf34>     <== NEVER TAKEN
40006fd0:	84 10 20 00 	clr  %g2                                       <== NOT EXECUTED
                                                  RTEMS_FDISK_PAGE_ACTIVE))
        {                                                             
          if (rtems_fdisk_page_desc_flags_set (&sc->page_descriptors[page],
40006fd4:	80 88 a0 02 	btst  2, %g2                                   
40006fd8:	32 80 00 04 	bne,a   40006fe8 <rtems_fdisk_ioctl+0xf2c>     
40006fdc:	a8 05 20 01 	inc  %l4                                       
                                               RTEMS_FDISK_PAGE_USED))
            used++;                                                   
40006fe0:	10 80 00 03 	b  40006fec <rtems_fdisk_ioctl+0xf30>          
40006fe4:	a6 04 e0 01 	inc  %l3                                       
          else                                                        
          {                                                           
            active++;                                                 
            is_active = true;                                         
40006fe8:	a2 10 20 01 	mov  1, %l1                                    
          }                                                           
        }                                                             
                                                                      
        for (block = 0; block < fd->block_count; block++)             
40006fec:	84 10 20 00 	clr  %g2                                       
        {                                                             
          if ((fd->blocks[block].segment == sc) &&                    
              (fd->blocks[block].page == page) && !is_active)         
40006ff0:	9a 0c 60 ff 	and  %l1, 0xff, %o5                            
            active++;                                                 
            is_active = true;                                         
          }                                                           
        }                                                             
                                                                      
        for (block = 0; block < fd->block_count; block++)             
40006ff4:	de 07 60 1c 	ld  [ %i5 + 0x1c ], %o7                        
40006ff8:	80 a0 80 0f 	cmp  %g2, %o7                                  
40006ffc:	1a 80 00 1a 	bcc  40007064 <rtems_fdisk_ioctl+0xfa8>        
40007000:	9f 28 a0 03 	sll  %g2, 3, %o7                               
        {                                                             
          if ((fd->blocks[block].segment == sc) &&                    
40007004:	d8 07 60 18 	ld  [ %i5 + 0x18 ], %o4                        
40007008:	96 03 00 0f 	add  %o4, %o7, %o3                             
4000700c:	de 03 00 0f 	ld  [ %o4 + %o7 ], %o7                         
40007010:	80 a3 c0 1c 	cmp  %o7, %i4                                  
40007014:	32 bf ff f8 	bne,a   40006ff4 <rtems_fdisk_ioctl+0xf38>     
40007018:	84 00 a0 01 	inc  %g2                                       
4000701c:	de 02 e0 04 	ld  [ %o3 + 4 ], %o7                           
40007020:	80 a3 c0 15 	cmp  %o7, %l5                                  
40007024:	32 bf ff f4 	bne,a   40006ff4 <rtems_fdisk_ioctl+0xf38>     
40007028:	84 00 a0 01 	inc  %g2                                       
              (fd->blocks[block].page == page) && !is_active)         
4000702c:	80 a3 60 00 	cmp  %o5, 0                                    
40007030:	32 bf ff f1 	bne,a   40006ff4 <rtems_fdisk_ioctl+0xf38>     <== ALWAYS TAKEN
40007034:	84 00 a0 01 	inc  %g2                                       
            rtems_fdisk_printf (fd,                                   
40007038:	96 10 00 02 	mov  %g2, %o3                                  <== NOT EXECUTED
4000703c:	c4 27 bf d8 	st  %g2, [ %fp + -40 ]                         <== NOT EXECUTED
40007040:	da 27 bf cc 	st  %o5, [ %fp + -52 ]                         <== NOT EXECUTED
40007044:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40007048:	92 10 00 16 	mov  %l6, %o1                                  <== NOT EXECUTED
4000704c:	7f ff f7 b1 	call  40004f10 <rtems_fdisk_printf>            <== NOT EXECUTED
40007050:	94 10 00 15 	mov  %l5, %o2                                  <== NOT EXECUTED
40007054:	da 07 bf cc 	ld  [ %fp + -52 ], %o5                         <== NOT EXECUTED
40007058:	c4 07 bf d8 	ld  [ %fp + -40 ], %g2                         <== NOT EXECUTED
            active++;                                                 
            is_active = true;                                         
          }                                                           
        }                                                             
                                                                      
        for (block = 0; block < fd->block_count; block++)             
4000705c:	10 bf ff e6 	b  40006ff4 <rtems_fdisk_ioctl+0xf38>          <== NOT EXECUTED
40007060:	84 00 a0 01 	inc  %g2                                       <== NOT EXECUTED
      bool                     is_active = false;                     
      char                     queues[5];                             
                                                                      
      rtems_fdisk_queue_status (fd, sc, queues);                      
                                                                      
      for (page = 0; page < sc->pages; page++)                        
40007064:	10 bf ff ca 	b  40006f8c <rtems_fdisk_ioctl+0xed0>          
40007068:	aa 05 60 01 	inc  %l5                                       
                                page, block);                         
        }                                                             
      }                                                               
                                                                      
      count = 0;                                                      
      for (block = 0; block < fd->block_count; block++)               
4000706c:	de 07 60 1c 	ld  [ %i5 + 0x1c ], %o7                        
40007070:	82 10 20 00 	clr  %g1                                       
40007074:	84 10 20 00 	clr  %g2                                       
40007078:	80 a0 40 0f 	cmp  %g1, %o7                                  
4000707c:	02 80 00 09 	be  400070a0 <rtems_fdisk_ioctl+0xfe4>         
40007080:	9b 28 60 03 	sll  %g1, 3, %o5                               
      {                                                               
        if (fd->blocks[block].segment == sc)                          
40007084:	d6 07 60 18 	ld  [ %i5 + 0x18 ], %o3                        
40007088:	da 02 c0 0d 	ld  [ %o3 + %o5 ], %o5                         
                                page, block);                         
        }                                                             
      }                                                               
                                                                      
      count = 0;                                                      
      for (block = 0; block < fd->block_count; block++)               
4000708c:	82 00 60 01 	inc  %g1                                       
      {                                                               
        if (fd->blocks[block].segment == sc)                          
          count++;                                                    
40007090:	9a 1b 40 1c 	xor  %o5, %i4, %o5                             
40007094:	80 a0 00 0d 	cmp  %g0, %o5                                  
40007098:	10 bf ff f8 	b  40007078 <rtems_fdisk_ioctl+0xfbc>          
4000709c:	84 60 bf ff 	subx  %g2, -1, %g2                             
                          " u:%3ld/%3ld e:%3ld/%3ld br:%ld",          
                          seg, queues,                                
                          sc->pages, sc->pages_active, active,        
                          sc->pages_used, used, erased,               
                          sc->pages - (sc->pages_active +             
                                       sc->pages_used + sc->pages_bad),
400070a0:	c2 07 20 20 	ld  [ %i4 + 0x20 ], %g1                        
      rtems_fdisk_printf (fd, "  %3ld %s p:%3ld a:%3ld/%3ld" \        
                          " u:%3ld/%3ld e:%3ld/%3ld br:%ld",          
                          seg, queues,                                
                          sc->pages, sc->pages_active, active,        
                          sc->pages_used, used, erased,               
                          sc->pages - (sc->pages_active +             
400070a4:	da 07 20 1c 	ld  [ %i4 + 0x1c ], %o5                        
      {                                                               
        if (fd->blocks[block].segment == sc)                          
          count++;                                                    
      }                                                               
                                                                      
      rtems_fdisk_printf (fd, "  %3ld %s p:%3ld a:%3ld/%3ld" \        
400070a8:	c2 23 a0 60 	st  %g1, [ %sp + 0x60 ]                        
400070ac:	e8 23 a0 5c 	st  %l4, [ %sp + 0x5c ]                        
400070b0:	e6 23 a0 64 	st  %l3, [ %sp + 0x64 ]                        
400070b4:	e4 23 a0 68 	st  %l2, [ %sp + 0x68 ]                        
400070b8:	c6 07 20 24 	ld  [ %i4 + 0x24 ], %g3                        
400070bc:	82 00 40 0d 	add  %g1, %o5, %g1                             
400070c0:	82 00 40 03 	add  %g1, %g3, %g1                             
400070c4:	82 23 00 01 	sub  %o4, %g1, %g1                             
400070c8:	94 10 00 18 	mov  %i0, %o2                                  
400070cc:	c2 23 a0 6c 	st  %g1, [ %sp + 0x6c ]                        
400070d0:	c4 23 a0 70 	st  %g2, [ %sp + 0x70 ]                        
400070d4:	90 10 00 1d 	mov  %i5, %o0                                  
400070d8:	92 10 00 17 	mov  %l7, %o1                                  
400070dc:	96 07 bf f8 	add  %fp, -8, %o3                              
400070e0:	7f ff f7 8c 	call  40004f10 <rtems_fdisk_printf>            
400070e4:	b0 06 20 01 	inc  %i0                                       
400070e8:	10 bf ff 99 	b  40006f4c <rtems_fdisk_ioctl+0xe90>          
400070ec:	a0 04 20 30 	add  %l0, 0x30, %l0                            
  rtems_fdisk_printf (fd, "Queue total\t%ld of %ld, %s", total, count,
                      total == count ? "ok" : "MISSING");             
                                                                      
  rtems_fdisk_printf (fd, "Device count\t%d", fd->device_count);      
                                                                      
  for (device = 0; device < fd->device_count; device++)               
400070f0:	b2 06 60 01 	inc  %i1                                       
400070f4:	10 bf ff 85 	b  40006f08 <rtems_fdisk_ioctl+0xe4c>          
400070f8:	b4 06 a0 0c 	add  %i2, 0xc, %i2                             
                          count);                                     
    }                                                                 
  }                                                                   
                                                                      
  {                                                                   
    rtems_fdisk_segment_ctl* sc = fd->used.head;                      
400070fc:	f8 07 60 40 	ld  [ %i5 + 0x40 ], %i4                        
    int count = 0;                                                    
    rtems_fdisk_printf (fd, "Used List:");                            
40007100:	90 10 00 1d 	mov  %i5, %o0                                  
40007104:	13 10 00 cb 	sethi  %hi(0x40032c00), %o1                    
    while (sc)                                                        
    {                                                                 
      rtems_fdisk_printf (fd, "  %3d %02d:%03d u:%3ld",               
40007108:	33 10 00 cb 	sethi  %hi(0x40032c00), %i1                    
  }                                                                   
                                                                      
  {                                                                   
    rtems_fdisk_segment_ctl* sc = fd->used.head;                      
    int count = 0;                                                    
    rtems_fdisk_printf (fd, "Used List:");                            
4000710c:	92 12 60 90 	or  %o1, 0x90, %o1                             
40007110:	7f ff f7 80 	call  40004f10 <rtems_fdisk_printf>            
40007114:	b4 10 20 00 	clr  %i2                                       
    while (sc)                                                        
    {                                                                 
      rtems_fdisk_printf (fd, "  %3d %02d:%03d u:%3ld",               
40007118:	b2 16 60 a0 	or  %i1, 0xa0, %i1                             
                                                                      
  {                                                                   
    rtems_fdisk_segment_ctl* sc = fd->used.head;                      
    int count = 0;                                                    
    rtems_fdisk_printf (fd, "Used List:");                            
    while (sc)                                                        
4000711c:	80 a7 20 00 	cmp  %i4, 0                                    
40007120:	02 80 00 0b 	be  4000714c <rtems_fdisk_ioctl+0x1090>        
40007124:	94 10 00 1a 	mov  %i2, %o2                                  
    {                                                                 
      rtems_fdisk_printf (fd, "  %3d %02d:%03d u:%3ld",               
40007128:	d6 07 20 08 	ld  [ %i4 + 8 ], %o3                           
4000712c:	d8 07 20 0c 	ld  [ %i4 + 0xc ], %o4                         
40007130:	da 07 20 20 	ld  [ %i4 + 0x20 ], %o5                        
40007134:	90 10 00 1d 	mov  %i5, %o0                                  
40007138:	92 10 00 19 	mov  %i1, %o1                                  
4000713c:	7f ff f7 75 	call  40004f10 <rtems_fdisk_printf>            
40007140:	b4 06 a0 01 	inc  %i2                                       
                          count, sc->device, sc->segment, sc->pages_used);
      sc = sc->next;                                                  
40007144:	10 bf ff f6 	b  4000711c <rtems_fdisk_ioctl+0x1060>         
40007148:	f8 07 00 00 	ld  [ %i4 ], %i4                               
      count++;                                                        
    }                                                                 
  }                                                                   
  fd->info_level = current_info_level;                                
4000714c:	c2 07 bf f0 	ld  [ %fp + -16 ], %g1                         
40007150:	c2 27 60 6c 	st  %g1, [ %i5 + 0x6c ]                        
      case RTEMS_FDISK_IOCTL_INFO_LEVEL:                              
        rtems_flashdisks[minor].info_level = (uintptr_t) argp;        
        break;                                                        
                                                                      
      case RTEMS_FDISK_IOCTL_PRINT_STATUS:                            
        errno = rtems_fdisk_print_status (&rtems_flashdisks[minor]);  
40007154:	c4 07 bf f4 	ld  [ %fp + -12 ], %g2                         
        break;                                                        
40007158:	10 80 00 06 	b  40007170 <rtems_fdisk_ioctl+0x10b4>         
4000715c:	c0 20 80 00 	clr  [ %g2 ]                                   
                                                                      
      default:                                                        
        rtems_blkdev_ioctl (dd, req, argp);                           
40007160:	90 10 00 18 	mov  %i0, %o0                                  
40007164:	92 10 00 19 	mov  %i1, %o1                                  
40007168:	40 00 3a 77 	call  40015b44 <rtems_blkdev_ioctl>            
4000716c:	94 10 00 1a 	mov  %i2, %o2                                  
        break;                                                        
    }                                                                 
                                                                      
    sc = rtems_semaphore_release (rtems_flashdisks[minor].lock);      
40007170:	03 10 01 1f 	sethi  %hi(0x40047c00), %g1                    
40007174:	c2 00 63 a8 	ld  [ %g1 + 0x3a8 ], %g1	! 40047fa8 <rtems_flashdisks>
40007178:	b6 00 40 1b 	add  %g1, %i3, %i3                             
4000717c:	40 00 16 34 	call  4000ca4c <rtems_semaphore_release>       
40007180:	d0 06 e0 64 	ld  [ %i3 + 0x64 ], %o0                        
    if (sc != RTEMS_SUCCESSFUL)                                       
40007184:	80 a2 20 00 	cmp  %o0, 0                                    
40007188:	02 80 00 06 	be  400071a0 <rtems_fdisk_ioctl+0x10e4>        <== ALWAYS TAKEN
4000718c:	01 00 00 00 	nop                                            
      errno = EIO;                                                    
40007190:	40 00 67 43 	call  40020e9c <__errno>                       <== NOT EXECUTED
40007194:	01 00 00 00 	nop                                            <== NOT EXECUTED
40007198:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
4000719c:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return errno == 0 ? 0 : -1;                                         
400071a0:	40 00 67 3f 	call  40020e9c <__errno>                       
400071a4:	01 00 00 00 	nop                                            
400071a8:	c2 02 00 00 	ld  [ %o0 ], %g1                               
400071ac:	80 a0 00 01 	cmp  %g0, %g1                                  
400071b0:	b0 60 20 00 	subx  %g0, 0, %i0                              
400071b4:	81 c7 e0 08 	ret                                            
400071b8:	81 e8 00 00 	restore                                        
{                                                                     
  rtems_blkdev_sg_buffer* sg = req->bufs;                             
  uint32_t                buf;                                        
  int                     ret = 0;                                    
                                                                      
  for (buf = 0; (ret == 0) && (buf < req->bufnum); buf++, sg++)       
400071bc:	10 bf fc b7 	b  40006498 <rtems_fdisk_ioctl+0x3dc>          <== NOT EXECUTED
400071c0:	a2 04 60 01 	inc  %l1                                       <== NOT EXECUTED
                                                                      

400054f8 <rtems_fdisk_queue_segment>: * @param fd The flash disk control table. * @param sc The segment control table to be reallocated */ static void rtems_fdisk_queue_segment (rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc) {
400054f8:	9d e3 bf 90 	save  %sp, -112, %sp                           
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd, " queue-seg:%02d-%03d: p=%d a=%d u=%d b=%d f=%s n=%s",
400054fc:	c2 06 60 28 	ld  [ %i1 + 0x28 ], %g1                        
 * @param fd The flash disk control table.                            
 * @param sc The segment control table to be reallocated              
 */                                                                   
static void                                                           
rtems_fdisk_queue_segment (rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc)
{                                                                     
40005500:	ba 10 00 18 	mov  %i0, %i5                                  
40005504:	b4 10 00 19 	mov  %i1, %i2                                  
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_info (fd, " queue-seg:%02d-%03d: p=%d a=%d u=%d b=%d f=%s n=%s",
40005508:	d4 06 60 08 	ld  [ %i1 + 8 ], %o2                           
4000550c:	d6 06 60 0c 	ld  [ %i1 + 0xc ], %o3                         
40005510:	d8 06 60 14 	ld  [ %i1 + 0x14 ], %o4                        
40005514:	da 06 60 1c 	ld  [ %i1 + 0x1c ], %o5                        
40005518:	c8 06 60 20 	ld  [ %i1 + 0x20 ], %g4                        
4000551c:	80 a0 60 00 	cmp  %g1, 0                                    
40005520:	02 80 00 05 	be  40005534 <rtems_fdisk_queue_segment+0x3c>  <== ALWAYS TAKEN
40005524:	c6 06 60 24 	ld  [ %i1 + 0x24 ], %g3                        
40005528:	05 10 00 c8 	sethi  %hi(0x40032000), %g2                    <== NOT EXECUTED
4000552c:	10 80 00 04 	b  4000553c <rtems_fdisk_queue_segment+0x44>   <== NOT EXECUTED
40005530:	84 10 a2 98 	or  %g2, 0x298, %g2	! 40032298 <__FUNCTION__.6501+0x230><== NOT EXECUTED
40005534:	05 10 00 c8 	sethi  %hi(0x40032000), %g2                    
40005538:	84 10 a2 a0 	or  %g2, 0x2a0, %g2	! 400322a0 <__FUNCTION__.6501+0x238>
4000553c:	c2 06 80 00 	ld  [ %i2 ], %g1                               
40005540:	80 a0 60 00 	cmp  %g1, 0                                    
40005544:	02 80 00 04 	be  40005554 <rtems_fdisk_queue_segment+0x5c>  
40005548:	03 10 00 c8 	sethi  %hi(0x40032000), %g1                    
4000554c:	10 80 00 04 	b  4000555c <rtems_fdisk_queue_segment+0x64>   
40005550:	82 10 62 a8 	or  %g1, 0x2a8, %g1	! 400322a8 <__FUNCTION__.6501+0x240>
40005554:	03 10 00 c8 	sethi  %hi(0x40032000), %g1                    
40005558:	82 10 62 b0 	or  %g1, 0x2b0, %g1	! 400322b0 <__FUNCTION__.6501+0x248>
4000555c:	c2 23 a0 68 	st  %g1, [ %sp + 0x68 ]                        
40005560:	c8 23 a0 5c 	st  %g4, [ %sp + 0x5c ]                        
40005564:	c6 23 a0 60 	st  %g3, [ %sp + 0x60 ]                        
40005568:	c4 23 a0 64 	st  %g2, [ %sp + 0x64 ]                        
4000556c:	90 10 00 1d 	mov  %i5, %o0                                  
40005570:	13 10 00 c8 	sethi  %hi(0x40032000), %o1                    
40005574:	7f ff fe 88 	call  40004f94 <rtems_fdisk_info>              
40005578:	92 12 62 b8 	or  %o1, 0x2b8, %o1	! 400322b8 <__FUNCTION__.6501+0x250>
                                                                      
  /*                                                                  
   * If the segment has failed then check the failed queue and append 
   * if not failed.                                                   
   */                                                                 
  if (sc->failed)                                                     
4000557c:	c2 06 a0 28 	ld  [ %i2 + 0x28 ], %g1                        
40005580:	80 a0 60 00 	cmp  %g1, 0                                    
40005584:	22 80 00 0a 	be,a   400055ac <rtems_fdisk_queue_segment+0xb4><== ALWAYS TAKEN
40005588:	92 10 00 1a 	mov  %i2, %o1                                  
  {                                                                   
    if (!rtems_fdisk_segment_queue_present (&fd->failed, sc))         
4000558c:	c2 07 60 58 	ld  [ %i5 + 0x58 ], %g1                        <== NOT EXECUTED
rtems_fdisk_segment_queue_present (rtems_fdisk_segment_ctl_queue* queue,
                                   rtems_fdisk_segment_ctl*       sc) 
{                                                                     
  rtems_fdisk_segment_ctl*  it = queue->head;                         
                                                                      
  while (it)                                                          
40005590:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40005594:	02 80 00 31 	be  40005658 <rtems_fdisk_queue_segment+0x160> <== NOT EXECUTED
40005598:	80 a0 40 1a 	cmp  %g1, %i2                                  <== NOT EXECUTED
  {                                                                   
    if (it == sc)                                                     
4000559c:	02 80 00 35 	be  40005670 <rtems_fdisk_queue_segment+0x178> <== NOT EXECUTED
400055a0:	01 00 00 00 	nop                                            <== NOT EXECUTED
      return true;                                                    
    it = it->next;                                                    
400055a4:	10 bf ff fb 	b  40005590 <rtems_fdisk_queue_segment+0x98>   <== NOT EXECUTED
400055a8:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * Remove the queue from the available or used queue.               
   */                                                                 
  rtems_fdisk_segment_queue_remove (&fd->available, sc);              
400055ac:	b8 07 60 34 	add  %i5, 0x34, %i4                            
400055b0:	7f ff fe 02 	call  40004db8 <rtems_fdisk_segment_queue_remove>
400055b4:	90 10 00 1c 	mov  %i4, %o0                                  
  rtems_fdisk_segment_queue_remove (&fd->used, sc);                   
400055b8:	92 10 00 1a 	mov  %i2, %o1                                  
400055bc:	b0 07 60 40 	add  %i5, 0x40, %i0                            
400055c0:	7f ff fd fe 	call  40004db8 <rtems_fdisk_segment_queue_remove>
400055c4:	90 10 00 18 	mov  %i0, %o0                                  
   * If they are and the driver has been configured to background     
   * erase place the segment on the used queue. If not configured     
   * to background erase perform the erase now.                       
   *                                                                  
   */                                                                 
  if (rtems_fdisk_seg_pages_available (sc) == 0)                      
400055c8:	7f ff fe 38 	call  40004ea8 <rtems_fdisk_seg_pages_available>
400055cc:	90 10 00 1a 	mov  %i2, %o0                                  
400055d0:	b6 92 20 00 	orcc  %o0, 0, %i3                              
400055d4:	32 80 00 17 	bne,a   40005630 <rtems_fdisk_queue_segment+0x138>
400055d8:	f2 07 60 34 	ld  [ %i5 + 0x34 ], %i1                        
  {                                                                   
    if (sc->pages_active)                                             
400055dc:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
400055e0:	80 a0 60 00 	cmp  %g1, 0                                    
400055e4:	22 80 00 0d 	be,a   40005618 <rtems_fdisk_queue_segment+0x120><== NEVER TAKEN
400055e8:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           <== NOT EXECUTED
      /*                                                              
       * Keep the used queue sorted by the most number of used        
       * pages. When we compact we want to move the pages into        
       * a new segment and cover more than one segment.               
       */                                                             
      rtems_fdisk_segment_ctl* seg = fd->used.head;                   
400055ec:	f2 07 60 40 	ld  [ %i5 + 0x40 ], %i1                        
                                                                      
      while (seg)                                                     
400055f0:	80 a6 60 00 	cmp  %i1, 0                                    
400055f4:	02 80 00 1d 	be  40005668 <rtems_fdisk_queue_segment+0x170> 
400055f8:	01 00 00 00 	nop                                            
      {                                                               
        if (sc->pages_used > seg->pages_used)                         
400055fc:	c4 06 a0 20 	ld  [ %i2 + 0x20 ], %g2                        
40005600:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40005604:	80 a0 80 01 	cmp  %g2, %g1                                  
40005608:	18 80 00 16 	bgu  40005660 <rtems_fdisk_queue_segment+0x168>
4000560c:	01 00 00 00 	nop                                            
          break;                                                      
        seg = seg->next;                                              
40005610:	10 bf ff f8 	b  400055f0 <rtems_fdisk_queue_segment+0xf8>   
40005614:	f2 06 40 00 	ld  [ %i1 ], %i1                               
      else                                                            
        rtems_fdisk_segment_queue_push_tail (&fd->used, sc);          
    }                                                                 
    else                                                              
    {                                                                 
      if ((fd->flags & RTEMS_FDISK_BACKGROUND_ERASE))                 
40005618:	80 88 60 01 	btst  1, %g1                                   <== NOT EXECUTED
4000561c:	12 80 00 13 	bne  40005668 <rtems_fdisk_queue_segment+0x170><== NOT EXECUTED
40005620:	b0 07 60 4c 	add  %i5, 0x4c, %i0                            <== NOT EXECUTED
        rtems_fdisk_segment_queue_push_tail (&fd->erase, sc);         
      else                                                            
        rtems_fdisk_erase_segment (fd, sc);                           
40005624:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
40005628:	7f ff ff 6e 	call  400053e0 <rtems_fdisk_erase_segment>     <== NOT EXECUTED
4000562c:	93 e8 00 1a 	restore  %g0, %i2, %o1                         <== NOT EXECUTED
     * with all the counters updated with the number of               
     * bits cleared and all bits set back to 1.                       
     */                                                               
    rtems_fdisk_segment_ctl* seg = fd->available.head;                
                                                                      
    while (seg)                                                       
40005630:	80 a6 60 00 	cmp  %i1, 0                                    
40005634:	02 80 00 0d 	be  40005668 <rtems_fdisk_queue_segment+0x170> 
40005638:	b0 10 00 1c 	mov  %i4, %i0                                  
    {                                                                 
      if (rtems_fdisk_seg_pages_available (sc) <                      
          rtems_fdisk_seg_pages_available (seg))                      
4000563c:	7f ff fe 1b 	call  40004ea8 <rtems_fdisk_seg_pages_available>
40005640:	90 10 00 19 	mov  %i1, %o0                                  
     */                                                               
    rtems_fdisk_segment_ctl* seg = fd->available.head;                
                                                                      
    while (seg)                                                       
    {                                                                 
      if (rtems_fdisk_seg_pages_available (sc) <                      
40005644:	80 a6 c0 08 	cmp  %i3, %o0                                  
40005648:	0a 80 00 06 	bcs  40005660 <rtems_fdisk_queue_segment+0x168>
4000564c:	b0 10 00 1c 	mov  %i4, %i0                                  
          rtems_fdisk_seg_pages_available (seg))                      
        break;                                                        
      seg = seg->next;                                                
40005650:	10 bf ff f8 	b  40005630 <rtems_fdisk_queue_segment+0x138>  
40005654:	f2 06 40 00 	ld  [ %i1 ], %i1                               
   * if not failed.                                                   
   */                                                                 
  if (sc->failed)                                                     
  {                                                                   
    if (!rtems_fdisk_segment_queue_present (&fd->failed, sc))         
      rtems_fdisk_segment_queue_push_tail (&fd->failed, sc);          
40005658:	10 80 00 04 	b  40005668 <rtems_fdisk_queue_segment+0x170>  <== NOT EXECUTED
4000565c:	b0 07 60 58 	add  %i5, 0x58, %i0                            <== NOT EXECUTED
        break;                                                        
      seg = seg->next;                                                
    }                                                                 
                                                                      
    if (seg)                                                          
      rtems_fdisk_segment_queue_insert_before (&fd->available, seg, sc);
40005660:	7f ff fd f3 	call  40004e2c <rtems_fdisk_segment_queue_insert_before>
40005664:	81 e8 00 00 	restore                                        
    else                                                              
      rtems_fdisk_segment_queue_push_tail (&fd->available, sc);       
40005668:	7f ff fd c2 	call  40004d70 <rtems_fdisk_segment_queue_push_tail>
4000566c:	93 e8 00 1a 	restore  %g0, %i2, %o1                         
40005670:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005674:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40006014 <rtems_fdisk_queue_status>: static void rtems_fdisk_queue_status (rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc, char queues[5]) { queues[0] = rtems_fdisk_segment_queue_present (&fd->available, sc) ? 'A' : '-';
40006014:	c2 02 20 34 	ld  [ %o0 + 0x34 ], %g1                        
rtems_fdisk_segment_queue_present (rtems_fdisk_segment_ctl_queue* queue,
                                   rtems_fdisk_segment_ctl*       sc) 
{                                                                     
  rtems_fdisk_segment_ctl*  it = queue->head;                         
                                                                      
  while (it)                                                          
40006018:	80 a0 60 00 	cmp  %g1, 0                                    
4000601c:	02 80 00 06 	be  40006034 <rtems_fdisk_queue_status+0x20>   
40006020:	80 a0 40 09 	cmp  %g1, %o1                                  
  {                                                                   
    if (it == sc)                                                     
40006024:	22 80 00 05 	be,a   40006038 <rtems_fdisk_queue_status+0x24>
40006028:	82 10 20 41 	mov  0x41, %g1                                 
      return true;                                                    
    it = it->next;                                                    
4000602c:	10 bf ff fb 	b  40006018 <rtems_fdisk_queue_status+0x4>     
40006030:	c2 00 40 00 	ld  [ %g1 ], %g1                               
40006034:	82 10 20 2d 	mov  0x2d, %g1                                 
static void                                                           
rtems_fdisk_queue_status (rtems_flashdisk*         fd,                
                          rtems_fdisk_segment_ctl* sc,                
                          char                     queues[5])         
{                                                                     
  queues[0] = rtems_fdisk_segment_queue_present (&fd->available, sc) ? 'A' : '-';
40006038:	c2 2a 80 00 	stb  %g1, [ %o2 ]                              
  queues[1] = rtems_fdisk_segment_queue_present (&fd->used, sc)      ? 'U' : '-';
4000603c:	c2 02 20 40 	ld  [ %o0 + 0x40 ], %g1                        
rtems_fdisk_segment_queue_present (rtems_fdisk_segment_ctl_queue* queue,
                                   rtems_fdisk_segment_ctl*       sc) 
{                                                                     
  rtems_fdisk_segment_ctl*  it = queue->head;                         
                                                                      
  while (it)                                                          
40006040:	80 a0 60 00 	cmp  %g1, 0                                    
40006044:	02 80 00 06 	be  4000605c <rtems_fdisk_queue_status+0x48>   
40006048:	80 a0 40 09 	cmp  %g1, %o1                                  
  {                                                                   
    if (it == sc)                                                     
4000604c:	22 80 00 05 	be,a   40006060 <rtems_fdisk_queue_status+0x4c>
40006050:	82 10 20 55 	mov  0x55, %g1                                 
      return true;                                                    
    it = it->next;                                                    
40006054:	10 bf ff fb 	b  40006040 <rtems_fdisk_queue_status+0x2c>    
40006058:	c2 00 40 00 	ld  [ %g1 ], %g1                               
4000605c:	82 10 20 2d 	mov  0x2d, %g1                                 
rtems_fdisk_queue_status (rtems_flashdisk*         fd,                
                          rtems_fdisk_segment_ctl* sc,                
                          char                     queues[5])         
{                                                                     
  queues[0] = rtems_fdisk_segment_queue_present (&fd->available, sc) ? 'A' : '-';
  queues[1] = rtems_fdisk_segment_queue_present (&fd->used, sc)      ? 'U' : '-';
40006060:	c2 2a a0 01 	stb  %g1, [ %o2 + 1 ]                          
  queues[2] = rtems_fdisk_segment_queue_present (&fd->erase, sc)     ? 'E' : '-';
40006064:	c2 02 20 4c 	ld  [ %o0 + 0x4c ], %g1                        
rtems_fdisk_segment_queue_present (rtems_fdisk_segment_ctl_queue* queue,
                                   rtems_fdisk_segment_ctl*       sc) 
{                                                                     
  rtems_fdisk_segment_ctl*  it = queue->head;                         
                                                                      
  while (it)                                                          
40006068:	80 a0 60 00 	cmp  %g1, 0                                    
4000606c:	02 80 00 06 	be  40006084 <rtems_fdisk_queue_status+0x70>   <== ALWAYS TAKEN
40006070:	80 a0 40 09 	cmp  %g1, %o1                                  
  {                                                                   
    if (it == sc)                                                     
40006074:	22 80 00 05 	be,a   40006088 <rtems_fdisk_queue_status+0x74><== NOT EXECUTED
40006078:	82 10 20 45 	mov  0x45, %g1                                 <== NOT EXECUTED
      return true;                                                    
    it = it->next;                                                    
4000607c:	10 bf ff fb 	b  40006068 <rtems_fdisk_queue_status+0x54>    <== NOT EXECUTED
40006080:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
40006084:	82 10 20 2d 	mov  0x2d, %g1                                 
                          rtems_fdisk_segment_ctl* sc,                
                          char                     queues[5])         
{                                                                     
  queues[0] = rtems_fdisk_segment_queue_present (&fd->available, sc) ? 'A' : '-';
  queues[1] = rtems_fdisk_segment_queue_present (&fd->used, sc)      ? 'U' : '-';
  queues[2] = rtems_fdisk_segment_queue_present (&fd->erase, sc)     ? 'E' : '-';
40006088:	c2 2a a0 02 	stb  %g1, [ %o2 + 2 ]                          
  queues[3] = rtems_fdisk_segment_queue_present (&fd->failed, sc)    ? 'F' : '-';
4000608c:	c2 02 20 58 	ld  [ %o0 + 0x58 ], %g1                        
rtems_fdisk_segment_queue_present (rtems_fdisk_segment_ctl_queue* queue,
                                   rtems_fdisk_segment_ctl*       sc) 
{                                                                     
  rtems_fdisk_segment_ctl*  it = queue->head;                         
                                                                      
  while (it)                                                          
40006090:	80 a0 60 00 	cmp  %g1, 0                                    
40006094:	02 80 00 06 	be  400060ac <rtems_fdisk_queue_status+0x98>   <== ALWAYS TAKEN
40006098:	80 a0 40 09 	cmp  %g1, %o1                                  
  {                                                                   
    if (it == sc)                                                     
4000609c:	22 80 00 05 	be,a   400060b0 <rtems_fdisk_queue_status+0x9c><== NOT EXECUTED
400060a0:	82 10 20 46 	mov  0x46, %g1                                 <== NOT EXECUTED
      return true;                                                    
    it = it->next;                                                    
400060a4:	10 bf ff fb 	b  40006090 <rtems_fdisk_queue_status+0x7c>    <== NOT EXECUTED
400060a8:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
400060ac:	82 10 20 2d 	mov  0x2d, %g1                                 
                          char                     queues[5])         
{                                                                     
  queues[0] = rtems_fdisk_segment_queue_present (&fd->available, sc) ? 'A' : '-';
  queues[1] = rtems_fdisk_segment_queue_present (&fd->used, sc)      ? 'U' : '-';
  queues[2] = rtems_fdisk_segment_queue_present (&fd->erase, sc)     ? 'E' : '-';
  queues[3] = rtems_fdisk_segment_queue_present (&fd->failed, sc)    ? 'F' : '-';
400060b0:	c2 2a a0 03 	stb  %g1, [ %o2 + 3 ]                          
  queues[4] = '\0';                                                   
400060b4:	81 c3 e0 08 	retl                                           
400060b8:	c0 2a a0 04 	clrb  [ %o2 + 4 ]                              
                                                                      

40005678 <rtems_fdisk_recover_block_mappings>: /** * Recover the block mappings from the devices. */ static int rtems_fdisk_recover_block_mappings (rtems_flashdisk* fd) {
40005678:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_fdisk_segment_queue_init (&fd->failed);                       
                                                                      
  /*                                                                  
   * Clear the lock mappings.                                         
   */                                                                 
  memset (fd->blocks, 0, fd->block_count * sizeof (rtems_fdisk_block_ctl));
4000567c:	d4 06 20 1c 	ld  [ %i0 + 0x1c ], %o2                        
40005680:	d0 06 20 18 	ld  [ %i0 + 0x18 ], %o0                        
 * Initialise the segment control queue.                              
 */                                                                   
static void                                                           
rtems_fdisk_segment_queue_init (rtems_fdisk_segment_ctl_queue* queue) 
{                                                                     
  queue->head = queue->tail = 0;                                      
40005684:	c0 26 20 38 	clr  [ %i0 + 0x38 ]                            
40005688:	c0 26 20 34 	clr  [ %i0 + 0x34 ]                            
  queue->count = 0;                                                   
4000568c:	c0 26 20 3c 	clr  [ %i0 + 0x3c ]                            
 * Initialise the segment control queue.                              
 */                                                                   
static void                                                           
rtems_fdisk_segment_queue_init (rtems_fdisk_segment_ctl_queue* queue) 
{                                                                     
  queue->head = queue->tail = 0;                                      
40005690:	c0 26 20 44 	clr  [ %i0 + 0x44 ]                            
40005694:	c0 26 20 40 	clr  [ %i0 + 0x40 ]                            
  queue->count = 0;                                                   
40005698:	c0 26 20 48 	clr  [ %i0 + 0x48 ]                            
 * Initialise the segment control queue.                              
 */                                                                   
static void                                                           
rtems_fdisk_segment_queue_init (rtems_fdisk_segment_ctl_queue* queue) 
{                                                                     
  queue->head = queue->tail = 0;                                      
4000569c:	c0 26 20 50 	clr  [ %i0 + 0x50 ]                            
400056a0:	c0 26 20 4c 	clr  [ %i0 + 0x4c ]                            
  queue->count = 0;                                                   
400056a4:	c0 26 20 54 	clr  [ %i0 + 0x54 ]                            
 * Initialise the segment control queue.                              
 */                                                                   
static void                                                           
rtems_fdisk_segment_queue_init (rtems_fdisk_segment_ctl_queue* queue) 
{                                                                     
  queue->head = queue->tail = 0;                                      
400056a8:	c0 26 20 5c 	clr  [ %i0 + 0x5c ]                            
400056ac:	c0 26 20 58 	clr  [ %i0 + 0x58 ]                            
  queue->count = 0;                                                   
400056b0:	c0 26 20 60 	clr  [ %i0 + 0x60 ]                            
  rtems_fdisk_segment_queue_init (&fd->failed);                       
                                                                      
  /*                                                                  
   * Clear the lock mappings.                                         
   */                                                                 
  memset (fd->blocks, 0, fd->block_count * sizeof (rtems_fdisk_block_ctl));
400056b4:	92 10 20 00 	clr  %o1                                       
400056b8:	95 2a a0 03 	sll  %o2, 3, %o2                               
400056bc:	40 00 72 7a 	call  400220a4 <memset>                        
400056c0:	25 10 00 c8 	sethi  %hi(0x40032000), %l2                    
               * each block so we can tell which is the later block when
               * duplicates appear. A power down with a failed wirte could cause
               * a duplicate.                                         
               */                                                     
              const rtems_fdisk_segment_ctl* bsc = fd->blocks[pd->block].segment;
              rtems_fdisk_error ("duplicate block: %d-%d-%d: " \      
400056c4:	27 10 00 c8 	sethi  %hi(0x40032000), %l3                    
          else if (rtems_fdisk_page_desc_flags_set (pd, RTEMS_FDISK_PAGE_ACTIVE))
          {                                                           
            if (pd->block >= fd->block_count)                         
            {                                                         
#if RTEMS_FDISK_TRACE                                                 
              rtems_fdisk_warning (fd,                                
400056c8:	29 10 00 c8 	sethi  %hi(0x40032000), %l4                    
            ++fd->erased_blocks;                                      
          }                                                           
          else                                                        
          {                                                           
#if RTEMS_FDISK_TRACE                                                 
            rtems_fdisk_warning (fd, "page not blank: %d-%d-%d",      
400056cc:	2b 10 00 c8 	sethi  %hi(0x40032000), %l5                    
            ret = rtems_fdisk_seg_write_page_desc (fd, sc,            
                                                   page, pd);         
                                                                      
            if (ret)                                                  
            {                                                         
              rtems_fdisk_error ("forcing page to used failed: %d-%d-%d",
400056d0:	2d 10 00 c8 	sethi  %hi(0x40032000), %l6                    
  memset (fd->blocks, 0, fd->block_count * sizeof (rtems_fdisk_block_ctl));
                                                                      
  /*                                                                  
   * Scan each segment or each device recovering the valid pages.     
   */                                                                 
  fd->erased_blocks = 0;                                              
400056d4:	c0 26 20 28 	clr  [ %i0 + 0x28 ]                            
  fd->starvation_threshold = 0;                                       
400056d8:	c0 26 20 24 	clr  [ %i0 + 0x24 ]                            
  for (device = 0; device < fd->device_count; device++)               
400056dc:	a0 10 20 00 	clr  %l0                                       
400056e0:	b2 10 20 00 	clr  %i1                                       
      rtems_fdisk_page_desc*          pd;                             
      uint32_t                        page;                           
      int                             ret;                            
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "recover-block-mappings:%02d-%03d", device, segment);
400056e4:	a4 14 a2 f0 	or  %l2, 0x2f0, %l2                            
               * each block so we can tell which is the later block when
               * duplicates appear. A power down with a failed wirte could cause
               * a duplicate.                                         
               */                                                     
              const rtems_fdisk_segment_ctl* bsc = fd->blocks[pd->block].segment;
              rtems_fdisk_error ("duplicate block: %d-%d-%d: " \      
400056e8:	a6 14 e3 d8 	or  %l3, 0x3d8, %l3                            
          else if (rtems_fdisk_page_desc_flags_set (pd, RTEMS_FDISK_PAGE_ACTIVE))
          {                                                           
            if (pd->block >= fd->block_count)                         
            {                                                         
#if RTEMS_FDISK_TRACE                                                 
              rtems_fdisk_warning (fd,                                
400056ec:	a8 15 23 a8 	or  %l4, 0x3a8, %l4                            
            ++fd->erased_blocks;                                      
          }                                                           
          else                                                        
          {                                                           
#if RTEMS_FDISK_TRACE                                                 
            rtems_fdisk_warning (fd, "page not blank: %d-%d-%d",      
400056f0:	aa 15 63 60 	or  %l5, 0x360, %l5                            
            ret = rtems_fdisk_seg_write_page_desc (fd, sc,            
                                                   page, pd);         
                                                                      
            if (ret)                                                  
            {                                                         
              rtems_fdisk_error ("forcing page to used failed: %d-%d-%d",
400056f4:	ac 15 a3 80 	or  %l6, 0x380, %l6                            
  /*                                                                  
   * Scan each segment or each device recovering the valid pages.     
   */                                                                 
  fd->erased_blocks = 0;                                              
  fd->starvation_threshold = 0;                                       
  for (device = 0; device < fd->device_count; device++)               
400056f8:	c2 06 20 30 	ld  [ %i0 + 0x30 ], %g1                        
400056fc:	80 a6 40 01 	cmp  %i1, %g1                                  
40005700:	1a 80 00 b5 	bcc  400059d4 <rtems_fdisk_recover_block_mappings+0x35c>
40005704:	a2 10 20 00 	clr  %l1                                       
40005708:	b4 10 20 00 	clr  %i2                                       
  {                                                                   
    uint32_t segment;                                                 
    for (segment = 0; segment < fd->devices[device].segment_count; segment++)
4000570c:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
40005710:	84 00 40 10 	add  %g1, %l0, %g2                             
40005714:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
40005718:	80 a6 80 02 	cmp  %i2, %g2                                  
4000571c:	1a 80 00 ab 	bcc  400059c8 <rtems_fdisk_recover_block_mappings+0x350>
40005720:	94 10 00 19 	mov  %i1, %o2                                  
    {                                                                 
      rtems_fdisk_segment_ctl*        sc = &fd->devices[device].segments[segment];
40005724:	fa 00 40 10 	ld  [ %g1 + %l0 ], %i5                         
40005728:	ba 07 40 11 	add  %i5, %l1, %i5                             
      const rtems_fdisk_segment_desc* sd = sc->descriptor;            
4000572c:	f8 07 60 04 	ld  [ %i5 + 4 ], %i4                           
      rtems_fdisk_page_desc*          pd;                             
      uint32_t                        page;                           
      int                             ret;                            
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "recover-block-mappings:%02d-%03d", device, segment);
40005730:	96 10 00 1a 	mov  %i2, %o3                                  
40005734:	92 10 00 12 	mov  %l2, %o1                                  
40005738:	7f ff fe 17 	call  40004f94 <rtems_fdisk_info>              
4000573c:	90 10 00 18 	mov  %i0, %o0                                  
 */                                                                   
static uint32_t                                                       
rtems_fdisk_pages_in_segment (const rtems_fdisk_segment_desc* sd,     
                              uint32_t                        page_size)
{                                                                     
  return sd->size / page_size;                                        
40005740:	d0 07 20 08 	ld  [ %i4 + 8 ], %o0                           
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "recover-block-mappings:%02d-%03d", device, segment);
#endif                                                                
                                                                      
      sc->pages_desc = rtems_fdisk_page_desc_pages (sd, fd->block_size);
40005744:	f6 06 20 14 	ld  [ %i0 + 0x14 ], %i3                        
 */                                                                   
static uint32_t                                                       
rtems_fdisk_pages_in_segment (const rtems_fdisk_segment_desc* sd,     
                              uint32_t                        page_size)
{                                                                     
  return sd->size / page_size;                                        
40005748:	7f ff f3 c3 	call  40002654 <.udiv>                         
4000574c:	92 10 00 1b 	mov  %i3, %o1                                  
rtems_fdisk_page_desc_pages (const rtems_fdisk_segment_desc* sd,      
                             uint32_t                        page_size)
{                                                                     
  uint32_t pages = rtems_fdisk_pages_in_segment (sd, page_size);      
  uint32_t bytes = pages * sizeof (rtems_fdisk_page_desc);            
  return ((bytes - 1) / page_size) + 1;                               
40005750:	92 10 00 1b 	mov  %i3, %o1                                  
 */                                                                   
static uint32_t                                                       
rtems_fdisk_pages_in_segment (const rtems_fdisk_segment_desc* sd,     
                              uint32_t                        page_size)
{                                                                     
  return sd->size / page_size;                                        
40005754:	b8 10 00 08 	mov  %o0, %i4                                  
static uint32_t                                                       
rtems_fdisk_page_desc_pages (const rtems_fdisk_segment_desc* sd,      
                             uint32_t                        page_size)
{                                                                     
  uint32_t pages = rtems_fdisk_pages_in_segment (sd, page_size);      
  uint32_t bytes = pages * sizeof (rtems_fdisk_page_desc);            
40005758:	91 2a 20 03 	sll  %o0, 3, %o0                               
  return ((bytes - 1) / page_size) + 1;                               
4000575c:	7f ff f3 be 	call  40002654 <.udiv>                         
40005760:	90 02 3f ff 	add  %o0, -1, %o0                              
#endif                                                                
                                                                      
      sc->pages_desc = rtems_fdisk_page_desc_pages (sd, fd->block_size);
      sc->pages =                                                     
        rtems_fdisk_pages_in_segment (sd, fd->block_size) - sc->pages_desc;
      if (sc->pages > fd->starvation_threshold)                       
40005764:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
rtems_fdisk_page_desc_pages (const rtems_fdisk_segment_desc* sd,      
                             uint32_t                        page_size)
{                                                                     
  uint32_t pages = rtems_fdisk_pages_in_segment (sd, page_size);      
  uint32_t bytes = pages * sizeof (rtems_fdisk_page_desc);            
  return ((bytes - 1) / page_size) + 1;                               
40005768:	ae 02 20 01 	add  %o0, 1, %l7                               
      rtems_fdisk_info (fd, "recover-block-mappings:%02d-%03d", device, segment);
#endif                                                                
                                                                      
      sc->pages_desc = rtems_fdisk_page_desc_pages (sd, fd->block_size);
      sc->pages =                                                     
        rtems_fdisk_pages_in_segment (sd, fd->block_size) - sc->pages_desc;
4000576c:	90 27 00 17 	sub  %i4, %l7, %o0                             
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "recover-block-mappings:%02d-%03d", device, segment);
#endif                                                                
                                                                      
      sc->pages_desc = rtems_fdisk_page_desc_pages (sd, fd->block_size);
40005770:	ee 27 60 18 	st  %l7, [ %i5 + 0x18 ]                        
      sc->pages =                                                     
        rtems_fdisk_pages_in_segment (sd, fd->block_size) - sc->pages_desc;
      if (sc->pages > fd->starvation_threshold)                       
40005774:	80 a2 00 01 	cmp  %o0, %g1                                  
40005778:	08 80 00 03 	bleu  40005784 <rtems_fdisk_recover_block_mappings+0x10c>
4000577c:	d0 27 60 14 	st  %o0, [ %i5 + 0x14 ]                        
        fd->starvation_threshold = sc->pages;                         
40005780:	d0 26 20 24 	st  %o0, [ %i0 + 0x24 ]                        
      sc->pages_used   = 0;                                           
      sc->pages_bad    = 0;                                           
                                                                      
      sc->failed = false;                                             
                                                                      
      if (!sc->page_descriptors)                                      
40005784:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
      sc->pages =                                                     
        rtems_fdisk_pages_in_segment (sd, fd->block_size) - sc->pages_desc;
      if (sc->pages > fd->starvation_threshold)                       
        fd->starvation_threshold = sc->pages;                         
                                                                      
      sc->pages_active = 0;                                           
40005788:	c0 27 60 1c 	clr  [ %i5 + 0x1c ]                            
      sc->pages_used   = 0;                                           
4000578c:	c0 27 60 20 	clr  [ %i5 + 0x20 ]                            
      sc->pages_bad    = 0;                                           
40005790:	c0 27 60 24 	clr  [ %i5 + 0x24 ]                            
                                                                      
      sc->failed = false;                                             
                                                                      
      if (!sc->page_descriptors)                                      
40005794:	80 a0 60 00 	cmp  %g1, 0                                    
40005798:	12 80 00 08 	bne  400057b8 <rtems_fdisk_recover_block_mappings+0x140><== NEVER TAKEN
4000579c:	c0 27 60 28 	clr  [ %i5 + 0x28 ]                            
        sc->page_descriptors = malloc (sc->pages_desc * fd->block_size);
400057a0:	92 10 00 1b 	mov  %i3, %o1                                  
400057a4:	7f ff f3 72 	call  4000256c <.umul>                         
400057a8:	90 10 00 17 	mov  %l7, %o0                                  
400057ac:	40 00 0b 6e 	call  40008564 <malloc>                        
400057b0:	01 00 00 00 	nop                                            
400057b4:	d0 27 60 10 	st  %o0, [ %i5 + 0x10 ]                        
                                                                      
      if (!sc->page_descriptors)                                      
400057b8:	f8 07 60 10 	ld  [ %i5 + 0x10 ], %i4                        
400057bc:	80 a7 20 00 	cmp  %i4, 0                                    
400057c0:	12 80 00 05 	bne  400057d4 <rtems_fdisk_recover_block_mappings+0x15c><== ALWAYS TAKEN
400057c4:	92 10 00 1b 	mov  %i3, %o1                                  
        rtems_fdisk_abort ("no memory for page descriptors");         
400057c8:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
400057cc:	7f ff fe 6c 	call  4000517c <rtems_fdisk_abort.constprop.9> <== NOT EXECUTED
400057d0:	90 12 21 c8 	or  %o0, 0x1c8, %o0	! 400321c8 <__FUNCTION__.6501+0x160><== NOT EXECUTED
       * descriptors.                                                 
       *                                                              
       * @todo It may be better to ask the driver to get these value  
       *       so NAND flash could be better supported.               
       */                                                             
      ret = rtems_fdisk_seg_read (fd, sc, 0, (void*) pd,              
400057d4:	7f ff f3 66 	call  4000256c <.umul>                         
400057d8:	90 10 00 17 	mov  %l7, %o0                                  
400057dc:	92 10 00 1d 	mov  %i5, %o1                                  
400057e0:	98 10 00 08 	mov  %o0, %o4                                  
400057e4:	94 10 20 00 	clr  %o2                                       
400057e8:	90 10 00 18 	mov  %i0, %o0                                  
400057ec:	7f ff fe a4 	call  4000527c <rtems_fdisk_seg_read>          
400057f0:	96 10 00 1c 	mov  %i4, %o3                                  
                                  sc->pages_desc * fd->block_size);   
                                                                      
      if (ret)                                                        
400057f4:	b6 92 20 00 	orcc  %o0, 0, %i3                              
400057f8:	22 80 00 25 	be,a   4000588c <rtems_fdisk_recover_block_mappings+0x214><== ALWAYS TAKEN
400057fc:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
      {                                                               
        rtems_fdisk_error ("recover-block-mappings:%02d-%03d: " \     
40005800:	40 00 76 e3 	call  4002338c <strerror>                      <== NOT EXECUTED
40005804:	b0 10 00 1b 	mov  %i3, %i0                                  <== NOT EXECUTED
40005808:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4000580c:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
40005810:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
40005814:	98 10 00 1b 	mov  %i3, %o4                                  <== NOT EXECUTED
40005818:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
4000581c:	7f ff fe 20 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005820:	90 12 23 18 	or  %o0, 0x318, %o0	! 40032318 <__FUNCTION__.6501+0x2b0><== NOT EXECUTED
                           "read page desc failed: %s (%d)",          
                           device, segment, strerror (ret), ret);     
        return ret;                                                   
40005824:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005828:	81 e8 00 00 	restore                                        <== NOT EXECUTED
       * If the page is active see if the block is with-in range and  
       * if the block is a duplicate.                                 
       */                                                             
      for (page = 0; page < sc->pages; page++, pd++)                  
      {                                                               
        if (rtems_fdisk_page_desc_erased (pd))                        
4000582c:	7f ff fd 95 	call  40004e80 <rtems_fdisk_page_desc_erased>  
40005830:	90 10 00 1c 	mov  %i4, %o0                                  
40005834:	80 a2 20 00 	cmp  %o0, 0                                    
40005838:	22 80 00 32 	be,a   40005900 <rtems_fdisk_recover_block_mappings+0x288><== NEVER TAKEN
4000583c:	c2 17 20 02 	lduh  [ %i4 + 2 ], %g1                         <== NOT EXECUTED
rtems_fdisk_seg_blank_check_page (const rtems_flashdisk*   fd,        
                                  rtems_fdisk_segment_ctl* sc,        
                                  uint32_t                 page)      
{                                                                     
  return rtems_fdisk_seg_blank_check (fd, sc,                         
                                      page * fd->block_size, fd->block_size);
40005840:	ee 06 20 14 	ld  [ %i0 + 0x14 ], %l7                        
        if (rtems_fdisk_page_desc_erased (pd))                        
        {                                                             
          /*                                                          
           * Is the page erased ?                                     
           */                                                         
          ret = rtems_fdisk_seg_blank_check_page (fd, sc,             
40005844:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
static int                                                            
rtems_fdisk_seg_blank_check_page (const rtems_flashdisk*   fd,        
                                  rtems_fdisk_segment_ctl* sc,        
                                  uint32_t                 page)      
{                                                                     
  return rtems_fdisk_seg_blank_check (fd, sc,                         
40005848:	92 10 00 17 	mov  %l7, %o1                                  
4000584c:	7f ff f3 48 	call  4000256c <.umul>                         
40005850:	90 06 c0 08 	add  %i3, %o0, %o0                             
40005854:	92 10 00 1d 	mov  %i5, %o1                                  
40005858:	94 10 00 08 	mov  %o0, %o2                                  
4000585c:	96 10 00 17 	mov  %l7, %o3                                  
40005860:	7f ff fe 66 	call  400051f8 <rtems_fdisk_seg_blank_check>   
40005864:	90 10 00 18 	mov  %i0, %o0                                  
           * Is the page erased ?                                     
           */                                                         
          ret = rtems_fdisk_seg_blank_check_page (fd, sc,             
                                                  page + sc->pages_desc);
                                                                      
          if (ret == 0)                                               
40005868:	80 a2 20 00 	cmp  %o0, 0                                    
4000586c:	32 80 00 0d 	bne,a   400058a0 <rtems_fdisk_recover_block_mappings+0x228><== NEVER TAKEN
40005870:	da 07 20 04 	ld  [ %i4 + 4 ], %o5                           <== NOT EXECUTED
          {                                                           
            ++fd->erased_blocks;                                      
40005874:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
40005878:	82 00 60 01 	inc  %g1                                       
4000587c:	c2 26 20 28 	st  %g1, [ %i0 + 0x28 ]                        
       * are active and how many are used.                            
       *                                                              
       * If the page is active see if the block is with-in range and  
       * if the block is a duplicate.                                 
       */                                                             
      for (page = 0; page < sc->pages; page++, pd++)                  
40005880:	b6 06 e0 01 	inc  %i3                                       
40005884:	b8 07 20 08 	add  %i4, 8, %i4                               
40005888:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000588c:	80 a6 c0 01 	cmp  %i3, %g1                                  
40005890:	0a bf ff e7 	bcs  4000582c <rtems_fdisk_recover_block_mappings+0x1b4>
40005894:	90 10 00 18 	mov  %i0, %o0                                  
40005898:	10 80 00 48 	b  400059b8 <rtems_fdisk_recover_block_mappings+0x340>
4000589c:	92 10 00 1d 	mov  %i5, %o1                                  
            ++fd->erased_blocks;                                      
          }                                                           
          else                                                        
          {                                                           
#if RTEMS_FDISK_TRACE                                                 
            rtems_fdisk_warning (fd, "page not blank: %d-%d-%d",      
400058a0:	92 10 00 15 	mov  %l5, %o1                                  <== NOT EXECUTED
400058a4:	94 10 00 19 	mov  %i1, %o2                                  <== NOT EXECUTED
400058a8:	96 10 00 1a 	mov  %i2, %o3                                  <== NOT EXECUTED
400058ac:	98 10 00 1b 	mov  %i3, %o4                                  <== NOT EXECUTED
400058b0:	7f ff fd da 	call  40005018 <rtems_fdisk_warning>           <== NOT EXECUTED
400058b4:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
400058b8:	c2 17 20 02 	lduh  [ %i4 + 2 ], %g1                         <== NOT EXECUTED
            rtems_fdisk_warning (fd, "page not blank: %d-%d-%d",      
                                 device, segment, page, pd->block);   
#endif                                                                
            rtems_fdisk_page_desc_set_flags (pd, RTEMS_FDISK_PAGE_USED);
                                                                      
            ret = rtems_fdisk_seg_write_page_desc (fd, sc,            
400058bc:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
400058c0:	82 08 7f fd 	and  %g1, -3, %g1                              <== NOT EXECUTED
            rtems_fdisk_warning (fd, "page not blank: %d-%d-%d",      
                                 device, segment, page, pd->block);   
#endif                                                                
            rtems_fdisk_page_desc_set_flags (pd, RTEMS_FDISK_PAGE_USED);
                                                                      
            ret = rtems_fdisk_seg_write_page_desc (fd, sc,            
400058c4:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
 * Set the flags. Setting means clear the bit to 0.                   
 */                                                                   
static void                                                           
rtems_fdisk_page_desc_set_flags (rtems_fdisk_page_desc* pd, uint16_t flags)
{                                                                     
  pd->flags &= ~flags;                                                
400058c8:	c2 37 20 02 	sth  %g1, [ %i4 + 2 ]                          <== NOT EXECUTED
            rtems_fdisk_warning (fd, "page not blank: %d-%d-%d",      
                                 device, segment, page, pd->block);   
#endif                                                                
            rtems_fdisk_page_desc_set_flags (pd, RTEMS_FDISK_PAGE_USED);
                                                                      
            ret = rtems_fdisk_seg_write_page_desc (fd, sc,            
400058cc:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
400058d0:	7f ff fe b3 	call  4000539c <rtems_fdisk_seg_write_page_desc><== NOT EXECUTED
400058d4:	96 10 00 1c 	mov  %i4, %o3                                  <== NOT EXECUTED
                                                   page, pd);         
                                                                      
            if (ret)                                                  
400058d8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
400058dc:	22 80 00 0d 	be,a   40005910 <rtems_fdisk_recover_block_mappings+0x298><== NOT EXECUTED
400058e0:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        <== NOT EXECUTED
            {                                                         
              rtems_fdisk_error ("forcing page to used failed: %d-%d-%d",
400058e4:	90 10 00 16 	mov  %l6, %o0                                  <== NOT EXECUTED
400058e8:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
400058ec:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
400058f0:	7f ff fd eb 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
400058f4:	96 10 00 1b 	mov  %i3, %o3                                  <== NOT EXECUTED
        }                                                             
        else                                                          
        {                                                             
          if (rtems_fdisk_page_desc_flags_set (pd, RTEMS_FDISK_PAGE_USED))
          {                                                           
            sc->pages_used++;                                         
400058f8:	10 80 00 06 	b  40005910 <rtems_fdisk_recover_block_mappings+0x298><== NOT EXECUTED
400058fc:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        <== NOT EXECUTED
            sc->pages_used++;                                         
          }                                                           
        }                                                             
        else                                                          
        {                                                             
          if (rtems_fdisk_page_desc_flags_set (pd, RTEMS_FDISK_PAGE_USED))
40005900:	80 88 60 02 	btst  2, %g1                                   <== NOT EXECUTED
40005904:	12 80 00 06 	bne  4000591c <rtems_fdisk_recover_block_mappings+0x2a4><== NOT EXECUTED
40005908:	80 88 60 01 	btst  1, %g1                                   <== NOT EXECUTED
          {                                                           
            sc->pages_used++;                                         
4000590c:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        <== NOT EXECUTED
40005910:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
40005914:	10 bf ff db 	b  40005880 <rtems_fdisk_recover_block_mappings+0x208><== NOT EXECUTED
40005918:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        <== NOT EXECUTED
          }                                                           
          else if (rtems_fdisk_page_desc_flags_set (pd, RTEMS_FDISK_PAGE_ACTIVE))
4000591c:	32 80 00 24 	bne,a   400059ac <rtems_fdisk_recover_block_mappings+0x334><== NOT EXECUTED
40005920:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        <== NOT EXECUTED
          {                                                           
            if (pd->block >= fd->block_count)                         
40005924:	da 07 20 04 	ld  [ %i4 + 4 ], %o5                           <== NOT EXECUTED
40005928:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        <== NOT EXECUTED
4000592c:	80 a3 40 01 	cmp  %o5, %g1                                  <== NOT EXECUTED
40005930:	2a 80 00 0a 	bcs,a   40005958 <rtems_fdisk_recover_block_mappings+0x2e0><== NOT EXECUTED
40005934:	c2 06 20 18 	ld  [ %i0 + 0x18 ], %g1                        <== NOT EXECUTED
            {                                                         
#if RTEMS_FDISK_TRACE                                                 
              rtems_fdisk_warning (fd,                                
40005938:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4000593c:	92 10 00 14 	mov  %l4, %o1                                  <== NOT EXECUTED
40005940:	94 10 00 19 	mov  %i1, %o2                                  <== NOT EXECUTED
40005944:	96 10 00 1a 	mov  %i2, %o3                                  <== NOT EXECUTED
40005948:	7f ff fd b4 	call  40005018 <rtems_fdisk_warning>           <== NOT EXECUTED
4000594c:	98 10 00 1b 	mov  %i3, %o4                                  <== NOT EXECUTED
               */                                                     
              sc->pages_active++;                                     
            }                                                         
          }                                                           
          else                                                        
            sc->pages_bad++;                                          
40005950:	10 80 00 17 	b  400059ac <rtems_fdisk_recover_block_mappings+0x334><== NOT EXECUTED
40005954:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        <== NOT EXECUTED
                                   "invalid block number: %d-%d-%d: block: %d",
                                   device, segment, page, pd->block); 
#endif                                                                
              sc->pages_bad++;                                        
            }                                                         
            else if (fd->blocks[pd->block].segment)                   
40005958:	9b 2b 60 03 	sll  %o5, 3, %o5                               <== NOT EXECUTED
4000595c:	c4 00 40 0d 	ld  [ %g1 + %o5 ], %g2                         <== NOT EXECUTED
40005960:	80 a0 a0 00 	cmp  %g2, 0                                    <== NOT EXECUTED
40005964:	02 80 00 0c 	be  40005994 <rtems_fdisk_recover_block_mappings+0x31c><== NOT EXECUTED
40005968:	86 00 40 0d 	add  %g1, %o5, %g3                             <== NOT EXECUTED
               * each block so we can tell which is the later block when
               * duplicates appear. A power down with a failed wirte could cause
               * a duplicate.                                         
               */                                                     
              const rtems_fdisk_segment_ctl* bsc = fd->blocks[pd->block].segment;
              rtems_fdisk_error ("duplicate block: %d-%d-%d: " \      
4000596c:	d2 00 a0 08 	ld  [ %g2 + 8 ], %o1                           <== NOT EXECUTED
40005970:	d4 00 a0 0c 	ld  [ %g2 + 0xc ], %o2                         <== NOT EXECUTED
40005974:	d6 00 e0 04 	ld  [ %g3 + 4 ], %o3                           <== NOT EXECUTED
40005978:	90 10 00 13 	mov  %l3, %o0                                  <== NOT EXECUTED
4000597c:	f6 23 a0 5c 	st  %i3, [ %sp + 0x5c ]                        <== NOT EXECUTED
40005980:	98 10 00 19 	mov  %i1, %o4                                  <== NOT EXECUTED
40005984:	7f ff fd c6 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005988:	9a 10 00 1a 	mov  %i2, %o5                                  <== NOT EXECUTED
               */                                                     
              sc->pages_active++;                                     
            }                                                         
          }                                                           
          else                                                        
            sc->pages_bad++;                                          
4000598c:	10 80 00 08 	b  400059ac <rtems_fdisk_recover_block_mappings+0x334><== NOT EXECUTED
40005990:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        <== NOT EXECUTED
            {                                                         
              /**                                                     
               * @todo                                                
               * Add start up crc checks here.                        
               */                                                     
              fd->blocks[pd->block].segment = sc;                     
40005994:	fa 20 40 0d 	st  %i5, [ %g1 + %o5 ]                         <== NOT EXECUTED
              fd->blocks[pd->block].page    = page;                   
                                                                      
              /*                                                      
               * The page is active.                                  
               */                                                     
              sc->pages_active++;                                     
40005998:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        <== NOT EXECUTED
              /**                                                     
               * @todo                                                
               * Add start up crc checks here.                        
               */                                                     
              fd->blocks[pd->block].segment = sc;                     
              fd->blocks[pd->block].page    = page;                   
4000599c:	f6 20 e0 04 	st  %i3, [ %g3 + 4 ]                           <== NOT EXECUTED
                                                                      
              /*                                                      
               * The page is active.                                  
               */                                                     
              sc->pages_active++;                                     
400059a0:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
400059a4:	10 bf ff b7 	b  40005880 <rtems_fdisk_recover_block_mappings+0x208><== NOT EXECUTED
400059a8:	c2 27 60 1c 	st  %g1, [ %i5 + 0x1c ]                        <== NOT EXECUTED
            }                                                         
          }                                                           
          else                                                        
            sc->pages_bad++;                                          
400059ac:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
400059b0:	10 bf ff b4 	b  40005880 <rtems_fdisk_recover_block_mappings+0x208><== NOT EXECUTED
400059b4:	c2 27 60 24 	st  %g1, [ %i5 + 0x24 ]                        <== NOT EXECUTED
      }                                                               
                                                                      
      /*                                                              
       * Place the segment on to the correct queue.                   
       */                                                             
      rtems_fdisk_queue_segment (fd, sc);                             
400059b8:	7f ff fe d0 	call  400054f8 <rtems_fdisk_queue_segment>     
400059bc:	b4 06 a0 01 	inc  %i2                                       
400059c0:	10 bf ff 53 	b  4000570c <rtems_fdisk_recover_block_mappings+0x94>
400059c4:	a2 04 60 30 	add  %l1, 0x30, %l1                            
  /*                                                                  
   * Scan each segment or each device recovering the valid pages.     
   */                                                                 
  fd->erased_blocks = 0;                                              
  fd->starvation_threshold = 0;                                       
  for (device = 0; device < fd->device_count; device++)               
400059c8:	b2 06 60 01 	inc  %i1                                       
400059cc:	10 bf ff 4b 	b  400056f8 <rtems_fdisk_recover_block_mappings+0x80>
400059d0:	a0 04 20 0c 	add  %l0, 0xc, %l0                             
      rtems_fdisk_queue_segment (fd, sc);                             
    }                                                                 
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
400059d4:	81 c7 e0 08 	ret                                            
400059d8:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40005a48 <rtems_fdisk_recycle_segment>: static int rtems_fdisk_recycle_segment (rtems_flashdisk* fd, rtems_fdisk_segment_ctl* ssc, rtems_fdisk_segment_ctl* dsc, uint32_t *pages) {
40005a48:	9d e3 bf 80 	save  %sp, -128, %sp                           
  int      ret;                                                       
  uint32_t spage;                                                     
  uint32_t used = 0;                                                  
  uint32_t active = 0;                                                
40005a4c:	a2 10 20 00 	clr  %l1                                       
static int                                                            
rtems_fdisk_recycle_segment (rtems_flashdisk*         fd,             
                                    rtems_fdisk_segment_ctl* ssc,     
                                    rtems_fdisk_segment_ctl* dsc,     
                                    uint32_t *pages)                  
{                                                                     
40005a50:	a4 10 00 19 	mov  %i1, %l2                                  
  int      ret;                                                       
  uint32_t spage;                                                     
  uint32_t used = 0;                                                  
40005a54:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
static int                                                            
rtems_fdisk_recycle_segment (rtems_flashdisk*         fd,             
                                    rtems_fdisk_segment_ctl* ssc,     
                                    rtems_fdisk_segment_ctl* dsc,     
                                    uint32_t *pages)                  
{                                                                     
40005a58:	b2 10 00 1a 	mov  %i2, %i1                                  
  int      ret;                                                       
  uint32_t spage;                                                     
  uint32_t used = 0;                                                  
  uint32_t active = 0;                                                
                                                                      
  for (spage = 0; spage < ssc->pages; spage++)                        
40005a5c:	b8 10 20 00 	clr  %i4                                       
40005a60:	c4 04 a0 14 	ld  [ %l2 + 0x14 ], %g2                        
40005a64:	80 a7 00 02 	cmp  %i4, %g2                                  
40005a68:	1a 80 00 cd 	bcc  40005d9c <rtems_fdisk_recycle_segment+0x354>
40005a6c:	ad 2f 20 03 	sll  %i4, 3, %l6                               
  {                                                                   
    rtems_fdisk_page_desc* spd = &ssc->page_descriptors[spage];       
40005a70:	ee 04 a0 10 	ld  [ %l2 + 0x10 ], %l7                        
40005a74:	a0 05 c0 16 	add  %l7, %l6, %l0                             
40005a78:	c4 14 20 02 	lduh  [ %l0 + 2 ], %g2                         
                                                                      
    if (rtems_fdisk_page_desc_flags_set (spd, RTEMS_FDISK_PAGE_ACTIVE) &&
40005a7c:	80 88 a0 01 	btst  1, %g2                                   
40005a80:	12 80 00 ba 	bne  40005d68 <rtems_fdisk_recycle_segment+0x320><== NEVER TAKEN
40005a84:	80 88 a0 02 	btst  2, %g2                                   
40005a88:	02 80 00 b8 	be  40005d68 <rtems_fdisk_recycle_segment+0x320>
40005a8c:	ba 10 20 00 	clr  %i5                                       
 * Find the next available page in a segment.                         
 */                                                                   
static uint32_t                                                       
rtems_fdisk_seg_next_available_page (rtems_fdisk_segment_ctl* sc)     
{                                                                     
  rtems_fdisk_page_desc* pd = &sc->page_descriptors[0];               
40005a90:	e8 06 60 10 	ld  [ %i1 + 0x10 ], %l4                        
  uint32_t               page;                                        
                                                                      
  for (page = 0; page < sc->pages; page++, pd++)                      
40005a94:	ea 06 60 14 	ld  [ %i1 + 0x14 ], %l5                        
40005a98:	a7 2f 60 03 	sll  %i5, 3, %l3                               
40005a9c:	80 a7 40 15 	cmp  %i5, %l5                                  
40005aa0:	02 80 00 07 	be  40005abc <rtems_fdisk_recycle_segment+0x74><== NEVER TAKEN
40005aa4:	90 05 00 13 	add  %l4, %l3, %o0                             
    if (rtems_fdisk_page_desc_erased (pd))                            
40005aa8:	7f ff fc f6 	call  40004e80 <rtems_fdisk_page_desc_erased>  
40005aac:	01 00 00 00 	nop                                            
40005ab0:	80 a2 20 00 	cmp  %o0, 0                                    
40005ab4:	22 bf ff f9 	be,a   40005a98 <rtems_fdisk_recycle_segment+0x50>
40005ab8:	ba 07 60 01 	inc  %i5                                       
      uint32_t               dst_pages;                               
      rtems_fdisk_page_desc* dpd;                                     
      uint32_t               dpage;                                   
                                                                      
      dpage = rtems_fdisk_seg_next_available_page (dsc);              
      dpd   = &dsc->page_descriptors[dpage];                          
40005abc:	b4 05 00 13 	add  %l4, %l3, %i2                             
                                                                      
      active++;                                                       
                                                                      
      if (dpage >= dsc->pages)                                        
40005ac0:	80 a7 40 15 	cmp  %i5, %l5                                  
40005ac4:	0a 80 00 14 	bcs  40005b14 <rtems_fdisk_recycle_segment+0xcc><== ALWAYS TAKEN
40005ac8:	a2 04 60 01 	inc  %l1                                       
      {                                                               
        rtems_fdisk_error ("recycle: %02d-%03d: " \                   
40005acc:	7f ff fc f7 	call  40004ea8 <rtems_fdisk_seg_pages_available><== NOT EXECUTED
40005ad0:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40005ad4:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
40005ad8:	d4 06 60 0c 	ld  [ %i1 + 0xc ], %o2                         <== NOT EXECUTED
40005adc:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
40005ae0:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
40005ae4:	7f ff fd 6e 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005ae8:	90 12 20 08 	or  %o0, 8, %o0	! 40032408 <__FUNCTION__.6501+0x3a0><== NOT EXECUTED
                           "no page desc available: %d",              
                           dsc->device, dsc->segment,                 
                           rtems_fdisk_seg_pages_available (dsc));    
        dsc->failed = true;                                           
40005aec:	84 10 20 01 	mov  1, %g2                                    <== NOT EXECUTED
        rtems_fdisk_queue_segment (fd, dsc);                          
40005af0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40005af4:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
40005af8:	7f ff fe 80 	call  400054f8 <rtems_fdisk_queue_segment>     <== NOT EXECUTED
40005afc:	c4 26 60 28 	st  %g2, [ %i1 + 0x28 ]                        <== NOT EXECUTED
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
40005b00:	90 06 20 40 	add  %i0, 0x40, %o0                            <== NOT EXECUTED
40005b04:	7f ff fc 7c 	call  40004cf4 <rtems_fdisk_segment_queue_push_head><== NOT EXECUTED
40005b08:	92 10 00 12 	mov  %l2, %o1                                  <== NOT EXECUTED
            ret = rtems_fdisk_erase_segment (fd, ssc);                
          }                                                           
          else                                                        
          {                                                           
            rtems_fdisk_error ("recycle: no available dst segment");  
            ret = EIO;                                                
40005b0c:	10 80 00 b6 	b  40005de4 <rtems_fdisk_recycle_segment+0x39c><== NOT EXECUTED
40005b10:	aa 10 20 05 	mov  5, %l5                                    <== NOT EXECUTED
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
        return EIO;                                                   
      }                                                               
                                                                      
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "recycle: %02d-%03d-%03d=>%02d-%03d-%03d",
40005b14:	da 06 60 08 	ld  [ %i1 + 8 ], %o5                           
40005b18:	c4 06 60 0c 	ld  [ %i1 + 0xc ], %g2                         
40005b1c:	d4 04 a0 08 	ld  [ %l2 + 8 ], %o2                           
40005b20:	d6 04 a0 0c 	ld  [ %l2 + 0xc ], %o3                         
40005b24:	c4 23 a0 5c 	st  %g2, [ %sp + 0x5c ]                        
40005b28:	98 10 00 1c 	mov  %i4, %o4                                  
40005b2c:	fa 23 a0 60 	st  %i5, [ %sp + 0x60 ]                        
40005b30:	90 10 00 18 	mov  %i0, %o0                                  
40005b34:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
40005b38:	7f ff fd 17 	call  40004f94 <rtems_fdisk_info>              
40005b3c:	92 12 60 38 	or  %o1, 0x38, %o1	! 40032438 <__FUNCTION__.6501+0x3d0>
                        ssc->device, ssc->segment, spage,             
                        dsc->device, dsc->segment, dpage);            
#endif                                                                
      ret = rtems_fdisk_seg_copy_page (fd, ssc,                       
40005b40:	c6 06 60 18 	ld  [ %i1 + 0x18 ], %g3                        
40005b44:	c4 04 a0 18 	ld  [ %l2 + 0x18 ], %g2                        
                           rtems_fdisk_segment_ctl* dst_sc,           
                           uint32_t                 dst_page)         
{                                                                     
  int ret;                                                            
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, "  seg-copy-page: %02d-%03d~%03d=>%02d-%03d~%03d",
40005b48:	da 06 60 08 	ld  [ %i1 + 8 ], %o5                           
40005b4c:	c8 06 60 0c 	ld  [ %i1 + 0xc ], %g4                         
40005b50:	d4 04 a0 08 	ld  [ %l2 + 8 ], %o2                           
40005b54:	d6 04 a0 0c 	ld  [ %l2 + 0xc ], %o3                         
#if RTEMS_FDISK_TRACE                                                 
      rtems_fdisk_info (fd, "recycle: %02d-%03d-%03d=>%02d-%03d-%03d",
                        ssc->device, ssc->segment, spage,             
                        dsc->device, dsc->segment, dpage);            
#endif                                                                
      ret = rtems_fdisk_seg_copy_page (fd, ssc,                       
40005b58:	84 07 00 02 	add  %i4, %g2, %g2                             
40005b5c:	86 07 40 03 	add  %i5, %g3, %g3                             
                           rtems_fdisk_segment_ctl* dst_sc,           
                           uint32_t                 dst_page)         
{                                                                     
  int ret;                                                            
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, "  seg-copy-page: %02d-%03d~%03d=>%02d-%03d~%03d",
40005b60:	98 10 00 02 	mov  %g2, %o4                                  
40005b64:	c8 23 a0 5c 	st  %g4, [ %sp + 0x5c ]                        
40005b68:	c6 23 a0 60 	st  %g3, [ %sp + 0x60 ]                        
40005b6c:	c4 3f bf f0 	std  %g2, [ %fp + -16 ]                        
40005b70:	90 10 00 18 	mov  %i0, %o0                                  
40005b74:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
40005b78:	7f ff fc e6 	call  40004f10 <rtems_fdisk_printf>            
40005b7c:	92 12 60 60 	or  %o1, 0x60, %o1	! 40032460 <__FUNCTION__.6501+0x3f8>
rtems_fdisk_seg_read_page (const rtems_flashdisk*   fd,               
                           rtems_fdisk_segment_ctl* sc,               
                           uint32_t                 page,             
                           void*                    buffer)           
{                                                                     
  return rtems_fdisk_seg_read (fd, sc,                                
40005b80:	c4 1f bf f0 	ldd  [ %fp + -16 ], %g2                        
                               page * fd->block_size, buffer, fd->block_size);
40005b84:	ea 06 20 14 	ld  [ %i0 + 0x14 ], %l5                        
rtems_fdisk_seg_read_page (const rtems_flashdisk*   fd,               
                           rtems_fdisk_segment_ctl* sc,               
                           uint32_t                 page,             
                           void*                    buffer)           
{                                                                     
  return rtems_fdisk_seg_read (fd, sc,                                
40005b88:	90 10 00 02 	mov  %g2, %o0                                  
40005b8c:	92 10 00 15 	mov  %l5, %o1                                  
40005b90:	7f ff f2 77 	call  4000256c <.umul>                         
40005b94:	c6 27 bf f4 	st  %g3, [ %fp + -12 ]                         
40005b98:	d6 06 20 68 	ld  [ %i0 + 0x68 ], %o3                        
40005b9c:	94 10 00 08 	mov  %o0, %o2                                  
40005ba0:	98 10 00 15 	mov  %l5, %o4                                  
40005ba4:	90 10 00 18 	mov  %i0, %o0                                  
40005ba8:	7f ff fd b5 	call  4000527c <rtems_fdisk_seg_read>          
40005bac:	92 10 00 12 	mov  %l2, %o1                                  
                      src_sc->device, src_sc->segment, src_page,      
                      dst_sc->device, dst_sc->segment, dst_page);     
#endif                                                                
  ret = rtems_fdisk_seg_read_page (fd, src_sc, src_page,              
                                   fd->copy_buffer);                  
  if (ret)                                                            
40005bb0:	aa 92 20 00 	orcc  %o0, 0, %l5                              
40005bb4:	12 80 00 0a 	bne  40005bdc <rtems_fdisk_recycle_segment+0x194><== NEVER TAKEN
40005bb8:	c6 07 bf f4 	ld  [ %fp + -12 ], %g3                         
    return ret;                                                       
  return rtems_fdisk_seg_write_page (fd, dst_sc, dst_page,            
40005bbc:	d6 06 20 68 	ld  [ %i0 + 0x68 ], %o3                        
40005bc0:	90 10 00 18 	mov  %i0, %o0                                  
40005bc4:	92 10 00 19 	mov  %i1, %o1                                  
40005bc8:	7f ff ff 85 	call  400059dc <rtems_fdisk_seg_write_page>    
40005bcc:	94 10 00 03 	mov  %g3, %o2                                  
#endif                                                                
      ret = rtems_fdisk_seg_copy_page (fd, ssc,                       
                                       spage + ssc->pages_desc,       
                                       dsc,                           
                                       dpage + dsc->pages_desc);      
      if (ret)                                                        
40005bd0:	aa 92 20 00 	orcc  %o0, 0, %l5                              
40005bd4:	22 80 00 1b 	be,a   40005c40 <rtems_fdisk_recycle_segment+0x1f8><== ALWAYS TAKEN
40005bd8:	c4 05 c0 16 	ld  [ %l7 + %l6 ], %g2                         
      {                                                               
        rtems_fdisk_error ("recycle: %02d-%03d-%03d=>" \              
40005bdc:	e2 04 a0 08 	ld  [ %l2 + 8 ], %l1                           <== NOT EXECUTED
40005be0:	e0 04 a0 0c 	ld  [ %l2 + 0xc ], %l0                         <== NOT EXECUTED
40005be4:	f4 06 60 08 	ld  [ %i1 + 8 ], %i2                           <== NOT EXECUTED
40005be8:	f6 06 60 0c 	ld  [ %i1 + 0xc ], %i3                         <== NOT EXECUTED
40005bec:	40 00 75 e8 	call  4002338c <strerror>                      <== NOT EXECUTED
40005bf0:	90 10 00 15 	mov  %l5, %o0                                  <== NOT EXECUTED
40005bf4:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
40005bf8:	d0 23 a0 60 	st  %o0, [ %sp + 0x60 ]                        <== NOT EXECUTED
40005bfc:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
40005c00:	96 10 00 1c 	mov  %i4, %o3                                  <== NOT EXECUTED
40005c04:	98 10 00 1a 	mov  %i2, %o4                                  <== NOT EXECUTED
40005c08:	9a 10 00 1b 	mov  %i3, %o5                                  <== NOT EXECUTED
40005c0c:	fa 23 a0 5c 	st  %i5, [ %sp + 0x5c ]                        <== NOT EXECUTED
40005c10:	ea 23 a0 64 	st  %l5, [ %sp + 0x64 ]                        <== NOT EXECUTED
40005c14:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
40005c18:	7f ff fd 21 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005c1c:	90 12 20 90 	or  %o0, 0x90, %o0	! 40032490 <__FUNCTION__.6501+0x428><== NOT EXECUTED
                           "%02d-%03d-%03d: "             \           
                           "copy page failed: %s (%d)",               
                           ssc->device, ssc->segment, spage,          
                           dsc->device, dsc->segment, dpage,          
                           strerror (ret), ret);                      
        rtems_fdisk_queue_segment (fd, dsc);                          
40005c20:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40005c24:	7f ff fe 35 	call  400054f8 <rtems_fdisk_queue_segment>     <== NOT EXECUTED
40005c28:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
40005c2c:	90 06 20 40 	add  %i0, 0x40, %o0                            <== NOT EXECUTED
40005c30:	7f ff fc 31 	call  40004cf4 <rtems_fdisk_segment_queue_push_head><== NOT EXECUTED
40005c34:	92 10 00 12 	mov  %l2, %o1                                  <== NOT EXECUTED
        return ret;                                                   
40005c38:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005c3c:	91 e8 00 15 	restore  %g0, %l5, %o0                         <== NOT EXECUTED
      }                                                               
                                                                      
      *dpd = *spd;                                                    
                                                                      
      ret = rtems_fdisk_seg_write_page_desc (fd,                      
40005c40:	90 10 00 18 	mov  %i0, %o0                                  
        rtems_fdisk_queue_segment (fd, dsc);                          
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
        return ret;                                                   
      }                                                               
                                                                      
      *dpd = *spd;                                                    
40005c44:	c4 25 00 13 	st  %g2, [ %l4 + %l3 ]                         
40005c48:	c4 04 20 04 	ld  [ %l0 + 4 ], %g2                           
                                                                      
      ret = rtems_fdisk_seg_write_page_desc (fd,                      
40005c4c:	92 10 00 19 	mov  %i1, %o1                                  
        rtems_fdisk_queue_segment (fd, dsc);                          
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
        return ret;                                                   
      }                                                               
                                                                      
      *dpd = *spd;                                                    
40005c50:	c4 26 a0 04 	st  %g2, [ %i2 + 4 ]                           
                                                                      
      ret = rtems_fdisk_seg_write_page_desc (fd,                      
40005c54:	94 10 00 1d 	mov  %i5, %o2                                  
40005c58:	7f ff fd d1 	call  4000539c <rtems_fdisk_seg_write_page_desc>
40005c5c:	96 10 00 1a 	mov  %i2, %o3                                  
                                             dsc,                     
                                             dpage, dpd);             
                                                                      
      if (ret)                                                        
40005c60:	a6 92 20 00 	orcc  %o0, 0, %l3                              
40005c64:	22 80 00 1b 	be,a   40005cd0 <rtems_fdisk_recycle_segment+0x288><== ALWAYS TAKEN
40005c68:	c4 06 60 1c 	ld  [ %i1 + 0x1c ], %g2                        
      {                                                               
        rtems_fdisk_error ("recycle: %02d-%03d-%03d=>"   \            
40005c6c:	e2 04 a0 08 	ld  [ %l2 + 8 ], %l1                           <== NOT EXECUTED
40005c70:	e0 04 a0 0c 	ld  [ %l2 + 0xc ], %l0                         <== NOT EXECUTED
40005c74:	f4 06 60 08 	ld  [ %i1 + 8 ], %i2                           <== NOT EXECUTED
40005c78:	40 00 75 c5 	call  4002338c <strerror>                      <== NOT EXECUTED
40005c7c:	f6 06 60 0c 	ld  [ %i1 + 0xc ], %i3                         <== NOT EXECUTED
40005c80:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
40005c84:	96 10 00 1c 	mov  %i4, %o3                                  <== NOT EXECUTED
40005c88:	98 10 00 1a 	mov  %i2, %o4                                  <== NOT EXECUTED
40005c8c:	9a 10 00 1b 	mov  %i3, %o5                                  <== NOT EXECUTED
40005c90:	d0 23 a0 60 	st  %o0, [ %sp + 0x60 ]                        <== NOT EXECUTED
40005c94:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
40005c98:	fa 23 a0 5c 	st  %i5, [ %sp + 0x5c ]                        <== NOT EXECUTED
40005c9c:	e6 23 a0 64 	st  %l3, [ %sp + 0x64 ]                        <== NOT EXECUTED
40005ca0:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    <== NOT EXECUTED
40005ca4:	7f ff fc fe 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005ca8:	90 12 20 d8 	or  %o0, 0xd8, %o0	! 400324d8 <__FUNCTION__.6501+0x470><== NOT EXECUTED
                           "%02d-%03d-%03d: copy pd failed: %s (%d)", 
                           ssc->device, ssc->segment, spage,          
                           dsc->device, dsc->segment, dpage,          
                           strerror (ret), ret);                      
        rtems_fdisk_queue_segment (fd, dsc);                          
40005cac:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40005cb0:	7f ff fe 12 	call  400054f8 <rtems_fdisk_queue_segment>     <== NOT EXECUTED
40005cb4:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
40005cb8:	90 06 20 40 	add  %i0, 0x40, %o0                            <== NOT EXECUTED
40005cbc:	92 10 00 12 	mov  %l2, %o1                                  <== NOT EXECUTED
40005cc0:	7f ff fc 0d 	call  40004cf4 <rtems_fdisk_segment_queue_push_head><== NOT EXECUTED
40005cc4:	aa 10 00 13 	mov  %l3, %l5                                  <== NOT EXECUTED
        return ret;                                                   
40005cc8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005ccc:	91 e8 00 15 	restore  %g0, %l5, %o0                         <== NOT EXECUTED
       */                                                             
                                                                      
      ssc->pages_active--;                                            
      ssc->pages_used++;                                              
                                                                      
      fd->blocks[spd->block].segment = dsc;                           
40005cd0:	c6 06 20 18 	ld  [ %i0 + 0x18 ], %g3                        
        rtems_fdisk_queue_segment (fd, dsc);                          
        rtems_fdisk_segment_queue_push_head (&fd->used, ssc);         
        return ret;                                                   
      }                                                               
                                                                      
      dsc->pages_active++;                                            
40005cd4:	84 00 a0 01 	inc  %g2                                       
40005cd8:	c4 26 60 1c 	st  %g2, [ %i1 + 0x1c ]                        
       * segment will be erased. Power down could be a problem.       
       * We do the stats to make sure everything is as it should      
       * be.                                                          
       */                                                             
                                                                      
      ssc->pages_active--;                                            
40005cdc:	c4 04 a0 1c 	ld  [ %l2 + 0x1c ], %g2                        
      fd->blocks[spd->block].page    = dpage;                         
                                                                      
      /*                                                              
       * Place the segment on to the correct queue.                   
       */                                                             
      rtems_fdisk_queue_segment (fd, dsc);                            
40005ce0:	90 10 00 18 	mov  %i0, %o0                                  
       * segment will be erased. Power down could be a problem.       
       * We do the stats to make sure everything is as it should      
       * be.                                                          
       */                                                             
                                                                      
      ssc->pages_active--;                                            
40005ce4:	84 00 bf ff 	add  %g2, -1, %g2                              
40005ce8:	c4 24 a0 1c 	st  %g2, [ %l2 + 0x1c ]                        
      ssc->pages_used++;                                              
40005cec:	c4 04 a0 20 	ld  [ %l2 + 0x20 ], %g2                        
      fd->blocks[spd->block].page    = dpage;                         
                                                                      
      /*                                                              
       * Place the segment on to the correct queue.                   
       */                                                             
      rtems_fdisk_queue_segment (fd, dsc);                            
40005cf0:	92 10 00 19 	mov  %i1, %o1                                  
       * We do the stats to make sure everything is as it should      
       * be.                                                          
       */                                                             
                                                                      
      ssc->pages_active--;                                            
      ssc->pages_used++;                                              
40005cf4:	84 00 a0 01 	inc  %g2                                       
40005cf8:	c4 24 a0 20 	st  %g2, [ %l2 + 0x20 ]                        
                                                                      
      fd->blocks[spd->block].segment = dsc;                           
40005cfc:	c4 04 20 04 	ld  [ %l0 + 4 ], %g2                           
40005d00:	85 28 a0 03 	sll  %g2, 3, %g2                               
40005d04:	88 00 c0 02 	add  %g3, %g2, %g4                             
40005d08:	f2 20 c0 02 	st  %i1, [ %g3 + %g2 ]                         
      fd->blocks[spd->block].page    = dpage;                         
                                                                      
      /*                                                              
       * Place the segment on to the correct queue.                   
       */                                                             
      rtems_fdisk_queue_segment (fd, dsc);                            
40005d0c:	7f ff fd fb 	call  400054f8 <rtems_fdisk_queue_segment>     
40005d10:	fa 21 20 04 	st  %i5, [ %g4 + 4 ]                           
                                                                      
      /*                                                              
       * Get new destination segment if necessary.                    
       */                                                             
      dst_pages = rtems_fdisk_seg_pages_available (dsc);              
40005d14:	7f ff fc 65 	call  40004ea8 <rtems_fdisk_seg_pages_available>
40005d18:	90 10 00 19 	mov  %i1, %o0                                  
      if (dst_pages == 0)                                             
40005d1c:	80 a2 20 00 	cmp  %o0, 0                                    
40005d20:	32 80 00 0f 	bne,a   40005d5c <rtems_fdisk_recycle_segment+0x314>
40005d24:	c4 06 c0 00 	ld  [ %i3 ], %g2                               
      {                                                               
        dsc = rtems_fdisk_seg_most_available (&fd->available);        
40005d28:	7f ff fd 04 	call  40005138 <rtems_fdisk_seg_most_available.isra.8>
40005d2c:	d0 06 20 34 	ld  [ %i0 + 0x34 ], %o0                        
        if (!dsc)                                                     
40005d30:	b2 92 20 00 	orcc  %o0, 0, %i1                              
40005d34:	32 80 00 0a 	bne,a   40005d5c <rtems_fdisk_recycle_segment+0x314><== NEVER TAKEN
40005d38:	c4 06 c0 00 	ld  [ %i3 ], %g2                               <== NOT EXECUTED
        {                                                             
          if (ssc->pages_active == 0)                                 
40005d3c:	c4 04 a0 1c 	ld  [ %l2 + 0x1c ], %g2                        
40005d40:	80 a0 a0 00 	cmp  %g2, 0                                    
40005d44:	02 80 00 26 	be  40005ddc <rtems_fdisk_recycle_segment+0x394><== ALWAYS TAKEN
40005d48:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    
          {                                                           
            ret = rtems_fdisk_erase_segment (fd, ssc);                
          }                                                           
          else                                                        
          {                                                           
            rtems_fdisk_error ("recycle: no available dst segment");  
40005d4c:	7f ff fc d4 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005d50:	90 12 21 20 	or  %o0, 0x120, %o0	! 40032520 <__FUNCTION__.6501+0x4b8><== NOT EXECUTED
            ret = EIO;                                                
40005d54:	10 80 00 24 	b  40005de4 <rtems_fdisk_recycle_segment+0x39c><== NOT EXECUTED
40005d58:	aa 10 20 05 	mov  5, %l5                                    <== NOT EXECUTED
                                                                      
          return ret;                                                 
        }                                                             
      }                                                               
                                                                      
      (*pages)--;                                                     
40005d5c:	84 00 bf ff 	add  %g2, -1, %g2                              
  {                                                                   
    rtems_fdisk_page_desc* spd = &ssc->page_descriptors[spage];       
                                                                      
    if (rtems_fdisk_page_desc_flags_set (spd, RTEMS_FDISK_PAGE_ACTIVE) &&
        !rtems_fdisk_page_desc_flags_set (spd, RTEMS_FDISK_PAGE_USED))
    {                                                                 
40005d60:	10 80 00 0d 	b  40005d94 <rtems_fdisk_recycle_segment+0x34c>
40005d64:	c4 26 c0 00 	st  %g2, [ %i3 ]                               
        }                                                             
      }                                                               
                                                                      
      (*pages)--;                                                     
    }                                                                 
    else if (rtems_fdisk_page_desc_erased (spd))                      
40005d68:	7f ff fc 46 	call  40004e80 <rtems_fdisk_page_desc_erased>  
40005d6c:	90 10 00 10 	mov  %l0, %o0                                  
40005d70:	80 a2 20 00 	cmp  %o0, 0                                    
40005d74:	02 80 00 06 	be  40005d8c <rtems_fdisk_recycle_segment+0x344><== ALWAYS TAKEN
40005d78:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
    {                                                                 
      --fd->erased_blocks;                                            
40005d7c:	c4 06 20 28 	ld  [ %i0 + 0x28 ], %g2                        <== NOT EXECUTED
40005d80:	84 00 bf ff 	add  %g2, -1, %g2                              <== NOT EXECUTED
40005d84:	10 80 00 04 	b  40005d94 <rtems_fdisk_recycle_segment+0x34c><== NOT EXECUTED
40005d88:	c4 26 20 28 	st  %g2, [ %i0 + 0x28 ]                        <== NOT EXECUTED
    }                                                                 
    else                                                              
    {                                                                 
      used++;                                                         
40005d8c:	82 00 60 01 	inc  %g1                                       
40005d90:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
  int      ret;                                                       
  uint32_t spage;                                                     
  uint32_t used = 0;                                                  
  uint32_t active = 0;                                                
                                                                      
  for (spage = 0; spage < ssc->pages; spage++)                        
40005d94:	10 bf ff 33 	b  40005a60 <rtems_fdisk_recycle_segment+0x18> 
40005d98:	b8 07 20 01 	inc  %i4                                       
      used++;                                                         
    }                                                                 
  }                                                                   
                                                                      
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, "ssc end: %d-%d: p=%ld, a=%ld, u=%ld",      
40005d9c:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40005da0:	d4 04 a0 08 	ld  [ %l2 + 8 ], %o2                           
40005da4:	d6 04 a0 0c 	ld  [ %l2 + 0xc ], %o3                         
40005da8:	c2 23 a0 5c 	st  %g1, [ %sp + 0x5c ]                        
40005dac:	90 10 00 18 	mov  %i0, %o0                                  
40005db0:	13 10 00 c9 	sethi  %hi(0x40032400), %o1                    
40005db4:	98 10 00 1b 	mov  %i3, %o4                                  
40005db8:	92 12 61 48 	or  %o1, 0x148, %o1                            
40005dbc:	7f ff fc 55 	call  40004f10 <rtems_fdisk_printf>            
40005dc0:	9a 10 00 11 	mov  %l1, %o5                                  
                      ssc->device, ssc->segment,                      
                      pages, active, used);                           
#endif                                                                
  if (ssc->pages_active != 0)                                         
40005dc4:	d2 04 a0 1c 	ld  [ %l2 + 0x1c ], %o1                        
40005dc8:	80 a2 60 00 	cmp  %o1, 0                                    
40005dcc:	02 80 00 04 	be  40005ddc <rtems_fdisk_recycle_segment+0x394><== ALWAYS TAKEN
40005dd0:	11 10 00 c9 	sethi  %hi(0x40032400), %o0                    
  {                                                                   
    rtems_fdisk_error ("compacting: ssc pages not 0: %d",             
40005dd4:	7f ff fc b2 	call  4000509c <rtems_fdisk_error>             <== NOT EXECUTED
40005dd8:	90 12 21 70 	or  %o0, 0x170, %o0	! 40032570 <__FUNCTION__.6501+0x508><== NOT EXECUTED
                       ssc->pages_active);                            
  }                                                                   
                                                                      
  ret = rtems_fdisk_erase_segment (fd, ssc);                          
40005ddc:	7f ff fd 81 	call  400053e0 <rtems_fdisk_erase_segment>     
40005de0:	93 e8 00 12 	restore  %g0, %l2, %o1                         
                                                                      
  return ret;                                                         
}                                                                     
40005de4:	b0 10 00 15 	mov  %l5, %i0                                  <== NOT EXECUTED
40005de8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005dec:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40005304 <rtems_fdisk_seg_write>: rtems_fdisk_seg_write (const rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc, uint32_t offset, const void* buffer, uint32_t size) {
40005304:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int ret;                                                            
  uint32_t                           device;                          
  uint32_t                           segment;                         
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
40005308:	e0 06 60 08 	ld  [ %i1 + 8 ], %l0                           
  segment = sc->segment;                                              
4000530c:	fa 06 60 0c 	ld  [ %i1 + 0xc ], %i5                         
static const rtems_fdisk_segment_desc*                                
rtems_fdisk_seg_descriptor (const rtems_flashdisk* fd,                
                            uint32_t               device,            
                            uint32_t               segment)           
{                                                                     
  return fd->devices[device].segments[segment].descriptor;            
40005310:	85 2c 20 04 	sll  %l0, 4, %g2                               
40005314:	83 2c 20 02 	sll  %l0, 2, %g1                               
40005318:	82 20 80 01 	sub  %g2, %g1, %g1                             
4000531c:	c4 06 20 2c 	ld  [ %i0 + 0x2c ], %g2                        
40005320:	89 2f 60 06 	sll  %i5, 6, %g4                               
40005324:	86 00 80 01 	add  %g2, %g1, %g3                             
40005328:	c4 00 80 01 	ld  [ %g2 + %g1 ], %g2                         
4000532c:	83 2f 60 04 	sll  %i5, 4, %g1                               
40005330:	82 21 00 01 	sub  %g4, %g1, %g1                             
40005334:	82 00 80 01 	add  %g2, %g1, %g1                             
40005338:	e2 00 60 04 	ld  [ %g1 + 4 ], %l1                           
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
  segment = sc->segment;                                              
  sd = rtems_fdisk_seg_descriptor (fd, device, segment);              
  ops = fd->devices[device].descriptor->flash_ops;                    
4000533c:	c2 00 e0 08 	ld  [ %g3 + 8 ], %g1                           
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, "  seg-write: %02d-%03d: o=%08x s=%d",      
40005340:	90 10 00 18 	mov  %i0, %o0                                  
  const rtems_fdisk_segment_desc*    sd;                              
  const rtems_fdisk_driver_handlers* ops;                             
  device = sc->device;                                                
  segment = sc->segment;                                              
  sd = rtems_fdisk_seg_descriptor (fd, device, segment);              
  ops = fd->devices[device].descriptor->flash_ops;                    
40005344:	e4 00 60 08 	ld  [ %g1 + 8 ], %l2                           
#if RTEMS_FDISK_TRACE                                                 
  rtems_fdisk_printf (fd, "  seg-write: %02d-%03d: o=%08x s=%d",      
40005348:	94 10 00 10 	mov  %l0, %o2                                  
4000534c:	96 10 00 1d 	mov  %i5, %o3                                  
40005350:	98 10 00 1a 	mov  %i2, %o4                                  
40005354:	9a 10 00 1c 	mov  %i4, %o5                                  
40005358:	13 10 00 c8 	sethi  %hi(0x40032000), %o1                    
4000535c:	7f ff fe ed 	call  40004f10 <rtems_fdisk_printf>            
40005360:	92 12 62 38 	or  %o1, 0x238, %o1	! 40032238 <__FUNCTION__.6501+0x1d0>
                      device, segment, offset, size);                 
#endif                                                                
  ret = ops->write (sd, device, segment, offset, buffer, size);       
40005364:	c2 04 a0 04 	ld  [ %l2 + 4 ], %g1                           
40005368:	90 10 00 11 	mov  %l1, %o0                                  
4000536c:	92 10 00 10 	mov  %l0, %o1                                  
40005370:	94 10 00 1d 	mov  %i5, %o2                                  
40005374:	96 10 00 1a 	mov  %i2, %o3                                  
40005378:	98 10 00 1b 	mov  %i3, %o4                                  
4000537c:	9f c0 40 00 	call  %g1                                      
40005380:	9a 10 00 1c 	mov  %i4, %o5                                  
  if (ret)                                                            
40005384:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40005388:	02 80 00 03 	be  40005394 <rtems_fdisk_seg_write+0x90>      <== ALWAYS TAKEN
4000538c:	82 10 20 01 	mov  1, %g1                                    
    sc->failed = true;                                                
40005390:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        <== NOT EXECUTED
                                                                      
  return ret;                                                         
}                                                                     
40005394:	81 c7 e0 08 	ret                                            
40005398:	81 e8 00 00 	restore                                        
                                                                      

400059dc <rtems_fdisk_seg_write_page>: static int rtems_fdisk_seg_write_page (rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc, uint32_t page, const void* buffer) {
400059dc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
400059e0:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
400059e4:	80 88 60 08 	btst  8, %g1                                   
400059e8:	32 80 00 0b 	bne,a   40005a14 <rtems_fdisk_seg_write_page+0x38><== ALWAYS TAKEN
400059ec:	fa 06 20 14 	ld  [ %i0 + 0x14 ], %i5                        
  {                                                                   
    int ret = rtems_fdisk_seg_blank_check_page (fd, sc, page);        
    if (ret)                                                          
      return ret;                                                     
  }                                                                   
  --fd->erased_blocks;                                                
400059f0:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        <== NOT EXECUTED
  return rtems_fdisk_seg_write (fd, sc,                               
                                page * fd->block_size, buffer, fd->block_size);
400059f4:	f8 06 20 14 	ld  [ %i0 + 0x14 ], %i4                        
  {                                                                   
    int ret = rtems_fdisk_seg_blank_check_page (fd, sc, page);        
    if (ret)                                                          
      return ret;                                                     
  }                                                                   
  --fd->erased_blocks;                                                
400059f8:	82 00 7f ff 	add  %g1, -1, %g1                              
  return rtems_fdisk_seg_write (fd, sc,                               
400059fc:	90 10 00 1a 	mov  %i2, %o0                                  
  {                                                                   
    int ret = rtems_fdisk_seg_blank_check_page (fd, sc, page);        
    if (ret)                                                          
      return ret;                                                     
  }                                                                   
  --fd->erased_blocks;                                                
40005a00:	c2 26 20 28 	st  %g1, [ %i0 + 0x28 ]                        
  return rtems_fdisk_seg_write (fd, sc,                               
40005a04:	7f ff f2 da 	call  4000256c <.umul>                         
40005a08:	92 10 00 1c 	mov  %i4, %o1                                  
40005a0c:	7f ff fe 3e 	call  40005304 <rtems_fdisk_seg_write>         
40005a10:	95 e8 00 08 	restore  %g0, %o0, %o2                         
static int                                                            
rtems_fdisk_seg_blank_check_page (const rtems_flashdisk*   fd,        
                                  rtems_fdisk_segment_ctl* sc,        
                                  uint32_t                 page)      
{                                                                     
  return rtems_fdisk_seg_blank_check (fd, sc,                         
40005a14:	90 10 00 1a 	mov  %i2, %o0                                  
40005a18:	7f ff f2 d5 	call  4000256c <.umul>                         
40005a1c:	92 10 00 1d 	mov  %i5, %o1                                  
40005a20:	92 10 00 19 	mov  %i1, %o1                                  
40005a24:	94 10 00 08 	mov  %o0, %o2                                  
40005a28:	96 10 00 1d 	mov  %i5, %o3                                  
40005a2c:	7f ff fd f3 	call  400051f8 <rtems_fdisk_seg_blank_check>   
40005a30:	90 10 00 18 	mov  %i0, %o0                                  
                            const void*              buffer)          
{                                                                     
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
  {                                                                   
    int ret = rtems_fdisk_seg_blank_check_page (fd, sc, page);        
    if (ret)                                                          
40005a34:	80 a2 20 00 	cmp  %o0, 0                                    
40005a38:	22 bf ff ef 	be,a   400059f4 <rtems_fdisk_seg_write_page+0x18><== ALWAYS TAKEN
40005a3c:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
      return ret;                                                     
  }                                                                   
  --fd->erased_blocks;                                                
  return rtems_fdisk_seg_write (fd, sc,                               
                                page * fd->block_size, buffer, fd->block_size);
}                                                                     
40005a40:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005a44:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

4000539c <rtems_fdisk_seg_write_page_desc>: static int rtems_fdisk_seg_write_page_desc (const rtems_flashdisk* fd, rtems_fdisk_segment_ctl* sc, uint32_t page, const rtems_fdisk_page_desc* page_desc) {
4000539c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  uint32_t offset = page * sizeof (rtems_fdisk_page_desc);            
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
400053a0:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
400053a4:	80 88 60 08 	btst  8, %g1                                   
400053a8:	12 80 00 04 	bne  400053b8 <rtems_fdisk_seg_write_page_desc+0x1c><== ALWAYS TAKEN
400053ac:	b5 2e a0 03 	sll  %i2, 3, %i2                               
                                           offset,                    
                                           sizeof (rtems_fdisk_page_desc));
    if (ret)                                                          
      return ret;                                                     
  }                                                                   
  return rtems_fdisk_seg_write (fd, sc, offset,                       
400053b0:	7f ff ff d5 	call  40005304 <rtems_fdisk_seg_write>         
400053b4:	99 e8 20 08 	restore  %g0, 8, %o4                           
                                 const rtems_fdisk_page_desc* page_desc)
{                                                                     
  uint32_t offset = page * sizeof (rtems_fdisk_page_desc);            
  if ((fd->flags & RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE))             
  {                                                                   
    int ret = rtems_fdisk_seg_blank_check (fd, sc,                    
400053b8:	90 10 00 18 	mov  %i0, %o0                                  
400053bc:	92 10 00 19 	mov  %i1, %o1                                  
400053c0:	94 10 00 1a 	mov  %i2, %o2                                  
400053c4:	7f ff ff 8d 	call  400051f8 <rtems_fdisk_seg_blank_check>   
400053c8:	96 10 20 08 	mov  8, %o3                                    
                                           offset,                    
                                           sizeof (rtems_fdisk_page_desc));
    if (ret)                                                          
400053cc:	80 a2 20 00 	cmp  %o0, 0                                    
400053d0:	02 bf ff f8 	be  400053b0 <rtems_fdisk_seg_write_page_desc+0x14><== ALWAYS TAKEN
400053d4:	01 00 00 00 	nop                                            
      return ret;                                                     
  }                                                                   
  return rtems_fdisk_seg_write (fd, sc, offset,                       
                                page_desc, sizeof (rtems_fdisk_page_desc));
}                                                                     
400053d8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400053dc:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

40004e2c <rtems_fdisk_segment_queue_insert_before>: static void rtems_fdisk_segment_queue_insert_before (rtems_fdisk_segment_ctl_queue* queue, rtems_fdisk_segment_ctl* item, rtems_fdisk_segment_ctl* sc) { if (item)
40004e2c:	80 a2 60 00 	cmp  %o1, 0                                    
40004e30:	02 80 00 10 	be  40004e70 <rtems_fdisk_segment_queue_insert_before+0x44><== NEVER TAKEN
40004e34:	84 10 00 08 	mov  %o0, %g2                                  
  {                                                                   
    rtems_fdisk_segment_ctl** prev = &queue->head;                    
    rtems_fdisk_segment_ctl*  it = queue->head;                       
40004e38:	c2 02 00 00 	ld  [ %o0 ], %g1                               
                                                                      
    while (it)                                                        
40004e3c:	80 a0 60 00 	cmp  %g1, 0                                    
40004e40:	02 80 00 0c 	be  40004e70 <rtems_fdisk_segment_queue_insert_before+0x44><== NEVER TAKEN
40004e44:	80 a2 40 01 	cmp  %o1, %g1                                  
    {                                                                 
      if (item == it)                                                 
40004e48:	32 80 00 08 	bne,a   40004e68 <rtems_fdisk_segment_queue_insert_before+0x3c>
40004e4c:	84 10 00 01 	mov  %g1, %g2                                  
      {                                                               
        sc->next = item;                                              
40004e50:	d2 22 80 00 	st  %o1, [ %o2 ]                               
        *prev = sc;                                                   
        queue->count++;                                               
40004e54:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           
    while (it)                                                        
    {                                                                 
      if (item == it)                                                 
      {                                                               
        sc->next = item;                                              
        *prev = sc;                                                   
40004e58:	d4 20 80 00 	st  %o2, [ %g2 ]                               
        queue->count++;                                               
40004e5c:	82 00 60 01 	inc  %g1                                       
        return;                                                       
40004e60:	81 c3 e0 08 	retl                                           
40004e64:	c2 22 20 08 	st  %g1, [ %o0 + 8 ]                           
      }                                                               
                                                                      
      prev = &it->next;                                               
      it = it->next;                                                  
40004e68:	10 bf ff f5 	b  40004e3c <rtems_fdisk_segment_queue_insert_before+0x10>
40004e6c:	c2 00 40 00 	ld  [ %g1 ], %g1                               
    }                                                                 
  }                                                                   
                                                                      
  rtems_fdisk_segment_queue_push_tail (queue, sc);                    
40004e70:	92 10 00 0a 	mov  %o2, %o1                                  <== NOT EXECUTED
40004e74:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
40004e78:	7f ff ff be 	call  40004d70 <rtems_fdisk_segment_queue_push_tail><== NOT EXECUTED
40004e7c:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                                                      

40004d30 <rtems_fdisk_segment_queue_pop_head>: /** * Pop the head of the segment control queue. */ static rtems_fdisk_segment_ctl* rtems_fdisk_segment_queue_pop_head (rtems_fdisk_segment_ctl_queue* queue) {
40004d30:	82 10 00 08 	mov  %o0, %g1                                  
  if (queue->head)                                                    
40004d34:	d0 02 00 00 	ld  [ %o0 ], %o0                               
40004d38:	80 a2 20 00 	cmp  %o0, 0                                    
40004d3c:	02 80 00 0b 	be  40004d68 <rtems_fdisk_segment_queue_pop_head+0x38><== NEVER TAKEN
40004d40:	01 00 00 00 	nop                                            
  {                                                                   
    rtems_fdisk_segment_ctl* sc = queue->head;                        
                                                                      
    queue->head = sc->next;                                           
40004d44:	c4 02 00 00 	ld  [ %o0 ], %g2                               
    if (!queue->head)                                                 
40004d48:	80 a0 a0 00 	cmp  %g2, 0                                    
40004d4c:	12 80 00 03 	bne  40004d58 <rtems_fdisk_segment_queue_pop_head+0x28>
40004d50:	c4 20 40 00 	st  %g2, [ %g1 ]                               
      queue->tail = 0;                                                
40004d54:	c0 20 60 04 	clr  [ %g1 + 4 ]                               
                                                                      
    queue->count--;                                                   
40004d58:	c4 00 60 08 	ld  [ %g1 + 8 ], %g2                           
40004d5c:	84 00 bf ff 	add  %g2, -1, %g2                              
40004d60:	c4 20 60 08 	st  %g2, [ %g1 + 8 ]                           
                                                                      
    sc->next = 0;                                                     
40004d64:	c0 22 00 00 	clr  [ %o0 ]                                   
                                                                      
    return sc;                                                        
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40004d68:	81 c3 e0 08 	retl                                           
                                                                      

40004cf4 <rtems_fdisk_segment_queue_push_head>: */ static void rtems_fdisk_segment_queue_push_head (rtems_fdisk_segment_ctl_queue* queue, rtems_fdisk_segment_ctl* sc) { if (sc)
40004cf4:	80 a2 60 00 	cmp  %o1, 0                                    <== NOT EXECUTED
40004cf8:	02 80 00 0c 	be  40004d28 <rtems_fdisk_segment_queue_push_head+0x34><== NOT EXECUTED
40004cfc:	01 00 00 00 	nop                                            <== NOT EXECUTED
  {                                                                   
    sc->next = queue->head;                                           
40004d00:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
40004d04:	c2 22 40 00 	st  %g1, [ %o1 ]                               <== NOT EXECUTED
    queue->head = sc;                                                 
                                                                      
    if (queue->tail == 0)                                             
40004d08:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           <== NOT EXECUTED
40004d0c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40004d10:	12 80 00 03 	bne  40004d1c <rtems_fdisk_segment_queue_push_head+0x28><== NOT EXECUTED
40004d14:	d2 22 00 00 	st  %o1, [ %o0 ]                               <== NOT EXECUTED
      queue->tail = sc;                                               
40004d18:	d2 22 20 04 	st  %o1, [ %o0 + 4 ]                           <== NOT EXECUTED
    queue->count++;                                                   
40004d1c:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           <== NOT EXECUTED
40004d20:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
40004d24:	c2 22 20 08 	st  %g1, [ %o0 + 8 ]                           <== NOT EXECUTED
40004d28:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
                                                                      

40004d70 <rtems_fdisk_segment_queue_push_tail>: */ static void rtems_fdisk_segment_queue_push_tail (rtems_fdisk_segment_ctl_queue* queue, rtems_fdisk_segment_ctl* sc) { if (sc)
40004d70:	80 a2 60 00 	cmp  %o1, 0                                    
40004d74:	02 80 00 0f 	be  40004db0 <rtems_fdisk_segment_queue_push_tail+0x40><== NEVER TAKEN
40004d78:	01 00 00 00 	nop                                            
  {                                                                   
    sc->next = 0;                                                     
                                                                      
    if (queue->head)                                                  
40004d7c:	c2 02 00 00 	ld  [ %o0 ], %g1                               
40004d80:	80 a0 60 00 	cmp  %g1, 0                                    
40004d84:	02 80 00 06 	be  40004d9c <rtems_fdisk_segment_queue_push_tail+0x2c>
40004d88:	c0 22 40 00 	clr  [ %o1 ]                                   
    {                                                                 
      queue->tail->next = sc;                                         
40004d8c:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           
40004d90:	d2 20 40 00 	st  %o1, [ %g1 ]                               
40004d94:	10 80 00 04 	b  40004da4 <rtems_fdisk_segment_queue_push_tail+0x34>
40004d98:	d2 22 20 04 	st  %o1, [ %o0 + 4 ]                           
      queue->tail       = sc;                                         
    }                                                                 
    else                                                              
    {                                                                 
      queue->head = queue->tail = sc;                                 
40004d9c:	d2 22 20 04 	st  %o1, [ %o0 + 4 ]                           
40004da0:	d2 22 00 00 	st  %o1, [ %o0 ]                               
    }                                                                 
                                                                      
    queue->count++;                                                   
40004da4:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           
40004da8:	82 00 60 01 	inc  %g1                                       
40004dac:	c2 22 20 08 	st  %g1, [ %o0 + 8 ]                           
40004db0:	81 c3 e0 08 	retl                                           
                                                                      

40004db8 <rtems_fdisk_segment_queue_remove>: static void rtems_fdisk_segment_queue_remove (rtems_fdisk_segment_ctl_queue* queue, rtems_fdisk_segment_ctl* sc) { rtems_fdisk_segment_ctl* prev = 0; rtems_fdisk_segment_ctl* it = queue->head;
40004db8:	c2 02 00 00 	ld  [ %o0 ], %g1                               
 */                                                                   
static void                                                           
rtems_fdisk_segment_queue_remove (rtems_fdisk_segment_ctl_queue* queue,
                                  rtems_fdisk_segment_ctl*       sc)  
{                                                                     
  rtems_fdisk_segment_ctl* prev = 0;                                  
40004dbc:	84 10 20 00 	clr  %g2                                       
                                                                      
  /*                                                                  
   * Do not change sc->next as sc could be on another queue.          
   */                                                                 
                                                                      
  while (it)                                                          
40004dc0:	80 a0 60 00 	cmp  %g1, 0                                    
40004dc4:	02 80 00 18 	be  40004e24 <rtems_fdisk_segment_queue_remove+0x6c>
40004dc8:	80 a2 40 01 	cmp  %o1, %g1                                  
  {                                                                   
    if (sc == it)                                                     
40004dcc:	32 80 00 14 	bne,a   40004e1c <rtems_fdisk_segment_queue_remove+0x64>
40004dd0:	84 10 00 01 	mov  %g1, %g2                                  
    {                                                                 
      if (prev == 0)                                                  
40004dd4:	80 a0 a0 00 	cmp  %g2, 0                                    
40004dd8:	12 80 00 07 	bne  40004df4 <rtems_fdisk_segment_queue_remove+0x3c>
40004ddc:	c2 02 40 00 	ld  [ %o1 ], %g1                               
      {                                                               
        queue->head = sc->next;                                       
        if (queue->head == 0)                                         
40004de0:	80 a0 60 00 	cmp  %g1, 0                                    
40004de4:	12 80 00 09 	bne  40004e08 <rtems_fdisk_segment_queue_remove+0x50>
40004de8:	c2 22 00 00 	st  %g1, [ %o0 ]                               
          queue->tail = 0;                                            
40004dec:	10 80 00 07 	b  40004e08 <rtems_fdisk_segment_queue_remove+0x50>
40004df0:	c0 22 20 04 	clr  [ %o0 + 4 ]                               
      }                                                               
      else                                                            
      {                                                               
        prev->next = sc->next;                                        
40004df4:	c2 20 80 00 	st  %g1, [ %g2 ]                               
        if (queue->tail == sc)                                        
40004df8:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           
40004dfc:	80 a0 40 09 	cmp  %g1, %o1                                  
40004e00:	22 80 00 02 	be,a   40004e08 <rtems_fdisk_segment_queue_remove+0x50><== ALWAYS TAKEN
40004e04:	c4 22 20 04 	st  %g2, [ %o0 + 4 ]                           
          queue->tail = prev;                                         
      }                                                               
      sc->next = 0;                                                   
      queue->count--;                                                 
40004e08:	c2 02 20 08 	ld  [ %o0 + 8 ], %g1                           
      {                                                               
        prev->next = sc->next;                                        
        if (queue->tail == sc)                                        
          queue->tail = prev;                                         
      }                                                               
      sc->next = 0;                                                   
40004e0c:	c0 22 40 00 	clr  [ %o1 ]                                   
      queue->count--;                                                 
40004e10:	82 00 7f ff 	add  %g1, -1, %g1                              
      break;                                                          
40004e14:	81 c3 e0 08 	retl                                           
40004e18:	c2 22 20 08 	st  %g1, [ %o0 + 8 ]                           
    }                                                                 
                                                                      
    prev = it;                                                        
    it = it->next;                                                    
40004e1c:	10 bf ff e9 	b  40004dc0 <rtems_fdisk_segment_queue_remove+0x8>
40004e20:	c2 00 40 00 	ld  [ %g1 ], %g1                               
40004e24:	81 c3 e0 08 	retl                                           
                                                                      

40005018 <rtems_fdisk_warning>: * @param ... The arguments for the format text. * @return int The number of bytes written to the output. */ static int rtems_fdisk_warning (const rtems_flashdisk* fd, const char *format, ...) {
40005018:	9d e3 bf 98 	save  %sp, -104, %sp                           <== NOT EXECUTED
  int ret = 0;                                                        
  if (fd->info_level >= 1)                                            
  {                                                                   
    va_list args;                                                     
    va_start (args, format);                                          
4000501c:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        <== NOT EXECUTED
40005020:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        <== NOT EXECUTED
40005024:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        <== NOT EXECUTED
40005028:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        <== NOT EXECUTED
 */                                                                   
static int                                                            
rtems_fdisk_warning (const rtems_flashdisk* fd, const char *format, ...)
{                                                                     
  int ret = 0;                                                        
  if (fd->info_level >= 1)                                            
4000502c:	c2 06 20 6c 	ld  [ %i0 + 0x6c ], %g1                        <== NOT EXECUTED
40005030:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40005034:	02 80 00 18 	be  40005094 <rtems_fdisk_warning+0x7c>        <== NOT EXECUTED
40005038:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
  {                                                                   
    va_list args;                                                     
    va_start (args, format);                                          
4000503c:	82 07 a0 4c 	add  %fp, 0x4c, %g1                            <== NOT EXECUTED
    fprintf (stdout, "fdisk:warning:");                               
40005040:	7f ff f1 0e 	call  40001478 <__getreent>                    <== NOT EXECUTED
40005044:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          <== NOT EXECUTED
40005048:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           <== NOT EXECUTED
4000504c:	11 10 00 c8 	sethi  %hi(0x40032000), %o0                    <== NOT EXECUTED
40005050:	40 00 71 81 	call  40021654 <fputs>                         <== NOT EXECUTED
40005054:	90 12 21 98 	or  %o0, 0x198, %o0	! 40032198 <__FUNCTION__.6501+0x130><== NOT EXECUTED
    ret =  vfprintf (stdout, format, args);                           
40005058:	7f ff f1 08 	call  40001478 <__getreent>                    <== NOT EXECUTED
4000505c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40005060:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          <== NOT EXECUTED
40005064:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
40005068:	40 00 94 5a 	call  4002a1d0 <vfprintf>                      <== NOT EXECUTED
4000506c:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
    fprintf (stdout, "\n");                                           
40005070:	7f ff f1 02 	call  40001478 <__getreent>                    <== NOT EXECUTED
40005074:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
40005078:	d2 02 20 08 	ld  [ %o0 + 8 ], %o1                           <== NOT EXECUTED
4000507c:	40 00 71 42 	call  40021584 <fputc>                         <== NOT EXECUTED
40005080:	90 10 20 0a 	mov  0xa, %o0                                  <== NOT EXECUTED
    fflush (stdout);                                                  
40005084:	7f ff f0 fd 	call  40001478 <__getreent>                    <== NOT EXECUTED
40005088:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000508c:	40 00 70 43 	call  40021198 <fflush>                        <== NOT EXECUTED
40005090:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
    va_end (args);                                                    
  }                                                                   
  return ret;                                                         
}                                                                     
40005094:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005098:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4000c3c0 <rtems_filesystem_check_access>: int eval_flags, mode_t node_mode, uid_t node_uid, gid_t node_gid ) {
4000c3c0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  mode_t perm_flags = eval_flags & RTEMS_FS_PERMS_RWX;                
  uid_t task_uid = geteuid();                                         
4000c3c4:	7f ff ff 73 	call  4000c190 <geteuid>                       
4000c3c8:	b0 0e 20 07 	and  %i0, 7, %i0                               
                                                                      
  if (task_uid == 0 || task_uid == node_uid) {                        
4000c3cc:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
4000c3d0:	91 32 20 10 	srl  %o0, 0x10, %o0                            
4000c3d4:	80 a2 00 1a 	cmp  %o0, %i2                                  
4000c3d8:	22 80 00 12 	be,a   4000c420 <rtems_filesystem_check_access+0x60>
4000c3dc:	b1 2e 20 06 	sll  %i0, 6, %i0                               
4000c3e0:	80 a2 20 00 	cmp  %o0, 0                                    
4000c3e4:	12 80 00 04 	bne  4000c3f4 <rtems_filesystem_check_access+0x34>
4000c3e8:	01 00 00 00 	nop                                            
4000c3ec:	10 80 00 0d 	b  4000c420 <rtems_filesystem_check_access+0x60>
4000c3f0:	b1 2e 20 06 	sll  %i0, 6, %i0                               
    perm_flags <<= RTEMS_FS_USR_SHIFT;                                
  } else {                                                            
    gid_t task_gid = getegid();                                       
4000c3f4:	7f ff ff 61 	call  4000c178 <getegid>                       
4000c3f8:	01 00 00 00 	nop                                            
                                                                      
    if (task_gid == 0 || task_gid == node_gid) {                      
4000c3fc:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
4000c400:	91 32 20 10 	srl  %o0, 0x10, %o0                            
4000c404:	80 a2 00 1b 	cmp  %o0, %i3                                  
4000c408:	22 80 00 06 	be,a   4000c420 <rtems_filesystem_check_access+0x60>
4000c40c:	b1 2e 20 03 	sll  %i0, 3, %i0                               
4000c410:	80 a2 20 00 	cmp  %o0, 0                                    
4000c414:	32 80 00 04 	bne,a   4000c424 <rtems_filesystem_check_access+0x64><== ALWAYS TAKEN
4000c418:	b0 2e 00 19 	andn  %i0, %i1, %i0                            
      perm_flags <<= RTEMS_FS_GRP_SHIFT;                              
4000c41c:	b1 2e 20 03 	sll  %i0, 3, %i0                               <== NOT EXECUTED
    } else {                                                          
      perm_flags <<= RTEMS_FS_OTH_SHIFT;                              
    }                                                                 
  }                                                                   
                                                                      
  return (perm_flags & node_mode) == perm_flags;                      
4000c420:	b0 2e 00 19 	andn  %i0, %i1, %i0                            
}                                                                     
4000c424:	80 a0 00 18 	cmp  %g0, %i0                                  
4000c428:	b0 60 3f ff 	subx  %g0, -1, %i0                             
4000c42c:	81 c7 e0 08 	ret                                            
4000c430:	81 e8 00 00 	restore                                        
                                                                      

400042c4 <rtems_filesystem_chmod>: int rtems_filesystem_chmod( const rtems_filesystem_location_info_t *loc, mode_t mode ) {
400042c4:	9d e3 bf 58 	save  %sp, -168, %sp                           
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
400042c8:	f8 06 20 14 	ld  [ %i0 + 0x14 ], %i4                        
  int rv;                                                             
                                                                      
  if ( mt_entry->writeable || rtems_filesystem_location_is_null( loc ) ) {
400042cc:	c2 0f 20 29 	ldub  [ %i4 + 0x29 ], %g1                      
400042d0:	80 a0 60 00 	cmp  %g1, 0                                    
400042d4:	12 80 00 07 	bne  400042f0 <rtems_filesystem_chmod+0x2c>    
400042d8:	03 10 00 4b 	sethi  %hi(0x40012c00), %g1                    
400042dc:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
400042e0:	82 10 61 28 	or  %g1, 0x128, %g1                            
400042e4:	80 a0 80 01 	cmp  %g2, %g1                                  
400042e8:	12 80 00 26 	bne  40004380 <rtems_filesystem_chmod+0xbc>    <== NEVER TAKEN
400042ec:	01 00 00 00 	nop                                            
    struct stat st;                                                   
                                                                      
    memset( &st, 0, sizeof(st) );                                     
400042f0:	92 10 20 00 	clr  %o1	! 0 <_TLS_BSS_size>                   
400042f4:	94 10 20 48 	mov  0x48, %o2                                 
400042f8:	40 00 22 f8 	call  4000ced8 <memset>                        
400042fc:	90 07 bf b8 	add  %fp, -72, %o0                             
                                                                      
    rv = (*loc->handlers->fstat_h)( loc, &st );                       
40004300:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
40004304:	90 10 00 18 	mov  %i0, %o0                                  
40004308:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
4000430c:	9f c0 40 00 	call  %g1                                      
40004310:	92 07 bf b8 	add  %fp, -72, %o1                             
    if ( rv == 0 ) {                                                  
40004314:	80 a2 20 00 	cmp  %o0, 0                                    
40004318:	32 80 00 20 	bne,a   40004398 <rtems_filesystem_chmod+0xd4> 
4000431c:	b0 10 00 08 	mov  %o0, %i0                                  
      uid_t uid = geteuid();                                          
40004320:	40 00 00 91 	call  40004564 <geteuid>                       
40004324:	01 00 00 00 	nop                                            
                                                                      
      if ( uid == 0 || st.st_uid == uid ) {                           
40004328:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
4000432c:	91 32 20 10 	srl  %o0, 0x10, %o0                            
40004330:	80 a2 20 00 	cmp  %o0, 0                                    
40004334:	02 80 00 05 	be  40004348 <rtems_filesystem_chmod+0x84>     
40004338:	c2 17 bf ca 	lduh  [ %fp + -54 ], %g1                       
4000433c:	80 a0 40 08 	cmp  %g1, %o0                                  
40004340:	12 80 00 0c 	bne  40004370 <rtems_filesystem_chmod+0xac>    
40004344:	01 00 00 00 	nop                                            
        mode_t mask = S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX;
                                                                      
        mode = (st.st_mode & ~mask) | (mode & mask);                  
                                                                      
        rv = (*mt_entry->ops->fchmod_h)( loc, mode );                 
40004348:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
      uid_t uid = geteuid();                                          
                                                                      
      if ( uid == 0 || st.st_uid == uid ) {                           
        mode_t mask = S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX;
                                                                      
        mode = (st.st_mode & ~mask) | (mode & mask);                  
4000434c:	c4 07 bf c4 	ld  [ %fp + -60 ], %g2                         
                                                                      
        rv = (*mt_entry->ops->fchmod_h)( loc, mode );                 
40004350:	c2 00 60 20 	ld  [ %g1 + 0x20 ], %g1                        
      uid_t uid = geteuid();                                          
                                                                      
      if ( uid == 0 || st.st_uid == uid ) {                           
        mode_t mask = S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX;
                                                                      
        mode = (st.st_mode & ~mask) | (mode & mask);                  
40004354:	b2 0e 6f ff 	and  %i1, 0xfff, %i1                           
40004358:	92 08 b0 00 	and  %g2, -4096, %o1                           
                                                                      
        rv = (*mt_entry->ops->fchmod_h)( loc, mode );                 
4000435c:	90 10 00 18 	mov  %i0, %o0                                  
40004360:	9f c0 40 00 	call  %g1                                      
40004364:	92 16 40 09 	or  %i1, %o1, %o1                              
                                                                      
    rv = (*loc->handlers->fstat_h)( loc, &st );                       
    if ( rv == 0 ) {                                                  
      uid_t uid = geteuid();                                          
                                                                      
      if ( uid == 0 || st.st_uid == uid ) {                           
40004368:	81 c7 e0 08 	ret                                            
4000436c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      
        mode = (st.st_mode & ~mask) | (mode & mask);                  
                                                                      
        rv = (*mt_entry->ops->fchmod_h)( loc, mode );                 
      } else {                                                        
        errno = EPERM;                                                
40004370:	40 00 22 6d 	call  4000cd24 <__errno>                       
40004374:	01 00 00 00 	nop                                            
40004378:	10 80 00 05 	b  4000438c <rtems_filesystem_chmod+0xc8>      
4000437c:	82 10 20 01 	mov  1, %g1	! 1 <_TLS_Alignment>               
        rv = -1;                                                      
      }                                                               
    }                                                                 
  } else {                                                            
    errno = EROFS;                                                    
40004380:	40 00 22 69 	call  4000cd24 <__errno>                       <== NOT EXECUTED
40004384:	01 00 00 00 	nop                                            <== NOT EXECUTED
40004388:	82 10 20 1e 	mov  0x1e, %g1	! 1e <_TLS_Alignment+0x1d>      <== NOT EXECUTED
4000438c:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    rv = -1;                                                          
40004390:	90 10 3f ff 	mov  -1, %o0                                   
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40004394:	b0 10 00 08 	mov  %o0, %i0                                  
40004398:	81 c7 e0 08 	ret                                            
4000439c:	81 e8 00 00 	restore                                        
                                                                      

400043a0 <rtems_filesystem_chown>: int rtems_filesystem_chown( const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group ) {
400043a0:	9d e3 bf 58 	save  %sp, -168, %sp                           
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
400043a4:	f8 06 20 14 	ld  [ %i0 + 0x14 ], %i4                        
  int rv;                                                             
                                                                      
  if ( mt_entry->writeable || rtems_filesystem_location_is_null( loc ) ) {
400043a8:	c2 0f 20 29 	ldub  [ %i4 + 0x29 ], %g1                      
400043ac:	80 a0 60 00 	cmp  %g1, 0                                    
400043b0:	12 80 00 07 	bne  400043cc <rtems_filesystem_chown+0x2c>    
400043b4:	03 10 00 4b 	sethi  %hi(0x40012c00), %g1                    
400043b8:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
400043bc:	82 10 61 28 	or  %g1, 0x128, %g1                            
400043c0:	80 a0 80 01 	cmp  %g2, %g1                                  
400043c4:	12 80 00 24 	bne  40004454 <rtems_filesystem_chown+0xb4>    <== NEVER TAKEN
400043c8:	01 00 00 00 	nop                                            
    struct stat st;                                                   
                                                                      
    memset( &st, 0, sizeof(st) );                                     
400043cc:	92 10 20 00 	clr  %o1	! 0 <_TLS_BSS_size>                   
400043d0:	94 10 20 48 	mov  0x48, %o2                                 
400043d4:	40 00 22 c1 	call  4000ced8 <memset>                        
400043d8:	90 07 bf b8 	add  %fp, -72, %o0                             
                                                                      
    rv = (*loc->handlers->fstat_h)( loc, &st );                       
400043dc:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
400043e0:	90 10 00 18 	mov  %i0, %o0                                  
400043e4:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
400043e8:	9f c0 40 00 	call  %g1                                      
400043ec:	92 07 bf b8 	add  %fp, -72, %o1                             
    if ( rv == 0 ) {                                                  
400043f0:	80 a2 20 00 	cmp  %o0, 0                                    
400043f4:	32 80 00 1e 	bne,a   4000446c <rtems_filesystem_chown+0xcc> 
400043f8:	b0 10 00 08 	mov  %o0, %i0                                  
      uid_t uid = geteuid();                                          
400043fc:	40 00 00 5a 	call  40004564 <geteuid>                       
40004400:	01 00 00 00 	nop                                            
                                                                      
      if ( uid == 0 || st.st_uid == uid ) {                           
40004404:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
40004408:	91 32 20 10 	srl  %o0, 0x10, %o0                            
4000440c:	80 a2 20 00 	cmp  %o0, 0                                    
40004410:	02 80 00 05 	be  40004424 <rtems_filesystem_chown+0x84>     
40004414:	c2 17 bf ca 	lduh  [ %fp + -54 ], %g1                       
40004418:	80 a0 40 08 	cmp  %g1, %o0                                  
4000441c:	12 80 00 0a 	bne  40004444 <rtems_filesystem_chown+0xa4>    
40004420:	01 00 00 00 	nop                                            
        rv = (*mt_entry->ops->chown_h)( loc, owner, group );          
40004424:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
40004428:	90 10 00 18 	mov  %i0, %o0                                  
4000442c:	c2 00 60 24 	ld  [ %g1 + 0x24 ], %g1                        
40004430:	92 10 00 19 	mov  %i1, %o1                                  
40004434:	9f c0 40 00 	call  %g1                                      
40004438:	94 10 00 1a 	mov  %i2, %o2                                  
4000443c:	81 c7 e0 08 	ret                                            
40004440:	91 e8 00 08 	restore  %g0, %o0, %o0                         
      } else {                                                        
        errno = EPERM;                                                
40004444:	40 00 22 38 	call  4000cd24 <__errno>                       
40004448:	01 00 00 00 	nop                                            
4000444c:	10 80 00 05 	b  40004460 <rtems_filesystem_chown+0xc0>      
40004450:	82 10 20 01 	mov  1, %g1	! 1 <_TLS_Alignment>               
        rv = -1;                                                      
      }                                                               
    }                                                                 
  } else {                                                            
    errno = EROFS;                                                    
40004454:	40 00 22 34 	call  4000cd24 <__errno>                       <== NOT EXECUTED
40004458:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000445c:	82 10 20 1e 	mov  0x1e, %g1	! 1e <_TLS_Alignment+0x1d>      <== NOT EXECUTED
40004460:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    rv = -1;                                                          
40004464:	90 10 3f ff 	mov  -1, %o0                                   
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40004468:	b0 10 00 08 	mov  %o0, %i0                                  
4000446c:	81 c7 e0 08 	ret                                            
40004470:	81 e8 00 00 	restore                                        
                                                                      

4000495c <rtems_filesystem_do_unmount>: } void rtems_filesystem_do_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
4000495c:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
extern pthread_key_t rtems_current_user_env_key;                      
                                                                      
static inline void rtems_libio_lock( void )                           
{                                                                     
  rtems_semaphore_obtain( rtems_libio_semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT );
40004960:	3b 10 00 60 	sethi  %hi(0x40018000), %i5                    
40004964:	d0 07 63 38 	ld  [ %i5 + 0x338 ], %o0	! 40018338 <rtems_libio_semaphore>
40004968:	92 10 20 00 	clr  %o1                                       
4000496c:	40 00 0b 3d 	call  40007660 <rtems_semaphore_obtain>        
40004970:	94 10 20 00 	clr  %o2                                       
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
40004974:	c4 06 00 00 	ld  [ %i0 ], %g2                               
  previous       = the_node->previous;                                
40004978:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
}                                                                     
                                                                      
static inline void rtems_libio_unlock( void )                         
{                                                                     
  rtems_semaphore_release( rtems_libio_semaphore );                   
4000497c:	d0 07 63 38 	ld  [ %i5 + 0x338 ], %o0                       
  next->previous = previous;                                          
40004980:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
40004984:	40 00 0b 7f 	call  40007780 <rtems_semaphore_release>       
40004988:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  rtems_filesystem_mt_lock();                                         
  rtems_chain_extract_unprotected(&mt_entry->mt_node);                
  rtems_filesystem_mt_unlock();                                       
  rtems_filesystem_global_location_release(mt_entry->mt_point_node);  
4000498c:	40 00 00 60 	call  40004b0c <rtems_filesystem_global_location_release>
40004990:	d0 06 20 20 	ld  [ %i0 + 0x20 ], %o0                        
  (*mt_entry->ops->fsunmount_me_h)(mt_entry);                         
40004994:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
40004998:	c2 00 60 3c 	ld  [ %g1 + 0x3c ], %g1                        
4000499c:	9f c0 40 00 	call  %g1                                      
400049a0:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  if (mt_entry->unmount_task != 0) {                                  
400049a4:	d0 06 20 3c 	ld  [ %i0 + 0x3c ], %o0                        
400049a8:	80 a2 20 00 	cmp  %o0, 0                                    
400049ac:	02 80 00 09 	be  400049d0 <rtems_filesystem_do_unmount+0x74><== NEVER TAKEN
400049b0:	01 00 00 00 	nop                                            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_status_code rtems_event_transient_send(    
  rtems_id id                                                         
)                                                                     
{                                                                     
  return rtems_event_system_send( id, RTEMS_EVENT_SYSTEM_TRANSIENT ); 
400049b4:	40 00 0b a0 	call  40007834 <rtems_event_system_send>       
400049b8:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
    rtems_status_code sc =                                            
      rtems_event_transient_send(mt_entry->unmount_task);             
    if (sc != RTEMS_SUCCESSFUL) {                                     
400049bc:	80 a2 20 00 	cmp  %o0, 0                                    
400049c0:	02 80 00 04 	be  400049d0 <rtems_filesystem_do_unmount+0x74><== ALWAYS TAKEN
400049c4:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
      rtems_fatal_error_occurred(0xdeadbeef);                         
400049c8:	40 00 0c ef 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
400049cc:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
  free(mt_entry);                                                     
400049d0:	7f ff fb 8f 	call  4000380c <free>                          
400049d4:	81 e8 00 00 	restore                                        
                                                                      

4000c468 <rtems_filesystem_eval_path_generic>: void rtems_filesystem_eval_path_generic( rtems_filesystem_eval_path_context_t *ctx, void *arg, const rtems_filesystem_eval_path_generic_config *config ) {
4000c468:	9d e3 bf a0 	save  %sp, -96, %sp                            
            } else {                                                  
              /* This is the root file system */                      
              status = (*config->eval_token)(ctx, arg, ".", 1);       
            }                                                         
          } else {                                                    
            status = (*config->eval_token)(ctx, arg, "..", 2);        
4000c46c:	23 10 00 58 	sethi  %hi(0x40016000), %l1                    
                ¤tloc->mt_entry->mt_point_node                  
              );                                                      
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;       
            } else {                                                  
              /* This is the root file system */                      
              status = (*config->eval_token)(ctx, arg, ".", 1);       
4000c470:	3b 10 00 58 	sethi  %hi(0x40016000), %i5                    
              rtems_filesystem_eval_path_error(ctx, EINVAL);          
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;       
            }                                                         
          }                                                           
        } else if (rtems_filesystem_is_parent_directory(token, tokenlen)) {
          rtems_filesystem_location_info_t *currentloc =              
4000c474:	a0 06 20 18 	add  %i0, 0x18, %l0                            
            } else {                                                  
              /* This is the root file system */                      
              status = (*config->eval_token)(ctx, arg, ".", 1);       
            }                                                         
          } else {                                                    
            status = (*config->eval_token)(ctx, arg, "..", 2);        
4000c478:	a2 14 63 38 	or  %l1, 0x338, %l1                            
                ¤tloc->mt_entry->mt_point_node                  
              );                                                      
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;       
            } else {                                                  
              /* This is the root file system */                      
              status = (*config->eval_token)(ctx, arg, ".", 1);       
4000c47c:	ba 17 63 30 	or  %i5, 0x330, %i5                            
  rtems_filesystem_eval_path_context_t *ctx,                          
  const char **token,                                                 
  size_t *tokenlen                                                    
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_next_token(ctx);                         
4000c480:	40 00 00 96 	call  4000c6d8 <rtems_filesystem_eval_path_next_token>
4000c484:	90 10 00 18 	mov  %i0, %o0                                  
  *token = ctx->token;                                                
  *tokenlen = ctx->tokenlen;                                          
4000c488:	f8 06 20 0c 	ld  [ %i0 + 0xc ], %i4                         
    const char *token;                                                
    size_t tokenlen;                                                  
                                                                      
    rtems_filesystem_eval_path_get_next_token(ctx, &token, &tokenlen);
                                                                      
    if (tokenlen > 0) {                                               
4000c48c:	80 a7 20 00 	cmp  %i4, 0                                    
4000c490:	02 80 00 50 	be  4000c5d0 <rtems_filesystem_eval_path_generic+0x168>
4000c494:	f6 06 20 08 	ld  [ %i0 + 8 ], %i3                           
      if ((*config->is_directory)(ctx, arg)) {                        
4000c498:	c2 06 80 00 	ld  [ %i2 ], %g1                               
4000c49c:	90 10 00 18 	mov  %i0, %o0                                  
4000c4a0:	9f c0 40 00 	call  %g1                                      
4000c4a4:	92 10 00 19 	mov  %i1, %o1                                  
4000c4a8:	80 a2 20 00 	cmp  %o0, 0                                    
4000c4ac:	02 80 00 71 	be  4000c670 <rtems_filesystem_eval_path_generic+0x208>
4000c4b0:	80 a7 20 01 	cmp  %i4, 1                                    
static inline bool rtems_filesystem_is_current_directory(             
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  return tokenlen == 1 && token [0] == '.';                           
4000c4b4:	12 80 00 06 	bne  4000c4cc <rtems_filesystem_eval_path_generic+0x64>
4000c4b8:	82 10 20 00 	clr  %g1                                       
4000c4bc:	c2 4e c0 00 	ldsb  [ %i3 ], %g1                             
4000c4c0:	82 18 60 2e 	xor  %g1, 0x2e, %g1                            
4000c4c4:	80 a0 00 01 	cmp  %g0, %g1                                  
4000c4c8:	82 60 3f ff 	subx  %g0, -1, %g1                             
        if (rtems_filesystem_is_current_directory(token, tokenlen)) { 
4000c4cc:	80 a0 60 00 	cmp  %g1, 0                                    
4000c4d0:	02 80 00 0d 	be  4000c504 <rtems_filesystem_eval_path_generic+0x9c>
4000c4d4:	80 a7 20 02 	cmp  %i4, 2                                    
          if (rtems_filesystem_eval_path_has_path(ctx)) {             
4000c4d8:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
4000c4dc:	80 a0 60 00 	cmp  %g1, 0                                    
4000c4e0:	32 80 00 3e 	bne,a   4000c5d8 <rtems_filesystem_eval_path_generic+0x170>
4000c4e4:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
            status = (*config->eval_token)(ctx, arg, ".", 1);         
          } else {                                                    
            int eval_flags = rtems_filesystem_eval_path_get_flags(ctx);
                                                                      
            if ((eval_flags & RTEMS_FS_REJECT_TERMINAL_DOT) == 0) {   
4000c4e8:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
4000c4ec:	80 88 61 00 	btst  0x100, %g1                               
4000c4f0:	22 80 00 3a 	be,a   4000c5d8 <rtems_filesystem_eval_path_generic+0x170>
4000c4f4:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
              status = (*config->eval_token)(ctx, arg, ".", 1);       
            } else {                                                  
              rtems_filesystem_eval_path_error(ctx, EINVAL);          
4000c4f8:	90 10 00 18 	mov  %i0, %o0                                  
4000c4fc:	10 80 00 59 	b  4000c660 <rtems_filesystem_eval_path_generic+0x1f8>
4000c500:	92 10 20 16 	mov  0x16, %o1                                 
static inline bool rtems_filesystem_is_parent_directory(              
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  return tokenlen == 2 && token [0] == '.' && token [1] == '.';       
4000c504:	12 80 00 0a 	bne  4000c52c <rtems_filesystem_eval_path_generic+0xc4>
4000c508:	82 10 20 00 	clr  %g1                                       
4000c50c:	c4 4e c0 00 	ldsb  [ %i3 ], %g2                             
4000c510:	80 a0 a0 2e 	cmp  %g2, 0x2e                                 
4000c514:	12 80 00 07 	bne  4000c530 <rtems_filesystem_eval_path_generic+0xc8>
4000c518:	80 a0 60 00 	cmp  %g1, 0                                    
4000c51c:	c2 4e e0 01 	ldsb  [ %i3 + 1 ], %g1                         
4000c520:	82 18 60 2e 	xor  %g1, 0x2e, %g1                            
4000c524:	80 a0 00 01 	cmp  %g0, %g1                                  
4000c528:	82 60 3f ff 	subx  %g0, -1, %g1                             
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;       
            }                                                         
          }                                                           
        } else if (rtems_filesystem_is_parent_directory(token, tokenlen)) {
4000c52c:	80 a0 60 00 	cmp  %g1, 0                                    
4000c530:	22 80 00 34 	be,a   4000c600 <rtems_filesystem_eval_path_generic+0x198>
4000c534:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
  return mt_entry == rootloc->mt_entry                                
    && (*mt_entry->ops->are_nodes_equal_h)( loc, rootloc );           
}                                                                     
                                                                      
void rtems_filesystem_eval_path_generic(                              
  rtems_filesystem_eval_path_context_t *ctx,                          
4000c538:	d2 06 20 30 	ld  [ %i0 + 0x30 ], %o1                        
static bool is_eval_path_root(                                        
  const rtems_filesystem_eval_path_context_t *ctx,                    
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
4000c53c:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
  const rtems_filesystem_location_info_t *rootloc = &ctx->rootloc->location;
                                                                      
  return mt_entry == rootloc->mt_entry                                
    && (*mt_entry->ops->are_nodes_equal_h)( loc, rootloc );           
4000c540:	c4 02 60 14 	ld  [ %o1 + 0x14 ], %g2                        
4000c544:	80 a0 40 02 	cmp  %g1, %g2                                  
4000c548:	12 80 00 06 	bne  4000c560 <rtems_filesystem_eval_path_generic+0xf8>
4000c54c:	90 10 20 00 	clr  %o0                                       
4000c550:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
4000c554:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
4000c558:	9f c0 40 00 	call  %g1                                      
4000c55c:	90 10 00 10 	mov  %l0, %o0                                  
          }                                                           
        } else if (rtems_filesystem_is_parent_directory(token, tokenlen)) {
          rtems_filesystem_location_info_t *currentloc =              
            rtems_filesystem_eval_path_get_currentloc( ctx );         
                                                                      
          if (is_eval_path_root(ctx, currentloc)) {                   
4000c560:	80 8a 20 01 	btst  1, %o0                                   
4000c564:	32 80 00 1d 	bne,a   4000c5d8 <rtems_filesystem_eval_path_generic+0x170>
4000c568:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
                                                                      
#include <rtems/libio_.h>                                             
                                                                      
static bool is_fs_root( const rtems_filesystem_location_info_t *loc ) 
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
4000c56c:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
  const rtems_filesystem_location_info_t *mt_fs_root =                
    &mt_entry->mt_fs_root->location;                                  
                                                                      
  return (*mt_entry->ops->are_nodes_equal_h)( loc, mt_fs_root );      
4000c570:	90 10 00 10 	mov  %l0, %o0                                  
4000c574:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4000c578:	c4 00 a0 10 	ld  [ %g2 + 0x10 ], %g2                        
4000c57c:	9f c0 80 00 	call  %g2                                      
4000c580:	d2 00 60 24 	ld  [ %g1 + 0x24 ], %o1                        
            rtems_filesystem_eval_path_get_currentloc( ctx );         
                                                                      
          if (is_eval_path_root(ctx, currentloc)) {                   
            /* This prevents the escape from a chroot() environment */
            status = (*config->eval_token)(ctx, arg, ".", 1);         
          } else if (is_fs_root(currentloc)) {                        
4000c584:	80 a2 20 00 	cmp  %o0, 0                                    
4000c588:	22 80 00 19 	be,a   4000c5ec <rtems_filesystem_eval_path_generic+0x184>
4000c58c:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
            if (currentloc->mt_entry->mt_point_node != NULL) {        
4000c590:	d2 06 20 2c 	ld  [ %i0 + 0x2c ], %o1                        
4000c594:	c2 02 60 20 	ld  [ %o1 + 0x20 ], %g1                        
4000c598:	80 a0 60 00 	cmp  %g1, 0                                    
4000c59c:	22 80 00 0f 	be,a   4000c5d8 <rtems_filesystem_eval_path_generic+0x170><== NEVER TAKEN
4000c5a0:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           <== NOT EXECUTED
                                                                      
static inline void rtems_filesystem_eval_path_put_back_token(         
  rtems_filesystem_eval_path_context_t *ctx                           
)                                                                     
{                                                                     
  size_t tokenlen = ctx->tokenlen;                                    
4000c5a4:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
                                                                      
  ctx->path -= tokenlen;                                              
4000c5a8:	c4 06 00 00 	ld  [ %i0 ], %g2                               
  ctx->pathlen += tokenlen;                                           
  ctx->tokenlen = 0;                                                  
4000c5ac:	c0 26 20 0c 	clr  [ %i0 + 0xc ]                             
  rtems_filesystem_eval_path_context_t *ctx                           
)                                                                     
{                                                                     
  size_t tokenlen = ctx->tokenlen;                                    
                                                                      
  ctx->path -= tokenlen;                                              
4000c5b0:	84 20 80 01 	sub  %g2, %g1, %g2                             
4000c5b4:	c4 26 00 00 	st  %g2, [ %i0 ]                               
  ctx->pathlen += tokenlen;                                           
4000c5b8:	c4 06 20 04 	ld  [ %i0 + 4 ], %g2                           
              rtems_filesystem_eval_path_put_back_token(ctx);         
              rtems_filesystem_eval_path_restart(                     
4000c5bc:	90 10 00 18 	mov  %i0, %o0                                  
4000c5c0:	82 00 80 01 	add  %g2, %g1, %g1                             
4000c5c4:	92 02 60 20 	add  %o1, 0x20, %o1                            
4000c5c8:	7f ff e0 6c 	call  40004778 <rtems_filesystem_eval_path_restart>
4000c5cc:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
4000c5d0:	81 c7 e0 08 	ret                                            
4000c5d4:	81 e8 00 00 	restore                                        
                ¤tloc->mt_entry->mt_point_node                  
              );                                                      
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;       
            } else {                                                  
              /* This is the root file system */                      
              status = (*config->eval_token)(ctx, arg, ".", 1);       
4000c5d8:	90 10 00 18 	mov  %i0, %o0                                  
4000c5dc:	92 10 00 19 	mov  %i1, %o1                                  
4000c5e0:	94 10 00 1d 	mov  %i5, %o2                                  
4000c5e4:	10 80 00 0b 	b  4000c610 <rtems_filesystem_eval_path_generic+0x1a8>
4000c5e8:	96 10 20 01 	mov  1, %o3                                    
            }                                                         
          } else {                                                    
            status = (*config->eval_token)(ctx, arg, "..", 2);        
4000c5ec:	90 10 00 18 	mov  %i0, %o0                                  
4000c5f0:	92 10 00 19 	mov  %i1, %o1                                  
4000c5f4:	94 10 00 11 	mov  %l1, %o2                                  
4000c5f8:	10 80 00 06 	b  4000c610 <rtems_filesystem_eval_path_generic+0x1a8>
4000c5fc:	96 10 20 02 	mov  2, %o3                                    
          }                                                           
        } else {                                                      
          status = (*config->eval_token)(ctx, arg, token, tokenlen);  
4000c600:	90 10 00 18 	mov  %i0, %o0                                  
4000c604:	92 10 00 19 	mov  %i1, %o1                                  
4000c608:	94 10 00 1b 	mov  %i3, %o2                                  
4000c60c:	96 10 00 1c 	mov  %i4, %o3                                  
4000c610:	9f c0 40 00 	call  %g1                                      
4000c614:	01 00 00 00 	nop                                            
        }                                                             
                                                                      
        if (status == RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY) {  
4000c618:	80 a2 20 02 	cmp  %o0, 2                                    
4000c61c:	12 80 00 18 	bne  4000c67c <rtems_filesystem_eval_path_generic+0x214>
4000c620:	80 a2 20 00 	cmp  %o0, 0                                    
          if (rtems_filesystem_eval_path_has_path(ctx)) {             
4000c624:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
4000c628:	80 a0 60 00 	cmp  %g1, 0                                    
4000c62c:	02 80 00 16 	be  4000c684 <rtems_filesystem_eval_path_generic+0x21c>
4000c630:	01 00 00 00 	nop                                            
            int eval_flags;                                           
                                                                      
            rtems_filesystem_eval_path_eat_delimiter(ctx);            
4000c634:	40 00 00 16 	call  4000c68c <rtems_filesystem_eval_path_eat_delimiter>
4000c638:	90 10 00 18 	mov  %i0, %o0                                  
            eval_flags = rtems_filesystem_eval_path_get_flags(ctx);   
            if (                                                      
              (eval_flags & RTEMS_FS_ACCEPT_RESIDUAL_DELIMITERS) == 0 
4000c63c:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
          if (rtems_filesystem_eval_path_has_path(ctx)) {             
            int eval_flags;                                           
                                                                      
            rtems_filesystem_eval_path_eat_delimiter(ctx);            
            eval_flags = rtems_filesystem_eval_path_get_flags(ctx);   
            if (                                                      
4000c640:	80 88 60 80 	btst  0x80, %g1                                
4000c644:	02 80 00 06 	be  4000c65c <rtems_filesystem_eval_path_generic+0x1f4>
4000c648:	90 10 00 18 	mov  %i0, %o0                                  
              (eval_flags & RTEMS_FS_ACCEPT_RESIDUAL_DELIMITERS) == 0 
                || rtems_filesystem_eval_path_has_path(ctx)           
4000c64c:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
4000c650:	80 a0 60 00 	cmp  %g1, 0                                    
4000c654:	02 80 00 0c 	be  4000c684 <rtems_filesystem_eval_path_generic+0x21c>
4000c658:	01 00 00 00 	nop                                            
            ) {                                                       
              rtems_filesystem_eval_path_error(ctx, ENOENT);          
4000c65c:	92 10 20 02 	mov  2, %o1	! 2 <_TLS_Alignment+0x1>           
4000c660:	7f ff df c1 	call  40004564 <rtems_filesystem_eval_path_error>
4000c664:	01 00 00 00 	nop                                            
4000c668:	81 c7 e0 08 	ret                                            
4000c66c:	81 e8 00 00 	restore                                        
            }                                                         
          }                                                           
        }                                                             
      } else {                                                        
        rtems_filesystem_eval_path_error(ctx, ENOTDIR);               
4000c670:	90 10 00 18 	mov  %i0, %o0                                  
4000c674:	10 bf ff fb 	b  4000c660 <rtems_filesystem_eval_path_generic+0x1f8>
4000c678:	92 10 20 14 	mov  0x14, %o1                                 
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
    RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE;                      
                                                                      
  while (status == RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE) {     
4000c67c:	02 bf ff 81 	be  4000c480 <rtems_filesystem_eval_path_generic+0x18>
4000c680:	01 00 00 00 	nop                                            
4000c684:	81 c7 e0 08 	ret                                            
4000c688:	81 e8 00 00 	restore                                        
                                                                      

400047dc <rtems_filesystem_eval_path_recursive>: void rtems_filesystem_eval_path_recursive( rtems_filesystem_eval_path_context_t *ctx, const char *path, size_t pathlen ) {
400047dc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (pathlen > 0) {                                                  
400047e0:	80 a6 a0 00 	cmp  %i2, 0                                    
400047e4:	02 80 00 27 	be  40004880 <rtems_filesystem_eval_path_recursive+0xa4><== NEVER TAKEN
400047e8:	ba 10 00 18 	mov  %i0, %i5                                  
    if (ctx->recursionlevel < RTEMS_FILESYSTEM_SYMLOOP_MAX) {         
400047ec:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
400047f0:	80 a0 60 1f 	cmp  %g1, 0x1f                                 
400047f4:	34 80 00 24 	bg,a   40004884 <rtems_filesystem_eval_path_recursive+0xa8>
400047f8:	b2 10 20 5c 	mov  0x5c, %i1                                 
  gid_t node_gid                                                      
);                                                                    
                                                                      
static inline bool rtems_filesystem_is_delimiter(char c)              
{                                                                     
  return c == '/' || c == '\\';                                       
400047fc:	c2 4e 40 00 	ldsb  [ %i1 ], %g1                             
      const char *saved_path = ctx->path;                             
40004800:	f6 06 00 00 	ld  [ %i0 ], %i3                               
      size_t saved_pathlen = ctx->pathlen;                            
                                                                      
      if (rtems_filesystem_is_delimiter(path [0])) {                  
40004804:	80 a0 60 5c 	cmp  %g1, 0x5c                                 
40004808:	02 80 00 05 	be  4000481c <rtems_filesystem_eval_path_recursive+0x40><== NEVER TAKEN
4000480c:	f8 06 20 04 	ld  [ %i0 + 4 ], %i4                           
40004810:	80 a0 60 2f 	cmp  %g1, 0x2f                                 
40004814:	32 80 00 06 	bne,a   4000482c <rtems_filesystem_eval_path_recursive+0x50>
40004818:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
        rtems_filesystem_eval_path_restart(ctx, &ctx->rootloc);       
4000481c:	90 10 00 1d 	mov  %i5, %o0                                  
40004820:	7f ff ff d6 	call  40004778 <rtems_filesystem_eval_path_restart>
40004824:	92 07 60 30 	add  %i5, 0x30, %o1                            
      }                                                               
                                                                      
      ctx->path = path;                                               
      ctx->pathlen = pathlen;                                         
                                                                      
      ++ctx->recursionlevel;                                          
40004828:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
                                                                      
      if (rtems_filesystem_is_delimiter(path [0])) {                  
        rtems_filesystem_eval_path_restart(ctx, &ctx->rootloc);       
      }                                                               
                                                                      
      ctx->path = path;                                               
4000482c:	f2 27 40 00 	st  %i1, [ %i5 ]                               
      ctx->pathlen = pathlen;                                         
                                                                      
      ++ctx->recursionlevel;                                          
40004830:	82 00 60 01 	inc  %g1                                       
      if (rtems_filesystem_is_delimiter(path [0])) {                  
        rtems_filesystem_eval_path_restart(ctx, &ctx->rootloc);       
      }                                                               
                                                                      
      ctx->path = path;                                               
      ctx->pathlen = pathlen;                                         
40004834:	f4 27 60 04 	st  %i2, [ %i5 + 4 ]                           
                                                                      
      ++ctx->recursionlevel;                                          
40004838:	c2 27 60 14 	st  %g1, [ %i5 + 0x14 ]                        
      while (ctx->pathlen > 0) {                                      
4000483c:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
40004840:	80 a0 60 00 	cmp  %g1, 0                                    
40004844:	22 80 00 09 	be,a   40004868 <rtems_filesystem_eval_path_recursive+0x8c>
40004848:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
        (*ctx->currentloc.mt_entry->ops->eval_path_h)(ctx);           
4000484c:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        
40004850:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
40004854:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
40004858:	9f c0 40 00 	call  %g1                                      
4000485c:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
      ctx->path = path;                                               
      ctx->pathlen = pathlen;                                         
                                                                      
      ++ctx->recursionlevel;                                          
      while (ctx->pathlen > 0) {                                      
40004860:	10 bf ff f8 	b  40004840 <rtems_filesystem_eval_path_recursive+0x64>
40004864:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
        (*ctx->currentloc.mt_entry->ops->eval_path_h)(ctx);           
      }                                                               
      --ctx->recursionlevel;                                          
                                                                      
      ctx->path = saved_path;                                         
40004868:	f6 27 40 00 	st  %i3, [ %i5 ]                               
                                                                      
      ++ctx->recursionlevel;                                          
      while (ctx->pathlen > 0) {                                      
        (*ctx->currentloc.mt_entry->ops->eval_path_h)(ctx);           
      }                                                               
      --ctx->recursionlevel;                                          
4000486c:	82 00 7f ff 	add  %g1, -1, %g1                              
                                                                      
      ctx->path = saved_path;                                         
      ctx->pathlen = saved_pathlen;                                   
40004870:	f8 27 60 04 	st  %i4, [ %i5 + 4 ]                           
                                                                      
      ++ctx->recursionlevel;                                          
      while (ctx->pathlen > 0) {                                      
        (*ctx->currentloc.mt_entry->ops->eval_path_h)(ctx);           
      }                                                               
      --ctx->recursionlevel;                                          
40004874:	c2 27 60 14 	st  %g1, [ %i5 + 0x14 ]                        
40004878:	81 c7 e0 08 	ret                                            
4000487c:	81 e8 00 00 	restore                                        
      ctx->pathlen = saved_pathlen;                                   
    } else {                                                          
      rtems_filesystem_eval_path_error(ctx, ELOOP);                   
    }                                                                 
  } else {                                                            
    rtems_filesystem_eval_path_error(ctx, ENOENT);                    
40004880:	b2 10 20 02 	mov  2, %i1                                    <== NOT EXECUTED
40004884:	7f ff ff 38 	call  40004564 <rtems_filesystem_eval_path_error>
40004888:	81 e8 00 00 	restore                                        
                                                                      

40005ab4 <rtems_filesystem_eval_path_start_with_parent>: const char *path, int eval_flags, rtems_filesystem_location_info_t *parentloc, int parent_eval_flags ) {
40005ab4:	9d e3 bf a0 	save  %sp, -96, %sp                            
40005ab8:	ba 10 00 18 	mov  %i0, %i5                                  
  size_t pathlen = strlen(path);                                      
40005abc:	40 00 3b ec 	call  40014a6c <strlen>                        
40005ac0:	90 10 00 19 	mov  %i1, %o0                                  
40005ac4:	a0 10 00 08 	mov  %o0, %l0                                  
40005ac8:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
#include <string.h>                                                   
                                                                      
static size_t get_parentpathlen(const char *path, size_t pathlen)     
{                                                                     
  while (pathlen > 0) {                                               
40005acc:	80 a6 20 00 	cmp  %i0, 0                                    
40005ad0:	02 80 00 0a 	be  40005af8 <rtems_filesystem_eval_path_start_with_parent+0x44>
40005ad4:	82 06 3f ff 	add  %i0, -1, %g1                              
  gid_t node_gid                                                      
);                                                                    
                                                                      
static inline bool rtems_filesystem_is_delimiter(char c)              
{                                                                     
  return c == '/' || c == '\\';                                       
40005ad8:	c4 4e 40 01 	ldsb  [ %i1 + %g1 ], %g2                       
    size_t i = pathlen - 1;                                           
                                                                      
    if (rtems_filesystem_is_delimiter(path [i])) {                    
40005adc:	80 a0 a0 5c 	cmp  %g2, 0x5c                                 
40005ae0:	02 80 00 34 	be  40005bb0 <rtems_filesystem_eval_path_start_with_parent+0xfc><== NEVER TAKEN
40005ae4:	80 a0 a0 2f 	cmp  %g2, 0x2f                                 
40005ae8:	02 80 00 33 	be  40005bb4 <rtems_filesystem_eval_path_start_with_parent+0x100>
40005aec:	80 a4 20 00 	cmp  %l0, 0                                    
      return pathlen;                                                 
    }                                                                 
                                                                      
    pathlen = i;                                                      
40005af0:	10 bf ff f7 	b  40005acc <rtems_filesystem_eval_path_start_with_parent+0x18>
40005af4:	b0 10 00 01 	mov  %g1, %i0                                  
  size_t parentpathlen = get_parentpathlen(path, pathlen);            
  const char *name = NULL;                                            
  size_t namelen = 0;                                                 
  const rtems_filesystem_location_info_t *currentloc = NULL;          
                                                                      
  if (pathlen > 0) {                                                  
40005af8:	80 a4 20 00 	cmp  %l0, 0                                    
40005afc:	02 80 00 06 	be  40005b14 <rtems_filesystem_eval_path_start_with_parent+0x60>
40005b00:	a2 10 00 19 	mov  %i1, %l1                                  
    if (parentpathlen == 0) {                                         
      parentpath = ".";                                               
      parentpathlen = 1;                                              
40005b04:	b0 10 20 01 	mov  1, %i0                                    
  size_t namelen = 0;                                                 
  const rtems_filesystem_location_info_t *currentloc = NULL;          
                                                                      
  if (pathlen > 0) {                                                  
    if (parentpathlen == 0) {                                         
      parentpath = ".";                                               
40005b08:	33 10 00 68 	sethi  %hi(0x4001a000), %i1                    
40005b0c:	10 80 00 04 	b  40005b1c <rtems_filesystem_eval_path_start_with_parent+0x68>
40005b10:	b2 16 63 40 	or  %i1, 0x340, %i1	! 4001a340 <rtems_filesystem_default_pathconf+0x3c>
    }                                                                 
                                                                      
    pathlen = i;                                                      
  }                                                                   
                                                                      
  return 0;                                                           
40005b14:	b0 10 00 10 	mov  %l0, %i0                                  
)                                                                     
{                                                                     
  size_t pathlen = strlen(path);                                      
  const char *parentpath = path;                                      
  size_t parentpathlen = get_parentpathlen(path, pathlen);            
  const char *name = NULL;                                            
40005b18:	a2 10 20 00 	clr  %l1                                       
  currentloc = eval_path_start(                                       
    ctx,                                                              
    parentpath,                                                       
    parentpathlen,                                                    
    parent_eval_flags,                                                
    &rtems_filesystem_root,                                           
40005b1c:	7f ff fe f9 	call  40005700 <rtems_current_user_env_get>    
40005b20:	01 00 00 00 	nop                                            
    &rtems_filesystem_current                                         
40005b24:	7f ff fe f7 	call  40005700 <rtems_current_user_env_get>    
40005b28:	a6 10 00 08 	mov  %o0, %l3                                  
  int eval_flags,                                                     
  rtems_filesystem_global_location_t *const *global_root_ptr,         
  rtems_filesystem_global_location_t *const *global_current_ptr       
)                                                                     
{                                                                     
  memset(ctx, 0, sizeof(*ctx));                                       
40005b2c:	92 10 20 00 	clr  %o1                                       
    ctx,                                                              
    parentpath,                                                       
    parentpathlen,                                                    
    parent_eval_flags,                                                
    &rtems_filesystem_root,                                           
    &rtems_filesystem_current                                         
40005b30:	a4 10 00 08 	mov  %o0, %l2                                  
  int eval_flags,                                                     
  rtems_filesystem_global_location_t *const *global_root_ptr,         
  rtems_filesystem_global_location_t *const *global_current_ptr       
)                                                                     
{                                                                     
  memset(ctx, 0, sizeof(*ctx));                                       
40005b34:	94 10 20 38 	mov  0x38, %o2                                 
40005b38:	40 00 3a dc 	call  400146a8 <memset>                        
40005b3c:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  ctx->path = path;                                                   
  ctx->pathlen = pathlen;                                             
  ctx->flags = eval_flags;                                            
                                                                      
  set_startloc(ctx, global_root_ptr, global_current_ptr);             
40005b40:	94 10 00 12 	mov  %l2, %o2                                  
40005b44:	92 04 e0 04 	add  %l3, 4, %o1                               
)                                                                     
{                                                                     
  memset(ctx, 0, sizeof(*ctx));                                       
                                                                      
  ctx->path = path;                                                   
  ctx->pathlen = pathlen;                                             
40005b48:	f0 27 60 04 	st  %i0, [ %i5 + 4 ]                           
  ctx->flags = eval_flags;                                            
                                                                      
  set_startloc(ctx, global_root_ptr, global_current_ptr);             
40005b4c:	90 10 00 1d 	mov  %i5, %o0                                  
  rtems_filesystem_global_location_t *const *global_current_ptr       
)                                                                     
{                                                                     
  memset(ctx, 0, sizeof(*ctx));                                       
                                                                      
  ctx->path = path;                                                   
40005b50:	f2 27 40 00 	st  %i1, [ %i5 ]                               
  ctx->pathlen = pathlen;                                             
  ctx->flags = eval_flags;                                            
                                                                      
  set_startloc(ctx, global_root_ptr, global_current_ptr);             
40005b54:	7f ff ff 5d 	call  400058c8 <set_startloc>                  
40005b58:	f8 27 60 10 	st  %i4, [ %i5 + 0x10 ]                        
                                                                      
  rtems_filesystem_instance_lock(&ctx->startloc->location);           
40005b5c:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
40005b60:	d0 00 60 14 	ld  [ %g1 + 0x14 ], %o0                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  (*mt_entry->ops->lock_h)( mt_entry );                               
40005b64:	c4 02 20 0c 	ld  [ %o0 + 0xc ], %g2                         
40005b68:	c4 00 80 00 	ld  [ %g2 ], %g2                               
40005b6c:	9f c0 80 00 	call  %g2                                      
40005b70:	b0 07 60 18 	add  %i5, 0x18, %i0                            
                                                                      
  rtems_filesystem_location_clone(                                    
40005b74:	d2 07 60 34 	ld  [ %i5 + 0x34 ], %o1                        
40005b78:	40 00 29 42 	call  40010080 <rtems_filesystem_location_clone>
40005b7c:	90 10 00 18 	mov  %i0, %o0                                  
    &ctx->currentloc,                                                 
    &ctx->startloc->location                                          
  );                                                                  
                                                                      
  rtems_filesystem_eval_path_continue(ctx);                           
40005b80:	7f ff ff b3 	call  40005a4c <rtems_filesystem_eval_path_continue>
40005b84:	90 10 00 1d 	mov  %i5, %o0                                  
    parent_eval_flags,                                                
    &rtems_filesystem_root,                                           
    &rtems_filesystem_current                                         
  );                                                                  
                                                                      
  rtems_filesystem_location_clone(parentloc, currentloc);             
40005b88:	90 10 00 1b 	mov  %i3, %o0                                  
40005b8c:	40 00 29 3d 	call  40010080 <rtems_filesystem_location_clone>
40005b90:	92 10 00 18 	mov  %i0, %o1                                  
                                                                      
  ctx->path = name;                                                   
  ctx->pathlen = namelen;                                             
  ctx->flags = eval_flags;                                            
                                                                      
  rtems_filesystem_eval_path_continue(ctx);                           
40005b94:	90 10 00 1d 	mov  %i5, %o0                                  
    &rtems_filesystem_current                                         
  );                                                                  
                                                                      
  rtems_filesystem_location_clone(parentloc, currentloc);             
                                                                      
  ctx->path = name;                                                   
40005b98:	e2 27 40 00 	st  %l1, [ %i5 ]                               
  ctx->pathlen = namelen;                                             
40005b9c:	e0 27 60 04 	st  %l0, [ %i5 + 4 ]                           
  ctx->flags = eval_flags;                                            
                                                                      
  rtems_filesystem_eval_path_continue(ctx);                           
40005ba0:	7f ff ff ab 	call  40005a4c <rtems_filesystem_eval_path_continue>
40005ba4:	f4 27 60 10 	st  %i2, [ %i5 + 0x10 ]                        
40005ba8:	81 c7 e0 08 	ret                                            
40005bac:	81 e8 00 00 	restore                                        
  size_t parentpathlen = get_parentpathlen(path, pathlen);            
  const char *name = NULL;                                            
  size_t namelen = 0;                                                 
  const rtems_filesystem_location_info_t *currentloc = NULL;          
                                                                      
  if (pathlen > 0) {                                                  
40005bb0:	80 a4 20 00 	cmp  %l0, 0                                    <== NOT EXECUTED
40005bb4:	02 bf ff d9 	be  40005b18 <rtems_filesystem_eval_path_start_with_parent+0x64><== NEVER TAKEN
40005bb8:	a2 06 40 18 	add  %i1, %i0, %l1                             
      parentpathlen = 1;                                              
      name = path;                                                    
      namelen = pathlen;                                              
    } else {                                                          
      name = path + parentpathlen;                                    
      namelen = pathlen - parentpathlen;                              
40005bbc:	10 bf ff d8 	b  40005b1c <rtems_filesystem_eval_path_start_with_parent+0x68>
40005bc0:	a0 24 00 18 	sub  %l0, %i0, %l0                             
                                                                      

4000c374 <rtems_filesystem_get_mount_handler>: rtems_filesystem_fsmount_me_t rtems_filesystem_get_mount_handler( const char *type ) {
4000c374:	9d e3 bf 98 	save  %sp, -104, %sp                           
  find_arg fa = {                                                     
4000c378:	f0 27 bf f8 	st  %i0, [ %fp + -8 ]                          
    .type = type,                                                     
    .mount_h = NULL                                                   
  };                                                                  
                                                                      
  if ( type != NULL ) {                                               
4000c37c:	80 a6 20 00 	cmp  %i0, 0                                    
4000c380:	02 80 00 06 	be  4000c398 <rtems_filesystem_get_mount_handler+0x24><== NEVER TAKEN
4000c384:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    rtems_filesystem_iterate( find_handler, &fa );                    
4000c388:	11 10 00 30 	sethi  %hi(0x4000c000), %o0                    
4000c38c:	92 07 bf f8 	add  %fp, -8, %o1                              
4000c390:	7f ff ff d2 	call  4000c2d8 <rtems_filesystem_iterate>      
4000c394:	90 12 22 a4 	or  %o0, 0x2a4, %o0                            
  }                                                                   
                                                                      
  return fa.mount_h;                                                  
}                                                                     
4000c398:	f0 07 bf fc 	ld  [ %fp + -4 ], %i0                          
4000c39c:	81 c7 e0 08 	ret                                            
4000c3a0:	81 e8 00 00 	restore                                        
                                                                      

40003750 <rtems_filesystem_initialize>: /* * Default mode for created files. */ void rtems_filesystem_initialize( void ) {
40003750:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
  const rtems_filesystem_mount_configuration *root_config =           
    &rtems_filesystem_root_configuration;                             
                                                                      
  rv = mount(                                                         
40003754:	05 10 00 55 	sethi  %hi(0x40015400), %g2                    
40003758:	82 10 a2 a8 	or  %g2, 0x2a8, %g1	! 400156a8 <rtems_filesystem_root_configuration>
4000375c:	d0 00 a2 a8 	ld  [ %g2 + 0x2a8 ], %o0                       
40003760:	d2 00 60 04 	ld  [ %g1 + 4 ], %o1                           
40003764:	d4 00 60 08 	ld  [ %g1 + 8 ], %o2                           
40003768:	d6 00 60 0c 	ld  [ %g1 + 0xc ], %o3                         
4000376c:	40 00 01 81 	call  40003d70 <mount>                         
40003770:	d8 00 60 10 	ld  [ %g1 + 0x10 ], %o4                        
    root_config->target,                                              
    root_config->filesystemtype,                                      
    root_config->options,                                             
    root_config->data                                                 
  );                                                                  
  if ( rv != 0 )                                                      
40003774:	80 a2 20 00 	cmp  %o0, 0                                    
40003778:	22 80 00 05 	be,a   4000378c <rtems_filesystem_initialize+0x3c><== ALWAYS TAKEN
4000377c:	11 10 00 56 	sethi  %hi(0x40015800), %o0                    
    rtems_fatal_error_occurred( 0xABCD0002 );                         
40003780:	11 2a f3 40 	sethi  %hi(0xabcd0000), %o0                    <== NOT EXECUTED
40003784:	10 80 00 09 	b  400037a8 <rtems_filesystem_initialize+0x58> <== NOT EXECUTED
40003788:	90 12 20 02 	or  %o0, 2, %o0	! abcd0002 <RAM_END+0x6b8d0002><== NOT EXECUTED
   *                                                                  
   *  NOTE: UNIX root is 755 and owned by root/root (0/0).  It is actually
   *        created that way by the IMFS.                             
   */                                                                 
                                                                      
  rv = mkdir( "/dev", 0777);                                          
4000378c:	92 10 21 ff 	mov  0x1ff, %o1                                
40003790:	40 00 01 30 	call  40003c50 <mkdir>                         
40003794:	90 12 22 18 	or  %o0, 0x218, %o0                            
  if ( rv != 0 )                                                      
40003798:	80 a2 20 00 	cmp  %o0, 0                                    
4000379c:	02 80 00 05 	be  400037b0 <rtems_filesystem_initialize+0x60><== ALWAYS TAKEN
400037a0:	11 2a f3 40 	sethi  %hi(0xabcd0000), %o0                    
    rtems_fatal_error_occurred( 0xABCD0003 );                         
400037a4:	90 12 20 03 	or  %o0, 3, %o0	! abcd0003 <RAM_END+0x6b8d0003><== NOT EXECUTED
400037a8:	40 00 11 77 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
400037ac:	01 00 00 00 	nop                                            <== NOT EXECUTED
400037b0:	81 c7 e0 08 	ret                                            
400037b4:	81 e8 00 00 	restore                                        
                                                                      

4000c2d8 <rtems_filesystem_iterate>: bool rtems_filesystem_iterate( rtems_per_filesystem_routine routine, void *routine_arg ) {
4000c2d8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_chain_control *chain = &filesystem_chain;                     
  const rtems_filesystem_table_t *table_entry = &rtems_filesystem_table [0];
4000c2dc:	39 10 00 55 	sethi  %hi(0x40015400), %i4                    
  rtems_chain_node *node = NULL;                                      
  bool stop = false;                                                  
4000c2e0:	ba 10 20 00 	clr  %i5                                       
  rtems_per_filesystem_routine routine,                               
  void *routine_arg                                                   
)                                                                     
{                                                                     
  rtems_chain_control *chain = &filesystem_chain;                     
  const rtems_filesystem_table_t *table_entry = &rtems_filesystem_table [0];
4000c2e4:	b8 17 22 bc 	or  %i4, 0x2bc, %i4                            
  rtems_chain_node *node = NULL;                                      
  bool stop = false;                                                  
                                                                      
  while ( table_entry->type && !stop ) {                              
4000c2e8:	c2 07 00 00 	ld  [ %i4 ], %g1                               
4000c2ec:	80 a0 60 00 	cmp  %g1, 0                                    
4000c2f0:	02 80 00 0a 	be  4000c318 <rtems_filesystem_iterate+0x40>   
4000c2f4:	82 0f 60 ff 	and  %i5, 0xff, %g1                            
4000c2f8:	80 a0 60 00 	cmp  %g1, 0                                    
4000c2fc:	12 80 00 1b 	bne  4000c368 <rtems_filesystem_iterate+0x90>  
4000c300:	90 10 00 1c 	mov  %i4, %o0                                  
    stop = (*routine)( table_entry, routine_arg );                    
4000c304:	92 10 00 19 	mov  %i1, %o1                                  
4000c308:	9f c6 00 00 	call  %i0                                      
4000c30c:	b8 07 20 08 	add  %i4, 8, %i4                               
4000c310:	10 bf ff f6 	b  4000c2e8 <rtems_filesystem_iterate+0x10>    
4000c314:	ba 10 00 08 	mov  %o0, %i5                                  
    ++table_entry;                                                    
  }                                                                   
                                                                      
  if ( !stop ) {                                                      
4000c318:	80 a0 60 00 	cmp  %g1, 0                                    
4000c31c:	32 80 00 14 	bne,a   4000c36c <rtems_filesystem_iterate+0x94>
4000c320:	b0 0f 60 ff 	and  %i5, 0xff, %i0                            
    rtems_libio_lock();                                               
4000c324:	7f ff ff d4 	call  4000c274 <rtems_libio_lock>              
4000c328:	37 10 00 5b 	sethi  %hi(0x40016c00), %i3                    
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First(                        
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Head( the_chain )->next;                              
4000c32c:	03 10 00 5b 	sethi  %hi(0x40016c00), %g1                    
4000c330:	f8 00 60 2c 	ld  [ %g1 + 0x2c ], %i4	! 40016c2c <filesystem_chain>
    for (                                                             
4000c334:	b6 16 e0 30 	or  %i3, 0x30, %i3                             
4000c338:	80 a7 00 1b 	cmp  %i4, %i3                                  
4000c33c:	02 80 00 09 	be  4000c360 <rtems_filesystem_iterate+0x88>   
4000c340:	80 8f 60 ff 	btst  0xff, %i5                                
      node = rtems_chain_first( chain );                              
      !rtems_chain_is_tail( chain, node ) && !stop;                   
4000c344:	12 80 00 07 	bne  4000c360 <rtems_filesystem_iterate+0x88>  <== NEVER TAKEN
4000c348:	90 07 20 08 	add  %i4, 8, %o0                               
      node = rtems_chain_next( node )                                 
    ) {                                                               
      const filesystem_node *fsn = (filesystem_node *) node;          
                                                                      
      stop = (*routine)( &fsn->entry, routine_arg );                  
4000c34c:	9f c6 00 00 	call  %i0                                      
4000c350:	92 10 00 19 	mov  %i1, %o1                                  
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
4000c354:	f8 07 00 00 	ld  [ %i4 ], %i4                               
4000c358:	10 bf ff f8 	b  4000c338 <rtems_filesystem_iterate+0x60>    
4000c35c:	ba 10 00 08 	mov  %o0, %i5                                  
    }                                                                 
    rtems_libio_unlock();                                             
4000c360:	7f ff ff cc 	call  4000c290 <rtems_libio_unlock>            
4000c364:	01 00 00 00 	nop                                            
  }                                                                   
                                                                      
  return stop;                                                        
}                                                                     
4000c368:	b0 0f 60 ff 	and  %i5, 0xff, %i0                            
4000c36c:	81 c7 e0 08 	ret                                            
4000c370:	81 e8 00 00 	restore                                        
                                                                      

4000bfd0 <rtems_filesystem_location_clone>: void rtems_filesystem_location_clone( rtems_filesystem_location_info_t *clone, const rtems_filesystem_location_info_t *master ) {
4000bfd0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rv = 0;                                                         
                                                                      
  clone = rtems_filesystem_location_copy( clone, master );            
4000bfd4:	90 10 00 18 	mov  %i0, %o0                                  
4000bfd8:	7f ff e2 45 	call  400048ec <rtems_filesystem_location_copy>
4000bfdc:	92 10 00 19 	mov  %i1, %o1                                  
  rv = (*clone->mt_entry->ops->clonenod_h)( clone );                  
4000bfe0:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
4000bfe4:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
4000bfe8:	c2 00 60 28 	ld  [ %g1 + 0x28 ], %g1                        
4000bfec:	9f c0 40 00 	call  %g1                                      
4000bff0:	b0 10 00 08 	mov  %o0, %i0                                  
  if ( rv != 0 ) {                                                    
4000bff4:	80 a2 20 00 	cmp  %o0, 0                                    
4000bff8:	02 80 00 06 	be  4000c010 <rtems_filesystem_location_clone+0x40><== ALWAYS TAKEN
4000bffc:	90 10 00 18 	mov  %i0, %o0                                  
    rtems_filesystem_location_remove_from_mt_entry( clone );          
4000c000:	7f ff e2 e0 	call  40004b80 <rtems_filesystem_location_remove_from_mt_entry><== NOT EXECUTED
4000c004:	33 10 00 5a 	sethi  %hi(0x40016800), %i1                    <== NOT EXECUTED
static inline rtems_filesystem_location_info_t *                      
rtems_filesystem_location_initialize_to_null(                         
  rtems_filesystem_location_info_t *loc                               
)                                                                     
{                                                                     
  return rtems_filesystem_location_copy(                              
4000c008:	7f ff e2 39 	call  400048ec <rtems_filesystem_location_copy><== NOT EXECUTED
4000c00c:	93 ee 63 8c 	restore  %i1, 0x38c, %o1                       <== NOT EXECUTED
4000c010:	81 c7 e0 08 	ret                                            
4000c014:	81 e8 00 00 	restore                                        
                                                                      

40004b80 <rtems_filesystem_location_remove_from_mt_entry>: } void rtems_filesystem_location_remove_from_mt_entry( rtems_filesystem_location_info_t *loc ) {
40004b80:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
40004b84:	7f ff f6 2c 	call  40002434 <sparc_disable_interrupts>      
40004b88:	01 00 00 00 	nop                                            
40004b8c:	b8 10 00 08 	mov  %o0, %i4                                  
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
40004b90:	c4 06 00 00 	ld  [ %i0 ], %g2                               
  previous       = the_node->previous;                                
40004b94:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
  rtems_filesystem_mt_entry_declare_lock_context(lock_context);       
  bool do_unmount;                                                    
                                                                      
  rtems_filesystem_mt_entry_lock(lock_context);                       
  rtems_chain_extract_unprotected(&loc->mt_entry_node);               
  do_unmount = rtems_filesystem_is_ready_for_unmount(loc->mt_entry);  
40004b98:	d0 06 20 14 	ld  [ %i0 + 0x14 ], %o0                        
  next->previous = previous;                                          
40004b9c:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
40004ba0:	7f ff ff 3b 	call  4000488c <rtems_filesystem_is_ready_for_unmount>
40004ba4:	c4 20 40 00 	st  %g2, [ %g1 ]                               
40004ba8:	ba 10 00 08 	mov  %o0, %i5                                  
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
40004bac:	7f ff f6 25 	call  40002440 <sparc_enable_interrupts>       
40004bb0:	90 10 00 1c 	mov  %i4, %o0                                  
  rtems_filesystem_mt_entry_unlock(lock_context);                     
                                                                      
  if (do_unmount) {                                                   
40004bb4:	80 a7 60 00 	cmp  %i5, 0                                    
40004bb8:	02 80 00 05 	be  40004bcc <rtems_filesystem_location_remove_from_mt_entry+0x4c><== ALWAYS TAKEN
40004bbc:	01 00 00 00 	nop                                            
    rtems_filesystem_do_unmount(loc->mt_entry);                       
40004bc0:	f0 06 20 14 	ld  [ %i0 + 0x14 ], %i0                        <== NOT EXECUTED
40004bc4:	7f ff ff 66 	call  4000495c <rtems_filesystem_do_unmount>   <== NOT EXECUTED
40004bc8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
40004bcc:	81 c7 e0 08 	ret                                            
40004bd0:	81 e8 00 00 	restore                                        
                                                                      

40004bfc <rtems_filesystem_location_transform_to_global>: } rtems_filesystem_global_location_t *rtems_filesystem_location_transform_to_global( rtems_filesystem_location_info_t *loc ) {
40004bfc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_filesystem_global_location_t *global_loc = malloc(sizeof(*global_loc));
40004c00:	7f ff fb d8 	call  40003b60 <malloc>                        
40004c04:	90 10 20 24 	mov  0x24, %o0                                 
                                                                      
  if (global_loc != NULL) {                                           
40004c08:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40004c0c:	02 80 00 0b 	be  40004c38 <rtems_filesystem_location_transform_to_global+0x3c><== NEVER TAKEN
40004c10:	82 10 20 01 	mov  1, %g1                                    
    global_loc->reference_count = 1;                                  
    global_loc->deferred_released_next = NULL;                        
40004c14:	c0 27 60 1c 	clr  [ %i5 + 0x1c ]                            
)                                                                     
{                                                                     
  rtems_filesystem_global_location_t *global_loc = malloc(sizeof(*global_loc));
                                                                      
  if (global_loc != NULL) {                                           
    global_loc->reference_count = 1;                                  
40004c18:	c2 27 60 18 	st  %g1, [ %i5 + 0x18 ]                        
    global_loc->deferred_released_next = NULL;                        
    global_loc->deferred_released_count = 0;                          
40004c1c:	c0 27 60 20 	clr  [ %i5 + 0x20 ]                            
    rtems_filesystem_location_copy(&global_loc->location, loc);       
40004c20:	7f ff ff 33 	call  400048ec <rtems_filesystem_location_copy>
40004c24:	92 10 00 18 	mov  %i0, %o1                                  
    rtems_filesystem_location_remove_from_mt_entry(loc);              
40004c28:	7f ff ff d6 	call  40004b80 <rtems_filesystem_location_remove_from_mt_entry>
40004c2c:	90 10 00 18 	mov  %i0, %o0                                  
40004c30:	81 c7 e0 08 	ret                                            
40004c34:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
  } else {                                                            
    rtems_filesystem_location_free(loc);                              
40004c38:	40 00 1d 1b 	call  4000c0a4 <rtems_filesystem_location_free><== NOT EXECUTED
40004c3c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
static inline rtems_filesystem_global_location_t *                    
rtems_filesystem_global_location_obtain_null(void)                    
{                                                                     
  rtems_filesystem_global_location_t *global_loc = NULL;              
                                                                      
  return rtems_filesystem_global_location_obtain( &global_loc );      
40004c40:	90 07 bf fc 	add  %fp, -4, %o0                              <== NOT EXECUTED
40004c44:	7f ff ff 80 	call  40004a44 <rtems_filesystem_global_location_obtain><== NOT EXECUTED
40004c48:	c0 27 bf fc 	clr  [ %fp + -4 ]                              <== NOT EXECUTED
    global_loc = rtems_filesystem_global_location_obtain_null();      
    errno = ENOMEM;                                                   
40004c4c:	40 00 2b 75 	call  4000fa20 <__errno>                       <== NOT EXECUTED
40004c50:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
40004c54:	82 10 20 0c 	mov  0xc, %g1                                  <== NOT EXECUTED
40004c58:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return global_loc;                                                  
}                                                                     
40004c5c:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
40004c60:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40004c64:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40004158 <rtems_gxx_key_create>: } int rtems_gxx_key_create (__gthread_key_t *key, void (*dtor) (void *)) {
40004158:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int eno;                                                            
  pthread_key_t *pkey;                                                
                                                                      
  pkey = malloc( sizeof( *pkey ) );                                   
4000415c:	40 00 00 fa 	call  40004544 <malloc>                        
40004160:	90 10 20 04 	mov  4, %o0                                    
  *key = pkey;                                                        
40004164:	d0 26 00 00 	st  %o0, [ %i0 ]                               
int rtems_gxx_key_create (__gthread_key_t *key, void (*dtor) (void *))
{                                                                     
  int eno;                                                            
  pthread_key_t *pkey;                                                
                                                                      
  pkey = malloc( sizeof( *pkey ) );                                   
40004168:	ba 10 00 08 	mov  %o0, %i5                                  
  *key = pkey;                                                        
  if ( pkey == NULL )                                                 
4000416c:	80 a2 20 00 	cmp  %o0, 0                                    
40004170:	02 80 00 0c 	be  400041a0 <rtems_gxx_key_create+0x48>       <== NEVER TAKEN
40004174:	82 10 20 0c 	mov  0xc, %g1                                  
    printk(                                                           
      "gxx_wrappers: create key=%x, dtor=%x, pkey=%x\n", key, dtor, pkey
    );                                                                
  #endif                                                              
                                                                      
  eno = pthread_key_create(pkey, dtor);                               
40004178:	40 00 0d b6 	call  40007850 <pthread_key_create>            
4000417c:	92 10 00 19 	mov  %i1, %o1                                  
40004180:	82 10 20 00 	clr  %g1                                       
  if ( eno != 0 ) {                                                   
40004184:	80 a2 20 00 	cmp  %o0, 0                                    
40004188:	02 80 00 06 	be  400041a0 <rtems_gxx_key_create+0x48>       <== ALWAYS TAKEN
4000418c:	b8 10 00 08 	mov  %o0, %i4                                  
    free( pkey );                                                     
40004190:	7f ff ff 9f 	call  4000400c <free>                          <== NOT EXECUTED
40004194:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    *key = NULL;                                                      
40004198:	82 10 00 1c 	mov  %i4, %g1                                  <== NOT EXECUTED
4000419c:	c0 26 00 00 	clr  [ %i0 ]                                   <== NOT EXECUTED
  }                                                                   
                                                                      
  return eno;                                                         
}                                                                     
400041a0:	81 c7 e0 08 	ret                                            
400041a4:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40008e6c <rtems_heap_allocate_aligned_with_boundary>: void *rtems_heap_allocate_aligned_with_boundary( size_t size, uintptr_t alignment, uintptr_t boundary ) {
40008e6c:	9d e3 bf a0 	save  %sp, -96, %sp                            
40008e70:	03 10 00 84 	sethi  %hi(0x40021000), %g1                    
  if (                                                                
40008e74:	c2 00 60 d0 	ld  [ %g1 + 0xd0 ], %g1	! 400210d0 <_System_state_Current>
void *rtems_heap_allocate_aligned_with_boundary(                      
  size_t size,                                                        
  uintptr_t alignment,                                                
  uintptr_t boundary                                                  
)                                                                     
{                                                                     
40008e78:	ba 10 00 18 	mov  %i0, %i5                                  
40008e7c:	b8 10 00 19 	mov  %i1, %i4                                  
  if (                                                                
40008e80:	80 a0 60 02 	cmp  %g1, 2                                    
40008e84:	02 80 00 08 	be  40008ea4 <rtems_heap_allocate_aligned_with_boundary+0x38><== ALWAYS TAKEN
40008e88:	b6 10 00 1a 	mov  %i2, %i3                                  
      && !malloc_is_system_state_OK()                                 
  ) {                                                                 
    return NULL;                                                      
  }                                                                   
                                                                      
  malloc_deferred_frees_process();                                    
40008e8c:	7f ff fc 44 	call  40007f9c <malloc_deferred_frees_process> 
40008e90:	b2 10 00 1d 	mov  %i5, %i1                                  
                                                                      
  /* FIXME: Statistics, boundary checks */                            
                                                                      
  return _Protected_heap_Allocate_aligned_with_boundary(              
40008e94:	03 10 00 7a 	sethi  %hi(0x4001e800), %g1                    
40008e98:	f0 00 60 ac 	ld  [ %g1 + 0xac ], %i0	! 4001e8ac <RTEMS_Malloc_Heap>
40008e9c:	40 00 18 52 	call  4000efe4 <_Protected_heap_Allocate_aligned_with_boundary>
40008ea0:	95 e8 00 1c 	restore  %g0, %i4, %o2                         
  uintptr_t boundary                                                  
)                                                                     
{                                                                     
  if (                                                                
    _System_state_Is_up( _System_state_Get() )                        
      && !malloc_is_system_state_OK()                                 
40008ea4:	7f ff fc 3a 	call  40007f8c <malloc_is_system_state_OK>     
40008ea8:	01 00 00 00 	nop                                            
40008eac:	80 a2 20 00 	cmp  %o0, 0                                    
40008eb0:	12 bf ff f7 	bne  40008e8c <rtems_heap_allocate_aligned_with_boundary+0x20>
40008eb4:	b0 10 20 00 	clr  %i0                                       
    RTEMS_Malloc_Heap,                                                
    size,                                                             
    alignment,                                                        
    boundary                                                          
  );                                                                  
}                                                                     
40008eb8:	81 c7 e0 08 	ret                                            
40008ebc:	81 e8 00 00 	restore                                        
                                                                      

40004750 <rtems_heap_extend_via_sbrk>: void *rtems_heap_extend_via_sbrk( Heap_Control *heap, size_t alloc_size ) {
40004750:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ptrdiff_t sbrk_amount = RTEMS_Malloc_Sbrk_amount;                   
40004754:	03 10 00 62 	sethi  %hi(0x40018800), %g1                    
40004758:	f8 00 61 b8 	ld  [ %g1 + 0x1b8 ], %i4	! 400189b8 <RTEMS_Malloc_Sbrk_amount>
  ptrdiff_t sbrk_size = (ptrdiff_t) alloc_size;                       
  ptrdiff_t misaligned = sbrk_amount != 0 ? sbrk_size % sbrk_amount : 0;
4000475c:	80 a7 20 00 	cmp  %i4, 0                                    
40004760:	02 80 00 0a 	be  40004788 <rtems_heap_extend_via_sbrk+0x38> 
40004764:	ba 10 00 19 	mov  %i1, %i5                                  
40004768:	90 10 00 19 	mov  %i1, %o0                                  
4000476c:	40 00 3d 70 	call  40013d2c <.rem>                          
40004770:	92 10 00 1c 	mov  %i4, %o1                                  
  void *return_this = NULL;                                           
                                                                      
  if ( misaligned != 0 ) {                                            
40004774:	80 a2 20 00 	cmp  %o0, 0                                    
40004778:	02 80 00 05 	be  4000478c <rtems_heap_extend_via_sbrk+0x3c> 
4000477c:	80 a7 60 00 	cmp  %i5, 0                                    
    sbrk_size += sbrk_amount - misaligned;                            
40004780:	ba 27 00 08 	sub  %i4, %o0, %i5                             
40004784:	ba 06 40 1d 	add  %i1, %i5, %i5                             
  }                                                                   
                                                                      
  if ( sbrk_size > 0 && sbrk_amount > 0 ) {                           
40004788:	80 a7 60 00 	cmp  %i5, 0                                    
4000478c:	04 80 00 17 	ble  400047e8 <rtems_heap_extend_via_sbrk+0x98><== NEVER TAKEN
40004790:	80 a7 20 00 	cmp  %i4, 0                                    
40004794:	04 80 00 15 	ble  400047e8 <rtems_heap_extend_via_sbrk+0x98>
40004798:	01 00 00 00 	nop                                            
    void *area_begin = sbrk( sbrk_size );                             
4000479c:	7f ff f4 30 	call  4000185c <sbrk>                          
400047a0:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
    if ( area_begin != (void *) -1 ) {                                
400047a4:	80 a2 3f ff 	cmp  %o0, -1                                   
400047a8:	02 80 00 10 	be  400047e8 <rtems_heap_extend_via_sbrk+0x98> 
400047ac:	92 10 00 08 	mov  %o0, %o1                                  
      bool ok = _Protected_heap_Extend( heap, area_begin, sbrk_size );
400047b0:	90 10 00 18 	mov  %i0, %o0                                  
400047b4:	40 00 13 7a 	call  4000959c <_Protected_heap_Extend>        
400047b8:	94 10 00 1d 	mov  %i5, %o2                                  
                                                                      
      if ( ok ) {                                                     
400047bc:	80 a2 20 00 	cmp  %o0, 0                                    
400047c0:	02 80 00 08 	be  400047e0 <rtems_heap_extend_via_sbrk+0x90> 
400047c4:	03 10 00 62 	sethi  %hi(0x40018800), %g1                    
        MSBUMP( space_available, sbrk_size );                         
400047c8:	c4 00 61 88 	ld  [ %g1 + 0x188 ], %g2	! 40018988 <rtems_malloc_statistics>
400047cc:	b4 10 20 00 	clr  %i2                                       
400047d0:	ba 07 40 02 	add  %i5, %g2, %i5                             
400047d4:	fa 20 61 88 	st  %i5, [ %g1 + 0x188 ]                       
400047d8:	40 00 13 63 	call  40009564 <_Protected_heap_Allocate_aligned_with_boundary>
400047dc:	97 e8 20 00 	restore  %g0, 0, %o3                           
                                                                      
        return_this = _Protected_heap_Allocate( heap, alloc_size );   
      } else {                                                        
        sbrk( -sbrk_size );                                           
400047e0:	7f ff f4 1f 	call  4000185c <sbrk>                          
400047e4:	90 20 00 1d 	neg  %i5, %o0                                  
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  return return_this;                                                 
}                                                                     
400047e8:	81 c7 e0 08 	ret                                            
400047ec:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40004478 <rtems_heap_null_extend>: Heap_Control *heap __attribute__((unused)), size_t alloc_size __attribute__((unused)) ) { return NULL; }
40004478:	81 c3 e0 08 	retl                                           
4000447c:	90 10 20 00 	clr  %o0                                       
                                                                      

400058b8 <rtems_ide_part_table_initialize>: * RTEMS_NO_MEMOTY if cannot have not enough memory, * RTEMS_INTERNAL_ERROR if other error occurs. */ rtems_status_code rtems_ide_part_table_initialize(const char *dev_name) {
400058b8:	9d e3 bf 88 	save  %sp, -120, %sp                           
    rtems_part_desc_t          *part_desc;                            
                                                                      
    /* logical device name /dev/hdxyy */                              
    char                        name[RTEMS_IDE_PARTITION_DEV_NAME_LENGTH_MAX];
                                                                      
    disk_desc = (rtems_disk_desc_t *) calloc(1, sizeof(rtems_disk_desc_t));
400058bc:	90 10 20 01 	mov  1, %o0                                    
 *      RTEMS_NO_MEMOTY if cannot have not enough memory,             
 *      RTEMS_INTERNAL_ERROR if other error occurs.                   
 */                                                                   
rtems_status_code                                                     
rtems_ide_part_table_initialize(const char *dev_name)                 
{                                                                     
400058c0:	b4 10 00 18 	mov  %i0, %i2                                  
    rtems_part_desc_t          *part_desc;                            
                                                                      
    /* logical device name /dev/hdxyy */                              
    char                        name[RTEMS_IDE_PARTITION_DEV_NAME_LENGTH_MAX];
                                                                      
    disk_desc = (rtems_disk_desc_t *) calloc(1, sizeof(rtems_disk_desc_t));
400058c4:	92 10 21 28 	mov  0x128, %o1                                
400058c8:	40 00 02 6b 	call  40006274 <calloc>                        
400058cc:	b0 10 20 1a 	mov  0x1a, %i0                                 
    if (disk_desc == NULL)                                            
400058d0:	80 a2 20 00 	cmp  %o0, 0                                    
400058d4:	02 80 00 0a 	be  400058fc <rtems_ide_part_table_initialize+0x44><== NEVER TAKEN
400058d8:	ba 10 00 08 	mov  %o0, %i5                                  
    {                                                                 
        return RTEMS_NO_MEMORY;                                       
    }                                                                 
                                                                      
    /* get partition table */                                         
    rc = partition_table_get(dev_name, disk_desc);                    
400058dc:	90 10 00 1a 	mov  %i2, %o0                                  
400058e0:	7f ff ff 81 	call  400056e4 <partition_table_get>           
400058e4:	92 10 00 1d 	mov  %i5, %o1                                  
    if (rc != RTEMS_SUCCESSFUL)                                       
400058e8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400058ec:	22 80 00 06 	be,a   40005904 <rtems_ide_part_table_initialize+0x4c><== ALWAYS TAKEN
400058f0:	f0 07 40 00 	ld  [ %i5 ], %i0                               
    {                                                                 
        free(disk_desc);                                              
400058f4:	40 00 02 98 	call  40006354 <free>                          <== NOT EXECUTED
400058f8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        return rc;                                                    
400058fc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40005900:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    /* To avoid device numbers conflicts we have to use for logic disk the same
     * device major number as ATA device has, and minor number that equals to
     * sum of logic disk partition number and the minor number of physical disk
     */                                                               
                                                                      
    rtems_filesystem_split_dev_t (disk_desc->dev, major, minor);      
40005904:	e0 07 60 04 	ld  [ %i5 + 4 ], %l0                           
                                                                      
    /* create logical disks on the physical one */                    
    for (part_num = 0; part_num < disk_desc->last_log_id; part_num++) 
    {                                                                 
        sprintf(name, "%s%d", dev_name, part_num + 1);                
40005908:	23 10 00 98 	sethi  %hi(0x40026000), %l1                    
                                                                      
        rc = rtems_disk_create_log(dev, disk_desc->dev, part_desc->start,
                                   part_desc->size, name);            
        if (rc != RTEMS_SUCCESSFUL)                                   
        {                                                             
            fprintf(stdout,"Cannot create device %s, error code %d\n", name, rc);
4000590c:	25 10 00 98 	sethi  %hi(0x40026000), %l2                    
     */                                                               
                                                                      
    rtems_filesystem_split_dev_t (disk_desc->dev, major, minor);      
                                                                      
    /* create logical disks on the physical one */                    
    for (part_num = 0; part_num < disk_desc->last_log_id; part_num++) 
40005910:	b8 10 20 00 	clr  %i4                                       
    {                                                                 
        sprintf(name, "%s%d", dev_name, part_num + 1);                
40005914:	b6 07 bf f0 	add  %fp, -16, %i3                             
40005918:	a2 14 62 88 	or  %l1, 0x288, %l1                            
                                                                      
        rc = rtems_disk_create_log(dev, disk_desc->dev, part_desc->start,
                                   part_desc->size, name);            
        if (rc != RTEMS_SUCCESSFUL)                                   
        {                                                             
            fprintf(stdout,"Cannot create device %s, error code %d\n", name, rc);
4000591c:	a4 14 a2 90 	or  %l2, 0x290, %l2                            
     */                                                               
                                                                      
    rtems_filesystem_split_dev_t (disk_desc->dev, major, minor);      
                                                                      
    /* create logical disks on the physical one */                    
    for (part_num = 0; part_num < disk_desc->last_log_id; part_num++) 
40005920:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
40005924:	80 a7 00 01 	cmp  %i4, %g1                                  
40005928:	16 80 00 1f 	bge  400059a4 <rtems_ide_part_table_initialize+0xec>
4000592c:	b8 07 20 01 	inc  %i4                                       
    {                                                                 
        sprintf(name, "%s%d", dev_name, part_num + 1);                
40005930:	92 10 00 11 	mov  %l1, %o1                                  
40005934:	90 10 00 1b 	mov  %i3, %o0                                  
40005938:	94 10 00 1a 	mov  %i2, %o2                                  
4000593c:	40 00 43 dd 	call  400168b0 <sprintf>                       
40005940:	96 10 00 1c 	mov  %i4, %o3                                  
40005944:	83 2f 20 02 	sll  %i4, 2, %g1                               
40005948:	82 07 40 01 	add  %i5, %g1, %g1                             
        dev = rtems_filesystem_make_dev_t(major, ++minor);            
                                                                      
        part_desc = disk_desc->partitions[part_num];                  
4000594c:	c2 00 60 24 	ld  [ %g1 + 0x24 ], %g1                        
        if (part_desc == NULL)                                        
40005950:	80 a0 60 00 	cmp  %g1, 0                                    
40005954:	02 bf ff f3 	be  40005920 <rtems_ide_part_table_initialize+0x68>
40005958:	92 07 00 10 	add  %i4, %l0, %o1                             
        {                                                             
            continue;                                                 
        }                                                             
                                                                      
        rc = rtems_disk_create_log(dev, disk_desc->dev, part_desc->start,
4000595c:	d8 00 60 04 	ld  [ %g1 + 4 ], %o4                           
40005960:	da 00 60 08 	ld  [ %g1 + 8 ], %o5                           
40005964:	d4 1f 40 00 	ldd  [ %i5 ], %o2                              
40005968:	f6 23 a0 5c 	st  %i3, [ %sp + 0x5c ]                        
4000596c:	7f ff fd eb 	call  40005118 <rtems_disk_create_log>         
40005970:	90 10 00 18 	mov  %i0, %o0                                  
                                   part_desc->size, name);            
        if (rc != RTEMS_SUCCESSFUL)                                   
40005974:	b2 92 20 00 	orcc  %o0, 0, %i1                              
40005978:	22 bf ff eb 	be,a   40005924 <rtems_ide_part_table_initialize+0x6c><== ALWAYS TAKEN
4000597c:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        
        {                                                             
            fprintf(stdout,"Cannot create device %s, error code %d\n", name, rc);
40005980:	7f ff ee 45 	call  40001294 <__getreent>                    <== NOT EXECUTED
40005984:	01 00 00 00 	nop                                            <== NOT EXECUTED
40005988:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           <== NOT EXECUTED
4000598c:	92 10 00 12 	mov  %l2, %o1                                  <== NOT EXECUTED
40005990:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
40005994:	40 00 41 b7 	call  40016070 <fprintf>                       <== NOT EXECUTED
40005998:	96 10 00 19 	mov  %i1, %o3                                  <== NOT EXECUTED
            continue;                                                 
4000599c:	10 bf ff e2 	b  40005924 <rtems_ide_part_table_initialize+0x6c><== NOT EXECUTED
400059a0:	c2 07 60 24 	ld  [ %i5 + 0x24 ], %g1                        <== NOT EXECUTED
        }                                                             
    }                                                                 
                                                                      
    partition_table_free(disk_desc);                                  
400059a4:	90 10 00 1d 	mov  %i5, %o0                                  
400059a8:	7f ff fe 97 	call  40005404 <partition_table_free>          
400059ac:	b0 10 20 00 	clr  %i0                                       
                                                                      
    return RTEMS_SUCCESSFUL;                                          
}                                                                     
400059b0:	81 c7 e0 08 	ret                                            
400059b4:	81 e8 00 00 	restore                                        
                                                                      

4000cd3c <rtems_iterate_over_all_threads>: #include <rtems/score/thread.h> #include <rtems/score/objectimpl.h> void rtems_iterate_over_all_threads(rtems_per_thread_routine routine) {
4000cd3c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  uint32_t             i;                                             
  uint32_t             api_index;                                     
  Thread_Control      *the_thread;                                    
  Objects_Information *information;                                   
                                                                      
  if ( !routine )                                                     
4000cd40:	ba 10 20 01 	mov  1, %i5                                    
4000cd44:	80 a6 20 00 	cmp  %i0, 0                                    
4000cd48:	02 80 00 1a 	be  4000cdb0 <rtems_iterate_over_all_threads+0x74><== NEVER TAKEN
4000cd4c:	35 10 00 c0 	sethi  %hi(0x40030000), %i2                    
4000cd50:	83 2f 60 02 	sll  %i5, 2, %g1                               
    #if !defined(RTEMS_POSIX_API) || defined(RTEMS_DEBUG)             
      if ( !_Objects_Information_table[ api_index ] )                 
        continue;                                                     
    #endif                                                            
                                                                      
    information = _Objects_Information_table[ api_index ][ 1 ];       
4000cd54:	84 16 a3 60 	or  %i2, 0x360, %g2                            
4000cd58:	c2 00 80 01 	ld  [ %g2 + %g1 ], %g1                         
4000cd5c:	f6 00 60 04 	ld  [ %g1 + 4 ], %i3                           
    if ( !information )                                               
4000cd60:	80 a6 e0 00 	cmp  %i3, 0                                    
4000cd64:	22 80 00 10 	be,a   4000cda4 <rtems_iterate_over_all_threads+0x68>
4000cd68:	ba 07 60 01 	inc  %i5                                       
4000cd6c:	10 80 00 09 	b  4000cd90 <rtems_iterate_over_all_threads+0x54>
4000cd70:	b8 10 20 01 	mov  1, %i4                                    
      continue;                                                       
                                                                      
    for ( i=1 ; i <= information->maximum ; i++ ) {                   
      the_thread = (Thread_Control *)information->local_table[ i ];   
4000cd74:	83 2f 20 02 	sll  %i4, 2, %g1                               
4000cd78:	d0 00 80 01 	ld  [ %g2 + %g1 ], %o0                         
                                                                      
      if ( !the_thread )                                              
4000cd7c:	80 a2 20 00 	cmp  %o0, 0                                    
4000cd80:	02 80 00 04 	be  4000cd90 <rtems_iterate_over_all_threads+0x54><== NEVER TAKEN
4000cd84:	b8 07 20 01 	inc  %i4                                       
	continue;                                                            
                                                                      
      (*routine)(the_thread);                                         
4000cd88:	9f c6 00 00 	call  %i0                                      
4000cd8c:	01 00 00 00 	nop                                            
                                                                      
    information = _Objects_Information_table[ api_index ][ 1 ];       
    if ( !information )                                               
      continue;                                                       
                                                                      
    for ( i=1 ; i <= information->maximum ; i++ ) {                   
4000cd90:	c2 16 e0 10 	lduh  [ %i3 + 0x10 ], %g1                      
4000cd94:	80 a7 00 01 	cmp  %i4, %g1                                  
4000cd98:	28 bf ff f7 	bleu,a   4000cd74 <rtems_iterate_over_all_threads+0x38>
4000cd9c:	c4 06 e0 1c 	ld  [ %i3 + 0x1c ], %g2                        
  Objects_Information *information;                                   
                                                                      
  if ( !routine )                                                     
    return;                                                           
                                                                      
  for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
4000cda0:	ba 07 60 01 	inc  %i5                                       
4000cda4:	80 a7 60 04 	cmp  %i5, 4                                    
4000cda8:	12 bf ff eb 	bne  4000cd54 <rtems_iterate_over_all_threads+0x18>
4000cdac:	83 2f 60 02 	sll  %i5, 2, %g1                               
4000cdb0:	81 c7 e0 08 	ret                                            
4000cdb4:	81 e8 00 00 	restore                                        
                                                                      

4000396c <rtems_libio_init>: rtems_id rtems_libio_semaphore; rtems_libio_t *rtems_libio_iops; rtems_libio_t *rtems_libio_iop_freelist; void rtems_libio_init( void ) {
4000396c:	9d e3 bf a0 	save  %sp, -96, %sp                            
    rtems_status_code rc;                                             
    uint32_t i;                                                       
    rtems_libio_t *iop;                                               
    int eno;                                                          
                                                                      
    if (rtems_libio_number_iops > 0)                                  
40003970:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
40003974:	fa 00 63 30 	ld  [ %g1 + 0x330 ], %i5	! 40016b30 <rtems_libio_number_iops>
40003978:	80 a7 60 00 	cmp  %i5, 0                                    
4000397c:	02 80 00 1b 	be  400039e8 <rtems_libio_init+0x7c>           <== NEVER TAKEN
40003980:	11 10 00 60 	sethi  %hi(0x40018000), %o0                    
    {                                                                 
        rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops,
40003984:	90 10 00 1d 	mov  %i5, %o0                                  
40003988:	7f ff ff 8c 	call  400037b8 <calloc>                        
4000398c:	92 10 20 38 	mov  0x38, %o1                                 
40003990:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
                                                    sizeof(rtems_libio_t));
        if (rtems_libio_iops == NULL)                                 
40003994:	80 a2 20 00 	cmp  %o0, 0                                    
40003998:	12 80 00 04 	bne  400039a8 <rtems_libio_init+0x3c>          
4000399c:	d0 20 63 30 	st  %o0, [ %g1 + 0x330 ]                       
            rtems_fatal_error_occurred(RTEMS_NO_MEMORY);              
400039a0:	10 80 00 1a 	b  40003a08 <rtems_libio_init+0x9c>            
400039a4:	90 10 20 1a 	mov  0x1a, %o0                                 
                                                                      
        iop = rtems_libio_iop_freelist = rtems_libio_iops;            
400039a8:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
        for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)  
400039ac:	84 10 00 08 	mov  %o0, %g2                                  
        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;            
400039b0:	d0 20 63 34 	st  %o0, [ %g1 + 0x334 ]                       
        for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)  
400039b4:	82 10 20 00 	clr  %g1                                       
400039b8:	82 00 60 01 	inc  %g1                                       
400039bc:	80 a0 40 1d 	cmp  %g1, %i5                                  
400039c0:	02 80 00 04 	be  400039d0 <rtems_libio_init+0x64>           
400039c4:	84 00 a0 38 	add  %g2, 0x38, %g2                            
          iop->data1 = iop + 1;                                       
400039c8:	10 bf ff fc 	b  400039b8 <rtems_libio_init+0x4c>            
400039cc:	c4 20 bf f8 	st  %g2, [ %g2 + -8 ]                          
        iop->data1 = NULL;                                            
400039d0:	85 28 60 03 	sll  %g1, 3, %g2                               
400039d4:	83 28 60 06 	sll  %g1, 6, %g1                               
400039d8:	82 20 40 02 	sub  %g1, %g2, %g1                             
400039dc:	90 02 00 01 	add  %o0, %g1, %o0                             
400039e0:	c0 22 3f f8 	clr  [ %o0 + -8 ]                              
    }                                                                 
                                                                      
  /*                                                                  
   *  Create the posix key for user environment.                      
   */                                                                 
  eno = pthread_key_create(                                           
400039e4:	11 10 00 60 	sethi  %hi(0x40018000), %o0                    
400039e8:	13 10 00 11 	sethi  %hi(0x40004400), %o1                    
400039ec:	90 12 23 7c 	or  %o0, 0x37c, %o0                            
400039f0:	40 00 0d 1f 	call  40006e6c <pthread_key_create>            
400039f4:	92 12 60 40 	or  %o1, 0x40, %o1                             
    &rtems_current_user_env_key,                                      
    rtems_libio_free_user_env                                         
  );                                                                  
  if (eno != 0) {                                                     
400039f8:	80 a2 20 00 	cmp  %o0, 0                                    
400039fc:	02 80 00 05 	be  40003a10 <rtems_libio_init+0xa4>           
40003a00:	11 13 10 92 	sethi  %hi(0x4c424800), %o0                    
    rtems_fatal_error_occurred( RTEMS_UNSATISFIED );                  
40003a04:	90 10 20 0d 	mov  0xd, %o0                                  
40003a08:	40 00 10 df 	call  40007d84 <rtems_fatal_error_occurred>    
40003a0c:	01 00 00 00 	nop                                            
  /*                                                                  
   *  Create the binary semaphore used to provide mutual exclusion    
   *  on the IOP Table.                                               
   */                                                                 
                                                                      
  rc = rtems_semaphore_create(                                        
40003a10:	92 10 20 01 	mov  1, %o1	! 1 <_TLS_Alignment>               
40003a14:	90 12 21 4f 	or  %o0, 0x14f, %o0                            
40003a18:	94 10 20 54 	mov  0x54, %o2                                 
40003a1c:	96 10 20 00 	clr  %o3                                       
40003a20:	19 10 00 60 	sethi  %hi(0x40018000), %o4                    
40003a24:	40 00 0e 5c 	call  40007394 <rtems_semaphore_create>        
40003a28:	98 13 23 38 	or  %o4, 0x338, %o4	! 40018338 <rtems_libio_semaphore>
    1,                                                                
    RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, 
    RTEMS_NO_PRIORITY,                                                
    &rtems_libio_semaphore                                            
  );                                                                  
  if ( rc != RTEMS_SUCCESSFUL )                                       
40003a2c:	80 a2 20 00 	cmp  %o0, 0                                    
40003a30:	12 bf ff f6 	bne  40003a08 <rtems_libio_init+0x9c>          <== NEVER TAKEN
40003a34:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
    rtems_fatal_error_occurred( rc );                                 
                                                                      
  /*                                                                  
   *  Initialize the base file system infrastructure.                 
   */                                                                 
  (* rtems_fs_init_helper)();                                         
40003a38:	c2 00 62 cc 	ld  [ %g1 + 0x2cc ], %g1	! 400156cc <rtems_fs_init_helper>
40003a3c:	9f c0 40 00 	call  %g1                                      
40003a40:	01 00 00 00 	nop                                            
40003a44:	81 c7 e0 08 	ret                                            
40003a48:	81 e8 00 00 	restore                                        
                                                                      

40004e94 <rtems_libio_set_private_env>: rtems_libio_free_user_env(env); _Thread_Enable_dispatch(); } rtems_status_code rtems_libio_set_private_env(void) {
40004e94:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc = RTEMS_SUCCESSFUL;                            
  rtems_user_env_t *old_env = rtems_current_user_env;                 
40004e98:	7f ff ff e6 	call  40004e30 <rtems_current_user_env_get>    
40004e9c:	b0 10 20 00 	clr  %i0                                       
40004ea0:	b8 10 00 08 	mov  %o0, %i4                                  
  bool uses_global_env = old_env == &rtems_global_user_env;           
                                                                      
  if (uses_global_env) {                                              
40004ea4:	11 10 00 4c 	sethi  %hi(0x40013000), %o0                    
40004ea8:	82 12 23 80 	or  %o0, 0x380, %g1	! 40013380 <rtems_global_user_env>
40004eac:	80 a7 00 01 	cmp  %i4, %g1                                  
40004eb0:	12 80 00 2c 	bne  40004f60 <rtems_libio_set_private_env+0xcc>
40004eb4:	b6 10 00 08 	mov  %o0, %i3                                  
    rtems_user_env_t *new_env = calloc(1, sizeof(*new_env));          
40004eb8:	90 10 20 01 	mov  1, %o0                                    
40004ebc:	92 10 20 24 	mov  0x24, %o1                                 
40004ec0:	40 00 15 2d 	call  4000a374 <calloc>                        
40004ec4:	b0 10 20 1a 	mov  0x1a, %i0                                 
                                                                      
    if (new_env != NULL) {                                            
40004ec8:	80 a2 20 00 	cmp  %o0, 0                                    
40004ecc:	02 80 00 25 	be  40004f60 <rtems_libio_set_private_env+0xcc>
40004ed0:	ba 10 00 08 	mov  %o0, %i5                                  
      *new_env = *old_env;                                            
40004ed4:	92 10 00 1c 	mov  %i4, %o1                                  
40004ed8:	40 00 1f c1 	call  4000cddc <memcpy>                        
40004edc:	94 10 20 24 	mov  0x24, %o2                                 
      new_env->root_directory =                                       
        rtems_filesystem_global_location_obtain(&old_env->root_directory);
40004ee0:	40 00 02 35 	call  400057b4 <rtems_filesystem_global_location_obtain>
40004ee4:	90 07 20 04 	add  %i4, 4, %o0                               
  if (uses_global_env) {                                              
    rtems_user_env_t *new_env = calloc(1, sizeof(*new_env));          
                                                                      
    if (new_env != NULL) {                                            
      *new_env = *old_env;                                            
      new_env->root_directory =                                       
40004ee8:	d0 27 60 04 	st  %o0, [ %i5 + 4 ]                           
        rtems_filesystem_global_location_obtain(&old_env->root_directory);
      new_env->current_directory =                                    
        rtems_filesystem_global_location_obtain(&old_env->current_directory);
40004eec:	40 00 02 32 	call  400057b4 <rtems_filesystem_global_location_obtain>
40004ef0:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
static inline bool rtems_filesystem_global_location_is_null(          
  const rtems_filesystem_global_location_t *global_loc                
)                                                                     
{                                                                     
  return rtems_filesystem_location_is_null( &global_loc->location );  
40004ef4:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
                                                                      
    if (new_env != NULL) {                                            
      *new_env = *old_env;                                            
      new_env->root_directory =                                       
        rtems_filesystem_global_location_obtain(&old_env->root_directory);
      new_env->current_directory =                                    
40004ef8:	d0 27 40 00 	st  %o0, [ %i5 ]                               
        rtems_filesystem_global_location_obtain(&old_env->current_directory);
                                                                      
      if (                                                            
40004efc:	c4 00 60 10 	ld  [ %g1 + 0x10 ], %g2                        
40004f00:	03 10 00 4b 	sethi  %hi(0x40012c00), %g1                    
40004f04:	82 10 61 28 	or  %g1, 0x128, %g1	! 40012d28 <rtems_filesystem_null_handlers>
40004f08:	80 a0 80 01 	cmp  %g2, %g1                                  
40004f0c:	22 80 00 18 	be,a   40004f6c <rtems_libio_set_private_env+0xd8>
40004f10:	b0 10 20 0d 	mov  0xd, %i0                                  
        !rtems_filesystem_global_location_is_null(new_env->root_directory)
          && !rtems_filesystem_global_location_is_null(new_env->current_directory)
40004f14:	c4 02 20 10 	ld  [ %o0 + 0x10 ], %g2                        
40004f18:	80 a0 80 01 	cmp  %g2, %g1                                  
40004f1c:	02 80 00 13 	be  40004f68 <rtems_libio_set_private_env+0xd4><== NEVER TAKEN
40004f20:	03 10 00 52 	sethi  %hi(0x40014800), %g1                    
      ) {                                                             
        int eno = pthread_setspecific(                                
40004f24:	d0 00 62 18 	ld  [ %g1 + 0x218 ], %o0	! 40014a18 <rtems_current_user_env_key>
40004f28:	92 10 00 1d 	mov  %i5, %o1                                  
40004f2c:	40 00 04 82 	call  40006134 <pthread_setspecific>           
40004f30:	b0 10 20 05 	mov  5, %i0                                    
          rtems_current_user_env_key,                                 
          new_env                                                     
        );                                                            
                                                                      
        if (eno == 0) {                                               
40004f34:	80 a2 20 00 	cmp  %o0, 0                                    
40004f38:	12 80 00 0d 	bne  40004f6c <rtems_libio_set_private_env+0xd8><== NEVER TAKEN
40004f3c:	01 00 00 00 	nop                                            
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40004f40:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40004f44:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40004f48:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
}                                                                     
                                                                      
static void free_user_env_protected(rtems_user_env_t *env)            
{                                                                     
  _Thread_Disable_dispatch();                                         
  rtems_libio_free_user_env(env);                                     
40004f4c:	90 16 e3 80 	or  %i3, 0x380, %o0                            
40004f50:	7f ff ff c3 	call  40004e5c <rtems_libio_free_user_env>     
40004f54:	b0 10 20 00 	clr  %i0                                       
  _Thread_Enable_dispatch();                                          
40004f58:	40 00 0e a5 	call  400089ec <_Thread_Enable_dispatch>       
40004f5c:	01 00 00 00 	nop                                            
40004f60:	81 c7 e0 08 	ret                                            
40004f64:	81 e8 00 00 	restore                                        
          free_user_env_protected(old_env);                           
        } else {                                                      
          sc = RTEMS_TOO_MANY;                                        
        }                                                             
      } else {                                                        
        sc = RTEMS_UNSATISFIED;                                       
40004f68:	b0 10 20 0d 	mov  0xd, %i0                                  <== NOT EXECUTED
      }                                                               
                                                                      
      if (sc != RTEMS_SUCCESSFUL) {                                   
        rtems_libio_free_user_env(new_env);                           
40004f6c:	7f ff ff bc 	call  40004e5c <rtems_libio_free_user_env>     
40004f70:	90 10 00 1d 	mov  %i5, %o0                                  
      sc = RTEMS_NO_MEMORY;                                           
    }                                                                 
  }                                                                   
                                                                      
  return sc;                                                          
}                                                                     
40004f74:	81 c7 e0 08 	ret                                            
40004f78:	81 e8 00 00 	restore                                        
                                                                      

400082cc <rtems_libio_to_fcntl_flags>: int rtems_libio_to_fcntl_flags( uint32_t flags ) { int fcntl_flags = 0; if ( (flags & LIBIO_FLAGS_READ_WRITE) == LIBIO_FLAGS_READ_WRITE ) {
400082cc:	84 0a 20 06 	and  %o0, 6, %g2                               
                                                                      
  return flags;                                                       
}                                                                     
                                                                      
int rtems_libio_to_fcntl_flags( uint32_t flags )                      
{                                                                     
400082d0:	82 10 00 08 	mov  %o0, %g1                                  
  int fcntl_flags = 0;                                                
                                                                      
  if ( (flags & LIBIO_FLAGS_READ_WRITE) == LIBIO_FLAGS_READ_WRITE ) { 
400082d4:	80 a0 a0 06 	cmp  %g2, 6                                    
400082d8:	02 80 00 07 	be  400082f4 <rtems_libio_to_fcntl_flags+0x28> 
400082dc:	90 10 20 02 	mov  2, %o0                                    
    fcntl_flags |= O_RDWR;                                            
  } else if ( (flags & LIBIO_FLAGS_READ) == LIBIO_FLAGS_READ) {       
400082e0:	80 88 60 02 	btst  2, %g1                                   
400082e4:	12 80 00 04 	bne  400082f4 <rtems_libio_to_fcntl_flags+0x28><== ALWAYS TAKEN
400082e8:	90 10 20 00 	clr  %o0                                       
    fcntl_flags |= O_RDONLY;                                          
  } else if ( (flags & LIBIO_FLAGS_WRITE) == LIBIO_FLAGS_WRITE) {     
400082ec:	91 30 60 02 	srl  %g1, 2, %o0                               <== NOT EXECUTED
400082f0:	90 0a 20 01 	and  %o0, 1, %o0                               <== NOT EXECUTED
    fcntl_flags |= O_WRONLY;                                          
  }                                                                   
                                                                      
  if ( (flags & LIBIO_FLAGS_NO_DELAY) == LIBIO_FLAGS_NO_DELAY ) {     
400082f4:	80 88 60 01 	btst  1, %g1                                   
400082f8:	02 80 00 04 	be  40008308 <rtems_libio_to_fcntl_flags+0x3c> 
400082fc:	80 88 62 00 	btst  0x200, %g1                               
    fcntl_flags |= O_NONBLOCK;                                        
40008300:	05 00 00 10 	sethi  %hi(0x4000), %g2                        
40008304:	90 12 00 02 	or  %o0, %g2, %o0                              
  }                                                                   
                                                                      
  if ( (flags & LIBIO_FLAGS_APPEND) == LIBIO_FLAGS_APPEND ) {         
40008308:	32 80 00 02 	bne,a   40008310 <rtems_libio_to_fcntl_flags+0x44>
4000830c:	90 12 20 08 	or  %o0, 8, %o0                                
    fcntl_flags |= O_APPEND;                                          
  }                                                                   
                                                                      
  if ( (flags & LIBIO_FLAGS_CREATE) == LIBIO_FLAGS_CREATE ) {         
40008310:	80 88 64 00 	btst  0x400, %g1                               
40008314:	32 80 00 02 	bne,a   4000831c <rtems_libio_to_fcntl_flags+0x50>
40008318:	90 12 22 00 	or  %o0, 0x200, %o0                            
    fcntl_flags |= O_CREAT;                                           
  }                                                                   
                                                                      
  return fcntl_flags;                                                 
}                                                                     
4000831c:	81 c3 e0 08 	retl                                           
                                                                      

400082f4 <rtems_malloc_statistics_at_free>: * size and thus we skip updating the statistics. */ static void rtems_malloc_statistics_at_free( void *pointer ) {
400082f4:	9d e3 bf 98 	save  %sp, -104, %sp                           
  uintptr_t size;                                                     
                                                                      
  if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) {
400082f8:	03 10 00 7a 	sethi  %hi(0x4001e800), %g1                    
400082fc:	d0 00 60 ac 	ld  [ %g1 + 0xac ], %o0	! 4001e8ac <RTEMS_Malloc_Heap>
40008300:	92 10 00 18 	mov  %i0, %o1                                  
40008304:	40 00 1b 62 	call  4000f08c <_Protected_heap_Get_block_size>
40008308:	94 07 bf fc 	add  %fp, -4, %o2                              
4000830c:	80 a2 20 00 	cmp  %o0, 0                                    
40008310:	02 80 00 08 	be  40008330 <rtems_malloc_statistics_at_free+0x3c><== NEVER TAKEN
40008314:	03 10 00 82 	sethi  %hi(0x40020800), %g1                    
    MSBUMP(lifetime_freed, size);                                     
40008318:	c8 07 bf fc 	ld  [ %fp + -4 ], %g4                          
4000831c:	82 10 61 40 	or  %g1, 0x140, %g1                            
40008320:	c4 18 60 28 	ldd  [ %g1 + 0x28 ], %g2                       
40008324:	86 80 c0 04 	addcc  %g3, %g4, %g3                           
40008328:	84 40 a0 00 	addx  %g2, 0, %g2                              
4000832c:	c4 38 60 28 	std  %g2, [ %g1 + 0x28 ]                       
40008330:	81 c7 e0 08 	ret                                            
40008334:	81 e8 00 00 	restore                                        
                                                                      

40008338 <rtems_malloc_statistics_at_malloc>: } static void rtems_malloc_statistics_at_malloc( void *pointer ) {
40008338:	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 )                                                     
4000833c:	80 a6 20 00 	cmp  %i0, 0                                    
40008340:	02 80 00 14 	be  40008390 <rtems_malloc_statistics_at_malloc+0x58><== NEVER TAKEN
40008344:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    return;                                                           
                                                                      
  _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size);
40008348:	03 10 00 7a 	sethi  %hi(0x4001e800), %g1                    
4000834c:	d0 00 60 ac 	ld  [ %g1 + 0xac ], %o0	! 4001e8ac <RTEMS_Malloc_Heap>
40008350:	92 10 00 18 	mov  %i0, %o1                                  
40008354:	40 00 1b 4e 	call  4000f08c <_Protected_heap_Get_block_size>
40008358:	94 07 bf fc 	add  %fp, -4, %o2                              
                                                                      
  MSBUMP(lifetime_allocated, actual_size);                            
4000835c:	03 10 00 82 	sethi  %hi(0x40020800), %g1                    
40008360:	c8 07 bf fc 	ld  [ %fp + -4 ], %g4                          
40008364:	82 10 61 40 	or  %g1, 0x140, %g1                            
40008368:	c4 18 60 20 	ldd  [ %g1 + 0x20 ], %g2                       
4000836c:	86 80 c0 04 	addcc  %g3, %g4, %g3                           
40008370:	84 40 a0 00 	addx  %g2, 0, %g2                              
40008374:	c4 38 60 20 	std  %g2, [ %g1 + 0x20 ]                       
                                                                      
  current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed);
40008378:	c4 00 60 2c 	ld  [ %g1 + 0x2c ], %g2                        
4000837c:	84 20 c0 02 	sub  %g3, %g2, %g2                             
  if (current_depth > s->max_depth)                                   
40008380:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
40008384:	80 a0 80 03 	cmp  %g2, %g3                                  
40008388:	38 80 00 02 	bgu,a   40008390 <rtems_malloc_statistics_at_malloc+0x58>
4000838c:	c4 20 60 18 	st  %g2, [ %g1 + 0x18 ]                        
40008390:	81 c7 e0 08 	ret                                            
40008394:	81 e8 00 00 	restore                                        
                                                                      

400102fc <rtems_memalign>: int rtems_memalign( void **pointer, size_t alignment, size_t size ) {
400102fc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  void *return_this;                                                  
                                                                      
  /*                                                                  
   *  Parameter error checks                                          
   */                                                                 
  if ( !pointer )                                                     
40010300:	ba 96 20 00 	orcc  %i0, 0, %i5                              
40010304:	12 80 00 04 	bne  40010314 <rtems_memalign+0x18>            
40010308:	03 10 00 73 	sethi  %hi(0x4001cc00), %g1                    
    return EINVAL;                                                    
4001030c:	81 c7 e0 08 	ret                                            
40010310:	91 e8 20 16 	restore  %g0, 0x16, %o0                        
  *pointer = NULL;                                                    
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if not in correct system state.
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
40010314:	c2 00 61 14 	ld  [ %g1 + 0x114 ], %g1                       
40010318:	80 a0 60 02 	cmp  %g1, 2                                    
4001031c:	02 80 00 0f 	be  40010358 <rtems_memalign+0x5c>             
40010320:	c0 27 40 00 	clr  [ %i5 ]                                   
    return EINVAL;                                                    
                                                                      
  /*                                                                  
   *  If some free's have been deferred, then do them now.            
   */                                                                 
  malloc_deferred_frees_process();                                    
40010324:	7f ff d2 89 	call  40004d48 <malloc_deferred_frees_process> 
40010328:	b0 10 20 0c 	mov  0xc, %i0                                  
  Heap_Control *heap,                                                 
  uintptr_t size,                                                     
  uintptr_t alignment                                                 
)                                                                     
{                                                                     
  return                                                              
4001032c:	03 10 00 6c 	sethi  %hi(0x4001b000), %g1                    
40010330:	d0 00 60 5c 	ld  [ %g1 + 0x5c ], %o0	! 4001b05c <RTEMS_Malloc_Heap>
40010334:	92 10 00 1a 	mov  %i2, %o1                                  
40010338:	94 10 00 19 	mov  %i1, %o2                                  
4001033c:	7f ff e9 44 	call  4000a84c <_Protected_heap_Allocate_aligned_with_boundary>
40010340:	96 10 20 00 	clr  %o3                                       
  return_this = _Protected_heap_Allocate_aligned(                     
    RTEMS_Malloc_Heap,                                                
    size,                                                             
    alignment                                                         
  );                                                                  
  if ( !return_this )                                                 
40010344:	80 a2 20 00 	cmp  %o0, 0                                    
40010348:	12 80 00 0a 	bne  40010370 <rtems_memalign+0x74>            
4001034c:	b8 10 00 08 	mov  %o0, %i4                                  
40010350:	81 c7 e0 08 	ret                                            
40010354:	81 e8 00 00 	restore                                        
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if not in correct system state.
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
       !malloc_is_system_state_OK() )                                 
40010358:	7f ff d2 78 	call  40004d38 <malloc_is_system_state_OK>     
4001035c:	01 00 00 00 	nop                                            
  *pointer = NULL;                                                    
                                                                      
  /*                                                                  
   *  Do not attempt to allocate memory if not in correct system state.
   */                                                                 
  if ( _System_state_Is_up(_System_state_Get()) &&                    
40010360:	80 a2 20 00 	cmp  %o0, 0                                    
40010364:	02 bf ff ea 	be  4001030c <rtems_memalign+0x10>             <== NEVER TAKEN
40010368:	01 00 00 00 	nop                                            
4001036c:	30 bf ff ee 	b,a   40010324 <rtems_memalign+0x28>           
    return ENOMEM;                                                    
                                                                      
  /*                                                                  
   *  If configured, update the more involved statistics              
   */                                                                 
  if ( rtems_malloc_statistics_helpers )                              
40010370:	03 10 00 6d 	sethi  %hi(0x4001b400), %g1                    
40010374:	c2 00 61 c8 	ld  [ %g1 + 0x1c8 ], %g1	! 4001b5c8 <rtems_malloc_statistics_helpers>
40010378:	80 a0 60 00 	cmp  %g1, 0                                    
4001037c:	22 80 00 06 	be,a   40010394 <rtems_memalign+0x98>          
40010380:	f8 27 40 00 	st  %i4, [ %i5 ]                               
    (*rtems_malloc_statistics_helpers->at_malloc)(pointer);           
40010384:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
40010388:	9f c0 40 00 	call  %g1                                      
4001038c:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  *pointer = return_this;                                             
40010390:	f8 27 40 00 	st  %i4, [ %i5 ]                               
  return 0;                                                           
}                                                                     
40010394:	81 c7 e0 08 	ret                                            
40010398:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

4000913c <rtems_mkdir>: return (retval); } int rtems_mkdir(const char *path, mode_t mode) {
4000913c:	9d e3 bf 58 	save  %sp, -168, %sp                           
  int success = 0;                                                    
  char *dup_path = strdup(path);                                      
40009140:	40 00 66 fc 	call  40022d30 <strdup>                        
40009144:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  if (dup_path != NULL) {                                             
40009148:	b6 92 20 00 	orcc  %o0, 0, %i3                              
4000914c:	32 80 00 04 	bne,a   4000915c <rtems_mkdir+0x20>            
40009150:	c2 4e c0 00 	ldsb  [ %i3 ], %g1                             
    success = build(dup_path, mode);                                  
    free(dup_path);                                                   
  }                                                                   
                                                                      
  return success != 0 ? 0 : -1;                                       
40009154:	81 c7 e0 08 	ret                                            
40009158:	91 e8 3f ff 	restore  %g0, -1, %o0                          
  char *p;                                                            
                                                                      
  p = path;                                                           
  oumask = 0;                                                         
  retval = 1;                                                         
  if (p[0] == '/')    /* Skip leading '/'. */                         
4000915c:	b8 10 20 01 	mov  1, %i4                                    
    ++p;                                                              
40009160:	82 18 60 2f 	xor  %g1, 0x2f, %g1                            
  char *p;                                                            
                                                                      
  p = path;                                                           
  oumask = 0;                                                         
  retval = 1;                                                         
  if (p[0] == '/')    /* Skip leading '/'. */                         
40009164:	b0 10 20 00 	clr  %i0                                       
    ++p;                                                              
40009168:	80 a0 00 01 	cmp  %g0, %g1                                  
        retval = 0;                                                   
        break;                                                        
      }                                                               
    }                                                                 
    if (!last)                                                        
        *p = '/';                                                     
4000916c:	a0 10 20 2f 	mov  0x2f, %l0                                 
                                                                      
  p = path;                                                           
  oumask = 0;                                                         
  retval = 1;                                                         
  if (p[0] == '/')    /* Skip leading '/'. */                         
    ++p;                                                              
40009170:	b4 66 ff ff 	subx  %i3, -1, %i2                             
  char *p;                                                            
                                                                      
  p = path;                                                           
  oumask = 0;                                                         
  retval = 1;                                                         
  if (p[0] == '/')    /* Skip leading '/'. */                         
40009174:	82 10 20 01 	mov  1, %g1                                    
    if (mkdir(path, last ? omode : S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
      if (errno == EEXIST || errno == EISDIR) {                       
        if (stat(path, &sb) < 0) {                                    
          retval = 0;                                                 
          break;                                                      
        } else if (!S_ISDIR(sb.st_mode)) {                            
40009178:	23 00 00 3c 	sethi  %hi(0xf000), %l1                        
4000917c:	25 00 00 10 	sethi  %hi(0x4000), %l2                        
  oumask = 0;                                                         
  retval = 1;                                                         
  if (p[0] == '/')    /* Skip leading '/'. */                         
    ++p;                                                              
  for (first = 1, last = 0; !last ; ++p) {                            
    if (p[0] == '\0')                                                 
40009180:	c6 4e 80 00 	ldsb  [ %i2 ], %g3                             
40009184:	80 a0 e0 00 	cmp  %g3, 0                                    
40009188:	22 80 00 07 	be,a   400091a4 <rtems_mkdir+0x68>             
4000918c:	84 10 20 01 	mov  1, %g2                                    
      last = 1;                                                       
    else if (p[0] != '/')                                             
40009190:	80 a0 e0 2f 	cmp  %g3, 0x2f                                 
40009194:	12 80 00 4f 	bne  400092d0 <rtems_mkdir+0x194>              
40009198:	84 10 20 00 	clr  %g2                                       
      continue;                                                       
    *p = '\0';                                                        
4000919c:	10 80 00 03 	b  400091a8 <rtems_mkdir+0x6c>                 
400091a0:	c0 2e 80 00 	clrb  [ %i2 ]                                  
400091a4:	c0 2e 80 00 	clrb  [ %i2 ]                                  
    if (!last && p[1] == '\0')                                        
400091a8:	80 a0 a0 00 	cmp  %g2, 0                                    
400091ac:	12 80 00 05 	bne  400091c0 <rtems_mkdir+0x84>               
400091b0:	ba 10 20 01 	mov  1, %i5                                    
400091b4:	c4 4e a0 01 	ldsb  [ %i2 + 1 ], %g2                         
400091b8:	80 a0 00 02 	cmp  %g0, %g2                                  
400091bc:	ba 60 3f ff 	subx  %g0, -1, %i5                             
      last = 1;                                                       
    if (first) {                                                      
400091c0:	80 a0 60 00 	cmp  %g1, 0                                    
400091c4:	02 80 00 08 	be  400091e4 <rtems_mkdir+0xa8>                
400091c8:	80 a7 60 00 	cmp  %i5, 0                                    
       *    mkdir [-m mode] dir                                       
       *                                                              
       * We change the user's umask and then restore it,              
       * instead of doing chmod's.                                    
       */                                                             
      oumask = umask(0);                                              
400091cc:	40 00 0a 0a 	call  4000b9f4 <umask>                         
400091d0:	90 10 20 00 	clr  %o0                                       
400091d4:	b0 10 00 08 	mov  %o0, %i0                                  
      numask = oumask & ~(S_IWUSR | S_IXUSR);                         
      (void)umask(numask);                                            
400091d8:	40 00 0a 07 	call  4000b9f4 <umask>                         
400091dc:	90 0a 3f 3f 	and  %o0, -193, %o0                            
      first = 0;                                                      
    }                                                                 
    if (last)                                                         
400091e0:	80 a7 60 00 	cmp  %i5, 0                                    
400091e4:	02 80 00 05 	be  400091f8 <rtems_mkdir+0xbc>                
400091e8:	92 10 21 ff 	mov  0x1ff, %o1                                
      (void)umask(oumask);                                            
400091ec:	40 00 0a 02 	call  4000b9f4 <umask>                         
400091f0:	90 10 00 18 	mov  %i0, %o0                                  
    if (mkdir(path, last ? omode : S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
400091f4:	92 10 00 19 	mov  %i1, %o1                                  
400091f8:	7f ff fd 17 	call  40008654 <mkdir>                         
400091fc:	90 10 00 1b 	mov  %i3, %o0                                  
40009200:	80 a2 20 00 	cmp  %o0, 0                                    
40009204:	16 80 00 2d 	bge  400092b8 <rtems_mkdir+0x17c>              
40009208:	80 a7 60 00 	cmp  %i5, 0                                    
      if (errno == EEXIST || errno == EISDIR) {                       
4000920c:	40 00 5f 24 	call  40020e9c <__errno>                       
40009210:	01 00 00 00 	nop                                            
40009214:	c2 02 00 00 	ld  [ %o0 ], %g1                               
40009218:	80 a0 60 11 	cmp  %g1, 0x11                                 
4000921c:	12 80 00 09 	bne  40009240 <rtems_mkdir+0x104>              
40009220:	90 10 00 1b 	mov  %i3, %o0                                  
        if (stat(path, &sb) < 0) {                                    
40009224:	40 00 00 3d 	call  40009318 <stat>                          
40009228:	92 07 bf b8 	add  %fp, -72, %o1                             
4000922c:	80 a2 20 00 	cmp  %o0, 0                                    
40009230:	16 80 00 0c 	bge  40009260 <rtems_mkdir+0x124>              <== ALWAYS TAKEN
40009234:	c2 07 bf c4 	ld  [ %fp + -60 ], %g1                         
          retval = 0;                                                 
40009238:	10 80 00 2b 	b  400092e4 <rtems_mkdir+0x1a8>                <== NOT EXECUTED
4000923c:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
      first = 0;                                                      
    }                                                                 
    if (last)                                                         
      (void)umask(oumask);                                            
    if (mkdir(path, last ? omode : S_IRWXU | S_IRWXG | S_IRWXO) < 0) {
      if (errno == EEXIST || errno == EISDIR) {                       
40009240:	40 00 5f 17 	call  40020e9c <__errno>                       
40009244:	01 00 00 00 	nop                                            
40009248:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000924c:	80 a0 60 15 	cmp  %g1, 0x15                                 
40009250:	02 bf ff f5 	be  40009224 <rtems_mkdir+0xe8>                <== NEVER TAKEN
40009254:	90 10 00 1b 	mov  %i3, %o0                                  
        if (stat(path, &sb) < 0) {                                    
          retval = 0;                                                 
40009258:	10 80 00 23 	b  400092e4 <rtems_mkdir+0x1a8>                
4000925c:	b8 10 20 00 	clr  %i4                                       
          break;                                                      
        } else if (!S_ISDIR(sb.st_mode)) {                            
40009260:	82 08 40 11 	and  %g1, %l1, %g1                             
40009264:	80 a0 40 12 	cmp  %g1, %l2                                  
40009268:	02 80 00 0f 	be  400092a4 <rtems_mkdir+0x168>               
4000926c:	80 a7 60 00 	cmp  %i5, 0                                    
          if (last)                                                   
40009270:	02 80 00 08 	be  40009290 <rtems_mkdir+0x154>               
40009274:	01 00 00 00 	nop                                            
            errno = EEXIST;                                           
40009278:	40 00 5f 09 	call  40020e9c <__errno>                       
4000927c:	b8 10 20 00 	clr  %i4	! 0 <_TLS_BSS_size>                   
40009280:	82 10 20 11 	mov  0x11, %g1                                 
40009284:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40009288:	10 80 00 17 	b  400092e4 <rtems_mkdir+0x1a8>                
4000928c:	ba 10 20 01 	mov  1, %i5                                    
          else                                                        
            errno = ENOTDIR;                                          
40009290:	40 00 5f 03 	call  40020e9c <__errno>                       
40009294:	b8 10 20 00 	clr  %i4                                       
40009298:	82 10 20 14 	mov  0x14, %g1                                 
4000929c:	10 80 00 12 	b  400092e4 <rtems_mkdir+0x1a8>                
400092a0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
          retval = 0;                                                 
          break;                                                      
        }                                                             
        if (last)                                                     
400092a4:	32 80 00 09 	bne,a   400092c8 <rtems_mkdir+0x18c>           
400092a8:	b8 10 20 02 	mov  2, %i4                                    
        retval = 0;                                                   
        break;                                                        
      }                                                               
    }                                                                 
    if (!last)                                                        
        *p = '/';                                                     
400092ac:	e0 2e 80 00 	stb  %l0, [ %i2 ]                              
400092b0:	10 80 00 07 	b  400092cc <rtems_mkdir+0x190>                
400092b4:	84 10 20 00 	clr  %g2                                       
      } else {                                                        
        retval = 0;                                                   
        break;                                                        
      }                                                               
    }                                                                 
    if (!last)                                                        
400092b8:	22 bf ff fe 	be,a   400092b0 <rtems_mkdir+0x174>            
400092bc:	e0 2e 80 00 	stb  %l0, [ %i2 ]                              
          else                                                        
            errno = ENOTDIR;                                          
          retval = 0;                                                 
          break;                                                      
        }                                                             
        if (last)                                                     
400092c0:	10 80 00 03 	b  400092cc <rtems_mkdir+0x190>                
400092c4:	84 10 20 01 	mov  1, %g2                                    
400092c8:	84 10 20 01 	mov  1, %g2                                    
400092cc:	82 10 20 00 	clr  %g1                                       
  p = path;                                                           
  oumask = 0;                                                         
  retval = 1;                                                         
  if (p[0] == '/')    /* Skip leading '/'. */                         
    ++p;                                                              
  for (first = 1, last = 0; !last ; ++p) {                            
400092d0:	80 a0 a0 00 	cmp  %g2, 0                                    
400092d4:	02 bf ff ab 	be  40009180 <rtems_mkdir+0x44>                
400092d8:	b4 06 a0 01 	inc  %i2                                       
400092dc:	10 80 00 03 	b  400092e8 <rtems_mkdir+0x1ac>                
400092e0:	ba 10 20 01 	mov  1, %i5                                    
    }                                                                 
    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) {                                    
400092e4:	82 10 20 00 	clr  %g1                                       
      }                                                               
    }                                                                 
    if (!last)                                                        
        *p = '/';                                                     
  }                                                                   
  if (!first && !last)                                                
400092e8:	80 97 40 01 	orcc  %i5, %g1, %g0                            
400092ec:	12 80 00 04 	bne  400092fc <rtems_mkdir+0x1c0>              
400092f0:	01 00 00 00 	nop                                            
    (void)umask(oumask);                                              
400092f4:	40 00 09 c0 	call  4000b9f4 <umask>                         
400092f8:	90 10 00 18 	mov  %i0, %o0                                  
  int success = 0;                                                    
  char *dup_path = strdup(path);                                      
                                                                      
  if (dup_path != NULL) {                                             
    success = build(dup_path, mode);                                  
    free(dup_path);                                                   
400092fc:	7f ff fb 0c 	call  40007f2c <free>                          
40009300:	90 10 00 1b 	mov  %i3, %o0                                  
  }                                                                   
                                                                      
  return success != 0 ? 0 : -1;                                       
40009304:	80 a7 20 00 	cmp  %i4, 0                                    
40009308:	02 bf ff 93 	be  40009154 <rtems_mkdir+0x18>                
4000930c:	01 00 00 00 	nop                                            
}                                                                     
40009310:	81 c7 e0 08 	ret                                            
40009314:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40009398 <rtems_partition_create>: uint32_t length, uint32_t buffer_size, rtems_attribute attribute_set, rtems_id *id ) {
40009398:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Partition_Control *the_partition;                                   
                                                                      
  if ( !rtems_is_name_valid( name ) )                                 
4000939c:	80 a6 20 00 	cmp  %i0, 0                                    
400093a0:	02 80 00 36 	be  40009478 <rtems_partition_create+0xe0>     
400093a4:	82 10 20 03 	mov  3, %g1                                    
    return RTEMS_INVALID_NAME;                                        
                                                                      
  if ( !starting_address )                                            
400093a8:	80 a6 60 00 	cmp  %i1, 0                                    
400093ac:	02 80 00 33 	be  40009478 <rtems_partition_create+0xe0>     
400093b0:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  if ( !id )                                                          
400093b4:	80 a7 60 00 	cmp  %i5, 0                                    
400093b8:	02 80 00 30 	be  40009478 <rtems_partition_create+0xe0>     <== NEVER TAKEN
400093bc:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  if ( length == 0 || buffer_size == 0 || length < buffer_size ||     
400093c0:	02 80 00 2e 	be  40009478 <rtems_partition_create+0xe0>     
400093c4:	82 10 20 08 	mov  8, %g1                                    
400093c8:	80 a6 e0 00 	cmp  %i3, 0                                    
400093cc:	02 80 00 2b 	be  40009478 <rtems_partition_create+0xe0>     
400093d0:	80 a6 80 1b 	cmp  %i2, %i3                                  
400093d4:	0a 80 00 29 	bcs  40009478 <rtems_partition_create+0xe0>    
400093d8:	80 8e e0 07 	btst  7, %i3                                   
400093dc:	12 80 00 27 	bne  40009478 <rtems_partition_create+0xe0>    
400093e0:	80 8e 60 07 	btst  7, %i1                                   
         !_Partition_Is_buffer_size_aligned( buffer_size ) )          
    return RTEMS_INVALID_SIZE;                                        
                                                                      
  if ( !_Addresses_Is_aligned( starting_address ) )                   
400093e4:	12 80 00 25 	bne  40009478 <rtems_partition_create+0xe0>    
400093e8:	82 10 20 09 	mov  9, %g1                                    
 *  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 );
400093ec:	23 10 00 77 	sethi  %hi(0x4001dc00), %l1                    
400093f0:	25 10 00 78 	sethi  %hi(0x4001e000), %l2                    
400093f4:	40 00 07 77 	call  4000b1d0 <_Objects_Allocate>             
400093f8:	90 14 62 c4 	or  %l1, 0x2c4, %o0                            
    return RTEMS_MP_NOT_CONFIGURED;                                   
#endif                                                                
                                                                      
  the_partition = _Partition_Allocate();                              
                                                                      
  if ( !the_partition ) {                                             
400093fc:	a0 92 20 00 	orcc  %o0, 0, %l0                              
40009400:	32 80 00 06 	bne,a   40009418 <rtems_partition_create+0x80> 
40009404:	f8 24 20 1c 	st  %i4, [ %l0 + 0x1c ]                        
40009408:	40 00 04 1e 	call  4000a480 <_API_Mutex_Unlock>             
4000940c:	d0 04 a0 d8 	ld  [ %l2 + 0xd8 ], %o0                        
    _Objects_Allocator_unlock();                                      
    return RTEMS_TOO_MANY;                                            
40009410:	10 80 00 1a 	b  40009478 <rtems_partition_create+0xe0>      
40009414:	82 10 20 05 	mov  5, %g1                                    
  the_partition->buffer_size           = buffer_size;                 
  the_partition->attribute_set         = attribute_set;               
  the_partition->number_of_used_blocks = 0;                           
                                                                      
  _Chain_Initialize( &the_partition->Memory, starting_address,        
                        length / buffer_size, buffer_size );          
40009418:	92 10 00 1b 	mov  %i3, %o1                                  
    _Objects_Allocator_unlock();                                      
    return RTEMS_TOO_MANY;                                            
  }                                                                   
#endif                                                                
                                                                      
  the_partition->starting_address      = starting_address;            
4000941c:	f2 24 20 10 	st  %i1, [ %l0 + 0x10 ]                        
  the_partition->length                = length;                      
40009420:	f4 24 20 14 	st  %i2, [ %l0 + 0x14 ]                        
  the_partition->buffer_size           = buffer_size;                 
40009424:	f6 24 20 18 	st  %i3, [ %l0 + 0x18 ]                        
  the_partition->attribute_set         = attribute_set;               
  the_partition->number_of_used_blocks = 0;                           
40009428:	c0 24 20 20 	clr  [ %l0 + 0x20 ]                            
                                                                      
  _Chain_Initialize( &the_partition->Memory, starting_address,        
                        length / buffer_size, buffer_size );          
4000942c:	40 00 32 67 	call  40015dc8 <.udiv>                         
40009430:	90 10 00 1a 	mov  %i2, %o0                                  
  the_partition->length                = length;                      
  the_partition->buffer_size           = buffer_size;                 
  the_partition->attribute_set         = attribute_set;               
  the_partition->number_of_used_blocks = 0;                           
                                                                      
  _Chain_Initialize( &the_partition->Memory, starting_address,        
40009434:	92 10 00 19 	mov  %i1, %o1                                  
                        length / buffer_size, buffer_size );          
40009438:	94 10 00 08 	mov  %o0, %o2                                  
  the_partition->length                = length;                      
  the_partition->buffer_size           = buffer_size;                 
  the_partition->attribute_set         = attribute_set;               
  the_partition->number_of_used_blocks = 0;                           
                                                                      
  _Chain_Initialize( &the_partition->Memory, starting_address,        
4000943c:	96 10 00 1b 	mov  %i3, %o3                                  
40009440:	b8 04 20 24 	add  %l0, 0x24, %i4                            
40009444:	40 00 04 3d 	call  4000a538 <_Chain_Initialize>             
40009448:	90 10 00 1c 	mov  %i4, %o0                                  
  Objects_Name         name                                           
)                                                                     
{                                                                     
  the_object->name = name;                                            
                                                                      
  _Objects_Set_local_object(                                          
4000944c:	c4 14 20 0a 	lduh  [ %l0 + 0xa ], %g2                       
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open(                              
  Objects_Information *information,                                   
40009450:	a2 14 62 c4 	or  %l1, 0x2c4, %l1                            
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40009454:	c6 04 60 1c 	ld  [ %l1 + 0x1c ], %g3                        
  Objects_Information *information,                                   
  Objects_Control     *the_object,                                    
  Objects_Name         name                                           
)                                                                     
{                                                                     
  the_object->name = name;                                            
40009458:	f0 24 20 0c 	st  %i0, [ %l0 + 0xc ]                         
                                                                      
  _Objects_Set_local_object(                                          
4000945c:	c2 04 20 08 	ld  [ %l0 + 8 ], %g1                           
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40009460:	85 28 a0 02 	sll  %g2, 2, %g2                               
40009464:	e0 20 c0 02 	st  %l0, [ %g3 + %g2 ]                         
40009468:	d0 04 a0 d8 	ld  [ %l2 + 0xd8 ], %o0                        
4000946c:	40 00 04 05 	call  4000a480 <_API_Mutex_Unlock>             
40009470:	c2 27 40 00 	st  %g1, [ %i5 ]                               
      0                  /* Not used */                               
    );                                                                
#endif                                                                
                                                                      
  _Objects_Allocator_unlock();                                        
  return RTEMS_SUCCESSFUL;                                            
40009474:	82 10 20 00 	clr  %g1                                       
}                                                                     
40009478:	81 c7 e0 08 	ret                                            
4000947c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000806c <rtems_partition_return_buffer>: rtems_status_code rtems_partition_return_buffer( rtems_id id, void *buffer ) {
4000806c:	9d e3 bf 98 	save  %sp, -104, %sp                           
RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Get (              
  Objects_Id         id,                                              
  Objects_Locations *location                                         
)                                                                     
{                                                                     
  return (Partition_Control *)                                        
40008070:	11 10 00 69 	sethi  %hi(0x4001a400), %o0                    
40008074:	92 10 00 18 	mov  %i0, %o1                                  
40008078:	90 12 22 10 	or  %o0, 0x210, %o0                            
4000807c:	40 00 07 4c 	call  40009dac <_Objects_Get>                  
40008080:	94 07 bf fc 	add  %fp, -4, %o2                              
   Partition_Control           *the_partition;                        
  Objects_Locations           location;                               
                                                                      
  the_partition = _Partition_Get( id, &location );                    
  switch ( location ) {                                               
40008084:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40008088:	80 a0 60 00 	cmp  %g1, 0                                    
4000808c:	12 80 00 21 	bne  40008110 <rtems_partition_return_buffer+0xa4>
40008090:	ba 10 00 08 	mov  %o0, %i5                                  
)                                                                     
{                                                                     
  void *starting;                                                     
  void *ending;                                                       
                                                                      
  starting = the_partition->starting_address;                         
40008094:	d0 02 20 10 	ld  [ %o0 + 0x10 ], %o0                        
RTEMS_INLINE_ROUTINE void *_Addresses_Add_offset (                    
  const void *base,                                                   
  uintptr_t   offset                                                  
)                                                                     
{                                                                     
  return (void *)((uintptr_t)base + offset);                          
40008098:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4000809c:	82 02 00 01 	add  %o0, %g1, %g1                             
  ending   = _Addresses_Add_offset( starting, the_partition->length );
                                                                      
  return (                                                            
    _Addresses_Is_in_range( the_buffer, starting, ending ) &&         
400080a0:	80 a6 40 01 	cmp  %i1, %g1                                  
400080a4:	18 80 00 0b 	bgu  400080d0 <rtems_partition_return_buffer+0x64>
400080a8:	82 10 20 00 	clr  %g1                                       
400080ac:	80 a6 40 08 	cmp  %i1, %o0                                  
400080b0:	0a 80 00 09 	bcs  400080d4 <rtems_partition_return_buffer+0x68><== NEVER TAKEN
400080b4:	80 a0 60 00 	cmp  %g1, 0                                    
  offset = (uint32_t) _Addresses_Subtract(                            
    the_buffer,                                                       
    the_partition->starting_address                                   
  );                                                                  
                                                                      
  return ((offset % the_partition->buffer_size) == 0);                
400080b8:	d2 07 60 18 	ld  [ %i5 + 0x18 ], %o1                        
400080bc:	40 00 30 fd 	call  400144b0 <.urem>                         
400080c0:	90 26 40 08 	sub  %i1, %o0, %o0                             
                                                                      
  starting = the_partition->starting_address;                         
  ending   = _Addresses_Add_offset( starting, the_partition->length );
                                                                      
  return (                                                            
    _Addresses_Is_in_range( the_buffer, starting, ending ) &&         
400080c4:	80 a0 00 08 	cmp  %g0, %o0                                  
400080c8:	10 80 00 02 	b  400080d0 <rtems_partition_return_buffer+0x64>
400080cc:	82 60 3f ff 	subx  %g0, -1, %g1                             
                                                                      
    case OBJECTS_LOCAL:                                               
      if ( _Partition_Is_buffer_valid( buffer, the_partition ) ) {    
400080d0:	80 a0 60 00 	cmp  %g1, 0                                    
400080d4:	02 80 00 0b 	be  40008100 <rtems_partition_return_buffer+0x94>
400080d8:	90 07 60 24 	add  %i5, 0x24, %o0                            
RTEMS_INLINE_ROUTINE void _Partition_Free_buffer (                    
  Partition_Control *the_partition,                                   
  Chain_Node        *the_buffer                                       
)                                                                     
{                                                                     
  _Chain_Append( &the_partition->Memory, the_buffer );                
400080dc:	40 00 03 4b 	call  40008e08 <_Chain_Append>                 
400080e0:	92 10 00 19 	mov  %i1, %o1                                  
        _Partition_Free_buffer( the_partition, buffer );              
        the_partition->number_of_used_blocks -= 1;                    
400080e4:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
        _Objects_Put( &the_partition->Object );                       
        return RTEMS_SUCCESSFUL;                                      
400080e8:	b0 10 20 00 	clr  %i0                                       
  switch ( location ) {                                               
                                                                      
    case OBJECTS_LOCAL:                                               
      if ( _Partition_Is_buffer_valid( buffer, the_partition ) ) {    
        _Partition_Free_buffer( the_partition, buffer );              
        the_partition->number_of_used_blocks -= 1;                    
400080ec:	82 00 7f ff 	add  %g1, -1, %g1                              
400080f0:	40 00 0a a5 	call  4000ab84 <_Thread_Enable_dispatch>       
400080f4:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
        _Objects_Put( &the_partition->Object );                       
        return RTEMS_SUCCESSFUL;                                      
400080f8:	81 c7 e0 08 	ret                                            
400080fc:	81 e8 00 00 	restore                                        
40008100:	40 00 0a a1 	call  4000ab84 <_Thread_Enable_dispatch>       
40008104:	b0 10 20 09 	mov  9, %i0                                    
      }                                                               
      _Objects_Put( &the_partition->Object );                         
      return RTEMS_INVALID_ADDRESS;                                   
40008108:	81 c7 e0 08 	ret                                            
4000810c:	81 e8 00 00 	restore                                        
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return RTEMS_INVALID_ID;                                            
}                                                                     
40008110:	81 c7 e0 08 	ret                                            
40008114:	91 e8 20 04 	restore  %g0, 4, %o0                           
                                                                      

40007300 <rtems_pthread_attribute_compare>: int rtems_pthread_attribute_compare( const pthread_attr_t *attr1, const pthread_attr_t *attr2 ) {
40007300:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ( attr1->is_initialized  !=  attr2->is_initialized )             
40007304:	c4 06 00 00 	ld  [ %i0 ], %g2                               
40007308:	c2 06 40 00 	ld  [ %i1 ], %g1                               
4000730c:	80 a0 80 01 	cmp  %g2, %g1                                  
40007310:	12 80 00 50 	bne  40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
40007314:	90 10 20 01 	mov  1, %o0                                    
    return 1;                                                         
                                                                      
  if ( attr1->stackaddr != attr2->stackaddr )                         
40007318:	c4 06 20 04 	ld  [ %i0 + 4 ], %g2                           
4000731c:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
40007320:	80 a0 80 01 	cmp  %g2, %g1                                  
40007324:	12 80 00 4b 	bne  40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
40007328:	01 00 00 00 	nop                                            
    return 1;                                                         
                                                                      
  if ( attr1->stacksize != attr2->stacksize )                         
4000732c:	c4 06 20 08 	ld  [ %i0 + 8 ], %g2                           
40007330:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
40007334:	80 a0 80 01 	cmp  %g2, %g1                                  
40007338:	12 80 00 46 	bne  40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
4000733c:	01 00 00 00 	nop                                            
    return 1;                                                         
                                                                      
  if ( attr1->contentionscope != attr2->contentionscope )             
40007340:	c4 06 20 0c 	ld  [ %i0 + 0xc ], %g2                         
40007344:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
40007348:	80 a0 80 01 	cmp  %g2, %g1                                  
4000734c:	12 80 00 41 	bne  40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
40007350:	01 00 00 00 	nop                                            
    return 1;                                                         
                                                                      
  if ( attr1->inheritsched != attr2->inheritsched )                   
40007354:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
40007358:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4000735c:	80 a0 80 01 	cmp  %g2, %g1                                  
40007360:	12 80 00 3c 	bne  40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
40007364:	01 00 00 00 	nop                                            
    return 1;                                                         
                                                                      
  if ( attr1->schedpolicy != attr2->schedpolicy )                     
40007368:	c4 06 20 14 	ld  [ %i0 + 0x14 ], %g2                        
4000736c:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        
40007370:	80 a0 80 01 	cmp  %g2, %g1                                  
40007374:	12 80 00 37 	bne  40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
40007378:	92 06 60 18 	add  %i1, 0x18, %o1                            
    return 1;                                                         
                                                                      
  if (memcmp(                                                         
4000737c:	90 06 20 18 	add  %i0, 0x18, %o0                            
40007380:	40 00 26 49 	call  40010ca4 <memcmp>                        
40007384:	94 10 20 1c 	mov  0x1c, %o2                                 
40007388:	80 a2 20 00 	cmp  %o0, 0                                    
4000738c:	32 80 00 31 	bne,a   40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
40007390:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
    sizeof(struct sched_param)                                        
  ))                                                                  
    return 1;                                                         
                                                                      
  #if HAVE_DECL_PTHREAD_ATTR_SETGUARDSIZE                             
    if ( attr1->guardsize != attr2->guardsize )                       
40007394:	c4 06 20 34 	ld  [ %i0 + 0x34 ], %g2                        
40007398:	c2 06 60 34 	ld  [ %i1 + 0x34 ], %g1                        
4000739c:	80 a0 80 01 	cmp  %g2, %g1                                  
400073a0:	32 80 00 2c 	bne,a   40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
400073a4:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
      return 1;                                                       
  #endif                                                              
                                                                      
  #if defined(_POSIX_THREAD_CPUTIME)                                  
    if ( attr1->cputime_clock_allowed != attr2->cputime_clock_allowed )
400073a8:	c4 06 20 38 	ld  [ %i0 + 0x38 ], %g2                        
400073ac:	c2 06 60 38 	ld  [ %i1 + 0x38 ], %g1                        
400073b0:	80 a0 80 01 	cmp  %g2, %g1                                  
400073b4:	32 80 00 27 	bne,a   40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
400073b8:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
      return 1;                                                       
  #endif                                                              
                                                                      
  if ( attr1->detachstate != attr2->detachstate )                     
400073bc:	c4 06 20 3c 	ld  [ %i0 + 0x3c ], %g2                        
400073c0:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
400073c4:	80 a0 80 01 	cmp  %g2, %g1                                  
400073c8:	32 80 00 22 	bne,a   40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
400073cc:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
    return 1;                                                         
                                                                      
  #if defined(__RTEMS_HAVE_SYS_CPUSET_H__)                            
    if ( attr1->affinitysetsize != attr2->affinitysetsize )           
400073d0:	c4 06 20 40 	ld  [ %i0 + 0x40 ], %g2                        
400073d4:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
400073d8:	80 a0 80 01 	cmp  %g2, %g1                                  
400073dc:	32 80 00 1d 	bne,a   40007450 <rtems_pthread_attribute_compare+0x150><== NEVER TAKEN
400073e0:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
}                                                                     
                                                                      
static __inline int CPU_EQUAL_S(size_t setsize, const cpu_set_t *set1,
  const cpu_set_t *set2)                                              
{                                                                     
  const cpu_set_word_t *w1 = &set1->__bits[0];                        
400073e4:	c8 06 20 44 	ld  [ %i0 + 0x44 ], %g4                        
  const cpu_set_word_t *w2 = &set2->__bits[0];                        
400073e8:	fa 06 60 44 	ld  [ %i1 + 0x44 ], %i5                        
  size_t n = setsize / sizeof(*w1);                                   
400073ec:	85 30 a0 02 	srl  %g2, 2, %g2                               
  size_t i;                                                           
                                                                      
  for (i = 0; i < n; ++i)                                             
400073f0:	82 10 20 00 	clr  %g1                                       
400073f4:	80 a0 40 02 	cmp  %g1, %g2                                  
400073f8:	02 80 00 09 	be  4000741c <rtems_pthread_attribute_compare+0x11c><== ALWAYS TAKEN
400073fc:	87 28 60 02 	sll  %g1, 2, %g3                               
    if (w1[i] != w2[i])                                               
40007400:	f8 01 00 03 	ld  [ %g4 + %g3 ], %i4                         <== NOT EXECUTED
40007404:	c6 07 40 03 	ld  [ %i5 + %g3 ], %g3                         <== NOT EXECUTED
40007408:	80 a7 00 03 	cmp  %i4, %g3                                  <== NOT EXECUTED
4000740c:	02 bf ff fa 	be  400073f4 <rtems_pthread_attribute_compare+0xf4><== NOT EXECUTED
40007410:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
  const pthread_attr_t *attr1,                                        
  const pthread_attr_t *attr2                                         
)                                                                     
{                                                                     
  if ( attr1->is_initialized  !=  attr2->is_initialized )             
    return 1;                                                         
40007414:	10 80 00 0f 	b  40007450 <rtems_pthread_attribute_compare+0x150><== NOT EXECUTED
40007418:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
}                                                                     
                                                                      
static __inline int CPU_EQUAL_S(size_t setsize, const cpu_set_t *set1,
  const cpu_set_t *set2)                                              
{                                                                     
  const cpu_set_word_t *w1 = &set1->__bits[0];                        
4000741c:	b0 06 20 48 	add  %i0, 0x48, %i0                            
  const cpu_set_word_t *w2 = &set2->__bits[0];                        
40007420:	b2 06 60 48 	add  %i1, 0x48, %i1                            
  size_t n = setsize / sizeof(*w1);                                   
  size_t i;                                                           
                                                                      
  for (i = 0; i < n; ++i)                                             
40007424:	82 10 20 00 	clr  %g1                                       
40007428:	80 a0 40 02 	cmp  %g1, %g2                                  
4000742c:	02 80 00 09 	be  40007450 <rtems_pthread_attribute_compare+0x150><== ALWAYS TAKEN
40007430:	87 28 60 02 	sll  %g1, 2, %g3                               
    if (w1[i] != w2[i])                                               
40007434:	c8 06 00 03 	ld  [ %i0 + %g3 ], %g4                         <== NOT EXECUTED
40007438:	c6 06 40 03 	ld  [ %i1 + %g3 ], %g3                         <== NOT EXECUTED
4000743c:	80 a1 00 03 	cmp  %g4, %g3                                  <== NOT EXECUTED
40007440:	12 bf ff f5 	bne  40007414 <rtems_pthread_attribute_compare+0x114><== NOT EXECUTED
40007444:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
  const cpu_set_word_t *w1 = &set1->__bits[0];                        
  const cpu_set_word_t *w2 = &set2->__bits[0];                        
  size_t n = setsize / sizeof(*w1);                                   
  size_t i;                                                           
                                                                      
  for (i = 0; i < n; ++i)                                             
40007448:	10 bf ff f9 	b  4000742c <rtems_pthread_attribute_compare+0x12c><== NOT EXECUTED
4000744c:	80 a0 40 02 	cmp  %g1, %g2                                  <== NOT EXECUTED
    ))                                                                
      return 1;                                                       
  #endif                                                              
                                                                      
  return 0;                                                           
}                                                                     
40007450:	81 c7 e0 08 	ret                                            
40007454:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40008370 <rtems_rate_monotonic_period>: rtems_status_code rtems_rate_monotonic_period( rtems_id id, rtems_interval length ) {
40008370:	9d e3 bf 98 	save  %sp, -104, %sp                           
RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Get (    
  Objects_Id         id,                                              
  Objects_Locations *location                                         
)                                                                     
{                                                                     
  return (Rate_monotonic_Control *)                                   
40008374:	11 10 00 68 	sethi  %hi(0x4001a000), %o0                    
40008378:	92 10 00 18 	mov  %i0, %o1                                  
4000837c:	90 12 22 a0 	or  %o0, 0x2a0, %o0                            
40008380:	40 00 09 38 	call  4000a860 <_Objects_Get>                  
40008384:	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 ) {                                               
40008388:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000838c:	80 a0 60 00 	cmp  %g1, 0                                    
40008390:	12 80 00 6c 	bne  40008540 <rtems_rate_monotonic_period+0x1d0>
40008394:	ba 10 00 08 	mov  %o0, %i5                                  
    case OBJECTS_LOCAL:                                               
      if ( !_Thread_Is_executing( the_period->owner ) ) {             
40008398:	c4 02 20 40 	ld  [ %o0 + 0x40 ], %g2                        
4000839c:	c2 01 a0 18 	ld  [ %g6 + 0x18 ], %g1                        
400083a0:	80 a0 80 01 	cmp  %g2, %g1                                  
400083a4:	02 80 00 06 	be  400083bc <rtems_rate_monotonic_period+0x4c>
400083a8:	80 a6 60 00 	cmp  %i1, 0                                    
RTEMS_INLINE_ROUTINE void _Objects_Put(                               
  Objects_Control *the_object                                         
)                                                                     
{                                                                     
  (void) the_object;                                                  
  _Thread_Enable_dispatch();                                          
400083ac:	40 00 0c a3 	call  4000b638 <_Thread_Enable_dispatch>       
400083b0:	b0 10 20 17 	mov  0x17, %i0                                 
        _Objects_Put( &the_period->Object );                          
        return RTEMS_NOT_OWNER_OF_RESOURCE;                           
400083b4:	81 c7 e0 08 	ret                                            
400083b8:	81 e8 00 00 	restore                                        
      }                                                               
                                                                      
      if ( length == RTEMS_PERIOD_STATUS ) {                          
400083bc:	12 80 00 0f 	bne  400083f8 <rtems_rate_monotonic_period+0x88>
400083c0:	01 00 00 00 	nop                                            
        switch ( the_period->state ) {                                
400083c4:	c2 02 20 38 	ld  [ %o0 + 0x38 ], %g1                        
400083c8:	80 a0 60 00 	cmp  %g1, 0                                    
400083cc:	02 80 00 07 	be  400083e8 <rtems_rate_monotonic_period+0x78>
400083d0:	b0 10 20 0b 	mov  0xb, %i0                                  
400083d4:	82 00 7f fd 	add  %g1, -3, %g1                              
400083d8:	80 a0 60 01 	cmp  %g1, 1                                    
400083dc:	18 80 00 03 	bgu  400083e8 <rtems_rate_monotonic_period+0x78>
400083e0:	b0 10 20 00 	clr  %i0                                       
          case RATE_MONOTONIC_INACTIVE:                               
            return_value = RTEMS_NOT_DEFINED;                         
            break;                                                    
          case RATE_MONOTONIC_EXPIRED:                                
          case RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING:                 
            return_value = RTEMS_TIMEOUT;                             
400083e4:	b0 10 20 06 	mov  6, %i0                                    
400083e8:	40 00 0c 94 	call  4000b638 <_Thread_Enable_dispatch>       
400083ec:	01 00 00 00 	nop                                            
          default:              /* unreached -- only to remove warnings */
            return_value = RTEMS_SUCCESSFUL;                          
            break;                                                    
        }                                                             
        _Objects_Put( &the_period->Object );                          
        return( return_value );                                       
400083f0:	81 c7 e0 08 	ret                                            
400083f4:	81 e8 00 00 	restore                                        
      }                                                               
                                                                      
      _ISR_Disable( level );                                          
400083f8:	7f ff eb 3f 	call  400030f4 <sparc_disable_interrupts>      
400083fc:	01 00 00 00 	nop                                            
40008400:	b8 10 00 08 	mov  %o0, %i4                                  
      if ( the_period->state == RATE_MONOTONIC_INACTIVE ) {           
40008404:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
40008408:	80 a0 60 00 	cmp  %g1, 0                                    
4000840c:	12 80 00 15 	bne  40008460 <rtems_rate_monotonic_period+0xf0>
40008410:	80 a0 60 02 	cmp  %g1, 2                                    
        _ISR_Enable( level );                                         
40008414:	7f ff eb 3b 	call  40003100 <sparc_enable_interrupts>       
40008418:	01 00 00 00 	nop                                            
        the_period->next_length = length;                             
                                                                      
        /*                                                            
         *  Baseline statistics information for the beginning of a period.
         */                                                           
        _Rate_monotonic_Initiate_statistics( the_period );            
4000841c:	90 10 00 1d 	mov  %i5, %o0                                  
40008420:	7f ff ff b9 	call  40008304 <_Rate_monotonic_Initiate_statistics>
40008424:	f2 27 60 3c 	st  %i1, [ %i5 + 0x3c ]                        
                                                                      
        the_period->state = RATE_MONOTONIC_ACTIVE;                    
40008428:	82 10 20 02 	mov  2, %g1                                    
4000842c:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
  Objects_Id                      id,                                 
  void                           *user_data                           
)                                                                     
{                                                                     
  the_watchdog->state     = WATCHDOG_INACTIVE;                        
  the_watchdog->routine   = routine;                                  
40008430:	03 10 00 21 	sethi  %hi(0x40008400), %g1                    
40008434:	82 10 63 fc 	or  %g1, 0x3fc, %g1	! 400087fc <_Rate_monotonic_Timeout>
  Watchdog_Service_routine_entry  routine,                            
  Objects_Id                      id,                                 
  void                           *user_data                           
)                                                                     
{                                                                     
  the_watchdog->state     = WATCHDOG_INACTIVE;                        
40008438:	c0 27 60 18 	clr  [ %i5 + 0x18 ]                            
  the_watchdog->routine   = routine;                                  
4000843c:	c2 27 60 2c 	st  %g1, [ %i5 + 0x2c ]                        
  the_watchdog->id        = id;                                       
40008440:	f0 27 60 30 	st  %i0, [ %i5 + 0x30 ]                        
  the_watchdog->user_data = user_data;                                
40008444:	c0 27 60 34 	clr  [ %i5 + 0x34 ]                            
  Watchdog_Control      *the_watchdog,                                
  Watchdog_Interval      units                                        
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
40008448:	f2 27 60 1c 	st  %i1, [ %i5 + 0x1c ]                        
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
4000844c:	11 10 00 69 	sethi  %hi(0x4001a400), %o0                    
40008450:	92 07 60 10 	add  %i5, 0x10, %o1                            
40008454:	40 00 11 0a 	call  4000c87c <_Watchdog_Insert>              
40008458:	90 12 20 10 	or  %o0, 0x10, %o0                             
4000845c:	30 80 00 1c 	b,a   400084cc <rtems_rate_monotonic_period+0x15c>
        _Watchdog_Insert_ticks( &the_period->Timer, length );         
        _Objects_Put( &the_period->Object );                          
        return RTEMS_SUCCESSFUL;                                      
      }                                                               
                                                                      
      if ( the_period->state == RATE_MONOTONIC_ACTIVE ) {             
40008460:	12 80 00 1f 	bne  400084dc <rtems_rate_monotonic_period+0x16c>
40008464:	80 a0 60 04 	cmp  %g1, 4                                    
        /*                                                            
         *  Update statistics from the concluding period.             
         */                                                           
        _Rate_monotonic_Update_statistics( the_period );              
40008468:	7f ff ff 5e 	call  400081e0 <_Rate_monotonic_Update_statistics>
4000846c:	90 10 00 1d 	mov  %i5, %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;         
40008470:	82 10 20 01 	mov  1, %g1                                    
        the_period->next_length = length;                             
40008474:	f2 27 60 3c 	st  %i1, [ %i5 + 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;         
40008478:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
        the_period->next_length = length;                             
                                                                      
        _ISR_Enable( level );                                         
4000847c:	7f ff eb 21 	call  40003100 <sparc_enable_interrupts>       
40008480:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
        _Thread_Executing->Wait.id = the_period->Object.id;           
40008484:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
40008488:	d0 01 a0 18 	ld  [ %g6 + 0x18 ], %o0                        
        _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
4000848c:	13 00 00 10 	sethi  %hi(0x4000), %o1                        
40008490:	40 00 0f c1 	call  4000c394 <_Thread_Set_state>             
40008494:	c2 22 20 20 	st  %g1, [ %o0 + 0x20 ]                        
                                                                      
        /*                                                            
         *  Did the watchdog timer expire while we were actually blocking
         *  on it?                                                    
         */                                                           
        _ISR_Disable( level );                                        
40008498:	7f ff eb 17 	call  400030f4 <sparc_disable_interrupts>      
4000849c:	01 00 00 00 	nop                                            
          local_state = the_period->state;                            
          the_period->state = RATE_MONOTONIC_ACTIVE;                  
400084a0:	82 10 20 02 	mov  2, %g1	! 2 <_TLS_Alignment+0x1>           
        /*                                                            
         *  Did the watchdog timer expire while we were actually blocking
         *  on it?                                                    
         */                                                           
        _ISR_Disable( level );                                        
          local_state = the_period->state;                            
400084a4:	f8 07 60 38 	ld  [ %i5 + 0x38 ], %i4                        
          the_period->state = RATE_MONOTONIC_ACTIVE;                  
400084a8:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
        _ISR_Enable( level );                                         
400084ac:	7f ff eb 15 	call  40003100 <sparc_enable_interrupts>       
400084b0:	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 )   
400084b4:	80 a7 20 03 	cmp  %i4, 3                                    
400084b8:	12 80 00 05 	bne  400084cc <rtems_rate_monotonic_period+0x15c>
400084bc:	01 00 00 00 	nop                                            
          _Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
400084c0:	d0 01 a0 18 	ld  [ %g6 + 0x18 ], %o0                        
400084c4:	40 00 0b b2 	call  4000b38c <_Thread_Clear_state>           
400084c8:	13 00 00 10 	sethi  %hi(0x4000), %o1                        
400084cc:	40 00 0c 5b 	call  4000b638 <_Thread_Enable_dispatch>       
400084d0:	b0 10 20 00 	clr  %i0                                       
                                                                      
        _Objects_Put( &the_period->Object );                          
        return RTEMS_SUCCESSFUL;                                      
400084d4:	81 c7 e0 08 	ret                                            
400084d8:	81 e8 00 00 	restore                                        
      }                                                               
                                                                      
      if ( the_period->state == RATE_MONOTONIC_EXPIRED ) {            
400084dc:	12 bf ff b6 	bne  400083b4 <rtems_rate_monotonic_period+0x44><== NEVER TAKEN
400084e0:	b0 10 20 04 	mov  4, %i0                                    
        /*                                                            
         *  Update statistics from the concluding period              
         */                                                           
        _Rate_monotonic_Update_statistics( the_period );              
400084e4:	7f ff ff 3f 	call  400081e0 <_Rate_monotonic_Update_statistics>
400084e8:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
        _ISR_Enable( level );                                         
400084ec:	7f ff eb 05 	call  40003100 <sparc_enable_interrupts>       
400084f0:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
        the_period->state = RATE_MONOTONIC_ACTIVE;                    
400084f4:	82 10 20 02 	mov  2, %g1                                    
400084f8:	92 07 60 10 	add  %i5, 0x10, %o1                            
400084fc:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
        the_period->next_length = length;                             
40008500:	f2 27 60 3c 	st  %i1, [ %i5 + 0x3c ]                        
  Watchdog_Control      *the_watchdog,                                
  Watchdog_Interval      units                                        
)                                                                     
{                                                                     
                                                                      
  the_watchdog->initial = units;                                      
40008504:	f2 27 60 1c 	st  %i1, [ %i5 + 0x1c ]                        
                                                                      
  _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );           
40008508:	11 10 00 69 	sethi  %hi(0x4001a400), %o0                    
4000850c:	40 00 10 dc 	call  4000c87c <_Watchdog_Insert>              
40008510:	90 12 20 10 	or  %o0, 0x10, %o0	! 4001a410 <_Watchdog_Ticks_chain>
40008514:	d2 07 60 40 	ld  [ %i5 + 0x40 ], %o1                        
40008518:	d4 07 60 3c 	ld  [ %i5 + 0x3c ], %o2                        
4000851c:	11 10 00 5c 	sethi  %hi(0x40017000), %o0                    
40008520:	90 12 21 34 	or  %o0, 0x134, %o0	! 40017134 <_Scheduler_Table>
40008524:	c2 02 20 2c 	ld  [ %o0 + 0x2c ], %g1                        
40008528:	9f c0 40 00 	call  %g1                                      
4000852c:	b0 10 20 06 	mov  6, %i0                                    
40008530:	40 00 0c 42 	call  4000b638 <_Thread_Enable_dispatch>       
40008534:	01 00 00 00 	nop                                            
          _Scheduler_Get( the_period->owner ),                        
          the_period->owner,                                          
          the_period->next_length                                     
        );                                                            
        _Objects_Put( &the_period->Object );                          
        return RTEMS_TIMEOUT;                                         
40008538:	81 c7 e0 08 	ret                                            
4000853c:	81 e8 00 00 	restore                                        
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return RTEMS_INVALID_ID;                                            
40008540:	b0 10 20 04 	mov  4, %i0                                    
}                                                                     
40008544:	81 c7 e0 08 	ret                                            
40008548:	81 e8 00 00 	restore                                        
                                                                      

4000854c <rtems_rate_monotonic_report_statistics_with_plugin>: void rtems_rate_monotonic_report_statistics_with_plugin( void *context, rtems_printk_plugin_t print ) {
4000854c:	9d e3 bf 38 	save  %sp, -200, %sp                           
  rtems_id                               id;                          
  rtems_rate_monotonic_period_statistics the_stats;                   
  rtems_rate_monotonic_period_status     the_status;                  
  char                                   name[5];                     
                                                                      
  if ( !print )                                                       
40008550:	80 a6 60 00 	cmp  %i1, 0                                    
40008554:	02 80 00 76 	be  4000872c <rtems_rate_monotonic_report_statistics_with_plugin+0x1e0><== NEVER TAKEN
40008558:	90 10 00 18 	mov  %i0, %o0                                  
    return;                                                           
                                                                      
  (*print)( context, "Period information by period\n" );              
4000855c:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
40008560:	9f c6 40 00 	call  %i1                                      
40008564:	92 12 62 18 	or  %o1, 0x218, %o1	! 40017a18 <rtems_filesystem_null_handlers+0x58>
  #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                          
    (*print)( context, "--- CPU times are in seconds ---\n" );        
40008568:	90 10 00 18 	mov  %i0, %o0                                  
4000856c:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
40008570:	9f c6 40 00 	call  %i1                                      
40008574:	92 12 62 38 	or  %o1, 0x238, %o1	! 40017a38 <rtems_filesystem_null_handlers+0x78>
    (*print)( context, "--- Wall times are in seconds ---\n" );       
40008578:	90 10 00 18 	mov  %i0, %o0                                  
4000857c:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
40008580:	9f c6 40 00 	call  %i1                                      
40008584:	92 12 62 60 	or  %o1, 0x260, %o1	! 40017a60 <rtems_filesystem_null_handlers+0xa0>
  Be sure to test the various cases.                                  
  (*print)( context,"\                                                
1234567890123456789012345678901234567890123456789012345678901234567890123456789\
\n");                                                                 
*/                                                                    
  (*print)( context, "   ID     OWNER COUNT MISSED     "              
40008588:	90 10 00 18 	mov  %i0, %o0                                  
4000858c:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
40008590:	9f c6 40 00 	call  %i1                                      
40008594:	92 12 62 88 	or  %o1, 0x288, %o1	! 40017a88 <rtems_filesystem_null_handlers+0xc8>
       #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__                     
          "          "                                                
       #endif                                                         
          "   WALL TIME\n"                                            
  );                                                                  
  (*print)( context, "                               "                
40008598:	90 10 00 18 	mov  %i0, %o0                                  
4000859c:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
400085a0:	9f c6 40 00 	call  %i1                                      
400085a4:	92 12 62 d8 	or  %o1, 0x2d8, %o1	! 40017ad8 <rtems_filesystem_null_handlers+0x118>
                                                                      
  /*                                                                  
   * 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 ;                   
400085a8:	03 10 00 68 	sethi  %hi(0x4001a000), %g1                    
400085ac:	82 10 62 a0 	or  %g1, 0x2a0, %g1	! 4001a2a0 <_Rate_monotonic_Information>
400085b0:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
    rtems_object_get_name( the_status.owner, sizeof(name), name );    
                                                                      
    /*                                                                
     *  Print part of report line that is not dependent on granularity
     */                                                               
    (*print)( context,                                                
400085b4:	37 10 00 5e 	sethi  %hi(0x40017800), %i3                    
      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,                                              
400085b8:	35 10 00 5e 	sethi  %hi(0x40017800), %i2                    
      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,                                              
400085bc:	21 10 00 5e 	sethi  %hi(0x40017800), %l0                    
                                                                      
    /*                                                                
     *  If the count is zero, don't print statistics                  
     */                                                               
    if (the_stats.count == 0) {                                       
      (*print)( context, "\n" );                                      
400085c0:	23 10 00 5b 	sethi  %hi(0x40016c00), %l1                    
400085c4:	b8 10 00 01 	mov  %g1, %i4                                  
    rtems_object_get_name( the_status.owner, sizeof(name), name );    
                                                                      
    /*                                                                
     *  Print part of report line that is not dependent on granularity
     */                                                               
    (*print)( context,                                                
400085c8:	b6 16 e3 28 	or  %i3, 0x328, %i3                            
      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,                                              
400085cc:	b4 16 a3 40 	or  %i2, 0x340, %i2                            
      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,                                              
400085d0:	a0 14 23 60 	or  %l0, 0x360, %l0                            
                                                                      
    /*                                                                
     *  If the count is zero, don't print statistics                  
     */                                                               
    if (the_stats.count == 0) {                                       
      (*print)( context, "\n" );                                      
400085d4:	a2 14 63 d8 	or  %l1, 0x3d8, %l1                            
                                                                      
  /*                                                                  
   * 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 ;                   
400085d8:	c2 07 20 0c 	ld  [ %i4 + 0xc ], %g1                         
400085dc:	80 a7 40 01 	cmp  %i5, %g1                                  
400085e0:	18 80 00 53 	bgu  4000872c <rtems_rate_monotonic_report_statistics_with_plugin+0x1e0>
400085e4:	90 10 00 1d 	mov  %i5, %o0                                  
        id <= _Rate_monotonic_Information.maximum_id ;                
        id++ ) {                                                      
    status = rtems_rate_monotonic_get_statistics( id, &the_stats );   
400085e8:	40 00 18 d5 	call  4000e93c <rtems_rate_monotonic_get_statistics>
400085ec:	92 07 bf c8 	add  %fp, -56, %o1                             
    if ( status != RTEMS_SUCCESSFUL )                                 
400085f0:	80 a2 20 00 	cmp  %o0, 0                                    
400085f4:	32 bf ff f9 	bne,a   400085d8 <rtems_rate_monotonic_report_statistics_with_plugin+0x8c>
400085f8:	ba 07 60 01 	inc  %i5                                       
    #if defined(RTEMS_DEBUG)                                          
      status = rtems_rate_monotonic_get_status( id, &the_status );    
      if ( status != RTEMS_SUCCESSFUL )                               
        continue;                                                     
    #else                                                             
      (void) rtems_rate_monotonic_get_status( id, &the_status );      
400085fc:	92 07 bf b0 	add  %fp, -80, %o1                             
40008600:	40 00 19 40 	call  4000eb00 <rtems_rate_monotonic_get_status>
40008604:	90 10 00 1d 	mov  %i5, %o0                                  
    #endif                                                            
                                                                      
    rtems_object_get_name( the_status.owner, sizeof(name), name );    
40008608:	d0 07 bf b0 	ld  [ %fp + -80 ], %o0                         
4000860c:	92 10 20 05 	mov  5, %o1                                    
40008610:	40 00 00 a8 	call  400088b0 <rtems_object_get_name>         
40008614:	94 07 bf a0 	add  %fp, -96, %o2                             
                                                                      
    /*                                                                
     *  Print part of report line that is not dependent on granularity
     */                                                               
    (*print)( context,                                                
40008618:	d8 1f bf c8 	ldd  [ %fp + -56 ], %o4                        
4000861c:	92 10 00 1b 	mov  %i3, %o1                                  
40008620:	90 10 00 18 	mov  %i0, %o0                                  
40008624:	94 10 00 1d 	mov  %i5, %o2                                  
40008628:	9f c6 40 00 	call  %i1                                      
4000862c:	96 07 bf a0 	add  %fp, -96, %o3                             
    );                                                                
                                                                      
    /*                                                                
     *  If the count is zero, don't print statistics                  
     */                                                               
    if (the_stats.count == 0) {                                       
40008630:	d2 07 bf c8 	ld  [ %fp + -56 ], %o1                         
40008634:	80 a2 60 00 	cmp  %o1, 0                                    
40008638:	12 80 00 07 	bne  40008654 <rtems_rate_monotonic_report_statistics_with_plugin+0x108>
4000863c:	94 07 bf a8 	add  %fp, -88, %o2                             
      (*print)( context, "\n" );                                      
40008640:	90 10 00 18 	mov  %i0, %o0                                  
40008644:	9f c6 40 00 	call  %i1                                      
40008648:	92 10 00 11 	mov  %l1, %o1                                  
      continue;                                                       
4000864c:	10 bf ff e3 	b  400085d8 <rtems_rate_monotonic_report_statistics_with_plugin+0x8c>
40008650:	ba 07 60 01 	inc  %i5                                       
      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 );
40008654:	40 00 0f b1 	call  4000c518 <_Timespec_Divide_by_integer>   
40008658:	90 07 bf e0 	add  %fp, -32, %o0                             
      (*print)( context,                                              
4000865c:	d0 07 bf d4 	ld  [ %fp + -44 ], %o0                         
40008660:	40 00 32 36 	call  40014f38 <.div>                          
40008664:	92 10 23 e8 	mov  0x3e8, %o1                                
40008668:	a8 10 00 08 	mov  %o0, %l4                                  
4000866c:	d0 07 bf dc 	ld  [ %fp + -36 ], %o0                         
40008670:	40 00 32 32 	call  40014f38 <.div>                          
40008674:	92 10 23 e8 	mov  0x3e8, %o1                                
40008678:	c2 07 bf a8 	ld  [ %fp + -88 ], %g1                         
4000867c:	a4 10 00 08 	mov  %o0, %l2                                  
40008680:	d0 07 bf ac 	ld  [ %fp + -84 ], %o0                         
40008684:	ea 07 bf d0 	ld  [ %fp + -48 ], %l5                         
40008688:	e6 07 bf d8 	ld  [ %fp + -40 ], %l3                         
4000868c:	c2 23 a0 5c 	st  %g1, [ %sp + 0x5c ]                        
40008690:	40 00 32 2a 	call  40014f38 <.div>                          
40008694:	92 10 23 e8 	mov  0x3e8, %o1                                
40008698:	96 10 00 14 	mov  %l4, %o3                                  
4000869c:	98 10 00 13 	mov  %l3, %o4                                  
400086a0:	9a 10 00 12 	mov  %l2, %o5                                  
400086a4:	94 10 00 15 	mov  %l5, %o2                                  
400086a8:	d0 23 a0 60 	st  %o0, [ %sp + 0x60 ]                        
400086ac:	92 10 00 1a 	mov  %i2, %o1                                  
400086b0:	9f c6 40 00 	call  %i1                                      
400086b4:	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);
400086b8:	d2 07 bf c8 	ld  [ %fp + -56 ], %o1                         
400086bc:	94 07 bf a8 	add  %fp, -88, %o2                             
400086c0:	40 00 0f 96 	call  4000c518 <_Timespec_Divide_by_integer>   
400086c4:	90 07 bf f8 	add  %fp, -8, %o0                              
      (*print)( context,                                              
400086c8:	d0 07 bf ec 	ld  [ %fp + -20 ], %o0                         
400086cc:	40 00 32 1b 	call  40014f38 <.div>                          
400086d0:	92 10 23 e8 	mov  0x3e8, %o1                                
400086d4:	a8 10 00 08 	mov  %o0, %l4                                  
400086d8:	d0 07 bf f4 	ld  [ %fp + -12 ], %o0                         
400086dc:	40 00 32 17 	call  40014f38 <.div>                          
400086e0:	92 10 23 e8 	mov  0x3e8, %o1                                
400086e4:	c2 07 bf a8 	ld  [ %fp + -88 ], %g1                         
400086e8:	a4 10 00 08 	mov  %o0, %l2                                  
400086ec:	d0 07 bf ac 	ld  [ %fp + -84 ], %o0                         
400086f0:	ea 07 bf e8 	ld  [ %fp + -24 ], %l5                         
400086f4:	e6 07 bf f0 	ld  [ %fp + -16 ], %l3                         
400086f8:	92 10 23 e8 	mov  0x3e8, %o1                                
400086fc:	40 00 32 0f 	call  40014f38 <.div>                          
40008700:	c2 23 a0 5c 	st  %g1, [ %sp + 0x5c ]                        
40008704:	92 10 00 10 	mov  %l0, %o1                                  
40008708:	d0 23 a0 60 	st  %o0, [ %sp + 0x60 ]                        
4000870c:	94 10 00 15 	mov  %l5, %o2                                  
40008710:	90 10 00 18 	mov  %i0, %o0                                  
40008714:	96 10 00 14 	mov  %l4, %o3                                  
40008718:	98 10 00 13 	mov  %l3, %o4                                  
4000871c:	9f c6 40 00 	call  %i1                                      
40008720:	9a 10 00 12 	mov  %l2, %o5                                  
   * 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++ ) {                                                      
40008724:	10 bf ff ad 	b  400085d8 <rtems_rate_monotonic_report_statistics_with_plugin+0x8c>
40008728:	ba 07 60 01 	inc  %i5                                       
4000872c:	81 c7 e0 08 	ret                                            
40008730:	81 e8 00 00 	restore                                        
                                                                      

40008874 <rtems_rbheap_allocate>: return big_enough; } void *rtems_rbheap_allocate(rtems_rbheap_control *control, size_t size) {
40008874:	9d e3 bf a0 	save  %sp, -96, %sp                            
  void *ptr = NULL;                                                   
  rtems_chain_control *free_chain = &control->free_chunk_chain;       
  rtems_rbtree_control *chunk_tree = &control->chunk_tree;            
  uintptr_t alignment = control->alignment;                           
40008878:	fa 06 20 30 	ld  [ %i0 + 0x30 ], %i5                        
                                                                      
#include <stdlib.h>                                                   
                                                                      
static uintptr_t align_up(uintptr_t alignment, uintptr_t value)       
{                                                                     
  uintptr_t excess = value % alignment;                               
4000887c:	90 10 00 19 	mov  %i1, %o0                                  
40008880:	92 10 00 1d 	mov  %i5, %o1                                  
40008884:	40 00 2f 9b 	call  400146f0 <.urem>                         
40008888:	b6 10 00 19 	mov  %i1, %i3                                  
                                                                      
  if (excess > 0) {                                                   
4000888c:	80 a2 20 00 	cmp  %o0, 0                                    
40008890:	02 80 00 05 	be  400088a4 <rtems_rbheap_allocate+0x30>      
40008894:	80 a6 c0 19 	cmp  %i3, %i1                                  
    value += alignment - excess;                                      
40008898:	b6 06 40 1d 	add  %i1, %i5, %i3                             
4000889c:	b6 26 c0 08 	sub  %i3, %o0, %i3                             
  rtems_chain_control *free_chain = &control->free_chunk_chain;       
  rtems_rbtree_control *chunk_tree = &control->chunk_tree;            
  uintptr_t alignment = control->alignment;                           
  uintptr_t aligned_size = align_up(alignment, size);                 
                                                                      
  if (size > 0 && size <= aligned_size) {                             
400088a0:	80 a6 c0 19 	cmp  %i3, %i1                                  
400088a4:	0a 80 00 04 	bcs  400088b4 <rtems_rbheap_allocate+0x40>     <== NEVER TAKEN
400088a8:	80 a6 60 00 	cmp  %i1, 0                                    
400088ac:	32 80 00 04 	bne,a   400088bc <rtems_rbheap_allocate+0x48>  
400088b0:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  return big_enough;                                                  
}                                                                     
                                                                      
void *rtems_rbheap_allocate(rtems_rbheap_control *control, size_t size)
{                                                                     
  void *ptr = NULL;                                                   
400088b4:	81 c7 e0 08 	ret                                            
400088b8:	91 e8 20 00 	restore  %g0, 0, %o0                           
  rtems_chain_control *free_chain,                                    
  size_t size                                                         
)                                                                     
{                                                                     
  rtems_chain_node *current = rtems_chain_first(free_chain);          
  const rtems_chain_node *tail = rtems_chain_tail(free_chain);        
400088bc:	84 06 20 04 	add  %i0, 4, %g2                               
  rtems_rbheap_chunk *big_enough = NULL;                              
400088c0:	ba 10 20 00 	clr  %i5                                       
                                                                      
  while (current != tail && big_enough == NULL) {                     
400088c4:	80 a7 60 00 	cmp  %i5, 0                                    
400088c8:	12 80 00 0a 	bne  400088f0 <rtems_rbheap_allocate+0x7c>     
400088cc:	80 a0 40 02 	cmp  %g1, %g2                                  
400088d0:	02 80 00 09 	be  400088f4 <rtems_rbheap_allocate+0x80>      
400088d4:	80 a7 60 00 	cmp  %i5, 0                                    
    rtems_rbheap_chunk *free_chunk = (rtems_rbheap_chunk *) current;  
                                                                      
    if (free_chunk->size >= size) {                                   
400088d8:	c6 00 60 1c 	ld  [ %g1 + 0x1c ], %g3                        
400088dc:	80 a0 c0 1b 	cmp  %g3, %i3                                  
400088e0:	ba 40 3f ff 	addx  %g0, -1, %i5                             
400088e4:	ba 08 40 1d 	and  %g1, %i5, %i5                             
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
400088e8:	10 bf ff f7 	b  400088c4 <rtems_rbheap_allocate+0x50>       
400088ec:	c2 00 40 00 	ld  [ %g1 ], %g1                               
  uintptr_t aligned_size = align_up(alignment, size);                 
                                                                      
  if (size > 0 && size <= aligned_size) {                             
    rtems_rbheap_chunk *free_chunk = search_free_chunk(free_chain, aligned_size);
                                                                      
    if (free_chunk != NULL) {                                         
400088f0:	80 a7 60 00 	cmp  %i5, 0                                    
400088f4:	02 bf ff f0 	be  400088b4 <rtems_rbheap_allocate+0x40>      
400088f8:	01 00 00 00 	nop                                            
      uintptr_t free_size = free_chunk->size;                         
400088fc:	f4 07 60 1c 	ld  [ %i5 + 0x1c ], %i2                        
                                                                      
      if (free_size > aligned_size) {                                 
40008900:	80 a6 80 1b 	cmp  %i2, %i3                                  
40008904:	28 80 00 13 	bleu,a   40008950 <rtems_rbheap_allocate+0xdc> 
40008908:	c4 07 40 00 	ld  [ %i5 ], %g2                               
        rtems_rbheap_chunk *new_chunk = get_chunk(control);           
4000890c:	7f ff ff 5c 	call  4000867c <get_chunk>                     
40008910:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
        if (new_chunk != NULL) {                                      
40008914:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40008918:	02 bf ff e7 	be  400088b4 <rtems_rbheap_allocate+0x40>      
4000891c:	b4 26 80 1b 	sub  %i2, %i3, %i2                             
          uintptr_t new_free_size = free_size - aligned_size;         
                                                                      
          free_chunk->size = new_free_size;                           
          new_chunk->begin = free_chunk->begin + new_free_size;       
40008920:	c2 07 60 18 	ld  [ %i5 + 0x18 ], %g1                        
        rtems_rbheap_chunk *new_chunk = get_chunk(control);           
                                                                      
        if (new_chunk != NULL) {                                      
          uintptr_t new_free_size = free_size - aligned_size;         
                                                                      
          free_chunk->size = new_free_size;                           
40008924:	f4 27 60 1c 	st  %i2, [ %i5 + 0x1c ]                        
          new_chunk->begin = free_chunk->begin + new_free_size;       
          new_chunk->size = aligned_size;                             
40008928:	f6 27 20 1c 	st  %i3, [ %i4 + 0x1c ]                        
                                                                      
        if (new_chunk != NULL) {                                      
          uintptr_t new_free_size = free_size - aligned_size;         
                                                                      
          free_chunk->size = new_free_size;                           
          new_chunk->begin = free_chunk->begin + new_free_size;       
4000892c:	b4 06 80 01 	add  %i2, %g1, %i2                             
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
40008930:	c0 27 00 00 	clr  [ %i4 ]                                   
40008934:	f4 27 20 18 	st  %i2, [ %i4 + 0x18 ]                        
static void insert_into_tree(                                         
  rtems_rbtree_control *tree,                                         
  rtems_rbheap_chunk *chunk                                           
)                                                                     
{                                                                     
  _RBTree_Insert(tree, &chunk->tree_node);                            
40008938:	90 06 20 18 	add  %i0, 0x18, %o0                            
4000893c:	40 00 06 ed 	call  4000a4f0 <_RBTree_Insert>                
40008940:	92 07 20 08 	add  %i4, 8, %o1                               
          free_chunk->size = new_free_size;                           
          new_chunk->begin = free_chunk->begin + new_free_size;       
          new_chunk->size = aligned_size;                             
          rtems_chain_set_off_chain(&new_chunk->chain_node);          
          insert_into_tree(chunk_tree, new_chunk);                    
          ptr = (void *) new_chunk->begin;                            
40008944:	f0 07 20 18 	ld  [ %i4 + 0x18 ], %i0                        
40008948:	81 c7 e0 08 	ret                                            
4000894c:	81 e8 00 00 	restore                                        
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
40008950:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
        }                                                             
      } else {                                                        
        rtems_chain_extract_unprotected(&free_chunk->chain_node);     
        rtems_chain_set_off_chain(&free_chunk->chain_node);           
        ptr = (void *) free_chunk->begin;                             
40008954:	f0 07 60 18 	ld  [ %i5 + 0x18 ], %i0                        
  next->previous = previous;                                          
40008958:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4000895c:	c4 20 40 00 	st  %g2, [ %g1 ]                               
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
40008960:	c0 27 40 00 	clr  [ %i5 ]                                   
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  return ptr;                                                         
}                                                                     
40008964:	81 c7 e0 08 	ret                                            
40008968:	81 e8 00 00 	restore                                        
                                                                      

400197dc <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) {
400197dc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc;                                                             
                                                                      
  if (!control->buffer)                                               
400197e0:	c2 06 00 00 	ld  [ %i0 ], %g1                               
 * @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)             
{                                                                     
400197e4:	ba 10 00 18 	mov  %i0, %i5                                  
  int rc;                                                             
                                                                      
  if (!control->buffer)                                               
400197e8:	80 a0 60 00 	cmp  %g1, 0                                    
400197ec:	02 80 00 0f 	be  40019828 <rtems_rfs_bitmap_load_map+0x4c>  
400197f0:	b0 10 20 06 	mov  6, %i0                                    
    return ENXIO;                                                     
                                                                      
  *map = NULL;                                                        
400197f4:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
  rc = rtems_rfs_buffer_handle_request (control->fs,                  
400197f8:	d4 07 60 08 	ld  [ %i5 + 8 ], %o2                           
400197fc:	d0 07 60 04 	ld  [ %i5 + 4 ], %o0                           
40019800:	d2 07 40 00 	ld  [ %i5 ], %o1                               
40019804:	40 00 06 96 	call  4001b25c <rtems_rfs_buffer_handle_request>
40019808:	96 10 20 01 	mov  1, %o3                                    
                                        control->buffer,              
                                        control->block,               
                                        true);                        
  if (rc)                                                             
4001980c:	80 a2 20 00 	cmp  %o0, 0                                    
40019810:	12 80 00 06 	bne  40019828 <rtems_rfs_bitmap_load_map+0x4c> <== NEVER TAKEN
40019814:	b0 10 00 08 	mov  %o0, %i0                                  
    return rc;                                                        
                                                                      
  *map = rtems_rfs_buffer_data (control->buffer);                     
40019818:	c2 07 40 00 	ld  [ %i5 ], %g1                               
4001981c:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
40019820:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
40019824:	c2 26 40 00 	st  %g1, [ %i1 ]                               
  return 0;                                                           
}                                                                     
40019828:	81 c7 e0 08 	ret                                            
4001982c:	81 e8 00 00 	restore                                        
                                                                      

40019ca4 <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) {
40019ca4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int                  rc = 0;                                        
                                                                      
  /*                                                                  
   * By default we assume the allocation failed.                      
   */                                                                 
  *allocated = false;                                                 
40019ca8:	c0 2e 80 00 	clrb  [ %i2 ]                                  
   * seed up then from the seed down a window number of bits, then repeat the
   * process from the window distance from the seed, again above then 
   * below. Keep moving out until all bits have been searched.        
   */                                                                 
  upper_seed = seed;                                                  
  lower_seed = seed;                                                  
40019cac:	ba 10 00 19 	mov  %i1, %i5                                  
   * 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))          
40019cb0:	80 a6 60 00 	cmp  %i1, 0                                    
40019cb4:	06 80 00 32 	bl  40019d7c <rtems_rfs_bitmap_map_alloc+0xd8> 
40019cb8:	80 a7 60 00 	cmp  %i5, 0                                    
40019cbc:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
40019cc0:	80 a6 40 01 	cmp  %i1, %g1                                  
40019cc4:	1a 80 00 2e 	bcc  40019d7c <rtems_rfs_bitmap_map_alloc+0xd8>
40019cc8:	80 a7 60 00 	cmp  %i5, 0                                    
         || ((lower_seed >= 0) && (lower_seed < control->size)))      
  {                                                                   
    /*                                                                
     * Search up first so bits allocated in succession are grouped together.
     */                                                               
    if (upper_seed < control->size)                                   
40019ccc:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
40019cd0:	80 a6 40 01 	cmp  %i1, %g1                                  
40019cd4:	2a 80 00 07 	bcs,a   40019cf0 <rtems_rfs_bitmap_map_alloc+0x4c>
40019cd8:	f2 26 c0 00 	st  %i1, [ %i3 ]                               
                                               window, 1);            
      if ((rc > 0) || *allocated)                                     
        break;                                                        
    }                                                                 
                                                                      
    if (lower_seed >= 0)                                              
40019cdc:	80 a7 60 00 	cmp  %i5, 0                                    
40019ce0:	36 80 00 12 	bge,a   40019d28 <rtems_rfs_bitmap_map_alloc+0x84>
40019ce4:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
                                                                      
    /*                                                                
     * 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)                                   
40019ce8:	10 80 00 1d 	b  40019d5c <rtems_rfs_bitmap_map_alloc+0xb8>  
40019cec:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
     * Search up first so bits allocated in succession are grouped together.
     */                                                               
    if (upper_seed < control->size)                                   
    {                                                                 
      *bit = upper_seed;                                              
      rc = rtems_rfs_search_map_for_clear_bit (control, bit, allocated,
40019cf0:	90 10 00 18 	mov  %i0, %o0                                  
40019cf4:	92 10 00 1b 	mov  %i3, %o1                                  
40019cf8:	94 10 00 1a 	mov  %i2, %o2                                  
40019cfc:	7f ff fe cd 	call  40019830 <rtems_rfs_search_map_for_clear_bit.constprop.1>
40019d00:	96 10 20 01 	mov  1, %o3                                    
                                               window, 1);            
      if ((rc > 0) || *allocated)                                     
40019d04:	80 a2 20 00 	cmp  %o0, 0                                    
40019d08:	34 80 00 24 	bg,a   40019d98 <rtems_rfs_bitmap_map_alloc+0xf4><== NEVER TAKEN
40019d0c:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
40019d10:	c2 0e 80 00 	ldub  [ %i2 ], %g1                             
40019d14:	80 a0 60 00 	cmp  %g1, 0                                    
40019d18:	02 bf ff f2 	be  40019ce0 <rtems_rfs_bitmap_map_alloc+0x3c> 
40019d1c:	80 a7 60 00 	cmp  %i5, 0                                    
    if (lower_seed >= 0)                                              
      lower_seed -= window;                                           
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40019d20:	81 c7 e0 08 	ret                                            
40019d24:	91 e8 20 00 	restore  %g0, 0, %o0                           
    }                                                                 
                                                                      
    if (lower_seed >= 0)                                              
    {                                                                 
      *bit = lower_seed;                                              
      rc = rtems_rfs_search_map_for_clear_bit (control, bit, allocated,
40019d28:	90 10 00 18 	mov  %i0, %o0                                  
40019d2c:	92 10 00 1b 	mov  %i3, %o1                                  
40019d30:	94 10 00 1a 	mov  %i2, %o2                                  
40019d34:	7f ff fe bf 	call  40019830 <rtems_rfs_search_map_for_clear_bit.constprop.1>
40019d38:	96 10 3f ff 	mov  -1, %o3                                   
                                               window, -1);           
      if ((rc > 0) || *allocated)                                     
40019d3c:	80 a2 20 00 	cmp  %o0, 0                                    
40019d40:	34 80 00 16 	bg,a   40019d98 <rtems_rfs_bitmap_map_alloc+0xf4><== NEVER TAKEN
40019d44:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
40019d48:	c2 0e 80 00 	ldub  [ %i2 ], %g1                             
40019d4c:	80 a0 60 00 	cmp  %g1, 0                                    
40019d50:	32 80 00 12 	bne,a   40019d98 <rtems_rfs_bitmap_map_alloc+0xf4>
40019d54:	b0 10 20 00 	clr  %i0                                       
                                                                      
    /*                                                                
     * 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)                                   
40019d58:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
40019d5c:	80 a6 40 01 	cmp  %i1, %g1                                  
40019d60:	2a 80 00 02 	bcs,a   40019d68 <rtems_rfs_bitmap_map_alloc+0xc4>
40019d64:	b2 06 68 00 	add  %i1, 0x800, %i1                           
      upper_seed += window;                                           
    if (lower_seed >= 0)                                              
40019d68:	80 a7 60 00 	cmp  %i5, 0                                    
40019d6c:	36 bf ff d1 	bge,a   40019cb0 <rtems_rfs_bitmap_map_alloc+0xc>
40019d70:	ba 07 78 00 	add  %i5, -2048, %i5                           
   * 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))          
40019d74:	10 bf ff d0 	b  40019cb4 <rtems_rfs_bitmap_map_alloc+0x10>  
40019d78:	80 a6 60 00 	cmp  %i1, 0                                    
         || ((lower_seed >= 0) && (lower_seed < control->size)))      
40019d7c:	26 80 00 07 	bl,a   40019d98 <rtems_rfs_bitmap_map_alloc+0xf4>
40019d80:	b0 10 20 00 	clr  %i0                                       
40019d84:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
40019d88:	80 a7 40 01 	cmp  %i5, %g1                                  
40019d8c:	0a bf ff d2 	bcs  40019cd4 <rtems_rfs_bitmap_map_alloc+0x30>
40019d90:	80 a6 40 01 	cmp  %i1, %g1                                  
    if (lower_seed >= 0)                                              
      lower_seed -= window;                                           
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40019d94:	b0 10 20 00 	clr  %i0                                       
40019d98:	81 c7 e0 08 	ret                                            
40019d9c:	81 e8 00 00 	restore                                        
                                                                      

40019aa8 <rtems_rfs_bitmap_mask_section>: return mask; } rtems_rfs_bitmap_element rtems_rfs_bitmap_mask_section (unsigned int start, unsigned int end) {
40019aa8:	82 10 00 08 	mov  %o0, %g1                                  
  rtems_rfs_bitmap_element mask = 0;                                  
  if (end > start)                                                    
40019aac:	80 a2 40 01 	cmp  %o1, %g1                                  
40019ab0:	08 80 00 06 	bleu  40019ac8 <rtems_rfs_bitmap_mask_section+0x20><== NEVER TAKEN
40019ab4:	90 10 20 00 	clr  %o0                                       
                                                                      
rtems_rfs_bitmap_element                                              
rtems_rfs_bitmap_mask (unsigned int size)                             
{                                                                     
  rtems_rfs_bitmap_element mask = RTEMS_RFS_BITMAP_ELEMENT_FULL_MASK; 
  mask >>= (rtems_rfs_bitmap_element_bits () - size);                 
40019ab8:	92 20 40 09 	sub  %g1, %o1, %o1                             
40019abc:	90 10 3f ff 	mov  -1, %o0                                   
40019ac0:	91 32 00 09 	srl  %o0, %o1, %o0                             
rtems_rfs_bitmap_element                                              
rtems_rfs_bitmap_mask_section (unsigned int start, unsigned int end)  
{                                                                     
  rtems_rfs_bitmap_element mask = 0;                                  
  if (end > start)                                                    
    mask = rtems_rfs_bitmap_mask (end - start) << start;              
40019ac4:	91 2a 00 01 	sll  %o0, %g1, %o0                             
  return mask;                                                        
}                                                                     
40019ac8:	81 c3 e0 08 	retl                                           
                                                                      

4001a020 <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) {
4001a020:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
  /*                                                                  
   * 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);     
4001a024:	96 10 20 01 	mov  1, %o3                                    
4001a028:	90 10 00 18 	mov  %i0, %o0                                  
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)       
{                                                                     
4001a02c:	ba 10 00 18 	mov  %i0, %i5                                  
                                                                      
  /*                                                                  
   * 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);     
4001a030:	92 10 00 19 	mov  %i1, %o1                                  
4001a034:	40 00 04 8a 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001a038:	94 10 00 1a 	mov  %i2, %o2                                  
  if (rc > 0)                                                         
4001a03c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001a040:	14 80 00 26 	bg  4001a0d8 <rtems_rfs_block_find_indirect+0xb8><== NEVER TAKEN
4001a044:	87 2e e0 02 	sll  %i3, 2, %g3                               
    return rc;                                                        
                                                                      
  *result = rtems_rfs_block_get_number (buffer, offset);              
4001a048:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001a04c:	c8 00 60 1c 	ld  [ %g1 + 0x1c ], %g4                        
4001a050:	82 01 00 03 	add  %g4, %g3, %g1                             
4001a054:	c4 09 00 03 	ldub  [ %g4 + %g3 ], %g2                       
4001a058:	f2 08 60 03 	ldub  [ %g1 + 3 ], %i1                         
4001a05c:	c6 08 60 01 	ldub  [ %g1 + 1 ], %g3                         
4001a060:	c2 08 60 02 	ldub  [ %g1 + 2 ], %g1                         
4001a064:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001a068:	83 28 60 08 	sll  %g1, 8, %g1                               
4001a06c:	84 16 40 02 	or  %i1, %g2, %g2                              
4001a070:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
4001a074:	84 10 80 03 	or  %g2, %g3, %g2                              
4001a078:	84 10 80 01 	or  %g2, %g1, %g2                              
  if ((*result + 1) == 0)                                             
4001a07c:	80 a0 bf ff 	cmp  %g2, -1                                   
4001a080:	02 80 00 03 	be  4001a08c <rtems_rfs_block_find_indirect+0x6c><== NEVER TAKEN
4001a084:	82 10 20 00 	clr  %g1                                       
4001a088:	82 10 00 02 	mov  %g2, %g1                                  
    *result = 0;                                                      
                                                                      
  if (*result >= rtems_rfs_fs_blocks (fs))                            
4001a08c:	c4 07 60 04 	ld  [ %i5 + 4 ], %g2                           
4001a090:	c2 27 00 00 	st  %g1, [ %i4 ]                               
4001a094:	80 a0 40 02 	cmp  %g1, %g2                                  
4001a098:	0a 80 00 10 	bcs  4001a0d8 <rtems_rfs_block_find_indirect+0xb8><== ALWAYS TAKEN
4001a09c:	b0 10 20 00 	clr  %i0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_FIND))                 
4001a0a0:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001a0a4:	7f ff e5 6a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001a0a8:	13 00 00 04 	sethi  %hi(0x1000), %o1                        <== NOT EXECUTED
4001a0ac:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001a0b0:	22 80 00 09 	be,a   4001a0d4 <rtems_rfs_block_find_indirect+0xb4><== NOT EXECUTED
4001a0b4:	c0 27 00 00 	clr  [ %i4 ]                                   <== NOT EXECUTED
      printf ("rtems-rfs: block-find: invalid block in table:"        
4001a0b8:	d2 07 00 00 	ld  [ %i4 ], %o1                               <== NOT EXECUTED
4001a0bc:	11 10 00 d1 	sethi  %hi(0x40034400), %o0                    <== NOT EXECUTED
4001a0c0:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
4001a0c4:	90 12 23 90 	or  %o0, 0x390, %o0                            <== NOT EXECUTED
4001a0c8:	40 00 20 70 	call  40022288 <printf>                        <== NOT EXECUTED
4001a0cc:	96 10 00 1b 	mov  %i3, %o3                                  <== NOT EXECUTED
              " block=%" PRId32 ", indirect=%" PRId32 "/%d\n", *result, block, offset);
    *result = 0;                                                      
4001a0d0:	c0 27 00 00 	clr  [ %i4 ]                                   <== NOT EXECUTED
4001a0d4:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
    rc = EIO;                                                         
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
4001a0d8:	81 c7 e0 08 	ret                                            
4001a0dc:	81 e8 00 00 	restore                                        
                                                                      

4001a3ec <rtems_rfs_block_map_close>: int rtems_rfs_block_map_close (rtems_rfs_file_system* fs, rtems_rfs_block_map* map) {
4001a3ec:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc = 0;                                                         
  int brc;                                                            
                                                                      
  if (map->dirty && map->inode)                                       
4001a3f0:	c2 0e 40 00 	ldub  [ %i1 ], %g1                             
4001a3f4:	80 a0 60 00 	cmp  %g1, 0                                    
4001a3f8:	02 80 00 61 	be  4001a57c <rtems_rfs_block_map_close+0x190> 
4001a3fc:	ba 10 20 00 	clr  %i5                                       
4001a400:	d2 06 60 04 	ld  [ %i1 + 4 ], %o1                           
4001a404:	80 a2 60 00 	cmp  %o1, 0                                    
4001a408:	22 80 00 5e 	be,a   4001a580 <rtems_rfs_block_map_close+0x194><== NEVER TAKEN
4001a40c:	92 06 60 38 	add  %i1, 0x38, %o1                            <== NOT EXECUTED
  {                                                                   
    brc = rtems_rfs_inode_load (fs, map->inode);                      
4001a410:	7f ff de 06 	call  40011c28 <rtems_rfs_inode_load>          
4001a414:	90 10 00 18 	mov  %i0, %o0                                  
    if (brc > 0)                                                      
4001a418:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001a41c:	14 80 00 59 	bg  4001a580 <rtems_rfs_block_map_close+0x194> <== NEVER TAKEN
4001a420:	92 06 60 38 	add  %i1, 0x38, %o1                            
4001a424:	82 10 20 00 	clr  %g1                                       
 */                                                                   
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);                      
4001a428:	ba 10 20 01 	mov  1, %i5                                    
    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]);    
4001a42c:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           
4001a430:	87 28 60 02 	sll  %g1, 2, %g3                               
 * @param[in] bno is 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);       
4001a434:	f8 00 a0 0c 	ld  [ %g2 + 0xc ], %i4                         
4001a438:	86 06 40 03 	add  %i1, %g3, %g3                             
4001a43c:	c6 00 e0 24 	ld  [ %g3 + 0x24 ], %g3                        
4001a440:	88 00 60 06 	add  %g1, 6, %g4                               
4001a444:	89 29 20 02 	sll  %g4, 2, %g4                               
4001a448:	b8 07 00 04 	add  %i4, %g4, %i4                             
4001a44c:	b7 30 e0 18 	srl  %g3, 0x18, %i3                            
4001a450:	f6 2f 20 04 	stb  %i3, [ %i4 + 4 ]                          
4001a454:	f8 00 a0 0c 	ld  [ %g2 + 0xc ], %i4                         
4001a458:	b7 30 e0 10 	srl  %g3, 0x10, %i3                            
4001a45c:	b8 07 00 04 	add  %i4, %g4, %i4                             
4001a460:	f6 2f 20 05 	stb  %i3, [ %i4 + 5 ]                          
4001a464:	f8 00 a0 0c 	ld  [ %g2 + 0xc ], %i4                         
4001a468:	b7 30 e0 08 	srl  %g3, 8, %i3                               
4001a46c:	b8 07 00 04 	add  %i4, %g4, %i4                             
4001a470:	f6 2f 20 06 	stb  %i3, [ %i4 + 6 ]                          
4001a474:	f8 00 a0 0c 	ld  [ %g2 + 0xc ], %i4                         
                                                                      
    if (rc == 0)                                                      
    {                                                                 
      int b;                                                          
                                                                      
      for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)                    
4001a478:	82 00 60 01 	inc  %g1                                       
4001a47c:	88 07 00 04 	add  %i4, %g4, %g4                             
4001a480:	c6 29 20 07 	stb  %g3, [ %g4 + 7 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001a484:	fa 28 a0 10 	stb  %i5, [ %g2 + 0x10 ]                       
4001a488:	80 a0 60 05 	cmp  %g1, 5                                    
4001a48c:	12 bf ff e8 	bne  4001a42c <rtems_rfs_block_map_close+0x40> 
4001a490:	86 10 20 01 	mov  1, %g3                                    
        rtems_rfs_inode_set_block (map->inode, b, map->blocks[b]);    
      rtems_rfs_inode_set_block_count (map->inode, map->size.count);  
4001a494:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
4001a498:	c4 06 60 08 	ld  [ %i1 + 8 ], %g2                           
 * @param[in] block_count is 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);      
4001a49c:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a4a0:	bb 30 a0 18 	srl  %g2, 0x18, %i5                            
4001a4a4:	fa 29 20 0c 	stb  %i5, [ %g4 + 0xc ]                        
4001a4a8:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a4ac:	bb 30 a0 10 	srl  %g2, 0x10, %i5                            
4001a4b0:	fa 29 20 0d 	stb  %i5, [ %g4 + 0xd ]                        
4001a4b4:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a4b8:	bb 30 a0 08 	srl  %g2, 8, %i5                               
4001a4bc:	fa 29 20 0e 	stb  %i5, [ %g4 + 0xe ]                        
4001a4c0:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
      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);            
4001a4c4:	90 10 00 18 	mov  %i0, %o0                                  
4001a4c8:	c4 29 20 0f 	stb  %g2, [ %g4 + 0xf ]                        
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001a4cc:	c6 28 60 10 	stb  %g3, [ %g1 + 0x10 ]                       
      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);
4001a4d0:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
 */                                                                   
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);    
4001a4d4:	fa 0e 60 0e 	ldub  [ %i1 + 0xe ], %i5                       
4001a4d8:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
4001a4dc:	c8 06 60 0c 	ld  [ %i1 + 0xc ], %g4                         
4001a4e0:	fa 28 a0 0a 	stb  %i5, [ %g2 + 0xa ]                        
4001a4e4:	c4 00 60 0c 	ld  [ %g1 + 0xc ], %g2                         
      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);            
4001a4e8:	94 10 20 01 	mov  1, %o2                                    
4001a4ec:	c8 28 a0 0b 	stb  %g4, [ %g2 + 0xb ]                        
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001a4f0:	c6 28 60 10 	stb  %g3, [ %g1 + 0x10 ]                       
                                                                      
      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);
4001a4f4:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
4001a4f8:	c4 06 60 1c 	ld  [ %i1 + 0x1c ], %g2                        
 * @param[in] block_count is 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);
4001a4fc:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a500:	bb 30 a0 18 	srl  %g2, 0x18, %i5                            
4001a504:	fa 29 20 30 	stb  %i5, [ %g4 + 0x30 ]                       
4001a508:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a50c:	bb 30 a0 10 	srl  %g2, 0x10, %i5                            
4001a510:	fa 29 20 31 	stb  %i5, [ %g4 + 0x31 ]                       
4001a514:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a518:	bb 30 a0 08 	srl  %g2, 8, %i5                               
4001a51c:	fa 29 20 32 	stb  %i5, [ %g4 + 0x32 ]                       
4001a520:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a524:	c4 29 20 33 	stb  %g2, [ %g4 + 0x33 ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001a528:	c6 28 60 10 	stb  %g3, [ %g1 + 0x10 ]                       
      rtems_rfs_inode_set_last_data_block (map->inode, map->last_data_block);
4001a52c:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
4001a530:	c4 06 60 20 	ld  [ %i1 + 0x20 ], %g2                        
 * @param[in] block_count is 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);
4001a534:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a538:	bb 30 a0 18 	srl  %g2, 0x18, %i5                            
4001a53c:	fa 29 20 34 	stb  %i5, [ %g4 + 0x34 ]                       
4001a540:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a544:	bb 30 a0 10 	srl  %g2, 0x10, %i5                            
4001a548:	fa 29 20 35 	stb  %i5, [ %g4 + 0x35 ]                       
4001a54c:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a550:	bb 30 a0 08 	srl  %g2, 8, %i5                               
4001a554:	fa 29 20 36 	stb  %i5, [ %g4 + 0x36 ]                       
4001a558:	c8 00 60 0c 	ld  [ %g1 + 0xc ], %g4                         
4001a55c:	c4 29 20 37 	stb  %g2, [ %g4 + 0x37 ]                       
                                                                      
      brc = rtems_rfs_inode_unload (fs, map->inode, true);            
4001a560:	d2 06 60 04 	ld  [ %i1 + 4 ], %o1                           
4001a564:	7f ff de 14 	call  40011db4 <rtems_rfs_inode_unload>        
4001a568:	c6 28 60 10 	stb  %g3, [ %g1 + 0x10 ]                       
      if (brc > 0)                                                    
        rc = brc;                                                     
                                                                      
      map->dirty = false;                                             
4001a56c:	c0 2e 40 00 	clrb  [ %i1 ]                                  
4001a570:	82 38 00 08 	xnor  %g0, %o0, %g1                            
4001a574:	83 38 60 1f 	sra  %g1, 0x1f, %g1                            
4001a578:	ba 0a 00 01 	and  %o0, %g1, %i5                             
 */                                                                   
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);                       
4001a57c:	92 06 60 38 	add  %i1, 0x38, %o1                            
    }                                                                 
  }                                                                   
                                                                      
  map->inode = NULL;                                                  
4001a580:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
4001a584:	40 00 02 ad 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001a588:	90 10 00 18 	mov  %i0, %o0                                  
4001a58c:	90 10 00 18 	mov  %i0, %o0                                  
  handle->dirty = false;                                              
4001a590:	c0 2e 60 38 	clrb  [ %i1 + 0x38 ]                           
  handle->bnum  = 0;                                                  
4001a594:	c0 26 60 3c 	clr  [ %i1 + 0x3c ]                            
  handle->buffer = NULL;                                              
4001a598:	c0 26 60 40 	clr  [ %i1 + 0x40 ]                            
 */                                                                   
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);                       
4001a59c:	92 06 60 44 	add  %i1, 0x44, %o1                            
4001a5a0:	40 00 02 a6 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001a5a4:	b0 10 00 1d 	mov  %i5, %i0                                  
  handle->dirty = false;                                              
4001a5a8:	c0 2e 60 44 	clrb  [ %i1 + 0x44 ]                           
  handle->bnum  = 0;                                                  
4001a5ac:	c0 26 60 48 	clr  [ %i1 + 0x48 ]                            
  handle->buffer = NULL;                                              
4001a5b0:	c0 26 60 4c 	clr  [ %i1 + 0x4c ]                            
    rc = brc;                                                         
  brc = rtems_rfs_buffer_handle_close (fs, &map->doubly_buffer);      
  if ((brc > 0) && (rc == 0))                                         
    rc = brc;                                                         
  return rc;                                                          
}                                                                     
4001a5b4:	81 c7 e0 08 	ret                                            
4001a5b8:	81 e8 00 00 	restore                                        
                                                                      

4001a5bc <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) {
4001a5bc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int rc = 0;                                                         
                                                                      
  *block = 0;                                                         
4001a5c0:	c0 26 c0 00 	clr  [ %i3 ]                                   
                                                                      
  /*                                                                  
   * Range checking here makes the remaining logic simpler.           
   */                                                                 
  if (rtems_rfs_block_pos_block_past_end (bpos, &map->size))          
4001a5c4:	f8 06 80 00 	ld  [ %i2 ], %i4                               
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)               
{                                                                     
4001a5c8:	ba 10 00 18 	mov  %i0, %i5                                  
  *block = 0;                                                         
                                                                      
  /*                                                                  
   * Range checking here makes the remaining logic simpler.           
   */                                                                 
  if (rtems_rfs_block_pos_block_past_end (bpos, &map->size))          
4001a5cc:	80 a7 20 00 	cmp  %i4, 0                                    
4001a5d0:	02 80 00 05 	be  4001a5e4 <rtems_rfs_block_map_find+0x28>   
4001a5d4:	e0 06 60 08 	ld  [ %i1 + 8 ], %l0                           
4001a5d8:	80 a4 20 00 	cmp  %l0, 0                                    
4001a5dc:	02 80 00 55 	be  4001a730 <rtems_rfs_block_map_find+0x174>  <== NEVER TAKEN
4001a5e0:	b0 10 20 06 	mov  6, %i0                                    
4001a5e4:	80 a7 00 10 	cmp  %i4, %l0                                  
4001a5e8:	1a 80 00 52 	bcc  4001a730 <rtems_rfs_block_map_find+0x174> 
4001a5ec:	b0 10 20 06 	mov  6, %i0                                    
    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))         
4001a5f0:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4001a5f4:	80 a7 00 01 	cmp  %i4, %g1                                  
4001a5f8:	12 80 00 07 	bne  4001a614 <rtems_rfs_block_map_find+0x58>  
4001a5fc:	80 a4 20 05 	cmp  %l0, 5                                    
4001a600:	c2 06 60 18 	ld  [ %i1 + 0x18 ], %g1                        
4001a604:	80 a0 60 00 	cmp  %g1, 0                                    
4001a608:	32 80 00 3f 	bne,a   4001a704 <rtems_rfs_block_map_find+0x148>
4001a60c:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
    /*                                                                
     * 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)                    
4001a610:	80 a4 20 05 	cmp  %l0, 5                                    
4001a614:	38 80 00 08 	bgu,a   4001a634 <rtems_rfs_block_map_find+0x78>
4001a618:	e2 07 60 34 	ld  [ %i5 + 0x34 ], %l1                        
    {                                                                 
      *block = map->blocks[bpos->bno];                                
4001a61c:	b8 07 20 08 	add  %i4, 8, %i4                               
4001a620:	b9 2f 20 02 	sll  %i4, 2, %i4                               
4001a624:	b8 06 40 1c 	add  %i1, %i4, %i4                             
4001a628:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
4001a62c:	10 80 00 36 	b  4001a704 <rtems_rfs_block_map_find+0x148>   
4001a630:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
       * 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;                      
4001a634:	90 10 00 1c 	mov  %i4, %o0                                  
4001a638:	40 00 50 f1 	call  4002e9fc <.urem>                         
4001a63c:	92 10 00 11 	mov  %l1, %o1                                  
      singly = bpos->bno / fs->blocks_per_block;                      
4001a640:	92 10 00 11 	mov  %l1, %o1                                  
       * 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;                      
4001a644:	a4 10 00 08 	mov  %o0, %l2                                  
      singly = bpos->bno / fs->blocks_per_block;                      
4001a648:	7f ff a0 03 	call  40002654 <.udiv>                         
4001a64c:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
      if (map->size.count <= fs->block_map_singly_blocks)             
4001a650:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
       */                                                             
      rtems_rfs_block_no direct;                                      
      rtems_rfs_block_no singly;                                      
                                                                      
      direct = bpos->bno % fs->blocks_per_block;                      
      singly = bpos->bno / fs->blocks_per_block;                      
4001a654:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          
                                                                      
      if (map->size.count <= fs->block_map_singly_blocks)             
4001a658:	80 a4 00 01 	cmp  %l0, %g1                                  
4001a65c:	18 80 00 09 	bgu  4001a680 <rtems_rfs_block_map_find+0xc4>  
4001a660:	b8 10 00 08 	mov  %o0, %i4                                  
      {                                                               
        /*                                                            
         * This is a single indirect table of blocks anchored off a slot in the
         * inode.                                                     
         */                                                           
        rc = rtems_rfs_block_find_indirect (fs,                       
4001a664:	b8 02 20 08 	add  %o0, 8, %i4                               
4001a668:	92 06 60 38 	add  %i1, 0x38, %o1                            
4001a66c:	b9 2f 20 02 	sll  %i4, 2, %i4                               
4001a670:	90 10 00 1d 	mov  %i5, %o0                                  
4001a674:	b8 06 40 1c 	add  %i1, %i4, %i4                             
4001a678:	10 80 00 1d 	b  4001a6ec <rtems_rfs_block_map_find+0x130>   
4001a67c:	d4 07 20 04 	ld  [ %i4 + 4 ], %o2                           
         * The map is doubly indirect.                                
         */                                                           
        rtems_rfs_block_no doubly;                                    
                                                                      
        doubly  = singly / fs->blocks_per_block;                      
        singly %= fs->blocks_per_block;                               
4001a680:	40 00 50 df 	call  4002e9fc <.urem>                         
4001a684:	92 10 00 11 	mov  %l1, %o1                                  
                                                                      
        if (map->size.count < fs->block_map_doubly_blocks)            
4001a688:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
         * The map is doubly indirect.                                
         */                                                           
        rtems_rfs_block_no doubly;                                    
                                                                      
        doubly  = singly / fs->blocks_per_block;                      
        singly %= fs->blocks_per_block;                               
4001a68c:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          
4001a690:	a6 10 00 08 	mov  %o0, %l3                                  
                                                                      
        if (map->size.count < fs->block_map_doubly_blocks)            
4001a694:	80 a4 00 01 	cmp  %l0, %g1                                  
4001a698:	1a 80 00 25 	bcc  4001a72c <rtems_rfs_block_map_find+0x170> <== NEVER TAKEN
4001a69c:	90 10 20 06 	mov  6, %o0                                    
        /*                                                            
         * The map is doubly indirect.                                
         */                                                           
        rtems_rfs_block_no doubly;                                    
                                                                      
        doubly  = singly / fs->blocks_per_block;                      
4001a6a0:	92 10 00 11 	mov  %l1, %o1                                  
4001a6a4:	7f ff 9f ec 	call  40002654 <.udiv>                         
4001a6a8:	90 10 00 1c 	mov  %i4, %o0                                  
        singly %= fs->blocks_per_block;                               
                                                                      
        if (map->size.count < fs->block_map_doubly_blocks)            
        {                                                             
          rc = rtems_rfs_block_find_indirect (fs,                     
4001a6ac:	90 02 20 08 	add  %o0, 8, %o0                               
4001a6b0:	83 2a 20 02 	sll  %o0, 2, %g1                               
4001a6b4:	82 06 40 01 	add  %i1, %g1, %g1                             
4001a6b8:	d4 00 60 04 	ld  [ %g1 + 4 ], %o2                           
4001a6bc:	b0 06 60 44 	add  %i1, 0x44, %i0                            
4001a6c0:	90 10 00 1d 	mov  %i5, %o0                                  
4001a6c4:	92 10 00 18 	mov  %i0, %o1                                  
4001a6c8:	96 10 00 13 	mov  %l3, %o3                                  
4001a6cc:	7f ff fe 55 	call  4001a020 <rtems_rfs_block_find_indirect> 
4001a6d0:	98 07 bf fc 	add  %fp, -4, %o4                              
                                              &map->doubly_buffer,    
                                              map->blocks[doubly],    
                                              singly, &singly);       
          if (rc == 0)                                                
4001a6d4:	80 a2 20 00 	cmp  %o0, 0                                    
4001a6d8:	12 80 00 16 	bne  4001a730 <rtems_rfs_block_map_find+0x174> <== NEVER TAKEN
4001a6dc:	b0 10 00 08 	mov  %o0, %i0                                  
          {                                                           
            rc = rtems_rfs_block_find_indirect (fs,                   
4001a6e0:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
4001a6e4:	90 10 00 1d 	mov  %i5, %o0                                  
4001a6e8:	92 06 60 38 	add  %i1, 0x38, %o1                            
4001a6ec:	96 10 00 12 	mov  %l2, %o3                                  
4001a6f0:	7f ff fe 4c 	call  4001a020 <rtems_rfs_block_find_indirect> 
4001a6f4:	98 10 00 1b 	mov  %i3, %o4                                  
        }                                                             
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  if (rc == 0)                                                        
4001a6f8:	80 a2 20 00 	cmp  %o0, 0                                    
4001a6fc:	32 80 00 0d 	bne,a   4001a730 <rtems_rfs_block_map_find+0x174><== NEVER TAKEN
4001a700:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
  {                                                                   
    rtems_rfs_block_copy_bpos (&map->bpos, bpos);                     
4001a704:	c2 06 80 00 	ld  [ %i2 ], %g1                               
4001a708:	c2 26 60 10 	st  %g1, [ %i1 + 0x10 ]                        
4001a70c:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
4001a710:	c2 26 60 14 	st  %g1, [ %i1 + 0x14 ]                        
4001a714:	c2 06 a0 08 	ld  [ %i2 + 8 ], %g1                           
4001a718:	c2 26 60 18 	st  %g1, [ %i1 + 0x18 ]                        
    map->bpos.block = *block;                                         
4001a71c:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
4001a720:	c2 26 60 18 	st  %g1, [ %i1 + 0x18 ]                        
4001a724:	81 c7 e0 08 	ret                                            
4001a728:	91 e8 20 00 	restore  %g0, 0, %o0                           
4001a72c:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
4001a730:	81 c7 e0 08 	ret                                            
4001a734:	81 e8 00 00 	restore                                        
                                                                      

4001a7e0 <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) {
4001a7e0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int b;                                                              
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_GROW))               
4001a7e4:	90 10 20 00 	clr  %o0                                       
4001a7e8:	13 00 00 08 	sethi  %hi(0x2000), %o1                        
4001a7ec:	7f ff e3 98 	call  4001364c <rtems_rfs_trace>               
4001a7f0:	ba 10 00 18 	mov  %i0, %i5                                  
4001a7f4:	80 a2 20 00 	cmp  %o0, 0                                    
4001a7f8:	22 80 00 08 	be,a   4001a818 <rtems_rfs_block_map_grow+0x38><== ALWAYS TAKEN
4001a7fc:	c4 06 60 08 	ld  [ %i1 + 8 ], %g2                           
    printf ("rtems-rfs: block-map-grow: entry: blocks=%zd count=%" PRIu32 "\n",
4001a800:	d4 06 60 08 	ld  [ %i1 + 8 ], %o2                           <== NOT EXECUTED
4001a804:	11 10 00 d1 	sethi  %hi(0x40034400), %o0                    <== NOT EXECUTED
4001a808:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001a80c:	40 00 1e 9f 	call  40022288 <printf>                        <== NOT EXECUTED
4001a810:	90 12 23 e0 	or  %o0, 0x3e0, %o0                            <== NOT EXECUTED
            blocks, map->size.count);                                 
                                                                      
  if ((map->size.count + blocks) >= rtems_rfs_fs_max_block_map_blocks (fs))
4001a814:	c4 06 60 08 	ld  [ %i1 + 8 ], %g2                           <== NOT EXECUTED
4001a818:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
4001a81c:	84 06 80 02 	add  %i2, %g2, %g2                             
4001a820:	80 a0 80 01 	cmp  %g2, %g1                                  
4001a824:	1a 80 00 b0 	bcc  4001aae4 <rtems_rfs_block_map_grow+0x304> <== NEVER TAKEN
4001a828:	b0 10 20 1b 	mov  0x1b, %i0                                 
4001a82c:	a0 10 20 00 	clr  %l0                                       
            return rc;                                                
          }                                                           
        }                                                             
      }                                                               
                                                                      
      rtems_rfs_block_set_number (&map->singly_buffer, direct, block);
4001a830:	a6 10 20 01 	mov  1, %l3                                    
                                      singly,                         
                                      singly_block);                  
        }                                                             
        else                                                          
        {                                                             
          rc = rtems_rfs_buffer_handle_request (fs,                   
4001a834:	a8 06 60 44 	add  %i1, 0x44, %l4                            
          }                                                           
                                                                      
          singly_block = rtems_rfs_block_get_number (&map->doubly_buffer,
                                                     singly);         
                                                                      
          rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001a838:	a2 06 60 38 	add  %i1, 0x38, %l1                            
                                                                      
  /*                                                                  
   * 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++)                                        
4001a83c:	80 a4 00 1a 	cmp  %l0, %i2                                  
4001a840:	02 80 00 cf 	be  4001ab7c <rtems_rfs_block_map_grow+0x39c>  
4001a844:	90 10 00 1d 	mov  %i5, %o0                                  
    /*                                                                
     * 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,      
4001a848:	d2 06 60 20 	ld  [ %i1 + 0x20 ], %o1                        
4001a84c:	94 10 20 00 	clr  %o2                                       
4001a850:	7f ff dc 10 	call  40011890 <rtems_rfs_group_bitmap_alloc>  
4001a854:	96 07 bf f8 	add  %fp, -8, %o3                              
                                       false, &block);                
    if (rc > 0)                                                       
4001a858:	80 a2 20 00 	cmp  %o0, 0                                    
4001a85c:	14 80 00 c6 	bg  4001ab74 <rtems_rfs_block_map_grow+0x394>  
4001a860:	01 00 00 00 	nop                                            
      return rc;                                                      
                                                                      
    if (map->size.count < RTEMS_RFS_INODE_BLOCKS)                     
4001a864:	f8 06 60 08 	ld  [ %i1 + 8 ], %i4                           
4001a868:	80 a7 20 04 	cmp  %i4, 4                                    
4001a86c:	38 80 00 08 	bgu,a   4001a88c <rtems_rfs_block_map_grow+0xac>
4001a870:	f0 07 60 34 	ld  [ %i5 + 0x34 ], %i0                        
      map->blocks[map->size.count] = block;                           
4001a874:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4001a878:	b8 07 20 08 	add  %i4, 8, %i4                               
4001a87c:	b9 2f 20 02 	sll  %i4, 2, %i4                               
4001a880:	b8 06 40 1c 	add  %i1, %i4, %i4                             
4001a884:	10 80 00 b0 	b  4001ab44 <rtems_rfs_block_map_grow+0x364>   
4001a888:	c2 27 20 04 	st  %g1, [ %i4 + 4 ]                           
       * 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;                
4001a88c:	90 10 00 1c 	mov  %i4, %o0                                  
4001a890:	40 00 50 5b 	call  4002e9fc <.urem>                         
4001a894:	92 10 00 18 	mov  %i0, %o1                                  
      singly = map->size.count / fs->blocks_per_block;                
4001a898:	92 10 00 18 	mov  %i0, %o1                                  
       * 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;                
4001a89c:	a4 10 00 08 	mov  %o0, %l2                                  
      singly = map->size.count / fs->blocks_per_block;                
4001a8a0:	7f ff 9f 6d 	call  40002654 <.udiv>                         
4001a8a4:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
      if (map->size.count < fs->block_map_singly_blocks)              
4001a8a8:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
4001a8ac:	80 a7 00 01 	cmp  %i4, %g1                                  
4001a8b0:	1a 80 00 1c 	bcc  4001a920 <rtems_rfs_block_map_grow+0x140> 
4001a8b4:	ac 10 00 08 	mov  %o0, %l6                                  
         * 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) ||                                          
4001a8b8:	80 a4 a0 00 	cmp  %l2, 0                                    
4001a8bc:	02 80 00 07 	be  4001a8d8 <rtems_rfs_block_map_grow+0xf8>   
4001a8c0:	82 02 20 08 	add  %o0, 8, %g1                               
4001a8c4:	80 a4 a0 05 	cmp  %l2, 5                                    
4001a8c8:	12 80 00 10 	bne  4001a908 <rtems_rfs_block_map_grow+0x128> 
4001a8cc:	80 a2 20 00 	cmp  %o0, 0                                    
4001a8d0:	32 80 00 0f 	bne,a   4001a90c <rtems_rfs_block_map_grow+0x12c>
4001a8d4:	83 28 60 02 	sll  %g1, 2, %g1                               
           */                                                         
          bool upping;                                                
          upping = map->size.count == RTEMS_RFS_INODE_BLOCKS;         
          rc = rtems_rfs_block_map_indirect_alloc (fs, map,           
                                                   &map->singly_buffer,
                                                   &map->blocks[singly],
4001a8d8:	83 28 60 02 	sll  %g1, 2, %g1                               
        {                                                             
          /*                                                          
           * Upping is when we move from direct to singly indirect.   
           */                                                         
          bool upping;                                                
          upping = map->size.count == RTEMS_RFS_INODE_BLOCKS;         
4001a8dc:	b8 1f 20 05 	xor  %i4, 5, %i4                               
          rc = rtems_rfs_block_map_indirect_alloc (fs, map,           
4001a8e0:	80 a0 00 1c 	cmp  %g0, %i4                                  
                                                   &map->singly_buffer,
                                                   &map->blocks[singly],
4001a8e4:	96 06 40 01 	add  %i1, %g1, %o3                             
          /*                                                          
           * 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,           
4001a8e8:	90 10 00 1d 	mov  %i5, %o0                                  
4001a8ec:	92 10 00 19 	mov  %i1, %o1                                  
4001a8f0:	94 10 00 11 	mov  %l1, %o2                                  
4001a8f4:	96 02 e0 04 	add  %o3, 4, %o3                               
4001a8f8:	7f ff fd 7a 	call  40019ee0 <rtems_rfs_block_map_indirect_alloc>
4001a8fc:	98 60 3f ff 	subx  %g0, -1, %o4                             
          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)                                                 
4001a900:	10 80 00 73 	b  4001aacc <rtems_rfs_block_map_grow+0x2ec>   
4001a904:	b0 92 20 00 	orcc  %o0, 0, %i0                              
                                                   &map->blocks[singly],
                                                   upping);           
        }                                                             
        else                                                          
        {                                                             
          rc = rtems_rfs_buffer_handle_request (fs,  &map->singly_buffer,
4001a908:	83 28 60 02 	sll  %g1, 2, %g1                               
4001a90c:	90 10 00 1d 	mov  %i5, %o0                                  
4001a910:	82 06 40 01 	add  %i1, %g1, %g1                             
4001a914:	92 10 00 11 	mov  %l1, %o1                                  
4001a918:	10 80 00 6a 	b  4001aac0 <rtems_rfs_block_map_grow+0x2e0>   
4001a91c:	d4 00 60 04 	ld  [ %g1 + 4 ], %o2                           
         * Doubly indirect tables are being used.                     
         */                                                           
        rtems_rfs_block_no doubly;                                    
        rtems_rfs_block_no singly_block;                              
                                                                      
        doubly  = singly / fs->blocks_per_block;                      
4001a920:	7f ff 9f 4d 	call  40002654 <.udiv>                         
4001a924:	92 10 00 18 	mov  %i0, %o1                                  
        singly %= fs->blocks_per_block;                               
4001a928:	92 10 00 18 	mov  %i0, %o1                                  
         * Doubly indirect tables are being used.                     
         */                                                           
        rtems_rfs_block_no doubly;                                    
        rtems_rfs_block_no singly_block;                              
                                                                      
        doubly  = singly / fs->blocks_per_block;                      
4001a92c:	aa 10 00 08 	mov  %o0, %l5                                  
        singly %= fs->blocks_per_block;                               
4001a930:	40 00 50 33 	call  4002e9fc <.urem>                         
4001a934:	90 10 00 16 	mov  %l6, %o0                                  
         * 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)                                              
4001a938:	80 a4 a0 00 	cmp  %l2, 0                                    
4001a93c:	12 80 00 46 	bne  4001aa54 <rtems_rfs_block_map_grow+0x274> 
4001a940:	b8 10 00 08 	mov  %o0, %i4                                  
        {                                                             
          rc = rtems_rfs_block_map_indirect_alloc (fs, map,           
4001a944:	90 10 00 1d 	mov  %i5, %o0                                  
4001a948:	92 10 00 19 	mov  %i1, %o1                                  
4001a94c:	94 10 00 11 	mov  %l1, %o2                                  
4001a950:	96 07 bf fc 	add  %fp, -4, %o3                              
4001a954:	7f ff fd 63 	call  40019ee0 <rtems_rfs_block_map_indirect_alloc>
4001a958:	98 10 20 00 	clr  %o4                                       
                                                   &map->singly_buffer,
                                                   &singly_block,     
                                                   false);            
          if (rc > 0)                                                 
4001a95c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001a960:	14 80 00 5d 	bg  4001aad4 <rtems_rfs_block_map_grow+0x2f4>  <== NEVER TAKEN
4001a964:	80 a7 20 00 	cmp  %i4, 0                                    
                                                                      
          /*                                                          
           * 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) ||                                        
4001a968:	02 80 00 07 	be  4001a984 <rtems_rfs_block_map_grow+0x1a4>  <== NEVER TAKEN
4001a96c:	82 05 60 08 	add  %l5, 8, %g1                               
4001a970:	80 a7 20 05 	cmp  %i4, 5                                    
4001a974:	12 80 00 12 	bne  4001a9bc <rtems_rfs_block_map_grow+0x1dc> 
4001a978:	80 a5 60 00 	cmp  %l5, 0                                    
4001a97c:	32 80 00 11 	bne,a   4001a9c0 <rtems_rfs_block_map_grow+0x1e0><== NEVER TAKEN
4001a980:	83 28 60 02 	sll  %g1, 2, %g1                               <== NOT EXECUTED
          {                                                           
            bool upping;                                              
            upping = map->size.count == fs->block_map_singly_blocks;  
            rc = rtems_rfs_block_map_indirect_alloc (fs, map,         
                                                     &map->doubly_buffer,
                                                     &map->blocks[doubly],
4001a984:	83 28 60 02 	sll  %g1, 2, %g1                               
           */                                                         
          if ((singly == 0) ||                                        
              ((doubly == 0) && (singly == RTEMS_RFS_INODE_BLOCKS)))  
          {                                                           
            bool upping;                                              
            upping = map->size.count == fs->block_map_singly_blocks;  
4001a988:	c4 06 60 08 	ld  [ %i1 + 8 ], %g2                           
            rc = rtems_rfs_block_map_indirect_alloc (fs, map,         
                                                     &map->doubly_buffer,
                                                     &map->blocks[doubly],
4001a98c:	96 06 40 01 	add  %i1, %g1, %o3                             
           */                                                         
          if ((singly == 0) ||                                        
              ((doubly == 0) && (singly == RTEMS_RFS_INODE_BLOCKS)))  
          {                                                           
            bool upping;                                              
            upping = map->size.count == fs->block_map_singly_blocks;  
4001a990:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
            rc = rtems_rfs_block_map_indirect_alloc (fs, map,         
4001a994:	90 10 00 1d 	mov  %i5, %o0                                  
           */                                                         
          if ((singly == 0) ||                                        
              ((doubly == 0) && (singly == RTEMS_RFS_INODE_BLOCKS)))  
          {                                                           
            bool upping;                                              
            upping = map->size.count == fs->block_map_singly_blocks;  
4001a998:	84 18 80 01 	xor  %g2, %g1, %g2                             
            rc = rtems_rfs_block_map_indirect_alloc (fs, map,         
4001a99c:	80 a0 00 02 	cmp  %g0, %g2                                  
4001a9a0:	92 10 00 19 	mov  %i1, %o1                                  
4001a9a4:	94 10 00 14 	mov  %l4, %o2                                  
4001a9a8:	96 02 e0 04 	add  %o3, 4, %o3                               
4001a9ac:	7f ff fd 4d 	call  40019ee0 <rtems_rfs_block_map_indirect_alloc>
4001a9b0:	98 60 3f ff 	subx  %g0, -1, %o4                             
          }                                                           
          else                                                        
          {                                                           
            rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
                                                  map->blocks[doubly], true);
            if (rc > 0)                                               
4001a9b4:	10 80 00 0a 	b  4001a9dc <rtems_rfs_block_map_grow+0x1fc>   
4001a9b8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
              return rc;                                              
            }                                                         
          }                                                           
          else                                                        
          {                                                           
            rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
4001a9bc:	83 28 60 02 	sll  %g1, 2, %g1                               
4001a9c0:	82 06 40 01 	add  %i1, %g1, %g1                             
4001a9c4:	d4 00 60 04 	ld  [ %g1 + 4 ], %o2                           
4001a9c8:	90 10 00 1d 	mov  %i5, %o0                                  
4001a9cc:	92 10 00 14 	mov  %l4, %o1                                  
4001a9d0:	40 00 02 23 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001a9d4:	96 10 20 01 	mov  1, %o3                                    
                                                  map->blocks[doubly], true);
            if (rc > 0)                                               
4001a9d8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001a9dc:	24 80 00 08 	ble,a   4001a9fc <rtems_rfs_block_map_grow+0x21c><== ALWAYS TAKEN
4001a9e0:	c2 06 60 4c 	ld  [ %i1 + 0x4c ], %g1                        
            {                                                         
              rtems_rfs_group_bitmap_free (fs, false, singly_block);  
4001a9e4:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          <== NOT EXECUTED
4001a9e8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001a9ec:	7f ff dc 2b 	call  40011a98 <rtems_rfs_group_bitmap_free>   <== NOT EXECUTED
4001a9f0:	92 10 20 00 	clr  %o1                                       <== 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);           
4001a9f4:	10 80 00 39 	b  4001aad8 <rtems_rfs_block_map_grow+0x2f8>   <== NOT EXECUTED
4001a9f8:	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,            
4001a9fc:	c4 0f bf fc 	ldub  [ %fp + -4 ], %g2                        
4001aa00:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001aa04:	b9 2f 20 02 	sll  %i4, 2, %i4                               
4001aa08:	c4 28 40 1c 	stb  %g2, [ %g1 + %i4 ]                        
4001aa0c:	c2 06 60 4c 	ld  [ %i1 + 0x4c ], %g1                        
4001aa10:	c4 17 bf fc 	lduh  [ %fp + -4 ], %g2                        
4001aa14:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001aa18:	82 00 40 1c 	add  %g1, %i4, %g1                             
4001aa1c:	c4 28 60 01 	stb  %g2, [ %g1 + 1 ]                          
4001aa20:	c2 06 60 4c 	ld  [ %i1 + 0x4c ], %g1                        
4001aa24:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
4001aa28:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001aa2c:	85 30 a0 08 	srl  %g2, 8, %g2                               
4001aa30:	82 00 40 1c 	add  %g1, %i4, %g1                             
4001aa34:	c4 28 60 02 	stb  %g2, [ %g1 + 2 ]                          
4001aa38:	c2 06 60 4c 	ld  [ %i1 + 0x4c ], %g1                        
4001aa3c:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001aa40:	b8 00 40 1c 	add  %g1, %i4, %i4                             
4001aa44:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4001aa48:	c2 2f 20 03 	stb  %g1, [ %i4 + 3 ]                          
4001aa4c:	10 80 00 28 	b  4001aaec <rtems_rfs_block_map_grow+0x30c>   
4001aa50:	e6 2e 60 44 	stb  %l3, [ %i1 + 0x44 ]                       
                                      singly,                         
                                      singly_block);                  
        }                                                             
        else                                                          
        {                                                             
          rc = rtems_rfs_buffer_handle_request (fs,                   
4001aa54:	aa 05 60 08 	add  %l5, 8, %l5                               
4001aa58:	ab 2d 60 02 	sll  %l5, 2, %l5                               
4001aa5c:	aa 06 40 15 	add  %i1, %l5, %l5                             
4001aa60:	d4 05 60 04 	ld  [ %l5 + 4 ], %o2                           
4001aa64:	90 10 00 1d 	mov  %i5, %o0                                  
4001aa68:	92 10 00 14 	mov  %l4, %o1                                  
4001aa6c:	40 00 01 fc 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001aa70:	96 10 20 01 	mov  1, %o3                                    
                                                &map->doubly_buffer,  
                                                map->blocks[doubly],  
                                                true);                
          if (rc > 0)                                                 
4001aa74:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001aa78:	14 80 00 17 	bg  4001aad4 <rtems_rfs_block_map_grow+0x2f4>  <== NEVER TAKEN
4001aa7c:	b9 2f 20 02 	sll  %i4, 2, %i4                               
          {                                                           
            rtems_rfs_group_bitmap_free (fs, false, block);           
            return rc;                                                
          }                                                           
                                                                      
          singly_block = rtems_rfs_block_get_number (&map->doubly_buffer,
4001aa80:	c2 06 60 4c 	ld  [ %i1 + 0x4c ], %g1                        
4001aa84:	c4 00 60 1c 	ld  [ %g1 + 0x1c ], %g2                        
                                                     singly);         
                                                                      
          rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001aa88:	90 10 00 1d 	mov  %i5, %o0                                  
          {                                                           
            rtems_rfs_group_bitmap_free (fs, false, block);           
            return rc;                                                
          }                                                           
                                                                      
          singly_block = rtems_rfs_block_get_number (&map->doubly_buffer,
4001aa8c:	82 00 80 1c 	add  %g2, %i4, %g1                             
4001aa90:	d4 08 80 1c 	ldub  [ %g2 + %i4 ], %o2                       
4001aa94:	c6 08 60 03 	ldub  [ %g1 + 3 ], %g3                         
4001aa98:	c4 08 60 01 	ldub  [ %g1 + 1 ], %g2                         
4001aa9c:	c2 08 60 02 	ldub  [ %g1 + 2 ], %g1                         
4001aaa0:	95 2a a0 18 	sll  %o2, 0x18, %o2                            
4001aaa4:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001aaa8:	94 10 c0 0a 	or  %g3, %o2, %o2                              
4001aaac:	83 28 60 08 	sll  %g1, 8, %g1                               
4001aab0:	94 12 80 02 	or  %o2, %g2, %o2                              
                                                     singly);         
                                                                      
          rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001aab4:	92 10 00 11 	mov  %l1, %o1                                  
          {                                                           
            rtems_rfs_group_bitmap_free (fs, false, block);           
            return rc;                                                
          }                                                           
                                                                      
          singly_block = rtems_rfs_block_get_number (&map->doubly_buffer,
4001aab8:	94 12 80 01 	or  %o2, %g1, %o2                              
4001aabc:	d4 27 bf fc 	st  %o2, [ %fp + -4 ]                          
                                                     singly);         
                                                                      
          rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001aac0:	40 00 01 e7 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001aac4:	96 10 20 01 	mov  1, %o3                                    
                                                singly_block, true);  
          if (rc > 0)                                                 
4001aac8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001aacc:	24 80 00 09 	ble,a   4001aaf0 <rtems_rfs_block_map_grow+0x310><== ALWAYS TAKEN
4001aad0:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
          {                                                           
            rtems_rfs_group_bitmap_free (fs, false, block);           
4001aad4:	d4 07 bf f8 	ld  [ %fp + -8 ], %o2                          <== NOT EXECUTED
4001aad8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001aadc:	7f ff db ef 	call  40011a98 <rtems_rfs_group_bitmap_free>   <== NOT EXECUTED
4001aae0:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
            return rc;                                                
4001aae4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001aae8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
          }                                                           
        }                                                             
      }                                                               
                                                                      
      rtems_rfs_block_set_number (&map->singly_buffer, direct, block);
4001aaec:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
4001aaf0:	c4 0f bf f8 	ldub  [ %fp + -8 ], %g2                        
4001aaf4:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001aaf8:	a5 2c a0 02 	sll  %l2, 2, %l2                               
4001aafc:	c4 28 40 12 	stb  %g2, [ %g1 + %l2 ]                        
4001ab00:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
4001ab04:	c4 17 bf f8 	lduh  [ %fp + -8 ], %g2                        
4001ab08:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001ab0c:	82 00 40 12 	add  %g1, %l2, %g1                             
4001ab10:	c4 28 60 01 	stb  %g2, [ %g1 + 1 ]                          
4001ab14:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
4001ab18:	c4 07 bf f8 	ld  [ %fp + -8 ], %g2                          
4001ab1c:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001ab20:	85 30 a0 08 	srl  %g2, 8, %g2                               
4001ab24:	82 00 40 12 	add  %g1, %l2, %g1                             
4001ab28:	c4 28 60 02 	stb  %g2, [ %g1 + 2 ]                          
4001ab2c:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
4001ab30:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001ab34:	a4 00 40 12 	add  %g1, %l2, %l2                             
4001ab38:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4001ab3c:	c2 2c a0 03 	stb  %g1, [ %l2 + 3 ]                          
4001ab40:	e6 2e 60 38 	stb  %l3, [ %i1 + 0x38 ]                       
    }                                                                 
                                                                      
    map->size.count++;                                                
4001ab44:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
    map->size.offset = 0;                                             
4001ab48:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
      }                                                               
                                                                      
      rtems_rfs_block_set_number (&map->singly_buffer, direct, block);
    }                                                                 
                                                                      
    map->size.count++;                                                
4001ab4c:	82 00 60 01 	inc  %g1                                       
4001ab50:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]                           
    map->size.offset = 0;                                             
                                                                      
    if (b == 0)                                                       
4001ab54:	80 a4 20 00 	cmp  %l0, 0                                    
4001ab58:	12 80 00 03 	bne  4001ab64 <rtems_rfs_block_map_grow+0x384> <== NEVER TAKEN
4001ab5c:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
      *new_block = block;                                             
4001ab60:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
    map->last_data_block = block;                                     
4001ab64:	c2 26 60 20 	st  %g1, [ %i1 + 0x20 ]                        
    map->dirty = true;                                                
4001ab68:	e6 2e 40 00 	stb  %l3, [ %i1 ]                              
                                                                      
  /*                                                                  
   * 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++)                                        
4001ab6c:	10 bf ff 34 	b  4001a83c <rtems_rfs_block_map_grow+0x5c>    
4001ab70:	a0 04 20 01 	inc  %l0                                       
    /*                                                                
     * 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,      
4001ab74:	81 c7 e0 08 	ret                                            
4001ab78:	91 e8 00 08 	restore  %g0, %o0, %o0                         
      *new_block = block;                                             
    map->last_data_block = block;                                     
    map->dirty = true;                                                
  }                                                                   
                                                                      
  return 0;                                                           
4001ab7c:	b0 10 20 00 	clr  %i0                                       
}                                                                     
4001ab80:	81 c7 e0 08 	ret                                            
4001ab84:	81 e8 00 00 	restore                                        
                                                                      

40019ee0 <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) {
40019ee0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  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);
40019ee4:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        
40019ee8:	90 10 00 18 	mov  %i0, %o0                                  
40019eec:	94 10 20 00 	clr  %o2                                       
40019ef0:	96 07 bf fc 	add  %fp, -4, %o3                              
40019ef4:	7f ff de 67 	call  40011890 <rtems_rfs_group_bitmap_alloc>  
40019ef8:	ba 10 00 18 	mov  %i0, %i5                                  
  if (rc > 0)                                                         
40019efc:	80 a2 20 00 	cmp  %o0, 0                                    
40019f00:	14 80 00 46 	bg  4001a018 <rtems_rfs_block_map_indirect_alloc+0x138><== NEVER TAKEN
40019f04:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
    return rc;                                                        
  rc = rtems_rfs_buffer_handle_request (fs, buffer, new_block, false);
40019f08:	90 10 00 18 	mov  %i0, %o0                                  
40019f0c:	92 10 00 1a 	mov  %i2, %o1                                  
40019f10:	40 00 04 d3 	call  4001b25c <rtems_rfs_buffer_handle_request>
40019f14:	96 10 20 00 	clr  %o3                                       
  if (rc > 0)                                                         
40019f18:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40019f1c:	04 80 00 07 	ble  40019f38 <rtems_rfs_block_map_indirect_alloc+0x58><== ALWAYS TAKEN
40019f20:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
  {                                                                   
    rtems_rfs_group_bitmap_free (fs, false, new_block);               
40019f24:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40019f28:	7f ff de dc 	call  40011a98 <rtems_rfs_group_bitmap_free>   <== NOT EXECUTED
40019f2c:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
    return rc;                                                        
40019f30:	10 80 00 3a 	b  4001a018 <rtems_rfs_block_map_indirect_alloc+0x138><== NOT EXECUTED
40019f34:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
  }                                                                   
  memset (rtems_rfs_buffer_data (buffer), 0xff, rtems_rfs_fs_block_size (fs));
40019f38:	c2 06 a0 08 	ld  [ %i2 + 8 ], %g1                           
40019f3c:	d4 07 60 08 	ld  [ %i5 + 8 ], %o2                           
40019f40:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40019f44:	40 00 20 58 	call  400220a4 <memset>                        
40019f48:	92 10 20 ff 	mov  0xff, %o1                                 
  if (upping)                                                         
40019f4c:	80 a7 20 00 	cmp  %i4, 0                                    
40019f50:	02 80 00 2d 	be  4001a004 <rtems_rfs_block_map_indirect_alloc+0x124>
40019f54:	82 10 20 01 	mov  1, %g1                                    
  {                                                                   
    int b;                                                            
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_GROW))             
40019f58:	90 10 20 00 	clr  %o0                                       
40019f5c:	7f ff e5 bc 	call  4001364c <rtems_rfs_trace>               
40019f60:	13 00 00 08 	sethi  %hi(0x2000), %o1                        
40019f64:	80 a2 20 00 	cmp  %o0, 0                                    
40019f68:	02 80 00 07 	be  40019f84 <rtems_rfs_block_map_indirect_alloc+0xa4><== ALWAYS TAKEN
40019f6c:	84 10 00 19 	mov  %i1, %g2                                  
      printf ("rtems-rfs: block-map-grow: upping: block-count=%" PRId32 "\n",
40019f70:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
40019f74:	11 10 00 d1 	sethi  %hi(0x40034400), %o0                    <== NOT EXECUTED
40019f78:	40 00 20 c4 	call  40022288 <printf>                        <== NOT EXECUTED
40019f7c:	90 12 23 58 	or  %o0, 0x358, %o0	! 40034758 <CSWTCH.1+0x8>  <== NOT EXECUTED
40019f80:	84 10 00 19 	mov  %i1, %g2                                  <== 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)  
{                                                                     
40019f84:	82 10 20 00 	clr  %g1                                       
    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]);         
40019f88:	86 10 20 01 	mov  1, %g3                                    
40019f8c:	c8 06 a0 08 	ld  [ %i2 + 8 ], %g4                           
40019f90:	fa 08 a0 24 	ldub  [ %g2 + 0x24 ], %i5                      
40019f94:	c8 01 20 1c 	ld  [ %g4 + 0x1c ], %g4                        
40019f98:	84 00 a0 04 	add  %g2, 4, %g2                               
40019f9c:	fa 29 00 01 	stb  %i5, [ %g4 + %g1 ]                        
40019fa0:	c8 06 a0 08 	ld  [ %i2 + 8 ], %g4                           
40019fa4:	fa 10 a0 20 	lduh  [ %g2 + 0x20 ], %i5                      
40019fa8:	c8 01 20 1c 	ld  [ %g4 + 0x1c ], %g4                        
40019fac:	88 01 00 01 	add  %g4, %g1, %g4                             
40019fb0:	fa 29 20 01 	stb  %i5, [ %g4 + 1 ]                          
40019fb4:	c8 06 a0 08 	ld  [ %i2 + 8 ], %g4                           
40019fb8:	fa 00 a0 20 	ld  [ %g2 + 0x20 ], %i5                        
40019fbc:	c8 01 20 1c 	ld  [ %g4 + 0x1c ], %g4                        
40019fc0:	bb 37 60 08 	srl  %i5, 8, %i5                               
40019fc4:	88 01 00 01 	add  %g4, %g1, %g4                             
40019fc8:	fa 29 20 02 	stb  %i5, [ %g4 + 2 ]                          
40019fcc:	c8 06 a0 08 	ld  [ %i2 + 8 ], %g4                           
40019fd0:	fa 00 a0 20 	ld  [ %g2 + 0x20 ], %i5                        
40019fd4:	c8 01 20 1c 	ld  [ %g4 + 0x1c ], %g4                        
40019fd8:	88 01 00 01 	add  %g4, %g1, %g4                             
40019fdc:	fa 29 20 03 	stb  %i5, [ %g4 + 3 ]                          
40019fe0:	82 00 60 04 	add  %g1, 4, %g1                               
  {                                                                   
    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++)                      
40019fe4:	80 a0 60 14 	cmp  %g1, 0x14                                 
40019fe8:	12 bf ff e9 	bne  40019f8c <rtems_rfs_block_map_indirect_alloc+0xac>
40019fec:	c6 2e 80 00 	stb  %g3, [ %i2 ]                              
      rtems_rfs_block_set_number (buffer, b, map->blocks[b]);         
    memset (map->blocks, 0, sizeof (map->blocks));                    
40019ff0:	90 06 60 24 	add  %i1, 0x24, %o0                            
40019ff4:	92 10 20 00 	clr  %o1                                       
40019ff8:	40 00 20 2b 	call  400220a4 <memset>                        
40019ffc:	94 10 20 14 	mov  0x14, %o2                                 
  }                                                                   
  rtems_rfs_buffer_mark_dirty (buffer);                               
4001a000:	82 10 20 01 	mov  1, %g1                                    
4001a004:	c2 2e 80 00 	stb  %g1, [ %i2 ]                              
  *block = new_block;                                                 
4001a008:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
  map->last_map_block = new_block;                                    
  return 0;                                                           
4001a00c:	90 10 20 00 	clr  %o0                                       
    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);                               
  *block = new_block;                                                 
4001a010:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
  map->last_map_block = new_block;                                    
4001a014:	c2 26 60 1c 	st  %g1, [ %i1 + 0x1c ]                        
  return 0;                                                           
}                                                                     
4001a018:	81 c7 e0 08 	ret                                            
4001a01c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001a0e0 <rtems_rfs_block_map_indirect_shrink.isra.7>: * @param indirect The index index in the inode's block table. * @param index The index in the indirect table of the block. * @return int The error number (errno). No error if 0. */ static int rtems_rfs_block_map_indirect_shrink (rtems_rfs_file_system* fs,
4001a0e0:	9d e3 bf a0 	save  %sp, -96, %sp                            
   * 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) ||                                                 
4001a0e4:	80 a7 20 00 	cmp  %i4, 0                                    
4001a0e8:	02 80 00 08 	be  4001a108 <rtems_rfs_block_map_indirect_shrink.isra.7+0x28><== NEVER TAKEN
4001a0ec:	b8 1f 20 05 	xor  %i4, 5, %i4                               
4001a0f0:	80 a7 20 00 	cmp  %i4, 0                                    
4001a0f4:	32 80 00 2b 	bne,a   4001a1a0 <rtems_rfs_block_map_indirect_shrink.isra.7+0xc0>
4001a0f8:	b0 10 20 00 	clr  %i0                                       
4001a0fc:	80 a6 e0 00 	cmp  %i3, 0                                    
4001a100:	32 80 00 28 	bne,a   4001a1a0 <rtems_rfs_block_map_indirect_shrink.isra.7+0xc0><== NEVER TAKEN
4001a104:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
4001a108:	83 2e e0 02 	sll  %i3, 2, %g1                               
      ((indirect == 0) && (index == RTEMS_RFS_INODE_BLOCKS)))         
  {                                                                   
    rtems_rfs_block_no block_to_free = map->blocks[indirect];         
                                                                      
    if ((indirect == 0) && (index == RTEMS_RFS_INODE_BLOCKS))         
4001a10c:	80 a7 20 00 	cmp  %i4, 0                                    
4001a110:	82 06 40 01 	add  %i1, %g1, %g1                             
4001a114:	12 80 00 1a 	bne  4001a17c <rtems_rfs_block_map_indirect_shrink.isra.7+0x9c><== NEVER TAKEN
4001a118:	fa 00 60 24 	ld  [ %g1 + 0x24 ], %i5                        
4001a11c:	80 a6 e0 00 	cmp  %i3, 0                                    
4001a120:	32 80 00 18 	bne,a   4001a180 <rtems_rfs_block_map_indirect_shrink.isra.7+0xa0><== NEVER TAKEN
4001a124:	c0 20 60 24 	clr  [ %g1 + 0x24 ]                            <== 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);      
4001a128:	c2 06 80 00 	ld  [ %i2 ], %g1                               
4001a12c:	84 10 20 00 	clr  %g2                                       
4001a130:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
4001a134:	f8 08 40 00 	ldub  [ %g1 ], %i4                             
4001a138:	c8 08 60 01 	ldub  [ %g1 + 1 ], %g4                         
4001a13c:	b9 2f 20 18 	sll  %i4, 0x18, %i4                            
4001a140:	89 29 20 10 	sll  %g4, 0x10, %g4                            
4001a144:	88 17 00 04 	or  %i4, %g4, %g4                              
4001a148:	f8 08 60 03 	ldub  [ %g1 + 3 ], %i4                         
4001a14c:	86 06 40 02 	add  %i1, %g2, %g3                             
4001a150:	88 11 00 1c 	or  %g4, %i4, %g4                              
4001a154:	f8 08 60 02 	ldub  [ %g1 + 2 ], %i4                         
4001a158:	84 00 a0 04 	add  %g2, 4, %g2                               
4001a15c:	b9 2f 20 08 	sll  %i4, 8, %i4                               
4001a160:	88 11 00 1c 	or  %g4, %i4, %g4                              
4001a164:	c8 20 e0 24 	st  %g4, [ %g3 + 0x24 ]                        
    {                                                                 
      /*                                                              
       * Move to direct inode access.                                 
       */                                                             
      int b;                                                          
      for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)                    
4001a168:	80 a0 a0 14 	cmp  %g2, 0x14                                 
4001a16c:	12 bf ff f2 	bne  4001a134 <rtems_rfs_block_map_indirect_shrink.isra.7+0x54>
4001a170:	82 00 60 04 	add  %g1, 4, %g1                               
       * One less singly indirect block in the inode.                 
       */                                                             
      map->blocks[indirect] = 0;                                      
    }                                                                 
                                                                      
    rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);      
4001a174:	10 80 00 04 	b  4001a184 <rtems_rfs_block_map_indirect_shrink.isra.7+0xa4>
4001a178:	90 10 00 18 	mov  %i0, %o0                                  
    else                                                              
    {                                                                 
      /*                                                              
       * One less singly indirect block in the inode.                 
       */                                                             
      map->blocks[indirect] = 0;                                      
4001a17c:	c0 20 60 24 	clr  [ %g1 + 0x24 ]                            <== NOT EXECUTED
    }                                                                 
                                                                      
    rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);      
4001a180:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001a184:	92 10 20 00 	clr  %o1                                       
4001a188:	7f ff de 44 	call  40011a98 <rtems_rfs_group_bitmap_free>   
4001a18c:	94 10 00 1d 	mov  %i5, %o2                                  
    if (rc > 0)                                                       
4001a190:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001a194:	14 80 00 05 	bg  4001a1a8 <rtems_rfs_block_map_indirect_shrink.isra.7+0xc8><== NEVER TAKEN
4001a198:	01 00 00 00 	nop                                            
      return rc;                                                      
                                                                      
    map->last_map_block = block_to_free;                              
4001a19c:	fa 26 60 1c 	st  %i5, [ %i1 + 0x1c ]                        
4001a1a0:	81 c7 e0 08 	ret                                            
4001a1a4:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
4001a1a8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001a1ac:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001a274 <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) {
4001a274:	9d e3 bf a0 	save  %sp, -96, %sp                            
   * 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;                                                 
4001a278:	c0 2e 80 00 	clrb  [ %i2 ]                                  
  map->inode = NULL;                                                  
4001a27c:	c0 26 a0 04 	clr  [ %i2 + 4 ]                               
 * @param[in] size is a pointer to the block size.                    
 */                                                                   
static inline void                                                    
rtems_rfs_block_set_size_zero (rtems_rfs_block_size* size)            
{                                                                     
  size->count = 0;                                                    
4001a280:	c0 26 a0 08 	clr  [ %i2 + 8 ]                               
  size->offset = 0;                                                   
4001a284:	c0 26 a0 0c 	clr  [ %i2 + 0xc ]                             
 * @param[in] bpos is a pointer to the block position.                
 */                                                                   
static inline void                                                    
rtems_rfs_block_set_bpos_zero (rtems_rfs_block_pos* bpos)             
{                                                                     
  bpos->bno = 0;                                                      
4001a288:	c0 26 a0 10 	clr  [ %i2 + 0x10 ]                            
  bpos->boff = 0;                                                     
4001a28c:	c0 26 a0 14 	clr  [ %i2 + 0x14 ]                            
  bpos->block = 0;                                                    
4001a290:	c0 26 a0 18 	clr  [ %i2 + 0x18 ]                            
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001a294:	c0 2e a0 38 	clrb  [ %i2 + 0x38 ]                           
  handle->bnum  = 0;                                                  
4001a298:	c0 26 a0 3c 	clr  [ %i2 + 0x3c ]                            
  handle->buffer = NULL;                                              
4001a29c:	c0 26 a0 40 	clr  [ %i2 + 0x40 ]                            
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001a2a0:	c0 2e a0 44 	clrb  [ %i2 + 0x44 ]                           
  handle->bnum  = 0;                                                  
4001a2a4:	c0 26 a0 48 	clr  [ %i2 + 0x48 ]                            
  handle->buffer = NULL;                                              
4001a2a8:	c0 26 a0 4c 	clr  [ %i2 + 0x4c ]                            
    return rc;                                                        
  rc = rtems_rfs_buffer_handle_open (fs, &map->doubly_buffer);        
  if (rc > 0)                                                         
    return rc;                                                        
                                                                      
  rc = rtems_rfs_inode_load (fs, inode);                              
4001a2ac:	90 10 00 18 	mov  %i0, %o0                                  
4001a2b0:	7f ff de 5e 	call  40011c28 <rtems_rfs_inode_load>          
4001a2b4:	92 10 00 19 	mov  %i1, %o1                                  
  if (rc > 0)                                                         
4001a2b8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001a2bc:	14 80 00 3d 	bg  4001a3b0 <rtems_rfs_block_map_open+0x13c>  <== NEVER TAKEN
4001a2c0:	86 10 20 00 	clr  %g3                                       
  return (((uint64_t) (size->count - 1)) * block_size) + offset;      
}                                                                     
                                                                      
int                                                                   
rtems_rfs_block_map_open (rtems_rfs_file_system*  fs,                 
                          rtems_rfs_inode_handle* inode,              
4001a2c4:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
                                                                      
  /*                                                                  
   * Extract the block and block count data from the inode into the targets
   * byte order.                                                      
   */                                                                 
  map->inode = inode;                                                 
4001a2c8:	f2 26 a0 04 	st  %i1, [ %i2 + 4 ]                           
4001a2cc:	84 00 60 1c 	add  %g1, 0x1c, %g2                            
 * @retval block 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]);      
4001a2d0:	f8 08 80 00 	ldub  [ %g2 ], %i4                             
4001a2d4:	fa 08 a0 01 	ldub  [ %g2 + 1 ], %i5                         
4001a2d8:	b9 2f 20 18 	sll  %i4, 0x18, %i4                            
4001a2dc:	bb 2f 60 10 	sll  %i5, 0x10, %i5                            
4001a2e0:	ba 17 00 1d 	or  %i4, %i5, %i5                              
4001a2e4:	f8 08 a0 03 	ldub  [ %g2 + 3 ], %i4                         
4001a2e8:	88 06 80 03 	add  %i2, %g3, %g4                             
4001a2ec:	ba 17 40 1c 	or  %i5, %i4, %i5                              
4001a2f0:	f8 08 a0 02 	ldub  [ %g2 + 2 ], %i4                         
4001a2f4:	86 00 e0 04 	add  %g3, 4, %g3                               
4001a2f8:	b9 2f 20 08 	sll  %i4, 8, %i4                               
4001a2fc:	ba 17 40 1c 	or  %i5, %i4, %i5                              
  for (b = 0; b < RTEMS_RFS_INODE_BLOCKS; b++)                        
    map->blocks[b] = rtems_rfs_inode_get_block (inode, b);            
4001a300:	fa 21 20 24 	st  %i5, [ %g4 + 0x24 ]                        
  /*                                                                  
   * 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++)                        
4001a304:	80 a0 e0 14 	cmp  %g3, 0x14                                 
4001a308:	12 bf ff f2 	bne  4001a2d0 <rtems_rfs_block_map_open+0x5c>  
4001a30c:	84 00 a0 04 	add  %g2, 4, %g2                               
 * @retval count 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);             
4001a310:	c6 08 60 0c 	ldub  [ %g1 + 0xc ], %g3                       
4001a314:	c4 08 60 0d 	ldub  [ %g1 + 0xd ], %g2                       
4001a318:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001a31c:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001a320:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001a324:	c6 08 60 0f 	ldub  [ %g1 + 0xf ], %g3                       
4001a328:	84 10 80 03 	or  %g2, %g3, %g2                              
4001a32c:	c6 08 60 0e 	ldub  [ %g1 + 0xe ], %g3                       
4001a330:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001a334:	84 10 80 03 	or  %g2, %g3, %g2                              
    map->blocks[b] = rtems_rfs_inode_get_block (inode, b);            
  map->size.count = rtems_rfs_inode_get_block_count (inode);          
4001a338:	c4 26 a0 08 	st  %g2, [ %i2 + 8 ]                           
  map->size.offset = rtems_rfs_inode_get_block_offset (inode);        
4001a33c:	c6 08 60 0b 	ldub  [ %g1 + 0xb ], %g3                       
 * @retval offset The block offset.                                   
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_block_offset (rtems_rfs_inode_handle* handle)     
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->block_offset);            
4001a340:	c4 08 60 0a 	ldub  [ %g1 + 0xa ], %g2                       
4001a344:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001a348:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001a34c:	c4 26 a0 0c 	st  %g2, [ %i2 + 0xc ]                         
 * @retval block 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);          
4001a350:	c6 08 60 30 	ldub  [ %g1 + 0x30 ], %g3                      
4001a354:	c4 08 60 31 	ldub  [ %g1 + 0x31 ], %g2                      
4001a358:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001a35c:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001a360:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001a364:	c6 08 60 33 	ldub  [ %g1 + 0x33 ], %g3                      
4001a368:	84 10 80 03 	or  %g2, %g3, %g2                              
4001a36c:	c6 08 60 32 	ldub  [ %g1 + 0x32 ], %g3                      
4001a370:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001a374:	84 10 80 03 	or  %g2, %g3, %g2                              
  map->last_map_block = rtems_rfs_inode_get_last_map_block (inode);   
4001a378:	c4 26 a0 1c 	st  %g2, [ %i2 + 0x1c ]                        
 *                                                                    
 */                                                                   
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);         
4001a37c:	c4 08 60 35 	ldub  [ %g1 + 0x35 ], %g2                      
4001a380:	c6 08 60 34 	ldub  [ %g1 + 0x34 ], %g3                      
4001a384:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001a388:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001a38c:	86 10 c0 02 	or  %g3, %g2, %g3                              
4001a390:	c4 08 60 37 	ldub  [ %g1 + 0x37 ], %g2                      
4001a394:	86 10 c0 02 	or  %g3, %g2, %g3                              
4001a398:	c4 08 60 36 	ldub  [ %g1 + 0x36 ], %g2                      
4001a39c:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001a3a0:	82 10 c0 02 	or  %g3, %g2, %g1                              
  map->last_data_block = rtems_rfs_inode_get_last_data_block (inode); 
4001a3a4:	c2 26 a0 20 	st  %g1, [ %i2 + 0x20 ]                        
                                                                      
  rc = rtems_rfs_inode_unload (fs, inode, false);                     
4001a3a8:	7f ff de 83 	call  40011db4 <rtems_rfs_inode_unload>        
4001a3ac:	95 e8 20 00 	restore  %g0, 0, %o2                           
 */                                                                   
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);                       
4001a3b0:	92 06 a0 38 	add  %i2, 0x38, %o1                            <== NOT EXECUTED
4001a3b4:	40 00 03 21 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001a3b8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001a3bc:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
  handle->dirty = false;                                              
4001a3c0:	c0 2e a0 38 	clrb  [ %i2 + 0x38 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001a3c4:	c0 26 a0 3c 	clr  [ %i2 + 0x3c ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
4001a3c8:	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);                       
4001a3cc:	92 06 a0 44 	add  %i2, 0x44, %o1                            <== NOT EXECUTED
4001a3d0:	40 00 03 1a 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001a3d4:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
  handle->dirty = false;                                              
4001a3d8:	c0 2e a0 44 	clrb  [ %i2 + 0x44 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001a3dc:	c0 26 a0 48 	clr  [ %i2 + 0x48 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
4001a3e0:	c0 26 a0 4c 	clr  [ %i2 + 0x4c ]                            <== NOT EXECUTED
                                                                      
  return rc;                                                          
}                                                                     
4001a3e4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001a3e8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001ab88 <rtems_rfs_block_map_shrink>: int rtems_rfs_block_map_shrink (rtems_rfs_file_system* fs, rtems_rfs_block_map* map, size_t blocks) {
4001ab88:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BLOCK_MAP_SHRINK))             
4001ab8c:	90 10 20 00 	clr  %o0                                       
4001ab90:	7f ff e2 af 	call  4001364c <rtems_rfs_trace>               
4001ab94:	13 00 00 10 	sethi  %hi(0x4000), %o1                        
4001ab98:	80 a2 20 00 	cmp  %o0, 0                                    
4001ab9c:	22 80 00 08 	be,a   4001abbc <rtems_rfs_block_map_shrink+0x34><== ALWAYS TAKEN
4001aba0:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
    printf ("rtems-rfs: block-map-shrink: entry: blocks=%zd count=%" PRIu32 "\n",
4001aba4:	d4 06 60 08 	ld  [ %i1 + 8 ], %o2                           <== NOT EXECUTED
4001aba8:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001abac:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001abb0:	40 00 1d b6 	call  40022288 <printf>                        <== NOT EXECUTED
4001abb4:	90 12 20 18 	or  %o0, 0x18, %o0                             <== NOT EXECUTED
            blocks, map->size.count);                                 
                                                                      
  if (map->size.count == 0)                                           
4001abb8:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           <== NOT EXECUTED
4001abbc:	80 a0 60 00 	cmp  %g1, 0                                    
4001abc0:	02 80 00 b6 	be  4001ae98 <rtems_rfs_block_map_shrink+0x310>
4001abc4:	80 a6 80 01 	cmp  %i2, %g1                                  
4001abc8:	38 80 00 02 	bgu,a   4001abd0 <rtems_rfs_block_map_shrink+0x48><== NEVER TAKEN
4001abcc:	b4 10 00 01 	mov  %g1, %i2                                  <== 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,
4001abd0:	a4 06 60 44 	add  %i1, 0x44, %l2                            
                                             doubly_singly);          
                                                                      
        /*                                                            
         * Read the singly indirect table and get the block number.   
         */                                                           
        rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001abd4:	a2 06 60 38 	add  %i1, 0x38, %l1                            
4001abd8:	a6 06 60 4c 	add  %i1, 0x4c, %l3                            
4001abdc:	a8 06 60 40 	add  %i1, 0x40, %l4                            
    if (rc > 0)                                                       
      return rc;                                                      
    map->size.count--;                                                
    map->size.offset = 0;                                             
    map->last_data_block = block_to_free;                             
    map->dirty = true;                                                
4001abe0:	aa 10 20 01 	mov  1, %l5                                    
    return 0;                                                         
                                                                      
  if (blocks > map->size.count)                                       
    blocks = map->size.count;                                         
                                                                      
  while (blocks)                                                      
4001abe4:	80 a6 a0 00 	cmp  %i2, 0                                    
4001abe8:	02 80 00 8d 	be  4001ae1c <rtems_rfs_block_map_shrink+0x294>
4001abec:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           
  {                                                                   
    rtems_rfs_block_no block;                                         
    rtems_rfs_block_no block_to_free;                                 
    int                rc;                                            
                                                                      
    block = map->size.count - 1;                                      
4001abf0:	b8 07 7f ff 	add  %i5, -1, %i4                              
                                                                      
    if (block < RTEMS_RFS_INODE_BLOCKS)                               
4001abf4:	80 a7 20 04 	cmp  %i4, 4                                    
4001abf8:	38 80 00 07 	bgu,a   4001ac14 <rtems_rfs_block_map_shrink+0x8c>
4001abfc:	e0 06 20 34 	ld  [ %i0 + 0x34 ], %l0                        
4001ac00:	b9 2f 20 02 	sll  %i4, 2, %i4                               
4001ac04:	b8 06 40 1c 	add  %i1, %i4, %i4                             
    {                                                                 
      /*                                                              
       * We have less than RTEMS_RFS_INODE_BLOCKS so they are held in the
       * inode.                                                       
       */                                                             
      block_to_free = map->blocks[block];                             
4001ac08:	fa 07 20 24 	ld  [ %i4 + 0x24 ], %i5                        
4001ac0c:	10 80 00 76 	b  4001ade4 <rtems_rfs_block_map_shrink+0x25c> 
4001ac10:	c0 27 20 24 	clr  [ %i4 + 0x24 ]                            
       * table of block numbers.                                      
       */                                                             
      rtems_rfs_block_no direct;                                      
      rtems_rfs_block_no singly;                                      
                                                                      
      direct = block % fs->blocks_per_block;                          
4001ac14:	90 10 00 1c 	mov  %i4, %o0                                  
4001ac18:	40 00 4f 79 	call  4002e9fc <.urem>                         
4001ac1c:	92 10 00 10 	mov  %l0, %o1                                  
      singly = block / fs->blocks_per_block;                          
4001ac20:	92 10 00 10 	mov  %l0, %o1                                  
       * table of block numbers.                                      
       */                                                             
      rtems_rfs_block_no direct;                                      
      rtems_rfs_block_no singly;                                      
                                                                      
      direct = block % fs->blocks_per_block;                          
4001ac24:	b6 10 00 08 	mov  %o0, %i3                                  
      singly = block / fs->blocks_per_block;                          
4001ac28:	7f ff 9e 8b 	call  40002654 <.udiv>                         
4001ac2c:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
      if (block < fs->block_map_singly_blocks)                        
4001ac30:	c2 06 20 38 	ld  [ %i0 + 0x38 ], %g1                        
4001ac34:	80 a7 00 01 	cmp  %i4, %g1                                  
4001ac38:	1a 80 00 20 	bcc  4001acb8 <rtems_rfs_block_map_shrink+0x130><== NEVER TAKEN
4001ac3c:	ac 10 00 08 	mov  %o0, %l6                                  
      {                                                               
        /*                                                            
         * Request the indirect block and then obtain the block number from the
         * indirect block.                                            
         */                                                           
        rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001ac40:	82 02 20 08 	add  %o0, 8, %g1                               
4001ac44:	83 28 60 02 	sll  %g1, 2, %g1                               
4001ac48:	82 06 40 01 	add  %i1, %g1, %g1                             
4001ac4c:	d4 00 60 04 	ld  [ %g1 + 4 ], %o2                           
4001ac50:	90 10 00 18 	mov  %i0, %o0                                  
4001ac54:	92 10 00 11 	mov  %l1, %o1                                  
4001ac58:	40 00 01 81 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001ac5c:	96 10 20 01 	mov  1, %o3                                    
                                              map->blocks[singly], true);
        if (rc > 0)                                                   
4001ac60:	80 a2 20 00 	cmp  %o0, 0                                    
4001ac64:	14 80 00 8f 	bg  4001aea0 <rtems_rfs_block_map_shrink+0x318><== NEVER TAKEN
4001ac68:	85 2e e0 02 	sll  %i3, 2, %g2                               
          return rc;                                                  
                                                                      
        block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
4001ac6c:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        
4001ac70:	c6 00 60 1c 	ld  [ %g1 + 0x1c ], %g3                        
                                                    direct);          
                                                                      
        rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
4001ac74:	90 10 00 18 	mov  %i0, %o0                                  
        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,
4001ac78:	82 00 c0 02 	add  %g3, %g2, %g1                             
4001ac7c:	fa 08 c0 02 	ldub  [ %g3 + %g2 ], %i5                       
4001ac80:	c8 08 60 03 	ldub  [ %g1 + 3 ], %g4                         
4001ac84:	c4 08 60 01 	ldub  [ %g1 + 1 ], %g2                         
4001ac88:	c2 08 60 02 	ldub  [ %g1 + 2 ], %g1                         
4001ac8c:	bb 2f 60 18 	sll  %i5, 0x18, %i5                            
4001ac90:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001ac94:	ba 11 00 1d 	or  %g4, %i5, %i5                              
4001ac98:	83 28 60 08 	sll  %g1, 8, %g1                               
4001ac9c:	ba 17 40 02 	or  %i5, %g2, %i5                              
                                                    direct);          
                                                                      
        rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
4001aca0:	92 10 00 19 	mov  %i1, %o1                                  
        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,
4001aca4:	ba 17 40 01 	or  %i5, %g1, %i5                              
                                                    direct);          
                                                                      
        rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->singly_buffer,
4001aca8:	94 10 00 14 	mov  %l4, %o2                                  
4001acac:	96 10 00 16 	mov  %l6, %o3                                  
4001acb0:	10 80 00 48 	b  4001add0 <rtems_rfs_block_map_shrink+0x248> 
4001acb4:	98 10 00 1b 	mov  %i3, %o4                                  
                                                  singly, direct);    
        if (rc)                                                       
          return rc;                                                  
      }                                                               
      else if (block < fs->block_map_doubly_blocks)                   
4001acb8:	c2 06 20 3c 	ld  [ %i0 + 0x3c ], %g1                        <== NOT EXECUTED
4001acbc:	80 a7 00 01 	cmp  %i4, %g1                                  <== NOT EXECUTED
4001acc0:	1a 80 00 58 	bcc  4001ae20 <rtems_rfs_block_map_shrink+0x298><== NOT EXECUTED
4001acc4:	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;                
4001acc8:	7f ff 9e 63 	call  40002654 <.udiv>                         <== NOT EXECUTED
4001accc:	92 10 00 10 	mov  %l0, %o1                                  <== NOT EXECUTED
        doubly_singly = singly % fs->blocks_per_block;                
4001acd0:	92 10 00 10 	mov  %l0, %o1                                  <== 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;                
4001acd4:	ae 10 00 08 	mov  %o0, %l7                                  <== NOT EXECUTED
        doubly_singly = singly % fs->blocks_per_block;                
4001acd8:	40 00 4f 49 	call  4002e9fc <.urem>                         <== NOT EXECUTED
4001acdc:	90 10 00 16 	mov  %l6, %o0                                  <== NOT EXECUTED
                                                                      
        rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
4001ace0:	82 05 e0 08 	add  %l7, 8, %g1                               <== NOT EXECUTED
4001ace4:	83 28 60 02 	sll  %g1, 2, %g1                               <== NOT EXECUTED
4001ace8:	82 06 40 01 	add  %i1, %g1, %g1                             <== NOT EXECUTED
4001acec:	d4 00 60 04 	ld  [ %g1 + 4 ], %o2                           <== 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;                
4001acf0:	a0 10 00 08 	mov  %o0, %l0                                  <== NOT EXECUTED
                                                                      
        rc = rtems_rfs_buffer_handle_request (fs, &map->doubly_buffer,
4001acf4:	92 10 00 12 	mov  %l2, %o1                                  <== NOT EXECUTED
4001acf8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001acfc:	40 00 01 58 	call  4001b25c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
4001ad00:	96 10 20 01 	mov  1, %o3                                    <== NOT EXECUTED
                                              map->blocks[doubly], true);
        if (rc > 0)                                                   
4001ad04:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ad08:	14 80 00 66 	bg  4001aea0 <rtems_rfs_block_map_shrink+0x318><== NOT EXECUTED
4001ad0c:	85 2c 20 02 	sll  %l0, 2, %g2                               <== NOT EXECUTED
          return rc;                                                  
                                                                      
        singly = rtems_rfs_block_get_number (&map->doubly_buffer,     
4001ad10:	c2 06 60 4c 	ld  [ %i1 + 0x4c ], %g1                        <== NOT EXECUTED
4001ad14:	c6 00 60 1c 	ld  [ %g1 + 0x1c ], %g3                        <== NOT EXECUTED
                                             doubly_singly);          
                                                                      
        /*                                                            
         * Read the singly indirect table and get the block number.   
         */                                                           
        rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001ad18:	90 10 00 18 	mov  %i0, %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,     
4001ad1c:	82 00 c0 02 	add  %g3, %g2, %g1                             <== NOT EXECUTED
4001ad20:	f8 08 c0 02 	ldub  [ %g3 + %g2 ], %i4                       <== NOT EXECUTED
4001ad24:	c8 08 60 03 	ldub  [ %g1 + 3 ], %g4                         <== NOT EXECUTED
4001ad28:	c4 08 60 01 	ldub  [ %g1 + 1 ], %g2                         <== NOT EXECUTED
4001ad2c:	c2 08 60 02 	ldub  [ %g1 + 2 ], %g1                         <== NOT EXECUTED
4001ad30:	85 28 a0 10 	sll  %g2, 0x10, %g2                            <== NOT EXECUTED
4001ad34:	83 28 60 08 	sll  %g1, 8, %g1                               <== NOT EXECUTED
4001ad38:	b9 2f 20 18 	sll  %i4, 0x18, %i4                            <== NOT EXECUTED
                                             doubly_singly);          
                                                                      
        /*                                                            
         * Read the singly indirect table and get the block number.   
         */                                                           
        rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001ad3c:	92 10 00 11 	mov  %l1, %o1                                  <== 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,     
4001ad40:	b8 11 00 1c 	or  %g4, %i4, %i4                              <== NOT EXECUTED
                                             doubly_singly);          
                                                                      
        /*                                                            
         * Read the singly indirect table and get the block number.   
         */                                                           
        rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001ad44:	96 10 20 01 	mov  1, %o3                                    <== 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,     
4001ad48:	b8 17 00 02 	or  %i4, %g2, %i4                              <== NOT EXECUTED
4001ad4c:	b8 17 00 01 	or  %i4, %g1, %i4                              <== NOT EXECUTED
                                             doubly_singly);          
                                                                      
        /*                                                            
         * Read the singly indirect table and get the block number.   
         */                                                           
        rc = rtems_rfs_buffer_handle_request (fs, &map->singly_buffer,
4001ad50:	40 00 01 43 	call  4001b25c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
4001ad54:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
                                              singly, true);          
        if (rc > 0)                                                   
4001ad58:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ad5c:	14 80 00 51 	bg  4001aea0 <rtems_rfs_block_map_shrink+0x318><== NOT EXECUTED
4001ad60:	85 2e e0 02 	sll  %i3, 2, %g2                               <== NOT EXECUTED
          return rc;                                                  
                                                                      
        block_to_free = rtems_rfs_block_get_number (&map->singly_buffer,
4001ad64:	c2 06 60 40 	ld  [ %i1 + 0x40 ], %g1                        <== NOT EXECUTED
4001ad68:	c6 00 60 1c 	ld  [ %g1 + 0x1c ], %g3                        <== NOT EXECUTED
                                                    direct);          
                                                                      
        if (direct == 0)                                              
4001ad6c:	80 a6 e0 00 	cmp  %i3, 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,
4001ad70:	82 00 c0 02 	add  %g3, %g2, %g1                             <== NOT EXECUTED
4001ad74:	fa 08 c0 02 	ldub  [ %g3 + %g2 ], %i5                       <== NOT EXECUTED
4001ad78:	c8 08 60 03 	ldub  [ %g1 + 3 ], %g4                         <== NOT EXECUTED
4001ad7c:	c4 08 60 01 	ldub  [ %g1 + 1 ], %g2                         <== NOT EXECUTED
4001ad80:	c2 08 60 02 	ldub  [ %g1 + 2 ], %g1                         <== NOT EXECUTED
4001ad84:	bb 2f 60 18 	sll  %i5, 0x18, %i5                            <== NOT EXECUTED
4001ad88:	85 28 a0 10 	sll  %g2, 0x10, %g2                            <== NOT EXECUTED
4001ad8c:	ba 11 00 1d 	or  %g4, %i5, %i5                              <== NOT EXECUTED
4001ad90:	83 28 60 08 	sll  %g1, 8, %g1                               <== NOT EXECUTED
4001ad94:	ba 17 40 02 	or  %i5, %g2, %i5                              <== NOT EXECUTED
                                                    direct);          
                                                                      
        if (direct == 0)                                              
4001ad98:	12 80 00 13 	bne  4001ade4 <rtems_rfs_block_map_shrink+0x25c><== NOT EXECUTED
4001ad9c:	ba 17 40 01 	or  %i5, %g1, %i5                              <== NOT EXECUTED
        {                                                             
          rc = rtems_rfs_group_bitmap_free (fs, false, singly);       
4001ada0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001ada4:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001ada8:	7f ff db 3c 	call  40011a98 <rtems_rfs_group_bitmap_free>   <== NOT EXECUTED
4001adac:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
          if (rc > 0)                                                 
4001adb0:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001adb4:	14 80 00 3b 	bg  4001aea0 <rtems_rfs_block_map_shrink+0x318><== NOT EXECUTED
4001adb8:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
            return rc;                                                
                                                                      
          map->last_map_block = singly;                               
4001adbc:	f8 26 60 1c 	st  %i4, [ %i1 + 0x1c ]                        <== NOT EXECUTED
                                                                      
          rc = rtems_rfs_block_map_indirect_shrink (fs, map, &map->doubly_buffer,
4001adc0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001adc4:	94 10 00 13 	mov  %l3, %o2                                  <== NOT EXECUTED
4001adc8:	96 10 00 17 	mov  %l7, %o3                                  <== NOT EXECUTED
4001adcc:	98 10 00 10 	mov  %l0, %o4                                  <== NOT EXECUTED
4001add0:	7f ff fc c4 	call  4001a0e0 <rtems_rfs_block_map_indirect_shrink.isra.7>
4001add4:	01 00 00 00 	nop                                            
                                                    doubly, doubly_singly);
          if (rc)                                                     
4001add8:	80 a2 20 00 	cmp  %o0, 0                                    
4001addc:	12 80 00 31 	bne  4001aea0 <rtems_rfs_block_map_shrink+0x318><== NEVER TAKEN
4001ade0:	01 00 00 00 	nop                                            
      {                                                               
        rc = EIO;                                                     
        break;                                                        
      }                                                               
    }                                                                 
    rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);      
4001ade4:	90 10 00 18 	mov  %i0, %o0                                  
4001ade8:	92 10 20 00 	clr  %o1                                       
4001adec:	7f ff db 2b 	call  40011a98 <rtems_rfs_group_bitmap_free>   
4001adf0:	94 10 00 1d 	mov  %i5, %o2                                  
    if (rc > 0)                                                       
4001adf4:	80 a2 20 00 	cmp  %o0, 0                                    
4001adf8:	14 80 00 2a 	bg  4001aea0 <rtems_rfs_block_map_shrink+0x318><== NEVER TAKEN
4001adfc:	b4 06 bf ff 	add  %i2, -1, %i2                              
      return rc;                                                      
    map->size.count--;                                                
4001ae00:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
    map->size.offset = 0;                                             
4001ae04:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
      }                                                               
    }                                                                 
    rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);      
    if (rc > 0)                                                       
      return rc;                                                      
    map->size.count--;                                                
4001ae08:	82 00 7f ff 	add  %g1, -1, %g1                              
    map->size.offset = 0;                                             
    map->last_data_block = block_to_free;                             
4001ae0c:	fa 26 60 20 	st  %i5, [ %i1 + 0x20 ]                        
      }                                                               
    }                                                                 
    rc = rtems_rfs_group_bitmap_free (fs, false, block_to_free);      
    if (rc > 0)                                                       
      return rc;                                                      
    map->size.count--;                                                
4001ae10:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]                           
    map->size.offset = 0;                                             
    map->last_data_block = block_to_free;                             
    map->dirty = true;                                                
4001ae14:	10 bf ff 74 	b  4001abe4 <rtems_rfs_block_map_shrink+0x5c>  
4001ae18:	ea 2e 40 00 	stb  %l5, [ %i1 ]                              
    blocks--;                                                         
  }                                                                   
                                                                      
  if (map->size.count == 0)                                           
4001ae1c:	80 a7 60 00 	cmp  %i5, 0                                    
4001ae20:	32 80 00 05 	bne,a   4001ae34 <rtems_rfs_block_map_shrink+0x2ac>
4001ae24:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
  {                                                                   
    map->last_map_block = 0;                                          
4001ae28:	c0 26 60 1c 	clr  [ %i1 + 0x1c ]                            
    map->last_data_block = 0;                                         
4001ae2c:	c0 26 60 20 	clr  [ %i1 + 0x20 ]                            
  }                                                                   
                                                                      
  /*                                                                  
   * Keep the position inside the map.                                
   */                                                                 
  if (rtems_rfs_block_pos_past_end (&map->bpos, &map->size))          
4001ae30:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
4001ae34:	80 a0 60 00 	cmp  %g1, 0                                    
4001ae38:	02 80 00 06 	be  4001ae50 <rtems_rfs_block_map_shrink+0x2c8>
4001ae3c:	80 a0 40 1d 	cmp  %g1, %i5                                  
4001ae40:	80 a7 60 00 	cmp  %i5, 0                                    
4001ae44:	22 80 00 0e 	be,a   4001ae7c <rtems_rfs_block_map_shrink+0x2f4><== ALWAYS TAKEN
4001ae48:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
4001ae4c:	80 a0 40 1d 	cmp  %g1, %i5                                  <== NOT EXECUTED
4001ae50:	3a 80 00 0b 	bcc,a   4001ae7c <rtems_rfs_block_map_shrink+0x2f4>
4001ae54:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
4001ae58:	84 07 7f ff 	add  %i5, -1, %g2                              
4001ae5c:	80 a0 40 02 	cmp  %g1, %g2                                  
4001ae60:	12 80 00 0e 	bne  4001ae98 <rtems_rfs_block_map_shrink+0x310><== NEVER TAKEN
4001ae64:	01 00 00 00 	nop                                            
4001ae68:	c4 06 60 14 	ld  [ %i1 + 0x14 ], %g2                        
4001ae6c:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
4001ae70:	80 a0 80 01 	cmp  %g2, %g1                                  
4001ae74:	08 80 00 09 	bleu  4001ae98 <rtems_rfs_block_map_shrink+0x310><== NEVER TAKEN
4001ae78:	01 00 00 00 	nop                                            
    rtems_rfs_block_size_get_bpos (&map->size, &map->bpos);           
4001ae7c:	fa 26 60 10 	st  %i5, [ %i1 + 0x10 ]                        
4001ae80:	c2 26 60 14 	st  %g1, [ %i1 + 0x14 ]                        
4001ae84:	80 a0 60 00 	cmp  %g1, 0                                    
4001ae88:	02 80 00 04 	be  4001ae98 <rtems_rfs_block_map_shrink+0x310><== ALWAYS TAKEN
4001ae8c:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            
4001ae90:	ba 07 7f ff 	add  %i5, -1, %i5                              <== NOT EXECUTED
4001ae94:	fa 26 60 10 	st  %i5, [ %i1 + 0x10 ]                        <== NOT EXECUTED
                                                                      
  return 0;                                                           
4001ae98:	81 c7 e0 08 	ret                                            
4001ae9c:	91 e8 20 00 	restore  %g0, 0, %o0                           
}                                                                     
4001aea0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001aea4:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

40020a3c <rtems_rfs_buffer_bdbuf_release>: int rtems_rfs_buffer_bdbuf_release (rtems_rfs_buffer* buffer, bool modified) {
40020a3c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc;                                               
  int               rc = 0;                                           
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_RELEASE))               
40020a40:	90 10 20 00 	clr  %o0                                       
40020a44:	7f ff cb 02 	call  4001364c <rtems_rfs_trace>               
40020a48:	92 10 20 40 	mov  0x40, %o1                                 
40020a4c:	80 a2 20 00 	cmp  %o0, 0                                    
40020a50:	02 80 00 0e 	be  40020a88 <rtems_rfs_buffer_bdbuf_release+0x4c><== ALWAYS TAKEN
40020a54:	80 a6 60 00 	cmp  %i1, 0                                    
    printf ("rtems-rfs: bdbuf-release: block=%" PRIuPTR " bdbuf=%" PRIu32 " %s\n",
40020a58:	d2 06 20 34 	ld  [ %i0 + 0x34 ], %o1                        <== NOT EXECUTED
40020a5c:	02 80 00 05 	be  40020a70 <rtems_rfs_buffer_bdbuf_release+0x34><== NOT EXECUTED
40020a60:	d4 06 20 18 	ld  [ %i0 + 0x18 ], %o2                        <== NOT EXECUTED
40020a64:	17 10 00 d7 	sethi  %hi(0x40035c00), %o3                    <== NOT EXECUTED
40020a68:	10 80 00 04 	b  40020a78 <rtems_rfs_buffer_bdbuf_release+0x3c><== NOT EXECUTED
40020a6c:	96 12 e3 30 	or  %o3, 0x330, %o3	! 40035f30 <status_code_to_errno+0x78><== NOT EXECUTED
40020a70:	17 10 00 d5 	sethi  %hi(0x40035400), %o3                    <== NOT EXECUTED
40020a74:	96 12 e2 c8 	or  %o3, 0x2c8, %o3	! 400356c8 <CSWTCH.1+0xf78><== NOT EXECUTED
40020a78:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
40020a7c:	40 00 06 03 	call  40022288 <printf>                        <== NOT EXECUTED
40020a80:	90 12 23 40 	or  %o0, 0x340, %o0	! 40035f40 <status_code_to_errno+0x88><== NOT EXECUTED
            ((intptr_t) buffer->user),                                
            buffer->block, modified ? "(modified)" : "");             
                                                                      
  if (modified)                                                       
40020a84:	80 a6 60 00 	cmp  %i1, 0                                    <== NOT EXECUTED
40020a88:	02 80 00 06 	be  40020aa0 <rtems_rfs_buffer_bdbuf_release+0x64>
40020a8c:	90 10 00 18 	mov  %i0, %o0                                  
    sc = rtems_bdbuf_release_modified (buffer);                       
40020a90:	7f ff d3 a5 	call  40015924 <rtems_bdbuf_release_modified>  
40020a94:	01 00 00 00 	nop                                            
40020a98:	10 80 00 05 	b  40020aac <rtems_rfs_buffer_bdbuf_release+0x70>
40020a9c:	80 a0 00 08 	cmp  %g0, %o0                                  
  else                                                                
    sc = rtems_bdbuf_release (buffer);                                
40020aa0:	7f ff d3 6c 	call  40015850 <rtems_bdbuf_release>           
40020aa4:	01 00 00 00 	nop                                            
int                                                                   
rtems_rfs_buffer_bdbuf_release (rtems_rfs_buffer* buffer,             
                                bool              modified)           
{                                                                     
  rtems_status_code sc;                                               
  int               rc = 0;                                           
40020aa8:	80 a0 00 08 	cmp  %g0, %o0                                  
40020aac:	b0 60 20 00 	subx  %g0, 0, %i0                              
#endif                                                                
    rc = EIO;                                                         
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
40020ab0:	b0 0e 20 05 	and  %i0, 5, %i0                               
40020ab4:	81 c7 e0 08 	ret                                            
40020ab8:	81 e8 00 00 	restore                                        
40020abc:	40 02 0c c8 	call  400a3ddc <__end+0x5a80c>                 <== NOT EXECUTED
40020ac0:	40 02 0c bc 	call  400a3db0 <__end+0x5a7e0>                 <== NOT EXECUTED
40020ac4:	40 02 0c b0 	call  400a3d84 <__end+0x5a7b4>                 <== NOT EXECUTED
40020ac8:	40 02 0c a4 	call  400a3d58 <__end+0x5a788>                 <== NOT EXECUTED
40020acc:	40 02 0c 9c 	call  400a3d3c <__end+0x5a76c>                 <== NOT EXECUTED
40020ad0:	40 02 0c 90 	call  400a3d10 <__end+0x5a740>                 <== NOT EXECUTED
40020ad4:	40 02 0c 84 	call  400a3ce4 <__end+0x5a714>                 <== NOT EXECUTED
40020ad8:	40 02 0c 78 	call  400a3cb8 <__end+0x5a6e8>                 <== NOT EXECUTED
40020adc:	40 02 0c 70 	call  400a3c9c <__end+0x5a6cc>                 <== NOT EXECUTED
40020ae0:	40 02 0c 64 	call  400a3c70 <__end+0x5a6a0>                 <== NOT EXECUTED
40020ae4:	40 02 0c 58 	call  400a3c44 <__end+0x5a674>                 <== NOT EXECUTED
40020ae8:	40 02 0c 4c 	call  400a3c18 <__end+0x5a648>                 <== NOT EXECUTED
                                                                      

4001b868 <rtems_rfs_buffer_close>: return 0; } int rtems_rfs_buffer_close (rtems_rfs_file_system* fs) {
4001b868:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc = 0;                                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CLOSE))                 
4001b86c:	90 10 20 00 	clr  %o0                                       
4001b870:	7f ff df 77 	call  4001364c <rtems_rfs_trace>               
4001b874:	92 10 20 10 	mov  0x10, %o1                                 
4001b878:	80 a2 20 00 	cmp  %o0, 0                                    
4001b87c:	22 80 00 06 	be,a   4001b894 <rtems_rfs_buffer_close+0x2c>  <== ALWAYS TAKEN
4001b880:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        
    printf ("rtems-rfs: buffer-close: closing\n");                    
4001b884:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001b888:	40 00 1b 0f 	call  400224c4 <puts>                          <== NOT EXECUTED
4001b88c:	90 12 20 f8 	or  %o0, 0xf8, %o0	! 40034cf8 <CSWTCH.1+0x5a8> <== 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));
4001b890:	c2 06 20 10 	ld  [ %i0 + 0x10 ], %g1                        <== NOT EXECUTED
4001b894:	90 10 00 18 	mov  %i0, %o0                                  
4001b898:	7f ff ff b9 	call  4001b77c <rtems_rfs_buffer_setblksize>   
4001b89c:	d2 00 60 20 	ld  [ %g1 + 0x20 ], %o1                        
                                                                      
  if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CLOSE))     
4001b8a0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001b8a4:	04 80 00 0e 	ble  4001b8dc <rtems_rfs_buffer_close+0x74>    <== ALWAYS TAKEN
4001b8a8:	90 10 20 00 	clr  %o0                                       
4001b8ac:	7f ff df 68 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b8b0:	92 10 20 10 	mov  0x10, %o1                                 <== NOT EXECUTED
4001b8b4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b8b8:	02 80 00 09 	be  4001b8dc <rtems_rfs_buffer_close+0x74>     <== NOT EXECUTED
4001b8bc:	01 00 00 00 	nop                                            <== NOT EXECUTED
    printf ("rtems-rfs: buffer-close: set media block size failed: %d: %s\n",
4001b8c0:	40 00 1e b3 	call  4002338c <strerror>                      <== NOT EXECUTED
4001b8c4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001b8c8:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001b8cc:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001b8d0:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001b8d4:	40 00 1a 6d 	call  40022288 <printf>                        <== NOT EXECUTED
4001b8d8:	90 12 21 20 	or  %o0, 0x120, %o0	! 40034d20 <CSWTCH.1+0x5d0><== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
  if (close (fs->device) < 0)                                         
4001b8dc:	7f ff b1 71 	call  40007ea0 <close>                         
4001b8e0:	d0 06 20 0c 	ld  [ %i0 + 0xc ], %o0                         
4001b8e4:	80 a2 20 00 	cmp  %o0, 0                                    
4001b8e8:	16 80 00 12 	bge  4001b930 <rtems_rfs_buffer_close+0xc8>    <== ALWAYS TAKEN
4001b8ec:	01 00 00 00 	nop                                            
  {                                                                   
    rc = errno;                                                       
4001b8f0:	40 00 15 6b 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001b8f4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CLOSE))               
4001b8f8:	92 10 20 10 	mov  0x10, %o1	! 10 <_TLS_Alignment+0xf>       <== NOT EXECUTED
    printf ("rtems-rfs: buffer-close: set media block size failed: %d: %s\n",
            rc, strerror (rc));                                       
                                                                      
  if (close (fs->device) < 0)                                         
  {                                                                   
    rc = errno;                                                       
4001b8fc:	fa 02 00 00 	ld  [ %o0 ], %i5                               <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CLOSE))               
4001b900:	7f ff df 53 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b904:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001b908:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b90c:	02 80 00 09 	be  4001b930 <rtems_rfs_buffer_close+0xc8>     <== NOT EXECUTED
4001b910:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: buffer-close: file close failed: %d: %s\n", 
4001b914:	40 00 1e 9e 	call  4002338c <strerror>                      <== NOT EXECUTED
4001b918:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001b91c:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001b920:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001b924:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001b928:	40 00 1a 58 	call  40022288 <printf>                        <== NOT EXECUTED
4001b92c:	90 12 21 60 	or  %o0, 0x160, %o0	! 40034d60 <CSWTCH.1+0x610><== NOT EXECUTED
              rc, strerror (rc));                                     
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
4001b930:	81 c7 e0 08 	ret                                            
4001b934:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
                                                                      

4001b038 <rtems_rfs_buffer_handle_release>: } int rtems_rfs_buffer_handle_release (rtems_rfs_file_system* fs, rtems_rfs_buffer_handle* handle) {
4001b038:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc = 0;                                                         
                                                                      
  if (rtems_rfs_buffer_handle_has_block (handle))                     
4001b03c:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001b040:	80 a0 60 00 	cmp  %g1, 0                                    
4001b044:	02 80 00 84 	be  4001b254 <rtems_rfs_buffer_handle_release+0x21c>
4001b048:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_RELEASE))      
4001b04c:	90 10 20 00 	clr  %o0                                       
4001b050:	7f ff e1 7f 	call  4001364c <rtems_rfs_trace>               
4001b054:	92 10 22 00 	mov  0x200, %o1                                
4001b058:	80 a2 20 00 	cmp  %o0, 0                                    
4001b05c:	22 80 00 18 	be,a   4001b0bc <rtems_rfs_buffer_handle_release+0x84><== ALWAYS TAKEN
4001b060:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
      printf ("rtems-rfs: buffer-release: block=%" PRIu32 " %s refs=%d %s\n",
4001b064:	c2 0e 40 00 	ldub  [ %i1 ], %g1                             <== NOT EXECUTED
4001b068:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4001b06c:	02 80 00 05 	be  4001b080 <rtems_rfs_buffer_handle_release+0x48><== NOT EXECUTED
4001b070:	d2 06 60 04 	ld  [ %i1 + 4 ], %o1                           <== NOT EXECUTED
4001b074:	15 10 00 d2 	sethi  %hi(0x40034800), %o2                    <== NOT EXECUTED
4001b078:	10 80 00 04 	b  4001b088 <rtems_rfs_buffer_handle_release+0x50><== NOT EXECUTED
4001b07c:	94 12 a0 e0 	or  %o2, 0xe0, %o2	! 400348e0 <CSWTCH.1+0x190> <== NOT EXECUTED
4001b080:	15 10 00 d5 	sethi  %hi(0x40035400), %o2                    <== NOT EXECUTED
4001b084:	94 12 a2 c8 	or  %o2, 0x2c8, %o2	! 400356c8 <CSWTCH.1+0xf78><== 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" : "");
4001b088:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           <== NOT EXECUTED
4001b08c:	d6 00 60 30 	ld  [ %g1 + 0x30 ], %o3                        <== NOT EXECUTED
  int rc = 0;                                                         
                                                                      
  if (rtems_rfs_buffer_handle_has_block (handle))                     
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_RELEASE))      
      printf ("rtems-rfs: buffer-release: block=%" PRIu32 " %s refs=%d %s\n",
4001b090:	80 a2 e0 00 	cmp  %o3, 0                                    <== NOT EXECUTED
4001b094:	32 80 00 05 	bne,a   4001b0a8 <rtems_rfs_buffer_handle_release+0x70><== NOT EXECUTED
4001b098:	19 10 00 d5 	sethi  %hi(0x40035400), %o4                    <== NOT EXECUTED
4001b09c:	19 10 00 d2 	sethi  %hi(0x40034800), %o4                    <== NOT EXECUTED
4001b0a0:	10 80 00 03 	b  4001b0ac <rtems_rfs_buffer_handle_release+0x74><== NOT EXECUTED
4001b0a4:	98 13 20 e8 	or  %o4, 0xe8, %o4	! 400348e8 <CSWTCH.1+0x198> <== NOT EXECUTED
4001b0a8:	98 13 22 c8 	or  %o4, 0x2c8, %o4                            <== NOT EXECUTED
4001b0ac:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b0b0:	40 00 1c 76 	call  40022288 <printf>                        <== NOT EXECUTED
4001b0b4:	90 12 20 f8 	or  %o0, 0xf8, %o0	! 400348f8 <CSWTCH.1+0x1a8> <== 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)                           
4001b0b8:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           <== NOT EXECUTED
4001b0bc:	c4 00 60 30 	ld  [ %g1 + 0x30 ], %g2                        
4001b0c0:	80 a0 a0 00 	cmp  %g2, 0                                    
4001b0c4:	04 80 00 03 	ble  4001b0d0 <rtems_rfs_buffer_handle_release+0x98><== NEVER TAKEN
4001b0c8:	84 00 bf ff 	add  %g2, -1, %g2                              
      rtems_rfs_buffer_refs_down (handle);                            
4001b0cc:	c4 20 60 30 	st  %g2, [ %g1 + 0x30 ]                        
                                                                      
    if (rtems_rfs_buffer_refs (handle) == 0)                          
4001b0d0:	c4 00 60 30 	ld  [ %g1 + 0x30 ], %g2                        
4001b0d4:	80 a0 a0 00 	cmp  %g2, 0                                    
4001b0d8:	12 80 00 5e 	bne  4001b250 <rtems_rfs_buffer_handle_release+0x218>
4001b0dc:	90 10 20 00 	clr  %o0                                       
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
  previous       = the_node->previous;                                
4001b0e0:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4001b0e4:	c6 00 40 00 	ld  [ %g1 ], %g3                               
    {                                                                 
      rtems_chain_extract_unprotected (rtems_rfs_buffer_link (handle));
      fs->buffers_count--;                                            
                                                                      
      if (rtems_rfs_fs_no_local_cache (fs))                           
4001b0e8:	d0 06 00 00 	ld  [ %i0 ], %o0                               
  previous       = the_node->previous;                                
  next->previous = previous;                                          
4001b0ec:	c4 20 e0 04 	st  %g2, [ %g3 + 4 ]                           
  previous->next = next;                                              
4001b0f0:	c6 20 80 00 	st  %g3, [ %g2 ]                               
      rtems_rfs_buffer_refs_down (handle);                            
                                                                      
    if (rtems_rfs_buffer_refs (handle) == 0)                          
    {                                                                 
      rtems_chain_extract_unprotected (rtems_rfs_buffer_link (handle));
      fs->buffers_count--;                                            
4001b0f4:	c4 06 20 50 	ld  [ %i0 + 0x50 ], %g2                        
                                                                      
      if (rtems_rfs_fs_no_local_cache (fs))                           
4001b0f8:	90 8a 20 02 	andcc  %o0, 2, %o0                             
      rtems_rfs_buffer_refs_down (handle);                            
                                                                      
    if (rtems_rfs_buffer_refs (handle) == 0)                          
    {                                                                 
      rtems_chain_extract_unprotected (rtems_rfs_buffer_link (handle));
      fs->buffers_count--;                                            
4001b0fc:	84 00 bf ff 	add  %g2, -1, %g2                              
                                                                      
      if (rtems_rfs_fs_no_local_cache (fs))                           
4001b100:	02 80 00 08 	be  4001b120 <rtems_rfs_buffer_handle_release+0xe8>
4001b104:	c4 26 20 50 	st  %g2, [ %i0 + 0x50 ]                        
      {                                                               
        handle->buffer->user = (void*) 0;                             
        rc = rtems_rfs_buffer_io_release (handle->buffer,             
4001b108:	d2 0e 40 00 	ldub  [ %i1 ], %o1                             
      rtems_chain_extract_unprotected (rtems_rfs_buffer_link (handle));
      fs->buffers_count--;                                            
                                                                      
      if (rtems_rfs_fs_no_local_cache (fs))                           
      {                                                               
        handle->buffer->user = (void*) 0;                             
4001b10c:	c0 20 60 34 	clr  [ %g1 + 0x34 ]                            
        rc = rtems_rfs_buffer_io_release (handle->buffer,             
4001b110:	40 00 16 4b 	call  40020a3c <rtems_rfs_buffer_bdbuf_release>
4001b114:	90 10 00 01 	mov  %g1, %o0                                  
4001b118:	10 80 00 4f 	b  4001b254 <rtems_rfs_buffer_handle_release+0x21c>
4001b11c:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
         * 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 +                                      
4001b120:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1                        
4001b124:	c4 06 20 70 	ld  [ %i0 + 0x70 ], %g2                        
4001b128:	84 00 80 01 	add  %g2, %g1, %g2                             
4001b12c:	c2 06 20 40 	ld  [ %i0 + 0x40 ], %g1                        
4001b130:	80 a0 80 01 	cmp  %g2, %g1                                  
4001b134:	2a 80 00 31 	bcs,a   4001b1f8 <rtems_rfs_buffer_handle_release+0x1c0>
4001b138:	c2 0e 40 00 	ldub  [ %i1 ], %g1                             
             fs->release_modified_count) >= fs->max_held_buffers)     
        {                                                             
          rtems_rfs_buffer* buffer;                                   
          bool              modified;                                 
                                                                      
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_RELEASE))
4001b13c:	90 10 20 00 	clr  %o0                                       
4001b140:	7f ff e1 43 	call  4001364c <rtems_rfs_trace>               
4001b144:	92 10 22 00 	mov  0x200, %o1                                
4001b148:	80 a2 20 00 	cmp  %o0, 0                                    
4001b14c:	22 80 00 09 	be,a   4001b170 <rtems_rfs_buffer_handle_release+0x138><== ALWAYS TAKEN
4001b150:	c4 06 20 60 	ld  [ %i0 + 0x60 ], %g2                        
            printf ("rtems-rfs: buffer-release: local cache overflow:"
4001b154:	d2 06 20 70 	ld  [ %i0 + 0x70 ], %o1                        <== NOT EXECUTED
4001b158:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1                        <== NOT EXECUTED
4001b15c:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b160:	92 02 40 01 	add  %o1, %g1, %o1                             <== NOT EXECUTED
4001b164:	40 00 1c 49 	call  40022288 <printf>                        <== NOT EXECUTED
4001b168:	90 12 21 30 	or  %o0, 0x130, %o0                            <== NOT EXECUTED
                    " %" PRIu32 "\n", fs->release_count + fs->release_modified_count);
                                                                      
          if (fs->release_count > fs->release_modified_count)         
4001b16c:	c4 06 20 60 	ld  [ %i0 + 0x60 ], %g2                        <== NOT EXECUTED
4001b170:	c2 06 20 70 	ld  [ %i0 + 0x70 ], %g1                        
4001b174:	80 a0 80 01 	cmp  %g2, %g1                                  
4001b178:	28 80 00 10 	bleu,a   4001b1b8 <rtems_rfs_buffer_handle_release+0x180>
4001b17c:	d0 06 20 64 	ld  [ %i0 + 0x64 ], %o0                        
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4001b180:	d0 06 20 54 	ld  [ %i0 + 0x54 ], %o0                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4001b184:	82 06 20 58 	add  %i0, 0x58, %g1                            
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4001b188:	80 a2 00 01 	cmp  %o0, %g1                                  
4001b18c:	02 80 00 06 	be  4001b1a4 <rtems_rfs_buffer_handle_release+0x16c><== NEVER TAKEN
4001b190:	86 06 20 54 	add  %i0, 0x54, %g3                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4001b194:	c2 02 00 00 	ld  [ %o0 ], %g1                               
                                                                      
  head->next = new_first;                                             
4001b198:	c2 26 20 54 	st  %g1, [ %i0 + 0x54 ]                        
  new_first->previous = head;                                         
4001b19c:	10 80 00 03 	b  4001b1a8 <rtems_rfs_buffer_handle_release+0x170>
4001b1a0:	c6 20 60 04 	st  %g3, [ %g1 + 4 ]                           
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
    return _Chain_Get_first_unprotected(the_chain);                   
  else                                                                
    return NULL;                                                      
4001b1a4:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
          {                                                           
            buffer = (rtems_rfs_buffer*)                              
              rtems_chain_get_unprotected (&fs->release);             
            fs->release_count--;                                      
4001b1a8:	84 00 bf ff 	add  %g2, -1, %g2                              
            modified = false;                                         
4001b1ac:	92 10 20 00 	clr  %o1                                       
4001b1b0:	10 80 00 0e 	b  4001b1e8 <rtems_rfs_buffer_handle_release+0x1b0>
4001b1b4:	c4 26 20 60 	st  %g2, [ %i0 + 0x60 ]                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4001b1b8:	84 06 20 68 	add  %i0, 0x68, %g2                            
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(              
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
4001b1bc:	80 a2 00 02 	cmp  %o0, %g2                                  
4001b1c0:	02 80 00 06 	be  4001b1d8 <rtems_rfs_buffer_handle_release+0x1a0><== NEVER TAKEN
4001b1c4:	86 06 20 64 	add  %i0, 0x64, %g3                            
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4001b1c8:	c4 02 00 00 	ld  [ %o0 ], %g2                               
                                                                      
  head->next = new_first;                                             
4001b1cc:	c4 26 20 64 	st  %g2, [ %i0 + 0x64 ]                        
  new_first->previous = head;                                         
4001b1d0:	10 80 00 03 	b  4001b1dc <rtems_rfs_buffer_handle_release+0x1a4>
4001b1d4:	c6 20 a0 04 	st  %g3, [ %g2 + 4 ]                           
)                                                                     
{                                                                     
  if ( !_Chain_Is_empty(the_chain))                                   
    return _Chain_Get_first_unprotected(the_chain);                   
  else                                                                
    return NULL;                                                      
4001b1d8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
          }                                                           
          else                                                        
          {                                                           
            buffer = (rtems_rfs_buffer*)                              
              rtems_chain_get_unprotected (&fs->release_modified);    
            fs->release_modified_count--;                             
4001b1dc:	82 00 7f ff 	add  %g1, -1, %g1                              
            modified = true;                                          
4001b1e0:	92 10 20 01 	mov  1, %o1                                    
          }                                                           
          else                                                        
          {                                                           
            buffer = (rtems_rfs_buffer*)                              
              rtems_chain_get_unprotected (&fs->release_modified);    
            fs->release_modified_count--;                             
4001b1e4:	c2 26 20 70 	st  %g1, [ %i0 + 0x70 ]                        
            modified = true;                                          
          }                                                           
          buffer->user = (void*) 0;                                   
4001b1e8:	c0 22 20 34 	clr  [ %o0 + 0x34 ]                            
          rc = rtems_rfs_buffer_io_release (buffer, modified);        
4001b1ec:	40 00 16 14 	call  40020a3c <rtems_rfs_buffer_bdbuf_release>
4001b1f0:	92 0a 60 01 	and  %o1, 1, %o1                               
        }                                                             
                                                                      
        if (rtems_rfs_buffer_dirty (handle))                          
4001b1f4:	c2 0e 40 00 	ldub  [ %i1 ], %g1                             
4001b1f8:	80 a0 60 00 	cmp  %g1, 0                                    
4001b1fc:	02 80 00 0c 	be  4001b22c <rtems_rfs_buffer_handle_release+0x1f4>
4001b200:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4001b204:	c4 06 20 6c 	ld  [ %i0 + 0x6c ], %g2                        
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001b208:	86 06 20 68 	add  %i0, 0x68, %g3                            
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4001b20c:	c6 20 40 00 	st  %g3, [ %g1 ]                               
  tail->previous = the_node;                                          
4001b210:	c2 26 20 6c 	st  %g1, [ %i0 + 0x6c ]                        
  old_last->next = the_node;                                          
4001b214:	c2 20 80 00 	st  %g1, [ %g2 ]                               
  the_node->previous = old_last;                                      
4001b218:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
        {                                                             
          rtems_chain_append_unprotected (&fs->release_modified,      
                                          rtems_rfs_buffer_link (handle));
          fs->release_modified_count++;                               
4001b21c:	c2 06 20 70 	ld  [ %i0 + 0x70 ], %g1                        
4001b220:	82 00 60 01 	inc  %g1                                       
4001b224:	10 80 00 0b 	b  4001b250 <rtems_rfs_buffer_handle_release+0x218>
4001b228:	c2 26 20 70 	st  %g1, [ %i0 + 0x70 ]                        
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4001b22c:	c4 06 20 5c 	ld  [ %i0 + 0x5c ], %g2                        
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001b230:	86 06 20 58 	add  %i0, 0x58, %g3                            
  Chain_Node *old_last = tail->previous;                              
                                                                      
  the_node->next = tail;                                              
4001b234:	c6 20 40 00 	st  %g3, [ %g1 ]                               
  tail->previous = the_node;                                          
4001b238:	c2 26 20 5c 	st  %g1, [ %i0 + 0x5c ]                        
  old_last->next = the_node;                                          
4001b23c:	c2 20 80 00 	st  %g1, [ %g2 ]                               
  the_node->previous = old_last;                                      
4001b240:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
        }                                                             
        else                                                          
        {                                                             
          rtems_chain_append_unprotected (&fs->release,               
                                          rtems_rfs_buffer_link (handle));
          fs->release_count++;                                        
4001b244:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1                        
4001b248:	82 00 60 01 	inc  %g1                                       
4001b24c:	c2 26 20 60 	st  %g1, [ %i0 + 0x60 ]                        
        }                                                             
      }                                                               
    }                                                                 
    handle->buffer = NULL;                                            
4001b250:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
4001b254:	81 c7 e0 08 	ret                                            
4001b258:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001b25c <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) {
4001b25c:	9d e3 bf a0 	save  %sp, -96, %sp                            
                                                                      
  /*                                                                  
   * 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))                     
4001b260:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001b264:	80 a0 60 00 	cmp  %g1, 0                                    
4001b268:	02 80 00 1a 	be  4001b2d0 <rtems_rfs_buffer_handle_request+0x74>
4001b26c:	ba 10 00 18 	mov  %i0, %i5                                  
  {                                                                   
    /*                                                                
     * Treat block 0 as special to handle the loading of the super block.
     */                                                               
    if (block && (rtems_rfs_buffer_bnum (handle) == block))           
4001b270:	80 a6 a0 00 	cmp  %i2, 0                                    
4001b274:	02 80 00 06 	be  4001b28c <rtems_rfs_buffer_handle_request+0x30><== NEVER TAKEN
4001b278:	90 10 20 00 	clr  %o0                                       
4001b27c:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
4001b280:	80 a0 40 1a 	cmp  %g1, %i2                                  
4001b284:	02 80 00 77 	be  4001b460 <rtems_rfs_buffer_handle_request+0x204>
4001b288:	b0 10 20 00 	clr  %i0                                       
      return 0;                                                       
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))      
4001b28c:	7f ff e0 f0 	call  4001364c <rtems_rfs_trace>               
4001b290:	92 10 21 00 	mov  0x100, %o1                                
4001b294:	80 a2 20 00 	cmp  %o0, 0                                    
4001b298:	22 80 00 07 	be,a   4001b2b4 <rtems_rfs_buffer_handle_request+0x58><== ALWAYS TAKEN
4001b29c:	90 10 00 1d 	mov  %i5, %o0                                  
      printf ("rtems-rfs: buffer-request: handle has buffer: %" PRIu32 "\n",
4001b2a0:	d2 06 60 04 	ld  [ %i1 + 4 ], %o1                           <== NOT EXECUTED
4001b2a4:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b2a8:	40 00 1b f8 	call  40022288 <printf>                        <== NOT EXECUTED
4001b2ac:	90 12 21 78 	or  %o0, 0x178, %o0	! 40034978 <CSWTCH.1+0x228><== NOT EXECUTED
              rtems_rfs_buffer_bnum (handle));                        
                                                                      
    rc = rtems_rfs_buffer_handle_release (fs, handle);                
4001b2b0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001b2b4:	7f ff ff 61 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001b2b8:	92 10 00 19 	mov  %i1, %o1                                  
    if (rc > 0)                                                       
4001b2bc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001b2c0:	14 80 00 8f 	bg  4001b4fc <rtems_rfs_buffer_handle_request+0x2a0><== NEVER TAKEN
4001b2c4:	01 00 00 00 	nop                                            
      return rc;                                                      
    handle->dirty = false;                                            
4001b2c8:	c0 2e 40 00 	clrb  [ %i1 ]                                  
    handle->bnum = 0;                                                 
4001b2cc:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
  }                                                                   
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))        
4001b2d0:	90 10 20 00 	clr  %o0                                       
4001b2d4:	7f ff e0 de 	call  4001364c <rtems_rfs_trace>               
4001b2d8:	92 10 21 00 	mov  0x100, %o1                                
4001b2dc:	80 a2 20 00 	cmp  %o0, 0                                    
4001b2e0:	22 80 00 07 	be,a   4001b2fc <rtems_rfs_buffer_handle_request+0xa0><== ALWAYS TAKEN
4001b2e4:	c2 07 60 50 	ld  [ %i5 + 0x50 ], %g1                        
    printf ("rtems-rfs: buffer-request: block=%" PRIu32 "\n", block); 
4001b2e8:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b2ec:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001b2f0:	40 00 1b e6 	call  40022288 <printf>                        <== NOT EXECUTED
4001b2f4:	90 12 21 b0 	or  %o0, 0x1b0, %o0                            <== 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)                                              
4001b2f8:	c2 07 60 50 	ld  [ %i5 + 0x50 ], %g1                        <== NOT EXECUTED
4001b2fc:	80 a0 60 00 	cmp  %g1, 0                                    
4001b300:	22 80 00 16 	be,a   4001b358 <rtems_rfs_buffer_handle_request+0xfc>
4001b304:	c2 07 40 00 	ld  [ %i5 ], %g1                               
  {                                                                   
    /*                                                                
     * Check the active buffer list for shared buffers.               
     */                                                               
    handle->buffer = rtems_rfs_scan_chain (&fs->buffers,              
4001b308:	90 07 60 44 	add  %i5, 0x44, %o0                            
4001b30c:	92 07 60 50 	add  %i5, 0x50, %o1                            
4001b310:	7f ff fe ea 	call  4001aeb8 <rtems_rfs_scan_chain>          
4001b314:	94 10 00 1a 	mov  %i2, %o2                                  
                                           &fs->buffers_count,        
                                           block);                    
    if (rtems_rfs_buffer_handle_has_block (handle) &&                 
4001b318:	80 a2 20 00 	cmp  %o0, 0                                    
4001b31c:	02 80 00 0e 	be  4001b354 <rtems_rfs_buffer_handle_request+0xf8>
4001b320:	d0 26 60 08 	st  %o0, [ %i1 + 8 ]                           
        rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))      
4001b324:	90 10 20 00 	clr  %o0                                       
4001b328:	7f ff e0 c9 	call  4001364c <rtems_rfs_trace>               
4001b32c:	92 10 21 00 	mov  0x100, %o1                                
     * 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) &&                 
4001b330:	80 a2 20 00 	cmp  %o0, 0                                    
4001b334:	22 80 00 09 	be,a   4001b358 <rtems_rfs_buffer_handle_request+0xfc><== ALWAYS TAKEN
4001b338:	c2 07 40 00 	ld  [ %i5 ], %g1                               
        rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))      
      printf ("rtems-rfs: buffer-request: buffer shared: refs: %d\n", 
              rtems_rfs_buffer_refs (handle) + 1);                    
4001b33c:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           <== NOT EXECUTED
    handle->buffer = rtems_rfs_scan_chain (&fs->buffers,              
                                           &fs->buffers_count,        
                                           block);                    
    if (rtems_rfs_buffer_handle_has_block (handle) &&                 
        rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))      
      printf ("rtems-rfs: buffer-request: buffer shared: refs: %d\n", 
4001b340:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b344:	d2 00 60 30 	ld  [ %g1 + 0x30 ], %o1                        <== NOT EXECUTED
4001b348:	90 12 21 d8 	or  %o0, 0x1d8, %o0                            <== NOT EXECUTED
4001b34c:	40 00 1b cf 	call  40022288 <printf>                        <== NOT EXECUTED
4001b350:	92 02 60 01 	inc  %o1                                       <== 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) &&                            
4001b354:	c2 07 40 00 	ld  [ %i5 ], %g1                               
4001b358:	80 88 60 02 	btst  2, %g1                                   
4001b35c:	12 80 00 20 	bne  4001b3dc <rtems_rfs_buffer_handle_request+0x180>
4001b360:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001b364:	80 a0 60 00 	cmp  %g1, 0                                    
4001b368:	12 80 00 43 	bne  4001b474 <rtems_rfs_buffer_handle_request+0x218>
4001b36c:	01 00 00 00 	nop                                            
      !rtems_rfs_buffer_handle_has_block (handle))                    
  {                                                                   
    /*                                                                
     * Check the local cache of released buffers.                     
     */                                                               
    if (fs->release_count)                                            
4001b370:	c2 07 60 60 	ld  [ %i5 + 0x60 ], %g1                        
4001b374:	80 a0 60 00 	cmp  %g1, 0                                    
4001b378:	22 80 00 08 	be,a   4001b398 <rtems_rfs_buffer_handle_request+0x13c>
4001b37c:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
      handle->buffer = rtems_rfs_scan_chain (&fs->release,            
4001b380:	90 07 60 54 	add  %i5, 0x54, %o0                            
4001b384:	92 07 60 60 	add  %i5, 0x60, %o1                            
4001b388:	7f ff fe cc 	call  4001aeb8 <rtems_rfs_scan_chain>          
4001b38c:	94 10 00 1a 	mov  %i2, %o2                                  
4001b390:	d0 26 60 08 	st  %o0, [ %i1 + 8 ]                           
                                             &fs->release_count,      
                                             block);                  
                                                                      
    if (!rtems_rfs_buffer_handle_has_block (handle) &&                
4001b394:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001b398:	80 a0 60 00 	cmp  %g1, 0                                    
4001b39c:	32 80 00 10 	bne,a   4001b3dc <rtems_rfs_buffer_handle_request+0x180>
4001b3a0:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001b3a4:	c2 07 60 70 	ld  [ %i5 + 0x70 ], %g1                        
4001b3a8:	80 a0 60 00 	cmp  %g1, 0                                    
4001b3ac:	22 80 00 0c 	be,a   4001b3dc <rtems_rfs_buffer_handle_request+0x180>
4001b3b0:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
        fs->release_modified_count)                                   
    {                                                                 
      handle->buffer = rtems_rfs_scan_chain (&fs->release_modified,   
4001b3b4:	90 07 60 64 	add  %i5, 0x64, %o0                            
4001b3b8:	92 07 60 70 	add  %i5, 0x70, %o1                            
4001b3bc:	7f ff fe bf 	call  4001aeb8 <rtems_rfs_scan_chain>          
4001b3c0:	94 10 00 1a 	mov  %i2, %o2                                  
                                             &fs->release_modified_count,
                                             block);                  
      /*                                                              
       * If we found a buffer retain the dirty buffer state.          
       */                                                             
      if (rtems_rfs_buffer_handle_has_block (handle))                 
4001b3c4:	80 a2 20 00 	cmp  %o0, 0                                    
4001b3c8:	02 80 00 04 	be  4001b3d8 <rtems_rfs_buffer_handle_request+0x17c>
4001b3cc:	d0 26 60 08 	st  %o0, [ %i1 + 8 ]                           
        rtems_rfs_buffer_mark_dirty (handle);                         
4001b3d0:	82 10 20 01 	mov  1, %g1                                    
4001b3d4:	c2 2e 40 00 	stb  %g1, [ %i1 ]                              
  }                                                                   
                                                                      
  /*                                                                  
   * If not located we request the buffer from the I/O layer.         
   */                                                                 
  if (!rtems_rfs_buffer_handle_has_block (handle))                    
4001b3d8:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
4001b3dc:	80 a0 60 00 	cmp  %g1, 0                                    
4001b3e0:	32 80 00 25 	bne,a   4001b474 <rtems_rfs_buffer_handle_request+0x218>
4001b3e4:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
  {                                                                   
    rc = rtems_rfs_buffer_io_request (fs, block, read, &handle->buffer);
4001b3e8:	90 10 00 1d 	mov  %i5, %o0                                  
4001b3ec:	92 10 00 1a 	mov  %i2, %o1                                  
4001b3f0:	94 10 00 1b 	mov  %i3, %o2                                  
4001b3f4:	40 00 15 81 	call  400209f8 <rtems_rfs_buffer_bdbuf_request>
4001b3f8:	96 06 60 08 	add  %i1, 8, %o3                               
                                                                      
    if (rc > 0)                                                       
4001b3fc:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001b400:	04 80 00 1a 	ble  4001b468 <rtems_rfs_buffer_handle_request+0x20c><== ALWAYS TAKEN
4001b404:	90 10 20 00 	clr  %o0                                       
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))    
4001b408:	92 10 21 00 	mov  0x100, %o1                                <== NOT EXECUTED
4001b40c:	7f ff e0 90 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b410:	b0 10 00 1c 	mov  %i4, %i0                                  <== NOT EXECUTED
4001b414:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b418:	02 80 00 12 	be  4001b460 <rtems_rfs_buffer_handle_request+0x204><== NOT EXECUTED
4001b41c:	80 a6 e0 00 	cmp  %i3, 0                                    <== NOT EXECUTED
        printf ("rtems-rfs: buffer-request: block=%" PRIu32 ": bdbuf-%s: %d: %s\n",
4001b420:	22 80 00 05 	be,a   4001b434 <rtems_rfs_buffer_handle_request+0x1d8><== NOT EXECUTED
4001b424:	3b 10 00 d2 	sethi  %hi(0x40034800), %i5                    <== NOT EXECUTED
4001b428:	3b 10 00 d2 	sethi  %hi(0x40034800), %i5                    <== NOT EXECUTED
4001b42c:	10 80 00 03 	b  4001b438 <rtems_rfs_buffer_handle_request+0x1dc><== NOT EXECUTED
4001b430:	ba 17 61 68 	or  %i5, 0x168, %i5	! 40034968 <CSWTCH.1+0x218><== NOT EXECUTED
4001b434:	ba 17 61 70 	or  %i5, 0x170, %i5                            <== NOT EXECUTED
4001b438:	40 00 1f d5 	call  4002338c <strerror>                      <== NOT EXECUTED
4001b43c:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
4001b440:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001b444:	98 10 00 08 	mov  %o0, %o4                                  <== NOT EXECUTED
4001b448:	94 10 00 1d 	mov  %i5, %o2                                  <== NOT EXECUTED
4001b44c:	96 10 00 1c 	mov  %i4, %o3                                  <== NOT EXECUTED
4001b450:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b454:	b0 10 00 1c 	mov  %i4, %i0                                  <== NOT EXECUTED
4001b458:	40 00 1b 8c 	call  40022288 <printf>                        <== NOT EXECUTED
4001b45c:	90 12 22 10 	or  %o0, 0x210, %o0                            <== NOT EXECUTED
4001b460:	81 c7 e0 08 	ret                                            
4001b464:	81 e8 00 00 	restore                                        
                block, read ? "read" : "get", rc, strerror (rc));     
      return rc;                                                      
    }                                                                 
                                                                      
    rtems_chain_set_off_chain (rtems_rfs_buffer_link(handle));        
4001b468:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
4001b46c:	c0 20 40 00 	clr  [ %g1 ]                                   
  }                                                                   
                                                                      
  /*                                                                  
   * Increase the reference count of the buffer.                      
   */                                                                 
  rtems_rfs_buffer_refs_up (handle);                                  
4001b470:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001b474:	86 07 60 48 	add  %i5, 0x48, %g3                            
4001b478:	c4 00 60 30 	ld  [ %g1 + 0x30 ], %g2                        
  fs->buffers_count++;                                                
                                                                      
  handle->buffer->user = (void*) ((intptr_t) block);                  
  handle->bnum = block;                                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))        
4001b47c:	90 10 20 00 	clr  %o0                                       
  }                                                                   
                                                                      
  /*                                                                  
   * Increase the reference count of the buffer.                      
   */                                                                 
  rtems_rfs_buffer_refs_up (handle);                                  
4001b480:	84 00 a0 01 	inc  %g2                                       
4001b484:	c4 20 60 30 	st  %g2, [ %g1 + 0x30 ]                        
  Chain_Node *old_last = tail->previous;                              
4001b488:	c4 07 60 4c 	ld  [ %i5 + 0x4c ], %g2                        
                                                                      
  the_node->next = tail;                                              
4001b48c:	c6 20 40 00 	st  %g3, [ %g1 ]                               
  tail->previous = the_node;                                          
4001b490:	c2 27 60 4c 	st  %g1, [ %i5 + 0x4c ]                        
  old_last->next = the_node;                                          
4001b494:	c2 20 80 00 	st  %g1, [ %g2 ]                               
  the_node->previous = old_last;                                      
4001b498:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
  rtems_chain_append_unprotected (&fs->buffers,                       
                                  rtems_rfs_buffer_link (handle));    
  fs->buffers_count++;                                                
4001b49c:	c4 07 60 50 	ld  [ %i5 + 0x50 ], %g2                        
                                                                      
  handle->buffer->user = (void*) ((intptr_t) block);                  
  handle->bnum = block;                                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))        
4001b4a0:	92 10 21 00 	mov  0x100, %o1                                
   * Increase the reference count of the buffer.                      
   */                                                                 
  rtems_rfs_buffer_refs_up (handle);                                  
  rtems_chain_append_unprotected (&fs->buffers,                       
                                  rtems_rfs_buffer_link (handle));    
  fs->buffers_count++;                                                
4001b4a4:	84 00 a0 01 	inc  %g2                                       
4001b4a8:	c4 27 60 50 	st  %g2, [ %i5 + 0x50 ]                        
                                                                      
  handle->buffer->user = (void*) ((intptr_t) block);                  
4001b4ac:	f4 20 60 34 	st  %i2, [ %g1 + 0x34 ]                        
  handle->bnum = block;                                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))        
4001b4b0:	7f ff e0 67 	call  4001364c <rtems_rfs_trace>               
4001b4b4:	f4 26 60 04 	st  %i2, [ %i1 + 4 ]                           
4001b4b8:	80 a2 20 00 	cmp  %o0, 0                                    
4001b4bc:	02 80 00 0f 	be  4001b4f8 <rtems_rfs_buffer_handle_request+0x29c><== ALWAYS TAKEN
4001b4c0:	80 a6 e0 00 	cmp  %i3, 0                                    
    printf ("rtems-rfs: buffer-request: block=%" PRIu32 " bdbuf-%s=%" PRIu32 " refs=%d\n",
4001b4c4:	22 80 00 05 	be,a   4001b4d8 <rtems_rfs_buffer_handle_request+0x27c><== NOT EXECUTED
4001b4c8:	15 10 00 d2 	sethi  %hi(0x40034800), %o2                    <== NOT EXECUTED
4001b4cc:	15 10 00 d2 	sethi  %hi(0x40034800), %o2                    <== NOT EXECUTED
4001b4d0:	10 80 00 03 	b  4001b4dc <rtems_rfs_buffer_handle_request+0x280><== NOT EXECUTED
4001b4d4:	94 12 a1 68 	or  %o2, 0x168, %o2	! 40034968 <CSWTCH.1+0x218><== NOT EXECUTED
4001b4d8:	94 12 a1 70 	or  %o2, 0x170, %o2                            <== NOT EXECUTED
            block, read ? "read" : "get", handle->buffer->block,      
4001b4dc:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           <== NOT EXECUTED
                                                                      
  handle->buffer->user = (void*) ((intptr_t) block);                  
  handle->bnum = block;                                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_HANDLE_REQUEST))        
    printf ("rtems-rfs: buffer-request: block=%" PRIu32 " bdbuf-%s=%" PRIu32 " refs=%d\n",
4001b4e0:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b4e4:	d6 00 60 18 	ld  [ %g1 + 0x18 ], %o3                        <== NOT EXECUTED
4001b4e8:	d8 00 60 30 	ld  [ %g1 + 0x30 ], %o4                        <== NOT EXECUTED
4001b4ec:	90 12 22 48 	or  %o0, 0x248, %o0                            <== NOT EXECUTED
4001b4f0:	40 00 1b 66 	call  40022288 <printf>                        <== NOT EXECUTED
4001b4f4:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
            block, read ? "read" : "get", handle->buffer->block,      
            handle->buffer->references);                              
                                                                      
  return 0;                                                           
4001b4f8:	b0 10 20 00 	clr  %i0                                       
}                                                                     
4001b4fc:	81 c7 e0 08 	ret                                            
4001b500:	81 e8 00 00 	restore                                        
                                                                      

4001b504 <rtems_rfs_buffer_open>: return rc; } int rtems_rfs_buffer_open (const char* name, rtems_rfs_file_system* fs) {
4001b504:	9d e3 bf 58 	save  %sp, -168, %sp                           
  struct stat st;                                                     
#if RTEMS_RFS_USE_LIBBLOCK                                            
  int rv;                                                             
#endif                                                                
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))                  
4001b508:	90 10 20 00 	clr  %o0                                       
4001b50c:	7f ff e0 50 	call  4001364c <rtems_rfs_trace>               
4001b510:	92 10 20 20 	mov  0x20, %o1                                 
4001b514:	80 a2 20 00 	cmp  %o0, 0                                    
4001b518:	22 80 00 07 	be,a   4001b534 <rtems_rfs_buffer_open+0x30>   <== ALWAYS TAKEN
4001b51c:	90 10 00 18 	mov  %i0, %o0                                  
    printf ("rtems-rfs: buffer-open: opening: %s\n", name);           
4001b520:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b524:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001b528:	40 00 1b 58 	call  40022288 <printf>                        <== NOT EXECUTED
4001b52c:	90 12 22 88 	or  %o0, 0x288, %o0                            <== NOT EXECUTED
                                                                      
  fs->device = open (name, O_RDWR);                                   
4001b530:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001b534:	7f ff b5 b7 	call  40008c10 <open>                          
4001b538:	92 10 20 02 	mov  2, %o1                                    
  if (fs->device < 0)                                                 
4001b53c:	80 a2 20 00 	cmp  %o0, 0                                    
4001b540:	16 80 00 0d 	bge  4001b574 <rtems_rfs_buffer_open+0x70>     <== ALWAYS TAKEN
4001b544:	d0 26 60 0c 	st  %o0, [ %i1 + 0xc ]                         
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_OPEN))                
4001b548:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001b54c:	7f ff e0 40 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b550:	92 10 20 08 	mov  8, %o1                                    <== NOT EXECUTED
4001b554:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b558:	02 80 00 05 	be  4001b56c <rtems_rfs_buffer_open+0x68>      <== NOT EXECUTED
4001b55c:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
      printf ("rtems-rfs: buffer-open: cannot open file\n");          
4001b560:	90 12 22 b0 	or  %o0, 0x2b0, %o0	! 40034ab0 <CSWTCH.1+0x360><== NOT EXECUTED
4001b564:	40 00 1b d8 	call  400224c4 <puts>                          <== NOT EXECUTED
4001b568:	01 00 00 00 	nop                                            <== NOT EXECUTED
    return ENXIO;                                                     
4001b56c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001b570:	91 e8 20 06 	restore  %g0, 6, %o0                           <== NOT EXECUTED
  }                                                                   
                                                                      
  if (fstat (fs->device, &st) < 0)                                    
4001b574:	7f ff b2 98 	call  40007fd4 <fstat>                         
4001b578:	92 07 bf b8 	add  %fp, -72, %o1                             
4001b57c:	80 a2 20 00 	cmp  %o0, 0                                    
4001b580:	16 80 00 12 	bge  4001b5c8 <rtems_rfs_buffer_open+0xc4>     <== ALWAYS TAKEN
4001b584:	c4 07 bf c4 	ld  [ %fp + -60 ], %g2                         
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_OPEN))                
4001b588:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001b58c:	7f ff e0 30 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b590:	92 10 20 08 	mov  8, %o1                                    <== NOT EXECUTED
4001b594:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b598:	02 bf ff f5 	be  4001b56c <rtems_rfs_buffer_open+0x68>      <== NOT EXECUTED
4001b59c:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: buffer-open: stat '%s' failed: %s\n",       
              name, strerror (errno));                                
4001b5a0:	40 00 16 3f 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001b5a4:	01 00 00 00 	nop                                            <== NOT EXECUTED
  }                                                                   
                                                                      
  if (fstat (fs->device, &st) < 0)                                    
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_OPEN))                
      printf ("rtems-rfs: buffer-open: stat '%s' failed: %s\n",       
4001b5a8:	40 00 1f 79 	call  4002338c <strerror>                      <== NOT EXECUTED
4001b5ac:	d0 02 00 00 	ld  [ %o0 ], %o0                               <== NOT EXECUTED
4001b5b0:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001b5b4:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001b5b8:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b5bc:	40 00 1b 33 	call  40022288 <printf>                        <== NOT EXECUTED
4001b5c0:	90 12 22 e0 	or  %o0, 0x2e0, %o0	! 40034ae0 <CSWTCH.1+0x390><== NOT EXECUTED
4001b5c4:	30 bf ff ea 	b,a   4001b56c <rtems_rfs_buffer_open+0x68>    <== NOT EXECUTED
                                                                      
#if RTEMS_RFS_USE_LIBBLOCK                                            
  /*                                                                  
   * Is the device a block device ?                                   
   */                                                                 
  if (!S_ISBLK (st.st_mode))                                          
4001b5c8:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
4001b5cc:	84 08 80 01 	and  %g2, %g1, %g2                             
4001b5d0:	03 00 00 18 	sethi  %hi(0x6000), %g1                        
4001b5d4:	80 a0 80 01 	cmp  %g2, %g1                                  
4001b5d8:	22 80 00 0c 	be,a   4001b608 <rtems_rfs_buffer_open+0x104>  <== ALWAYS TAKEN
4001b5dc:	d0 06 60 0c 	ld  [ %i1 + 0xc ], %o0                         
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_OPEN))                
4001b5e0:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001b5e4:	7f ff e0 1a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b5e8:	92 10 20 08 	mov  8, %o1                                    <== NOT EXECUTED
4001b5ec:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b5f0:	02 bf ff df 	be  4001b56c <rtems_rfs_buffer_open+0x68>      <== NOT EXECUTED
4001b5f4:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
      printf ("rtems-rfs: buffer-open: '%s' is not a block device\n", name);
4001b5f8:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001b5fc:	40 00 1b 23 	call  40022288 <printf>                        <== NOT EXECUTED
4001b600:	90 12 23 10 	or  %o0, 0x310, %o0                            <== NOT EXECUTED
4001b604:	30 bf ff da 	b,a   4001b56c <rtems_rfs_buffer_open+0x68>    <== NOT EXECUTED
static inline int rtems_disk_fd_get_disk_device(                      
  int fd,                                                             
  rtems_disk_device **dd_ptr                                          
)                                                                     
{                                                                     
  return ioctl(fd, RTEMS_BLKIO_GETDISKDEV, dd_ptr);                   
4001b608:	13 10 01 10 	sethi  %hi(0x40044000), %o1                    
4001b60c:	94 06 60 10 	add  %i1, 0x10, %o2                            
4001b610:	7f ff b2 c1 	call  40008114 <ioctl>                         
4001b614:	92 12 62 09 	or  %o1, 0x209, %o1                            
4001b618:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
  /*                                                                  
   * Check that device is registred as a block device and lock it.    
   */                                                                 
  rv = rtems_disk_fd_get_disk_device (fs->device, &fs->disk);         
  if (rv != 0)                                                        
4001b61c:	80 a6 20 00 	cmp  %i0, 0                                    
4001b620:	02 80 00 09 	be  4001b644 <rtems_rfs_buffer_open+0x140>     <== ALWAYS TAKEN
4001b624:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_OPEN))                
4001b628:	7f ff e0 09 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b62c:	92 10 20 08 	mov  8, %o1                                    <== NOT EXECUTED
4001b630:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b634:	02 bf ff ce 	be  4001b56c <rtems_rfs_buffer_open+0x68>      <== NOT EXECUTED
4001b638:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
      printf ("rtems-rfs: buffer-open: cannot obtain the disk\n");    
4001b63c:	10 bf ff ca 	b  4001b564 <rtems_rfs_buffer_open+0x60>       <== NOT EXECUTED
4001b640:	90 12 23 48 	or  %o0, 0x348, %o0	! 40034b48 <CSWTCH.1+0x3f8><== NOT EXECUTED
#else                                                                 
  fs->media_size = st.st_size;                                        
  strcat (fs->name, name);                                            
#endif                                                                
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))                  
4001b644:	7f ff e0 02 	call  4001364c <rtems_rfs_trace>               
4001b648:	92 10 20 20 	mov  0x20, %o1                                 
4001b64c:	80 a2 20 00 	cmp  %o0, 0                                    
4001b650:	02 80 00 07 	be  4001b66c <rtems_rfs_buffer_open+0x168>     <== ALWAYS TAKEN
4001b654:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    
    printf ("rtems-rfs: buffer-open: blks=%" PRId32 ", blk-size=%" PRId32 "\n",
            rtems_rfs_fs_media_blocks (fs),                           
4001b658:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        <== NOT EXECUTED
  fs->media_size = st.st_size;                                        
  strcat (fs->name, name);                                            
#endif                                                                
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))                  
    printf ("rtems-rfs: buffer-open: blks=%" PRId32 ", blk-size=%" PRId32 "\n",
4001b65c:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1                        <== NOT EXECUTED
4001b660:	d4 00 60 20 	ld  [ %g1 + 0x20 ], %o2                        <== NOT EXECUTED
4001b664:	40 00 1b 09 	call  40022288 <printf>                        <== NOT EXECUTED
4001b668:	90 12 23 78 	or  %o0, 0x378, %o0                            <== NOT EXECUTED
            rtems_rfs_fs_media_blocks (fs),                           
            rtems_rfs_fs_media_block_size (fs));                      
                                                                      
  return 0;                                                           
}                                                                     
4001b66c:	81 c7 e0 08 	ret                                            
4001b670:	81 e8 00 00 	restore                                        
                                                                      

4001b77c <rtems_rfs_buffer_setblksize>: return result; } int rtems_rfs_buffer_setblksize (rtems_rfs_file_system* fs, size_t size) {
4001b77c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc;                                                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))            
4001b780:	90 10 20 00 	clr  %o0                                       
  return result;                                                      
}                                                                     
                                                                      
int                                                                   
rtems_rfs_buffer_setblksize (rtems_rfs_file_system* fs, size_t size)  
{                                                                     
4001b784:	f2 27 a0 48 	st  %i1, [ %fp + 0x48 ]                        
  int rc;                                                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))            
4001b788:	7f ff df b1 	call  4001364c <rtems_rfs_trace>               
4001b78c:	92 10 24 00 	mov  0x400, %o1                                
4001b790:	80 a2 20 00 	cmp  %o0, 0                                    
4001b794:	02 80 00 05 	be  4001b7a8 <rtems_rfs_buffer_setblksize+0x2c><== ALWAYS TAKEN
4001b798:	d2 07 a0 48 	ld  [ %fp + 0x48 ], %o1                        
    printf ("rtems-rfs: buffer-setblksize: block size: %zu\n", size); 
4001b79c:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001b7a0:	40 00 1a ba 	call  40022288 <printf>                        <== NOT EXECUTED
4001b7a4:	90 12 20 48 	or  %o0, 0x48, %o0	! 40034c48 <CSWTCH.1+0x4f8> <== NOT EXECUTED
                                                                      
  rc = rtems_rfs_buffers_release (fs);                                
4001b7a8:	7f ff ff d5 	call  4001b6fc <rtems_rfs_buffers_release>     
4001b7ac:	90 10 00 18 	mov  %i0, %o0                                  
  if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))
4001b7b0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001b7b4:	04 80 00 0e 	ble  4001b7ec <rtems_rfs_buffer_setblksize+0x70><== ALWAYS TAKEN
4001b7b8:	90 10 20 00 	clr  %o0                                       
4001b7bc:	7f ff df a4 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b7c0:	92 10 24 00 	mov  0x400, %o1                                <== NOT EXECUTED
4001b7c4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b7c8:	02 80 00 09 	be  4001b7ec <rtems_rfs_buffer_setblksize+0x70><== NOT EXECUTED
4001b7cc:	01 00 00 00 	nop                                            <== NOT EXECUTED
    printf ("rtems-rfs: buffer-setblksize: buffer release failed: %d: %s\n",
4001b7d0:	40 00 1e ef 	call  4002338c <strerror>                      <== NOT EXECUTED
4001b7d4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001b7d8:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001b7dc:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001b7e0:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001b7e4:	40 00 1a a9 	call  40022288 <printf>                        <== NOT EXECUTED
4001b7e8:	90 12 20 78 	or  %o0, 0x78, %o0	! 40034c78 <CSWTCH.1+0x528> <== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
  rc = rtems_rfs_buffer_sync (fs);                                    
4001b7ec:	7f ff ff a2 	call  4001b674 <rtems_rfs_buffer_sync>         
4001b7f0:	90 10 00 18 	mov  %i0, %o0                                  
  if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SETBLKSIZE))
4001b7f4:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001b7f8:	04 80 00 0e 	ble  4001b830 <rtems_rfs_buffer_setblksize+0xb4><== ALWAYS TAKEN
4001b7fc:	90 10 20 00 	clr  %o0                                       
4001b800:	7f ff df 93 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b804:	92 10 24 00 	mov  0x400, %o1                                <== NOT EXECUTED
4001b808:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b80c:	22 80 00 0a 	be,a   4001b834 <rtems_rfs_buffer_setblksize+0xb8><== NOT EXECUTED
4001b810:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        <== NOT EXECUTED
    printf ("rtems-rfs: buffer-setblksize: device sync failed: %d: %s\n",
4001b814:	40 00 1e de 	call  4002338c <strerror>                      <== NOT EXECUTED
4001b818:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001b81c:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001b820:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001b824:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001b828:	40 00 1a 98 	call  40022288 <printf>                        <== NOT EXECUTED
4001b82c:	90 12 20 b8 	or  %o0, 0xb8, %o0	! 40034cb8 <CSWTCH.1+0x568> <== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
#if RTEMS_RFS_USE_LIBBLOCK                                            
  rc = fs->disk->ioctl (fs->disk, RTEMS_BLKIO_SETBLKSIZE, &size);     
4001b830:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        
4001b834:	13 20 01 10 	sethi  %hi(0x80044000), %o1                    
4001b838:	c2 02 20 38 	ld  [ %o0 + 0x38 ], %g1                        
4001b83c:	92 12 62 04 	or  %o1, 0x204, %o1                            
4001b840:	9f c0 40 00 	call  %g1                                      
4001b844:	94 07 a0 48 	add  %fp, 0x48, %o2                            
  if (rc < 0)                                                         
4001b848:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001b84c:	16 80 00 05 	bge  4001b860 <rtems_rfs_buffer_setblksize+0xe4><== ALWAYS TAKEN
4001b850:	01 00 00 00 	nop                                            
    rc = errno;                                                       
4001b854:	40 00 15 92 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001b858:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001b85c:	f0 02 00 00 	ld  [ %o0 ], %i0                               <== NOT EXECUTED
#endif                                                                
  return rc;                                                          
}                                                                     
4001b860:	81 c7 e0 08 	ret                                            
4001b864:	81 e8 00 00 	restore                                        
                                                                      

4001b674 <rtems_rfs_buffer_sync>: return rc; } int rtems_rfs_buffer_sync (rtems_rfs_file_system* fs) {
4001b674:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int result = 0;                                                     
#if RTEMS_RFS_USE_LIBBLOCK                                            
  rtems_status_code sc;                                               
#endif                                                                
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))                  
4001b678:	90 10 20 00 	clr  %o0                                       
4001b67c:	7f ff df f4 	call  4001364c <rtems_rfs_trace>               
4001b680:	92 10 20 20 	mov  0x20, %o1                                 
4001b684:	80 a2 20 00 	cmp  %o0, 0                                    
4001b688:	22 80 00 06 	be,a   4001b6a0 <rtems_rfs_buffer_sync+0x2c>   <== ALWAYS TAKEN
4001b68c:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        
    printf ("rtems-rfs: buffer-sync: syncing\n");                     
4001b690:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b694:	40 00 1b 8c 	call  400224c4 <puts>                          <== NOT EXECUTED
4001b698:	90 12 23 a8 	or  %o0, 0x3a8, %o0	! 40034ba8 <CSWTCH.1+0x458><== 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));                
4001b69c:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        <== NOT EXECUTED
4001b6a0:	7f ff e8 bd 	call  40015994 <rtems_bdbuf_syncdev>           
4001b6a4:	ba 10 20 00 	clr  %i5                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
4001b6a8:	80 a2 20 00 	cmp  %o0, 0                                    
4001b6ac:	02 80 00 0f 	be  4001b6e8 <rtems_rfs_buffer_sync+0x74>      <== ALWAYS TAKEN
4001b6b0:	b8 10 00 08 	mov  %o0, %i4                                  
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_SYNC))                
4001b6b4:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001b6b8:	92 10 20 20 	mov  0x20, %o1                                 <== NOT EXECUTED
4001b6bc:	7f ff df e4 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b6c0:	ba 10 20 05 	mov  5, %i5                                    <== NOT EXECUTED
4001b6c4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b6c8:	22 80 00 09 	be,a   4001b6ec <rtems_rfs_buffer_sync+0x78>   <== NOT EXECUTED
4001b6cc:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        <== NOT EXECUTED
      printf ("rtems-rfs: buffer-sync: device sync failed: %s\n",     
4001b6d0:	7f ff f2 27 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
4001b6d4:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
4001b6d8:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4001b6dc:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b6e0:	40 00 1a ea 	call  40022288 <printf>                        <== NOT EXECUTED
4001b6e4:	90 12 23 c8 	or  %o0, 0x3c8, %o0	! 40034bc8 <CSWTCH.1+0x478><== NOT EXECUTED
              rtems_status_text (sc));                                
    result = EIO;                                                     
  }                                                                   
  rtems_disk_release (fs->disk);                                      
4001b6e8:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        
4001b6ec:	7f ff a5 41 	call  40004bf0 <rtems_disk_release>            
4001b6f0:	b0 10 00 1d 	mov  %i5, %i0                                  
      printf ("rtems-rfs: buffer-sync: file sync failed: %d: %s\n",   
              result, strerror (result));                             
  }                                                                   
#endif                                                                
  return result;                                                      
}                                                                     
4001b6f4:	81 c7 e0 08 	ret                                            
4001b6f8:	81 e8 00 00 	restore                                        
                                                                      

4001b6fc <rtems_rfs_buffers_release>: return rrc; } int rtems_rfs_buffers_release (rtems_rfs_file_system* fs) {
4001b6fc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rrc = 0;                                                        
  int rc;                                                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_RELEASE))               
4001b700:	90 10 20 00 	clr  %o0                                       
4001b704:	92 10 20 40 	mov  0x40, %o1                                 
4001b708:	7f ff df d1 	call  4001364c <rtems_rfs_trace>               
4001b70c:	ba 10 00 18 	mov  %i0, %i5                                  
4001b710:	80 a2 20 00 	cmp  %o0, 0                                    
4001b714:	02 80 00 09 	be  4001b738 <rtems_rfs_buffers_release+0x3c>  <== ALWAYS TAKEN
4001b718:	92 07 60 60 	add  %i5, 0x60, %o1                            
    printf ("rtems-rfs: buffers-release: active:%" PRIu32 " "         
4001b71c:	d2 06 20 50 	ld  [ %i0 + 0x50 ], %o1                        <== NOT EXECUTED
4001b720:	d4 06 20 60 	ld  [ %i0 + 0x60 ], %o2                        <== NOT EXECUTED
4001b724:	d6 06 20 70 	ld  [ %i0 + 0x70 ], %o3                        <== NOT EXECUTED
4001b728:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001b72c:	40 00 1a d7 	call  40022288 <printf>                        <== NOT EXECUTED
4001b730:	90 12 23 f8 	or  %o0, 0x3f8, %o0	! 40034bf8 <CSWTCH.1+0x4a8><== NOT EXECUTED
            "release:%" PRIu32 " release-modified:%" PRIu32 "\n",     
            fs->buffers_count, fs->release_count, fs->release_modified_count);
                                                                      
  rc = rtems_rfs_release_chain (&fs->release,                         
4001b734:	92 07 60 60 	add  %i5, 0x60, %o1                            <== NOT EXECUTED
4001b738:	94 10 20 00 	clr  %o2                                       
4001b73c:	7f ff fe 1b 	call  4001afa8 <rtems_rfs_release_chain>       
4001b740:	90 07 60 54 	add  %i5, 0x54, %o0                            
4001b744:	82 38 00 08 	xnor  %g0, %o0, %g1                            
4001b748:	83 38 60 1f 	sra  %g1, 0x1f, %g1                            
                                &fs->release_count,                   
                                false);                               
  if ((rc > 0) && (rrc == 0))                                         
    rrc = rc;                                                         
  rc = rtems_rfs_release_chain (&fs->release_modified,                
4001b74c:	92 07 60 70 	add  %i5, 0x70, %o1                            
4001b750:	b0 0a 00 01 	and  %o0, %g1, %i0                             
4001b754:	94 10 20 01 	mov  1, %o2                                    
4001b758:	7f ff fe 14 	call  4001afa8 <rtems_rfs_release_chain>       
4001b75c:	90 07 60 64 	add  %i5, 0x64, %o0                            
                                &fs->release_modified_count,          
                                true);                                
  if ((rc > 0) && (rrc == 0))                                         
4001b760:	80 a6 20 00 	cmp  %i0, 0                                    
4001b764:	12 80 00 04 	bne  4001b774 <rtems_rfs_buffers_release+0x78> <== NEVER TAKEN
4001b768:	80 a2 20 00 	cmp  %o0, 0                                    
4001b76c:	34 80 00 02 	bg,a   4001b774 <rtems_rfs_buffers_release+0x78><== NEVER TAKEN
4001b770:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
    rrc = rc;                                                         
                                                                      
  return rrc;                                                         
}                                                                     
4001b774:	81 c7 e0 08 	ret                                            
4001b778:	81 e8 00 00 	restore                                        
                                                                      

4001be48 <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) {
4001be48:	9d e3 bf 30 	save  %sp, -208, %sp                           
  rtems_rfs_block_map     map;                                        
  rtems_rfs_block_pos     bpos;                                       
  rtems_rfs_buffer_handle buffer;                                     
  int                     rc;                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))                
4001be4c:	90 10 20 00 	clr  %o0                                       
4001be50:	13 08 00 00 	sethi  %hi(0x20000000), %o1                    
4001be54:	7f ff dd fe 	call  4001364c <rtems_rfs_trace>               
4001be58:	a0 10 00 18 	mov  %i0, %l0                                  
4001be5c:	80 a2 20 00 	cmp  %o0, 0                                    
4001be60:	02 80 00 14 	be  4001beb0 <rtems_rfs_dir_add_entry+0x68>    <== ALWAYS TAKEN
4001be64:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: dir-add-entry: dir=%" PRId32 ", name=",       
4001be68:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001be6c:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001be70:	ba 10 00 1a 	mov  %i2, %i5                                  <== NOT EXECUTED
4001be74:	90 12 20 68 	or  %o0, 0x68, %o0                             <== NOT EXECUTED
4001be78:	40 00 19 04 	call  40022288 <printf>                        <== NOT EXECUTED
4001be7c:	b0 06 80 1b 	add  %i2, %i3, %i0                             <== NOT EXECUTED
            rtems_rfs_inode_ino (dir));                               
    for (c = 0; c < length; c++)                                      
4001be80:	80 a7 40 18 	cmp  %i5, %i0                                  <== NOT EXECUTED
4001be84:	02 80 00 07 	be  4001bea0 <rtems_rfs_dir_add_entry+0x58>    <== NOT EXECUTED
4001be88:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
      printf ("%c", name[c]);                                         
4001be8c:	d0 4f 40 00 	ldsb  [ %i5 ], %o0                             <== NOT EXECUTED
4001be90:	40 00 19 64 	call  40022420 <putchar>                       <== NOT EXECUTED
4001be94:	ba 07 60 01 	inc  %i5                                       <== NOT EXECUTED
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))                
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: dir-add-entry: dir=%" PRId32 ", name=",       
            rtems_rfs_inode_ino (dir));                               
    for (c = 0; c < length; c++)                                      
4001be98:	10 bf ff fb 	b  4001be84 <rtems_rfs_dir_add_entry+0x3c>     <== NOT EXECUTED
4001be9c:	80 a7 40 18 	cmp  %i5, %i0                                  <== NOT EXECUTED
      printf ("%c", name[c]);                                         
    printf (", len=%zd\n", length);                                   
4001bea0:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001bea4:	40 00 18 f9 	call  40022288 <printf>                        <== NOT EXECUTED
4001bea8:	90 12 20 98 	or  %o0, 0x98, %o0                             <== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_block_map_open (fs, dir, &map);                      
4001beac:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001beb0:	92 10 00 19 	mov  %i1, %o1                                  
4001beb4:	7f ff f8 f0 	call  4001a274 <rtems_rfs_block_map_open>      
4001beb8:	94 07 bf b0 	add  %fp, -80, %o2                             
  if (rc > 0)                                                         
4001bebc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001bec0:	14 80 00 95 	bg  4001c114 <rtems_rfs_dir_add_entry+0x2cc>   <== NEVER TAKEN
4001bec4:	29 00 00 3f 	sethi  %hi(0xfc00), %l4                        
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001bec8:	c0 2f bf a4 	clrb  [ %fp + -92 ]                            
  handle->bnum  = 0;                                                  
4001becc:	c0 27 bf a8 	clr  [ %fp + -88 ]                             
  handle->buffer = NULL;                                              
4001bed0:	c0 27 bf ac 	clr  [ %fp + -84 ]                             
 * @param[in] bpos is a pointer to the block position.                
 */                                                                   
static inline void                                                    
rtems_rfs_block_set_bpos_zero (rtems_rfs_block_pos* bpos)             
{                                                                     
  bpos->bno = 0;                                                      
4001bed4:	c0 27 bf 98 	clr  [ %fp + -104 ]                            
  bpos->boff = 0;                                                     
4001bed8:	c0 27 bf 9c 	clr  [ %fp + -100 ]                            
  bpos->block = 0;                                                    
4001bedc:	c0 27 bf a0 	clr  [ %fp + -96 ]                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001bee0:	a8 15 23 ff 	or  %l4, 0x3ff, %l4                            
      {                                                               
        if ((length + RTEMS_RFS_DIR_ENTRY_SIZE) <                     
4001bee4:	a4 06 e0 0a 	add  %i3, 0xa, %l2                             
    /*                                                                
     * 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);          
4001bee8:	90 10 00 10 	mov  %l0, %o0                                  
4001beec:	92 07 bf b0 	add  %fp, -80, %o1                             
4001bef0:	94 07 bf 98 	add  %fp, -104, %o2                            
4001bef4:	7f ff f9 b2 	call  4001a5bc <rtems_rfs_block_map_find>      
4001bef8:	96 07 bf 94 	add  %fp, -108, %o3                            
    if (rc > 0)                                                       
4001befc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001bf00:	04 80 00 29 	ble  4001bfa4 <rtems_rfs_dir_add_entry+0x15c>  
4001bf04:	80 a6 20 06 	cmp  %i0, 6                                    
    {                                                                 
      if (rc != ENXIO)                                                
4001bf08:	02 80 00 0f 	be  4001bf44 <rtems_rfs_dir_add_entry+0xfc>    <== ALWAYS TAKEN
4001bf0c:	90 10 00 10 	mov  %l0, %o0                                  
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))          
4001bf10:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001bf14:	7f ff dd ce 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bf18:	13 08 00 00 	sethi  %hi(0x20000000), %o1                    <== NOT EXECUTED
4001bf1c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bf20:	22 80 00 a4 	be,a   4001c1b0 <rtems_rfs_dir_add_entry+0x368><== NOT EXECUTED
4001bf24:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
          printf ("rtems-rfs: dir-add-entry: "                        
4001bf28:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           <== NOT EXECUTED
4001bf2c:	40 00 1d 18 	call  4002338c <strerror>                      <== NOT EXECUTED
4001bf30:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001bf34:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001bf38:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001bf3c:	10 80 00 15 	b  4001bf90 <rtems_rfs_dir_add_entry+0x148>    <== NOT EXECUTED
4001bf40:	90 12 20 a8 	or  %o0, 0xa8, %o0	! 400350a8 <CSWTCH.1+0x958> <== NOT EXECUTED
      }                                                               
                                                                      
      /*                                                              
       * We have reached the end of the directory so add a block.     
       */                                                             
      rc = rtems_rfs_block_map_grow (fs, &map, 1, &block);            
4001bf44:	92 07 bf b0 	add  %fp, -80, %o1                             
4001bf48:	94 10 20 01 	mov  1, %o2                                    
4001bf4c:	7f ff fa 25 	call  4001a7e0 <rtems_rfs_block_map_grow>      
4001bf50:	96 07 bf 94 	add  %fp, -108, %o3                            
      if (rc > 0)                                                     
4001bf54:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001bf58:	04 80 00 14 	ble  4001bfa8 <rtems_rfs_dir_add_entry+0x160>  <== ALWAYS TAKEN
4001bf5c:	a2 10 20 00 	clr  %l1                                       
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))          
4001bf60:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001bf64:	7f ff dd ba 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bf68:	13 08 00 00 	sethi  %hi(0x20000000), %o1                    <== NOT EXECUTED
4001bf6c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bf70:	22 80 00 90 	be,a   4001c1b0 <rtems_rfs_dir_add_entry+0x368><== NOT EXECUTED
4001bf74:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
          printf ("rtems-rfs: dir-add-entry: "                        
4001bf78:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           <== NOT EXECUTED
4001bf7c:	40 00 1d 04 	call  4002338c <strerror>                      <== NOT EXECUTED
4001bf80:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001bf84:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001bf88:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001bf8c:	90 12 20 f0 	or  %o0, 0xf0, %o0	! 400350f0 <CSWTCH.1+0x9a0> <== NOT EXECUTED
4001bf90:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001bf94:	40 00 18 bd 	call  40022288 <printf>                        <== NOT EXECUTED
4001bf98:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
      entry  += elength;                                              
      offset += elength;                                              
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001bf9c:	10 80 00 85 	b  4001c1b0 <rtems_rfs_dir_add_entry+0x368>    <== NOT EXECUTED
4001bfa0:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
4001bfa4:	a2 10 20 01 	mov  1, %l1                                    
      }                                                               
                                                                      
      read = false;                                                   
    }                                                                 
                                                                      
    bpos.bno++;                                                       
4001bfa8:	c2 07 bf 98 	ld  [ %fp + -104 ], %g1                        
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, read);  
4001bfac:	d4 07 bf 94 	ld  [ %fp + -108 ], %o2                        
      }                                                               
                                                                      
      read = false;                                                   
    }                                                                 
                                                                      
    bpos.bno++;                                                       
4001bfb0:	82 00 60 01 	inc  %g1                                       
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, read);  
4001bfb4:	a2 0c 60 ff 	and  %l1, 0xff, %l1                            
      }                                                               
                                                                      
      read = false;                                                   
    }                                                                 
                                                                      
    bpos.bno++;                                                       
4001bfb8:	c2 27 bf 98 	st  %g1, [ %fp + -104 ]                        
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, read);  
4001bfbc:	90 10 00 10 	mov  %l0, %o0                                  
4001bfc0:	92 07 bf a4 	add  %fp, -92, %o1                             
4001bfc4:	7f ff fc a6 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001bfc8:	96 10 00 11 	mov  %l1, %o3                                  
    if (rc > 0)                                                       
4001bfcc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001bfd0:	04 80 00 0f 	ble  4001c00c <rtems_rfs_dir_add_entry+0x1c4>  <== ALWAYS TAKEN
4001bfd4:	c2 07 bf ac 	ld  [ %fp + -84 ], %g1                         
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))            
4001bfd8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001bfdc:	7f ff dd 9c 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bfe0:	13 08 00 00 	sethi  %hi(0x20000000), %o1                    <== NOT EXECUTED
4001bfe4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bfe8:	22 80 00 72 	be,a   4001c1b0 <rtems_rfs_dir_add_entry+0x368><== NOT EXECUTED
4001bfec:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
        printf ("rtems-rfs: dir-add-entry: "                          
4001bff0:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           <== NOT EXECUTED
4001bff4:	40 00 1c e6 	call  4002338c <strerror>                      <== NOT EXECUTED
4001bff8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001bffc:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001c000:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c004:	10 bf ff e3 	b  4001bf90 <rtems_rfs_dir_add_entry+0x148>    <== NOT EXECUTED
4001c008:	90 12 21 38 	or  %o0, 0x138, %o0	! 40035138 <CSWTCH.1+0x9e8><== NOT EXECUTED
      break;                                                          
    }                                                                 
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
                                                                      
    if (!read)                                                        
4001c00c:	80 a4 60 00 	cmp  %l1, 0                                    
4001c010:	12 80 00 06 	bne  4001c028 <rtems_rfs_dir_add_entry+0x1e0>  
4001c014:	fa 00 60 1c 	ld  [ %g1 + 0x1c ], %i5                        
      memset (entry, 0xff, rtems_rfs_fs_block_size (fs));             
4001c018:	d4 04 20 08 	ld  [ %l0 + 8 ], %o2                           
4001c01c:	90 10 00 1d 	mov  %i5, %o0                                  
4001c020:	40 00 18 21 	call  400220a4 <memset>                        
4001c024:	92 10 20 ff 	mov  0xff, %o1                                 
                                                                      
    offset = 0;                                                       
                                                                      
    while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c028:	c2 04 20 08 	ld  [ %l0 + 8 ], %g1                           
    entry  = rtems_rfs_buffer_data (&buffer);                         
                                                                      
    if (!read)                                                        
      memset (entry, 0xff, rtems_rfs_fs_block_size (fs));             
                                                                      
    offset = 0;                                                       
4001c02c:	a2 10 20 00 	clr  %l1                                       
                                                                      
    while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c030:	84 00 7f f6 	add  %g1, -10, %g2                             
4001c034:	80 a4 40 02 	cmp  %l1, %g2                                  
4001c038:	1a bf ff ad 	bcc  4001beec <rtems_rfs_dir_add_entry+0xa4>   <== NEVER TAKEN
4001c03c:	90 10 00 10 	mov  %l0, %o0                                  
    {                                                                 
      rtems_rfs_ino eino;                                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
4001c040:	c6 0f 60 09 	ldub  [ %i5 + 9 ], %g3                         
4001c044:	f0 0f 60 08 	ldub  [ %i5 + 8 ], %i0                         
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c048:	e6 0f 40 00 	ldub  [ %i5 ], %l3                             
    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);                   
4001c04c:	b1 2e 20 08 	sll  %i0, 8, %i0                               
4001c050:	b0 16 00 03 	or  %i0, %g3, %i0                              
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c054:	c6 0f 60 01 	ldub  [ %i5 + 1 ], %g3                         
4001c058:	a7 2c e0 18 	sll  %l3, 0x18, %l3                            
4001c05c:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
4001c060:	a6 14 c0 03 	or  %l3, %g3, %l3                              
4001c064:	c6 0f 60 03 	ldub  [ %i5 + 3 ], %g3                         
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c068:	80 a6 00 14 	cmp  %i0, %l4                                  
    {                                                                 
      rtems_rfs_ino eino;                                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c06c:	a6 14 c0 03 	or  %l3, %g3, %l3                              
4001c070:	c6 0f 60 02 	ldub  [ %i5 + 2 ], %g3                         
4001c074:	87 28 e0 08 	sll  %g3, 8, %g3                               
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c078:	12 80 00 29 	bne  4001c11c <rtems_rfs_dir_add_entry+0x2d4>  
4001c07c:	a6 14 c0 03 	or  %l3, %g3, %l3                              
      {                                                               
        if ((length + RTEMS_RFS_DIR_ENTRY_SIZE) <                     
            (rtems_rfs_fs_block_size (fs) - offset))                  
4001c080:	a2 20 40 11 	sub  %g1, %l1, %l1                             
      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) <                     
4001c084:	80 a4 80 11 	cmp  %l2, %l1                                  
4001c088:	1a bf ff 9a 	bcc  4001bef0 <rtems_rfs_dir_add_entry+0xa8>   <== NEVER TAKEN
4001c08c:	92 07 bf b0 	add  %fp, -80, %o1                             
            (rtems_rfs_fs_block_size (fs) - offset))                  
        {                                                             
          uint32_t hash;                                              
          hash = rtems_rfs_dir_hash (name, length);                   
4001c090:	92 10 00 1b 	mov  %i3, %o1                                  
4001c094:	40 00 12 96 	call  40020aec <rtems_rfs_dir_hash>            
4001c098:	90 10 00 1a 	mov  %i2, %o0                                  
          rtems_rfs_dir_set_entry_hash (entry, hash);                 
4001c09c:	83 32 20 18 	srl  %o0, 0x18, %g1                            
4001c0a0:	c2 2f 60 04 	stb  %g1, [ %i5 + 4 ]                          
4001c0a4:	83 32 20 10 	srl  %o0, 0x10, %g1                            
4001c0a8:	c2 2f 60 05 	stb  %g1, [ %i5 + 5 ]                          
4001c0ac:	83 32 20 08 	srl  %o0, 8, %g1                               
4001c0b0:	c2 2f 60 06 	stb  %g1, [ %i5 + 6 ]                          
          rtems_rfs_dir_set_entry_ino (entry, ino);                   
4001c0b4:	83 37 20 18 	srl  %i4, 0x18, %g1                            
4001c0b8:	c2 2f 40 00 	stb  %g1, [ %i5 ]                              
4001c0bc:	83 37 20 10 	srl  %i4, 0x10, %g1                            
4001c0c0:	c2 2f 60 01 	stb  %g1, [ %i5 + 1 ]                          
4001c0c4:	83 37 20 08 	srl  %i4, 8, %g1                               
4001c0c8:	c2 2f 60 02 	stb  %g1, [ %i5 + 2 ]                          
          rtems_rfs_dir_set_entry_length (entry,                      
4001c0cc:	83 34 a0 08 	srl  %l2, 8, %g1                               
                                          RTEMS_RFS_DIR_ENTRY_SIZE + length);
          memcpy (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length);    
4001c0d0:	94 10 00 1b 	mov  %i3, %o2                                  
        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);                 
4001c0d4:	d0 2f 60 07 	stb  %o0, [ %i5 + 7 ]                          
          rtems_rfs_dir_set_entry_ino (entry, ino);                   
          rtems_rfs_dir_set_entry_length (entry,                      
4001c0d8:	c2 2f 60 08 	stb  %g1, [ %i5 + 8 ]                          
                                          RTEMS_RFS_DIR_ENTRY_SIZE + length);
          memcpy (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length);    
4001c0dc:	92 10 00 1a 	mov  %i2, %o1                                  
            (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);                 
          rtems_rfs_dir_set_entry_ino (entry, ino);                   
4001c0e0:	f8 2f 60 03 	stb  %i4, [ %i5 + 3 ]                          
          rtems_rfs_dir_set_entry_length (entry,                      
4001c0e4:	e4 2f 60 09 	stb  %l2, [ %i5 + 9 ]                          
                                          RTEMS_RFS_DIR_ENTRY_SIZE + length);
          memcpy (entry + RTEMS_RFS_DIR_ENTRY_SIZE, name, length);    
4001c0e8:	40 00 17 5c 	call  40021e58 <memcpy>                        
4001c0ec:	90 07 60 0a 	add  %i5, 0xa, %o0                             
          rtems_rfs_buffer_mark_dirty (&buffer);                      
4001c0f0:	82 10 20 01 	mov  1, %g1                                    
          rtems_rfs_buffer_handle_close (fs, &buffer);                
4001c0f4:	92 07 bf a4 	add  %fp, -92, %o1                             
          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);                      
4001c0f8:	c2 2f bf a4 	stb  %g1, [ %fp + -92 ]                        
          rtems_rfs_buffer_handle_close (fs, &buffer);                
4001c0fc:	7f ff fe 0f 	call  4001b938 <rtems_rfs_buffer_handle_close> 
4001c100:	90 10 00 10 	mov  %l0, %o0                                  
          rtems_rfs_block_map_close (fs, &map);                       
4001c104:	90 10 00 10 	mov  %l0, %o0                                  
4001c108:	92 07 bf b0 	add  %fp, -80, %o1                             
4001c10c:	7f ff f8 b8 	call  4001a3ec <rtems_rfs_block_map_close>     
4001c110:	b0 10 20 00 	clr  %i0                                       
          return 0;                                                   
4001c114:	81 c7 e0 08 	ret                                            
4001c118:	81 e8 00 00 	restore                                        
        }                                                             
                                                                      
        break;                                                        
      }                                                               
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
4001c11c:	80 a6 20 0a 	cmp  %i0, 0xa                                  
4001c120:	04 80 00 0d 	ble  4001c154 <rtems_rfs_dir_add_entry+0x30c>  <== NEVER TAKEN
4001c124:	90 10 20 00 	clr  %o0                                       
4001c128:	c6 04 20 1c 	ld  [ %l0 + 0x1c ], %g3                        
4001c12c:	80 a6 00 03 	cmp  %i0, %g3                                  
4001c130:	1a 80 00 09 	bcc  4001c154 <rtems_rfs_dir_add_entry+0x30c>  <== NEVER TAKEN
4001c134:	80 a4 e0 00 	cmp  %l3, 0                                    
4001c138:	02 80 00 07 	be  4001c154 <rtems_rfs_dir_add_entry+0x30c>   <== NEVER TAKEN
4001c13c:	01 00 00 00 	nop                                            
4001c140:	c6 04 20 14 	ld  [ %l0 + 0x14 ], %g3                        
4001c144:	80 a4 c0 03 	cmp  %l3, %g3                                  
4001c148:	28 80 00 18 	bleu,a   4001c1a8 <rtems_rfs_dir_add_entry+0x360><== ALWAYS TAKEN
4001c14c:	ba 07 40 18 	add  %i5, %i0, %i5                             
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_ADD_ENTRY))          
4001c150:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001c154:	7f ff dd 3e 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001c158:	13 08 00 00 	sethi  %hi(0x20000000), %o1                    <== NOT EXECUTED
4001c15c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001c160:	02 80 00 0a 	be  4001c188 <rtems_rfs_dir_add_entry+0x340>   <== NOT EXECUTED
4001c164:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
          printf ("rtems-rfs: dir-add-entry: "                        
4001c168:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001c16c:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c170:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
4001c174:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
4001c178:	96 10 00 13 	mov  %l3, %o3                                  <== NOT EXECUTED
4001c17c:	40 00 18 43 	call  40022288 <printf>                        <== NOT EXECUTED
4001c180:	98 10 00 11 	mov  %l1, %o4                                  <== NOT EXECUTED
                  "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);                  
4001c184:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
4001c188:	7f ff fd ec 	call  4001b938 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001c18c:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
        rtems_rfs_block_map_close (fs, &map);                         
4001c190:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001c194:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
4001c198:	7f ff f8 95 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001c19c:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
        return EIO;                                                   
4001c1a0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c1a4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
      }                                                               
                                                                      
      entry  += elength;                                              
      offset += elength;                                              
4001c1a8:	10 bf ff a3 	b  4001c034 <rtems_rfs_dir_add_entry+0x1ec>    
4001c1ac:	a2 04 40 18 	add  %l1, %i0, %l1                             
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c1b0:	7f ff fd e2 	call  4001b938 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001c1b4:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
  rtems_rfs_block_map_close (fs, &map);                               
4001c1b8:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001c1bc:	7f ff f8 8c 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001c1c0:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
  return rc;                                                          
}                                                                     
4001c1c4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c1c8:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001c1cc <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) {
4001c1cc:	9d e3 bf 40 	save  %sp, -192, %sp                           
  rtems_rfs_block_no      block;                                      
  rtems_rfs_buffer_handle buffer;                                     
  bool                    search;                                     
  int                     rc;                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))                
4001c1d0:	90 10 20 00 	clr  %o0                                       
4001c1d4:	13 10 00 00 	sethi  %hi(0x40000000), %o1                    
4001c1d8:	7f ff dd 1d 	call  4001364c <rtems_rfs_trace>               
4001c1dc:	ba 10 00 18 	mov  %i0, %i5                                  
4001c1e0:	80 a2 20 00 	cmp  %o0, 0                                    
4001c1e4:	02 80 00 09 	be  4001c208 <rtems_rfs_dir_del_entry+0x3c>    <== ALWAYS TAKEN
4001c1e8:	90 10 00 1d 	mov  %i5, %o0                                  
    printf ("rtems-rfs: dir-del-entry: dir=%" PRId32 ", entry=%" PRId32 " offset=%" PRIu32 "\n",
4001c1ec:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001c1f0:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c1f4:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
4001c1f8:	90 12 21 c8 	or  %o0, 0x1c8, %o0                            <== NOT EXECUTED
4001c1fc:	40 00 18 23 	call  40022288 <printf>                        <== NOT EXECUTED
4001c200:	96 10 00 1b 	mov  %i3, %o3                                  <== NOT EXECUTED
            rtems_rfs_inode_ino (dir), ino, offset);                  
                                                                      
  rc = rtems_rfs_block_map_open (fs, dir, &map);                      
4001c204:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c208:	92 10 00 19 	mov  %i1, %o1                                  
4001c20c:	7f ff f8 1a 	call  4001a274 <rtems_rfs_block_map_open>      
4001c210:	94 07 bf b0 	add  %fp, -80, %o2                             
  if (rc > 0)                                                         
4001c214:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c218:	14 80 00 c9 	bg  4001c53c <rtems_rfs_dir_del_entry+0x370>   <== NEVER TAKEN
4001c21c:	90 10 00 1d 	mov  %i5, %o0                                  
    return rc;                                                        
                                                                      
  rc = rtems_rfs_block_map_seek (fs, &map, offset, &block);           
4001c220:	92 07 bf b0 	add  %fp, -80, %o1                             
4001c224:	94 10 20 00 	clr  %o2                                       
4001c228:	96 10 00 1b 	mov  %i3, %o3                                  
4001c22c:	7f ff f9 43 	call  4001a738 <rtems_rfs_block_map_seek>      
4001c230:	98 07 bf a0 	add  %fp, -96, %o4                             
  if (rc > 0)                                                         
4001c234:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c238:	04 80 00 06 	ble  4001c250 <rtems_rfs_dir_del_entry+0x84>   <== ALWAYS TAKEN
4001c23c:	80 a6 20 06 	cmp  %i0, 6                                    
  {                                                                   
    if (rc == ENXIO)                                                  
4001c240:	22 80 00 d4 	be,a   4001c590 <rtems_rfs_dir_del_entry+0x3c4><== NOT EXECUTED
4001c244:	b0 10 20 02 	mov  2, %i0                                    <== NOT EXECUTED
        rc = ENOENT;                                                  
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
  rtems_rfs_block_map_close (fs, &map);                               
4001c248:	10 80 00 d3 	b  4001c594 <rtems_rfs_dir_del_entry+0x3c8>    <== NOT EXECUTED
4001c24c:	90 10 00 1d 	mov  %i5, %o0                                  <== 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)                                                       
4001c250:	80 a0 00 1b 	cmp  %g0, %i3                                  
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c254:	29 00 00 3f 	sethi  %hi(0xfc00), %l4                        
        break;                                                        
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
          printf ("rtems-rfs: dir-del-entry: "                        
4001c258:	2b 10 00 d4 	sethi  %hi(0x40035000), %l5                    
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001c25c:	c0 2f bf a4 	clrb  [ %fp + -92 ]                            
  handle->bnum  = 0;                                                  
4001c260:	c0 27 bf a8 	clr  [ %fp + -88 ]                             
  handle->buffer = NULL;                                              
4001c264:	c0 27 bf ac 	clr  [ %fp + -84 ]                             
      rc = ENOENT;                                                    
    rtems_rfs_block_map_close (fs, &map);                             
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_handle_open (fs, &buffer);                    
4001c268:	b0 10 20 00 	clr  %i0                                       
                                                                      
    /*                                                                
     * If we are searching start at the beginning of the block. If not searching
     * skip to the offset in the block.                               
     */                                                               
    if (search)                                                       
4001c26c:	a6 60 3f ff 	subx  %g0, -1, %l3                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c270:	a8 15 23 ff 	or  %l4, 0x3ff, %l4                            
        break;                                                        
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
          printf ("rtems-rfs: dir-del-entry: "                        
4001c274:	aa 15 62 50 	or  %l5, 0x250, %l5                            
  /*                                                                  
   * Only search if the offset is 0 else we are at that position.     
   */                                                                 
  search = offset ? false : true;                                     
                                                                      
  while (rc == 0)                                                     
4001c278:	80 a6 20 00 	cmp  %i0, 0                                    
4001c27c:	12 80 00 c2 	bne  4001c584 <rtems_rfs_dir_del_entry+0x3b8>  <== NEVER TAKEN
4001c280:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         
  {                                                                   
    uint8_t* entry;                                                   
    int      eoffset;                                                 
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);  
4001c284:	90 10 00 1d 	mov  %i5, %o0                                  
4001c288:	92 07 bf a4 	add  %fp, -92, %o1                             
4001c28c:	7f ff fb f4 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001c290:	96 10 20 01 	mov  1, %o3                                    
    if (rc > 0)                                                       
4001c294:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c298:	04 80 00 13 	ble  4001c2e4 <rtems_rfs_dir_del_entry+0x118>  <== ALWAYS TAKEN
4001c29c:	80 a4 e0 00 	cmp  %l3, 0                                    
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))            
4001c2a0:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001c2a4:	7f ff dc ea 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001c2a8:	13 10 00 00 	sethi  %hi(0x40000000), %o1                    <== NOT EXECUTED
4001c2ac:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001c2b0:	22 80 00 b6 	be,a   4001c588 <rtems_rfs_dir_del_entry+0x3bc><== NOT EXECUTED
4001c2b4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        printf ("rtems-rfs: dir-del-entry: "                          
4001c2b8:	f8 06 60 08 	ld  [ %i1 + 8 ], %i4                           <== NOT EXECUTED
4001c2bc:	40 00 1c 34 	call  4002338c <strerror>                      <== NOT EXECUTED
4001c2c0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001c2c4:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001c2c8:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001c2cc:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
4001c2d0:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c2d4:	40 00 17 ed 	call  40022288 <printf>                        <== NOT EXECUTED
4001c2d8:	90 12 22 08 	or  %o0, 0x208, %o0	! 40035208 <CSWTCH.1+0xab8><== NOT EXECUTED
      if (rc == ENXIO)                                                
        rc = ENOENT;                                                  
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c2dc:	10 80 00 ab 	b  4001c588 <rtems_rfs_dir_del_entry+0x3bc>    <== NOT EXECUTED
4001c2e0:	90 10 00 1d 	mov  %i5, %o0                                  <== 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)                                                       
4001c2e4:	12 80 00 06 	bne  4001c2fc <rtems_rfs_dir_del_entry+0x130>  <== NEVER TAKEN
4001c2e8:	a0 10 20 00 	clr  %l0                                       
      eoffset = 0;                                                    
    else                                                              
      eoffset = offset % rtems_rfs_fs_block_size (fs);                
4001c2ec:	d2 07 60 08 	ld  [ %i5 + 8 ], %o1                           
4001c2f0:	40 00 49 c3 	call  4002e9fc <.urem>                         
4001c2f4:	90 10 00 1b 	mov  %i3, %o0                                  
4001c2f8:	a0 10 00 08 	mov  %o0, %l0                                  
                                                                      
    entry = rtems_rfs_buffer_data (&buffer) + eoffset;                
4001c2fc:	c2 07 bf ac 	ld  [ %fp + -84 ], %g1                         
4001c300:	f8 00 60 1c 	ld  [ %g1 + 0x1c ], %i4                        
                                                                      
    while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c304:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
    if (search)                                                       
      eoffset = 0;                                                    
    else                                                              
      eoffset = offset % rtems_rfs_fs_block_size (fs);                
                                                                      
    entry = rtems_rfs_buffer_data (&buffer) + eoffset;                
4001c308:	b8 07 00 10 	add  %i4, %l0, %i4                             
                                                                      
    while (eoffset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c30c:	84 00 7f f6 	add  %g1, -10, %g2                             
4001c310:	80 a4 00 02 	cmp  %l0, %g2                                  
4001c314:	1a 80 00 91 	bcc  4001c558 <rtems_rfs_dir_del_entry+0x38c>  <== NEVER TAKEN
4001c318:	80 a6 20 00 	cmp  %i0, 0                                    
    {                                                                 
      rtems_rfs_ino eino;                                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
4001c31c:	c6 0f 20 09 	ldub  [ %i4 + 9 ], %g3                         
4001c320:	e2 0f 20 08 	ldub  [ %i4 + 8 ], %l1                         
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c324:	e4 0f 00 00 	ldub  [ %i4 ], %l2                             
    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);                   
4001c328:	a3 2c 60 08 	sll  %l1, 8, %l1                               
4001c32c:	a2 14 40 03 	or  %l1, %g3, %l1                              
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c330:	c6 0f 20 01 	ldub  [ %i4 + 1 ], %g3                         
4001c334:	a5 2c a0 18 	sll  %l2, 0x18, %l2                            
4001c338:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
4001c33c:	a4 14 80 03 	or  %l2, %g3, %l2                              
4001c340:	c6 0f 20 03 	ldub  [ %i4 + 3 ], %g3                         
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c344:	80 a4 40 14 	cmp  %l1, %l4                                  
    {                                                                 
      rtems_rfs_ino eino;                                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c348:	a4 14 80 03 	or  %l2, %g3, %l2                              
4001c34c:	c6 0f 20 02 	ldub  [ %i4 + 2 ], %g3                         
4001c350:	87 28 e0 08 	sll  %g3, 8, %g3                               
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c354:	02 80 00 80 	be  4001c554 <rtems_rfs_dir_del_entry+0x388>   <== NEVER TAKEN
4001c358:	a4 14 80 03 	or  %l2, %g3, %l2                              
        break;                                                        
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
4001c35c:	80 a4 60 0a 	cmp  %l1, 0xa                                  
4001c360:	04 80 00 0d 	ble  4001c394 <rtems_rfs_dir_del_entry+0x1c8>  <== NEVER TAKEN
4001c364:	90 10 20 00 	clr  %o0                                       
4001c368:	c6 07 60 1c 	ld  [ %i5 + 0x1c ], %g3                        
4001c36c:	80 a4 40 03 	cmp  %l1, %g3                                  
4001c370:	1a 80 00 09 	bcc  4001c394 <rtems_rfs_dir_del_entry+0x1c8>  <== NEVER TAKEN
4001c374:	80 a4 a0 00 	cmp  %l2, 0                                    
4001c378:	02 80 00 07 	be  4001c394 <rtems_rfs_dir_del_entry+0x1c8>   <== NEVER TAKEN
4001c37c:	01 00 00 00 	nop                                            
4001c380:	c6 07 60 14 	ld  [ %i5 + 0x14 ], %g3                        
4001c384:	80 a4 80 03 	cmp  %l2, %g3                                  
4001c388:	08 80 00 11 	bleu  4001c3cc <rtems_rfs_dir_del_entry+0x200> <== ALWAYS TAKEN
4001c38c:	80 a6 80 12 	cmp  %i2, %l2                                  
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
4001c390:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001c394:	7f ff dc ae 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001c398:	13 10 00 00 	sethi  %hi(0x40000000), %o1                    <== NOT EXECUTED
4001c39c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001c3a0:	22 bf ff b6 	be,a   4001c278 <rtems_rfs_dir_del_entry+0xac> <== NOT EXECUTED
4001c3a4:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
          printf ("rtems-rfs: dir-del-entry: "                        
4001c3a8:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001c3ac:	d8 07 bf a0 	ld  [ %fp + -96 ], %o4                         <== NOT EXECUTED
4001c3b0:	90 10 00 15 	mov  %l5, %o0                                  <== NOT EXECUTED
4001c3b4:	94 10 00 11 	mov  %l1, %o2                                  <== NOT EXECUTED
4001c3b8:	96 10 00 12 	mov  %l2, %o3                                  <== NOT EXECUTED
4001c3bc:	40 00 17 b3 	call  40022288 <printf>                        <== NOT EXECUTED
4001c3c0:	9a 10 00 10 	mov  %l0, %o5                                  <== NOT EXECUTED
      rc = ENOENT;                                                    
    rtems_rfs_block_map_close (fs, &map);                             
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_handle_open (fs, &buffer);                    
4001c3c4:	10 bf ff ad 	b  4001c278 <rtems_rfs_dir_del_entry+0xac>     <== NOT EXECUTED
4001c3c8:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
                  rtems_rfs_inode_ino (dir), elength, eino, block, eoffset);
        rc = EIO;                                                     
        break;                                                        
      }                                                               
                                                                      
      if (ino == rtems_rfs_dir_entry_ino (entry))                     
4001c3cc:	12 80 00 5e 	bne  4001c544 <rtems_rfs_dir_del_entry+0x378>  <== NEVER TAKEN
4001c3d0:	80 a4 e0 00 	cmp  %l3, 0                                    
      {                                                               
        uint32_t remaining;                                           
        remaining = rtems_rfs_fs_block_size (fs) - (eoffset + elength);
        memmove (entry, entry + elength, remaining);                  
4001c3d4:	92 07 00 11 	add  %i4, %l1, %o1                             
4001c3d8:	90 10 00 1c 	mov  %i4, %o0                                  
      }                                                               
                                                                      
      if (ino == rtems_rfs_dir_entry_ino (entry))                     
      {                                                               
        uint32_t remaining;                                           
        remaining = rtems_rfs_fs_block_size (fs) - (eoffset + elength);
4001c3dc:	b6 04 00 11 	add  %l0, %l1, %i3                             
4001c3e0:	b6 20 40 1b 	sub  %g1, %i3, %i3                             
        memmove (entry, entry + elength, remaining);                  
4001c3e4:	40 00 16 dc 	call  40021f54 <memmove>                       
4001c3e8:	94 10 00 1b 	mov  %i3, %o2                                  
        memset (entry + remaining, 0xff, elength);                    
4001c3ec:	90 07 00 1b 	add  %i4, %i3, %o0                             
4001c3f0:	92 10 20 ff 	mov  0xff, %o1                                 
4001c3f4:	40 00 17 2c 	call  400220a4 <memset>                        
4001c3f8:	94 10 00 11 	mov  %l1, %o2                                  
         * 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);                 
4001c3fc:	c4 0f 20 08 	ldub  [ %i4 + 8 ], %g2                         
4001c400:	c2 0f 20 09 	ldub  [ %i4 + 9 ], %g1                         
4001c404:	85 28 a0 08 	sll  %g2, 8, %g2                               
                                                                      
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
4001c408:	90 10 20 00 	clr  %o0                                       
         * 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);                 
4001c40c:	b8 10 80 01 	or  %g2, %g1, %i4                              
                                                                      
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
4001c410:	7f ff dc 8f 	call  4001364c <rtems_rfs_trace>               
4001c414:	13 10 00 00 	sethi  %hi(0x40000000), %o1                    
4001c418:	80 a2 20 00 	cmp  %o0, 0                                    
4001c41c:	02 80 00 1a 	be  4001c484 <rtems_rfs_dir_del_entry+0x2b8>   <== ALWAYS TAKEN
4001c420:	03 3f ff c0 	sethi  %hi(0xffff0000), %g1                    
          printf ("rtems-rfs: dir-del-entry: "                        
                  "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");    
4001c424:	c2 07 bf c0 	ld  [ %fp + -64 ], %g1                         <== NOT EXECUTED
         *       also empty. This way we could clean up an empty directory.
         */                                                           
        elength = rtems_rfs_dir_entry_length (entry);                 
                                                                      
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
          printf ("rtems-rfs: dir-del-entry: "                        
4001c428:	d6 07 bf a0 	ld  [ %fp + -96 ], %o3                         <== NOT EXECUTED
4001c42c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4001c430:	12 80 00 08 	bne  4001c450 <rtems_rfs_dir_del_entry+0x284>  <== NOT EXECUTED
4001c434:	c4 07 bf b8 	ld  [ %fp + -72 ], %g2                         <== 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");    
4001c438:	80 a0 a0 00 	cmp  %g2, 0                                    <== NOT EXECUTED
4001c43c:	12 80 00 06 	bne  4001c454 <rtems_rfs_dir_del_entry+0x288>  <== NOT EXECUTED
4001c440:	84 00 bf ff 	add  %g2, -1, %g2                              <== NOT EXECUTED
         *       also empty. This way we could clean up an empty directory.
         */                                                           
        elength = rtems_rfs_dir_entry_length (entry);                 
                                                                      
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
          printf ("rtems-rfs: dir-del-entry: "                        
4001c444:	1b 10 00 cf 	sethi  %hi(0x40033c00), %o5                    <== NOT EXECUTED
4001c448:	10 80 00 08 	b  4001c468 <rtems_rfs_dir_del_entry+0x29c>    <== NOT EXECUTED
4001c44c:	9a 13 60 c8 	or  %o5, 0xc8, %o5	! 40033cc8 <_Semaphore_Translate_core_mutex_return_code_+0xb38><== 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");    
4001c450:	84 00 bf ff 	add  %g2, -1, %g2                              <== NOT EXECUTED
4001c454:	80 a0 40 02 	cmp  %g1, %g2                                  <== NOT EXECUTED
4001c458:	02 bf ff fc 	be  4001c448 <rtems_rfs_dir_del_entry+0x27c>   <== NOT EXECUTED
4001c45c:	1b 10 00 cf 	sethi  %hi(0x40033c00), %o5                    <== NOT EXECUTED
         *       also empty. This way we could clean up an empty directory.
         */                                                           
        elength = rtems_rfs_dir_entry_length (entry);                 
                                                                      
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))          
          printf ("rtems-rfs: dir-del-entry: "                        
4001c460:	1b 10 00 c8 	sethi  %hi(0x40032000), %o5                    <== NOT EXECUTED
4001c464:	9a 13 62 a0 	or  %o5, 0x2a0, %o5	! 400322a0 <__FUNCTION__.6501+0x238><== NOT EXECUTED
4001c468:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c46c:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001c470:	90 12 22 a0 	or  %o0, 0x2a0, %o0                            <== NOT EXECUTED
4001c474:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001c478:	40 00 17 84 	call  40022288 <printf>                        <== NOT EXECUTED
4001c47c:	98 10 00 10 	mov  %l0, %o4                                  <== 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) &&                 
4001c480:	03 3f ff c0 	sethi  %hi(0xffff0000), %g1                    <== NOT EXECUTED
4001c484:	b8 38 40 1c 	xnor  %g1, %i4, %i4                            
4001c488:	80 a7 20 00 	cmp  %i4, 0                                    
4001c48c:	12 80 00 23 	bne  4001c518 <rtems_rfs_dir_del_entry+0x34c>  
4001c490:	80 a4 20 00 	cmp  %l0, 0                                    
4001c494:	12 80 00 21 	bne  4001c518 <rtems_rfs_dir_del_entry+0x34c>  <== ALWAYS TAKEN
4001c498:	c2 07 bf c0 	ld  [ %fp + -64 ], %g1                         
            (eoffset == 0) && rtems_rfs_block_map_last (&map))        
4001c49c:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4001c4a0:	12 80 00 05 	bne  4001c4b4 <rtems_rfs_dir_del_entry+0x2e8>  <== NOT EXECUTED
4001c4a4:	c4 07 bf b8 	ld  [ %fp + -72 ], %g2                         <== NOT EXECUTED
4001c4a8:	80 a0 a0 00 	cmp  %g2, 0                                    <== NOT EXECUTED
4001c4ac:	02 80 00 07 	be  4001c4c8 <rtems_rfs_dir_del_entry+0x2fc>   <== NOT EXECUTED
4001c4b0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c4b4:	84 00 bf ff 	add  %g2, -1, %g2                              <== NOT EXECUTED
4001c4b8:	80 a0 40 02 	cmp  %g1, %g2                                  <== NOT EXECUTED
4001c4bc:	12 80 00 18 	bne  4001c51c <rtems_rfs_dir_del_entry+0x350>  <== NOT EXECUTED
4001c4c0:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
        {                                                             
          rc = rtems_rfs_block_map_shrink (fs, &map, 1);              
4001c4c4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c4c8:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
4001c4cc:	7f ff f9 af 	call  4001ab88 <rtems_rfs_block_map_shrink>    <== NOT EXECUTED
4001c4d0:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
          if (rc > 0)                                                 
4001c4d4:	b8 92 20 00 	orcc  %o0, 0, %i4                              <== NOT EXECUTED
4001c4d8:	04 80 00 10 	ble  4001c518 <rtems_rfs_dir_del_entry+0x34c>  <== NOT EXECUTED
4001c4dc:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
          {                                                           
            if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_DEL_ENTRY))      
4001c4e0:	7f ff dc 5b 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001c4e4:	13 10 00 00 	sethi  %hi(0x40000000), %o1                    <== NOT EXECUTED
4001c4e8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001c4ec:	02 80 00 0c 	be  4001c51c <rtems_rfs_dir_del_entry+0x350>   <== NOT EXECUTED
4001c4f0:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
              printf ("rtems-rfs: dir-del-entry: "                    
4001c4f4:	f6 06 60 08 	ld  [ %i1 + 8 ], %i3                           <== NOT EXECUTED
4001c4f8:	40 00 1b a5 	call  4002338c <strerror>                      <== NOT EXECUTED
4001c4fc:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
4001c500:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001c504:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001c508:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001c50c:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c510:	40 00 17 5e 	call  40022288 <printf>                        <== NOT EXECUTED
4001c514:	90 12 23 00 	or  %o0, 0x300, %o0	! 40035300 <CSWTCH.1+0xbb0><== 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);                        
4001c518:	82 10 20 01 	mov  1, %g1                                    
        rtems_rfs_buffer_handle_close (fs, &buffer);                  
4001c51c:	92 07 bf a4 	add  %fp, -92, %o1                             
                      "block map shrink failed for ino %" PRIu32 ": %d: %s\n",
                      rtems_rfs_inode_ino (dir), rc, strerror (rc));  
          }                                                           
        }                                                             
                                                                      
        rtems_rfs_buffer_mark_dirty (&buffer);                        
4001c520:	c2 2f bf a4 	stb  %g1, [ %fp + -92 ]                        
        rtems_rfs_buffer_handle_close (fs, &buffer);                  
4001c524:	7f ff fd 05 	call  4001b938 <rtems_rfs_buffer_handle_close> 
4001c528:	90 10 00 1d 	mov  %i5, %o0                                  
        rtems_rfs_block_map_close (fs, &map);                         
4001c52c:	90 10 00 1d 	mov  %i5, %o0                                  
4001c530:	92 07 bf b0 	add  %fp, -80, %o1                             
4001c534:	7f ff f7 ae 	call  4001a3ec <rtems_rfs_block_map_close>     
4001c538:	b0 10 20 00 	clr  %i0                                       
        return 0;                                                     
4001c53c:	81 c7 e0 08 	ret                                            
4001c540:	81 e8 00 00 	restore                                        
      }                                                               
                                                                      
      if (!search)                                                    
4001c544:	02 80 00 18 	be  4001c5a4 <rtems_rfs_dir_del_entry+0x3d8>   <== NOT EXECUTED
4001c548:	b8 07 00 11 	add  %i4, %l1, %i4                             <== NOT EXECUTED
        rc = EIO;                                                     
        break;                                                        
      }                                                               
                                                                      
      entry   += elength;                                             
      eoffset += elength;                                             
4001c54c:	10 bf ff 71 	b  4001c310 <rtems_rfs_dir_del_entry+0x144>    <== NOT EXECUTED
4001c550:	a0 04 00 11 	add  %l0, %l1, %l0                             <== NOT EXECUTED
    }                                                                 
                                                                      
    if (rc == 0)                                                      
4001c554:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
4001c558:	12 bf ff 49 	bne  4001c27c <rtems_rfs_dir_del_entry+0xb0>   <== NOT EXECUTED
4001c55c:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
    {                                                                 
      rc = rtems_rfs_block_map_next_block (fs, &map, &block);         
4001c560:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c564:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
4001c568:	7f ff f8 91 	call  4001a7ac <rtems_rfs_block_map_next_block><== NOT EXECUTED
4001c56c:	94 07 bf a0 	add  %fp, -96, %o2                             <== NOT EXECUTED
      if (rc == ENXIO)                                                
4001c570:	80 a2 20 06 	cmp  %o0, 6                                    <== NOT EXECUTED
4001c574:	12 bf ff 41 	bne  4001c278 <rtems_rfs_dir_del_entry+0xac>   <== NOT EXECUTED
4001c578:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
        rc = ENOENT;                                                  
4001c57c:	10 bf ff 3f 	b  4001c278 <rtems_rfs_dir_del_entry+0xac>     <== NOT EXECUTED
4001c580:	b0 10 20 02 	mov  2, %i0                                    <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c584:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c588:	7f ff fc ec 	call  4001b938 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001c58c:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
  rtems_rfs_block_map_close (fs, &map);                               
4001c590:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c594:	7f ff f7 96 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001c598:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
  return rc;                                                          
4001c59c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001c5a0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
      rc = ENOENT;                                                    
    rtems_rfs_block_map_close (fs, &map);                             
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_handle_open (fs, &buffer);                    
4001c5a4:	10 bf ff 35 	b  4001c278 <rtems_rfs_dir_del_entry+0xac>     <== NOT EXECUTED
4001c5a8:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
                                                                      

4001c928 <rtems_rfs_dir_empty>: int rtems_rfs_dir_empty (rtems_rfs_file_system* fs, rtems_rfs_inode_handle* dir) {
4001c928:	9d e3 bf 40 	save  %sp, -192, %sp                           
  rtems_rfs_buffer_handle buffer;                                     
  rtems_rfs_block_no      block;                                      
  bool                    empty;                                      
  int                     rc;                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                     
4001c92c:	90 10 20 00 	clr  %o0                                       
4001c930:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
4001c934:	7f ff db 46 	call  4001364c <rtems_rfs_trace>               
4001c938:	ba 10 00 18 	mov  %i0, %i5                                  
4001c93c:	80 a2 20 00 	cmp  %o0, 0                                    
4001c940:	22 80 00 07 	be,a   4001c95c <rtems_rfs_dir_empty+0x34>     <== ALWAYS TAKEN
4001c944:	90 10 00 1d 	mov  %i5, %o0                                  
    printf ("rtems-rfs: dir-empty: dir=%" PRId32 "\n", rtems_rfs_inode_ino (dir));
4001c948:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001c94c:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001c950:	40 00 16 4e 	call  40022288 <printf>                        <== NOT EXECUTED
4001c954:	90 12 20 30 	or  %o0, 0x30, %o0	! 40035430 <CSWTCH.1+0xce0> <== NOT EXECUTED
                                                                      
  empty = true;                                                       
                                                                      
  rc = rtems_rfs_block_map_open (fs, dir, &map);                      
4001c958:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001c95c:	92 10 00 19 	mov  %i1, %o1                                  
4001c960:	7f ff f6 45 	call  4001a274 <rtems_rfs_block_map_open>      
4001c964:	94 07 bf b0 	add  %fp, -80, %o2                             
  if (rc > 0)                                                         
4001c968:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c96c:	14 80 00 73 	bg  4001cb38 <rtems_rfs_dir_empty+0x210>       <== NEVER TAKEN
4001c970:	90 10 00 1d 	mov  %i5, %o0                                  
    return rc;                                                        
                                                                      
  rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);                
4001c974:	92 07 bf b0 	add  %fp, -80, %o1                             
4001c978:	94 10 20 00 	clr  %o2                                       
4001c97c:	96 10 20 00 	clr  %o3                                       
4001c980:	7f ff f7 6e 	call  4001a738 <rtems_rfs_block_map_seek>      
4001c984:	98 07 bf a0 	add  %fp, -96, %o4                             
  if (rc > 0)                                                         
4001c988:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c98c:	14 80 00 69 	bg  4001cb30 <rtems_rfs_dir_empty+0x208>       <== NEVER TAKEN
4001c990:	90 10 00 1d 	mov  %i5, %o0                                  
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c994:	21 00 00 3f 	sethi  %hi(0xfc00), %l0                        
        break;                                                        
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_EMPTY))              
          printf ("rtems-rfs: dir-empty: "                            
4001c998:	23 10 00 d5 	sethi  %hi(0x40035400), %l1                    
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001c99c:	c0 2f bf a4 	clrb  [ %fp + -92 ]                            
  handle->bnum  = 0;                                                  
4001c9a0:	c0 27 bf a8 	clr  [ %fp + -88 ]                             
  handle->buffer = NULL;                                              
4001c9a4:	c0 27 bf ac 	clr  [ %fp + -84 ]                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001c9a8:	a0 14 23 ff 	or  %l0, 0x3ff, %l0                            
        break;                                                        
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_EMPTY))              
          printf ("rtems-rfs: dir-empty: "                            
4001c9ac:	a2 14 60 50 	or  %l1, 0x50, %l1                             
  while (empty)                                                       
  {                                                                   
    uint8_t* entry;                                                   
    int      offset;                                                  
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);  
4001c9b0:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         
4001c9b4:	90 10 00 1d 	mov  %i5, %o0                                  
4001c9b8:	92 07 bf a4 	add  %fp, -92, %o1                             
4001c9bc:	7f ff fa 28 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001c9c0:	96 10 20 01 	mov  1, %o3                                    
    if (rc > 0)                                                       
4001c9c4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c9c8:	14 80 00 4f 	bg  4001cb04 <rtems_rfs_dir_empty+0x1dc>       <== NEVER TAKEN
4001c9cc:	c2 07 bf ac 	ld  [ %fp + -84 ], %g1                         
      break;                                                          
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
    offset = 0;                                                       
                                                                      
    while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c9d0:	c4 07 60 08 	ld  [ %i5 + 8 ], %g2                           
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);  
    if (rc > 0)                                                       
      break;                                                          
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
4001c9d4:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
    offset = 0;                                                       
                                                                      
    while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c9d8:	84 00 bf f6 	add  %g2, -10, %g2                             
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);  
    if (rc > 0)                                                       
      break;                                                          
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
    offset = 0;                                                       
4001c9dc:	b6 10 20 00 	clr  %i3                                       
                                                                      
    while (offset < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001c9e0:	80 a6 c0 02 	cmp  %i3, %g2                                  
4001c9e4:	1a 80 00 3f 	bcc  4001cae0 <rtems_rfs_dir_empty+0x1b8>      <== NEVER TAKEN
4001c9e8:	90 10 00 1d 	mov  %i5, %o0                                  
    {                                                                 
      rtems_rfs_ino eino;                                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
4001c9ec:	c6 08 60 09 	ldub  [ %g1 + 9 ], %g3                         
4001c9f0:	f8 08 60 08 	ldub  [ %g1 + 8 ], %i4                         
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001c9f4:	f4 08 40 00 	ldub  [ %g1 ], %i2                             
    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);                   
4001c9f8:	b9 2f 20 08 	sll  %i4, 8, %i4                               
4001c9fc:	b8 17 00 03 	or  %i4, %g3, %i4                              
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001ca00:	c6 08 60 01 	ldub  [ %g1 + 1 ], %g3                         
4001ca04:	b5 2e a0 18 	sll  %i2, 0x18, %i2                            
4001ca08:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
4001ca0c:	b4 16 80 03 	or  %i2, %g3, %i2                              
4001ca10:	c6 08 60 03 	ldub  [ %g1 + 3 ], %g3                         
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001ca14:	80 a7 00 10 	cmp  %i4, %l0                                  
    {                                                                 
      rtems_rfs_ino eino;                                             
      int           elength;                                          
                                                                      
      elength = rtems_rfs_dir_entry_length (entry);                   
      eino    = rtems_rfs_dir_entry_ino (entry);                      
4001ca18:	b4 16 80 03 	or  %i2, %g3, %i2                              
4001ca1c:	c6 08 60 02 	ldub  [ %g1 + 2 ], %g3                         
4001ca20:	87 28 e0 08 	sll  %g3, 8, %g3                               
                                                                      
      if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                       
4001ca24:	02 80 00 2f 	be  4001cae0 <rtems_rfs_dir_empty+0x1b8>       
4001ca28:	b4 16 80 03 	or  %i2, %g3, %i2                              
        break;                                                        
                                                                      
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
4001ca2c:	80 a7 20 0a 	cmp  %i4, 0xa                                  
4001ca30:	04 80 00 0d 	ble  4001ca64 <rtems_rfs_dir_empty+0x13c>      <== NEVER TAKEN
4001ca34:	90 10 20 01 	mov  1, %o0                                    
4001ca38:	c6 07 60 1c 	ld  [ %i5 + 0x1c ], %g3                        
4001ca3c:	80 a7 00 03 	cmp  %i4, %g3                                  
4001ca40:	1a 80 00 09 	bcc  4001ca64 <rtems_rfs_dir_empty+0x13c>      <== NEVER TAKEN
4001ca44:	80 a6 a0 00 	cmp  %i2, 0                                    
4001ca48:	02 80 00 07 	be  4001ca64 <rtems_rfs_dir_empty+0x13c>       <== NEVER TAKEN
4001ca4c:	01 00 00 00 	nop                                            
4001ca50:	c6 07 60 14 	ld  [ %i5 + 0x14 ], %g3                        
4001ca54:	80 a6 80 03 	cmp  %i2, %g3                                  
4001ca58:	08 80 00 10 	bleu  4001ca98 <rtems_rfs_dir_empty+0x170>     <== ALWAYS TAKEN
4001ca5c:	80 a7 20 0b 	cmp  %i4, 0xb                                  
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_EMPTY))              
4001ca60:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
4001ca64:	7f ff da fa 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001ca68:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001ca6c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ca70:	22 80 00 1c 	be,a   4001cae0 <rtems_rfs_dir_empty+0x1b8>    <== NOT EXECUTED
4001ca74:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
          printf ("rtems-rfs: dir-empty: "                            
4001ca78:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001ca7c:	90 10 00 11 	mov  %l1, %o0                                  <== NOT EXECUTED
4001ca80:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001ca84:	96 10 00 1a 	mov  %i2, %o3                                  <== NOT EXECUTED
4001ca88:	40 00 16 00 	call  40022288 <printf>                        <== NOT EXECUTED
4001ca8c:	98 10 00 1b 	mov  %i3, %o4                                  <== NOT EXECUTED
      offset += elength;                                              
    }                                                                 
                                                                      
    if (empty)                                                        
    {                                                                 
      rc = rtems_rfs_block_map_next_block (fs, &map, &block);         
4001ca90:	10 80 00 14 	b  4001cae0 <rtems_rfs_dir_empty+0x1b8>        <== NOT EXECUTED
4001ca94:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                                                                      
      /*                                                              
       * Ignore the current (.) and parent (..) entries. Anything else means
       * the directory is not empty.                                  
       */                                                             
      if (((elength != (RTEMS_RFS_DIR_ENTRY_SIZE + 1)) ||             
4001ca98:	12 80 00 04 	bne  4001caa8 <rtems_rfs_dir_empty+0x180>      
4001ca9c:	80 a7 20 0c 	cmp  %i4, 0xc                                  
4001caa0:	10 80 00 09 	b  4001cac4 <rtems_rfs_dir_empty+0x19c>        
4001caa4:	c6 08 60 0a 	ldub  [ %g1 + 0xa ], %g3                       
           (entry[RTEMS_RFS_DIR_ENTRY_SIZE] != '.')) &&               
4001caa8:	32 80 00 18 	bne,a   4001cb08 <rtems_rfs_dir_empty+0x1e0>   
4001caac:	82 10 20 00 	clr  %g1                                       
          ((elength != (RTEMS_RFS_DIR_ENTRY_SIZE + 2)) ||             
4001cab0:	c6 08 60 0a 	ldub  [ %g1 + 0xa ], %g3                       
4001cab4:	80 a0 e0 2e 	cmp  %g3, 0x2e                                 
4001cab8:	32 80 00 14 	bne,a   4001cb08 <rtems_rfs_dir_empty+0x1e0>   <== NEVER TAKEN
4001cabc:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
           (entry[RTEMS_RFS_DIR_ENTRY_SIZE] != '.') ||                
4001cac0:	c6 08 60 0b 	ldub  [ %g1 + 0xb ], %g3                       
4001cac4:	80 a0 e0 2e 	cmp  %g3, 0x2e                                 
4001cac8:	12 80 00 04 	bne  4001cad8 <rtems_rfs_dir_empty+0x1b0>      <== NEVER TAKEN
4001cacc:	b6 06 c0 1c 	add  %i3, %i4, %i3                             
      {                                                               
        empty = false;                                                
        break;                                                        
      }                                                               
                                                                      
      entry  += elength;                                              
4001cad0:	10 bf ff c4 	b  4001c9e0 <rtems_rfs_dir_empty+0xb8>         
4001cad4:	82 00 40 1c 	add  %g1, %i4, %g1                             
4001cad8:	10 80 00 0c 	b  4001cb08 <rtems_rfs_dir_empty+0x1e0>        <== NOT EXECUTED
4001cadc:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
      offset += elength;                                              
    }                                                                 
                                                                      
    if (empty)                                                        
    {                                                                 
      rc = rtems_rfs_block_map_next_block (fs, &map, &block);         
4001cae0:	92 07 bf b0 	add  %fp, -80, %o1                             
4001cae4:	7f ff f7 32 	call  4001a7ac <rtems_rfs_block_map_next_block>
4001cae8:	94 07 bf a0 	add  %fp, -96, %o2                             
      if (rc > 0)                                                     
4001caec:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001caf0:	24 bf ff b1 	ble,a   4001c9b4 <rtems_rfs_dir_empty+0x8c>    <== NEVER TAKEN
4001caf4:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         <== NOT EXECUTED
      {                                                               
        if (rc == ENXIO)                                              
4001caf8:	80 a6 20 06 	cmp  %i0, 6                                    
4001cafc:	22 80 00 02 	be,a   4001cb04 <rtems_rfs_dir_empty+0x1dc>    <== ALWAYS TAKEN
4001cb00:	b0 10 20 00 	clr  %i0                                       
4001cb04:	82 10 20 01 	mov  1, %g1                                    
        break;                                                        
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  if ((rc == 0) && !empty)                                            
4001cb08:	80 88 60 ff 	btst  0xff, %g1                                
4001cb0c:	12 80 00 06 	bne  4001cb24 <rtems_rfs_dir_empty+0x1fc>      
4001cb10:	90 10 00 1d 	mov  %i5, %o0                                  
4001cb14:	80 a6 20 00 	cmp  %i0, 0                                    
4001cb18:	22 80 00 03 	be,a   4001cb24 <rtems_rfs_dir_empty+0x1fc>    <== ALWAYS TAKEN
4001cb1c:	b0 10 20 5a 	mov  0x5a, %i0                                 
    rc = ENOTEMPTY;                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001cb20:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001cb24:	7f ff fb 85 	call  4001b938 <rtems_rfs_buffer_handle_close> 
4001cb28:	92 07 bf a4 	add  %fp, -92, %o1                             
  rtems_rfs_block_map_close (fs, &map);                               
4001cb2c:	90 10 00 1d 	mov  %i5, %o0                                  
4001cb30:	7f ff f6 2f 	call  4001a3ec <rtems_rfs_block_map_close>     
4001cb34:	92 07 bf b0 	add  %fp, -80, %o1                             
  return rc;                                                          
4001cb38:	81 c7 e0 08 	ret                                            
4001cb3c:	81 e8 00 00 	restore                                        
                                                                      

40020aec <rtems_rfs_dir_hash>: { 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;
40020aec:	07 37 f7 c5 	sethi  %hi(0xdfdf1400), %g3                    
40020af0:	86 10 e2 9f 	or  %g3, 0x29f, %g3	! dfdf169f <RAM_END+0x9f9f169f>
40020af4:	86 02 40 03 	add  %o1, %g3, %g3                             
40020af8:	84 10 00 03 	mov  %g3, %g2                                  
40020afc:	82 10 00 03 	mov  %g3, %g1                                  
                                                                      
  } 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)                                               
40020b00:	80 a2 60 0c 	cmp  %o1, 0xc                                  
40020b04:	28 80 00 4a 	bleu,a   40020c2c <rtems_rfs_dir_hash+0x140>   
40020b08:	92 02 7f ff 	add  %o1, -1, %o1                              
    {                                                                 
      a += k[0];                                                      
40020b0c:	c8 0a 00 00 	ldub  [ %o0 ], %g4                             
      a += ((uint32_t)k[1])<<8;                                       
      a += ((uint32_t)k[2])<<16;                                      
40020b10:	da 0a 20 02 	ldub  [ %o0 + 2 ], %o5                         
    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];                                                      
40020b14:	86 01 00 03 	add  %g4, %g3, %g3                             
      a += ((uint32_t)k[1])<<8;                                       
40020b18:	c8 0a 20 01 	ldub  [ %o0 + 1 ], %g4                         
      a += ((uint32_t)k[2])<<16;                                      
40020b1c:	9b 2b 60 10 	sll  %o5, 0x10, %o5                            
                                                                      
    /*--------------- all but the last block: affect some 32 bits of (a,b,c) */
    while (length > 12)                                               
    {                                                                 
      a += k[0];                                                      
      a += ((uint32_t)k[1])<<8;                                       
40020b20:	89 29 20 08 	sll  %g4, 8, %g4                               
40020b24:	88 00 c0 04 	add  %g3, %g4, %g4                             
      a += ((uint32_t)k[2])<<16;                                      
      a += ((uint32_t)k[3])<<24;                                      
      b += k[4];                                                      
40020b28:	c6 0a 20 04 	ldub  [ %o0 + 4 ], %g3                         
    /*--------------- all but the last block: affect some 32 bits of (a,b,c) */
    while (length > 12)                                               
    {                                                                 
      a += k[0];                                                      
      a += ((uint32_t)k[1])<<8;                                       
      a += ((uint32_t)k[2])<<16;                                      
40020b2c:	88 01 00 0d 	add  %g4, %o5, %g4                             
      a += ((uint32_t)k[3])<<24;                                      
      b += k[4];                                                      
40020b30:	82 00 c0 01 	add  %g3, %g1, %g1                             
      b += ((uint32_t)k[5])<<8;                                       
40020b34:	c6 0a 20 05 	ldub  [ %o0 + 5 ], %g3                         
    while (length > 12)                                               
    {                                                                 
      a += k[0];                                                      
      a += ((uint32_t)k[1])<<8;                                       
      a += ((uint32_t)k[2])<<16;                                      
      a += ((uint32_t)k[3])<<24;                                      
40020b38:	da 0a 20 03 	ldub  [ %o0 + 3 ], %o5                         
      b += k[4];                                                      
      b += ((uint32_t)k[5])<<8;                                       
40020b3c:	87 28 e0 08 	sll  %g3, 8, %g3                               
40020b40:	82 00 40 03 	add  %g1, %g3, %g1                             
      b += ((uint32_t)k[6])<<16;                                      
40020b44:	c6 0a 20 06 	ldub  [ %o0 + 6 ], %g3                         
    while (length > 12)                                               
    {                                                                 
      a += k[0];                                                      
      a += ((uint32_t)k[1])<<8;                                       
      a += ((uint32_t)k[2])<<16;                                      
      a += ((uint32_t)k[3])<<24;                                      
40020b48:	9b 2b 60 18 	sll  %o5, 0x18, %o5                            
      b += k[4];                                                      
      b += ((uint32_t)k[5])<<8;                                       
      b += ((uint32_t)k[6])<<16;                                      
40020b4c:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40020b50:	82 00 40 03 	add  %g1, %g3, %g1                             
      b += ((uint32_t)k[7])<<24;                                      
40020b54:	c6 0a 20 07 	ldub  [ %o0 + 7 ], %g3                         
    while (length > 12)                                               
    {                                                                 
      a += k[0];                                                      
      a += ((uint32_t)k[1])<<8;                                       
      a += ((uint32_t)k[2])<<16;                                      
      a += ((uint32_t)k[3])<<24;                                      
40020b58:	88 01 00 0d 	add  %g4, %o5, %g4                             
      b += k[4];                                                      
      b += ((uint32_t)k[5])<<8;                                       
      b += ((uint32_t)k[6])<<16;                                      
      b += ((uint32_t)k[7])<<24;                                      
40020b5c:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
40020b60:	82 00 40 03 	add  %g1, %g3, %g1                             
      c += k[8];                                                      
40020b64:	c6 0a 20 08 	ldub  [ %o0 + 8 ], %g3                         
      c += ((uint32_t)k[9])<<8;                                       
      c += ((uint32_t)k[10])<<16;                                     
      c += ((uint32_t)k[11])<<24;                                     
      mix(a,b,c);                                                     
      length -= 12;                                                   
40020b68:	92 02 7f f4 	add  %o1, -12, %o1                             
      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;                                      
      c += k[8];                                                      
40020b6c:	84 00 c0 02 	add  %g3, %g2, %g2                             
      c += ((uint32_t)k[9])<<8;                                       
40020b70:	c6 0a 20 09 	ldub  [ %o0 + 9 ], %g3                         
      c += ((uint32_t)k[10])<<16;                                     
      c += ((uint32_t)k[11])<<24;                                     
      mix(a,b,c);                                                     
      length -= 12;                                                   
      k += 12;                                                        
40020b74:	90 02 20 0c 	add  %o0, 0xc, %o0                             
      b += k[4];                                                      
      b += ((uint32_t)k[5])<<8;                                       
      b += ((uint32_t)k[6])<<16;                                      
      b += ((uint32_t)k[7])<<24;                                      
      c += k[8];                                                      
      c += ((uint32_t)k[9])<<8;                                       
40020b78:	87 28 e0 08 	sll  %g3, 8, %g3                               
40020b7c:	84 00 80 03 	add  %g2, %g3, %g2                             
      c += ((uint32_t)k[10])<<16;                                     
40020b80:	c6 0a 3f fe 	ldub  [ %o0 + -2 ], %g3                        
40020b84:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40020b88:	84 00 80 03 	add  %g2, %g3, %g2                             
      c += ((uint32_t)k[11])<<24;                                     
40020b8c:	c6 0a 3f ff 	ldub  [ %o0 + -1 ], %g3                        
40020b90:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
40020b94:	84 00 80 03 	add  %g2, %g3, %g2                             
      mix(a,b,c);                                                     
40020b98:	88 21 00 02 	sub  %g4, %g2, %g4                             
40020b9c:	9b 30 a0 1c 	srl  %g2, 0x1c, %o5                            
40020ba0:	87 28 a0 04 	sll  %g2, 4, %g3                               
40020ba4:	86 13 40 03 	or  %o5, %g3, %g3                              
40020ba8:	86 19 00 03 	xor  %g4, %g3, %g3                             
40020bac:	9b 30 e0 1a 	srl  %g3, 0x1a, %o5                            
40020bb0:	89 28 e0 06 	sll  %g3, 6, %g4                               
40020bb4:	88 13 40 04 	or  %o5, %g4, %g4                              
40020bb8:	84 00 80 01 	add  %g2, %g1, %g2                             
40020bbc:	82 20 40 03 	sub  %g1, %g3, %g1                             
40020bc0:	82 19 00 01 	xor  %g4, %g1, %g1                             
40020bc4:	9b 30 60 18 	srl  %g1, 0x18, %o5                            
40020bc8:	89 28 60 08 	sll  %g1, 8, %g4                               
40020bcc:	88 13 40 04 	or  %o5, %g4, %g4                              
40020bd0:	86 00 c0 02 	add  %g3, %g2, %g3                             
40020bd4:	84 20 80 01 	sub  %g2, %g1, %g2                             
40020bd8:	84 19 00 02 	xor  %g4, %g2, %g2                             
40020bdc:	9b 30 a0 10 	srl  %g2, 0x10, %o5                            
40020be0:	89 28 a0 10 	sll  %g2, 0x10, %g4                            
40020be4:	88 13 40 04 	or  %o5, %g4, %g4                              
40020be8:	82 00 40 03 	add  %g1, %g3, %g1                             
40020bec:	86 20 c0 02 	sub  %g3, %g2, %g3                             
40020bf0:	86 19 00 03 	xor  %g4, %g3, %g3                             
40020bf4:	9b 30 e0 0d 	srl  %g3, 0xd, %o5                             
40020bf8:	89 28 e0 13 	sll  %g3, 0x13, %g4                            
40020bfc:	88 13 40 04 	or  %o5, %g4, %g4                              
40020c00:	84 00 80 01 	add  %g2, %g1, %g2                             
40020c04:	82 20 40 03 	sub  %g1, %g3, %g1                             
40020c08:	86 00 c0 02 	add  %g3, %g2, %g3                             
40020c0c:	82 19 00 01 	xor  %g4, %g1, %g1                             
40020c10:	84 20 80 01 	sub  %g2, %g1, %g2                             
40020c14:	9b 30 60 1c 	srl  %g1, 0x1c, %o5                            
40020c18:	89 28 60 04 	sll  %g1, 4, %g4                               
40020c1c:	82 00 40 03 	add  %g1, %g3, %g1                             
40020c20:	88 13 40 04 	or  %o5, %g4, %g4                              
40020c24:	10 bf ff b7 	b  40020b00 <rtems_rfs_dir_hash+0x14>          
40020c28:	84 19 00 02 	xor  %g4, %g2, %g2                             
      length -= 12;                                                   
      k += 12;                                                        
    }                                                                 
                                                                      
    /*-------------------------------- last block: affect all 32 bits of (c) */
    switch(length)                   /* all the case statements fall through */
40020c2c:	80 a2 60 0b 	cmp  %o1, 0xb                                  
40020c30:	18 80 00 4c 	bgu  40020d60 <rtems_rfs_dir_hash+0x274>       <== NEVER TAKEN
40020c34:	93 2a 60 02 	sll  %o1, 2, %o1                               
40020c38:	09 10 00 82 	sethi  %hi(0x40020800), %g4                    
40020c3c:	88 11 22 bc 	or  %g4, 0x2bc, %g4	! 40020abc <rtems_rfs_buffer_bdbuf_release+0x80>
40020c40:	c8 01 00 09 	ld  [ %g4 + %o1 ], %g4                         
40020c44:	81 c1 00 00 	jmp  %g4                                       
40020c48:	01 00 00 00 	nop                                            
    {                                                                 
      case 12: c+=((uint32_t)k[11])<<24;                              
40020c4c:	c8 0a 20 0b 	ldub  [ %o0 + 0xb ], %g4                       
40020c50:	89 29 20 18 	sll  %g4, 0x18, %g4                            
40020c54:	84 01 00 02 	add  %g4, %g2, %g2                             
      case 11: c+=((uint32_t)k[10])<<16;                              
40020c58:	c8 0a 20 0a 	ldub  [ %o0 + 0xa ], %g4                       
40020c5c:	89 29 20 10 	sll  %g4, 0x10, %g4                            
40020c60:	84 00 80 04 	add  %g2, %g4, %g2                             
      case 10: c+=((uint32_t)k[9])<<8;                                
40020c64:	c8 0a 20 09 	ldub  [ %o0 + 9 ], %g4                         
40020c68:	89 29 20 08 	sll  %g4, 8, %g4                               
40020c6c:	84 00 80 04 	add  %g2, %g4, %g2                             
      case 9 : c+=k[8];                                               
40020c70:	c8 0a 20 08 	ldub  [ %o0 + 8 ], %g4                         
40020c74:	84 00 80 04 	add  %g2, %g4, %g2                             
      case 8 : b+=((uint32_t)k[7])<<24;                               
40020c78:	c8 0a 20 07 	ldub  [ %o0 + 7 ], %g4                         
40020c7c:	89 29 20 18 	sll  %g4, 0x18, %g4                            
40020c80:	82 01 00 01 	add  %g4, %g1, %g1                             
      case 7 : b+=((uint32_t)k[6])<<16;                               
40020c84:	c8 0a 20 06 	ldub  [ %o0 + 6 ], %g4                         
40020c88:	89 29 20 10 	sll  %g4, 0x10, %g4                            
40020c8c:	82 00 40 04 	add  %g1, %g4, %g1                             
      case 6 : b+=((uint32_t)k[5])<<8;                                
40020c90:	c8 0a 20 05 	ldub  [ %o0 + 5 ], %g4                         
40020c94:	89 29 20 08 	sll  %g4, 8, %g4                               
40020c98:	82 00 40 04 	add  %g1, %g4, %g1                             
      case 5 : b+=k[4];                                               
40020c9c:	c8 0a 20 04 	ldub  [ %o0 + 4 ], %g4                         
40020ca0:	82 00 40 04 	add  %g1, %g4, %g1                             
      case 4 : a+=((uint32_t)k[3])<<24;                               
40020ca4:	c8 0a 20 03 	ldub  [ %o0 + 3 ], %g4                         
40020ca8:	89 29 20 18 	sll  %g4, 0x18, %g4                            
40020cac:	86 01 00 03 	add  %g4, %g3, %g3                             
      case 3 : a+=((uint32_t)k[2])<<16;                               
40020cb0:	c8 0a 20 02 	ldub  [ %o0 + 2 ], %g4                         
40020cb4:	89 29 20 10 	sll  %g4, 0x10, %g4                            
40020cb8:	86 00 c0 04 	add  %g3, %g4, %g3                             
      case 2 : a+=((uint32_t)k[1])<<8;                                
40020cbc:	c8 0a 20 01 	ldub  [ %o0 + 1 ], %g4                         
40020cc0:	89 29 20 08 	sll  %g4, 8, %g4                               
40020cc4:	86 00 c0 04 	add  %g3, %g4, %g3                             
        break;                                                        
      case 0 : return c;                                              
    }                                                                 
  }                                                                   
                                                                      
  final(a,b,c);                                                       
40020cc8:	9b 30 60 12 	srl  %g1, 0x12, %o5                            
40020ccc:	89 28 60 0e 	sll  %g1, 0xe, %g4                             
40020cd0:	88 11 00 0d 	or  %g4, %o5, %g4                              
40020cd4:	84 18 80 01 	xor  %g2, %g1, %g2                             
40020cd8:	84 20 80 04 	sub  %g2, %g4, %g2                             
      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];                                               
40020cdc:	c8 0a 00 00 	ldub  [ %o0 ], %g4                             
        break;                                                        
      case 0 : return c;                                              
    }                                                                 
  }                                                                   
                                                                      
  final(a,b,c);                                                       
40020ce0:	9b 30 a0 15 	srl  %g2, 0x15, %o5                            
      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];                                               
40020ce4:	86 00 c0 04 	add  %g3, %g4, %g3                             
        break;                                                        
      case 0 : return c;                                              
    }                                                                 
  }                                                                   
                                                                      
  final(a,b,c);                                                       
40020ce8:	89 28 a0 0b 	sll  %g2, 0xb, %g4                             
40020cec:	88 13 40 04 	or  %o5, %g4, %g4                              
40020cf0:	86 18 80 03 	xor  %g2, %g3, %g3                             
40020cf4:	86 20 c0 04 	sub  %g3, %g4, %g3                             
40020cf8:	9b 30 e0 07 	srl  %g3, 7, %o5                               
40020cfc:	89 28 e0 19 	sll  %g3, 0x19, %g4                            
40020d00:	88 13 40 04 	or  %o5, %g4, %g4                              
40020d04:	82 18 c0 01 	xor  %g3, %g1, %g1                             
40020d08:	82 20 40 04 	sub  %g1, %g4, %g1                             
40020d0c:	9b 30 60 10 	srl  %g1, 0x10, %o5                            
40020d10:	89 28 60 10 	sll  %g1, 0x10, %g4                            
40020d14:	88 13 40 04 	or  %o5, %g4, %g4                              
40020d18:	84 18 40 02 	xor  %g1, %g2, %g2                             
40020d1c:	84 20 80 04 	sub  %g2, %g4, %g2                             
40020d20:	9b 30 a0 1c 	srl  %g2, 0x1c, %o5                            
40020d24:	89 28 a0 04 	sll  %g2, 4, %g4                               
40020d28:	88 13 40 04 	or  %o5, %g4, %g4                              
40020d2c:	86 18 80 03 	xor  %g2, %g3, %g3                             
40020d30:	86 20 c0 04 	sub  %g3, %g4, %g3                             
40020d34:	89 30 e0 12 	srl  %g3, 0x12, %g4                            
40020d38:	82 18 c0 01 	xor  %g3, %g1, %g1                             
40020d3c:	87 28 e0 0e 	sll  %g3, 0xe, %g3                             
40020d40:	86 11 00 03 	or  %g4, %g3, %g3                              
40020d44:	82 20 40 03 	sub  %g1, %g3, %g1                             
40020d48:	91 30 60 08 	srl  %g1, 8, %o0                               
40020d4c:	84 18 40 02 	xor  %g1, %g2, %g2                             
40020d50:	83 28 60 18 	sll  %g1, 0x18, %g1                            
40020d54:	82 12 00 01 	or  %o0, %g1, %g1                              
  return c;                                                           
40020d58:	81 c3 e0 08 	retl                                           
40020d5c:	90 20 80 01 	sub  %g2, %g1, %o0                             
}                                                                     
40020d60:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
40020d64:	90 10 00 02 	mov  %g2, %o0                                  <== NOT EXECUTED
                                                                      

4001b960 <rtems_rfs_dir_lookup_ino>: rtems_rfs_inode_handle* inode, const char* name, int length, rtems_rfs_ino* ino, uint32_t* offset) {
4001b960:	9d e3 bf 38 	save  %sp, -200, %sp                           
  rtems_rfs_block_map     map;                                        
  rtems_rfs_buffer_handle entries;                                    
  int                     rc;                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))               
4001b964:	90 10 20 00 	clr  %o0                                       
4001b968:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     
4001b96c:	7f ff df 38 	call  4001364c <rtems_rfs_trace>               
4001b970:	a4 10 00 18 	mov  %i0, %l2                                  
4001b974:	80 a2 20 00 	cmp  %o0, 0                                    
4001b978:	22 80 00 13 	be,a   4001b9c4 <rtems_rfs_dir_lookup_ino+0x64><== ALWAYS TAKEN
4001b97c:	c0 27 00 00 	clr  [ %i4 ]                                   
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: dir-lookup-ino: lookup ino: root=%" PRId32 ", path=",
4001b980:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001b984:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
            inode->ino);                                              
    for (c = 0; c < length; c++)                                      
4001b988:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
  int                     rc;                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))               
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: dir-lookup-ino: lookup ino: root=%" PRId32 ", path=",
4001b98c:	40 00 1a 3f 	call  40022288 <printf>                        <== NOT EXECUTED
4001b990:	90 12 21 98 	or  %o0, 0x198, %o0                            <== NOT EXECUTED
            inode->ino);                                              
    for (c = 0; c < length; c++)                                      
4001b994:	80 a6 00 1b 	cmp  %i0, %i3                                  <== NOT EXECUTED
4001b998:	36 80 00 07 	bge,a   4001b9b4 <rtems_rfs_dir_lookup_ino+0x54><== NOT EXECUTED
4001b99c:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
      printf ("%c", name[c]);                                         
4001b9a0:	d0 4e 80 18 	ldsb  [ %i2 + %i0 ], %o0                       <== NOT EXECUTED
4001b9a4:	40 00 1a 9f 	call  40022420 <putchar>                       <== NOT EXECUTED
4001b9a8:	b0 06 20 01 	inc  %i0                                       <== NOT EXECUTED
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))               
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: dir-lookup-ino: lookup ino: root=%" PRId32 ", path=",
            inode->ino);                                              
    for (c = 0; c < length; c++)                                      
4001b9ac:	10 bf ff fb 	b  4001b998 <rtems_rfs_dir_lookup_ino+0x38>    <== NOT EXECUTED
4001b9b0:	80 a6 00 1b 	cmp  %i0, %i3                                  <== NOT EXECUTED
      printf ("%c", name[c]);                                         
    printf (", len=%d\n", length);                                    
4001b9b4:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001b9b8:	40 00 1a 34 	call  40022288 <printf>                        <== NOT EXECUTED
4001b9bc:	90 12 21 d0 	or  %o0, 0x1d0, %o0                            <== NOT EXECUTED
  }                                                                   
                                                                      
  *ino = RTEMS_RFS_EMPTY_INO;                                         
4001b9c0:	c0 27 00 00 	clr  [ %i4 ]                                   <== NOT EXECUTED
  *offset = 0;                                                        
4001b9c4:	c0 27 40 00 	clr  [ %i5 ]                                   
                                                                      
  rc = rtems_rfs_block_map_open (fs, inode, &map);                    
4001b9c8:	90 10 00 12 	mov  %l2, %o0                                  
4001b9cc:	92 10 00 19 	mov  %i1, %o1                                  
4001b9d0:	7f ff fa 29 	call  4001a274 <rtems_rfs_block_map_open>      
4001b9d4:	94 07 bf b0 	add  %fp, -80, %o2                             
  if (rc > 0)                                                         
4001b9d8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001b9dc:	04 80 00 12 	ble  4001ba24 <rtems_rfs_dir_lookup_ino+0xc4>  <== ALWAYS TAKEN
4001b9e0:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))             
4001b9e4:	7f ff df 1a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001b9e8:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     <== NOT EXECUTED
4001b9ec:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001b9f0:	02 80 01 14 	be  4001be40 <rtems_rfs_dir_lookup_ino+0x4e0>  <== NOT EXECUTED
4001b9f4:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: dir-lookup-ino: map open failed for ino %" PRIu32 ": %d: %s",
4001b9f8:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           <== NOT EXECUTED
4001b9fc:	40 00 1e 64 	call  4002338c <strerror>                      <== NOT EXECUTED
4001ba00:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001ba04:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001ba08:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001ba0c:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
4001ba10:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001ba14:	40 00 1a 1d 	call  40022288 <printf>                        <== NOT EXECUTED
4001ba18:	90 12 21 e0 	or  %o0, 0x1e0, %o0	! 40034de0 <CSWTCH.1+0x690><== NOT EXECUTED
4001ba1c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001ba20:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    uint32_t           hash;                                          
                                                                      
    /*                                                                
     * Calculate the hash of the look up string.                      
     */                                                               
    hash = rtems_rfs_dir_hash (name, length);                         
4001ba24:	92 10 00 1b 	mov  %i3, %o1                                  
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001ba28:	c0 2f bf a4 	clrb  [ %fp + -92 ]                            
  handle->bnum  = 0;                                                  
4001ba2c:	c0 27 bf a8 	clr  [ %fp + -88 ]                             
  handle->buffer = NULL;                                              
4001ba30:	c0 27 bf ac 	clr  [ %fp + -84 ]                             
4001ba34:	40 00 14 2e 	call  40020aec <rtems_rfs_dir_hash>            
4001ba38:	90 10 00 1a 	mov  %i2, %o0                                  
                                                                      
    /*                                                                
     * 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);              
4001ba3c:	92 07 bf b0 	add  %fp, -80, %o1                             
    uint32_t           hash;                                          
                                                                      
    /*                                                                
     * Calculate the hash of the look up string.                      
     */                                                               
    hash = rtems_rfs_dir_hash (name, length);                         
4001ba40:	d0 27 bf 9c 	st  %o0, [ %fp + -100 ]                        
                                                                      
    /*                                                                
     * 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);              
4001ba44:	94 10 20 00 	clr  %o2                                       
4001ba48:	90 10 00 12 	mov  %l2, %o0                                  
4001ba4c:	96 10 20 00 	clr  %o3                                       
4001ba50:	7f ff fb 3a 	call  4001a738 <rtems_rfs_block_map_seek>      
4001ba54:	98 07 bf a0 	add  %fp, -96, %o4                             
    if (rc > 0)                                                       
4001ba58:	a0 92 20 00 	orcc  %o0, 0, %l0                              
4001ba5c:	14 80 00 0b 	bg  4001ba88 <rtems_rfs_dir_lookup_ino+0x128>  <== NEVER TAKEN
4001ba60:	90 10 20 00 	clr  %o0                                       
    while ((rc == 0) && block)                                        
    {                                                                 
      uint8_t* entry;                                                 
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))           
        printf ("rtems-rfs: dir-lookup-ino: block read, ino=%" PRIu32 " bno=%" PRId32 "\n",
4001ba64:	29 10 00 d3 	sethi  %hi(0x40034c00), %l4                    
                                                                      
        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)                     
4001ba68:	2b 00 00 3f 	sethi  %hi(0xfc00), %l5                        
        }                                                             
                                                                      
        if (ehash == hash)                                            
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_CHECK)) 
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001ba6c:	2d 10 00 d3 	sethi  %hi(0x40034c00), %l6                    
      {                                                               
        rc = rtems_rfs_block_map_next_block (fs, &map, &block);       
        if ((rc > 0) && (rc != ENXIO))                                
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))       
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001ba70:	2f 10 00 d3 	sethi  %hi(0x40034c00), %l7                    
    while ((rc == 0) && block)                                        
    {                                                                 
      uint8_t* entry;                                                 
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))           
        printf ("rtems-rfs: dir-lookup-ino: block read, ino=%" PRIu32 " bno=%" PRId32 "\n",
4001ba74:	a8 15 22 60 	or  %l4, 0x260, %l4                            
                                                                      
        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)                     
4001ba78:	aa 15 63 ff 	or  %l5, 0x3ff, %l5                            
        }                                                             
                                                                      
        if (ehash == hash)                                            
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_CHECK)) 
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001ba7c:	ac 15 a3 30 	or  %l6, 0x330, %l6                            
      {                                                               
        rc = rtems_rfs_block_map_next_block (fs, &map, &block);       
        if ((rc > 0) && (rc != ENXIO))                                
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))       
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001ba80:	10 80 00 4d 	b  4001bbb4 <rtems_rfs_dir_lookup_ino+0x254>   
4001ba84:	ae 15 e3 d8 	or  %l7, 0x3d8, %l7                            
     * seek 0. If an error the block will be 0.                       
     */                                                               
    rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);              
    if (rc > 0)                                                       
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))           
4001ba88:	7f ff de f1 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001ba8c:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     <== NOT EXECUTED
4001ba90:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ba94:	02 80 00 0a 	be  4001babc <rtems_rfs_dir_lookup_ino+0x15c>  <== NOT EXECUTED
4001ba98:	80 a4 20 06 	cmp  %l0, 6                                    <== NOT EXECUTED
        printf ("rtems-rfs: dir-lookup-ino: block map find failed: %d: %s\n",
4001ba9c:	40 00 1e 3c 	call  4002338c <strerror>                      <== NOT EXECUTED
4001baa0:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001baa4:	92 10 00 10 	mov  %l0, %o1                                  <== NOT EXECUTED
4001baa8:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001baac:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001bab0:	40 00 19 f6 	call  40022288 <printf>                        <== NOT EXECUTED
4001bab4:	90 12 22 20 	or  %o0, 0x220, %o0	! 40034e20 <CSWTCH.1+0x6d0><== NOT EXECUTED
                rc, strerror (rc));                                   
      if (rc == ENXIO)                                                
4001bab8:	80 a4 20 06 	cmp  %l0, 6                                    <== NOT EXECUTED
4001babc:	22 80 00 d8 	be,a   4001be1c <rtems_rfs_dir_lookup_ino+0x4bc><== NOT EXECUTED
4001bac0:	a0 10 20 02 	mov  2, %l0                                    <== 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);                       
4001bac4:	10 80 00 d7 	b  4001be20 <rtems_rfs_dir_lookup_ino+0x4c0>   <== NOT EXECUTED
4001bac8:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
      rtems_rfs_buffer_handle_close (fs, &entries);                   
      rtems_rfs_block_map_close (fs, &map);                           
      return rc;                                                      
    }                                                                 
                                                                      
    while ((rc == 0) && block)                                        
4001bacc:	80 a0 60 00 	cmp  %g1, 0                                    
4001bad0:	02 80 00 c4 	be  4001bde0 <rtems_rfs_dir_lookup_ino+0x480>  <== NEVER TAKEN
4001bad4:	90 10 20 00 	clr  %o0                                       
    {                                                                 
      uint8_t* entry;                                                 
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))           
4001bad8:	7f ff de dd 	call  4001364c <rtems_rfs_trace>               
4001badc:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     
4001bae0:	80 a2 20 00 	cmp  %o0, 0                                    
4001bae4:	02 80 00 07 	be  4001bb00 <rtems_rfs_dir_lookup_ino+0x1a0>  <== ALWAYS TAKEN
4001bae8:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         
        printf ("rtems-rfs: dir-lookup-ino: block read, ino=%" PRIu32 " bno=%" PRId32 "\n",
4001baec:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001baf0:	d4 07 bf c0 	ld  [ %fp + -64 ], %o2                         <== NOT EXECUTED
4001baf4:	40 00 19 e5 	call  40022288 <printf>                        <== NOT EXECUTED
4001baf8:	90 10 00 14 	mov  %l4, %o0                                  <== NOT EXECUTED
                rtems_rfs_inode_ino (inode), map.bpos.bno);           
                                                                      
      rc = rtems_rfs_buffer_handle_request (fs, &entries, block, true);
4001bafc:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         <== NOT EXECUTED
4001bb00:	90 10 00 12 	mov  %l2, %o0                                  
4001bb04:	92 07 bf a4 	add  %fp, -92, %o1                             
4001bb08:	7f ff fd d5 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001bb0c:	96 10 20 01 	mov  1, %o3                                    
      if (rc > 0)                                                     
4001bb10:	a0 92 20 00 	orcc  %o0, 0, %l0                              
4001bb14:	14 80 00 2d 	bg  4001bbc8 <rtems_rfs_dir_lookup_ino+0x268>  <== NEVER TAKEN
4001bb18:	c2 07 bf ac 	ld  [ %fp + -84 ], %g1                         
       * means the entry is empty.                                    
       */                                                             
                                                                      
      entry = rtems_rfs_buffer_data (&entries);                       
                                                                      
      map.bpos.boff = 0;                                              
4001bb1c:	c0 27 bf c4 	clr  [ %fp + -60 ]                             
      /*                                                              
       * 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);                       
4001bb20:	e2 00 60 1c 	ld  [ %g1 + 0x1c ], %l1                        
                                                                      
      map.bpos.boff = 0;                                              
                                                                      
      while (map.bpos.boff < (rtems_rfs_fs_block_size (fs) - RTEMS_RFS_DIR_ENTRY_SIZE))
4001bb24:	c2 04 a0 08 	ld  [ %l2 + 8 ], %g1                           
4001bb28:	c4 07 bf c4 	ld  [ %fp + -60 ], %g2                         
4001bb2c:	82 00 7f f6 	add  %g1, -10, %g1                             
4001bb30:	80 a0 80 01 	cmp  %g2, %g1                                  
4001bb34:	1a 80 00 1e 	bcc  4001bbac <rtems_rfs_dir_lookup_ino+0x24c> <== NEVER TAKEN
4001bb38:	80 a4 20 00 	cmp  %l0, 0                                    
      {                                                               
        uint32_t ehash;                                               
        int      elength;                                             
                                                                      
        ehash  = rtems_rfs_dir_entry_hash (entry);                    
4001bb3c:	c2 0c 60 05 	ldub  [ %l1 + 5 ], %g1                         
4001bb40:	c6 0c 60 04 	ldub  [ %l1 + 4 ], %g3                         
4001bb44:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001bb48:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001bb4c:	86 10 c0 01 	or  %g3, %g1, %g3                              
4001bb50:	c2 0c 60 07 	ldub  [ %l1 + 7 ], %g1                         
        elength = rtems_rfs_dir_entry_length (entry);                 
4001bb54:	c4 0c 60 09 	ldub  [ %l1 + 9 ], %g2                         
      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);                    
4001bb58:	86 10 c0 01 	or  %g3, %g1, %g3                              
4001bb5c:	c2 0c 60 06 	ldub  [ %l1 + 6 ], %g1                         
        elength = rtems_rfs_dir_entry_length (entry);                 
        *ino = rtems_rfs_dir_entry_ino (entry);                       
4001bb60:	c8 0c 40 00 	ldub  [ %l1 ], %g4                             
      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);                    
4001bb64:	83 28 60 08 	sll  %g1, 8, %g1                               
4001bb68:	86 10 c0 01 	or  %g3, %g1, %g3                              
        elength = rtems_rfs_dir_entry_length (entry);                 
4001bb6c:	c2 0c 60 08 	ldub  [ %l1 + 8 ], %g1                         
        *ino = rtems_rfs_dir_entry_ino (entry);                       
4001bb70:	89 29 20 18 	sll  %g4, 0x18, %g4                            
      {                                                               
        uint32_t ehash;                                               
        int      elength;                                             
                                                                      
        ehash  = rtems_rfs_dir_entry_hash (entry);                    
        elength = rtems_rfs_dir_entry_length (entry);                 
4001bb74:	83 28 60 08 	sll  %g1, 8, %g1                               
4001bb78:	a6 10 40 02 	or  %g1, %g2, %l3                              
        *ino = rtems_rfs_dir_entry_ino (entry);                       
4001bb7c:	c4 0c 60 01 	ldub  [ %l1 + 1 ], %g2                         
                                                                      
        if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                     
4001bb80:	80 a4 c0 15 	cmp  %l3, %l5                                  
        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);                       
4001bb84:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001bb88:	84 11 00 02 	or  %g4, %g2, %g2                              
4001bb8c:	c8 0c 60 03 	ldub  [ %l1 + 3 ], %g4                         
4001bb90:	84 10 80 04 	or  %g2, %g4, %g2                              
4001bb94:	c8 0c 60 02 	ldub  [ %l1 + 2 ], %g4                         
4001bb98:	89 29 20 08 	sll  %g4, 8, %g4                               
4001bb9c:	84 10 80 04 	or  %g2, %g4, %g2                              
                                                                      
        if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                     
4001bba0:	12 80 00 1d 	bne  4001bc14 <rtems_rfs_dir_lookup_ino+0x2b4> 
4001bba4:	c4 27 00 00 	st  %g2, [ %i4 ]                               
                                                                      
        map.bpos.boff += elength;                                     
        entry += elength;                                             
      }                                                               
                                                                      
      if (rc == 0)                                                    
4001bba8:	80 a4 20 00 	cmp  %l0, 0                                    
4001bbac:	02 80 00 70 	be  4001bd6c <rtems_rfs_dir_lookup_ino+0x40c>  <== ALWAYS TAKEN
4001bbb0:	90 10 00 12 	mov  %l2, %o0                                  
      rtems_rfs_buffer_handle_close (fs, &entries);                   
      rtems_rfs_block_map_close (fs, &map);                           
      return rc;                                                      
    }                                                                 
                                                                      
    while ((rc == 0) && block)                                        
4001bbb4:	80 a4 20 00 	cmp  %l0, 0                                    
4001bbb8:	02 bf ff c5 	be  4001bacc <rtems_rfs_dir_lookup_ino+0x16c>  
4001bbbc:	c2 07 bf a0 	ld  [ %fp + -96 ], %g1                         
4001bbc0:	10 80 00 98 	b  4001be20 <rtems_rfs_dir_lookup_ino+0x4c0>   
4001bbc4:	92 07 bf a4 	add  %fp, -92, %o1                             
                rtems_rfs_inode_ino (inode), map.bpos.bno);           
                                                                      
      rc = rtems_rfs_buffer_handle_request (fs, &entries, block, true);
      if (rc > 0)                                                     
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))         
4001bbc8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001bbcc:	7f ff de a0 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bbd0:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     <== NOT EXECUTED
4001bbd4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bbd8:	22 80 00 92 	be,a   4001be20 <rtems_rfs_dir_lookup_ino+0x4c0><== NOT EXECUTED
4001bbdc:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
          printf ("rtems-rfs: dir-lookup-ino: block read, ino=%" PRIu32 " block=%" PRId32 ": %d: %s\n",
4001bbe0:	f8 06 60 08 	ld  [ %i1 + 8 ], %i4                           <== NOT EXECUTED
4001bbe4:	fa 07 bf a0 	ld  [ %fp + -96 ], %i5                         <== NOT EXECUTED
4001bbe8:	40 00 1d e9 	call  4002338c <strerror>                      <== NOT EXECUTED
4001bbec:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001bbf0:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001bbf4:	98 10 00 08 	mov  %o0, %o4                                  <== NOT EXECUTED
4001bbf8:	94 10 00 1d 	mov  %i5, %o2                                  <== NOT EXECUTED
4001bbfc:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001bc00:	96 10 00 10 	mov  %l0, %o3                                  <== NOT EXECUTED
4001bc04:	40 00 19 a1 	call  40022288 <printf>                        <== NOT EXECUTED
4001bc08:	90 12 22 98 	or  %o0, 0x298, %o0                            <== 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);                       
4001bc0c:	10 80 00 85 	b  4001be20 <rtems_rfs_dir_lookup_ino+0x4c0>   <== NOT EXECUTED
4001bc10:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
        *ino = rtems_rfs_dir_entry_ino (entry);                       
                                                                      
        if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                     
          break;                                                      
                                                                      
        if (rtems_rfs_dir_entry_valid (fs, elength, *ino))            
4001bc14:	80 a4 e0 0a 	cmp  %l3, 0xa                                  
4001bc18:	34 80 00 11 	bg,a   4001bc5c <rtems_rfs_dir_lookup_ino+0x2fc><== ALWAYS TAKEN
4001bc1c:	c8 04 a0 1c 	ld  [ %l2 + 0x1c ], %g4                        
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))       
4001bc20:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001bc24:	7f ff de 8a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bc28:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     <== NOT EXECUTED
4001bc2c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bc30:	22 80 00 7b 	be,a   4001be1c <rtems_rfs_dir_lookup_ino+0x4bc><== NOT EXECUTED
4001bc34:	a0 10 20 05 	mov  5, %l0                                    <== NOT EXECUTED
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001bc38:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001bc3c:	d6 07 00 00 	ld  [ %i4 ], %o3                               <== NOT EXECUTED
4001bc40:	d8 07 bf c4 	ld  [ %fp + -60 ], %o4                         <== NOT EXECUTED
4001bc44:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001bc48:	94 10 00 13 	mov  %l3, %o2                                  <== NOT EXECUTED
4001bc4c:	40 00 19 8f 	call  40022288 <printf>                        <== NOT EXECUTED
4001bc50:	90 12 22 e0 	or  %o0, 0x2e0, %o0                            <== NOT EXECUTED
      }                                                               
    }                                                                 
                                                                      
    if ((rc == 0) && (block == 0))                                    
    {                                                                 
      rc = EIO;                                                       
4001bc54:	10 80 00 72 	b  4001be1c <rtems_rfs_dir_lookup_ino+0x4bc>   <== NOT EXECUTED
4001bc58:	a0 10 20 05 	mov  5, %l0                                    <== NOT EXECUTED
        *ino = rtems_rfs_dir_entry_ino (entry);                       
                                                                      
        if (elength == RTEMS_RFS_DIR_ENTRY_EMPTY)                     
          break;                                                      
                                                                      
        if (rtems_rfs_dir_entry_valid (fs, elength, *ino))            
4001bc5c:	80 a4 c0 04 	cmp  %l3, %g4                                  
4001bc60:	1a bf ff f0 	bcc  4001bc20 <rtems_rfs_dir_lookup_ino+0x2c0> <== NEVER TAKEN
4001bc64:	80 a0 a0 00 	cmp  %g2, 0                                    
4001bc68:	02 bf ff ef 	be  4001bc24 <rtems_rfs_dir_lookup_ino+0x2c4>  <== NEVER TAKEN
4001bc6c:	90 10 20 00 	clr  %o0                                       
4001bc70:	c8 04 a0 14 	ld  [ %l2 + 0x14 ], %g4                        
4001bc74:	80 a0 80 04 	cmp  %g2, %g4                                  
4001bc78:	18 bf ff eb 	bgu  4001bc24 <rtems_rfs_dir_lookup_ino+0x2c4> <== NEVER TAKEN
4001bc7c:	c2 07 bf 9c 	ld  [ %fp + -100 ], %g1                        
                    rtems_rfs_inode_ino (inode), elength, *ino, map.bpos.boff);
          rc = EIO;                                                   
          break;                                                      
        }                                                             
                                                                      
        if (ehash == hash)                                            
4001bc80:	80 a0 c0 01 	cmp  %g3, %g1                                  
4001bc84:	12 80 00 36 	bne  4001bd5c <rtems_rfs_dir_lookup_ino+0x3fc> 
4001bc88:	c4 07 bf c4 	ld  [ %fp + -60 ], %g2                         
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_CHECK)) 
4001bc8c:	90 10 20 00 	clr  %o0                                       
4001bc90:	7f ff de 6f 	call  4001364c <rtems_rfs_trace>               
4001bc94:	13 02 00 00 	sethi  %hi(0x8000000), %o1                     
4001bc98:	80 a2 20 00 	cmp  %o0, 0                                    
4001bc9c:	02 80 00 12 	be  4001bce4 <rtems_rfs_dir_lookup_ino+0x384>  <== ALWAYS TAKEN
4001bca0:	90 04 60 0a 	add  %l1, 0xa, %o0                             
            printf ("rtems-rfs: dir-lookup-ino: "                     
                    "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));        
4001bca4:	c4 0c 60 01 	ldub  [ %l1 + 1 ], %g2                         <== NOT EXECUTED
4001bca8:	da 0c 40 00 	ldub  [ %l1 ], %o5                             <== NOT EXECUTED
4001bcac:	85 28 a0 10 	sll  %g2, 0x10, %g2                            <== NOT EXECUTED
4001bcb0:	9b 2b 60 18 	sll  %o5, 0x18, %o5                            <== NOT EXECUTED
4001bcb4:	9a 13 40 02 	or  %o5, %g2, %o5                              <== NOT EXECUTED
4001bcb8:	c4 0c 60 03 	ldub  [ %l1 + 3 ], %g2                         <== NOT EXECUTED
        }                                                             
                                                                      
        if (ehash == hash)                                            
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_CHECK)) 
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001bcbc:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== 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));        
4001bcc0:	9a 13 40 02 	or  %o5, %g2, %o5                              <== NOT EXECUTED
4001bcc4:	c4 0c 60 02 	ldub  [ %l1 + 2 ], %g2                         <== NOT EXECUTED
        }                                                             
                                                                      
        if (ehash == hash)                                            
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_CHECK)) 
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001bcc8:	d4 1f bf c0 	ldd  [ %fp + -64 ], %o2                        <== 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));        
4001bccc:	85 28 a0 08 	sll  %g2, 8, %g2                               <== NOT EXECUTED
        }                                                             
                                                                      
        if (ehash == hash)                                            
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_CHECK)) 
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001bcd0:	90 10 00 16 	mov  %l6, %o0                                  <== NOT EXECUTED
4001bcd4:	98 10 00 13 	mov  %l3, %o4                                  <== NOT EXECUTED
4001bcd8:	40 00 19 6c 	call  40022288 <printf>                        <== NOT EXECUTED
4001bcdc:	9a 13 40 02 	or  %o5, %g2, %o5                              <== 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)
4001bce0:	90 04 60 0a 	add  %l1, 0xa, %o0                             <== NOT EXECUTED
4001bce4:	92 10 00 1a 	mov  %i2, %o1                                  
4001bce8:	40 00 18 32 	call  40021db0 <memcmp>                        
4001bcec:	94 10 00 1b 	mov  %i3, %o2                                  
4001bcf0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001bcf4:	12 80 00 1a 	bne  4001bd5c <rtems_rfs_dir_lookup_ino+0x3fc> <== NEVER TAKEN
4001bcf8:	c4 07 bf c4 	ld  [ %fp + -60 ], %g2                         
          {                                                           
            *offset = rtems_rfs_block_map_pos (fs, &map);             
4001bcfc:	90 10 00 12 	mov  %l2, %o0                                  
4001bd00:	7f ff f9 3d 	call  4001a1f4 <rtems_rfs_block_get_pos>       
4001bd04:	92 07 bf c0 	add  %fp, -64, %o1                             
                                                                      
            if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_FOUND))
4001bd08:	90 10 20 00 	clr  %o0                                       
                    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);             
4001bd0c:	d2 27 40 00 	st  %o1, [ %i5 ]                               
                                                                      
            if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO_FOUND))
4001bd10:	7f ff de 4f 	call  4001364c <rtems_rfs_trace>               
4001bd14:	13 04 00 00 	sethi  %hi(0x10000000), %o1                    
4001bd18:	80 a2 20 00 	cmp  %o0, 0                                    
4001bd1c:	22 80 00 09 	be,a   4001bd40 <rtems_rfs_dir_lookup_ino+0x3e0><== ALWAYS TAKEN
4001bd20:	92 07 bf a4 	add  %fp, -92, %o1                             
              printf ("rtems-rfs: dir-lookup-ino: "                   
4001bd24:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001bd28:	d4 07 00 00 	ld  [ %i4 ], %o2                               <== NOT EXECUTED
4001bd2c:	d6 07 40 00 	ld  [ %i5 ], %o3                               <== NOT EXECUTED
4001bd30:	11 10 00 d3 	sethi  %hi(0x40034c00), %o0                    <== NOT EXECUTED
4001bd34:	40 00 19 55 	call  40022288 <printf>                        <== NOT EXECUTED
4001bd38:	90 12 23 90 	or  %o0, 0x390, %o0	! 40034f90 <CSWTCH.1+0x840><== NOT EXECUTED
                      "entry found in ino %" PRIu32 ", ino=%" PRIu32 " offset=%" PRIu32 "\n",
                      rtems_rfs_inode_ino (inode), *ino, *offset);    
                                                                      
            rtems_rfs_buffer_handle_close (fs, &entries);             
4001bd3c:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
4001bd40:	7f ff fe fe 	call  4001b938 <rtems_rfs_buffer_handle_close> 
4001bd44:	90 10 00 12 	mov  %l2, %o0                                  
            rtems_rfs_block_map_close (fs, &map);                     
4001bd48:	90 10 00 12 	mov  %l2, %o0                                  
4001bd4c:	7f ff f9 a8 	call  4001a3ec <rtems_rfs_block_map_close>     
4001bd50:	92 07 bf b0 	add  %fp, -80, %o1                             
            return 0;                                                 
4001bd54:	81 c7 e0 08 	ret                                            
4001bd58:	81 e8 00 00 	restore                                        
          }                                                           
        }                                                             
                                                                      
        map.bpos.boff += elength;                                     
        entry += elength;                                             
4001bd5c:	a2 04 40 13 	add  %l1, %l3, %l1                             
            rtems_rfs_block_map_close (fs, &map);                     
            return 0;                                                 
          }                                                           
        }                                                             
                                                                      
        map.bpos.boff += elength;                                     
4001bd60:	84 00 80 13 	add  %g2, %l3, %g2                             
4001bd64:	10 bf ff 70 	b  4001bb24 <rtems_rfs_dir_lookup_ino+0x1c4>   
4001bd68:	c4 27 bf c4 	st  %g2, [ %fp + -60 ]                         
        entry += elength;                                             
      }                                                               
                                                                      
      if (rc == 0)                                                    
      {                                                               
        rc = rtems_rfs_block_map_next_block (fs, &map, &block);       
4001bd6c:	92 07 bf b0 	add  %fp, -80, %o1                             
4001bd70:	7f ff fa 8f 	call  4001a7ac <rtems_rfs_block_map_next_block>
4001bd74:	94 07 bf a0 	add  %fp, -96, %o2                             
        if ((rc > 0) && (rc != ENXIO))                                
4001bd78:	80 a2 20 06 	cmp  %o0, 6                                    
4001bd7c:	02 80 00 05 	be  4001bd90 <rtems_rfs_dir_lookup_ino+0x430>  <== ALWAYS TAKEN
4001bd80:	a0 10 00 08 	mov  %o0, %l0                                  
4001bd84:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bd88:	14 80 00 07 	bg  4001bda4 <rtems_rfs_dir_lookup_ino+0x444>  <== NOT EXECUTED
4001bd8c:	90 10 20 00 	clr  %o0                                       <== 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)                                              
4001bd90:	80 a4 20 06 	cmp  %l0, 6                                    
4001bd94:	22 bf ff 88 	be,a   4001bbb4 <rtems_rfs_dir_lookup_ino+0x254><== ALWAYS TAKEN
4001bd98:	a0 10 20 02 	mov  2, %l0                                    
      rtems_rfs_buffer_handle_close (fs, &entries);                   
      rtems_rfs_block_map_close (fs, &map);                           
      return rc;                                                      
    }                                                                 
                                                                      
    while ((rc == 0) && block)                                        
4001bd9c:	10 bf ff 87 	b  4001bbb8 <rtems_rfs_dir_lookup_ino+0x258>   <== NOT EXECUTED
4001bda0:	80 a4 20 00 	cmp  %l0, 0                                    <== NOT EXECUTED
      if (rc == 0)                                                    
      {                                                               
        rc = rtems_rfs_block_map_next_block (fs, &map, &block);       
        if ((rc > 0) && (rc != ENXIO))                                
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))       
4001bda4:	7f ff de 2a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bda8:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     <== NOT EXECUTED
4001bdac:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bdb0:	22 bf ff f9 	be,a   4001bd94 <rtems_rfs_dir_lookup_ino+0x434><== NOT EXECUTED
4001bdb4:	80 a4 20 06 	cmp  %l0, 6                                    <== NOT EXECUTED
            printf ("rtems-rfs: dir-lookup-ino: "                     
4001bdb8:	f0 06 60 08 	ld  [ %i1 + 8 ], %i0                           <== NOT EXECUTED
4001bdbc:	40 00 1d 74 	call  4002338c <strerror>                      <== NOT EXECUTED
4001bdc0:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001bdc4:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001bdc8:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001bdcc:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
4001bdd0:	40 00 19 2e 	call  40022288 <printf>                        <== NOT EXECUTED
4001bdd4:	90 10 00 17 	mov  %l7, %o0                                  <== NOT EXECUTED
      rtems_rfs_buffer_handle_close (fs, &entries);                   
      rtems_rfs_block_map_close (fs, &map);                           
      return rc;                                                      
    }                                                                 
                                                                      
    while ((rc == 0) && block)                                        
4001bdd8:	10 bf ff 78 	b  4001bbb8 <rtems_rfs_dir_lookup_ino+0x258>   <== NOT EXECUTED
4001bddc:	80 a4 20 00 	cmp  %l0, 0                                    <== NOT EXECUTED
    }                                                                 
                                                                      
    if ((rc == 0) && (block == 0))                                    
    {                                                                 
      rc = EIO;                                                       
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_LOOKUP_INO))           
4001bde0:	7f ff de 1b 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001bde4:	13 01 00 00 	sethi  %hi(0x4000000), %o1                     <== NOT EXECUTED
4001bde8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001bdec:	02 80 00 0c 	be  4001be1c <rtems_rfs_dir_lookup_ino+0x4bc>  <== NOT EXECUTED
4001bdf0:	a0 10 20 05 	mov  5, %l0                                    <== NOT EXECUTED
        printf ("rtems-rfs: dir-lookup-ino: block is 0 in ino %" PRIu32 ": %d: %s\n",
4001bdf4:	fa 06 60 08 	ld  [ %i1 + 8 ], %i5                           <== NOT EXECUTED
4001bdf8:	40 00 1d 65 	call  4002338c <strerror>                      <== NOT EXECUTED
4001bdfc:	90 10 20 05 	mov  5, %o0                                    <== NOT EXECUTED
4001be00:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001be04:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001be08:	94 10 20 05 	mov  5, %o2                                    <== NOT EXECUTED
4001be0c:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001be10:	40 00 19 1e 	call  40022288 <printf>                        <== NOT EXECUTED
4001be14:	90 12 20 28 	or  %o0, 0x28, %o0	! 40035028 <CSWTCH.1+0x8d8> <== NOT EXECUTED
      }                                                               
    }                                                                 
                                                                      
    if ((rc == 0) && (block == 0))                                    
    {                                                                 
      rc = EIO;                                                       
4001be18:	a0 10 20 05 	mov  5, %l0                                    <== 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);                       
4001be1c:	92 07 bf a4 	add  %fp, -92, %o1                             <== NOT EXECUTED
4001be20:	7f ff fe c6 	call  4001b938 <rtems_rfs_buffer_handle_close> 
4001be24:	90 10 00 12 	mov  %l2, %o0                                  
  rtems_rfs_block_map_close (fs, &map);                               
4001be28:	90 10 00 12 	mov  %l2, %o0                                  
4001be2c:	92 07 bf b0 	add  %fp, -80, %o1                             
4001be30:	7f ff f9 6f 	call  4001a3ec <rtems_rfs_block_map_close>     
4001be34:	b0 10 00 10 	mov  %l0, %i0                                  
  return rc;                                                          
4001be38:	81 c7 e0 08 	ret                                            
4001be3c:	81 e8 00 00 	restore                                        
}                                                                     
4001be40:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001be44:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001c5ac <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) {
4001c5ac:	9d e3 bf 40 	save  %sp, -192, %sp                           
  rtems_rfs_block_map     map;                                        
  rtems_rfs_buffer_handle buffer;                                     
  rtems_rfs_block_no      block;                                      
  int                     rc;                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                     
4001c5b0:	90 10 20 00 	clr  %o0                                       
4001c5b4:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
4001c5b8:	7f ff dc 25 	call  4001364c <rtems_rfs_trace>               
4001c5bc:	a4 10 00 18 	mov  %i0, %l2                                  
4001c5c0:	80 a2 20 00 	cmp  %o0, 0                                    
4001c5c4:	22 80 00 09 	be,a   4001c5e8 <rtems_rfs_dir_read+0x3c>      <== ALWAYS TAKEN
4001c5c8:	c0 27 40 00 	clr  [ %i5 ]                                   
    printf ("rtems-rfs: dir-read: dir=%" PRId32 " offset=%" PRId64 "\n",
4001c5cc:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001c5d0:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c5d4:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
4001c5d8:	90 12 23 48 	or  %o0, 0x348, %o0                            <== NOT EXECUTED
4001c5dc:	40 00 17 2b 	call  40022288 <printf>                        <== NOT EXECUTED
4001c5e0:	96 10 00 1b 	mov  %i3, %o3                                  <== NOT EXECUTED
            rtems_rfs_inode_ino (dir), offset);                       
                                                                      
  *length = 0;                                                        
4001c5e4:	c0 27 40 00 	clr  [ %i5 ]                                   <== NOT EXECUTED
                                                                      
  rc = rtems_rfs_block_map_open (fs, dir, &map);                      
4001c5e8:	90 10 00 12 	mov  %l2, %o0                                  
4001c5ec:	92 10 00 19 	mov  %i1, %o1                                  
4001c5f0:	7f ff f7 21 	call  4001a274 <rtems_rfs_block_map_open>      
4001c5f4:	94 07 bf b0 	add  %fp, -80, %o2                             
  if (rc > 0)                                                         
4001c5f8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c5fc:	14 80 00 c9 	bg  4001c920 <rtems_rfs_dir_read+0x374>        <== NEVER TAKEN
4001c600:	90 10 00 1a 	mov  %i2, %o0                                  
    return rc;                                                        
                                                                      
  if (((rtems_rfs_fs_block_size (fs) -                                
        (offset % rtems_rfs_fs_block_size (fs))) <= RTEMS_RFS_DIR_ENTRY_SIZE))
4001c604:	e0 04 a0 08 	ld  [ %l2 + 8 ], %l0                           
4001c608:	a2 10 00 10 	mov  %l0, %l1                                  
4001c60c:	92 10 00 1b 	mov  %i3, %o1                                  
4001c610:	a0 10 20 00 	clr  %l0                                       
4001c614:	96 10 00 11 	mov  %l1, %o3                                  
4001c618:	40 00 4a db 	call  4002f184 <__moddi3>                      
4001c61c:	94 10 00 10 	mov  %l0, %o2                                  
                                                                      
  rc = rtems_rfs_block_map_open (fs, dir, &map);                      
  if (rc > 0)                                                         
    return rc;                                                        
                                                                      
  if (((rtems_rfs_fs_block_size (fs) -                                
4001c620:	92 a4 40 09 	subcc  %l1, %o1, %o1                           
4001c624:	90 64 00 08 	subx  %l0, %o0, %o0                            
4001c628:	80 a2 20 00 	cmp  %o0, 0                                    
4001c62c:	34 80 00 17 	bg,a   4001c688 <rtems_rfs_dir_read+0xdc>      <== NEVER TAKEN
4001c630:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
4001c634:	80 a2 20 00 	cmp  %o0, 0                                    
4001c638:	12 80 00 06 	bne  4001c650 <rtems_rfs_dir_read+0xa4>        <== NEVER TAKEN
4001c63c:	90 10 00 1a 	mov  %i2, %o0                                  
4001c640:	80 a2 60 0a 	cmp  %o1, 0xa                                  
4001c644:	18 80 00 11 	bgu  4001c688 <rtems_rfs_dir_read+0xdc>        <== ALWAYS TAKEN
4001c648:	90 10 00 12 	mov  %l2, %o0                                  
        (offset % rtems_rfs_fs_block_size (fs))) <= RTEMS_RFS_DIR_ENTRY_SIZE))
    offset = (((offset / rtems_rfs_fs_block_size (fs)) + 1) *         
4001c64c:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
4001c650:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001c654:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
4001c658:	40 00 49 d9 	call  4002edbc <__divdi3>                      <== NOT EXECUTED
4001c65c:	96 10 00 11 	mov  %l1, %o3                                  <== NOT EXECUTED
4001c660:	86 82 60 01 	addcc  %o1, 1, %g3                             <== NOT EXECUTED
4001c664:	84 42 20 00 	addx  %o0, 0, %g2                              <== NOT EXECUTED
4001c668:	92 10 00 03 	mov  %g3, %o1                                  <== NOT EXECUTED
4001c66c:	90 10 00 02 	mov  %g2, %o0                                  <== NOT EXECUTED
4001c670:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
4001c674:	40 00 49 8e 	call  4002ecac <__muldi3>                      <== NOT EXECUTED
4001c678:	96 10 00 11 	mov  %l1, %o3                                  <== NOT EXECUTED
4001c67c:	b4 10 00 08 	mov  %o0, %i2                                  <== NOT EXECUTED
4001c680:	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);           
4001c684:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
4001c688:	92 07 bf b0 	add  %fp, -80, %o1                             
4001c68c:	94 10 00 1a 	mov  %i2, %o2                                  
4001c690:	96 10 00 1b 	mov  %i3, %o3                                  
4001c694:	7f ff f8 29 	call  4001a738 <rtems_rfs_block_map_seek>      
4001c698:	98 07 bf a0 	add  %fp, -96, %o4                             
  if (rc > 0)                                                         
4001c69c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c6a0:	04 80 00 06 	ble  4001c6b8 <rtems_rfs_dir_read+0x10c>       <== ALWAYS TAKEN
4001c6a4:	80 a6 20 06 	cmp  %i0, 6                                    
  {                                                                   
    if (rc == ENXIO)                                                  
4001c6a8:	22 80 00 9b 	be,a   4001c914 <rtems_rfs_dir_read+0x368>     <== NOT EXECUTED
4001c6ac:	b0 10 20 02 	mov  2, %i0                                    <== NOT EXECUTED
    if (rc == ENXIO)                                                  
      rc = ENOENT;                                                    
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
  rtems_rfs_block_map_close (fs, &map);                               
4001c6b0:	10 80 00 9a 	b  4001c918 <rtems_rfs_dir_read+0x36c>         <== NOT EXECUTED
4001c6b4:	90 10 00 12 	mov  %l2, %o0                                  <== 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)                         
4001c6b8:	2b 00 00 3f 	sethi  %hi(0xfc00), %l5                        
    }                                                                 
                                                                      
    *length += rtems_rfs_fs_block_size (fs) - map.bpos.boff;          
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                   
      printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
4001c6bc:	2d 10 00 d4 	sethi  %hi(0x40035000), %l6                    
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001c6c0:	c0 2f bf a4 	clrb  [ %fp + -92 ]                            
  handle->bnum  = 0;                                                  
4001c6c4:	c0 27 bf a8 	clr  [ %fp + -88 ]                             
  handle->buffer = NULL;                                              
4001c6c8:	c0 27 bf ac 	clr  [ %fp + -84 ]                             
    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)                         
4001c6cc:	aa 15 63 ff 	or  %l5, 0x3ff, %l5                            
    }                                                                 
                                                                      
    *length += rtems_rfs_fs_block_size (fs) - map.bpos.boff;          
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                   
      printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
4001c6d0:	ac 15 a3 f8 	or  %l6, 0x3f8, %l6                            
    uint8_t*      entry;                                              
    rtems_rfs_ino eino;                                               
    int           elength;                                            
    int           remaining;                                          
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs, &buffer, block, true);  
4001c6d4:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         
4001c6d8:	90 10 00 12 	mov  %l2, %o0                                  
4001c6dc:	92 07 bf a4 	add  %fp, -92, %o1                             
4001c6e0:	7f ff fa df 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001c6e4:	96 10 20 01 	mov  1, %o3                                    
    if (rc > 0)                                                       
4001c6e8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001c6ec:	14 80 00 87 	bg  4001c908 <rtems_rfs_dir_read+0x35c>        <== NEVER TAKEN
4001c6f0:	c2 07 bf ac 	ld  [ %fp + -84 ], %g1                         
      rtems_rfs_block_map_close (fs, &map);                           
      return rc;                                                      
    }                                                                 
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
    entry += map.bpos.boff;                                           
4001c6f4:	e6 07 bf c4 	ld  [ %fp + -60 ], %l3                         
      rtems_rfs_buffer_handle_close (fs, &buffer);                    
      rtems_rfs_block_map_close (fs, &map);                           
      return rc;                                                      
    }                                                                 
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
4001c6f8:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
    entry += map.bpos.boff;                                           
4001c6fc:	a0 00 40 13 	add  %g1, %l3, %l0                             
                                                                      
    elength = rtems_rfs_dir_entry_length (entry);                     
4001c700:	c4 0c 20 09 	ldub  [ %l0 + 9 ], %g2                         
4001c704:	e2 0c 20 08 	ldub  [ %l0 + 8 ], %l1                         
    eino    = rtems_rfs_dir_entry_ino (entry);                        
4001c708:	e8 08 40 13 	ldub  [ %g1 + %l3 ], %l4                       
    }                                                                 
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
    entry += map.bpos.boff;                                           
                                                                      
    elength = rtems_rfs_dir_entry_length (entry);                     
4001c70c:	a3 2c 60 08 	sll  %l1, 8, %l1                               
    eino    = rtems_rfs_dir_entry_ino (entry);                        
4001c710:	c6 0c 20 01 	ldub  [ %l0 + 1 ], %g3                         
    }                                                                 
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
    entry += map.bpos.boff;                                           
                                                                      
    elength = rtems_rfs_dir_entry_length (entry);                     
4001c714:	a2 14 40 02 	or  %l1, %g2, %l1                              
    eino    = rtems_rfs_dir_entry_ino (entry);                        
4001c718:	c2 0c 20 02 	ldub  [ %l0 + 2 ], %g1                         
                                                                      
    if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)                         
4001c71c:	80 a4 40 15 	cmp  %l1, %l5                                  
4001c720:	02 80 00 5d 	be  4001c894 <rtems_rfs_dir_read+0x2e8>        
4001c724:	c4 0c 20 03 	ldub  [ %l0 + 3 ], %g2                         
                                                                      
    entry  = rtems_rfs_buffer_data (&buffer);                         
    entry += map.bpos.boff;                                           
                                                                      
    elength = rtems_rfs_dir_entry_length (entry);                     
    eino    = rtems_rfs_dir_entry_ino (entry);                        
4001c728:	a9 2d 20 18 	sll  %l4, 0x18, %l4                            
4001c72c:	86 08 e0 ff 	and  %g3, 0xff, %g3                            
4001c730:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
4001c734:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
4001c738:	82 08 60 ff 	and  %g1, 0xff, %g1                            
4001c73c:	a8 15 00 03 	or  %l4, %g3, %l4                              
4001c740:	83 28 60 08 	sll  %g1, 8, %g1                               
4001c744:	a8 15 00 02 	or  %l4, %g2, %l4                              
                                                                      
    if (elength != RTEMS_RFS_DIR_ENTRY_EMPTY)                         
    {                                                                 
      if (rtems_rfs_dir_entry_valid (fs, elength, eino))              
4001c748:	80 a4 60 0a 	cmp  %l1, 0xa                                  
4001c74c:	04 80 00 0d 	ble  4001c780 <rtems_rfs_dir_read+0x1d4>       <== NEVER TAKEN
4001c750:	a8 15 00 01 	or  %l4, %g1, %l4                              
4001c754:	c2 04 a0 1c 	ld  [ %l2 + 0x1c ], %g1                        
4001c758:	80 a4 40 01 	cmp  %l1, %g1                                  
4001c75c:	1a 80 00 0a 	bcc  4001c784 <rtems_rfs_dir_read+0x1d8>       <== NEVER TAKEN
4001c760:	90 10 20 00 	clr  %o0                                       
4001c764:	80 a5 20 00 	cmp  %l4, 0                                    
4001c768:	02 80 00 08 	be  4001c788 <rtems_rfs_dir_read+0x1dc>        <== NEVER TAKEN
4001c76c:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
4001c770:	c2 04 a0 14 	ld  [ %l2 + 0x14 ], %g1                        
4001c774:	80 a5 00 01 	cmp  %l4, %g1                                  
4001c778:	08 80 00 12 	bleu  4001c7c0 <rtems_rfs_dir_read+0x214>      <== ALWAYS TAKEN
4001c77c:	90 10 00 1c 	mov  %i4, %o0                                  
      {                                                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))               
4001c780:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001c784:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    <== NOT EXECUTED
4001c788:	7f ff db b1 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001c78c:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
4001c790:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001c794:	22 80 00 5e 	be,a   4001c90c <rtems_rfs_dir_read+0x360>     <== NOT EXECUTED
4001c798:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
          printf ("rtems-rfs: dir-read: "                             
4001c79c:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
4001c7a0:	d8 07 bf c4 	ld  [ %fp + -60 ], %o4                         <== NOT EXECUTED
4001c7a4:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c7a8:	94 10 00 11 	mov  %l1, %o2                                  <== NOT EXECUTED
4001c7ac:	96 10 00 14 	mov  %l4, %o3                                  <== NOT EXECUTED
4001c7b0:	40 00 16 b6 	call  40022288 <printf>                        <== NOT EXECUTED
4001c7b4:	90 12 23 78 	or  %o0, 0x378, %o0                            <== NOT EXECUTED
    rc = rtems_rfs_block_map_next_block (fs, &map, &block);           
    if (rc == ENXIO)                                                  
      rc = ENOENT;                                                    
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c7b8:	10 80 00 55 	b  4001c90c <rtems_rfs_dir_read+0x360>         <== NOT EXECUTED
4001c7bc:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
                  rtems_rfs_inode_ino (dir), elength, eino, map.bpos.boff);
        rc = EIO;                                                     
        break;                                                        
      }                                                               
                                                                      
      memset (dirent, 0, sizeof (struct dirent));                     
4001c7c0:	92 10 20 00 	clr  %o1                                       
4001c7c4:	40 00 16 38 	call  400220a4 <memset>                        
4001c7c8:	94 10 21 18 	mov  0x118, %o2                                
      dirent->d_off = offset;                                         
      dirent->d_reclen = sizeof (struct dirent);                      
4001c7cc:	82 10 21 18 	mov  0x118, %g1                                
4001c7d0:	c2 37 20 10 	sth  %g1, [ %i4 + 0x10 ]                       
                                                                      
      *length += elength;                                             
4001c7d4:	c2 07 40 00 	ld  [ %i5 ], %g1                               
        rc = EIO;                                                     
        break;                                                        
      }                                                               
                                                                      
      memset (dirent, 0, sizeof (struct dirent));                     
      dirent->d_off = offset;                                         
4001c7d8:	f4 3f 20 08 	std  %i2, [ %i4 + 8 ]                          
      dirent->d_reclen = sizeof (struct dirent);                      
                                                                      
      *length += elength;                                             
4001c7dc:	82 04 40 01 	add  %l1, %g1, %g1                             
4001c7e0:	c2 27 40 00 	st  %g1, [ %i5 ]                               
                                                                      
      remaining = rtems_rfs_fs_block_size (fs) - (map.bpos.boff + elength);
4001c7e4:	c4 04 a0 08 	ld  [ %l2 + 8 ], %g2                           
4001c7e8:	a6 20 80 13 	sub  %g2, %l3, %l3                             
4001c7ec:	a6 24 c0 11 	sub  %l3, %l1, %l3                             
                                                                      
      if (remaining <= RTEMS_RFS_DIR_ENTRY_SIZE)                      
4001c7f0:	80 a4 e0 0a 	cmp  %l3, 0xa                                  
4001c7f4:	14 80 00 04 	bg  4001c804 <rtems_rfs_dir_read+0x258>        <== ALWAYS TAKEN
4001c7f8:	a2 04 7f f6 	add  %l1, -10, %l1                             
        *length += remaining;                                         
4001c7fc:	82 04 c0 01 	add  %l3, %g1, %g1                             <== NOT EXECUTED
4001c800:	c2 27 40 00 	st  %g1, [ %i5 ]                               <== NOT EXECUTED
4001c804:	80 a4 60 ff 	cmp  %l1, 0xff                                 
4001c808:	34 80 00 02 	bg,a   4001c810 <rtems_rfs_dir_read+0x264>     <== NEVER TAKEN
4001c80c:	a2 10 20 ff 	mov  0xff, %l1                                 <== NOT EXECUTED
                                                                      
      elength -= RTEMS_RFS_DIR_ENTRY_SIZE;                            
      if (elength > NAME_MAX)                                         
        elength = NAME_MAX;                                           
                                                                      
      memcpy (dirent->d_name, entry + RTEMS_RFS_DIR_ENTRY_SIZE, elength);
4001c810:	92 04 20 0a 	add  %l0, 0xa, %o1                             
4001c814:	94 10 00 11 	mov  %l1, %o2                                  
4001c818:	ba 07 20 14 	add  %i4, 0x14, %i5                            
4001c81c:	40 00 15 8f 	call  40021e58 <memcpy>                        
4001c820:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
      dirent->d_ino = rtems_rfs_dir_entry_ino (entry);                
4001c824:	c4 0c 00 00 	ldub  [ %l0 ], %g2                             
4001c828:	c2 0c 20 01 	ldub  [ %l0 + 1 ], %g1                         
4001c82c:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001c830:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001c834:	82 10 80 01 	or  %g2, %g1, %g1                              
4001c838:	c4 0c 20 03 	ldub  [ %l0 + 3 ], %g2                         
      dirent->d_namlen = elength;                                     
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                 
4001c83c:	90 10 20 00 	clr  %o0                                       
      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);                
4001c840:	82 10 40 02 	or  %g1, %g2, %g1                              
4001c844:	c4 0c 20 02 	ldub  [ %l0 + 2 ], %g2                         
      dirent->d_namlen = elength;                                     
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                 
4001c848:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
      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);                
4001c84c:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001c850:	82 10 40 02 	or  %g1, %g2, %g1                              
      dirent->d_namlen = elength;                                     
4001c854:	e2 37 20 12 	sth  %l1, [ %i4 + 0x12 ]                       
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                 
4001c858:	7f ff db 7d 	call  4001364c <rtems_rfs_trace>               
4001c85c:	c2 27 00 00 	st  %g1, [ %i4 ]                               
4001c860:	80 a2 20 00 	cmp  %o0, 0                                    
4001c864:	22 80 00 2a 	be,a   4001c90c <rtems_rfs_dir_read+0x360>     <== ALWAYS TAKEN
4001c868:	90 10 00 12 	mov  %l2, %o0                                  
        printf ("rtems-rfs: dir-read: found off:%" PRIooff_t " ino:%ld name=%s\n",
4001c86c:	c4 1f 20 08 	ldd  [ %i4 + 8 ], %g2                          <== NOT EXECUTED
4001c870:	d6 07 00 00 	ld  [ %i4 ], %o3                               <== NOT EXECUTED
4001c874:	11 10 00 d4 	sethi  %hi(0x40035000), %o0                    <== NOT EXECUTED
4001c878:	92 10 00 02 	mov  %g2, %o1                                  <== NOT EXECUTED
4001c87c:	94 10 00 03 	mov  %g3, %o2                                  <== NOT EXECUTED
4001c880:	98 10 00 1d 	mov  %i5, %o4                                  <== NOT EXECUTED
4001c884:	40 00 16 81 	call  40022288 <printf>                        <== NOT EXECUTED
4001c888:	90 12 23 c0 	or  %o0, 0x3c0, %o0                            <== NOT EXECUTED
    rc = rtems_rfs_block_map_next_block (fs, &map, &block);           
    if (rc == ENXIO)                                                  
      rc = ENOENT;                                                    
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c88c:	10 80 00 20 	b  4001c90c <rtems_rfs_dir_read+0x360>         <== NOT EXECUTED
4001c890:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
        printf ("rtems-rfs: dir-read: found off:%" PRIooff_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;          
4001c894:	c2 04 a0 08 	ld  [ %l2 + 8 ], %g1                           
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                   
4001c898:	90 10 20 00 	clr  %o0                                       
        printf ("rtems-rfs: dir-read: found off:%" PRIooff_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;          
4001c89c:	a6 20 40 13 	sub  %g1, %l3, %l3                             
4001c8a0:	c2 07 40 00 	ld  [ %i5 ], %g1                               
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                   
4001c8a4:	13 20 00 00 	sethi  %hi(0x80000000), %o1                    
        printf ("rtems-rfs: dir-read: found off:%" PRIooff_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;          
4001c8a8:	a6 00 40 13 	add  %g1, %l3, %l3                             
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_DIR_READ))                   
4001c8ac:	7f ff db 68 	call  4001364c <rtems_rfs_trace>               
4001c8b0:	e6 27 40 00 	st  %l3, [ %i5 ]                               
4001c8b4:	80 a2 20 00 	cmp  %o0, 0                                    
4001c8b8:	02 80 00 08 	be  4001c8d8 <rtems_rfs_dir_read+0x32c>        <== ALWAYS TAKEN
4001c8bc:	90 10 00 12 	mov  %l2, %o0                                  
      printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
4001c8c0:	d6 07 40 00 	ld  [ %i5 ], %o3                               <== NOT EXECUTED
4001c8c4:	90 10 00 16 	mov  %l6, %o0                                  <== NOT EXECUTED
4001c8c8:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001c8cc:	40 00 16 6f 	call  40022288 <printf>                        <== NOT EXECUTED
4001c8d0:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
              offset, *length);                                       
                                                                      
    rc = rtems_rfs_block_map_next_block (fs, &map, &block);           
4001c8d4:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
4001c8d8:	92 07 bf b0 	add  %fp, -80, %o1                             
4001c8dc:	7f ff f7 b4 	call  4001a7ac <rtems_rfs_block_map_next_block>
4001c8e0:	94 07 bf a0 	add  %fp, -96, %o2                             
    if (rc == ENXIO)                                                  
4001c8e4:	80 a2 20 06 	cmp  %o0, 6                                    
4001c8e8:	02 80 00 07 	be  4001c904 <rtems_rfs_dir_read+0x358>        <== ALWAYS TAKEN
4001c8ec:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
  /*                                                                  
   * Look for an empty entry and if this is the last block that is the end of
   * the directory.                                                   
   */                                                                 
  while (rc == 0)                                                     
4001c8f0:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001c8f4:	02 bf ff 79 	be  4001c6d8 <rtems_rfs_dir_read+0x12c>        <== NOT EXECUTED
4001c8f8:	d4 07 bf a0 	ld  [ %fp + -96 ], %o2                         <== NOT EXECUTED
    rc = rtems_rfs_block_map_next_block (fs, &map, &block);           
    if (rc == ENXIO)                                                  
      rc = ENOENT;                                                    
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c8fc:	10 80 00 04 	b  4001c90c <rtems_rfs_dir_read+0x360>         <== NOT EXECUTED
4001c900:	90 10 00 12 	mov  %l2, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: dir-read: next block: off:%" PRId64 " length:%zd\n",
              offset, *length);                                       
                                                                      
    rc = rtems_rfs_block_map_next_block (fs, &map, &block);           
    if (rc == ENXIO)                                                  
      rc = ENOENT;                                                    
4001c904:	b0 10 20 02 	mov  2, %i0                                    
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &buffer);                        
4001c908:	90 10 00 12 	mov  %l2, %o0                                  
4001c90c:	7f ff fc 0b 	call  4001b938 <rtems_rfs_buffer_handle_close> 
4001c910:	92 07 bf a4 	add  %fp, -92, %o1                             
  rtems_rfs_block_map_close (fs, &map);                               
4001c914:	90 10 00 12 	mov  %l2, %o0                                  
4001c918:	7f ff f6 b5 	call  4001a3ec <rtems_rfs_block_map_close>     
4001c91c:	92 07 bf b0 	add  %fp, -80, %o1                             
  return rc;                                                          
}                                                                     
4001c920:	81 c7 e0 08 	ret                                            
4001c924:	81 e8 00 00 	restore                                        
                                                                      

4001cb40 <rtems_rfs_file_close>: } int rtems_rfs_file_close (rtems_rfs_file_system* fs, rtems_rfs_file_handle* handle) {
4001cb40:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rrc;                                                            
  int rc;                                                             
                                                                      
  rrc = 0;                                                            
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))                   
4001cb44:	90 10 20 10 	mov  0x10, %o0                                 
4001cb48:	7f ff da c1 	call  4001364c <rtems_rfs_trace>               
4001cb4c:	92 10 20 00 	clr  %o1                                       
4001cb50:	80 a2 20 00 	cmp  %o0, 0                                    
4001cb54:	22 80 00 08 	be,a   4001cb74 <rtems_rfs_file_close+0x34>    <== ALWAYS TAKEN
4001cb58:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        
    printf ("rtems-rfs: file-close: entry: ino=%" PRId32 "\n",        
4001cb5c:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        <== NOT EXECUTED
4001cb60:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001cb64:	d2 00 60 14 	ld  [ %g1 + 0x14 ], %o1                        <== NOT EXECUTED
4001cb68:	40 00 15 c8 	call  40022288 <printf>                        <== NOT EXECUTED
4001cb6c:	90 12 20 98 	or  %o0, 0x98, %o0                             <== NOT EXECUTED
            handle->shared->inode.ino);                               
                                                                      
  if (handle->shared->references > 0)                                 
4001cb70:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        <== NOT EXECUTED
4001cb74:	c2 02 60 08 	ld  [ %o1 + 8 ], %g1                           
4001cb78:	80 a0 60 00 	cmp  %g1, 0                                    
4001cb7c:	04 80 00 03 	ble  4001cb88 <rtems_rfs_file_close+0x48>      <== NEVER TAKEN
4001cb80:	82 00 7f ff 	add  %g1, -1, %g1                              
    handle->shared->references--;                                     
4001cb84:	c2 22 60 08 	st  %g1, [ %o1 + 8 ]                           
                                                                      
  if (handle->shared->references == 0)                                
4001cb88:	c2 02 60 08 	ld  [ %o1 + 8 ], %g1                           
4001cb8c:	80 a0 60 00 	cmp  %g1, 0                                    
4001cb90:	12 80 00 80 	bne  4001cd90 <rtems_rfs_file_close+0x250>     <== NEVER TAKEN
4001cb94:	ba 10 20 00 	clr  %i5                                       
  {                                                                   
    if (!rtems_rfs_inode_is_loaded (&handle->shared->inode))          
4001cb98:	c2 02 60 18 	ld  [ %o1 + 0x18 ], %g1                        
4001cb9c:	80 a0 60 00 	cmp  %g1, 0                                    
4001cba0:	32 80 00 09 	bne,a   4001cbc4 <rtems_rfs_file_close+0x84>   <== NEVER TAKEN
4001cba4:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        <== NOT EXECUTED
      rrc = rtems_rfs_inode_load (fs, &handle->shared->inode);        
4001cba8:	90 10 00 18 	mov  %i0, %o0                                  
4001cbac:	7f ff d4 1f 	call  40011c28 <rtems_rfs_inode_load>          
4001cbb0:	92 02 60 0c 	add  %o1, 0xc, %o1                             
                                                                      
    if (rrc == 0)                                                     
4001cbb4:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001cbb8:	32 80 00 3f 	bne,a   4001ccb4 <rtems_rfs_file_close+0x174>  <== NEVER TAKEN
4001cbbc:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        <== NOT EXECUTED
    {                                                                 
      /*                                                              
       * @todo This could be clever and only update if different.     
       */                                                             
      rtems_rfs_inode_set_atime (&handle->shared->inode,              
4001cbc0:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
4001cbc4:	c4 00 60 8c 	ld  [ %g1 + 0x8c ], %g2                        
 */                                                                   
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);                  
4001cbc8:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
4001cbcc:	89 30 a0 18 	srl  %g2, 0x18, %g4                            
4001cbd0:	c8 28 e0 10 	stb  %g4, [ %g3 + 0x10 ]                       
4001cbd4:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
4001cbd8:	89 30 a0 10 	srl  %g2, 0x10, %g4                            
4001cbdc:	c8 28 e0 11 	stb  %g4, [ %g3 + 0x11 ]                       
4001cbe0:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
4001cbe4:	89 30 a0 08 	srl  %g2, 8, %g4                               
4001cbe8:	c8 28 e0 12 	stb  %g4, [ %g3 + 0x12 ]                       
4001cbec:	c6 00 60 18 	ld  [ %g1 + 0x18 ], %g3                        
4001cbf0:	c4 28 e0 13 	stb  %g2, [ %g3 + 0x13 ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001cbf4:	86 10 20 01 	mov  1, %g3                                    
4001cbf8:	c6 28 60 1c 	stb  %g3, [ %g1 + 0x1c ]                       
                                 handle->shared->atime);              
      rtems_rfs_inode_set_mtime (&handle->shared->inode,              
4001cbfc:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
4001cc00:	c4 00 60 90 	ld  [ %g1 + 0x90 ], %g2                        
 */                                                                   
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);                  
4001cc04:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc08:	bb 30 a0 18 	srl  %g2, 0x18, %i5                            
4001cc0c:	fa 29 20 14 	stb  %i5, [ %g4 + 0x14 ]                       
4001cc10:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc14:	bb 30 a0 10 	srl  %g2, 0x10, %i5                            
4001cc18:	fa 29 20 15 	stb  %i5, [ %g4 + 0x15 ]                       
4001cc1c:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc20:	bb 30 a0 08 	srl  %g2, 8, %i5                               
4001cc24:	fa 29 20 16 	stb  %i5, [ %g4 + 0x16 ]                       
4001cc28:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc2c:	c4 29 20 17 	stb  %g2, [ %g4 + 0x17 ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001cc30:	c6 28 60 1c 	stb  %g3, [ %g1 + 0x1c ]                       
                                 handle->shared->mtime);              
      rtems_rfs_inode_set_ctime (&handle->shared->inode,              
4001cc34:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
4001cc38:	c4 00 60 94 	ld  [ %g1 + 0x94 ], %g2                        
 */                                                                   
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);                  
4001cc3c:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc40:	bb 30 a0 18 	srl  %g2, 0x18, %i5                            
4001cc44:	fa 29 20 18 	stb  %i5, [ %g4 + 0x18 ]                       
4001cc48:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc4c:	bb 30 a0 10 	srl  %g2, 0x10, %i5                            
4001cc50:	fa 29 20 19 	stb  %i5, [ %g4 + 0x19 ]                       
4001cc54:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc58:	bb 30 a0 08 	srl  %g2, 8, %i5                               
4001cc5c:	fa 29 20 1a 	stb  %i5, [ %g4 + 0x1a ]                       
4001cc60:	c8 00 60 18 	ld  [ %g1 + 0x18 ], %g4                        
4001cc64:	c4 29 20 1b 	stb  %g2, [ %g4 + 0x1b ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001cc68:	c6 28 60 1c 	stb  %g3, [ %g1 + 0x1c ]                       
                                 handle->shared->ctime);              
      if (!rtems_rfs_block_size_equal (&handle->shared->size,         
4001cc6c:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        
4001cc70:	c4 00 60 84 	ld  [ %g1 + 0x84 ], %g2                        
4001cc74:	c6 00 60 3c 	ld  [ %g1 + 0x3c ], %g3                        
4001cc78:	80 a0 80 03 	cmp  %g2, %g3                                  
4001cc7c:	32 80 00 08 	bne,a   4001cc9c <rtems_rfs_file_close+0x15c>  <== NEVER TAKEN
4001cc80:	c4 20 60 3c 	st  %g2, [ %g1 + 0x3c ]                        <== NOT EXECUTED
4001cc84:	c8 00 60 88 	ld  [ %g1 + 0x88 ], %g4                        
4001cc88:	c6 00 60 40 	ld  [ %g1 + 0x40 ], %g3                        
4001cc8c:	80 a1 00 03 	cmp  %g4, %g3                                  
4001cc90:	02 80 00 08 	be  4001ccb0 <rtems_rfs_file_close+0x170>      <== ALWAYS TAKEN
4001cc94:	ba 10 20 00 	clr  %i5                                       
 */                                                                   
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);                       
4001cc98:	c4 20 60 3c 	st  %g2, [ %g1 + 0x3c ]                        <== NOT EXECUTED
4001cc9c:	c4 00 60 88 	ld  [ %g1 + 0x88 ], %g2                        <== NOT EXECUTED
  map->dirty = true;                                                  
4001cca0:	ba 10 20 00 	clr  %i5                                       <== 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);                       
4001cca4:	c4 20 60 40 	st  %g2, [ %g1 + 0x40 ]                        <== NOT EXECUTED
  map->dirty = true;                                                  
4001cca8:	84 10 20 01 	mov  1, %g2                                    <== NOT EXECUTED
4001ccac:	c4 28 60 34 	stb  %g2, [ %g1 + 0x34 ]                       <== 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);        
4001ccb0:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        
4001ccb4:	90 10 00 18 	mov  %i0, %o0                                  
4001ccb8:	7f ff f5 cd 	call  4001a3ec <rtems_rfs_block_map_close>     
4001ccbc:	92 02 60 34 	add  %o1, 0x34, %o1                            
    if (rc > 0)                                                       
4001ccc0:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001ccc4:	04 80 00 14 	ble  4001cd14 <rtems_rfs_file_close+0x1d4>     <== ALWAYS TAKEN
4001ccc8:	90 10 20 10 	mov  0x10, %o0                                 
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))               
4001cccc:	7f ff da 60 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001ccd0:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001ccd4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ccd8:	02 80 00 0d 	be  4001cd0c <rtems_rfs_file_close+0x1cc>      <== NOT EXECUTED
4001ccdc:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
        printf ("rtems-rfs: file-close: map close error: ino=%" PRId32 ": %d: %s\n",
4001cce0:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        <== NOT EXECUTED
4001cce4:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
4001cce8:	40 00 19 a9 	call  4002338c <strerror>                      <== NOT EXECUTED
4001ccec:	f6 00 60 14 	ld  [ %g1 + 0x14 ], %i3                        <== NOT EXECUTED
4001ccf0:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001ccf4:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001ccf8:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001ccfc:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001cd00:	40 00 15 62 	call  40022288 <printf>                        <== NOT EXECUTED
4001cd04:	90 12 20 c0 	or  %o0, 0xc0, %o0	! 400354c0 <CSWTCH.1+0xd70> <== NOT EXECUTED
                handle->shared->inode.ino, rc, strerror (rc));        
      if (rrc == 0)                                                   
4001cd08:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
4001cd0c:	22 80 00 02 	be,a   4001cd14 <rtems_rfs_file_close+0x1d4>   <== NOT EXECUTED
4001cd10:	ba 10 00 1c 	mov  %i4, %i5                                  <== NOT EXECUTED
        rrc = rc;                                                     
    }                                                                 
                                                                      
    rc = rtems_rfs_inode_close (fs, &handle->shared->inode);          
4001cd14:	d2 06 60 1c 	ld  [ %i1 + 0x1c ], %o1                        
4001cd18:	90 10 00 18 	mov  %i0, %o0                                  
4001cd1c:	7f ff d4 62 	call  40011ea4 <rtems_rfs_inode_close>         
4001cd20:	92 02 60 0c 	add  %o1, 0xc, %o1                             
    if (rc > 0)                                                       
4001cd24:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001cd28:	04 80 00 14 	ble  4001cd78 <rtems_rfs_file_close+0x238>     <== ALWAYS TAKEN
4001cd2c:	90 10 20 10 	mov  0x10, %o0                                 
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))               
4001cd30:	7f ff da 47 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001cd34:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001cd38:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001cd3c:	02 80 00 0d 	be  4001cd70 <rtems_rfs_file_close+0x230>      <== NOT EXECUTED
4001cd40:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
        printf ("rtems-rfs: file-close: inode close error: ino=%" PRId32 ": %d: %s\n",
4001cd44:	c2 06 60 1c 	ld  [ %i1 + 0x1c ], %g1                        <== NOT EXECUTED
4001cd48:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
4001cd4c:	40 00 19 90 	call  4002338c <strerror>                      <== NOT EXECUTED
4001cd50:	f6 00 60 14 	ld  [ %g1 + 0x14 ], %i3                        <== NOT EXECUTED
4001cd54:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001cd58:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001cd5c:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001cd60:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001cd64:	40 00 15 49 	call  40022288 <printf>                        <== NOT EXECUTED
4001cd68:	90 12 21 00 	or  %o0, 0x100, %o0	! 40035500 <CSWTCH.1+0xdb0><== NOT EXECUTED
                handle->shared->inode.ino, rc, strerror (rc));        
      if (rrc == 0)                                                   
4001cd6c:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
4001cd70:	22 80 00 02 	be,a   4001cd78 <rtems_rfs_file_close+0x238>   <== NOT EXECUTED
4001cd74:	ba 10 00 1c 	mov  %i4, %i5                                  <== NOT EXECUTED
        rrc = rc;                                                     
    }                                                                 
                                                                      
    rtems_chain_extract_unprotected (&handle->shared->link);          
4001cd78:	d0 06 60 1c 	ld  [ %i1 + 0x1c ], %o0                        
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4001cd7c:	c4 02 00 00 	ld  [ %o0 ], %g2                               
  previous       = the_node->previous;                                
4001cd80:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           
  next->previous = previous;                                          
4001cd84:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
    free (handle->shared);                                            
4001cd88:	7f ff ac 69 	call  40007f2c <free>                          
4001cd8c:	c4 20 40 00 	st  %g2, [ %g1 ]                               
 */                                                                   
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);                       
4001cd90:	90 10 00 18 	mov  %i0, %o0                                  
4001cd94:	7f ff f8 a9 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001cd98:	92 06 60 04 	add  %i1, 4, %o1                               
  handle->dirty = false;                                              
4001cd9c:	c0 2e 60 04 	clrb  [ %i1 + 4 ]                              
  handle->bnum  = 0;                                                  
4001cda0:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
                                                                      
  rc = rtems_rfs_buffer_handle_close (fs, &handle->buffer);           
  if ((rrc == 0) && (rc > 0))                                         
    rrc = rc;                                                         
                                                                      
  if (rrc > 0)                                                        
4001cda4:	80 a7 60 00 	cmp  %i5, 0                                    
4001cda8:	04 80 00 0f 	ble  4001cde4 <rtems_rfs_file_close+0x2a4>     <== ALWAYS TAKEN
4001cdac:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_CLOSE))                 
4001cdb0:	90 10 20 10 	mov  0x10, %o0                                 <== NOT EXECUTED
4001cdb4:	7f ff da 26 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001cdb8:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001cdbc:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001cdc0:	22 80 00 0a 	be,a   4001cde8 <rtems_rfs_file_close+0x2a8>   <== NOT EXECUTED
4001cdc4:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: file-close: result: %d: %s\n", rrc, strerror (rrc));
4001cdc8:	40 00 19 71 	call  4002338c <strerror>                      <== NOT EXECUTED
4001cdcc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001cdd0:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001cdd4:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001cdd8:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001cddc:	40 00 15 2b 	call  40022288 <printf>                        <== NOT EXECUTED
4001cde0:	90 12 21 40 	or  %o0, 0x140, %o0	! 40035540 <CSWTCH.1+0xdf0><== NOT EXECUTED
  }                                                                   
                                                                      
  free (handle);                                                      
4001cde4:	90 10 00 19 	mov  %i1, %o0                                  
4001cde8:	7f ff ac 51 	call  40007f2c <free>                          
4001cdec:	b0 10 00 1d 	mov  %i5, %i0                                  
                                                                      
  return rrc;                                                         
}                                                                     
4001cdf0:	81 c7 e0 08 	ret                                            
4001cdf4:	81 e8 00 00 	restore                                        
                                                                      

4001d6e4 <rtems_rfs_file_get_shared>: */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next;
4001d6e4:	c2 02 20 74 	ld  [ %o0 + 0x74 ], %g1                        
RTEMS_INLINE_ROUTINE bool _Chain_Is_tail(                             
  const Chain_Control *the_chain,                                     
  const Chain_Node    *the_node                                       
)                                                                     
{                                                                     
  return (the_node == _Chain_Immutable_tail( the_chain ));            
4001d6e8:	90 02 20 78 	add  %o0, 0x78, %o0                            
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))               
4001d6ec:	80 a0 40 08 	cmp  %g1, %o0                                  
4001d6f0:	02 80 00 08 	be  4001d710 <rtems_rfs_file_get_shared+0x2c>  
4001d6f4:	01 00 00 00 	nop                                            
  {                                                                   
    rtems_rfs_file_shared* shared;                                    
    shared = (rtems_rfs_file_shared*) node;                           
    if (shared->inode.ino == ino)                                     
4001d6f8:	c4 00 60 14 	ld  [ %g1 + 0x14 ], %g2                        
4001d6fc:	80 a0 80 09 	cmp  %g2, %o1                                  
4001d700:	02 80 00 06 	be  4001d718 <rtems_rfs_file_get_shared+0x34>  <== ALWAYS TAKEN
4001d704:	01 00 00 00 	nop                                            
 * @param[in] the_node is the node to be operated upon.               
 *                                                                    
 * @return This method returns the next node on the chain.            
 */                                                                   
RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_next(              
  rtems_chain_node *the_node                                          
4001d708:	10 bf ff f9 	b  4001d6ec <rtems_rfs_file_get_shared+0x8>    <== NOT EXECUTED
4001d70c:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
4001d710:	81 c3 e0 08 	retl                                           
4001d714:	90 10 20 00 	clr  %o0                                       
      return shared;                                                  
    node = rtems_chain_next (node);                                   
  }                                                                   
  return NULL;                                                        
}                                                                     
4001d718:	81 c3 e0 08 	retl                                           
4001d71c:	90 10 00 01 	mov  %g1, %o0                                  
                                                                      

4001d01c <rtems_rfs_file_io_end>: int rtems_rfs_file_io_end (rtems_rfs_file_handle* handle, size_t size, bool read) {
4001d01c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  bool atime;                                                         
  bool mtime;                                                         
  bool length;                                                        
  int  rc = 0;                                                        
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001d020:	90 10 20 20 	mov  0x20, %o0                                 
4001d024:	92 10 20 00 	clr  %o1                                       
4001d028:	7f ff d9 89 	call  4001364c <rtems_rfs_trace>               
4001d02c:	ba 10 00 18 	mov  %i0, %i5                                  
4001d030:	80 a2 20 00 	cmp  %o0, 0                                    
4001d034:	22 80 00 0e 	be,a   4001d06c <rtems_rfs_file_io_end+0x50>   <== ALWAYS TAKEN
4001d038:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
    printf ("rtems-rfs: file-io:   end: %s size=%zu\n",               
4001d03c:	80 a6 a0 00 	cmp  %i2, 0                                    <== NOT EXECUTED
4001d040:	22 80 00 05 	be,a   4001d054 <rtems_rfs_file_io_end+0x38>   <== NOT EXECUTED
4001d044:	13 10 00 d5 	sethi  %hi(0x40035400), %o1                    <== NOT EXECUTED
4001d048:	13 10 00 d2 	sethi  %hi(0x40034800), %o1                    <== NOT EXECUTED
4001d04c:	10 80 00 03 	b  4001d058 <rtems_rfs_file_io_end+0x3c>       <== NOT EXECUTED
4001d050:	92 12 61 68 	or  %o1, 0x168, %o1	! 40034968 <CSWTCH.1+0x218><== NOT EXECUTED
4001d054:	92 12 61 68 	or  %o1, 0x168, %o1                            <== NOT EXECUTED
4001d058:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d05c:	94 10 00 19 	mov  %i1, %o2                                  <== NOT EXECUTED
4001d060:	40 00 14 8a 	call  40022288 <printf>                        <== NOT EXECUTED
4001d064:	90 12 22 28 	or  %o0, 0x228, %o0                            <== NOT EXECUTED
            read ? "read" : "write", size);                           
                                                                      
  if (rtems_rfs_buffer_handle_has_block (&handle->buffer))            
4001d068:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         <== NOT EXECUTED
4001d06c:	80 a0 60 00 	cmp  %g1, 0                                    
4001d070:	02 80 00 1e 	be  4001d0e8 <rtems_rfs_file_io_end+0xcc>      <== NEVER TAKEN
4001d074:	80 a6 a0 00 	cmp  %i2, 0                                    
  {                                                                   
    if (!read)                                                        
4001d078:	32 80 00 05 	bne,a   4001d08c <rtems_rfs_file_io_end+0x70>  
4001d07c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
      rtems_rfs_buffer_mark_dirty (rtems_rfs_file_buffer (handle));   
4001d080:	82 10 20 01 	mov  1, %g1                                    
4001d084:	c2 2f 60 04 	stb  %g1, [ %i5 + 4 ]                          
    rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle), 
4001d088:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
4001d08c:	92 07 60 04 	add  %i5, 4, %o1                               
4001d090:	7f ff f7 ea 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001d094:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
                                          rtems_rfs_file_buffer (handle));
    if (rc > 0)                                                       
4001d098:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001d09c:	04 80 00 14 	ble  4001d0ec <rtems_rfs_file_io_end+0xd0>     <== ALWAYS TAKEN
4001d0a0:	80 a6 a0 00 	cmp  %i2, 0                                    
    {                                                                 
      printf (                                                        
4001d0a4:	22 80 00 05 	be,a   4001d0b8 <rtems_rfs_file_io_end+0x9c>   <== NOT EXECUTED
4001d0a8:	3b 10 00 d5 	sethi  %hi(0x40035400), %i5                    <== NOT EXECUTED
4001d0ac:	3b 10 00 d2 	sethi  %hi(0x40034800), %i5                    <== NOT EXECUTED
4001d0b0:	10 80 00 03 	b  4001d0bc <rtems_rfs_file_io_end+0xa0>       <== NOT EXECUTED
4001d0b4:	ba 17 61 68 	or  %i5, 0x168, %i5	! 40034968 <CSWTCH.1+0x218><== NOT EXECUTED
4001d0b8:	ba 17 61 68 	or  %i5, 0x168, %i5                            <== NOT EXECUTED
4001d0bc:	40 00 18 b4 	call  4002338c <strerror>                      <== NOT EXECUTED
4001d0c0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001d0c4:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
4001d0c8:	98 10 00 08 	mov  %o0, %o4                                  <== NOT EXECUTED
4001d0cc:	94 10 00 19 	mov  %i1, %o2                                  <== NOT EXECUTED
4001d0d0:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d0d4:	96 10 00 18 	mov  %i0, %o3                                  <== NOT EXECUTED
4001d0d8:	40 00 14 6c 	call  40022288 <printf>                        <== NOT EXECUTED
4001d0dc:	90 12 22 50 	or  %o0, 0x250, %o0                            <== NOT EXECUTED
        "rtems-rfs: file-io:   end: error on release: %s size=%zu: %d: %s\n",
        read ? "read" : "write", size, rc, strerror (rc));            
                                                                      
      return rc;                                                      
4001d0e0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001d0e4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                       bool                   read)                   
{                                                                     
  bool atime;                                                         
  bool mtime;                                                         
  bool length;                                                        
  int  rc = 0;                                                        
4001d0e8:	b0 10 20 00 	clr  %i0                                       <== 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;                                          
4001d0ec:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4001d0f0:	b2 06 40 01 	add  %i1, %g1, %i1                             
                                                                      
  if (handle->bpos.boff >=                                            
      rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))           
4001d0f4:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
   * 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;                                          
4001d0f8:	f2 27 60 14 	st  %i1, [ %i5 + 0x14 ]                        
                                                                      
  if (handle->bpos.boff >=                                            
      rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))           
4001d0fc:	c4 00 60 98 	ld  [ %g1 + 0x98 ], %g2                        
4001d100:	c4 00 a0 08 	ld  [ %g2 + 8 ], %g2                           
   * 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;                                          
                                                                      
  if (handle->bpos.boff >=                                            
4001d104:	80 a6 40 02 	cmp  %i1, %g2                                  
4001d108:	0a 80 00 07 	bcs  4001d124 <rtems_rfs_file_io_end+0x108>    
4001d10c:	80 a6 a0 00 	cmp  %i2, 0                                    
      rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))           
  {                                                                   
    handle->bpos.bno++;                                               
4001d110:	c6 07 60 10 	ld  [ %i5 + 0x10 ], %g3                        
    handle->bpos.boff -= rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
4001d114:	b2 26 40 02 	sub  %i1, %g2, %i1                             
  handle->bpos.boff += size;                                          
                                                                      
  if (handle->bpos.boff >=                                            
      rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))           
  {                                                                   
    handle->bpos.bno++;                                               
4001d118:	86 00 e0 01 	inc  %g3                                       
    handle->bpos.boff -= rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
4001d11c:	f2 27 60 14 	st  %i1, [ %i5 + 0x14 ]                        
  handle->bpos.boff += size;                                          
                                                                      
  if (handle->bpos.boff >=                                            
      rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))           
  {                                                                   
    handle->bpos.bno++;                                               
4001d120:	c6 27 60 10 	st  %g3, [ %i5 + 0x10 ]                        
  }                                                                   
                                                                      
  length = false;                                                     
  mtime = !read;                                                      
                                                                      
  if (!read &&                                                        
4001d124:	12 80 00 19 	bne  4001d188 <rtems_rfs_file_io_end+0x16c>    
4001d128:	84 10 20 00 	clr  %g2                                       
      rtems_rfs_block_map_past_end (rtems_rfs_file_map (handle),      
4001d12c:	c6 07 60 10 	ld  [ %i5 + 0x10 ], %g3                        
  }                                                                   
                                                                      
  length = false;                                                     
  mtime = !read;                                                      
                                                                      
  if (!read &&                                                        
4001d130:	80 a0 e0 00 	cmp  %g3, 0                                    
4001d134:	02 80 00 05 	be  4001d148 <rtems_rfs_file_io_end+0x12c>     
4001d138:	c4 00 60 3c 	ld  [ %g1 + 0x3c ], %g2                        
      rtems_rfs_block_map_past_end (rtems_rfs_file_map (handle),      
4001d13c:	80 a0 a0 00 	cmp  %g2, 0                                    
4001d140:	22 80 00 0f 	be,a   4001d17c <rtems_rfs_file_io_end+0x160>  <== NEVER TAKEN
4001d144:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        <== NOT EXECUTED
4001d148:	80 a0 c0 02 	cmp  %g3, %g2                                  
4001d14c:	3a 80 00 0c 	bcc,a   4001d17c <rtems_rfs_file_io_end+0x160> 
4001d150:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        
4001d154:	88 00 bf ff 	add  %g2, -1, %g4                              
4001d158:	80 a0 c0 04 	cmp  %g3, %g4                                  
4001d15c:	12 80 00 0b 	bne  4001d188 <rtems_rfs_file_io_end+0x16c>    
4001d160:	84 10 20 00 	clr  %g2                                       
4001d164:	c8 07 60 14 	ld  [ %i5 + 0x14 ], %g4                        
4001d168:	c6 00 60 40 	ld  [ %g1 + 0x40 ], %g3                        
4001d16c:	80 a1 00 03 	cmp  %g4, %g3                                  
4001d170:	28 80 00 07 	bleu,a   4001d18c <rtems_rfs_file_io_end+0x170>
4001d174:	c2 07 40 00 	ld  [ %i5 ], %g1                               
 */                                                                   
static inline void                                                    
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,        
                                     rtems_rfs_block_off  offset)     
{                                                                     
  map->size.offset = offset;                                          
4001d178:	c4 07 60 14 	ld  [ %i5 + 0x14 ], %g2                        
4001d17c:	c4 20 60 40 	st  %g2, [ %g1 + 0x40 ]                        
  map->dirty = true;                                                  
4001d180:	84 10 20 01 	mov  1, %g2                                    
4001d184:	c4 28 60 34 	stb  %g2, [ %g1 + 0x34 ]                       
    rtems_rfs_block_map_set_size_offset (rtems_rfs_file_map (handle), 
                                         handle->bpos.boff);          
    length = true;                                                    
  }                                                                   
                                                                      
  atime  = rtems_rfs_file_update_atime (handle);                      
4001d188:	c2 07 40 00 	ld  [ %i5 ], %g1                               
  mtime  = rtems_rfs_file_update_mtime (handle) && mtime;             
4001d18c:	b8 10 20 00 	clr  %i4                                       
    rtems_rfs_block_map_set_size_offset (rtems_rfs_file_map (handle), 
                                         handle->bpos.boff);          
    length = true;                                                    
  }                                                                   
                                                                      
  atime  = rtems_rfs_file_update_atime (handle);                      
4001d190:	a2 08 60 01 	and  %g1, 1, %l1                               
  mtime  = rtems_rfs_file_update_mtime (handle) && mtime;             
4001d194:	80 88 60 02 	btst  2, %g1                                   
4001d198:	a2 1c 60 01 	xor  %l1, 1, %l1                               
4001d19c:	12 80 00 03 	bne  4001d1a8 <rtems_rfs_file_io_end+0x18c>    <== NEVER TAKEN
4001d1a0:	a0 0c 60 01 	and  %l1, 1, %l0                               
4001d1a4:	b8 1e a0 01 	xor  %i2, 1, %i4                               
4001d1a8:	b2 0f 20 01 	and  %i4, 1, %i1                               
  length = rtems_rfs_file_update_length (handle) && length;           
4001d1ac:	80 88 60 04 	btst  4, %g1                                   
4001d1b0:	12 80 00 03 	bne  4001d1bc <rtems_rfs_file_io_end+0x1a0>    <== NEVER TAKEN
4001d1b4:	b6 10 20 00 	clr  %i3                                       
4001d1b8:	b6 08 a0 ff 	and  %g2, 0xff, %i3                            
4001d1bc:	b6 0e e0 01 	and  %i3, 1, %i3                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001d1c0:	90 10 20 20 	mov  0x20, %o0                                 
4001d1c4:	92 10 20 00 	clr  %o1                                       
4001d1c8:	7f ff d9 21 	call  4001364c <rtems_rfs_trace>               
4001d1cc:	b6 0e e0 ff 	and  %i3, 0xff, %i3                            
4001d1d0:	80 a2 20 00 	cmp  %o0, 0                                    
4001d1d4:	22 80 00 14 	be,a   4001d224 <rtems_rfs_file_io_end+0x208>  <== ALWAYS TAKEN
4001d1d8:	b8 17 00 11 	or  %i4, %l1, %i4                              
    printf ("rtems-rfs: file-io:   end: pos=%" PRIu32 ":%" PRIu32 " %c %c %c\n",
4001d1dc:	80 a0 00 10 	cmp  %g0, %l0                                  <== NOT EXECUTED
4001d1e0:	d2 07 60 10 	ld  [ %i5 + 0x10 ], %o1                        <== NOT EXECUTED
4001d1e4:	96 40 3f ff 	addx  %g0, -1, %o3                             <== NOT EXECUTED
4001d1e8:	d4 07 60 14 	ld  [ %i5 + 0x14 ], %o2                        <== NOT EXECUTED
4001d1ec:	80 a0 00 19 	cmp  %g0, %i1                                  <== NOT EXECUTED
4001d1f0:	98 40 3f ff 	addx  %g0, -1, %o4                             <== NOT EXECUTED
4001d1f4:	80 a0 00 1b 	cmp  %g0, %i3                                  <== NOT EXECUTED
4001d1f8:	96 0a ff ec 	and  %o3, -20, %o3                             <== NOT EXECUTED
4001d1fc:	98 0b 3f e0 	and  %o4, -32, %o4                             <== NOT EXECUTED
4001d200:	9a 40 3f ff 	addx  %g0, -1, %o5                             <== NOT EXECUTED
4001d204:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d208:	9a 0b 7f e1 	and  %o5, -31, %o5                             <== NOT EXECUTED
4001d20c:	90 12 22 98 	or  %o0, 0x298, %o0                            <== NOT EXECUTED
4001d210:	96 02 e0 41 	add  %o3, 0x41, %o3                            <== NOT EXECUTED
4001d214:	98 03 20 4d 	add  %o4, 0x4d, %o4                            <== NOT EXECUTED
4001d218:	40 00 14 1c 	call  40022288 <printf>                        <== NOT EXECUTED
4001d21c:	9a 03 60 4c 	add  %o5, 0x4c, %o5                            <== NOT EXECUTED
            handle->bpos.bno, handle->bpos.boff,                      
            atime ? 'A' : '-', mtime ? 'M' : '-', length ? 'L' : '-');
                                                                      
  if (atime || mtime)                                                 
4001d220:	b8 17 00 11 	or  %i4, %l1, %i4                              <== NOT EXECUTED
4001d224:	80 8f 20 01 	btst  1, %i4                                   
4001d228:	02 80 00 13 	be  4001d274 <rtems_rfs_file_io_end+0x258>     <== NEVER TAKEN
4001d22c:	80 a6 e0 00 	cmp  %i3, 0                                    
  {                                                                   
    time_t now = time (NULL);                                         
4001d230:	40 00 24 27 	call  400262cc <time>                          
4001d234:	90 10 20 00 	clr  %o0                                       
    if (read && atime)                                                
4001d238:	80 a6 a0 00 	cmp  %i2, 0                                    
4001d23c:	02 80 00 07 	be  4001d258 <rtems_rfs_file_io_end+0x23c>     
4001d240:	80 a6 60 00 	cmp  %i1, 0                                    
4001d244:	80 a4 20 00 	cmp  %l0, 0                                    
4001d248:	02 80 00 04 	be  4001d258 <rtems_rfs_file_io_end+0x23c>     <== NEVER TAKEN
4001d24c:	80 a6 60 00 	cmp  %i1, 0                                    
      handle->shared->atime = now;                                    
4001d250:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
4001d254:	d0 20 60 8c 	st  %o0, [ %g1 + 0x8c ]                        
    if (!read && mtime)                                               
4001d258:	02 80 00 07 	be  4001d274 <rtems_rfs_file_io_end+0x258>     
4001d25c:	80 a6 e0 00 	cmp  %i3, 0                                    
4001d260:	80 a6 a0 01 	cmp  %i2, 1                                    
4001d264:	02 80 00 04 	be  4001d274 <rtems_rfs_file_io_end+0x258>     <== NEVER TAKEN
4001d268:	80 a6 e0 00 	cmp  %i3, 0                                    
      handle->shared->mtime = now;                                    
4001d26c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
4001d270:	d0 20 60 90 	st  %o0, [ %g1 + 0x90 ]                        
  }                                                                   
  if (length)                                                         
4001d274:	02 80 00 07 	be  4001d290 <rtems_rfs_file_io_end+0x274>     
4001d278:	01 00 00 00 	nop                                            
  {                                                                   
    handle->shared->size.count =                                      
      rtems_rfs_block_map_count (rtems_rfs_file_map (handle));        
4001d27c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
    if (!read && mtime)                                               
      handle->shared->mtime = now;                                    
  }                                                                   
  if (length)                                                         
  {                                                                   
    handle->shared->size.count =                                      
4001d280:	c4 00 60 3c 	ld  [ %g1 + 0x3c ], %g2                        
4001d284:	c4 20 60 84 	st  %g2, [ %g1 + 0x84 ]                        
      rtems_rfs_block_map_count (rtems_rfs_file_map (handle));        
    handle->shared->size.offset =                                     
4001d288:	c4 00 60 40 	ld  [ %g1 + 0x40 ], %g2                        
4001d28c:	c4 20 60 88 	st  %g2, [ %g1 + 0x88 ]                        
      rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle));  
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
4001d290:	81 c7 e0 08 	ret                                            
4001d294:	81 e8 00 00 	restore                                        
                                                                      

4001d298 <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))
4001d298:	c2 02 20 0c 	ld  [ %o0 + 0xc ], %g1                         
4001d29c:	80 a0 60 00 	cmp  %g1, 0                                    
4001d2a0:	02 80 00 08 	be  4001d2c0 <rtems_rfs_file_io_release+0x28>  <== ALWAYS TAKEN
4001d2a4:	92 10 00 08 	mov  %o0, %o1                                  
    rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle), 
4001d2a8:	c2 02 20 1c 	ld  [ %o0 + 0x1c ], %g1                        <== NOT EXECUTED
4001d2ac:	92 02 60 04 	add  %o1, 4, %o1                               <== NOT EXECUTED
4001d2b0:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        <== NOT EXECUTED
4001d2b4:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
4001d2b8:	7f ff f7 60 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001d2bc:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                          rtems_rfs_file_buffer (handle));
  return rc;                                                          
}                                                                     
4001d2c0:	81 c3 e0 08 	retl                                           
4001d2c4:	90 10 20 00 	clr  %o0                                       
                                                                      

4001cdf8 <rtems_rfs_file_io_start>: int rtems_rfs_file_io_start (rtems_rfs_file_handle* handle, size_t* available, bool read) {
4001cdf8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  size_t size;                                                        
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001cdfc:	90 10 20 20 	mov  0x20, %o0                                 
4001ce00:	92 10 20 00 	clr  %o1                                       
4001ce04:	7f ff da 12 	call  4001364c <rtems_rfs_trace>               
4001ce08:	ba 10 00 18 	mov  %i0, %i5                                  
4001ce0c:	80 a2 20 00 	cmp  %o0, 0                                    
4001ce10:	22 80 00 0f 	be,a   4001ce4c <rtems_rfs_file_io_start+0x54> <== ALWAYS TAKEN
4001ce14:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
    printf ("rtems-rfs: file-io: start: %s pos=%" PRIu32 ":%" PRIu32 "\n",
4001ce18:	80 a6 a0 00 	cmp  %i2, 0                                    <== NOT EXECUTED
4001ce1c:	22 80 00 05 	be,a   4001ce30 <rtems_rfs_file_io_start+0x38> <== NOT EXECUTED
4001ce20:	13 10 00 d5 	sethi  %hi(0x40035400), %o1                    <== NOT EXECUTED
4001ce24:	13 10 00 d2 	sethi  %hi(0x40034800), %o1                    <== NOT EXECUTED
4001ce28:	10 80 00 03 	b  4001ce34 <rtems_rfs_file_io_start+0x3c>     <== NOT EXECUTED
4001ce2c:	92 12 61 68 	or  %o1, 0x168, %o1	! 40034968 <CSWTCH.1+0x218><== NOT EXECUTED
4001ce30:	92 12 61 68 	or  %o1, 0x168, %o1                            <== NOT EXECUTED
4001ce34:	d4 07 60 10 	ld  [ %i5 + 0x10 ], %o2                        <== NOT EXECUTED
4001ce38:	d6 07 60 14 	ld  [ %i5 + 0x14 ], %o3                        <== NOT EXECUTED
4001ce3c:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001ce40:	40 00 15 12 	call  40022288 <printf>                        <== NOT EXECUTED
4001ce44:	90 12 21 70 	or  %o0, 0x170, %o0	! 40035570 <CSWTCH.1+0xe20><== NOT EXECUTED
            read ? "read" : "write",  handle->bpos.bno, handle->bpos.boff);
                                                                      
  if (!rtems_rfs_buffer_handle_has_block (&handle->buffer))           
4001ce48:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         <== NOT EXECUTED
4001ce4c:	80 a0 60 00 	cmp  %g1, 0                                    
4001ce50:	12 80 00 50 	bne  4001cf90 <rtems_rfs_file_io_start+0x198>  
4001ce54:	80 a6 a0 00 	cmp  %i2, 0                                    
    bool                   request_read;                              
    int                    rc;                                        
                                                                      
    request_read = read;                                              
                                                                      
    rc = rtems_rfs_block_map_find (rtems_rfs_file_fs (handle),        
4001ce58:	d2 07 60 1c 	ld  [ %i5 + 0x1c ], %o1                        
4001ce5c:	94 07 60 10 	add  %i5, 0x10, %o2                            
4001ce60:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001ce64:	96 07 bf fc 	add  %fp, -4, %o3                              
4001ce68:	7f ff f5 d5 	call  4001a5bc <rtems_rfs_block_map_find>      
4001ce6c:	92 02 60 34 	add  %o1, 0x34, %o1                            
                                   rtems_rfs_file_map (handle),       
                                   rtems_rfs_file_bpos (handle),      
                                   &block);                           
    if (rc > 0)                                                       
4001ce70:	80 a2 20 00 	cmp  %o0, 0                                    
4001ce74:	04 80 00 1f 	ble  4001cef0 <rtems_rfs_file_io_start+0xf8>   
4001ce78:	80 a2 20 06 	cmp  %o0, 6                                    
    {                                                                 
      /*                                                              
       * Has the read reached the EOF ?                               
       */                                                             
      if (read && (rc == ENXIO))                                      
4001ce7c:	12 80 00 66 	bne  4001d014 <rtems_rfs_file_io_start+0x21c>  <== NEVER TAKEN
4001ce80:	b0 10 00 08 	mov  %o0, %i0                                  
4001ce84:	80 a6 a0 00 	cmp  %i2, 0                                    
4001ce88:	22 80 00 05 	be,a   4001ce9c <rtems_rfs_file_io_start+0xa4> <== ALWAYS TAKEN
4001ce8c:	80 a2 20 06 	cmp  %o0, 6                                    
      {                                                               
        *available = 0;                                               
4001ce90:	c0 26 40 00 	clr  [ %i1 ]                                   <== NOT EXECUTED
        return 0;                                                     
4001ce94:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001ce98:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
      }                                                               
                                                                      
      if (rc != ENXIO)                                                
4001ce9c:	12 80 00 5e 	bne  4001d014 <rtems_rfs_file_io_start+0x21c>  <== NEVER TAKEN
4001cea0:	b0 10 00 08 	mov  %o0, %i0                                  
        return rc;                                                    
                                                                      
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                  
4001cea4:	90 10 20 20 	mov  0x20, %o0                                 
4001cea8:	7f ff d9 e9 	call  4001364c <rtems_rfs_trace>               
4001ceac:	92 10 20 00 	clr  %o1                                       
4001ceb0:	80 a2 20 00 	cmp  %o0, 0                                    
4001ceb4:	22 80 00 06 	be,a   4001cecc <rtems_rfs_file_io_start+0xd4> <== ALWAYS TAKEN
4001ceb8:	d2 07 60 1c 	ld  [ %i5 + 0x1c ], %o1                        
        printf ("rtems-rfs: file-io: start: grow\n");                 
4001cebc:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001cec0:	40 00 15 81 	call  400224c4 <puts>                          <== NOT EXECUTED
4001cec4:	90 12 21 a0 	or  %o0, 0x1a0, %o0	! 400355a0 <CSWTCH.1+0xe50><== NOT EXECUTED
                                                                      
      rc = rtems_rfs_block_map_grow (rtems_rfs_file_fs (handle),      
4001cec8:	d2 07 60 1c 	ld  [ %i5 + 0x1c ], %o1                        <== NOT EXECUTED
4001cecc:	94 10 20 01 	mov  1, %o2                                    
4001ced0:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001ced4:	96 07 bf fc 	add  %fp, -4, %o3                              
4001ced8:	7f ff f6 42 	call  4001a7e0 <rtems_rfs_block_map_grow>      
4001cedc:	92 02 60 34 	add  %o1, 0x34, %o1                            
                                     rtems_rfs_file_map (handle),     
                                     1, &block);                      
      if (rc > 0)                                                     
4001cee0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001cee4:	14 80 00 4c 	bg  4001d014 <rtems_rfs_file_io_start+0x21c>   
4001cee8:	b8 10 20 00 	clr  %i4                                       
4001ceec:	30 80 00 0f 	b,a   4001cf28 <rtems_rfs_file_io_start+0x130> 
      /*                                                              
       * 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 &&                                                    
4001cef0:	b8 96 a0 00 	orcc  %i2, 0, %i4                              
4001cef4:	12 80 00 0e 	bne  4001cf2c <rtems_rfs_file_io_start+0x134>  
4001cef8:	90 10 20 20 	mov  0x20, %o0                                 
4001cefc:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
4001cf00:	80 a0 60 00 	cmp  %g1, 0                                    
4001cf04:	12 80 00 0a 	bne  4001cf2c <rtems_rfs_file_io_start+0x134>  
4001cf08:	b8 10 20 01 	mov  1, %i4                                    
          (rtems_rfs_file_block_offset (handle) ||                    
           (*available < rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))))
4001cf0c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
       * 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) ||                    
4001cf10:	c4 06 40 00 	ld  [ %i1 ], %g2                               
           (*available < rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))))
4001cf14:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
       * 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) ||                    
4001cf18:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
4001cf1c:	80 a0 80 01 	cmp  %g2, %g1                                  
4001cf20:	3a 80 00 03 	bcc,a   4001cf2c <rtems_rfs_file_io_start+0x134><== NEVER TAKEN
4001cf24:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
           (*available < rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle)))))
        request_read = true;                                          
    }                                                                 
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                    
4001cf28:	90 10 20 20 	mov  0x20, %o0                                 
4001cf2c:	7f ff d9 c8 	call  4001364c <rtems_rfs_trace>               
4001cf30:	92 10 20 00 	clr  %o1                                       
4001cf34:	80 a2 20 00 	cmp  %o0, 0                                    
4001cf38:	22 80 00 0e 	be,a   4001cf70 <rtems_rfs_file_io_start+0x178><== ALWAYS TAKEN
4001cf3c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
      printf ("rtems-rfs: file-io: start: block=%" PRIu32 " request-read=%s\n",
4001cf40:	80 a7 20 00 	cmp  %i4, 0                                    <== NOT EXECUTED
4001cf44:	02 80 00 05 	be  4001cf58 <rtems_rfs_file_io_start+0x160>   <== NOT EXECUTED
4001cf48:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          <== NOT EXECUTED
4001cf4c:	15 10 00 cf 	sethi  %hi(0x40033c00), %o2                    <== NOT EXECUTED
4001cf50:	10 80 00 04 	b  4001cf60 <rtems_rfs_file_io_start+0x168>    <== NOT EXECUTED
4001cf54:	94 12 a0 c8 	or  %o2, 0xc8, %o2	! 40033cc8 <_Semaphore_Translate_core_mutex_return_code_+0xb38><== NOT EXECUTED
4001cf58:	15 10 00 c8 	sethi  %hi(0x40032000), %o2                    <== NOT EXECUTED
4001cf5c:	94 12 a2 a0 	or  %o2, 0x2a0, %o2	! 400322a0 <__FUNCTION__.6501+0x238><== NOT EXECUTED
4001cf60:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001cf64:	40 00 14 c9 	call  40022288 <printf>                        <== NOT EXECUTED
4001cf68:	90 12 21 c0 	or  %o0, 0x1c0, %o0	! 400355c0 <CSWTCH.1+0xe70><== NOT EXECUTED
              block, request_read ? "yes" : "no");                    
                                                                      
    rc = rtems_rfs_buffer_handle_request (rtems_rfs_file_fs (handle), 
4001cf6c:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        <== NOT EXECUTED
4001cf70:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
4001cf74:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
4001cf78:	92 07 60 04 	add  %i5, 4, %o1                               
4001cf7c:	7f ff f8 b8 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001cf80:	96 10 00 1c 	mov  %i4, %o3                                  
                                          rtems_rfs_file_buffer (handle),
                                          block, request_read);       
    if (rc > 0)                                                       
4001cf84:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001cf88:	14 80 00 23 	bg  4001d014 <rtems_rfs_file_io_start+0x21c>   <== NEVER TAKEN
4001cf8c:	80 a6 a0 00 	cmp  %i2, 0                                    
      return rc;                                                      
  }                                                                   
                                                                      
  if (read                                                            
4001cf90:	02 80 00 11 	be  4001cfd4 <rtems_rfs_file_io_start+0x1dc>   
4001cf94:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        
      && rtems_rfs_block_map_last (rtems_rfs_file_map (handle))       
4001cf98:	c4 00 60 44 	ld  [ %g1 + 0x44 ], %g2                        
4001cf9c:	80 a0 a0 00 	cmp  %g2, 0                                    
4001cfa0:	12 80 00 05 	bne  4001cfb4 <rtems_rfs_file_io_start+0x1bc>  
4001cfa4:	c6 00 60 3c 	ld  [ %g1 + 0x3c ], %g3                        
4001cfa8:	80 a0 e0 00 	cmp  %g3, 0                                    
4001cfac:	22 80 00 07 	be,a   4001cfc8 <rtems_rfs_file_io_start+0x1d0><== NEVER TAKEN
4001cfb0:	f8 00 60 40 	ld  [ %g1 + 0x40 ], %i4                        <== NOT EXECUTED
4001cfb4:	86 00 ff ff 	add  %g3, -1, %g3                              
4001cfb8:	80 a0 80 03 	cmp  %g2, %g3                                  
4001cfbc:	32 80 00 07 	bne,a   4001cfd8 <rtems_rfs_file_io_start+0x1e0>
4001cfc0:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
      && rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle)))
4001cfc4:	f8 00 60 40 	ld  [ %g1 + 0x40 ], %i4                        
4001cfc8:	80 a7 20 00 	cmp  %i4, 0                                    
4001cfcc:	32 80 00 05 	bne,a   4001cfe0 <rtems_rfs_file_io_start+0x1e8>
4001cfd0:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
    size = rtems_rfs_block_map_size_offset (rtems_rfs_file_map (handle));
  else                                                                
    size = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));      
4001cfd4:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
4001cfd8:	f8 00 60 08 	ld  [ %g1 + 8 ], %i4                           
                                                                      
  *available = size - rtems_rfs_file_block_offset (handle);           
4001cfdc:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001cfe0:	90 10 20 20 	mov  0x20, %o0                                 
      && 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));      
                                                                      
  *available = size - rtems_rfs_file_block_offset (handle);           
4001cfe4:	82 27 00 01 	sub  %i4, %g1, %g1                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001cfe8:	92 10 20 00 	clr  %o1                                       
      && 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));      
                                                                      
  *available = size - rtems_rfs_file_block_offset (handle);           
4001cfec:	c2 26 40 00 	st  %g1, [ %i1 ]                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001cff0:	7f ff d9 97 	call  4001364c <rtems_rfs_trace>               
4001cff4:	b0 10 20 00 	clr  %i0                                       
4001cff8:	80 a2 20 00 	cmp  %o0, 0                                    
4001cffc:	02 80 00 06 	be  4001d014 <rtems_rfs_file_io_start+0x21c>   <== ALWAYS TAKEN
4001d000:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    
    printf ("rtems-rfs: file-io: start: available=%zu (%zu)\n",       
4001d004:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
4001d008:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001d00c:	40 00 14 9f 	call  40022288 <printf>                        <== NOT EXECUTED
4001d010:	90 12 21 f8 	or  %o0, 0x1f8, %o0                            <== NOT EXECUTED
            *available, size);                                        
                                                                      
  return 0;                                                           
}                                                                     
4001d014:	81 c7 e0 08 	ret                                            
4001d018:	81 e8 00 00 	restore                                        
                                                                      

4001d720 <rtems_rfs_file_open>: int rtems_rfs_file_open (rtems_rfs_file_system* fs, rtems_rfs_ino ino, int oflag, rtems_rfs_file_handle** file) {
4001d720:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_file_handle* handle;                                      
  rtems_rfs_file_shared* shared;                                      
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))                    
4001d724:	90 10 20 08 	mov  8, %o0                                    
4001d728:	92 10 20 00 	clr  %o1                                       
4001d72c:	7f ff d7 c8 	call  4001364c <rtems_rfs_trace>               
4001d730:	a0 10 00 18 	mov  %i0, %l0                                  
4001d734:	80 a2 20 00 	cmp  %o0, 0                                    
4001d738:	22 80 00 07 	be,a   4001d754 <rtems_rfs_file_open+0x34>     <== ALWAYS TAKEN
4001d73c:	c0 26 c0 00 	clr  [ %i3 ]                                   
    printf ("rtems-rfs: file-open: ino=%" PRId32 "\n", ino);          
4001d740:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d744:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4001d748:	40 00 12 d0 	call  40022288 <printf>                        <== NOT EXECUTED
4001d74c:	90 12 23 18 	or  %o0, 0x318, %o0                            <== NOT EXECUTED
                                                                      
  *file = NULL;                                                       
4001d750:	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));                   
4001d754:	90 10 20 20 	mov  0x20, %o0                                 
4001d758:	7f ff ab 83 	call  40008564 <malloc>                        
4001d75c:	b0 10 20 0c 	mov  0xc, %i0                                  
  if (!handle)                                                        
4001d760:	80 a2 20 00 	cmp  %o0, 0                                    
4001d764:	02 80 00 56 	be  4001d8bc <rtems_rfs_file_open+0x19c>       <== NEVER TAKEN
4001d768:	ba 10 00 08 	mov  %o0, %i5                                  
    return ENOMEM;                                                    
                                                                      
  memset (handle, 0, sizeof (rtems_rfs_file_handle));                 
4001d76c:	92 10 20 00 	clr  %o1                                       
4001d770:	40 00 12 4d 	call  400220a4 <memset>                        
4001d774:	94 10 20 20 	mov  0x20, %o2                                 
                                                                      
  /*                                                                  
   * Scan the file system data list of open files for this ino. If found up
   * the reference count and return the pointer to the data.          
   */                                                                 
  shared = rtems_rfs_file_get_shared (fs, ino);                       
4001d778:	90 10 00 10 	mov  %l0, %o0                                  
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001d77c:	c0 2f 60 04 	clrb  [ %i5 + 4 ]                              
  handle->bnum  = 0;                                                  
4001d780:	c0 27 60 08 	clr  [ %i5 + 8 ]                               
  handle->buffer = NULL;                                              
4001d784:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
4001d788:	7f ff ff d7 	call  4001d6e4 <rtems_rfs_file_get_shared>     
4001d78c:	92 10 00 19 	mov  %i1, %o1                                  
  if (shared)                                                         
4001d790:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001d794:	02 80 00 0d 	be  4001d7c8 <rtems_rfs_file_open+0xa8>        <== ALWAYS TAKEN
4001d798:	90 10 20 08 	mov  8, %o0                                    
  {                                                                   
    shared->references++;                                             
4001d79c:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           <== NOT EXECUTED
4001d7a0:	82 00 60 01 	inc  %g1                                       <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))                  
4001d7a4:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001d7a8:	7f ff d7 a9 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001d7ac:	c2 27 20 08 	st  %g1, [ %i4 + 8 ]                           <== NOT EXECUTED
4001d7b0:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001d7b4:	22 80 00 8e 	be,a   4001d9ec <rtems_rfs_file_open+0x2cc>    <== NOT EXECUTED
4001d7b8:	f4 27 40 00 	st  %i2, [ %i5 ]                               <== NOT EXECUTED
      printf ("rtems-rfs: file-open: ino=%" PRId32 " shared\n", ino); 
4001d7bc:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d7c0:	10 80 00 88 	b  4001d9e0 <rtems_rfs_file_open+0x2c0>        <== NOT EXECUTED
4001d7c4:	90 12 23 38 	or  %o0, 0x338, %o0	! 40035738 <CSWTCH.1+0xfe8><== 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));                 
4001d7c8:	7f ff ab 67 	call  40008564 <malloc>                        
4001d7cc:	90 10 20 9c 	mov  0x9c, %o0                                 
    if (!shared)                                                      
4001d7d0:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001d7d4:	02 80 00 32 	be  4001d89c <rtems_rfs_file_open+0x17c>       <== NEVER TAKEN
4001d7d8:	92 10 20 00 	clr  %o1                                       
      rtems_rfs_buffer_handle_close (fs, &handle->buffer);            
      free (handle);                                                  
      return ENOMEM;                                                  
    }                                                                 
                                                                      
    memset (shared, 0, sizeof (rtems_rfs_file_shared));               
4001d7dc:	40 00 12 32 	call  400220a4 <memset>                        
4001d7e0:	94 10 20 9c 	mov  0x9c, %o2                                 
                                                                      
    rc = rtems_rfs_inode_open (fs, ino, &shared->inode, true);        
4001d7e4:	a2 07 20 0c 	add  %i4, 0xc, %l1                             
4001d7e8:	90 10 00 10 	mov  %l0, %o0                                  
4001d7ec:	92 10 00 19 	mov  %i1, %o1                                  
4001d7f0:	94 10 00 11 	mov  %l1, %o2                                  
4001d7f4:	7f ff d1 3a 	call  40011cdc <rtems_rfs_inode_open>          
4001d7f8:	96 10 20 01 	mov  1, %o3                                    
    if (rc > 0)                                                       
4001d7fc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001d800:	04 80 00 0f 	ble  4001d83c <rtems_rfs_file_open+0x11c>      <== ALWAYS TAKEN
4001d804:	90 10 20 08 	mov  8, %o0                                    
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))                
4001d808:	7f ff d7 91 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001d80c:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001d810:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001d814:	02 80 00 20 	be  4001d894 <rtems_rfs_file_open+0x174>       <== NOT EXECUTED
4001d818:	01 00 00 00 	nop                                            <== NOT EXECUTED
        printf ("rtems-rfs: file-open: inode open failed: %d: %s\n",  
4001d81c:	40 00 16 dc 	call  4002338c <strerror>                      <== NOT EXECUTED
4001d820:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001d824:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001d828:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001d82c:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d830:	40 00 12 96 	call  40022288 <printf>                        <== NOT EXECUTED
4001d834:	90 12 23 60 	or  %o0, 0x360, %o0	! 40035760 <CSWTCH.1+0x1010><== NOT EXECUTED
4001d838:	30 80 00 17 	b,a   4001d894 <rtems_rfs_file_open+0x174>     <== 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); 
4001d83c:	90 10 00 10 	mov  %l0, %o0                                  
4001d840:	92 10 00 11 	mov  %l1, %o1                                  
4001d844:	7f ff f2 8c 	call  4001a274 <rtems_rfs_block_map_open>      
4001d848:	94 07 20 34 	add  %i4, 0x34, %o2                            
    if (rc > 0)                                                       
4001d84c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001d850:	04 80 00 1d 	ble  4001d8c4 <rtems_rfs_file_open+0x1a4>      <== ALWAYS TAKEN
4001d854:	90 10 20 08 	mov  8, %o0                                    
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))                
4001d858:	7f ff d7 7d 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001d85c:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
4001d860:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001d864:	22 80 00 0a 	be,a   4001d88c <rtems_rfs_file_open+0x16c>    <== NOT EXECUTED
4001d868:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
        printf ("rtems-rfs: file-open: block map open failed: %d: %s\n",
4001d86c:	40 00 16 c8 	call  4002338c <strerror>                      <== NOT EXECUTED
4001d870:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001d874:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001d878:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001d87c:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d880:	40 00 12 82 	call  40022288 <printf>                        <== NOT EXECUTED
4001d884:	90 12 23 98 	or  %o0, 0x398, %o0	! 40035798 <CSWTCH.1+0x1048><== NOT EXECUTED
                rc, strerror (rc));                                   
      rtems_rfs_inode_close (fs, &shared->inode);                     
4001d888:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001d88c:	7f ff d1 86 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001d890:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
      free (shared);                                                  
4001d894:	7f ff a9 a6 	call  40007f2c <free>                          <== NOT EXECUTED
4001d898:	90 10 00 1c 	mov  %i4, %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);                       
4001d89c:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001d8a0:	7f ff f5 e6 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001d8a4:	92 07 60 04 	add  %i5, 4, %o1                               <== NOT EXECUTED
      rtems_rfs_buffer_handle_close (fs, &handle->buffer);            
      free (handle);                                                  
4001d8a8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  handle->dirty = false;                                              
4001d8ac:	c0 2f 60 04 	clrb  [ %i5 + 4 ]                              <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001d8b0:	c0 27 60 08 	clr  [ %i5 + 8 ]                               <== NOT EXECUTED
4001d8b4:	7f ff a9 9e 	call  40007f2c <free>                          <== NOT EXECUTED
4001d8b8:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             <== NOT EXECUTED
      return rc;                                                      
4001d8bc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001d8c0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
    }                                                                 
                                                                      
    shared->references = 1;                                           
4001d8c4:	82 10 20 01 	mov  1, %g1                                    
4001d8c8:	c2 27 20 08 	st  %g1, [ %i4 + 8 ]                           
      return ENOMEM;                                                  
    }                                                                 
                                                                      
    memset (shared, 0, sizeof (rtems_rfs_file_shared));               
                                                                      
    rc = rtems_rfs_inode_open (fs, ino, &shared->inode, true);        
4001d8cc:	c2 07 20 18 	ld  [ %i4 + 0x18 ], %g1                        
    shared->ctime = rtems_rfs_inode_get_ctime (&shared->inode);       
    shared->fs = fs;                                                  
                                                                      
    rtems_chain_append_unprotected (&fs->file_shares, &shared->link); 
                                                                      
    rtems_rfs_inode_unload (fs, &shared->inode, false);               
4001d8d0:	92 10 00 11 	mov  %l1, %o1                                  
 * @retval count 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);             
4001d8d4:	c6 08 60 0c 	ldub  [ %g1 + 0xc ], %g3                       
4001d8d8:	c4 08 60 0d 	ldub  [ %g1 + 0xd ], %g2                       
4001d8dc:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001d8e0:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001d8e4:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001d8e8:	c6 08 60 0f 	ldub  [ %g1 + 0xf ], %g3                       
4001d8ec:	94 10 20 00 	clr  %o2                                       
4001d8f0:	84 10 80 03 	or  %g2, %g3, %g2                              
4001d8f4:	c6 08 60 0e 	ldub  [ %g1 + 0xe ], %g3                       
4001d8f8:	90 10 00 10 	mov  %l0, %o0                                  
4001d8fc:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001d900:	84 10 80 03 	or  %g2, %g3, %g2                              
      free (handle);                                                  
      return rc;                                                      
    }                                                                 
                                                                      
    shared->references = 1;                                           
    shared->size.count = rtems_rfs_inode_get_block_count (&shared->inode);
4001d904:	c4 27 20 84 	st  %g2, [ %i4 + 0x84 ]                        
    shared->size.offset = rtems_rfs_inode_get_block_offset (&shared->inode);
4001d908:	c6 08 60 0b 	ldub  [ %g1 + 0xb ], %g3                       
 * @retval offset The block offset.                                   
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_block_offset (rtems_rfs_inode_handle* handle)     
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->block_offset);            
4001d90c:	c4 08 60 0a 	ldub  [ %g1 + 0xa ], %g2                       
4001d910:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001d914:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001d918:	c4 27 20 88 	st  %g2, [ %i4 + 0x88 ]                        
 * @retval atime 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);                   
4001d91c:	c6 08 60 10 	ldub  [ %g1 + 0x10 ], %g3                      
4001d920:	c4 08 60 11 	ldub  [ %g1 + 0x11 ], %g2                      
4001d924:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001d928:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001d92c:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001d930:	c6 08 60 13 	ldub  [ %g1 + 0x13 ], %g3                      
4001d934:	84 10 80 03 	or  %g2, %g3, %g2                              
4001d938:	c6 08 60 12 	ldub  [ %g1 + 0x12 ], %g3                      
4001d93c:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001d940:	84 10 80 03 	or  %g2, %g3, %g2                              
    shared->atime = rtems_rfs_inode_get_atime (&shared->inode);       
4001d944:	c4 27 20 8c 	st  %g2, [ %i4 + 0x8c ]                        
 * @retval mtime 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);                   
4001d948:	c6 08 60 14 	ldub  [ %g1 + 0x14 ], %g3                      
4001d94c:	c4 08 60 15 	ldub  [ %g1 + 0x15 ], %g2                      
4001d950:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001d954:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001d958:	84 10 c0 02 	or  %g3, %g2, %g2                              
4001d95c:	c6 08 60 17 	ldub  [ %g1 + 0x17 ], %g3                      
4001d960:	84 10 80 03 	or  %g2, %g3, %g2                              
4001d964:	c6 08 60 16 	ldub  [ %g1 + 0x16 ], %g3                      
4001d968:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001d96c:	84 10 80 03 	or  %g2, %g3, %g2                              
    shared->mtime = rtems_rfs_inode_get_mtime (&shared->inode);       
4001d970:	c4 27 20 90 	st  %g2, [ %i4 + 0x90 ]                        
 * @retval ctime 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);                   
4001d974:	c4 08 60 19 	ldub  [ %g1 + 0x19 ], %g2                      
4001d978:	c6 08 60 18 	ldub  [ %g1 + 0x18 ], %g3                      
4001d97c:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
4001d980:	87 28 e0 18 	sll  %g3, 0x18, %g3                            
4001d984:	86 10 c0 02 	or  %g3, %g2, %g3                              
4001d988:	c4 08 60 1b 	ldub  [ %g1 + 0x1b ], %g2                      
4001d98c:	86 10 c0 02 	or  %g3, %g2, %g3                              
4001d990:	c4 08 60 1a 	ldub  [ %g1 + 0x1a ], %g2                      
    shared->ctime = rtems_rfs_inode_get_ctime (&shared->inode);       
    shared->fs = fs;                                                  
4001d994:	e0 27 20 98 	st  %l0, [ %i4 + 0x98 ]                        
4001d998:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001d99c:	82 10 c0 02 	or  %g3, %g2, %g1                              
RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected(                  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001d9a0:	84 04 20 78 	add  %l0, 0x78, %g2                            
    shared->references = 1;                                           
    shared->size.count = rtems_rfs_inode_get_block_count (&shared->inode);
    shared->size.offset = rtems_rfs_inode_get_block_offset (&shared->inode);
    shared->atime = rtems_rfs_inode_get_atime (&shared->inode);       
    shared->mtime = rtems_rfs_inode_get_mtime (&shared->inode);       
    shared->ctime = rtems_rfs_inode_get_ctime (&shared->inode);       
4001d9a4:	c2 27 20 94 	st  %g1, [ %i4 + 0x94 ]                        
  Chain_Node *old_last = tail->previous;                              
4001d9a8:	c2 04 20 7c 	ld  [ %l0 + 0x7c ], %g1                        
                                                                      
  the_node->next = tail;                                              
4001d9ac:	c4 27 00 00 	st  %g2, [ %i4 ]                               
  tail->previous = the_node;                                          
4001d9b0:	f8 24 20 7c 	st  %i4, [ %l0 + 0x7c ]                        
  old_last->next = the_node;                                          
4001d9b4:	f8 20 40 00 	st  %i4, [ %g1 ]                               
    shared->fs = fs;                                                  
                                                                      
    rtems_chain_append_unprotected (&fs->file_shares, &shared->link); 
                                                                      
    rtems_rfs_inode_unload (fs, &shared->inode, false);               
4001d9b8:	7f ff d0 ff 	call  40011db4 <rtems_rfs_inode_unload>        
4001d9bc:	c2 27 20 04 	st  %g1, [ %i4 + 4 ]                           
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_OPEN))                  
4001d9c0:	90 10 20 08 	mov  8, %o0                                    
4001d9c4:	7f ff d7 22 	call  4001364c <rtems_rfs_trace>               
4001d9c8:	92 10 20 00 	clr  %o1                                       
4001d9cc:	80 a2 20 00 	cmp  %o0, 0                                    
4001d9d0:	22 80 00 07 	be,a   4001d9ec <rtems_rfs_file_open+0x2cc>    <== ALWAYS TAKEN
4001d9d4:	f4 27 40 00 	st  %i2, [ %i5 ]                               
      printf ("rtems-rfs: file-open: ino=%" PRId32 " share created\n", ino);
4001d9d8:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d9dc:	90 12 23 d0 	or  %o0, 0x3d0, %o0	! 400357d0 <CSWTCH.1+0x1080><== NOT EXECUTED
4001d9e0:	40 00 12 2a 	call  40022288 <printf>                        <== NOT EXECUTED
4001d9e4:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  handle->flags  = oflag;                                             
4001d9e8:	f4 27 40 00 	st  %i2, [ %i5 ]                               <== NOT EXECUTED
  handle->shared = shared;                                            
4001d9ec:	f8 27 60 1c 	st  %i4, [ %i5 + 0x1c ]                        
                                                                      
  *file = handle;                                                     
4001d9f0:	fa 26 c0 00 	st  %i5, [ %i3 ]                               
                                                                      
  return 0;                                                           
4001d9f4:	b0 10 20 00 	clr  %i0                                       
}                                                                     
4001d9f8:	81 c7 e0 08 	ret                                            
4001d9fc:	81 e8 00 00 	restore                                        
                                                                      

4001d2c8 <rtems_rfs_file_seek>: int rtems_rfs_file_seek (rtems_rfs_file_handle* handle, rtems_rfs_pos pos, rtems_rfs_pos* new_pos) {
4001d2c8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001d2cc:	90 10 20 20 	mov  0x20, %o0                                 
4001d2d0:	7f ff d8 df 	call  4001364c <rtems_rfs_trace>               
4001d2d4:	92 10 20 00 	clr  %o1                                       
4001d2d8:	80 a2 20 00 	cmp  %o0, 0                                    
4001d2dc:	22 80 00 08 	be,a   4001d2fc <rtems_rfs_file_seek+0x34>     <== ALWAYS TAKEN
4001d2e0:	d2 06 20 1c 	ld  [ %i0 + 0x1c ], %o1                        
    printf ("rtems-rfs: file-seek: new=%" PRIu64 "\n", pos);          
4001d2e4:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d2e8:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4001d2ec:	90 12 22 d0 	or  %o0, 0x2d0, %o0                            <== NOT EXECUTED
4001d2f0:	40 00 13 e6 	call  40022288 <printf>                        <== NOT EXECUTED
4001d2f4:	94 10 00 1a 	mov  %i2, %o2                                  <== 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),
4001d2f8:	d2 06 20 1c 	ld  [ %i0 + 0x1c ], %o1                        <== NOT EXECUTED
4001d2fc:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001d300:	7f ff f3 c5 	call  4001a214 <rtems_rfs_block_get_size>      
4001d304:	92 02 60 84 	add  %o1, 0x84, %o1                            
4001d308:	80 a6 40 08 	cmp  %i1, %o0                                  
4001d30c:	18 80 00 23 	bgu  4001d398 <rtems_rfs_file_seek+0xd0>       <== NEVER TAKEN
4001d310:	01 00 00 00 	nop                                            
4001d314:	32 80 00 06 	bne,a   4001d32c <rtems_rfs_file_seek+0x64>    <== NEVER TAKEN
4001d318:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        <== NOT EXECUTED
4001d31c:	80 a6 80 09 	cmp  %i2, %o1                                  
4001d320:	18 80 00 1e 	bgu  4001d398 <rtems_rfs_file_seek+0xd0>       
4001d324:	01 00 00 00 	nop                                            
                                            handle->shared))          
  {                                                                   
    rtems_rfs_file_set_bpos (handle, pos);                            
4001d328:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        
4001d32c:	b8 06 20 10 	add  %i0, 0x10, %i4                            
4001d330:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
4001d334:	92 10 00 19 	mov  %i1, %o1                                  
4001d338:	94 10 00 1a 	mov  %i2, %o2                                  
4001d33c:	7f ff f3 9d 	call  4001a1b0 <rtems_rfs_block_get_bpos>      
4001d340:	96 10 00 1c 	mov  %i4, %o3                                  
    /*                                                                
     * 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))          
4001d344:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
4001d348:	80 a0 60 00 	cmp  %g1, 0                                    
4001d34c:	02 80 00 18 	be  4001d3ac <rtems_rfs_file_seek+0xe4>        
4001d350:	94 10 00 1c 	mov  %i4, %o2                                  
    {                                                                 
      rtems_rfs_buffer_block block;                                   
      int                    rc;                                      
                                                                      
      rc = rtems_rfs_block_map_find (rtems_rfs_file_fs (handle),      
4001d354:	d2 06 20 1c 	ld  [ %i0 + 0x1c ], %o1                        
4001d358:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001d35c:	96 07 bf fc 	add  %fp, -4, %o3                              
4001d360:	7f ff f4 97 	call  4001a5bc <rtems_rfs_block_map_find>      
4001d364:	92 02 60 34 	add  %o1, 0x34, %o1                            
                                     rtems_rfs_file_map (handle),     
                                     rtems_rfs_file_bpos (handle),    
                                     &block);                         
      if (rc > 0)                                                     
4001d368:	80 a2 20 00 	cmp  %o0, 0                                    
4001d36c:	14 80 00 13 	bg  4001d3b8 <rtems_rfs_file_seek+0xf0>        <== NEVER TAKEN
4001d370:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
        return rc;                                                    
      if (rtems_rfs_buffer_bnum (&handle->buffer) != block)           
4001d374:	c4 06 20 08 	ld  [ %i0 + 8 ], %g2                           
4001d378:	80 a0 80 01 	cmp  %g2, %g1                                  
4001d37c:	02 80 00 0c 	be  4001d3ac <rtems_rfs_file_seek+0xe4>        <== ALWAYS TAKEN
4001d380:	92 06 20 04 	add  %i0, 4, %o1                               
      {                                                               
        rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
4001d384:	c2 06 20 1c 	ld  [ %i0 + 0x1c ], %g1                        <== NOT EXECUTED
4001d388:	7f ff f7 2c 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001d38c:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        <== 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);                      
    if (rc > 0)                                                       
4001d390:	10 80 00 05 	b  4001d3a4 <rtems_rfs_file_seek+0xdc>         <== NOT EXECUTED
4001d394:	80 a2 20 00 	cmp  %o0, 0                                    <== 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);                      
4001d398:	7f ff ff c0 	call  4001d298 <rtems_rfs_file_io_release>     
4001d39c:	90 10 00 18 	mov  %i0, %o0                                  
    if (rc > 0)                                                       
4001d3a0:	80 a2 20 00 	cmp  %o0, 0                                    
4001d3a4:	14 80 00 05 	bg  4001d3b8 <rtems_rfs_file_seek+0xf0>        <== NEVER TAKEN
4001d3a8:	01 00 00 00 	nop                                            
      return rc;                                                      
  }                                                                   
                                                                      
  *new_pos = pos;                                                     
4001d3ac:	f2 26 c0 00 	st  %i1, [ %i3 ]                               
4001d3b0:	f4 26 e0 04 	st  %i2, [ %i3 + 4 ]                           
  return 0;                                                           
4001d3b4:	90 10 20 00 	clr  %o0                                       
}                                                                     
4001d3b8:	81 c7 e0 08 	ret                                            
4001d3bc:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001d3c0 <rtems_rfs_file_set_size>: int rtems_rfs_file_set_size (rtems_rfs_file_handle* handle, rtems_rfs_pos new_size) {
4001d3c0:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_rfs_block_map* map  = rtems_rfs_file_map (handle);            
  rtems_rfs_pos        size;                                          
  int                  rc;                                            
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001d3c4:	90 10 20 20 	mov  0x20, %o0                                 
}                                                                     
                                                                      
int                                                                   
rtems_rfs_file_set_size (rtems_rfs_file_handle* handle,               
                         rtems_rfs_pos          new_size)             
{                                                                     
4001d3c8:	ba 10 00 1a 	mov  %i2, %i5                                  
  rtems_rfs_block_map* map  = rtems_rfs_file_map (handle);            
  rtems_rfs_pos        size;                                          
  int                  rc;                                            
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001d3cc:	92 10 20 00 	clr  %o1                                       
                                                                      
int                                                                   
rtems_rfs_file_set_size (rtems_rfs_file_handle* handle,               
                         rtems_rfs_pos          new_size)             
{                                                                     
  rtems_rfs_block_map* map  = rtems_rfs_file_map (handle);            
4001d3d0:	f4 06 20 1c 	ld  [ %i0 + 0x1c ], %i2                        
  rtems_rfs_pos        size;                                          
  int                  rc;                                            
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_FILE_IO))                      
4001d3d4:	7f ff d8 9e 	call  4001364c <rtems_rfs_trace>               
4001d3d8:	b6 10 00 18 	mov  %i0, %i3                                  
4001d3dc:	80 a2 20 00 	cmp  %o0, 0                                    
4001d3e0:	02 80 00 07 	be  4001d3fc <rtems_rfs_file_set_size+0x3c>    <== ALWAYS TAKEN
4001d3e4:	b8 10 00 19 	mov  %i1, %i4                                  
    printf ("rtems-rfs: file-set-size: size=%" PRIu64 "\n", new_size);
4001d3e8:	11 10 00 d5 	sethi  %hi(0x40035400), %o0                    <== NOT EXECUTED
4001d3ec:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4001d3f0:	90 12 22 f0 	or  %o0, 0x2f0, %o0                            <== NOT EXECUTED
4001d3f4:	40 00 13 a5 	call  40022288 <printf>                        <== NOT EXECUTED
4001d3f8:	94 10 00 1d 	mov  %i5, %o2                                  <== NOT EXECUTED
                                                                      
  size = rtems_rfs_file_size (handle);                                
4001d3fc:	d2 06 e0 1c 	ld  [ %i3 + 0x1c ], %o1                        
4001d400:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001d404:	7f ff f3 84 	call  4001a214 <rtems_rfs_block_get_size>      
4001d408:	92 02 60 84 	add  %o1, 0x84, %o1                            
  /*                                                                  
   * 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)                                               
4001d40c:	80 a2 00 1c 	cmp  %o0, %i4                                  
4001d410:	12 80 00 05 	bne  4001d424 <rtems_rfs_file_set_size+0x64>   <== NEVER TAKEN
4001d414:	a0 06 a0 34 	add  %i2, 0x34, %l0                            
4001d418:	80 a2 40 1d 	cmp  %o1, %i5                                  
4001d41c:	22 80 00 a7 	be,a   4001d6b8 <rtems_rfs_file_set_size+0x2f8>
4001d420:	f0 06 c0 00 	ld  [ %i3 ], %i0                               
  {                                                                   
    /*                                                                
     * Short cut for the common truncate on open call.                
     */                                                               
    if (new_size == 0)                                                
4001d424:	80 97 00 1d 	orcc  %i4, %i5, %g0                            
4001d428:	12 80 00 0a 	bne  4001d450 <rtems_rfs_file_set_size+0x90>   
4001d42c:	f2 06 e0 1c 	ld  [ %i3 + 0x1c ], %i1                        
    {                                                                 
      rc = rtems_rfs_block_map_free_all (rtems_rfs_file_fs (handle), map);
4001d430:	d0 06 60 98 	ld  [ %i1 + 0x98 ], %o0                        
4001d434:	7f ff f6 9d 	call  4001aea8 <rtems_rfs_block_map_free_all>  
4001d438:	92 10 00 10 	mov  %l0, %o1                                  
      if (rc > 0)                                                     
4001d43c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001d440:	14 80 00 a7 	bg  4001d6dc <rtems_rfs_file_set_size+0x31c>   <== NEVER TAKEN
4001d444:	01 00 00 00 	nop                                            
          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);    
4001d448:	10 80 00 97 	b  4001d6a4 <rtems_rfs_file_set_size+0x2e4>    
4001d44c:	c4 06 a0 3c 	ld  [ %i2 + 0x3c ], %g2                        
      if (rc > 0)                                                     
        return rc;                                                    
    }                                                                 
    else                                                              
    {                                                                 
      if (size < new_size)                                            
4001d450:	80 a7 00 08 	cmp  %i4, %o0                                  
4001d454:	38 80 00 09 	bgu,a   4001d478 <rtems_rfs_file_set_size+0xb8><== NEVER TAKEN
4001d458:	c2 06 60 98 	ld  [ %i1 + 0x98 ], %g1                        <== NOT EXECUTED
4001d45c:	80 a7 00 08 	cmp  %i4, %o0                                  
4001d460:	32 80 00 58 	bne,a   4001d5c0 <rtems_rfs_file_set_size+0x200><== NEVER TAKEN
4001d464:	e0 06 60 98 	ld  [ %i1 + 0x98 ], %l0                        <== NOT EXECUTED
4001d468:	80 a7 40 09 	cmp  %i5, %o1                                  
4001d46c:	28 80 00 55 	bleu,a   4001d5c0 <rtems_rfs_file_set_size+0x200>
4001d470:	e0 06 60 98 	ld  [ %i1 + 0x98 ], %l0                        
        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));
4001d474:	c2 06 60 98 	ld  [ %i1 + 0x98 ], %g1                        
         */                                                           
        rtems_rfs_pos count;                                          
        uint32_t      length;                                         
        bool          read_block;                                     
                                                                      
        count = new_size - size;                                      
4001d478:	ba a7 40 09 	subcc  %i5, %o1, %i5                           
        length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
4001d47c:	f2 00 60 08 	ld  [ %g1 + 8 ], %i1                           
         */                                                           
        rtems_rfs_pos count;                                          
        uint32_t      length;                                         
        bool          read_block;                                     
                                                                      
        count = new_size - size;                                      
4001d480:	b8 67 00 08 	subx  %i4, %o0, %i4                            
        length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
        read_block = false;                                           
4001d484:	a4 10 20 00 	clr  %l2                                       
4001d488:	a2 10 20 01 	mov  1, %l1                                    
          }                                                           
                                                                      
          /*                                                          
           * Only read the block if the length is not the block size. 
           */                                                         
          rc = rtems_rfs_buffer_handle_request (rtems_rfs_file_fs (handle),
4001d48c:	a6 06 e0 04 	add  %i3, 4, %l3                               
                                                                      
        count = new_size - size;                                      
        length = rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
        read_block = false;                                           
                                                                      
        while (count)                                                 
4001d490:	80 97 00 1d 	orcc  %i4, %i5, %g0                            
4001d494:	22 80 00 84 	be,a   4001d6a4 <rtems_rfs_file_set_size+0x2e4>
4001d498:	c4 06 a0 3c 	ld  [ %i2 + 0x3c ], %g2                        
          /*                                                          
           * 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);
4001d49c:	c4 06 a0 40 	ld  [ %i2 + 0x40 ], %g2                        
4001d4a0:	c2 06 a0 3c 	ld  [ %i2 + 0x3c ], %g1                        
4001d4a4:	c4 27 bf f8 	st  %g2, [ %fp + -8 ]                          
4001d4a8:	c2 27 bf f4 	st  %g1, [ %fp + -12 ]                         
4001d4ac:	80 a0 a0 00 	cmp  %g2, 0                                    
4001d4b0:	02 80 00 04 	be  4001d4c0 <rtems_rfs_file_set_size+0x100>   
4001d4b4:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
4001d4b8:	82 00 7f ff 	add  %g1, -1, %g1                              
4001d4bc:	c2 27 bf f4 	st  %g1, [ %fp + -12 ]                         
          rc = rtems_rfs_block_map_find (rtems_rfs_file_fs (handle),  
4001d4c0:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
4001d4c4:	92 10 00 10 	mov  %l0, %o1                                  
4001d4c8:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
4001d4cc:	94 07 bf f4 	add  %fp, -12, %o2                             
4001d4d0:	7f ff f4 3b 	call  4001a5bc <rtems_rfs_block_map_find>      
4001d4d4:	96 07 bf f0 	add  %fp, -16, %o3                             
                                         map, &bpos, &block);         
          if (rc > 0)                                                 
4001d4d8:	80 a2 20 00 	cmp  %o0, 0                                    
4001d4dc:	14 80 00 0e 	bg  4001d514 <rtems_rfs_file_set_size+0x154>   
4001d4e0:	80 a2 20 06 	cmp  %o0, 6                                    
                                           map, 1, &block);           
            if (rc > 0)                                               
              return rc;                                              
          }                                                           
                                                                      
          if (count < (length - bpos.boff))                           
4001d4e4:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4001d4e8:	80 a7 20 00 	cmp  %i4, 0                                    
4001d4ec:	12 80 00 16 	bne  4001d544 <rtems_rfs_file_set_size+0x184>  <== NEVER TAKEN
4001d4f0:	84 26 40 01 	sub  %i1, %g1, %g2                             
4001d4f4:	80 a0 80 1d 	cmp  %g2, %i5                                  
4001d4f8:	28 80 00 14 	bleu,a   4001d548 <rtems_rfs_file_set_size+0x188>
4001d4fc:	c0 26 a0 40 	clr  [ %i2 + 0x40 ]                            
          {                                                           
            length = count + bpos.boff;                               
4001d500:	b2 00 40 1d 	add  %g1, %i5, %i1                             
4001d504:	e2 2e a0 34 	stb  %l1, [ %i2 + 0x34 ]                       
 */                                                                   
static inline void                                                    
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,        
                                     rtems_rfs_block_off  offset)     
{                                                                     
  map->size.offset = offset;                                          
4001d508:	f2 26 a0 40 	st  %i1, [ %i2 + 0x40 ]                        
            read_block = true;                                        
4001d50c:	10 80 00 10 	b  4001d54c <rtems_rfs_file_set_size+0x18c>    
4001d510:	a4 10 20 01 	mov  1, %l2                                    
          if (rc > 0)                                                 
          {                                                           
            /*                                                        
             * Have we reached the EOF ?                              
             */                                                       
            if (rc != ENXIO)                                          
4001d514:	12 80 00 29 	bne  4001d5b8 <rtems_rfs_file_set_size+0x1f8>  <== NEVER TAKEN
4001d518:	92 10 00 10 	mov  %l0, %o1                                  
              return rc;                                              
                                                                      
            rc = rtems_rfs_block_map_grow (rtems_rfs_file_fs (handle),
4001d51c:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
4001d520:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
4001d524:	94 10 20 01 	mov  1, %o2                                    
4001d528:	7f ff f4 ae 	call  4001a7e0 <rtems_rfs_block_map_grow>      
4001d52c:	96 07 bf f0 	add  %fp, -16, %o3                             
                                           map, 1, &block);           
            if (rc > 0)                                               
4001d530:	80 a2 20 00 	cmp  %o0, 0                                    
4001d534:	04 bf ff ed 	ble  4001d4e8 <rtems_rfs_file_set_size+0x128>  <== ALWAYS TAKEN
4001d538:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
          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));
                                                                      
          rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
4001d53c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001d540:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
4001d544:	c0 26 a0 40 	clr  [ %i2 + 0x40 ]                            <== NOT EXECUTED
  map->dirty = true;                                                  
4001d548:	e2 2e a0 34 	stb  %l1, [ %i2 + 0x34 ]                       
          }                                                           
                                                                      
          /*                                                          
           * Only read the block if the length is not the block size. 
           */                                                         
          rc = rtems_rfs_buffer_handle_request (rtems_rfs_file_fs (handle),
4001d54c:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
4001d550:	d4 07 bf f0 	ld  [ %fp + -16 ], %o2                         
4001d554:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
4001d558:	92 10 00 13 	mov  %l3, %o1                                  
4001d55c:	7f ff f7 40 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001d560:	96 0c a0 01 	and  %l2, 1, %o3                               
                                                rtems_rfs_file_buffer (handle),
                                                block, read_block);   
          if (rc > 0)                                                 
4001d564:	80 a2 20 00 	cmp  %o0, 0                                    
4001d568:	14 80 00 14 	bg  4001d5b8 <rtems_rfs_file_set_size+0x1f8>   <== NEVER TAKEN
4001d56c:	d4 07 bf f8 	ld  [ %fp + -8 ], %o2                          
            return rc;                                                
                                                                      
          dst = rtems_rfs_buffer_data (&handle->buffer);              
4001d570:	c2 06 e0 0c 	ld  [ %i3 + 0xc ], %g1                         
          memset (dst + bpos.boff, 0, length - bpos.boff);            
4001d574:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
4001d578:	92 10 20 00 	clr  %o1                                       
4001d57c:	90 02 00 0a 	add  %o0, %o2, %o0                             
4001d580:	40 00 12 c9 	call  400220a4 <memset>                        
4001d584:	94 26 40 0a 	sub  %i1, %o2, %o2                             
                                                                      
          rtems_rfs_buffer_mark_dirty (rtems_rfs_file_buffer (handle));
                                                                      
          rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
4001d588:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
            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));
4001d58c:	e2 2e e0 04 	stb  %l1, [ %i3 + 4 ]                          
                                                                      
          rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
4001d590:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
4001d594:	7f ff f6 a9 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001d598:	92 10 00 13 	mov  %l3, %o1                                  
                                                rtems_rfs_file_buffer (handle));
          if (rc > 0)                                                 
4001d59c:	80 a2 20 00 	cmp  %o0, 0                                    
4001d5a0:	14 80 00 06 	bg  4001d5b8 <rtems_rfs_file_set_size+0x1f8>   <== NEVER TAKEN
4001d5a4:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
            return rc;                                                
                                                                      
          count -= length - bpos.boff;                                
4001d5a8:	82 26 40 01 	sub  %i1, %g1, %g1                             
4001d5ac:	ba a7 40 01 	subcc  %i5, %g1, %i5                           
4001d5b0:	10 bf ff b8 	b  4001d490 <rtems_rfs_file_set_size+0xd0>     
4001d5b4:	b8 67 20 00 	subx  %i4, 0, %i4                              
          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));
                                                                      
          rc = rtems_rfs_buffer_handle_release (rtems_rfs_file_fs (handle),
4001d5b8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001d5bc:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
         * Shrink                                                     
         */                                                           
        rtems_rfs_block_no blocks;                                    
        uint32_t           offset;                                    
                                                                      
        blocks =                                                      
4001d5c0:	f0 06 a0 3c 	ld  [ %i2 + 0x3c ], %i0                        
          rtems_rfs_block_map_count (map) -                           
          (((new_size - 1) /                                          
4001d5c4:	e2 04 20 08 	ld  [ %l0 + 8 ], %l1                           
4001d5c8:	92 87 7f ff 	addcc  %i5, -1, %o1                            
4001d5cc:	94 10 20 00 	clr  %o2                                       
4001d5d0:	90 47 3f ff 	addx  %i4, -1, %o0                             
4001d5d4:	40 00 47 e5 	call  4002f568 <__udivdi3>                     
4001d5d8:	96 10 00 11 	mov  %l1, %o3                                  
         * Shrink                                                     
         */                                                           
        rtems_rfs_block_no blocks;                                    
        uint32_t           offset;                                    
                                                                      
        blocks =                                                      
4001d5dc:	b0 06 3f ff 	add  %i0, -1, %i0                              
          rtems_rfs_block_map_count (map) -                           
          (((new_size - 1) /                                          
            rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle))) + 1);
                                                                      
        offset =                                                      
          new_size % rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
4001d5e0:	90 10 00 1c 	mov  %i4, %o0                                  
         * Shrink                                                     
         */                                                           
        rtems_rfs_block_no blocks;                                    
        uint32_t           offset;                                    
                                                                      
        blocks =                                                      
4001d5e4:	b0 26 00 09 	sub  %i0, %o1, %i0                             
          rtems_rfs_block_map_count (map) -                           
          (((new_size - 1) /                                          
            rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle))) + 1);
                                                                      
        offset =                                                      
          new_size % rtems_rfs_fs_block_size (rtems_rfs_file_fs (handle));
4001d5e8:	94 10 20 00 	clr  %o2                                       
4001d5ec:	92 10 00 1d 	mov  %i5, %o1                                  
4001d5f0:	40 00 48 b2 	call  4002f8b8 <__umoddi3>                     
4001d5f4:	96 10 00 11 	mov  %l1, %o3                                  
                                                                      
        if (blocks)                                                   
4001d5f8:	80 a6 20 00 	cmp  %i0, 0                                    
4001d5fc:	12 80 00 0b 	bne  4001d628 <rtems_rfs_file_set_size+0x268>  
4001d600:	ba 10 00 09 	mov  %o1, %i5                                  
            return rc;                                                
        }                                                             
                                                                      
        rtems_rfs_block_map_set_size_offset (map, offset);            
                                                                      
        if (rtems_rfs_block_pos_past_end (rtems_rfs_file_bpos (handle),
4001d604:	c4 06 e0 10 	ld  [ %i3 + 0x10 ], %g2                        
4001d608:	82 10 20 01 	mov  1, %g1                                    
 */                                                                   
static inline void                                                    
rtems_rfs_block_map_set_size_offset (rtems_rfs_block_map* map,        
                                     rtems_rfs_block_off  offset)     
{                                                                     
  map->size.offset = offset;                                          
4001d60c:	fa 26 a0 40 	st  %i5, [ %i2 + 0x40 ]                        
  map->dirty = true;                                                  
4001d610:	c2 2e a0 34 	stb  %g1, [ %i2 + 0x34 ]                       
4001d614:	80 a0 a0 00 	cmp  %g2, 0                                    
4001d618:	12 80 00 0d 	bne  4001d64c <rtems_rfs_file_set_size+0x28c>  
4001d61c:	c2 06 a0 3c 	ld  [ %i2 + 0x3c ], %g1                        
4001d620:	10 80 00 0f 	b  4001d65c <rtems_rfs_file_set_size+0x29c>    
4001d624:	80 a0 80 01 	cmp  %g2, %g1                                  
          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),
4001d628:	94 10 00 18 	mov  %i0, %o2                                  
4001d62c:	90 10 00 10 	mov  %l0, %o0                                  
4001d630:	7f ff f5 56 	call  4001ab88 <rtems_rfs_block_map_shrink>    
4001d634:	92 06 60 34 	add  %i1, 0x34, %o1                            
                                           rtems_rfs_file_map (handle),
                                           blocks);                   
          if (rc > 0)                                                 
4001d638:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001d63c:	14 80 00 28 	bg  4001d6dc <rtems_rfs_file_set_size+0x31c>   <== NEVER TAKEN
4001d640:	01 00 00 00 	nop                                            
            return rc;                                                
        }                                                             
                                                                      
        rtems_rfs_block_map_set_size_offset (map, offset);            
                                                                      
        if (rtems_rfs_block_pos_past_end (rtems_rfs_file_bpos (handle),
4001d644:	10 bf ff f1 	b  4001d608 <rtems_rfs_file_set_size+0x248>    
4001d648:	c4 06 e0 10 	ld  [ %i3 + 0x10 ], %g2                        
4001d64c:	80 a0 60 00 	cmp  %g1, 0                                    
4001d650:	22 80 00 0e 	be,a   4001d688 <rtems_rfs_file_set_size+0x2c8><== NEVER TAKEN
4001d654:	c2 26 e0 10 	st  %g1, [ %i3 + 0x10 ]                        <== NOT EXECUTED
4001d658:	80 a0 80 01 	cmp  %g2, %g1                                  
4001d65c:	3a 80 00 0b 	bcc,a   4001d688 <rtems_rfs_file_set_size+0x2c8><== NEVER TAKEN
4001d660:	c2 26 e0 10 	st  %g1, [ %i3 + 0x10 ]                        <== NOT EXECUTED
4001d664:	86 00 7f ff 	add  %g1, -1, %g3                              
4001d668:	80 a0 80 03 	cmp  %g2, %g3                                  
4001d66c:	32 80 00 0e 	bne,a   4001d6a4 <rtems_rfs_file_set_size+0x2e4><== NEVER TAKEN
4001d670:	c4 06 a0 3c 	ld  [ %i2 + 0x3c ], %g2                        <== NOT EXECUTED
4001d674:	c4 06 e0 14 	ld  [ %i3 + 0x14 ], %g2                        
4001d678:	80 a0 80 1d 	cmp  %g2, %i5                                  
4001d67c:	28 80 00 0a 	bleu,a   4001d6a4 <rtems_rfs_file_set_size+0x2e4>
4001d680:	c4 06 a0 3c 	ld  [ %i2 + 0x3c ], %g2                        
                                          rtems_rfs_block_map_size (map)))
          rtems_rfs_block_size_get_bpos (rtems_rfs_block_map_size (map),
4001d684:	c2 26 e0 10 	st  %g1, [ %i3 + 0x10 ]                        
4001d688:	fa 26 e0 14 	st  %i5, [ %i3 + 0x14 ]                        
4001d68c:	80 a7 60 00 	cmp  %i5, 0                                    
4001d690:	02 80 00 04 	be  4001d6a0 <rtems_rfs_file_set_size+0x2e0>   <== NEVER TAKEN
4001d694:	c0 26 e0 18 	clr  [ %i3 + 0x18 ]                            
4001d698:	82 00 7f ff 	add  %g1, -1, %g1                              
4001d69c:	c2 26 e0 10 	st  %g1, [ %i3 + 0x10 ]                        
                                         rtems_rfs_file_bpos (handle));
      }                                                               
    }                                                                 
                                                                      
    handle->shared->size.count  = rtems_rfs_block_map_count (map);    
4001d6a0:	c4 06 a0 3c 	ld  [ %i2 + 0x3c ], %g2                        
4001d6a4:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
4001d6a8:	c4 20 60 84 	st  %g2, [ %g1 + 0x84 ]                        
    handle->shared->size.offset = rtems_rfs_block_map_size_offset (map);
4001d6ac:	c4 06 a0 40 	ld  [ %i2 + 0x40 ], %g2                        
4001d6b0:	c4 20 60 88 	st  %g2, [ %g1 + 0x88 ]                        
  }                                                                   
                                                                      
  if (rtems_rfs_file_update_mtime (handle))                           
4001d6b4:	f0 06 c0 00 	ld  [ %i3 ], %i0                               
4001d6b8:	b0 8e 20 02 	andcc  %i0, 2, %i0                             
4001d6bc:	32 80 00 06 	bne,a   4001d6d4 <rtems_rfs_file_set_size+0x314><== NEVER TAKEN
4001d6c0:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
    handle->shared->mtime = time (NULL);                              
4001d6c4:	fa 06 e0 1c 	ld  [ %i3 + 0x1c ], %i5                        
4001d6c8:	40 00 23 01 	call  400262cc <time>                          
4001d6cc:	90 10 20 00 	clr  %o0                                       
4001d6d0:	d0 27 60 90 	st  %o0, [ %i5 + 0x90 ]                        
4001d6d4:	81 c7 e0 08 	ret                                            
4001d6d8:	81 e8 00 00 	restore                                        
                                                                      
  return 0;                                                           
}                                                                     
4001d6dc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001d6e0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

400108c0 <rtems_rfs_format>: return rc; } int rtems_rfs_format (const char* name, const rtems_rfs_format_config* config) {
400108c0:	9d e3 be e0 	save  %sp, -288, %sp                           
  rtems_rfs_file_system fs;                                           
  int                   group;                                        
  int                   rc;                                           
                                                                      
  if (config->verbose)                                                
400108c4:	c2 0e 60 15 	ldub  [ %i1 + 0x15 ], %g1                      
400108c8:	80 a0 60 00 	cmp  %g1, 0                                    
400108cc:	02 80 00 07 	be  400108e8 <rtems_rfs_format+0x28>           <== ALWAYS TAKEN
400108d0:	ba 07 bf 7c 	add  %fp, -132, %i5                            
    printf ("rtems-rfs: format: %s\n", name);                         
400108d4:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
400108d8:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
400108dc:	40 00 46 6b 	call  40022288 <printf>                        <== NOT EXECUTED
400108e0:	90 12 21 e8 	or  %o0, 0x1e8, %o0                            <== NOT EXECUTED
                                                                      
  memset (&fs, 0, sizeof (rtems_rfs_file_system));                    
400108e4:	ba 07 bf 7c 	add  %fp, -132, %i5                            <== NOT EXECUTED
400108e8:	92 10 20 00 	clr  %o1                                       
400108ec:	94 10 20 84 	mov  0x84, %o2                                 
400108f0:	40 00 45 ed 	call  400220a4 <memset>                        
400108f4:	90 10 00 1d 	mov  %i5, %o0                                  
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
400108f8:	82 07 bf c4 	add  %fp, -60, %g1                             
400108fc:	c2 27 bf c0 	st  %g1, [ %fp + -64 ]                         
  head->previous = NULL;                                              
  tail->previous = head;                                              
40010900:	82 07 bf c0 	add  %fp, -64, %g1                             
40010904:	c2 27 bf c8 	st  %g1, [ %fp + -56 ]                         
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40010908:	82 07 bf d4 	add  %fp, -44, %g1                             
4001090c:	c2 27 bf d0 	st  %g1, [ %fp + -48 ]                         
  head->previous = NULL;                                              
  tail->previous = head;                                              
40010910:	82 07 bf d0 	add  %fp, -48, %g1                             
40010914:	c2 27 bf d8 	st  %g1, [ %fp + -40 ]                         
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40010918:	82 07 bf e4 	add  %fp, -28, %g1                             
4001091c:	c2 27 bf e0 	st  %g1, [ %fp + -32 ]                         
  head->previous = NULL;                                              
  tail->previous = head;                                              
40010920:	82 07 bf e0 	add  %fp, -32, %g1                             
40010924:	c2 27 bf e8 	st  %g1, [ %fp + -24 ]                         
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
40010928:	82 07 bf f4 	add  %fp, -12, %g1                             
4001092c:	c2 27 bf f0 	st  %g1, [ %fp + -16 ]                         
  head->previous = NULL;                                              
  tail->previous = head;                                              
40010930:	82 07 bf f0 	add  %fp, -16, %g1                             
40010934:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
  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;                
40010938:	82 10 20 05 	mov  5, %g1                                    
4001093c:	c2 27 bf bc 	st  %g1, [ %fp + -68 ]                         
                                                                      
  fs.release_count = 0;                                               
  fs.release_modified_count = 0;                                      
                                                                      
  fs.flags = RTEMS_RFS_FS_NO_LOCAL_CACHE;                             
40010940:	82 10 20 02 	mov  2, %g1                                    
                                                                      
  /*                                                                  
   * Open the buffer interface.                                       
   */                                                                 
  rc = rtems_rfs_buffer_open (name, &fs);                             
40010944:	90 10 00 18 	mov  %i0, %o0                                  
  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;                             
40010948:	c2 27 bf 7c 	st  %g1, [ %fp + -132 ]                        
                                                                      
  /*                                                                  
   * Open the buffer interface.                                       
   */                                                                 
  rc = rtems_rfs_buffer_open (name, &fs);                             
4001094c:	40 00 2a ee 	call  4001b504 <rtems_rfs_buffer_open>         
40010950:	92 10 00 1d 	mov  %i5, %o1                                  
  if (rc > 0)                                                         
40010954:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40010958:	04 80 00 08 	ble  40010978 <rtems_rfs_format+0xb8>          <== ALWAYS TAKEN
4001095c:	c2 07 bf 8c 	ld  [ %fp + -116 ], %g1                        
  {                                                                   
    printf ("rtems-rfs: format: buffer open failed: %d: %s\n",        
40010960:	40 00 4a 8b 	call  4002338c <strerror>                      <== NOT EXECUTED
40010964:	01 00 00 00 	nop                                            <== NOT EXECUTED
40010968:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001096c:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010970:	10 80 01 06 	b  40010d88 <rtems_rfs_format+0x4c8>           <== NOT EXECUTED
40010974:	90 12 22 00 	or  %o0, 0x200, %o0	! 40033200 <_Semaphore_Translate_core_mutex_return_code_+0x70><== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * Check the media.                                                 
   */                                                                 
  if (rtems_rfs_fs_media_block_size (&fs) == 0)                       
40010978:	c2 00 60 20 	ld  [ %g1 + 0x20 ], %g1                        
4001097c:	80 a0 60 00 	cmp  %g1, 0                                    
40010980:	32 80 00 08 	bne,a   400109a0 <rtems_rfs_format+0xe0>       <== ALWAYS TAKEN
40010984:	c2 06 40 00 	ld  [ %i1 ], %g1                               
  {                                                                   
    printf ("rtems-rfs: media block is invalid: %" PRIu32 "\n",       
40010988:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
4001098c:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
40010990:	40 00 46 3e 	call  40022288 <printf>                        <== NOT EXECUTED
40010994:	90 12 22 30 	or  %o0, 0x230, %o0                            <== NOT EXECUTED
                                                                      
  /*                                                                  
   * Check the configuration data.                                    
   */                                                                 
  if (!rtems_rfs_check_config (&fs, config))                          
    return -1;                                                        
40010998:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001099c:	91 e8 3f ff 	restore  %g0, -1, %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;                                
  if (!fs->block_size)                                                
400109a0:	80 a0 60 00 	cmp  %g1, 0                                    
400109a4:	12 80 00 2a 	bne  40010a4c <rtems_rfs_format+0x18c>         
400109a8:	c2 27 bf 84 	st  %g1, [ %fp + -124 ]                        
  {                                                                   
    uint64_t total_size = rtems_rfs_fs_media_size (fs);               
400109ac:	40 00 34 28 	call  4001da4c <rtems_rfs_fs_media_size>       
400109b0:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
    if (total_size >= GIGS (1))                                       
400109b4:	80 a2 20 00 	cmp  %o0, 0                                    
400109b8:	12 80 00 08 	bne  400109d8 <rtems_rfs_format+0x118>         <== NEVER TAKEN
400109bc:	37 00 04 00 	sethi  %hi(0x100000), %i3                      
400109c0:	03 00 03 ff 	sethi  %hi(0xffc00), %g1                       
400109c4:	82 10 63 ff 	or  %g1, 0x3ff, %g1	! fffff <_TLS_Alignment+0xffffe>
400109c8:	80 a2 40 01 	cmp  %o1, %g1                                  
400109cc:	08 80 00 16 	bleu  40010a24 <rtems_rfs_format+0x164>        <== ALWAYS TAKEN
400109d0:	c2 07 bf 84 	ld  [ %fp + -124 ], %g1                        
    {                                                                 
      uint32_t gigs = (total_size + GIGS (1)) / GIGS (1);             
400109d4:	37 00 04 00 	sethi  %hi(0x100000), %i3                      <== NOT EXECUTED
400109d8:	86 82 40 1b 	addcc  %o1, %i3, %g3                           <== NOT EXECUTED
400109dc:	83 30 e0 14 	srl  %g3, 0x14, %g1                            <== NOT EXECUTED
400109e0:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
      int      b;                                                     
      for (b = 31; b > 0; b--)                                        
        if ((gigs & (1 << b)) != 0)                                   
400109e4:	86 10 20 01 	mov  1, %g3                                    <== 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);             
400109e8:	84 42 00 1a 	addx  %o0, %i2, %g2                            <== NOT EXECUTED
400109ec:	85 28 a0 0c 	sll  %g2, 0xc, %g2                             <== NOT EXECUTED
400109f0:	84 10 80 01 	or  %g2, %g1, %g2                              <== NOT EXECUTED
      int      b;                                                     
      for (b = 31; b > 0; b--)                                        
400109f4:	82 10 20 1f 	mov  0x1f, %g1                                 <== NOT EXECUTED
        if ((gigs & (1 << b)) != 0)                                   
400109f8:	89 28 c0 01 	sll  %g3, %g1, %g4                             <== NOT EXECUTED
400109fc:	80 89 00 02 	btst  %g4, %g2                                 <== NOT EXECUTED
40010a00:	32 80 00 06 	bne,a   40010a18 <rtems_rfs_format+0x158>      <== NOT EXECUTED
40010a04:	84 10 20 01 	mov  1, %g2                                    <== NOT EXECUTED
                                                                      
    if (total_size >= GIGS (1))                                       
    {                                                                 
      uint32_t gigs = (total_size + GIGS (1)) / GIGS (1);             
      int      b;                                                     
      for (b = 31; b > 0; b--)                                        
40010a08:	82 80 7f ff 	addcc  %g1, -1, %g1                            <== NOT EXECUTED
40010a0c:	12 bf ff fc 	bne  400109fc <rtems_rfs_format+0x13c>         <== NOT EXECUTED
40010a10:	89 28 c0 01 	sll  %g3, %g1, %g4                             <== NOT EXECUTED
        if ((gigs & (1 << b)) != 0)                                   
          break;                                                      
      fs->block_size = 1 << b;                                        
40010a14:	84 10 20 01 	mov  1, %g2                                    <== NOT EXECUTED
40010a18:	83 28 80 01 	sll  %g2, %g1, %g1                             <== NOT EXECUTED
40010a1c:	c2 27 bf 84 	st  %g1, [ %fp + -124 ]                        <== NOT EXECUTED
    }                                                                 
                                                                      
    if (fs->block_size < 512)                                         
40010a20:	c2 07 bf 84 	ld  [ %fp + -124 ], %g1                        <== NOT EXECUTED
40010a24:	80 a0 61 ff 	cmp  %g1, 0x1ff                                
40010a28:	18 80 00 05 	bgu  40010a3c <rtems_rfs_format+0x17c>         <== NEVER TAKEN
40010a2c:	c4 07 bf 84 	ld  [ %fp + -124 ], %g2                        
      fs->block_size = 512;                                           
40010a30:	82 10 22 00 	mov  0x200, %g1                                
40010a34:	c2 27 bf 84 	st  %g1, [ %fp + -124 ]                        
                                                                      
    if (fs->block_size > (4 * 1024))                                  
40010a38:	c4 07 bf 84 	ld  [ %fp + -124 ], %g2                        
40010a3c:	03 00 00 04 	sethi  %hi(0x1000), %g1                        
40010a40:	80 a0 80 01 	cmp  %g2, %g1                                  
40010a44:	38 80 00 02 	bgu,a   40010a4c <rtems_rfs_format+0x18c>      <== NEVER TAKEN
40010a48:	c2 27 bf 84 	st  %g1, [ %fp + -124 ]                        <== NOT EXECUTED
      fs->block_size = (4 * 1024);                                    
  }                                                                   
                                                                      
  if ((fs->block_size % rtems_rfs_fs_media_block_size (fs)) != 0)     
40010a4c:	c2 07 bf 8c 	ld  [ %fp + -116 ], %g1                        
40010a50:	f8 07 bf 84 	ld  [ %fp + -124 ], %i4                        
40010a54:	f6 00 60 20 	ld  [ %g1 + 0x20 ], %i3                        
40010a58:	90 10 00 1c 	mov  %i4, %o0                                  
40010a5c:	40 00 77 e8 	call  4002e9fc <.urem>                         
40010a60:	92 10 00 1b 	mov  %i3, %o1                                  
40010a64:	80 a2 20 00 	cmp  %o0, 0                                    
40010a68:	22 80 00 07 	be,a   40010a84 <rtems_rfs_format+0x1c4>       <== ALWAYS TAKEN
40010a6c:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
  {                                                                   
    printf ("block size (%zd) is not a multiple of media block size (%" PRId32 ")\n",
40010a70:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010a74:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
40010a78:	90 12 22 58 	or  %o0, 0x258, %o0                            <== NOT EXECUTED
40010a7c:	10 80 00 fb 	b  40010e68 <rtems_rfs_format+0x5a8>           <== NOT EXECUTED
40010a80:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
            fs->block_size, rtems_rfs_fs_media_block_size (fs));      
    return false;                                                     
  }                                                                   
                                                                      
  fs->group_blocks = config->group_blocks;                            
  if (!fs->group_blocks)                                              
40010a84:	80 a0 60 00 	cmp  %g1, 0                                    
40010a88:	02 80 00 04 	be  40010a98 <rtems_rfs_format+0x1d8>          <== ALWAYS TAKEN
40010a8c:	b9 2f 20 03 	sll  %i4, 3, %i4                               
    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;                            
40010a90:	10 80 00 03 	b  40010a9c <rtems_rfs_format+0x1dc>           <== NOT EXECUTED
40010a94:	c2 27 bf a4 	st  %g1, [ %fp + -92 ]                         <== 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);  
40010a98:	f8 27 bf a4 	st  %i4, [ %fp + -92 ]                         
  }                                                                   
                                                                      
  if (fs->group_blocks > rtems_rfs_bitmap_numof_bits (fs->block_size))
40010a9c:	c2 07 bf a4 	ld  [ %fp + -92 ], %g1                         
40010aa0:	80 a0 40 1c 	cmp  %g1, %i4                                  
40010aa4:	08 80 00 04 	bleu  40010ab4 <rtems_rfs_format+0x1f4>        <== ALWAYS TAKEN
40010aa8:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    
  {                                                                   
    printf ("group block count is higher than bits in block\n");      
40010aac:	10 80 00 bb 	b  40010d98 <rtems_rfs_format+0x4d8>           <== NOT EXECUTED
40010ab0:	90 12 22 98 	or  %o0, 0x298, %o0	! 40033298 <_Semaphore_Translate_core_mutex_return_code_+0x108><== NOT EXECUTED
    return false;                                                     
  }                                                                   
                                                                      
  fs->blocks = rtems_rfs_fs_media_size (fs) / fs->block_size;         
40010ab4:	40 00 33 e6 	call  4001da4c <rtems_rfs_fs_media_size>       
40010ab8:	90 10 00 1d 	mov  %i5, %o0                                  
40010abc:	f8 07 bf 84 	ld  [ %fp + -124 ], %i4                        
40010ac0:	94 10 20 00 	clr  %o2                                       
40010ac4:	40 00 7a a9 	call  4002f568 <__udivdi3>                     
40010ac8:	96 10 00 1c 	mov  %i4, %o3                                  
40010acc:	d2 27 bf 80 	st  %o1, [ %fp + -128 ]                        
40010ad0:	b6 10 00 09 	mov  %o1, %i3                                  
 * 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));  
40010ad4:	b5 2f 20 03 	sll  %i4, 3, %i2                               
 * "quotient = dividend / divisor"                                    
 */                                                                   
static int                                                            
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)          
{                                                                     
  if (dividend == 0)                                                  
40010ad8:	80 a2 60 00 	cmp  %o1, 0                                    
40010adc:	02 80 00 06 	be  40010af4 <rtems_rfs_format+0x234>          <== NEVER TAKEN
40010ae0:	a0 10 20 01 	mov  1, %l0                                    
    return 1;                                                         
  return ((dividend - 1) / divisor) + 1;                              
40010ae4:	90 02 7f ff 	add  %o1, -1, %o0                              
40010ae8:	7f ff c6 db 	call  40002654 <.udiv>                         
40010aec:	92 10 00 1a 	mov  %i2, %o1                                  
40010af0:	a0 02 20 01 	add  %o0, 1, %l0                               
   * 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;                            
40010af4:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
  /*                                                                  
   * 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), 
40010af8:	e0 27 bf a0 	st  %l0, [ %fp + -96 ]                         
                                            rtems_rfs_bits_per_block (fs));
                                                                      
  fs->group_inodes = config->group_inodes;                            
  if (!fs->group_inodes)                                              
40010afc:	80 a0 60 00 	cmp  %g1, 0                                    
40010b00:	12 80 00 19 	bne  40010b64 <rtems_rfs_format+0x2a4>         <== NEVER TAKEN
40010b04:	c2 27 bf a8 	st  %g1, [ %fp + -88 ]                         
    int inode_overhead = RTEMS_RFS_INODE_OVERHEAD_PERCENTAGE;         
                                                                      
    /*                                                                
     * The number of inodes per group is set as a percentage.         
     */                                                               
    if (config->inode_overhead)                                       
40010b08:	d0 06 60 0c 	ld  [ %i1 + 0xc ], %o0                         
40010b0c:	80 a2 20 00 	cmp  %o0, 0                                    
40010b10:	22 80 00 02 	be,a   40010b18 <rtems_rfs_format+0x258>       <== ALWAYS TAKEN
40010b14:	90 10 20 01 	mov  1, %o0                                    
rtems_rfs_inodes_from_percent (rtems_rfs_file_system* fs,             
                               int                    percentage)     
{                                                                     
  int blocks;                                                         
  blocks = ((rtems_rfs_fs_blocks (fs) -                               
             RTEMS_RFS_SUPERBLOCK_SIZE) * percentage) / 100;          
40010b18:	7f ff c6 95 	call  4000256c <.umul>                         
40010b1c:	92 06 ff ff 	add  %i3, -1, %o1                              
40010b20:	92 10 20 64 	mov  0x64, %o1                                 
40010b24:	7f ff c6 cc 	call  40002654 <.udiv>                         
40010b28:	b6 10 20 01 	mov  1, %i3                                    
 * "quotient = dividend / divisor"                                    
 */                                                                   
static int                                                            
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)          
{                                                                     
  if (dividend == 0)                                                  
40010b2c:	80 a2 20 00 	cmp  %o0, 0                                    
40010b30:	22 80 00 07 	be,a   40010b4c <rtems_rfs_format+0x28c>       
40010b34:	92 10 20 38 	mov  0x38, %o1                                 
    return 1;                                                         
  return ((dividend - 1) / divisor) + 1;                              
40010b38:	90 02 3f ff 	add  %o0, -1, %o0                              
40010b3c:	7f ff c6 c6 	call  40002654 <.udiv>                         
40010b40:	92 10 00 10 	mov  %l0, %o1                                  
40010b44:	b6 02 20 01 	add  %o0, 1, %i3                               
{                                                                     
  int blocks;                                                         
  blocks = ((rtems_rfs_fs_blocks (fs) -                               
             RTEMS_RFS_SUPERBLOCK_SIZE) * percentage) / 100;          
  blocks = rtems_rfs_rup_quotient (blocks, fs->group_count);          
  return blocks * (rtems_rfs_fs_block_size (fs) / RTEMS_RFS_INODE_SIZE);
40010b48:	92 10 20 38 	mov  0x38, %o1                                 
40010b4c:	7f ff c6 c2 	call  40002654 <.udiv>                         
40010b50:	90 10 00 1c 	mov  %i4, %o0                                  
40010b54:	92 10 00 08 	mov  %o0, %o1                                  
40010b58:	7f ff c6 85 	call  4000256c <.umul>                         
40010b5c:	90 10 00 1b 	mov  %i3, %o0                                  
     * 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);
40010b60:	d0 27 bf a8 	st  %o0, [ %fp + -88 ]                         
  }                                                                   
                                                                      
  /*                                                                  
   * 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;
40010b64:	90 10 00 1c 	mov  %i4, %o0                                  
40010b68:	7f ff c6 bb 	call  40002654 <.udiv>                         
40010b6c:	92 10 20 38 	mov  0x38, %o1                                 
  fs->group_inodes =                                                  
    rtems_rfs_rup_quotient (fs->group_inodes,                         
40010b70:	c2 07 bf a8 	ld  [ %fp + -88 ], %g1                         
  }                                                                   
                                                                      
  /*                                                                  
   * 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;
40010b74:	d0 27 bf ac 	st  %o0, [ %fp + -84 ]                         
40010b78:	b8 10 00 08 	mov  %o0, %i4                                  
 * "quotient = dividend / divisor"                                    
 */                                                                   
static int                                                            
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)          
{                                                                     
  if (dividend == 0)                                                  
40010b7c:	80 a0 60 00 	cmp  %g1, 0                                    
40010b80:	02 80 00 06 	be  40010b98 <rtems_rfs_format+0x2d8>          <== NEVER TAKEN
40010b84:	90 10 20 01 	mov  1, %o0                                    
    return 1;                                                         
  return ((dividend - 1) / divisor) + 1;                              
40010b88:	90 00 7f ff 	add  %g1, -1, %o0                              
40010b8c:	7f ff c6 b2 	call  40002654 <.udiv>                         
40010b90:	92 10 00 1c 	mov  %i4, %o1                                  
40010b94:	90 02 20 01 	inc  %o0                                       
   * 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,                         
                            fs->inodes_per_block) * fs->inodes_per_block;
40010b98:	7f ff c6 75 	call  4000256c <.umul>                         
40010b9c:	92 10 00 1c 	mov  %i4, %o1                                  
                                                                      
  if (fs->group_inodes > rtems_rfs_bitmap_numof_bits (fs->block_size))
40010ba0:	80 a2 00 1a 	cmp  %o0, %i2                                  
40010ba4:	38 80 00 03 	bgu,a   40010bb0 <rtems_rfs_format+0x2f0>      <== NEVER TAKEN
40010ba8:	f4 27 bf a8 	st  %i2, [ %fp + -88 ]                         <== NOT EXECUTED
40010bac:	d0 27 bf a8 	st  %o0, [ %fp + -88 ]                         
    fs->group_inodes = rtems_rfs_bitmap_numof_bits (fs->block_size);  
                                                                      
  fs->max_name_length = config->max_name_length;                      
40010bb0:	c2 06 60 10 	ld  [ %i1 + 0x10 ], %g1                        
  if (!fs->max_name_length)                                           
40010bb4:	80 a0 60 00 	cmp  %g1, 0                                    
40010bb8:	22 80 00 02 	be,a   40010bc0 <rtems_rfs_format+0x300>       <== ALWAYS TAKEN
40010bbc:	82 10 22 00 	mov  0x200, %g1                                
                            fs->inodes_per_block) * fs->inodes_per_block;
                                                                      
  if (fs->group_inodes > rtems_rfs_bitmap_numof_bits (fs->block_size))
    fs->group_inodes = rtems_rfs_bitmap_numof_bits (fs->block_size);  
                                                                      
  fs->max_name_length = config->max_name_length;                      
40010bc0:	c2 27 bf 98 	st  %g1, [ %fp + -104 ]                        
   * Check the configuration data.                                    
   */                                                                 
  if (!rtems_rfs_check_config (&fs, config))                          
    return -1;                                                        
                                                                      
  if (config->verbose)                                                
40010bc4:	c2 0e 60 15 	ldub  [ %i1 + 0x15 ], %g1                      
40010bc8:	80 a0 60 00 	cmp  %g1, 0                                    
40010bcc:	02 80 00 65 	be  40010d60 <rtems_rfs_format+0x4a0>          <== ALWAYS TAKEN
40010bd0:	d2 07 bf 84 	ld  [ %fp + -124 ], %o1                        
  {                                                                   
    printf ("rtems-rfs: format: media size = %" PRIu64 "\n",          
40010bd4:	40 00 33 9e 	call  4001da4c <rtems_rfs_fs_media_size>       <== NOT EXECUTED
40010bd8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40010bdc:	84 10 00 08 	mov  %o0, %g2                                  <== NOT EXECUTED
40010be0:	86 10 00 09 	mov  %o1, %g3                                  <== NOT EXECUTED
40010be4:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010be8:	92 10 00 02 	mov  %g2, %o1                                  <== NOT EXECUTED
40010bec:	94 10 00 03 	mov  %g3, %o2                                  <== NOT EXECUTED
40010bf0:	40 00 45 a6 	call  40022288 <printf>                        <== NOT EXECUTED
40010bf4:	90 12 22 c8 	or  %o0, 0x2c8, %o0                            <== NOT EXECUTED
            rtems_rfs_fs_media_size (&fs));                           
    printf ("rtems-rfs: format: media blocks = %" PRIu32 "\n",        
40010bf8:	c2 07 bf 8c 	ld  [ %fp + -116 ], %g1                        <== NOT EXECUTED
40010bfc:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c00:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1                        <== NOT EXECUTED
40010c04:	40 00 45 a1 	call  40022288 <printf>                        <== NOT EXECUTED
40010c08:	90 12 22 f0 	or  %o0, 0x2f0, %o0                            <== NOT EXECUTED
            rtems_rfs_fs_media_blocks (&fs));                         
    printf ("rtems-rfs: format: media block size = %" PRIu32 "\n",    
40010c0c:	c2 07 bf 8c 	ld  [ %fp + -116 ], %g1                        <== NOT EXECUTED
40010c10:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c14:	d2 00 60 20 	ld  [ %g1 + 0x20 ], %o1                        <== NOT EXECUTED
40010c18:	40 00 45 9c 	call  40022288 <printf>                        <== NOT EXECUTED
40010c1c:	90 12 23 18 	or  %o0, 0x318, %o0                            <== NOT EXECUTED
            rtems_rfs_fs_media_block_size (&fs));                     
    printf ("rtems-rfs: format: size = %" PRIu64 "\n",                
40010c20:	40 00 33 82 	call  4001da28 <rtems_rfs_fs_size>             <== NOT EXECUTED
40010c24:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40010c28:	84 10 00 08 	mov  %o0, %g2                                  <== NOT EXECUTED
40010c2c:	86 10 00 09 	mov  %o1, %g3                                  <== NOT EXECUTED
40010c30:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c34:	92 10 00 02 	mov  %g2, %o1                                  <== NOT EXECUTED
40010c38:	94 10 00 03 	mov  %g3, %o2                                  <== NOT EXECUTED
40010c3c:	40 00 45 93 	call  40022288 <printf>                        <== NOT EXECUTED
40010c40:	90 12 23 48 	or  %o0, 0x348, %o0                            <== NOT EXECUTED
            rtems_rfs_fs_size (&fs));                                 
    printf ("rtems-rfs: format: blocks = %zu\n",                      
40010c44:	d2 07 bf 80 	ld  [ %fp + -128 ], %o1                        <== NOT EXECUTED
40010c48:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c4c:	40 00 45 8f 	call  40022288 <printf>                        <== NOT EXECUTED
40010c50:	90 12 23 68 	or  %o0, 0x368, %o0	! 40033368 <_Semaphore_Translate_core_mutex_return_code_+0x1d8><== NOT EXECUTED
            rtems_rfs_fs_blocks (&fs));                               
    printf ("rtems-rfs: format: block size = %zu\n",                  
40010c54:	d2 07 bf 84 	ld  [ %fp + -124 ], %o1                        <== NOT EXECUTED
40010c58:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c5c:	40 00 45 8b 	call  40022288 <printf>                        <== NOT EXECUTED
40010c60:	90 12 23 90 	or  %o0, 0x390, %o0	! 40033390 <_Semaphore_Translate_core_mutex_return_code_+0x200><== NOT EXECUTED
            rtems_rfs_fs_block_size (&fs));                           
    printf ("rtems-rfs: format: bits per block = %u\n",               
40010c64:	d2 07 bf 84 	ld  [ %fp + -124 ], %o1                        <== NOT EXECUTED
40010c68:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c6c:	93 2a 60 03 	sll  %o1, 3, %o1                               <== NOT EXECUTED
40010c70:	40 00 45 86 	call  40022288 <printf>                        <== NOT EXECUTED
40010c74:	90 12 23 b8 	or  %o0, 0x3b8, %o0                            <== NOT EXECUTED
            rtems_rfs_bits_per_block (&fs));                          
    printf ("rtems-rfs: format: inode size = %zu\n", RTEMS_RFS_INODE_SIZE);
40010c78:	92 10 20 38 	mov  0x38, %o1                                 <== NOT EXECUTED
40010c7c:	11 10 00 cc 	sethi  %hi(0x40033000), %o0                    <== NOT EXECUTED
40010c80:	40 00 45 82 	call  40022288 <printf>                        <== NOT EXECUTED
40010c84:	90 12 23 e0 	or  %o0, 0x3e0, %o0	! 400333e0 <_Semaphore_Translate_core_mutex_return_code_+0x250><== NOT EXECUTED
    printf ("rtems-rfs: format: inodes = %zu (%d.%d%%)\n",            
40010c88:	d2 07 bf a0 	ld  [ %fp + -96 ], %o1                         <== NOT EXECUTED
            fs.group_inodes * fs.group_count,                         
40010c8c:	f8 07 bf a8 	ld  [ %fp + -88 ], %i4                         <== NOT EXECUTED
    printf ("rtems-rfs: format: block size = %zu\n",                  
            rtems_rfs_fs_block_size (&fs));                           
    printf ("rtems-rfs: format: bits per block = %u\n",               
            rtems_rfs_bits_per_block (&fs));                          
    printf ("rtems-rfs: format: inode size = %zu\n", RTEMS_RFS_INODE_SIZE);
    printf ("rtems-rfs: format: inodes = %zu (%d.%d%%)\n",            
40010c90:	7f ff c6 37 	call  4000256c <.umul>                         <== NOT EXECUTED
40010c94:	90 10 00 1c 	mov  %i4, %o0                                  <== 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,
40010c98:	83 2f 20 03 	sll  %i4, 3, %g1                               <== NOT EXECUTED
    printf ("rtems-rfs: format: block size = %zu\n",                  
            rtems_rfs_fs_block_size (&fs));                           
    printf ("rtems-rfs: format: bits per block = %u\n",               
            rtems_rfs_bits_per_block (&fs));                          
    printf ("rtems-rfs: format: inode size = %zu\n", RTEMS_RFS_INODE_SIZE);
    printf ("rtems-rfs: format: inodes = %zu (%d.%d%%)\n",            
40010c9c:	b4 10 00 08 	mov  %o0, %i2                                  <== 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,
40010ca0:	b9 2f 20 06 	sll  %i4, 6, %i4                               <== NOT EXECUTED
                                  rtems_rfs_fs_block_size (fs));      
40010ca4:	f6 07 bf 84 	ld  [ %fp + -124 ], %i3                        <== NOT EXECUTED
 * "quotient = dividend / divisor"                                    
 */                                                                   
static int                                                            
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)          
{                                                                     
  if (dividend == 0)                                                  
40010ca8:	b8 a7 00 01 	subcc  %i4, %g1, %i4                           <== NOT EXECUTED
40010cac:	02 80 00 06 	be  40010cc4 <rtems_rfs_format+0x404>          <== NOT EXECUTED
40010cb0:	90 10 20 01 	mov  1, %o0                                    <== NOT EXECUTED
    return 1;                                                         
  return ((dividend - 1) / divisor) + 1;                              
40010cb4:	90 07 3f ff 	add  %i4, -1, %o0                              <== NOT EXECUTED
40010cb8:	7f ff c6 67 	call  40002654 <.udiv>                         <== NOT EXECUTED
40010cbc:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
40010cc0:	90 02 20 01 	inc  %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))
40010cc4:	c2 07 bf 80 	ld  [ %fp + -128 ], %g1                        <== 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));  
40010cc8:	b7 2e e0 03 	sll  %i3, 3, %i3                               <== 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))
40010ccc:	92 00 7f ff 	add  %g1, -1, %o1                              <== NOT EXECUTED
40010cd0:	80 a6 c0 09 	cmp  %i3, %o1                                  <== NOT EXECUTED
40010cd4:	28 80 00 02 	bleu,a   40010cdc <rtems_rfs_format+0x41c>     <== NOT EXECUTED
40010cd8:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
    bits_per_block = rtems_rfs_fs_blocks (fs) - RTEMS_RFS_SUPERBLOCK_SIZE;
  return ((blocks + 1) * 100 * 10) / bits_per_block;                  
40010cdc:	84 02 20 01 	add  %o0, 1, %g2                               <== NOT EXECUTED
40010ce0:	87 28 a0 02 	sll  %g2, 2, %g3                               <== NOT EXECUTED
40010ce4:	89 28 a0 07 	sll  %g2, 7, %g4                               <== NOT EXECUTED
40010ce8:	86 21 00 03 	sub  %g4, %g3, %g3                             <== NOT EXECUTED
40010cec:	90 00 c0 02 	add  %g3, %g2, %o0                             <== NOT EXECUTED
40010cf0:	7f ff c6 5b 	call  4000265c <.div>                          <== NOT EXECUTED
40010cf4:	91 2a 20 03 	sll  %o0, 3, %o0                               <== NOT EXECUTED
    printf ("rtems-rfs: format: block size = %zu\n",                  
            rtems_rfs_fs_block_size (&fs));                           
    printf ("rtems-rfs: format: bits per block = %u\n",               
            rtems_rfs_bits_per_block (&fs));                          
    printf ("rtems-rfs: format: inode size = %zu\n", RTEMS_RFS_INODE_SIZE);
    printf ("rtems-rfs: format: inodes = %zu (%d.%d%%)\n",            
40010cf8:	92 10 20 0a 	mov  0xa, %o1                                  <== NOT EXECUTED
40010cfc:	7f ff c6 58 	call  4000265c <.div>                          <== NOT EXECUTED
40010d00:	b6 10 00 08 	mov  %o0, %i3                                  <== NOT EXECUTED
40010d04:	92 10 20 0a 	mov  0xa, %o1                                  <== NOT EXECUTED
40010d08:	b8 10 00 08 	mov  %o0, %i4                                  <== NOT EXECUTED
40010d0c:	40 00 77 3e 	call  4002ea04 <.rem>                          <== NOT EXECUTED
40010d10:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
40010d14:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
40010d18:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
40010d1c:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
40010d20:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010d24:	40 00 45 59 	call  40022288 <printf>                        <== NOT EXECUTED
40010d28:	90 12 20 08 	or  %o0, 8, %o0	! 40033408 <_Semaphore_Translate_core_mutex_return_code_+0x278><== 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);      
40010d2c:	d2 07 bf a0 	ld  [ %fp + -96 ], %o1                         <== NOT EXECUTED
40010d30:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010d34:	40 00 45 55 	call  40022288 <printf>                        <== NOT EXECUTED
40010d38:	90 12 20 38 	or  %o0, 0x38, %o0	! 40033438 <_Semaphore_Translate_core_mutex_return_code_+0x2a8><== NOT EXECUTED
    printf ("rtems-rfs: format: group blocks = %zu\n", fs.group_blocks);
40010d3c:	d2 07 bf a4 	ld  [ %fp + -92 ], %o1                         <== NOT EXECUTED
40010d40:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010d44:	40 00 45 51 	call  40022288 <printf>                        <== NOT EXECUTED
40010d48:	90 12 20 58 	or  %o0, 0x58, %o0	! 40033458 <_Semaphore_Translate_core_mutex_return_code_+0x2c8><== NOT EXECUTED
    printf ("rtems-rfs: format: group inodes = %zu\n", fs.group_inodes);
40010d4c:	d2 07 bf a8 	ld  [ %fp + -88 ], %o1                         <== NOT EXECUTED
40010d50:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010d54:	40 00 45 4d 	call  40022288 <printf>                        <== NOT EXECUTED
40010d58:	90 12 20 80 	or  %o0, 0x80, %o0	! 40033480 <_Semaphore_Translate_core_mutex_return_code_+0x2f0><== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_setblksize (&fs, rtems_rfs_fs_block_size (&fs));
40010d5c:	d2 07 bf 84 	ld  [ %fp + -124 ], %o1                        <== NOT EXECUTED
40010d60:	40 00 2a 87 	call  4001b77c <rtems_rfs_buffer_setblksize>   
40010d64:	90 10 00 1d 	mov  %i5, %o0                                  
  if (rc > 0)                                                         
40010d68:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40010d6c:	24 80 00 0e 	ble,a   40010da4 <rtems_rfs_format+0x4e4>      <== ALWAYS TAKEN
40010d70:	c0 2f bf 54 	clrb  [ %fp + -172 ]                           
  {                                                                   
    printf ("rtems-rfs: format: setting block size failed: %d: %s\n", 
40010d74:	40 00 49 86 	call  4002338c <strerror>                      <== NOT EXECUTED
40010d78:	01 00 00 00 	nop                                            <== NOT EXECUTED
40010d7c:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40010d80:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010d84:	90 12 20 a8 	or  %o0, 0xa8, %o0	! 400334a8 <_Semaphore_Translate_core_mutex_return_code_+0x318><== NOT EXECUTED
40010d88:	10 80 00 38 	b  40010e68 <rtems_rfs_format+0x5a8>           <== NOT EXECUTED
40010d8c:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
    return -1;                                                        
  }                                                                   
                                                                      
  if (!rtems_rfs_write_superblock (&fs))                              
  {                                                                   
    printf ("rtems-rfs: format: superblock write failed\n");          
40010d90:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010d94:	90 12 21 a0 	or  %o0, 0x1a0, %o0	! 400335a0 <_Semaphore_Translate_core_mutex_return_code_+0x410><== NOT EXECUTED
40010d98:	40 00 45 cb 	call  400224c4 <puts>                          <== NOT EXECUTED
40010d9c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40010da0:	30 80 02 17 	b,a   400115fc <rtems_rfs_format+0xd3c>        <== 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;                                                  
40010da4:	c0 27 bf 58 	clr  [ %fp + -168 ]                            
  handle->buffer = NULL;                                              
40010da8:	c0 27 bf 5c 	clr  [ %fp + -164 ]                            
    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);       
40010dac:	90 10 00 1d 	mov  %i5, %o0                                  
40010db0:	92 07 bf 54 	add  %fp, -172, %o1                            
40010db4:	94 10 20 00 	clr  %o2                                       
40010db8:	40 00 29 29 	call  4001b25c <rtems_rfs_buffer_handle_request>
40010dbc:	96 10 20 00 	clr  %o3                                       
  if (rc > 0)                                                         
40010dc0:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40010dc4:	04 80 00 2d 	ble  40010e78 <rtems_rfs_format+0x5b8>         <== ALWAYS TAKEN
40010dc8:	92 07 bf 54 	add  %fp, -172, %o1                            
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
40010dcc:	7f ff fe b3 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
40010dd0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("rtems-rfs: write-superblock: request failed: %d: %s\n",  
40010dd4:	40 00 49 6e 	call  4002338c <strerror>                      <== NOT EXECUTED
40010dd8:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
40010ddc:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40010de0:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40010de4:	90 12 20 e0 	or  %o0, 0xe0, %o0	! 400334e0 <_Semaphore_Translate_core_mutex_return_code_+0x350><== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_handle_close (fs, &handle);                   
  if (rc > 0)                                                         
  {                                                                   
    printf ("rtems-rfs: write-superblock: buffer handle close failed: %d: %s\n",
40010de8:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
40010dec:	40 00 45 27 	call  40022288 <printf>                        <== NOT EXECUTED
40010df0:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
    printf ("rtems-rfs: format: setting block size failed: %d: %s\n", 
            rc, strerror (rc));                                       
    return -1;                                                        
  }                                                                   
                                                                      
  if (!rtems_rfs_write_superblock (&fs))                              
40010df4:	80 8e a0 ff 	btst  0xff, %i2                                
40010df8:	02 bf ff e6 	be  40010d90 <rtems_rfs_format+0x4d0>          <== NEVER TAKEN
40010dfc:	29 10 00 cd 	sethi  %hi(0x40033400), %l4                    
  rc = rtems_rfs_bitmap_map_clear_all (&bitmap);                      
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_bitmap_close (&bitmap);                                 
    rtems_rfs_buffer_handle_close (fs, &handle);                      
    printf ("\nrtems-rfs: write-group: group %3d: inode bitmap" \     
40010e00:	2b 10 00 cd 	sethi  %hi(0x40033400), %l5                    
  rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,       
                              group_base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
    printf ("\nrtems-rfs: write-group: group %3d: open inode bitmap failed: %d: %s\n",
40010e04:	2d 10 00 cd 	sethi  %hi(0x40033400), %l6                    
    printf ("rtems-rfs: format: setting block size failed: %d: %s\n", 
            rc, strerror (rc));                                       
    return -1;                                                        
  }                                                                   
                                                                      
  if (!rtems_rfs_write_superblock (&fs))                              
40010e08:	b8 10 20 00 	clr  %i4                                       
   */                                                                 
  rc = rtems_rfs_bitmap_close (&bitmap);                              
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
    printf ("\nrtems-rfs: write-group: group %3d: close inode" \      
40010e0c:	a8 15 23 e0 	or  %l4, 0x3e0, %l4                            
  rc = rtems_rfs_bitmap_map_clear_all (&bitmap);                      
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_bitmap_close (&bitmap);                                 
    rtems_rfs_buffer_handle_close (fs, &handle);                      
    printf ("\nrtems-rfs: write-group: group %3d: inode bitmap" \     
40010e10:	aa 15 63 90 	or  %l5, 0x390, %l5                            
  rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,       
                              group_base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
    printf ("\nrtems-rfs: write-group: group %3d: open inode bitmap failed: %d: %s\n",
40010e14:	ac 15 a3 48 	or  %l6, 0x348, %l6                            
  {                                                                   
    printf ("rtems-rfs: format: superblock write failed\n");          
    return -1;                                                        
  }                                                                   
                                                                      
  for (group = 0; group < fs.group_count; group++)                    
40010e18:	c2 07 bf a0 	ld  [ %fp + -96 ], %g1                         
40010e1c:	80 a7 00 01 	cmp  %i4, %g1                                  
40010e20:	06 80 00 87 	bl  4001103c <rtems_rfs_format+0x77c>          
40010e24:	e4 0e 60 15 	ldub  [ %i1 + 0x15 ], %l2                      
    if (!rtems_rfs_write_group (&fs, group,                           
                                config->initialise_inodes, config->verbose))
      return -1;                                                      
                                                                      
  if (config->verbose)                                                
40010e28:	80 8c a0 ff 	btst  0xff, %l2                                
40010e2c:	02 80 00 04 	be  40010e3c <rtems_rfs_format+0x57c>          <== ALWAYS TAKEN
40010e30:	01 00 00 00 	nop                                            
    printf ("\n");                                                    
40010e34:	40 00 45 7b 	call  40022420 <putchar>                       <== NOT EXECUTED
40010e38:	90 10 20 0a 	mov  0xa, %o0	! a <_TLS_Alignment+0x9>         <== NOT EXECUTED
                                                                      
  rc = rtems_rfs_buffer_close (&fs);                                  
40010e3c:	40 00 2a 8b 	call  4001b868 <rtems_rfs_buffer_close>        
40010e40:	90 10 00 1d 	mov  %i5, %o0                                  
  if (rc > 0)                                                         
40010e44:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40010e48:	24 80 01 67 	ble,a   400113e4 <rtems_rfs_format+0xb24>      <== ALWAYS TAKEN
40010e4c:	90 10 00 18 	mov  %i0, %o0                                  
  {                                                                   
    printf ("rtems-rfs: format: buffer close failed: %d: %s\n",       
40010e50:	40 00 49 4f 	call  4002338c <strerror>                      <== NOT EXECUTED
40010e54:	01 00 00 00 	nop                                            <== NOT EXECUTED
40010e58:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40010e5c:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40010e60:	90 12 20 b0 	or  %o0, 0xb0, %o0	! 400338b0 <_Semaphore_Translate_core_mutex_return_code_+0x720><== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_write_root_dir (name);                               
  if (rc > 0)                                                         
  {                                                                   
    printf ("rtems-rfs: format: writing root dir failed: %d: %s\n",   
40010e64:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
40010e68:	40 00 45 08 	call  40022288 <printf>                        <== NOT EXECUTED
40010e6c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40010e70:	81 c7 e0 08 	ret                                            
40010e74:	81 e8 00 00 	restore                                        
    printf ("rtems-rfs: write-superblock: request failed: %d: %s\n",  
            rc, strerror (rc));                                       
    return false;                                                     
  }                                                                   
                                                                      
  sb = rtems_rfs_buffer_data (&handle);                               
40010e78:	c2 07 bf 5c 	ld  [ %fp + -164 ], %g1                        
                                                                      
#define write_sb(_o, _d) rtems_rfs_write_u32(sb + (_o), _d)           
                                                                      
  memset (sb, 0xff, rtems_rfs_fs_block_size (fs));                    
40010e7c:	d4 07 bf 84 	ld  [ %fp + -124 ], %o2                        
    printf ("rtems-rfs: write-superblock: request failed: %d: %s\n",  
            rc, strerror (rc));                                       
    return false;                                                     
  }                                                                   
                                                                      
  sb = rtems_rfs_buffer_data (&handle);                               
40010e80:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        
                                                                      
#define write_sb(_o, _d) rtems_rfs_write_u32(sb + (_o), _d)           
                                                                      
  memset (sb, 0xff, rtems_rfs_fs_block_size (fs));                    
40010e84:	92 10 20 ff 	mov  0xff, %o1                                 
40010e88:	40 00 44 87 	call  400220a4 <memset>                        
40010e8c:	90 10 00 01 	mov  %g1, %o0                                  
                                                                      
  write_sb (RTEMS_RFS_SB_OFFSET_MAGIC, RTEMS_RFS_SB_MAGIC);           
40010e90:	84 10 20 28 	mov  0x28, %g2                                 
40010e94:	c4 2a 00 00 	stb  %g2, [ %o0 ]                              
40010e98:	84 10 20 09 	mov  9, %g2                                    
40010e9c:	c4 2a 20 01 	stb  %g2, [ %o0 + 1 ]                          
40010ea0:	84 10 20 20 	mov  0x20, %g2                                 
  write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);          
40010ea4:	c0 2a 20 04 	clrb  [ %o0 + 4 ]                              
                                                                      
#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);           
40010ea8:	c4 2a 20 02 	stb  %g2, [ %o0 + 2 ]                          
  write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);          
40010eac:	c0 2a 20 05 	clrb  [ %o0 + 5 ]                              
40010eb0:	c0 2a 20 06 	clrb  [ %o0 + 6 ]                              
40010eb4:	c0 2a 20 07 	clrb  [ %o0 + 7 ]                              
                                                                      
#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);           
40010eb8:	86 10 20 01 	mov  1, %g3                                    
40010ebc:	c6 2a 20 03 	stb  %g3, [ %o0 + 3 ]                          
  write_sb (RTEMS_RFS_SB_OFFSET_VERSION, RTEMS_RFS_VERSION);          
  write_sb (RTEMS_RFS_SB_OFFSET_BLOCKS, rtems_rfs_fs_blocks (fs));    
40010ec0:	c4 07 bf 80 	ld  [ %fp + -128 ], %g2                        
  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);                 
40010ec4:	92 07 bf 54 	add  %fp, -172, %o1                            
                                                                      
  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));    
40010ec8:	89 30 a0 18 	srl  %g2, 0x18, %g4                            
40010ecc:	c8 2a 20 0c 	stb  %g4, [ %o0 + 0xc ]                        
40010ed0:	89 30 a0 10 	srl  %g2, 0x10, %g4                            
40010ed4:	c4 2a 20 0f 	stb  %g2, [ %o0 + 0xf ]                        
40010ed8:	c8 2a 20 0d 	stb  %g4, [ %o0 + 0xd ]                        
40010edc:	89 30 a0 08 	srl  %g2, 8, %g4                               
  write_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE, rtems_rfs_fs_block_size (fs));
40010ee0:	c4 0f bf 84 	ldub  [ %fp + -124 ], %g2                      
                                                                      
  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));    
40010ee4:	c8 2a 20 0e 	stb  %g4, [ %o0 + 0xe ]                        
  write_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE, rtems_rfs_fs_block_size (fs));
40010ee8:	c4 2a 20 08 	stb  %g2, [ %o0 + 8 ]                          
40010eec:	c4 17 bf 84 	lduh  [ %fp + -124 ], %g2                      
40010ef0:	c4 2a 20 09 	stb  %g2, [ %o0 + 9 ]                          
40010ef4:	c4 07 bf 84 	ld  [ %fp + -124 ], %g2                        
40010ef8:	85 30 a0 08 	srl  %g2, 8, %g2                               
40010efc:	c4 2a 20 0a 	stb  %g2, [ %o0 + 0xa ]                        
40010f00:	c4 07 bf 84 	ld  [ %fp + -124 ], %g2                        
40010f04:	c4 2a 20 0b 	stb  %g2, [ %o0 + 0xb ]                        
  write_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS, fs->bad_blocks);          
40010f08:	c4 0f bf 94 	ldub  [ %fp + -108 ], %g2                      
40010f0c:	c4 2a 20 10 	stb  %g2, [ %o0 + 0x10 ]                       
40010f10:	c4 17 bf 94 	lduh  [ %fp + -108 ], %g2                      
40010f14:	c4 2a 20 11 	stb  %g2, [ %o0 + 0x11 ]                       
40010f18:	c4 07 bf 94 	ld  [ %fp + -108 ], %g2                        
40010f1c:	85 30 a0 08 	srl  %g2, 8, %g2                               
40010f20:	c4 2a 20 12 	stb  %g2, [ %o0 + 0x12 ]                       
40010f24:	c4 07 bf 94 	ld  [ %fp + -108 ], %g2                        
40010f28:	c4 2a 20 13 	stb  %g2, [ %o0 + 0x13 ]                       
  write_sb (RTEMS_RFS_SB_OFFSET_MAX_NAME_LENGTH, fs->max_name_length);
40010f2c:	c4 0f bf 98 	ldub  [ %fp + -104 ], %g2                      
40010f30:	c4 2a 20 14 	stb  %g2, [ %o0 + 0x14 ]                       
40010f34:	c4 17 bf 98 	lduh  [ %fp + -104 ], %g2                      
40010f38:	c4 2a 20 15 	stb  %g2, [ %o0 + 0x15 ]                       
40010f3c:	c4 07 bf 98 	ld  [ %fp + -104 ], %g2                        
40010f40:	85 30 a0 08 	srl  %g2, 8, %g2                               
40010f44:	c4 2a 20 16 	stb  %g2, [ %o0 + 0x16 ]                       
40010f48:	c4 07 bf 98 	ld  [ %fp + -104 ], %g2                        
40010f4c:	c4 2a 20 17 	stb  %g2, [ %o0 + 0x17 ]                       
  write_sb (RTEMS_RFS_SB_OFFSET_GROUPS, fs->group_count);             
40010f50:	c4 0f bf a0 	ldub  [ %fp + -96 ], %g2                       
40010f54:	c4 2a 20 18 	stb  %g2, [ %o0 + 0x18 ]                       
40010f58:	c4 17 bf a0 	lduh  [ %fp + -96 ], %g2                       
40010f5c:	c4 2a 20 19 	stb  %g2, [ %o0 + 0x19 ]                       
40010f60:	c4 07 bf a0 	ld  [ %fp + -96 ], %g2                         
40010f64:	85 30 a0 08 	srl  %g2, 8, %g2                               
40010f68:	c4 2a 20 1a 	stb  %g2, [ %o0 + 0x1a ]                       
40010f6c:	c4 07 bf a0 	ld  [ %fp + -96 ], %g2                         
40010f70:	c4 2a 20 1b 	stb  %g2, [ %o0 + 0x1b ]                       
  write_sb (RTEMS_RFS_SB_OFFSET_GROUP_BLOCKS, fs->group_blocks);      
40010f74:	c4 0f bf a4 	ldub  [ %fp + -92 ], %g2                       
40010f78:	c4 2a 20 1c 	stb  %g2, [ %o0 + 0x1c ]                       
40010f7c:	c4 17 bf a4 	lduh  [ %fp + -92 ], %g2                       
40010f80:	c4 2a 20 1d 	stb  %g2, [ %o0 + 0x1d ]                       
40010f84:	c4 07 bf a4 	ld  [ %fp + -92 ], %g2                         
40010f88:	85 30 a0 08 	srl  %g2, 8, %g2                               
40010f8c:	c4 2a 20 1e 	stb  %g2, [ %o0 + 0x1e ]                       
40010f90:	c4 07 bf a4 	ld  [ %fp + -92 ], %g2                         
40010f94:	c4 2a 20 1f 	stb  %g2, [ %o0 + 0x1f ]                       
  write_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES, fs->group_inodes);      
40010f98:	c4 0f bf a8 	ldub  [ %fp + -88 ], %g2                       
40010f9c:	c4 2a 20 20 	stb  %g2, [ %o0 + 0x20 ]                       
40010fa0:	c4 17 bf a8 	lduh  [ %fp + -88 ], %g2                       
40010fa4:	c4 2a 20 21 	stb  %g2, [ %o0 + 0x21 ]                       
40010fa8:	c4 07 bf a8 	ld  [ %fp + -88 ], %g2                         
40010fac:	85 30 a0 08 	srl  %g2, 8, %g2                               
40010fb0:	c4 2a 20 22 	stb  %g2, [ %o0 + 0x22 ]                       
40010fb4:	c4 07 bf a8 	ld  [ %fp + -88 ], %g2                         
  write_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE, RTEMS_RFS_INODE_SIZE);    
40010fb8:	c0 2a 20 24 	clrb  [ %o0 + 0x24 ]                           
  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);      
40010fbc:	c4 2a 20 23 	stb  %g2, [ %o0 + 0x23 ]                       
  write_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE, RTEMS_RFS_INODE_SIZE);    
40010fc0:	c0 2a 20 25 	clrb  [ %o0 + 0x25 ]                           
40010fc4:	c0 2a 20 26 	clrb  [ %o0 + 0x26 ]                           
40010fc8:	84 10 20 38 	mov  0x38, %g2                                 
40010fcc:	c4 2a 20 27 	stb  %g2, [ %o0 + 0x27 ]                       
                                                                      
  rtems_rfs_buffer_mark_dirty (&handle);                              
40010fd0:	c6 2f bf 54 	stb  %g3, [ %fp + -172 ]                       
                                                                      
  rc = rtems_rfs_buffer_handle_release (fs, &handle);                 
40010fd4:	40 00 28 19 	call  4001b038 <rtems_rfs_buffer_handle_release>
40010fd8:	90 10 00 1d 	mov  %i5, %o0                                  
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
40010fdc:	92 07 bf 54 	add  %fp, -172, %o1                            
  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);                 
40010fe0:	b8 10 00 08 	mov  %o0, %i4                                  
  if (rc > 0)                                                         
40010fe4:	80 a7 20 00 	cmp  %i4, 0                                    
40010fe8:	04 80 00 0a 	ble  40011010 <rtems_rfs_format+0x750>         <== ALWAYS TAKEN
40010fec:	90 10 00 1d 	mov  %i5, %o0                                  
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
40010ff0:	7f ff fe 2a 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
40010ff4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    printf ("rtems-rfs: write-superblock: buffer release failed: %d: %s\n",
40010ff8:	40 00 48 e5 	call  4002338c <strerror>                      <== NOT EXECUTED
40010ffc:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
40011000:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011004:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40011008:	10 bf ff 78 	b  40010de8 <rtems_rfs_format+0x528>           <== NOT EXECUTED
4001100c:	90 12 21 18 	or  %o0, 0x118, %o0	! 40033518 <_Semaphore_Translate_core_mutex_return_code_+0x388><== NOT EXECUTED
            rc, strerror (rc));                                       
    return false;                                                     
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_handle_close (fs, &handle);                   
40011010:	7f ff fe 22 	call  40010898 <rtems_rfs_buffer_handle_close> 
40011014:	b4 10 20 01 	mov  1, %i2                                    
  if (rc > 0)                                                         
40011018:	80 a2 20 00 	cmp  %o0, 0                                    
4001101c:	04 bf ff 76 	ble  40010df4 <rtems_rfs_format+0x534>         <== ALWAYS TAKEN
40011020:	b8 10 00 08 	mov  %o0, %i4                                  
  {                                                                   
    printf ("rtems-rfs: write-superblock: buffer handle close failed: %d: %s\n",
40011024:	40 00 48 da 	call  4002338c <strerror>                      <== NOT EXECUTED
40011028:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001102c:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011030:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40011034:	10 bf ff 6d 	b  40010de8 <rtems_rfs_format+0x528>           <== NOT EXECUTED
40011038:	90 12 21 58 	or  %o0, 0x158, %o0	! 40033558 <_Semaphore_Translate_core_mutex_return_code_+0x3c8><== NOT EXECUTED
  size_t                   group_size;                                
  int                      blocks;                                    
  int                      b;                                         
  int                      rc;                                        
                                                                      
  group_base = rtems_rfs_fs_block (fs, group, 0);                     
4001103c:	f6 07 bf a4 	ld  [ %fp + -92 ], %i3                         
40011040:	90 10 00 1c 	mov  %i4, %o0                                  
40011044:	7f ff c5 4a 	call  4000256c <.umul>                         
40011048:	92 10 00 1b 	mov  %i3, %o1                                  
                                                                      
  if (group_base > rtems_rfs_fs_blocks (fs))                          
4001104c:	c2 07 bf 80 	ld  [ %fp + -128 ], %g1                        
  size_t                   group_size;                                
  int                      blocks;                                    
  int                      b;                                         
  int                      rc;                                        
                                                                      
  group_base = rtems_rfs_fs_block (fs, group, 0);                     
40011050:	a0 02 20 01 	add  %o0, 1, %l0                               
    printf ("rtems-rfs: format: superblock write failed\n");          
    return -1;                                                        
  }                                                                   
                                                                      
  for (group = 0; group < fs.group_count; group++)                    
    if (!rtems_rfs_write_group (&fs, group,                           
40011054:	ee 0e 60 14 	ldub  [ %i1 + 0x14 ], %l7                      
  int                      b;                                         
  int                      rc;                                        
                                                                      
  group_base = rtems_rfs_fs_block (fs, group, 0);                     
                                                                      
  if (group_base > rtems_rfs_fs_blocks (fs))                          
40011058:	80 a4 00 01 	cmp  %l0, %g1                                  
4001105c:	08 80 00 08 	bleu  4001107c <rtems_rfs_format+0x7bc>        <== ALWAYS TAKEN
40011060:	a2 10 00 08 	mov  %o0, %l1                                  
  {                                                                   
    printf ("rtems-rfs: write-group: group %d base beyond disk limit\n",
40011064:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40011068:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001106c:	40 00 44 87 	call  40022288 <printf>                        <== NOT EXECUTED
40011070:	90 12 21 d0 	or  %o0, 0x1d0, %o0                            <== NOT EXECUTED
  rc = rtems_rfs_buffer_handle_close (fs, &handle);                   
  if (rc > 0)                                                         
  {                                                                   
    printf ("\nrtems-rfs: write-group: buffer handle close failed: %d: %s\n",
            rc, strerror (rc));                                       
    return false;                                                     
40011074:	10 80 00 d7 	b  400113d0 <rtems_rfs_format+0xb10>           <== NOT EXECUTED
40011078:	82 10 20 00 	clr  %g1                                       <== 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))           
4001107c:	84 04 00 1b 	add  %l0, %i3, %g2                             
40011080:	80 a0 80 01 	cmp  %g2, %g1                                  
40011084:	38 80 00 02 	bgu,a   4001108c <rtems_rfs_format+0x7cc>      <== ALWAYS TAKEN
40011088:	b6 20 40 10 	sub  %g1, %l0, %i3                             
    group_size = rtems_rfs_fs_blocks (fs) - group_base;               
                                                                      
  if (verbose)                                                        
4001108c:	a4 8c a0 ff 	andcc  %l2, 0xff, %l2                          
40011090:	22 80 00 09 	be,a   400110b4 <rtems_rfs_format+0x7f4>       <== ALWAYS TAKEN
40011094:	c0 2f bf 48 	clrb  [ %fp + -184 ]                           
    printf ("\rrtems-rfs: format: group %3d: base = %" PRId32 ", size = %zd",
40011098:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
4001109c:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
400110a0:	90 12 22 10 	or  %o0, 0x210, %o0                            <== NOT EXECUTED
400110a4:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
400110a8:	40 00 44 78 	call  40022288 <printf>                        <== NOT EXECUTED
400110ac:	96 10 00 1b 	mov  %i3, %o3                                  <== NOT EXECUTED
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
400110b0:	c0 2f bf 48 	clrb  [ %fp + -184 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
400110b4:	c0 27 bf 4c 	clr  [ %fp + -180 ]                            
    printf ("\nrtems-rfs: write-group: handle open failed: %d: %s\n", 
            rc, strerror (rc));                                       
    return false;                                                     
  }                                                                   
                                                                      
  if (verbose)                                                        
400110b8:	80 a4 a0 00 	cmp  %l2, 0                                    
400110bc:	02 80 00 05 	be  400110d0 <rtems_rfs_format+0x810>          <== ALWAYS TAKEN
400110c0:	c0 27 bf 50 	clr  [ %fp + -176 ]                            
    printf (", blocks");                                              
400110c4:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
400110c8:	40 00 44 70 	call  40022288 <printf>                        <== NOT EXECUTED
400110cc:	90 12 22 48 	or  %o0, 0x248, %o0	! 40033648 <_Semaphore_Translate_core_mutex_return_code_+0x4b8><== NOT EXECUTED
                                                                      
  /*                                                                  
   * Open the block bitmap using the new buffer.                      
   */                                                                 
  rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,       
400110d0:	98 10 00 10 	mov  %l0, %o4                                  
400110d4:	90 07 bf 54 	add  %fp, -172, %o0                            
400110d8:	92 10 00 1d 	mov  %i5, %o1                                  
400110dc:	94 07 bf 48 	add  %fp, -184, %o2                            
400110e0:	40 00 23 69 	call  40019e84 <rtems_rfs_bitmap_open>         
400110e4:	96 10 00 1b 	mov  %i3, %o3                                  
                              group_base + RTEMS_RFS_GROUP_BLOCK_BITMAP_BLOCK);
  if (rc > 0)                                                         
400110e8:	a0 92 20 00 	orcc  %o0, 0, %l0                              
400110ec:	04 80 00 0a 	ble  40011114 <rtems_rfs_format+0x854>         <== ALWAYS TAKEN
400110f0:	92 07 bf 48 	add  %fp, -184, %o1                            
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
400110f4:	7f ff fd e9 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
400110f8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: open block bitmap failed: %d: %s\n",
400110fc:	40 00 48 a4 	call  4002338c <strerror>                      <== NOT EXECUTED
40011100:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
40011104:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
40011108:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
4001110c:	10 80 00 17 	b  40011168 <rtems_rfs_format+0x8a8>           <== NOT EXECUTED
40011110:	90 12 22 58 	or  %o0, 0x258, %o0	! 40033658 <_Semaphore_Translate_core_mutex_return_code_+0x4c8><== 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));
40011114:	c2 07 bf 50 	ld  [ %fp + -176 ], %g1                        
40011118:	d4 07 bf 84 	ld  [ %fp + -124 ], %o2                        
4001111c:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40011120:	40 00 43 e1 	call  400220a4 <memset>                        
40011124:	92 10 20 ff 	mov  0xff, %o1                                 
                                                                      
  /*                                                                  
   * Clear the bitmap.                                                
   */                                                                 
  rc = rtems_rfs_bitmap_map_clear_all (&bitmap);                      
40011128:	40 00 22 b2 	call  40019bf0 <rtems_rfs_bitmap_map_clear_all>
4001112c:	90 07 bf 54 	add  %fp, -172, %o0                            
40011130:	a0 10 00 08 	mov  %o0, %l0                                  
  if (rc > 0)                                                         
40011134:	80 a4 20 00 	cmp  %l0, 0                                    
40011138:	04 80 00 0f 	ble  40011174 <rtems_rfs_format+0x8b4>         <== ALWAYS TAKEN
4001113c:	90 07 bf 54 	add  %fp, -172, %o0                            
  {                                                                   
    rtems_rfs_bitmap_close (&bitmap);                                 
40011140:	40 00 23 62 	call  40019ec8 <rtems_rfs_bitmap_close>        <== NOT EXECUTED
40011144:	01 00 00 00 	nop                                            <== NOT EXECUTED
    rtems_rfs_buffer_handle_close (fs, &handle);                      
40011148:	92 07 bf 48 	add  %fp, -184, %o1                            <== NOT EXECUTED
4001114c:	7f ff fd d3 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
40011150:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: block bitmap clear all failed: %d: %s\n",
40011154:	40 00 48 8e 	call  4002338c <strerror>                      <== NOT EXECUTED
40011158:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001115c:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
40011160:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40011164:	90 12 22 a0 	or  %o0, 0x2a0, %o0	! 400336a0 <_Semaphore_Translate_core_mutex_return_code_+0x510><== NOT EXECUTED
40011168:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001116c:	10 80 00 61 	b  400112f0 <rtems_rfs_format+0xa30>           <== NOT EXECUTED
40011170:	94 10 00 10 	mov  %l0, %o2                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * Forced allocation of the block bitmap.                           
   */                                                                 
  rtems_rfs_bitmap_map_set (&bitmap, RTEMS_RFS_GROUP_BLOCK_BITMAP_BLOCK);
40011174:	40 00 22 57 	call  40019ad0 <rtems_rfs_bitmap_map_set>      
40011178:	92 10 20 00 	clr  %o1                                       
                                                                      
  /*                                                                  
   * Forced allocation of the inode bitmap.                           
   */                                                                 
  rtems_rfs_bitmap_map_set (&bitmap, RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
4001117c:	92 10 20 01 	mov  1, %o1                                    
40011180:	40 00 22 54 	call  40019ad0 <rtems_rfs_bitmap_map_set>      
40011184:	90 07 bf 54 	add  %fp, -172, %o0                            
                                                                      
  /*                                                                  
   * Determine the number of inodes blocks in the group.              
   */                                                                 
  blocks = rtems_rfs_rup_quotient (fs->group_inodes, fs->inodes_per_block);
40011188:	d0 07 bf a8 	ld  [ %fp + -88 ], %o0                         
4001118c:	d2 07 bf ac 	ld  [ %fp + -84 ], %o1                         
 * "quotient = dividend / divisor"                                    
 */                                                                   
static int                                                            
rtems_rfs_rup_quotient (uint32_t dividend, uint32_t divisor)          
{                                                                     
  if (dividend == 0)                                                  
40011190:	80 a2 20 00 	cmp  %o0, 0                                    
40011194:	02 80 00 05 	be  400111a8 <rtems_rfs_format+0x8e8>          <== NEVER TAKEN
40011198:	a0 10 20 01 	mov  1, %l0                                    
    return 1;                                                         
  return ((dividend - 1) / divisor) + 1;                              
4001119c:	7f ff c5 2e 	call  40002654 <.udiv>                         
400111a0:	90 02 3f ff 	add  %o0, -1, %o0                              
400111a4:	a0 02 20 01 	add  %o0, 1, %l0                               
  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++)                                        
400111a8:	a6 10 20 00 	clr  %l3                                       
400111ac:	80 a4 c0 10 	cmp  %l3, %l0                                  
400111b0:	16 80 00 07 	bge  400111cc <rtems_rfs_format+0x90c>         
400111b4:	90 07 bf 54 	add  %fp, -172, %o0                            
    rtems_rfs_bitmap_map_set (&bitmap, b + RTEMS_RFS_GROUP_INODE_BLOCK);
400111b8:	92 04 e0 02 	add  %l3, 2, %o1                               
400111bc:	40 00 22 45 	call  40019ad0 <rtems_rfs_bitmap_map_set>      
400111c0:	a6 04 e0 01 	inc  %l3                                       
  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++)                                        
400111c4:	10 bf ff fb 	b  400111b0 <rtems_rfs_format+0x8f0>           
400111c8:	80 a4 c0 10 	cmp  %l3, %l0                                  
    rtems_rfs_bitmap_map_set (&bitmap, b + RTEMS_RFS_GROUP_INODE_BLOCK);
                                                                      
  /*                                                                  
   * Close the block bitmap.                                          
   */                                                                 
  rc = rtems_rfs_bitmap_close (&bitmap);                              
400111cc:	40 00 23 3f 	call  40019ec8 <rtems_rfs_bitmap_close>        
400111d0:	01 00 00 00 	nop                                            
  if (rc > 0)                                                         
400111d4:	a6 92 20 00 	orcc  %o0, 0, %l3                              
400111d8:	24 80 00 0d 	ble,a   4001120c <rtems_rfs_format+0x94c>      <== ALWAYS TAKEN
400111dc:	82 10 20 01 	mov  1, %g1                                    
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
400111e0:	92 07 bf 48 	add  %fp, -184, %o1                            <== NOT EXECUTED
400111e4:	7f ff fd ad 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
400111e8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: close block bitmap failed: %d: %s\n",
400111ec:	40 00 48 68 	call  4002338c <strerror>                      <== NOT EXECUTED
400111f0:	90 10 00 13 	mov  %l3, %o0                                  <== NOT EXECUTED
400111f4:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
400111f8:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
400111fc:	94 10 00 13 	mov  %l3, %o2                                  <== NOT EXECUTED
40011200:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
40011204:	10 80 00 3b 	b  400112f0 <rtems_rfs_format+0xa30>           <== NOT EXECUTED
40011208:	90 12 22 f0 	or  %o0, 0x2f0, %o0	! 400336f0 <_Semaphore_Translate_core_mutex_return_code_+0x560><== NOT EXECUTED
    return false;                                                     
  }                                                                   
                                                                      
  rtems_rfs_buffer_mark_dirty (&handle);                              
                                                                      
  if (verbose)                                                        
4001120c:	80 a4 a0 00 	cmp  %l2, 0                                    
40011210:	02 80 00 05 	be  40011224 <rtems_rfs_format+0x964>          <== ALWAYS TAKEN
40011214:	c2 2f bf 48 	stb  %g1, [ %fp + -184 ]                       
    printf (", inodes");                                              
40011218:	11 10 00 cd 	sethi  %hi(0x40033400), %o0                    <== NOT EXECUTED
4001121c:	40 00 44 1b 	call  40022288 <printf>                        <== NOT EXECUTED
40011220:	90 12 23 38 	or  %o0, 0x338, %o0	! 40033738 <_Semaphore_Translate_core_mutex_return_code_+0x5a8><== NOT EXECUTED
                                                                      
  /*                                                                  
   * Open the inode bitmap using the old buffer. Should release any changes.
   */                                                                 
  rc = rtems_rfs_bitmap_open (&bitmap, fs, &handle, group_size,       
40011224:	96 10 00 1b 	mov  %i3, %o3                                  
40011228:	90 07 bf 54 	add  %fp, -172, %o0                            
4001122c:	92 10 00 1d 	mov  %i5, %o1                                  
40011230:	94 07 bf 48 	add  %fp, -184, %o2                            
40011234:	40 00 23 14 	call  40019e84 <rtems_rfs_bitmap_open>         
40011238:	98 04 60 02 	add  %l1, 2, %o4                               
                              group_base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
  if (rc > 0)                                                         
4001123c:	b6 92 20 00 	orcc  %o0, 0, %i3                              
40011240:	04 80 00 09 	ble  40011264 <rtems_rfs_format+0x9a4>         <== ALWAYS TAKEN
40011244:	92 07 bf 48 	add  %fp, -184, %o1                            
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
40011248:	7f ff fd 94 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001124c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: open inode bitmap failed: %d: %s\n",
40011250:	40 00 48 4f 	call  4002338c <strerror>                      <== NOT EXECUTED
40011254:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
40011258:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
4001125c:	10 80 00 23 	b  400112e8 <rtems_rfs_format+0xa28>           <== NOT EXECUTED
40011260:	90 10 00 16 	mov  %l6, %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), 0x00, rtems_rfs_fs_block_size (fs));
40011264:	c2 07 bf 50 	ld  [ %fp + -176 ], %g1                        
40011268:	d4 07 bf 84 	ld  [ %fp + -124 ], %o2                        
4001126c:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
40011270:	40 00 43 8d 	call  400220a4 <memset>                        
40011274:	92 10 20 00 	clr  %o1                                       
                                                                      
  /*                                                                  
   * Clear the inode bitmap.                                          
   */                                                                 
  rc = rtems_rfs_bitmap_map_clear_all (&bitmap);                      
40011278:	40 00 22 5e 	call  40019bf0 <rtems_rfs_bitmap_map_clear_all>
4001127c:	90 07 bf 54 	add  %fp, -172, %o0                            
40011280:	b6 10 00 08 	mov  %o0, %i3                                  
  if (rc > 0)                                                         
40011284:	80 a6 e0 00 	cmp  %i3, 0                                    
40011288:	04 80 00 0c 	ble  400112b8 <rtems_rfs_format+0x9f8>         <== ALWAYS TAKEN
4001128c:	90 07 bf 54 	add  %fp, -172, %o0                            
  {                                                                   
    rtems_rfs_bitmap_close (&bitmap);                                 
40011290:	40 00 23 0e 	call  40019ec8 <rtems_rfs_bitmap_close>        <== NOT EXECUTED
40011294:	01 00 00 00 	nop                                            <== NOT EXECUTED
    rtems_rfs_buffer_handle_close (fs, &handle);                      
40011298:	92 07 bf 48 	add  %fp, -184, %o1                            <== NOT EXECUTED
4001129c:	7f ff fd 7f 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
400112a0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: inode bitmap" \     
400112a4:	40 00 48 3a 	call  4002338c <strerror>                      <== NOT EXECUTED
400112a8:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
400112ac:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
400112b0:	10 80 00 0e 	b  400112e8 <rtems_rfs_format+0xa28>           <== NOT EXECUTED
400112b4:	90 10 00 15 	mov  %l5, %o0                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * Close the inode bitmap.                                          
   */                                                                 
  rc = rtems_rfs_bitmap_close (&bitmap);                              
400112b8:	40 00 23 04 	call  40019ec8 <rtems_rfs_bitmap_close>        
400112bc:	01 00 00 00 	nop                                            
  if (rc > 0)                                                         
400112c0:	b6 92 20 00 	orcc  %o0, 0, %i3                              
400112c4:	24 80 00 0f 	ble,a   40011300 <rtems_rfs_format+0xa40>      <== ALWAYS TAKEN
400112c8:	82 10 20 01 	mov  1, %g1                                    
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
400112cc:	92 07 bf 48 	add  %fp, -184, %o1                            <== NOT EXECUTED
400112d0:	7f ff fd 72 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
400112d4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: close inode" \      
400112d8:	40 00 48 2d 	call  4002338c <strerror>                      <== NOT EXECUTED
400112dc:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
400112e0:	96 10 00 08 	mov  %o0, %o3                                  <== NOT EXECUTED
400112e4:	90 10 00 14 	mov  %l4, %o0                                  <== NOT EXECUTED
400112e8:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
400112ec:	94 10 00 1b 	mov  %i3, %o2                                  <== NOT EXECUTED
400112f0:	40 00 43 e6 	call  40022288 <printf>                        <== NOT EXECUTED
400112f4:	01 00 00 00 	nop                                            <== NOT EXECUTED
  rc = rtems_rfs_buffer_handle_close (fs, &handle);                   
  if (rc > 0)                                                         
  {                                                                   
    printf ("\nrtems-rfs: write-group: buffer handle close failed: %d: %s\n",
            rc, strerror (rc));                                       
    return false;                                                     
400112f8:	10 80 00 36 	b  400113d0 <rtems_rfs_format+0xb10>           <== NOT EXECUTED
400112fc:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   <== NOT EXECUTED
    printf ("\nrtems-rfs: write-group: group %3d: close inode" \      
            " bitmap failed: %d: %s\n", group, rc, strerror (rc));    
    return false;                                                     
  }                                                                   
                                                                      
  rtems_rfs_buffer_mark_dirty (&handle);                              
40011300:	c2 2f bf 48 	stb  %g1, [ %fp + -184 ]                       
                                                                      
  /*                                                                  
   * Initialise the inode tables if required to do so.                
   */                                                                 
  if (initialise_inodes)                                              
40011304:	80 8d e0 ff 	btst  0xff, %l7                                
40011308:	b6 10 20 00 	clr  %i3                                       
  {                                                                   
    for (b = 0; b < blocks; b++)                                      
    {                                                                 
      rc = rtems_rfs_buffer_handle_request (fs, &handle,              
                                            group_base + b + RTEMS_RFS_GROUP_INODE_BLOCK,
4001130c:	a6 04 60 03 	add  %l1, 3, %l3                               
  rtems_rfs_buffer_mark_dirty (&handle);                              
                                                                      
  /*                                                                  
   * Initialise the inode tables if required to do so.                
   */                                                                 
  if (initialise_inodes)                                              
40011310:	12 80 00 18 	bne  40011370 <rtems_rfs_format+0xab0>         <== NEVER TAKEN
40011314:	ae 10 00 1d 	mov  %i5, %l7                                  
                                                                      
      rtems_rfs_buffer_mark_dirty (&handle);                          
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_buffer_handle_close (fs, &handle);                   
40011318:	90 10 00 17 	mov  %l7, %o0                                  
4001131c:	7f ff fd 5f 	call  40010898 <rtems_rfs_buffer_handle_close> 
40011320:	92 07 bf 48 	add  %fp, -184, %o1                            
  if (rc > 0)                                                         
40011324:	b6 92 20 00 	orcc  %o0, 0, %i3                              
40011328:	04 80 00 2a 	ble  400113d0 <rtems_rfs_format+0xb10>         <== ALWAYS TAKEN
4001132c:	82 10 00 1a 	mov  %i2, %g1                                  
  {                                                                   
    printf ("\nrtems-rfs: write-group: buffer handle close failed: %d: %s\n",
40011330:	40 00 48 17 	call  4002338c <strerror>                      <== NOT EXECUTED
40011334:	01 00 00 00 	nop                                            <== NOT EXECUTED
40011338:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001133c:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011340:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011344:	40 00 43 d1 	call  40022288 <printf>                        <== NOT EXECUTED
40011348:	90 12 20 70 	or  %o0, 0x70, %o0	! 40033870 <_Semaphore_Translate_core_mutex_return_code_+0x6e0><== NOT EXECUTED
            rc, strerror (rc));                                       
    return false;                                                     
4001134c:	10 80 00 21 	b  400113d0 <rtems_rfs_format+0xb10>           <== NOT EXECUTED
40011350:	82 10 20 00 	clr  %g1                                       <== 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));
40011354:	d4 07 bf 84 	ld  [ %fp + -124 ], %o2                        <== NOT EXECUTED
40011358:	d0 00 a0 1c 	ld  [ %g2 + 0x1c ], %o0                        <== NOT EXECUTED
4001135c:	40 00 43 52 	call  400220a4 <memset>                        <== NOT EXECUTED
40011360:	92 10 20 ff 	mov  0xff, %o1                                 <== NOT EXECUTED
                                                                      
      rtems_rfs_buffer_mark_dirty (&handle);                          
40011364:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
  /*                                                                  
   * Initialise the inode tables if required to do so.                
   */                                                                 
  if (initialise_inodes)                                              
  {                                                                   
    for (b = 0; b < blocks; b++)                                      
40011368:	b6 06 e0 01 	inc  %i3                                       <== 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));
                                                                      
      rtems_rfs_buffer_mark_dirty (&handle);                          
4001136c:	c2 2f bf 48 	stb  %g1, [ %fp + -184 ]                       <== NOT EXECUTED
  /*                                                                  
   * Initialise the inode tables if required to do so.                
   */                                                                 
  if (initialise_inodes)                                              
  {                                                                   
    for (b = 0; b < blocks; b++)                                      
40011370:	80 a6 c0 10 	cmp  %i3, %l0                                  <== NOT EXECUTED
40011374:	16 bf ff e9 	bge  40011318 <rtems_rfs_format+0xa58>         <== NOT EXECUTED
40011378:	a4 04 c0 1b 	add  %l3, %i3, %l2                             <== NOT EXECUTED
    {                                                                 
      rc = rtems_rfs_buffer_handle_request (fs, &handle,              
4001137c:	90 10 00 17 	mov  %l7, %o0                                  <== NOT EXECUTED
40011380:	92 07 bf 48 	add  %fp, -184, %o1                            <== NOT EXECUTED
40011384:	94 10 00 12 	mov  %l2, %o2                                  <== NOT EXECUTED
40011388:	40 00 27 b5 	call  4001b25c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
4001138c:	96 10 20 00 	clr  %o3                                       <== NOT EXECUTED
                                            group_base + b + RTEMS_RFS_GROUP_INODE_BLOCK,
                                            false);                   
      if (rc > 0)                                                     
40011390:	a2 92 20 00 	orcc  %o0, 0, %l1                              <== NOT EXECUTED
40011394:	04 bf ff f0 	ble  40011354 <rtems_rfs_format+0xa94>         <== NOT EXECUTED
40011398:	c4 07 bf 50 	ld  [ %fp + -176 ], %g2                        <== NOT EXECUTED
      {                                                               
        rtems_rfs_buffer_handle_close (fs, &handle);                  
4001139c:	92 07 bf 48 	add  %fp, -184, %o1                            <== NOT EXECUTED
400113a0:	7f ff fd 3e 	call  40010898 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
400113a4:	90 10 00 17 	mov  %l7, %o0                                  <== NOT EXECUTED
        printf ("\nrtems-rfs: write-group: group %3d: block %" PRId32 " request failed: %d: %s\n",
400113a8:	40 00 47 f9 	call  4002338c <strerror>                      <== NOT EXECUTED
400113ac:	90 10 00 11 	mov  %l1, %o0                                  <== NOT EXECUTED
400113b0:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
400113b4:	98 10 00 08 	mov  %o0, %o4                                  <== NOT EXECUTED
400113b8:	94 10 00 12 	mov  %l2, %o2                                  <== NOT EXECUTED
400113bc:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
400113c0:	96 10 00 11 	mov  %l1, %o3                                  <== NOT EXECUTED
400113c4:	40 00 43 b1 	call  40022288 <printf>                        <== NOT EXECUTED
400113c8:	90 12 20 28 	or  %o0, 0x28, %o0                             <== NOT EXECUTED
  rc = rtems_rfs_buffer_handle_close (fs, &handle);                   
  if (rc > 0)                                                         
  {                                                                   
    printf ("\nrtems-rfs: write-group: buffer handle close failed: %d: %s\n",
            rc, strerror (rc));                                       
    return false;                                                     
400113cc:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
    printf ("rtems-rfs: format: superblock write failed\n");          
    return -1;                                                        
  }                                                                   
                                                                      
  for (group = 0; group < fs.group_count; group++)                    
    if (!rtems_rfs_write_group (&fs, group,                           
400113d0:	80 88 60 ff 	btst  0xff, %g1                                
400113d4:	22 bf fe a7 	be,a   40010e70 <rtems_rfs_format+0x5b0>       <== NEVER TAKEN
400113d8:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
  {                                                                   
    printf ("rtems-rfs: format: superblock write failed\n");          
    return -1;                                                        
  }                                                                   
                                                                      
  for (group = 0; group < fs.group_count; group++)                    
400113dc:	10 bf fe 8f 	b  40010e18 <rtems_rfs_format+0x558>           
400113e0:	b8 07 20 01 	inc  %i4                                       
  int                    rc;                                          
                                                                      
  /*                                                                  
   * External API so returns -1.                                      
   */                                                                 
  rc = rtems_rfs_fs_open (name, NULL,                                 
400113e4:	92 10 20 00 	clr  %o1                                       
400113e8:	94 10 20 06 	mov  6, %o2                                    
400113ec:	96 10 20 00 	clr  %o3                                       
400113f0:	40 00 31 a1 	call  4001da74 <rtems_rfs_fs_open>             
400113f4:	98 07 bf 44 	add  %fp, -188, %o4                            
                          RTEMS_RFS_FS_FORCE_OPEN | RTEMS_RFS_FS_NO_LOCAL_CACHE,
                          0, &fs);                                    
  if (rc < 0)                                                         
400113f8:	80 a2 20 00 	cmp  %o0, 0                                    
400113fc:	36 80 00 0e 	bge,a   40011434 <rtems_rfs_format+0xb74>      <== ALWAYS TAKEN
40011400:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        
  {                                                                   
    printf ("rtems-rfs: format: file system open failed: %d: %s\n",   
            errno, strerror (errno));                                 
40011404:	40 00 3e a6 	call  40020e9c <__errno>                       <== NOT EXECUTED
40011408:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
4001140c:	40 00 3e a4 	call  40020e9c <__errno>                       <== NOT EXECUTED
40011410:	fa 02 00 00 	ld  [ %o0 ], %i5                               <== 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",   
40011414:	40 00 47 de 	call  4002338c <strerror>                      <== NOT EXECUTED
40011418:	d0 02 00 00 	ld  [ %o0 ], %o0                               <== NOT EXECUTED
4001141c:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
40011420:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011424:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011428:	40 00 43 98 	call  40022288 <printf>                        <== NOT EXECUTED
4001142c:	90 12 20 e0 	or  %o0, 0xe0, %o0	! 400338e0 <_Semaphore_Translate_core_mutex_return_code_+0x750><== NOT EXECUTED
40011430:	30 80 00 73 	b,a   400115fc <rtems_rfs_format+0xd3c>        <== NOT EXECUTED
            errno, strerror (errno));                                 
    return -1;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_alloc (fs, RTEMS_RFS_ROOT_INO, &ino);          
40011434:	92 10 20 01 	mov  1, %o1                                    
40011438:	40 00 01 ed 	call  40011bec <rtems_rfs_inode_alloc>         
4001143c:	94 07 bf 48 	add  %fp, -184, %o2                            
  if (rc > 0)                                                         
40011440:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40011444:	04 80 00 0a 	ble  4001146c <rtems_rfs_format+0xbac>         <== ALWAYS TAKEN
40011448:	d2 07 bf 48 	ld  [ %fp + -184 ], %o1                        
  {                                                                   
    printf ("rtems-rfs: format: inode allocation failed: %d: %s\n",   
4001144c:	40 00 47 d0 	call  4002338c <strerror>                      <== NOT EXECUTED
40011450:	01 00 00 00 	nop                                            <== NOT EXECUTED
40011454:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
40011458:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001145c:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011460:	40 00 43 8a 	call  40022288 <printf>                        <== NOT EXECUTED
40011464:	90 12 21 18 	or  %o0, 0x118, %o0	! 40033918 <_Semaphore_Translate_core_mutex_return_code_+0x788><== NOT EXECUTED
40011468:	30 80 00 06 	b,a   40011480 <rtems_rfs_format+0xbc0>        <== NOT EXECUTED
            rc, strerror (rc));                                       
    rtems_rfs_fs_close (fs);                                          
    return rc;                                                        
  }                                                                   
                                                                      
  if (ino != RTEMS_RFS_ROOT_INO)                                      
4001146c:	80 a2 60 01 	cmp  %o1, 1                                    
40011470:	02 80 00 08 	be  40011490 <rtems_rfs_format+0xbd0>          <== ALWAYS TAKEN
40011474:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    
  {                                                                   
    printf ("rtems-rfs: format: allocated inode not root ino: %" PRId32 "\n", ino);
40011478:	40 00 43 84 	call  40022288 <printf>                        <== NOT EXECUTED
4001147c:	90 12 21 50 	or  %o0, 0x150, %o0	! 40033950 <_Semaphore_Translate_core_mutex_return_code_+0x7c0><== NOT EXECUTED
    rtems_rfs_fs_close (fs);                                          
40011480:	40 00 33 7e 	call  4001e278 <rtems_rfs_fs_close>            <== NOT EXECUTED
40011484:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        <== NOT EXECUTED
            rc, strerror (rc));                                       
    return -1;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_write_root_dir (name);                               
  if (rc > 0)                                                         
40011488:	10 80 00 55 	b  400115dc <rtems_rfs_format+0xd1c>           <== NOT EXECUTED
4001148c:	80 a7 60 00 	cmp  %i5, 0                                    <== 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);                  
40011490:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        
40011494:	92 10 20 01 	mov  1, %o1                                    
40011498:	94 07 bf 54 	add  %fp, -172, %o2                            
4001149c:	40 00 02 10 	call  40011cdc <rtems_rfs_inode_open>          
400114a0:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
400114a4:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400114a8:	24 80 00 0e 	ble,a   400114e0 <rtems_rfs_format+0xc20>      <== ALWAYS TAKEN
400114ac:	90 07 bf 54 	add  %fp, -172, %o0                            
  {                                                                   
    printf ("rtems-rfs: format: inode open failed: %d: %s\n",         
400114b0:	40 00 47 b7 	call  4002338c <strerror>                      <== NOT EXECUTED
400114b4:	01 00 00 00 	nop                                            <== NOT EXECUTED
400114b8:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
400114bc:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
400114c0:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
400114c4:	40 00 43 71 	call  40022288 <printf>                        <== NOT EXECUTED
400114c8:	90 12 21 88 	or  %o0, 0x188, %o0	! 40033988 <_Semaphore_Translate_core_mutex_return_code_+0x7f8><== NOT EXECUTED
            rc, strerror (rc));                                       
    rtems_rfs_group_bitmap_free (fs, true, ino);                      
400114cc:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        <== NOT EXECUTED
400114d0:	d4 07 bf 48 	ld  [ %fp + -184 ], %o2                        <== NOT EXECUTED
400114d4:	40 00 01 71 	call  40011a98 <rtems_rfs_group_bitmap_free>   <== NOT EXECUTED
400114d8:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
400114dc:	30 bf ff e9 	b,a   40011480 <rtems_rfs_format+0xbc0>        <== NOT EXECUTED
    rtems_rfs_fs_close (fs);                                          
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_initialise (&inode, 0,                         
400114e0:	92 10 20 00 	clr  %o1                                       
400114e4:	15 00 00 10 	sethi  %hi(0x4000), %o2                        
400114e8:	96 10 20 00 	clr  %o3                                       
400114ec:	94 12 a1 c9 	or  %o2, 0x1c9, %o2                            
400114f0:	40 00 02 f1 	call  400120b4 <rtems_rfs_inode_initialise>    
400114f4:	98 10 20 00 	clr  %o4                                       
                                   (RTEMS_RFS_S_IFDIR | RTEMS_RFS_S_IRWXU |
                                    RTEMS_RFS_S_IXGRP | RTEMS_RFS_S_IXOTH),
                                   0, 0);                             
  if (rc > 0)                                                         
400114f8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400114fc:	24 80 00 0a 	ble,a   40011524 <rtems_rfs_format+0xc64>      <== ALWAYS TAKEN
40011500:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        
    printf ("rtems-rfs: format: inode initialise failed: %d: %s\n",   
40011504:	40 00 47 a2 	call  4002338c <strerror>                      <== NOT EXECUTED
40011508:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001150c:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
40011510:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011514:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011518:	40 00 43 5c 	call  40022288 <printf>                        <== NOT EXECUTED
4001151c:	90 12 21 b8 	or  %o0, 0x1b8, %o0	! 400339b8 <_Semaphore_Translate_core_mutex_return_code_+0x828><== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
  rc = rtems_rfs_dir_add_entry (fs, &inode, ".", 1, ino);             
40011520:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        <== NOT EXECUTED
40011524:	d8 07 bf 48 	ld  [ %fp + -184 ], %o4                        
40011528:	92 07 bf 54 	add  %fp, -172, %o1                            
4001152c:	15 10 00 c7 	sethi  %hi(0x40031c00), %o2                    
40011530:	96 10 20 01 	mov  1, %o3                                    
40011534:	40 00 2a 45 	call  4001be48 <rtems_rfs_dir_add_entry>       
40011538:	94 12 a0 10 	or  %o2, 0x10, %o2                             
  if (rc > 0)                                                         
4001153c:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40011540:	24 80 00 0a 	ble,a   40011568 <rtems_rfs_format+0xca8>      <== ALWAYS TAKEN
40011544:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        
    printf ("rtems-rfs: format: directory add failed: %d: %s\n",      
40011548:	40 00 47 91 	call  4002338c <strerror>                      <== NOT EXECUTED
4001154c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40011550:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
40011554:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011558:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
4001155c:	40 00 43 4b 	call  40022288 <printf>                        <== NOT EXECUTED
40011560:	90 12 21 f0 	or  %o0, 0x1f0, %o0	! 400339f0 <_Semaphore_Translate_core_mutex_return_code_+0x860><== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
40011564:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        <== NOT EXECUTED
40011568:	40 00 02 4f 	call  40011ea4 <rtems_rfs_inode_close>         
4001156c:	92 07 bf 54 	add  %fp, -172, %o1                            
  if (rc > 0)                                                         
40011570:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40011574:	04 80 00 09 	ble  40011598 <rtems_rfs_format+0xcd8>         <== ALWAYS TAKEN
40011578:	01 00 00 00 	nop                                            
    printf ("rtems-rfs: format: inode close failed: %d: %s\n",        
4001157c:	40 00 47 84 	call  4002338c <strerror>                      <== NOT EXECUTED
40011580:	01 00 00 00 	nop                                            <== NOT EXECUTED
40011584:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
40011588:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001158c:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011590:	40 00 43 3e 	call  40022288 <printf>                        <== NOT EXECUTED
40011594:	90 12 22 28 	or  %o0, 0x228, %o0	! 40033a28 <_Semaphore_Translate_core_mutex_return_code_+0x898><== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
  rc = rtems_rfs_fs_close (fs);                                       
40011598:	40 00 33 38 	call  4001e278 <rtems_rfs_fs_close>            
4001159c:	d0 07 bf 44 	ld  [ %fp + -188 ], %o0                        
  if (rc < 0)                                                         
400115a0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400115a4:	16 80 00 0e 	bge  400115dc <rtems_rfs_format+0xd1c>         <== ALWAYS TAKEN
400115a8:	80 a7 60 00 	cmp  %i5, 0                                    
    printf ("rtems-rfs: format: file system close failed: %d: %s\n",  
            errno, strerror (errno));                                 
400115ac:	40 00 3e 3c 	call  40020e9c <__errno>                       <== NOT EXECUTED
400115b0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400115b4:	40 00 3e 3a 	call  40020e9c <__errno>                       <== NOT EXECUTED
400115b8:	f8 02 00 00 	ld  [ %o0 ], %i4                               <== 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",  
400115bc:	40 00 47 74 	call  4002338c <strerror>                      <== NOT EXECUTED
400115c0:	d0 02 00 00 	ld  [ %o0 ], %o0                               <== NOT EXECUTED
400115c4:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
400115c8:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
400115cc:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
400115d0:	40 00 43 2e 	call  40022288 <printf>                        <== NOT EXECUTED
400115d4:	90 12 22 58 	or  %o0, 0x258, %o0	! 40033a58 <_Semaphore_Translate_core_mutex_return_code_+0x8c8><== NOT EXECUTED
            rc, strerror (rc));                                       
    return -1;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_write_root_dir (name);                               
  if (rc > 0)                                                         
400115d8:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
400115dc:	24 bf fe 25 	ble,a   40010e70 <rtems_rfs_format+0x5b0>      <== ALWAYS TAKEN
400115e0:	b0 10 20 00 	clr  %i0                                       
  {                                                                   
    printf ("rtems-rfs: format: writing root dir failed: %d: %s\n",   
400115e4:	40 00 47 6a 	call  4002338c <strerror>                      <== NOT EXECUTED
400115e8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
400115ec:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
400115f0:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
400115f4:	10 bf fe 1c 	b  40010e64 <rtems_rfs_format+0x5a4>           <== NOT EXECUTED
400115f8:	90 12 22 90 	or  %o0, 0x290, %o0	! 40033a90 <_Semaphore_Translate_core_mutex_return_code_+0x900><== NOT EXECUTED
400115fc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011600:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001e278 <rtems_rfs_fs_close>: int rtems_rfs_fs_close (rtems_rfs_file_system* fs) {
4001e278:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int group;                                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_CLOSE))                        
4001e27c:	90 10 20 00 	clr  %o0                                       
4001e280:	7f ff d4 f3 	call  4001364c <rtems_rfs_trace>               
4001e284:	92 10 20 02 	mov  2, %o1                                    
4001e288:	80 a2 20 00 	cmp  %o0, 0                                    
4001e28c:	02 80 00 06 	be  4001e2a4 <rtems_rfs_fs_close+0x2c>         <== ALWAYS TAKEN
4001e290:	b8 10 20 00 	clr  %i4                                       
    printf ("rtems-rfs: close\n");                                    
4001e294:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e298:	40 00 10 8b 	call  400224c4 <puts>                          <== NOT EXECUTED
4001e29c:	90 12 23 40 	or  %o0, 0x340, %o0	! 40035b40 <CSWTCH.1+0x13f0><== NOT EXECUTED
  return 0;                                                           
}                                                                     
                                                                      
int                                                                   
rtems_rfs_fs_close (rtems_rfs_file_system* fs)                        
{                                                                     
4001e2a0:	b8 10 20 00 	clr  %i4                                       <== NOT EXECUTED
4001e2a4:	ba 10 20 00 	clr  %i5                                       
  int group;                                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_CLOSE))                        
    printf ("rtems-rfs: close\n");                                    
                                                                      
  for (group = 0; group < fs->group_count; group++)                   
4001e2a8:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
4001e2ac:	80 a7 40 01 	cmp  %i5, %g1                                  
4001e2b0:	16 80 00 08 	bge  4001e2d0 <rtems_rfs_fs_close+0x58>        
4001e2b4:	90 10 00 18 	mov  %i0, %o0                                  
    rtems_rfs_group_close (fs, &fs->groups[group]);                   
4001e2b8:	d2 06 20 20 	ld  [ %i0 + 0x20 ], %o1                        
4001e2bc:	92 02 40 1c 	add  %o1, %i4, %o1                             
4001e2c0:	7f ff cd 50 	call  40011800 <rtems_rfs_group_close>         
4001e2c4:	ba 07 60 01 	inc  %i5                                       
4001e2c8:	10 bf ff f8 	b  4001e2a8 <rtems_rfs_fs_close+0x30>          
4001e2cc:	b8 07 20 50 	add  %i4, 0x50, %i4                            
                                                                      
  rtems_rfs_buffer_close (fs);                                        
4001e2d0:	7f ff f5 66 	call  4001b868 <rtems_rfs_buffer_close>        
4001e2d4:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  free (fs);                                                          
4001e2d8:	90 10 00 18 	mov  %i0, %o0                                  
4001e2dc:	7f ff a7 14 	call  40007f2c <free>                          
4001e2e0:	b0 10 20 00 	clr  %i0                                       
  return 0;                                                           
}                                                                     
4001e2e4:	81 c7 e0 08 	ret                                            
4001e2e8:	81 e8 00 00 	restore                                        
                                                                      

4001da74 <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) {
4001da74:	9d e3 bf 78 	save  %sp, -136, %sp                           
#endif                                                                
  rtems_rfs_inode_handle inode;                                       
  uint16_t               mode;                                        
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                         
4001da78:	90 10 20 00 	clr  %o0                                       
4001da7c:	7f ff d6 f4 	call  4001364c <rtems_rfs_trace>               
4001da80:	92 10 20 01 	mov  1, %o1                                    
4001da84:	80 a2 20 00 	cmp  %o0, 0                                    
4001da88:	02 80 00 05 	be  4001da9c <rtems_rfs_fs_open+0x28>          <== ALWAYS TAKEN
4001da8c:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    
    printf ("rtems-rfs: open: %s\n", name);                           
4001da90:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001da94:	40 00 11 fd 	call  40022288 <printf>                        <== NOT EXECUTED
4001da98:	90 12 20 00 	mov  %o0, %o0                                  <== NOT EXECUTED
                                                                      
  *fs = malloc (sizeof (rtems_rfs_file_system));                      
4001da9c:	7f ff aa b2 	call  40008564 <malloc>                        
4001daa0:	90 10 20 84 	mov  0x84, %o0                                 
  if (!*fs)                                                           
4001daa4:	80 a2 20 00 	cmp  %o0, 0                                    
4001daa8:	12 80 00 0f 	bne  4001dae4 <rtems_rfs_fs_open+0x70>         <== ALWAYS TAKEN
4001daac:	d0 27 00 00 	st  %o0, [ %i4 ]                               
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001dab0:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001dab4:	7f ff d6 e6 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001dab8:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001dabc:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001dac0:	02 80 00 05 	be  4001dad4 <rtems_rfs_fs_open+0x60>          <== NOT EXECUTED
4001dac4:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: open: no memory for file system data\n");   
4001dac8:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001dacc:	40 00 12 7e 	call  400224c4 <puts>                          <== NOT EXECUTED
4001dad0:	90 12 20 18 	or  %o0, 0x18, %o0	! 40035818 <CSWTCH.1+0x10c8><== NOT EXECUTED
    errno = ENOMEM;                                                   
4001dad4:	40 00 0c f2 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001dad8:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001dadc:	10 80 01 cb 	b  4001e208 <rtems_rfs_fs_open+0x794>          <== NOT EXECUTED
4001dae0:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
    return -1;                                                        
  }                                                                   
                                                                      
  memset (*fs, 0, sizeof (rtems_rfs_file_system));                    
4001dae4:	92 10 20 00 	clr  %o1                                       
4001dae8:	40 00 11 6f 	call  400220a4 <memset>                        
4001daec:	94 10 20 84 	mov  0x84, %o2                                 
                                                                      
  (*fs)->user = user;                                                 
4001daf0:	c2 07 00 00 	ld  [ %i4 ], %g1                               
#endif                                                                
                                                                      
  /*                                                                  
   * Open the buffer interface.                                       
   */                                                                 
  rc = rtems_rfs_buffer_open (name, *fs);                             
4001daf4:	90 10 00 18 	mov  %i0, %o0                                  
    return -1;                                                        
  }                                                                   
                                                                      
  memset (*fs, 0, sizeof (rtems_rfs_file_system));                    
                                                                      
  (*fs)->user = user;                                                 
4001daf8:	f2 20 60 80 	st  %i1, [ %g1 + 0x80 ]                        
  rtems_chain_initialize_empty (&(*fs)->buffers);                     
4001dafc:	c2 07 00 00 	ld  [ %i4 ], %g1                               
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
4001db00:	c0 20 60 48 	clr  [ %g1 + 0x48 ]                            
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001db04:	84 00 60 44 	add  %g1, 0x44, %g2                            
4001db08:	86 00 60 48 	add  %g1, 0x48, %g3                            
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
  tail->previous = head;                                              
4001db0c:	c4 20 60 4c 	st  %g2, [ %g1 + 0x4c ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4001db10:	c6 20 60 44 	st  %g3, [ %g1 + 0x44 ]                        
  rtems_chain_initialize_empty (&(*fs)->release);                     
4001db14:	c2 07 00 00 	ld  [ %i4 ], %g1                               
  head->previous = NULL;                                              
4001db18:	c0 20 60 58 	clr  [ %g1 + 0x58 ]                            
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001db1c:	84 00 60 54 	add  %g1, 0x54, %g2                            
4001db20:	86 00 60 58 	add  %g1, 0x58, %g3                            
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
  tail->previous = head;                                              
4001db24:	c4 20 60 5c 	st  %g2, [ %g1 + 0x5c ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4001db28:	c6 20 60 54 	st  %g3, [ %g1 + 0x54 ]                        
  rtems_chain_initialize_empty (&(*fs)->release_modified);            
4001db2c:	c2 07 00 00 	ld  [ %i4 ], %g1                               
  head->previous = NULL;                                              
4001db30:	c0 20 60 68 	clr  [ %g1 + 0x68 ]                            
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001db34:	84 00 60 64 	add  %g1, 0x64, %g2                            
4001db38:	86 00 60 68 	add  %g1, 0x68, %g3                            
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
  tail->previous = head;                                              
4001db3c:	c4 20 60 6c 	st  %g2, [ %g1 + 0x6c ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4001db40:	c6 20 60 64 	st  %g3, [ %g1 + 0x64 ]                        
  rtems_chain_initialize_empty (&(*fs)->file_shares);                 
4001db44:	c2 07 00 00 	ld  [ %i4 ], %g1                               
  head->previous = NULL;                                              
4001db48:	c0 20 60 78 	clr  [ %g1 + 0x78 ]                            
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(                    
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
4001db4c:	84 00 60 74 	add  %g1, 0x74, %g2                            
4001db50:	86 00 60 78 	add  %g1, 0x78, %g3                            
                                                                      
  head->next = tail;                                                  
  head->previous = NULL;                                              
  tail->previous = head;                                              
4001db54:	c4 20 60 7c 	st  %g2, [ %g1 + 0x7c ]                        
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *tail = _Chain_Tail( the_chain );                        
                                                                      
  head->next = tail;                                                  
4001db58:	c6 20 60 74 	st  %g3, [ %g1 + 0x74 ]                        
                                                                      
  (*fs)->max_held_buffers = max_held_buffers;                         
4001db5c:	d2 07 00 00 	ld  [ %i4 ], %o1                               
4001db60:	f6 22 60 40 	st  %i3, [ %o1 + 0x40 ]                        
  (*fs)->buffers_count = 0;                                           
4001db64:	c0 22 60 50 	clr  [ %o1 + 0x50 ]                            
  (*fs)->release_count = 0;                                           
4001db68:	c0 22 60 60 	clr  [ %o1 + 0x60 ]                            
  (*fs)->release_modified_count = 0;                                  
4001db6c:	c0 22 60 70 	clr  [ %o1 + 0x70 ]                            
#endif                                                                
                                                                      
  /*                                                                  
   * Open the buffer interface.                                       
   */                                                                 
  rc = rtems_rfs_buffer_open (name, *fs);                             
4001db70:	7f ff f6 65 	call  4001b504 <rtems_rfs_buffer_open>         
4001db74:	f4 22 40 00 	st  %i2, [ %o1 ]                               
  if (rc > 0)                                                         
4001db78:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001db7c:	04 80 00 16 	ble  4001dbd4 <rtems_rfs_fs_open+0x160>        <== ALWAYS TAKEN
4001db80:	f6 07 00 00 	ld  [ %i4 ], %i3                               
  {                                                                   
    free (*fs);                                                       
4001db84:	7f ff a8 ea 	call  40007f2c <free>                          <== NOT EXECUTED
4001db88:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001db8c:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001db90:	7f ff d6 af 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001db94:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001db98:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001db9c:	02 80 00 09 	be  4001dbc0 <rtems_rfs_fs_open+0x14c>         <== NOT EXECUTED
4001dba0:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: open: buffer open failed: %d: %s\n",        
4001dba4:	40 00 15 fa 	call  4002338c <strerror>                      <== NOT EXECUTED
4001dba8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001dbac:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001dbb0:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001dbb4:	90 12 20 48 	or  %o0, 0x48, %o0	! 40035848 <CSWTCH.1+0x10f8><== NOT EXECUTED
4001dbb8:	40 00 11 b4 	call  40022288 <printf>                        <== NOT EXECUTED
4001dbbc:	92 10 00 1d 	mov  %i5, %o1                                  <== NOT EXECUTED
              rc, strerror (rc));                                     
    errno = rc;                                                       
4001dbc0:	40 00 0c b7 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001dbc4:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001dbc8:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
    return -1;                                                        
4001dbcc:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001dbd0:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001dbd4:	c0 2f bf d8 	clrb  [ %fp + -40 ]                            
  handle->bnum  = 0;                                                  
4001dbd8:	c0 27 bf dc 	clr  [ %fp + -36 ]                             
  handle->buffer = NULL;                                              
4001dbdc:	c0 27 bf e0 	clr  [ %fp + -32 ]                             
      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);        
4001dbe0:	90 10 00 1b 	mov  %i3, %o0                                  
4001dbe4:	92 07 bf d8 	add  %fp, -40, %o1                             
4001dbe8:	94 10 20 00 	clr  %o2                                       
4001dbec:	7f ff f5 9c 	call  4001b25c <rtems_rfs_buffer_handle_request>
4001dbf0:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
4001dbf4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001dbf8:	04 80 00 0d 	ble  4001dc2c <rtems_rfs_fs_open+0x1b8>        <== ALWAYS TAKEN
4001dbfc:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001dc00:	7f ff d6 93 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001dc04:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001dc08:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001dc0c:	22 80 01 2d 	be,a   4001e0c0 <rtems_rfs_fs_open+0x64c>      <== NOT EXECUTED
4001dc10:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: request failed%d: %s\n",   
4001dc14:	40 00 15 de 	call  4002338c <strerror>                      <== NOT EXECUTED
4001dc18:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001dc1c:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001dc20:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001dc24:	10 80 00 de 	b  4001df9c <rtems_rfs_fs_open+0x528>          <== NOT EXECUTED
4001dc28:	90 12 20 78 	or  %o0, 0x78, %o0	! 40035878 <CSWTCH.1+0x1128><== NOT EXECUTED
              rc, strerror (rc));                                     
    return rc;                                                        
  }                                                                   
                                                                      
  sb = rtems_rfs_buffer_data (&handle);                               
4001dc2c:	c2 07 bf e0 	ld  [ %fp + -32 ], %g1                         
4001dc30:	fa 00 60 1c 	ld  [ %g1 + 0x1c ], %i5                        
                                                                      
#define read_sb(_o) rtems_rfs_read_u32 (sb + (_o))                    
                                                                      
  if (read_sb (RTEMS_RFS_SB_OFFSET_MAGIC) != RTEMS_RFS_SB_MAGIC)      
4001dc34:	c2 0f 60 01 	ldub  [ %i5 + 1 ], %g1                         
4001dc38:	c4 0f 40 00 	ldub  [ %i5 ], %g2                             
4001dc3c:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001dc40:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001dc44:	84 10 80 01 	or  %g2, %g1, %g2                              
4001dc48:	c2 0f 60 03 	ldub  [ %i5 + 3 ], %g1                         
4001dc4c:	84 10 80 01 	or  %g2, %g1, %g2                              
4001dc50:	c2 0f 60 02 	ldub  [ %i5 + 2 ], %g1                         
4001dc54:	83 28 60 08 	sll  %g1, 8, %g1                               
4001dc58:	84 10 80 01 	or  %g2, %g1, %g2                              
4001dc5c:	03 0a 02 48 	sethi  %hi(0x28092000), %g1                    
4001dc60:	82 10 60 01 	or  %g1, 1, %g1	! 28092001 <RAM_SIZE+0x27c92001>
4001dc64:	80 a0 80 01 	cmp  %g2, %g1                                  
4001dc68:	22 80 00 0b 	be,a   4001dc94 <rtems_rfs_fs_open+0x220>      <== ALWAYS TAKEN
4001dc6c:	c2 0f 60 0d 	ldub  [ %i5 + 0xd ], %g1                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001dc70:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001dc74:	7f ff d6 76 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001dc78:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001dc7c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001dc80:	22 80 00 57 	be,a   4001dddc <rtems_rfs_fs_open+0x368>      <== NOT EXECUTED
4001dc84:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: invalid superblock, bad magic\n");
4001dc88:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001dc8c:	10 80 00 2f 	b  4001dd48 <rtems_rfs_fs_open+0x2d4>          <== NOT EXECUTED
4001dc90:	90 12 20 b0 	or  %o0, 0xb0, %o0	! 400358b0 <CSWTCH.1+0x1160><== NOT EXECUTED
    rtems_rfs_buffer_handle_close (fs, &handle);                      
    return EIO;                                                       
  }                                                                   
                                                                      
  fs->blocks     = read_sb (RTEMS_RFS_SB_OFFSET_BLOCKS);              
4001dc94:	d6 0f 60 0c 	ldub  [ %i5 + 0xc ], %o3                       
4001dc98:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001dc9c:	97 2a e0 18 	sll  %o3, 0x18, %o3                            
4001dca0:	96 12 c0 01 	or  %o3, %g1, %o3                              
4001dca4:	c2 0f 60 0f 	ldub  [ %i5 + 0xf ], %g1                       
uint64_t                                                              
rtems_rfs_fs_size (rtems_rfs_file_system* fs)                         
{                                                                     
  uint64_t blocks = rtems_rfs_fs_blocks (fs);                         
  uint64_t block_size = rtems_rfs_fs_block_size (fs);                 
  return blocks * block_size;                                         
4001dca8:	94 10 20 00 	clr  %o2                                       
      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);              
4001dcac:	96 12 c0 01 	or  %o3, %g1, %o3                              
4001dcb0:	c2 0f 60 0e 	ldub  [ %i5 + 0xe ], %g1                       
uint64_t                                                              
rtems_rfs_fs_size (rtems_rfs_file_system* fs)                         
{                                                                     
  uint64_t blocks = rtems_rfs_fs_blocks (fs);                         
  uint64_t block_size = rtems_rfs_fs_block_size (fs);                 
  return blocks * block_size;                                         
4001dcb4:	90 10 20 00 	clr  %o0                                       
      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);              
4001dcb8:	83 28 60 08 	sll  %g1, 8, %g1                               
4001dcbc:	96 12 c0 01 	or  %o3, %g1, %o3                              
4001dcc0:	d6 26 e0 04 	st  %o3, [ %i3 + 4 ]                           
  fs->block_size = read_sb (RTEMS_RFS_SB_OFFSET_BLOCK_SIZE);          
4001dcc4:	c2 0f 60 09 	ldub  [ %i5 + 9 ], %g1                         
4001dcc8:	f4 0f 60 08 	ldub  [ %i5 + 8 ], %i2                         
4001dccc:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001dcd0:	b5 2e a0 18 	sll  %i2, 0x18, %i2                            
4001dcd4:	b4 16 80 01 	or  %i2, %g1, %i2                              
4001dcd8:	c2 0f 60 0b 	ldub  [ %i5 + 0xb ], %g1                       
4001dcdc:	b4 16 80 01 	or  %i2, %g1, %i2                              
4001dce0:	c2 0f 60 0a 	ldub  [ %i5 + 0xa ], %g1                       
4001dce4:	83 28 60 08 	sll  %g1, 8, %g1                               
4001dce8:	b4 16 80 01 	or  %i2, %g1, %i2                              
4001dcec:	f4 26 e0 08 	st  %i2, [ %i3 + 8 ]                           
uint64_t                                                              
rtems_rfs_fs_size (rtems_rfs_file_system* fs)                         
{                                                                     
  uint64_t blocks = rtems_rfs_fs_blocks (fs);                         
  uint64_t block_size = rtems_rfs_fs_block_size (fs);                 
  return blocks * block_size;                                         
4001dcf0:	40 00 43 ef 	call  4002ecac <__muldi3>                      
4001dcf4:	92 10 00 1a 	mov  %i2, %o1                                  
4001dcf8:	b2 10 00 08 	mov  %o0, %i1                                  
4001dcfc:	b0 10 00 09 	mov  %o1, %i0                                  
  }                                                                   
                                                                      
  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))           
4001dd00:	7f ff ff 53 	call  4001da4c <rtems_rfs_fs_media_size>       
4001dd04:	90 10 00 1b 	mov  %i3, %o0                                  
4001dd08:	80 a6 40 08 	cmp  %i1, %o0                                  
4001dd0c:	38 80 00 08 	bgu,a   4001dd2c <rtems_rfs_fs_open+0x2b8>     <== NEVER TAKEN
4001dd10:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001dd14:	32 80 00 11 	bne,a   4001dd58 <rtems_rfs_fs_open+0x2e4>     <== NEVER TAKEN
4001dd18:	c4 0f 60 24 	ldub  [ %i5 + 0x24 ], %g2                      <== NOT EXECUTED
4001dd1c:	80 a6 00 09 	cmp  %i0, %o1                                  
4001dd20:	28 80 00 0e 	bleu,a   4001dd58 <rtems_rfs_fs_open+0x2e4>    <== ALWAYS TAKEN
4001dd24:	c4 0f 60 24 	ldub  [ %i5 + 0x24 ], %g2                      
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001dd28:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001dd2c:	7f ff d6 48 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001dd30:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001dd34:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001dd38:	22 80 00 29 	be,a   4001dddc <rtems_rfs_fs_open+0x368>      <== NOT EXECUTED
4001dd3c:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: invalid superblock block/size count\n");
4001dd40:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001dd44:	90 12 20 f0 	or  %o0, 0xf0, %o0	! 400358f0 <CSWTCH.1+0x11a0><== NOT EXECUTED
4001dd48:	40 00 11 df 	call  400224c4 <puts>                          <== NOT EXECUTED
4001dd4c:	01 00 00 00 	nop                                            <== NOT EXECUTED
  if (read_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE) != RTEMS_RFS_INODE_SIZE)
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
      printf ("rtems-rfs: read-superblock: inode size mismatch: fs:%" PRId32 " target:%" PRId32 "\n",
              read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
    rtems_rfs_buffer_handle_close (fs, &handle);                      
4001dd50:	10 80 00 23 	b  4001dddc <rtems_rfs_fs_open+0x368>          <== NOT EXECUTED
4001dd54:	90 10 00 1b 	mov  %i3, %o0                                  <== 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)
4001dd58:	c2 0f 60 25 	ldub  [ %i5 + 0x25 ], %g1                      
4001dd5c:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001dd60:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001dd64:	82 10 80 01 	or  %g2, %g1, %g1                              
4001dd68:	c4 0f 60 27 	ldub  [ %i5 + 0x27 ], %g2                      
4001dd6c:	82 10 40 02 	or  %g1, %g2, %g1                              
4001dd70:	c4 0f 60 26 	ldub  [ %i5 + 0x26 ], %g2                      
4001dd74:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001dd78:	82 10 40 02 	or  %g1, %g2, %g1                              
4001dd7c:	80 a0 60 38 	cmp  %g1, 0x38                                 
4001dd80:	22 80 00 1b 	be,a   4001ddec <rtems_rfs_fs_open+0x378>      <== ALWAYS TAKEN
4001dd84:	c4 0f 60 10 	ldub  [ %i5 + 0x10 ], %g2                      
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001dd88:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001dd8c:	7f ff d6 30 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001dd90:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001dd94:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001dd98:	22 80 00 11 	be,a   4001dddc <rtems_rfs_fs_open+0x368>      <== NOT EXECUTED
4001dd9c:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: inode size mismatch: fs:%" PRId32 " target:%" PRId32 "\n",
              read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
4001dda0:	c2 0f 60 05 	ldub  [ %i5 + 5 ], %g1                         <== NOT EXECUTED
4001dda4:	d2 0f 60 04 	ldub  [ %i5 + 4 ], %o1                         <== NOT EXECUTED
4001dda8:	83 28 60 10 	sll  %g1, 0x10, %g1                            <== NOT EXECUTED
4001ddac:	93 2a 60 18 	sll  %o1, 0x18, %o1                            <== NOT EXECUTED
4001ddb0:	92 12 40 01 	or  %o1, %g1, %o1                              <== NOT EXECUTED
4001ddb4:	c2 0f 60 07 	ldub  [ %i5 + 7 ], %g1                         <== NOT EXECUTED
  }                                                                   
                                                                      
  if (read_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE) != RTEMS_RFS_INODE_SIZE)
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
      printf ("rtems-rfs: read-superblock: inode size mismatch: fs:%" PRId32 " target:%" PRId32 "\n",
4001ddb8:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
              read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
4001ddbc:	92 12 40 01 	or  %o1, %g1, %o1                              <== NOT EXECUTED
4001ddc0:	c2 0f 60 06 	ldub  [ %i5 + 6 ], %g1                         <== NOT EXECUTED
  }                                                                   
                                                                      
  if (read_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE) != RTEMS_RFS_INODE_SIZE)
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
      printf ("rtems-rfs: read-superblock: inode size mismatch: fs:%" PRId32 " target:%" PRId32 "\n",
4001ddc4:	90 12 21 30 	or  %o0, 0x130, %o0                            <== NOT EXECUTED
              read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
4001ddc8:	83 28 60 08 	sll  %g1, 8, %g1                               <== NOT EXECUTED
  }                                                                   
                                                                      
  if (read_sb (RTEMS_RFS_SB_OFFSET_INODE_SIZE) != RTEMS_RFS_INODE_SIZE)
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
      printf ("rtems-rfs: read-superblock: inode size mismatch: fs:%" PRId32 " target:%" PRId32 "\n",
4001ddcc:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4001ddd0:	40 00 11 2e 	call  40022288 <printf>                        <== NOT EXECUTED
4001ddd4:	92 12 40 01 	or  %o1, %g1, %o1                              <== NOT EXECUTED
              read_sb (RTEMS_RFS_SB_OFFSET_VERSION), RTEMS_RFS_VERSION_MASK);
    rtems_rfs_buffer_handle_close (fs, &handle);                      
4001ddd8:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
4001dddc:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
4001dde0:	7f ff ff 08 	call  4001da00 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001dde4:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
4001dde8:	30 80 00 b8 	b,a   4001e0c8 <rtems_rfs_fs_open+0x654>       <== NOT EXECUTED
    return EIO;                                                       
  }                                                                   
                                                                      
  fs->bad_blocks      = read_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS);     
4001ddec:	c2 0f 60 11 	ldub  [ %i5 + 0x11 ], %g1                      
4001ddf0:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001ddf4:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001ddf8:	82 10 80 01 	or  %g2, %g1, %g1                              
4001ddfc:	c4 0f 60 13 	ldub  [ %i5 + 0x13 ], %g2                      
  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 =                                              
    rtems_rfs_fs_block_size (fs) / sizeof (rtems_rfs_inode_block);    
4001de00:	91 36 a0 02 	srl  %i2, 2, %o0                               
              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);     
4001de04:	82 10 40 02 	or  %g1, %g2, %g1                              
4001de08:	c4 0f 60 12 	ldub  [ %i5 + 0x12 ], %g2                      
    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 =                                       
    fs->blocks_per_block * fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
4001de0c:	92 10 00 08 	mov  %o0, %o1                                  
              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);     
4001de10:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001de14:	82 10 40 02 	or  %g1, %g2, %g1                              
4001de18:	c2 26 e0 18 	st  %g1, [ %i3 + 0x18 ]                        
  fs->max_name_length = read_sb (RTEMS_RFS_SB_OFFSET_MAX_NAME_LENGTH);
4001de1c:	c4 0f 60 14 	ldub  [ %i5 + 0x14 ], %g2                      
4001de20:	c2 0f 60 15 	ldub  [ %i5 + 0x15 ], %g1                      
4001de24:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001de28:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001de2c:	82 10 80 01 	or  %g2, %g1, %g1                              
4001de30:	c4 0f 60 17 	ldub  [ %i5 + 0x17 ], %g2                      
4001de34:	82 10 40 02 	or  %g1, %g2, %g1                              
4001de38:	c4 0f 60 16 	ldub  [ %i5 + 0x16 ], %g2                      
4001de3c:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001de40:	82 10 40 02 	or  %g1, %g2, %g1                              
4001de44:	c2 26 e0 1c 	st  %g1, [ %i3 + 0x1c ]                        
  fs->group_count     = read_sb (RTEMS_RFS_SB_OFFSET_GROUPS);         
4001de48:	c2 0f 60 19 	ldub  [ %i5 + 0x19 ], %g1                      
4001de4c:	f0 0f 60 18 	ldub  [ %i5 + 0x18 ], %i0                      
4001de50:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001de54:	b1 2e 20 18 	sll  %i0, 0x18, %i0                            
4001de58:	b0 16 00 01 	or  %i0, %g1, %i0                              
4001de5c:	c2 0f 60 1b 	ldub  [ %i5 + 0x1b ], %g1                      
4001de60:	b0 16 00 01 	or  %i0, %g1, %i0                              
4001de64:	c2 0f 60 1a 	ldub  [ %i5 + 0x1a ], %g1                      
4001de68:	83 28 60 08 	sll  %g1, 8, %g1                               
4001de6c:	b0 16 00 01 	or  %i0, %g1, %i0                              
4001de70:	f0 26 e0 24 	st  %i0, [ %i3 + 0x24 ]                        
  fs->group_blocks    = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_BLOCKS);   
4001de74:	c2 0f 60 1d 	ldub  [ %i5 + 0x1d ], %g1                      
4001de78:	f2 0f 60 1c 	ldub  [ %i5 + 0x1c ], %i1                      
4001de7c:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001de80:	b3 2e 60 18 	sll  %i1, 0x18, %i1                            
4001de84:	b2 16 40 01 	or  %i1, %g1, %i1                              
4001de88:	c2 0f 60 1f 	ldub  [ %i5 + 0x1f ], %g1                      
4001de8c:	b2 16 40 01 	or  %i1, %g1, %i1                              
4001de90:	c2 0f 60 1e 	ldub  [ %i5 + 0x1e ], %g1                      
4001de94:	83 28 60 08 	sll  %g1, 8, %g1                               
4001de98:	b2 16 40 01 	or  %i1, %g1, %i1                              
4001de9c:	f2 26 e0 28 	st  %i1, [ %i3 + 0x28 ]                        
  fs->group_inodes    = read_sb (RTEMS_RFS_SB_OFFSET_GROUP_INODES);   
4001dea0:	c2 0f 60 21 	ldub  [ %i5 + 0x21 ], %g1                      
4001dea4:	c4 0f 60 20 	ldub  [ %i5 + 0x20 ], %g2                      
4001dea8:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001deac:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001deb0:	84 10 80 01 	or  %g2, %g1, %g2                              
4001deb4:	c2 0f 60 23 	ldub  [ %i5 + 0x23 ], %g1                      
4001deb8:	84 10 80 01 	or  %g2, %g1, %g2                              
4001debc:	c2 0f 60 22 	ldub  [ %i5 + 0x22 ], %g1                      
                                                                      
  fs->blocks_per_block =                                              
4001dec0:	d0 26 e0 34 	st  %o0, [ %i3 + 0x34 ]                        
                                                                      
  fs->bad_blocks      = read_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS);     
  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);   
4001dec4:	83 28 60 08 	sll  %g1, 8, %g1                               
4001dec8:	ba 10 80 01 	or  %g2, %g1, %i5                              
                                                                      
  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;                    
4001decc:	85 2a 20 02 	sll  %o0, 2, %g2                               
4001ded0:	84 00 80 08 	add  %g2, %o0, %g2                             
                                                                      
  fs->bad_blocks      = read_sb (RTEMS_RFS_SB_OFFSET_BAD_BLOCKS);     
  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);   
4001ded4:	fa 26 e0 2c 	st  %i5, [ %i3 + 0x2c ]                        
    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 =                                       
    fs->blocks_per_block * fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
4001ded8:	7f ff 91 a5 	call  4000256c <.umul>                         
4001dedc:	c4 26 e0 38 	st  %g2, [ %i3 + 0x38 ]                        
4001dee0:	83 2a 20 02 	sll  %o0, 2, %g1                               
4001dee4:	90 00 40 08 	add  %g1, %o0, %o0                             
                                                                      
  fs->inodes = fs->group_count * fs->group_inodes;                    
4001dee8:	92 10 00 18 	mov  %i0, %o1                                  
  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 =                                       
4001deec:	d0 26 e0 3c 	st  %o0, [ %i3 + 0x3c ]                        
    fs->blocks_per_block * fs->blocks_per_block * RTEMS_RFS_INODE_BLOCKS;
                                                                      
  fs->inodes = fs->group_count * fs->group_inodes;                    
4001def0:	7f ff 91 9f 	call  4000256c <.umul>                         
4001def4:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;       
4001def8:	92 10 20 38 	mov  0x38, %o1                                 
  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;                    
4001defc:	d0 26 e0 14 	st  %o0, [ %i3 + 0x14 ]                        
                                                                      
  fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;       
4001df00:	7f ff 91 d5 	call  40002654 <.udiv>                         
4001df04:	90 10 00 1a 	mov  %i2, %o0                                  
4001df08:	d0 26 e0 30 	st  %o0, [ %i3 + 0x30 ]                        
                                                                      
  if (fs->group_blocks >                                              
      rtems_rfs_bitmap_numof_bits (rtems_rfs_fs_block_size (fs)))     
4001df0c:	b5 2e a0 03 	sll  %i2, 3, %i2                               
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
4001df10:	90 10 00 1b 	mov  %i3, %o0                                  
                                                                      
  fs->inodes = fs->group_count * fs->group_inodes;                    
                                                                      
  fs->inodes_per_block = fs->block_size / RTEMS_RFS_INODE_SIZE;       
                                                                      
  if (fs->group_blocks >                                              
4001df14:	80 a6 40 1a 	cmp  %i1, %i2                                  
4001df18:	08 80 00 0c 	bleu  4001df48 <rtems_rfs_fs_open+0x4d4>       <== ALWAYS TAKEN
4001df1c:	92 07 bf d8 	add  %fp, -40, %o1                             
      rtems_rfs_bitmap_numof_bits (rtems_rfs_fs_block_size (fs)))     
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
4001df20:	7f ff fe b8 	call  4001da00 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001df24:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001df28:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001df2c:	7f ff d5 c8 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001df30:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001df34:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001df38:	02 80 00 64 	be  4001e0c8 <rtems_rfs_fs_open+0x654>         <== NOT EXECUTED
4001df3c:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: groups blocks larger than block bits\n");
4001df40:	10 80 00 2f 	b  4001dffc <rtems_rfs_fs_open+0x588>          <== NOT EXECUTED
4001df44:	90 12 21 78 	or  %o0, 0x178, %o0	! 40035978 <CSWTCH.1+0x1228><== NOT EXECUTED
    return EIO;                                                       
  }                                                                   
                                                                      
  rtems_rfs_buffer_handle_close (fs, &handle);                        
4001df48:	7f ff fe ae 	call  4001da00 <rtems_rfs_buffer_handle_close> 
4001df4c:	01 00 00 00 	nop                                            
                                                                      
  /*                                                                  
   * Change the block size to the value in the superblock.            
   */                                                                 
  rc = rtems_rfs_buffer_setblksize (fs, rtems_rfs_fs_block_size (fs));
4001df50:	d2 06 e0 08 	ld  [ %i3 + 8 ], %o1                           
4001df54:	7f ff f6 0a 	call  4001b77c <rtems_rfs_buffer_setblksize>   
4001df58:	90 10 00 1b 	mov  %i3, %o0                                  
  if (rc > 0)                                                         
4001df5c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001df60:	04 80 00 13 	ble  4001dfac <rtems_rfs_fs_open+0x538>        <== ALWAYS TAKEN
4001df64:	92 07 bf d8 	add  %fp, -40, %o1                             
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
4001df68:	7f ff fe a6 	call  4001da00 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001df6c:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001df70:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001df74:	7f ff d5 b6 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001df78:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001df7c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001df80:	22 80 00 50 	be,a   4001e0c0 <rtems_rfs_fs_open+0x64c>      <== NOT EXECUTED
4001df84:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: invalid superblock block size%d: %s\n",
4001df88:	40 00 15 01 	call  4002338c <strerror>                      <== NOT EXECUTED
4001df8c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001df90:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001df94:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001df98:	90 12 21 c0 	or  %o0, 0x1c0, %o0	! 400359c0 <CSWTCH.1+0x1270><== NOT EXECUTED
4001df9c:	40 00 10 bb 	call  40022288 <printf>                        <== NOT EXECUTED
4001dfa0:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
    errno = rc;                                                       
    return -1;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_fs_read_superblock (*fs);                            
  if (rc > 0)                                                         
4001dfa4:	10 80 00 47 	b  4001e0c0 <rtems_rfs_fs_open+0x64c>          <== NOT EXECUTED
4001dfa8:	80 a6 20 00 	cmp  %i0, 0                                    <== 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));    
4001dfac:	d0 06 e0 24 	ld  [ %i3 + 0x24 ], %o0                        
4001dfb0:	7f ff a7 7c 	call  40007da0 <calloc>                        
4001dfb4:	92 10 20 50 	mov  0x50, %o1                                 
                                                                      
  if (!fs->groups)                                                    
4001dfb8:	80 a2 20 00 	cmp  %o0, 0                                    
4001dfbc:	02 80 00 05 	be  4001dfd0 <rtems_rfs_fs_open+0x55c>         <== NEVER TAKEN
4001dfc0:	d0 26 e0 20 	st  %o0, [ %i3 + 0x20 ]                        
4001dfc4:	b4 10 20 00 	clr  %i2                                       
4001dfc8:	10 80 00 11 	b  4001e00c <rtems_rfs_fs_open+0x598>          
4001dfcc:	ba 10 20 00 	clr  %i5                                       
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &handle);                      
4001dfd0:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
4001dfd4:	7f ff fe 8b 	call  4001da00 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001dfd8:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001dfdc:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001dfe0:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001dfe4:	7f ff d5 9a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001dfe8:	b0 10 20 0c 	mov  0xc, %i0                                  <== NOT EXECUTED
4001dfec:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001dff0:	02 80 00 36 	be  4001e0c8 <rtems_rfs_fs_open+0x654>         <== NOT EXECUTED
4001dff4:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
      printf ("rtems-rfs: read-superblock: no memory for group table\n");
4001dff8:	90 12 22 08 	or  %o0, 0x208, %o0	! 40035a08 <CSWTCH.1+0x12b8><== NOT EXECUTED
4001dffc:	40 00 11 32 	call  400224c4 <puts>                          <== NOT EXECUTED
4001e000:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001e004:	30 80 00 31 	b,a   4001e0c8 <rtems_rfs_fs_open+0x654>       <== 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++)                   
4001e008:	ba 07 60 01 	inc  %i5                                       
4001e00c:	c2 06 e0 24 	ld  [ %i3 + 0x24 ], %g1                        
4001e010:	80 a7 40 01 	cmp  %i5, %g1                                  
4001e014:	36 80 00 42 	bge,a   4001e11c <rtems_rfs_fs_open+0x6a8>     
4001e018:	b0 10 20 00 	clr  %i0                                       
  {                                                                   
    rc = rtems_rfs_group_open (fs,                                    
                               rtems_rfs_fs_block (fs, group, 0),     
4001e01c:	f2 06 e0 28 	ld  [ %i3 + 0x28 ], %i1                        
4001e020:	90 10 00 1d 	mov  %i5, %o0                                  
4001e024:	7f ff 91 52 	call  4000256c <.umul>                         
4001e028:	92 10 00 19 	mov  %i1, %o1                                  
   * 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++)                   
  {                                                                   
    rc = rtems_rfs_group_open (fs,                                    
4001e02c:	d8 06 e0 20 	ld  [ %i3 + 0x20 ], %o4                        
4001e030:	d6 06 e0 2c 	ld  [ %i3 + 0x2c ], %o3                        
                               rtems_rfs_fs_block (fs, group, 0),     
4001e034:	92 02 20 01 	add  %o0, 1, %o1                               
   * 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++)                   
  {                                                                   
    rc = rtems_rfs_group_open (fs,                                    
4001e038:	98 03 00 1a 	add  %o4, %i2, %o4                             
4001e03c:	90 10 00 1b 	mov  %i3, %o0                                  
4001e040:	94 10 00 19 	mov  %i1, %o2                                  
4001e044:	7f ff cd 70 	call  40011604 <rtems_rfs_group_open>          
4001e048:	b4 06 a0 50 	add  %i2, 0x50, %i2                            
                               rtems_rfs_fs_block (fs, group, 0),     
                               fs->group_blocks,                      
                               fs->group_inodes,                      
                               &fs->groups[group]);                   
    if (rc > 0)                                                       
4001e04c:	80 a2 20 00 	cmp  %o0, 0                                    
4001e050:	04 bf ff ee 	ble  4001e008 <rtems_rfs_fs_open+0x594>        <== ALWAYS TAKEN
4001e054:	b0 10 00 08 	mov  %o0, %i0                                  
4001e058:	b2 10 20 00 	clr  %i1                                       <== NOT EXECUTED
4001e05c:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
    {                                                                 
      int g;                                                          
      for (g = 0; g < group; g++)                                     
4001e060:	80 a6 80 1d 	cmp  %i2, %i5                                  <== NOT EXECUTED
4001e064:	16 80 00 08 	bge  4001e084 <rtems_rfs_fs_open+0x610>        <== NOT EXECUTED
4001e068:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
        rtems_rfs_group_close (fs, &fs->groups[g]);                   
4001e06c:	d2 06 e0 20 	ld  [ %i3 + 0x20 ], %o1                        <== NOT EXECUTED
4001e070:	92 02 40 19 	add  %o1, %i1, %o1                             <== NOT EXECUTED
4001e074:	7f ff cd e3 	call  40011800 <rtems_rfs_group_close>         <== NOT EXECUTED
4001e078:	b4 06 a0 01 	inc  %i2                                       <== NOT EXECUTED
4001e07c:	10 bf ff f9 	b  4001e060 <rtems_rfs_fs_open+0x5ec>          <== NOT EXECUTED
4001e080:	b2 06 60 50 	add  %i1, 0x50, %i1                            <== NOT EXECUTED
      rtems_rfs_buffer_handle_close (fs, &handle);                    
4001e084:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
4001e088:	7f ff fe 5e 	call  4001da00 <rtems_rfs_buffer_handle_close> <== NOT EXECUTED
4001e08c:	90 10 00 1b 	mov  %i3, %o0                                  <== NOT EXECUTED
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                     
4001e090:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e094:	7f ff d5 6e 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e098:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001e09c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e0a0:	22 80 00 08 	be,a   4001e0c0 <rtems_rfs_fs_open+0x64c>      <== NOT EXECUTED
4001e0a4:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
        printf ("rtems-rfs: read-superblock: no memory for group table%d: %s\n",
4001e0a8:	40 00 14 b9 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e0ac:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e0b0:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e0b4:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e0b8:	10 bf ff b9 	b  4001df9c <rtems_rfs_fs_open+0x528>          <== NOT EXECUTED
4001e0bc:	90 12 22 40 	or  %o0, 0x240, %o0	! 40035a40 <CSWTCH.1+0x12f0><== NOT EXECUTED
    errno = rc;                                                       
    return -1;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_fs_read_superblock (*fs);                            
  if (rc > 0)                                                         
4001e0c0:	22 80 00 18 	be,a   4001e120 <rtems_rfs_fs_open+0x6ac>      <== NOT EXECUTED
4001e0c4:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
  {                                                                   
    rtems_rfs_buffer_close (*fs);                                     
4001e0c8:	7f ff f5 e8 	call  4001b868 <rtems_rfs_buffer_close>        <== NOT EXECUTED
4001e0cc:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
    free (*fs);                                                       
4001e0d0:	7f ff a7 97 	call  40007f2c <free>                          <== NOT EXECUTED
4001e0d4:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001e0d8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e0dc:	7f ff d5 5c 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e0e0:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001e0e4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e0e8:	02 80 00 09 	be  4001e10c <rtems_rfs_fs_open+0x698>         <== NOT EXECUTED
4001e0ec:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: open: reading superblock: %d: %s\n",        
4001e0f0:	40 00 14 a7 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e0f4:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e0f8:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001e0fc:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e100:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e104:	40 00 10 61 	call  40022288 <printf>                        <== NOT EXECUTED
4001e108:	90 12 22 80 	or  %o0, 0x280, %o0	! 40035a80 <CSWTCH.1+0x1330><== NOT EXECUTED
              rc, strerror (rc));                                     
    errno = rc;                                                       
4001e10c:	40 00 0b 64 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001e110:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001e114:	10 bf fe ae 	b  4001dbcc <rtems_rfs_fs_open+0x158>          <== NOT EXECUTED
4001e118:	f0 22 00 00 	st  %i0, [ %o0 ]                               <== NOT EXECUTED
    return -1;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (*fs, RTEMS_RFS_ROOT_INO, &inode, true);  
4001e11c:	d0 07 00 00 	ld  [ %i4 ], %o0                               
4001e120:	92 10 20 01 	mov  1, %o1                                    
4001e124:	94 07 bf d8 	add  %fp, -40, %o2                             
4001e128:	7f ff ce ed 	call  40011cdc <rtems_rfs_inode_open>          
4001e12c:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
4001e130:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001e134:	04 80 00 12 	ble  4001e17c <rtems_rfs_fs_open+0x708>        <== ALWAYS TAKEN
4001e138:	d0 07 00 00 	ld  [ %i4 ], %o0                               
  {                                                                   
    rtems_rfs_buffer_close (*fs);                                     
4001e13c:	7f ff f5 cb 	call  4001b868 <rtems_rfs_buffer_close>        <== NOT EXECUTED
4001e140:	01 00 00 00 	nop                                            <== NOT EXECUTED
    free (*fs);                                                       
4001e144:	7f ff a7 7a 	call  40007f2c <free>                          <== NOT EXECUTED
4001e148:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001e14c:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e150:	7f ff d5 3f 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e154:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001e158:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e15c:	02 bf fe 99 	be  4001dbc0 <rtems_rfs_fs_open+0x14c>         <== NOT EXECUTED
4001e160:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: open: reading root inode: %d: %s\n",        
4001e164:	40 00 14 8a 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e168:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001e16c:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e170:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e174:	10 bf fe 91 	b  4001dbb8 <rtems_rfs_fs_open+0x144>          <== NOT EXECUTED
4001e178:	90 12 22 b0 	or  %o0, 0x2b0, %o0	! 40035ab0 <CSWTCH.1+0x1360><== NOT EXECUTED
              rc, strerror (rc));                                     
    errno = rc;                                                       
    return -1;                                                        
  }                                                                   
                                                                      
  if (((*fs)->flags & RTEMS_RFS_FS_FORCE_OPEN) == 0)                  
4001e17c:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4001e180:	80 88 60 04 	btst  4, %g1                                   
4001e184:	12 80 00 23 	bne  4001e210 <rtems_rfs_fs_open+0x79c>        
4001e188:	c4 07 bf e4 	ld  [ %fp + -28 ], %g2                         
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
4001e18c:	c2 08 a0 02 	ldub  [ %g2 + 2 ], %g1                         
4001e190:	c4 08 a0 03 	ldub  [ %g2 + 3 ], %g2                         
4001e194:	83 28 60 08 	sll  %g1, 8, %g1                               
4001e198:	82 10 40 02 	or  %g1, %g2, %g1                              
  {                                                                   
    mode = rtems_rfs_inode_get_mode (&inode);                         
                                                                      
    if ((mode == 0xffff) || !RTEMS_RFS_S_ISDIR (mode))                
4001e19c:	05 3f ff c0 	sethi  %hi(0xffff0000), %g2                    
4001e1a0:	87 28 60 10 	sll  %g1, 0x10, %g3                            
4001e1a4:	80 a0 c0 02 	cmp  %g3, %g2                                  
4001e1a8:	02 80 00 07 	be  4001e1c4 <rtems_rfs_fs_open+0x750>         <== NEVER TAKEN
4001e1ac:	05 00 00 3c 	sethi  %hi(0xf000), %g2                        
4001e1b0:	82 08 40 02 	and  %g1, %g2, %g1                             
4001e1b4:	05 00 00 10 	sethi  %hi(0x4000), %g2                        
4001e1b8:	80 a0 40 02 	cmp  %g1, %g2                                  
4001e1bc:	02 80 00 15 	be  4001e210 <rtems_rfs_fs_open+0x79c>         <== ALWAYS TAKEN
4001e1c0:	01 00 00 00 	nop                                            
    {                                                                 
      rtems_rfs_inode_close (*fs, &inode);                            
4001e1c4:	7f ff cf 38 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001e1c8:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
      rtems_rfs_buffer_close (*fs);                                   
4001e1cc:	7f ff f5 a7 	call  4001b868 <rtems_rfs_buffer_close>        <== NOT EXECUTED
4001e1d0:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
      free (*fs);                                                     
4001e1d4:	7f ff a7 56 	call  40007f2c <free>                          <== NOT EXECUTED
4001e1d8:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                     
4001e1dc:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e1e0:	7f ff d5 1b 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e1e4:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001e1e8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e1ec:	02 80 00 04 	be  4001e1fc <rtems_rfs_fs_open+0x788>         <== NOT EXECUTED
4001e1f0:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
        printf ("rtems-rfs: open: invalid root inode mode\n");        
4001e1f4:	40 00 10 b4 	call  400224c4 <puts>                          <== NOT EXECUTED
4001e1f8:	90 12 22 e0 	or  %o0, 0x2e0, %o0	! 40035ae0 <CSWTCH.1+0x1390><== NOT EXECUTED
      errno = EIO;                                                    
4001e1fc:	40 00 0b 28 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001e200:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001e204:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
4001e208:	10 bf fe 71 	b  4001dbcc <rtems_rfs_fs_open+0x158>          <== NOT EXECUTED
4001e20c:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
      return -1;                                                      
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (*fs, &inode);                           
4001e210:	7f ff cf 25 	call  40011ea4 <rtems_rfs_inode_close>         
4001e214:	92 07 bf d8 	add  %fp, -40, %o1                             
  if (rc > 0)                                                         
4001e218:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001e21c:	04 80 00 12 	ble  4001e264 <rtems_rfs_fs_open+0x7f0>        <== ALWAYS TAKEN
4001e220:	01 00 00 00 	nop                                            
  {                                                                   
    rtems_rfs_buffer_close (*fs);                                     
4001e224:	7f ff f5 91 	call  4001b868 <rtems_rfs_buffer_close>        <== NOT EXECUTED
4001e228:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
    free (*fs);                                                       
4001e22c:	7f ff a7 40 	call  40007f2c <free>                          <== NOT EXECUTED
4001e230:	d0 07 00 00 	ld  [ %i4 ], %o0                               <== NOT EXECUTED
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_OPEN))                       
4001e234:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e238:	7f ff d5 05 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e23c:	92 10 20 01 	mov  1, %o1                                    <== NOT EXECUTED
4001e240:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e244:	02 bf fe 5f 	be  4001dbc0 <rtems_rfs_fs_open+0x14c>         <== NOT EXECUTED
4001e248:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: open: closing root inode: %d: %s\n", rc, strerror (rc));
4001e24c:	40 00 14 50 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e250:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001e254:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e258:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e25c:	10 bf fe 57 	b  4001dbb8 <rtems_rfs_fs_open+0x144>          <== NOT EXECUTED
4001e260:	90 12 23 10 	or  %o0, 0x310, %o0	! 40035b10 <CSWTCH.1+0x13c0><== NOT EXECUTED
    errno = rc;                                                       
    return -1;                                                        
  }                                                                   
                                                                      
  errno = 0;                                                          
4001e264:	40 00 0b 0e 	call  40020e9c <__errno>                       
4001e268:	01 00 00 00 	nop                                            
4001e26c:	c0 22 00 00 	clr  [ %o0 ]                                   
  return 0;                                                           
}                                                                     
4001e270:	81 c7 e0 08 	ret                                            
4001e274:	81 e8 00 00 	restore                                        
                                                                      

4001da28 <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) {
4001da28:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  uint64_t blocks = rtems_rfs_fs_blocks (fs);                         
  uint64_t block_size = rtems_rfs_fs_block_size (fs);                 
  return blocks * block_size;                                         
4001da2c:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           <== NOT EXECUTED
4001da30:	d6 06 20 04 	ld  [ %i0 + 4 ], %o3                           <== NOT EXECUTED
4001da34:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4001da38:	40 00 44 9d 	call  4002ecac <__muldi3>                      <== NOT EXECUTED
4001da3c:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
}                                                                     
4001da40:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
4001da44:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001da48:	93 e8 00 09 	restore  %g0, %o1, %o1                         <== NOT EXECUTED
                                                                      

40011890 <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) {
40011890:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_rfs_bitmap_bit bit;                                           
  int                  offset;                                        
  bool                 updown;                                        
  int                  direction;                                     
                                                                      
  if (inode)                                                          
40011894:	80 a6 a0 00 	cmp  %i2, 0                                    
40011898:	22 80 00 04 	be,a   400118a8 <rtems_rfs_group_bitmap_alloc+0x18>
4001189c:	e0 06 20 28 	ld  [ %i0 + 0x28 ], %l0                        
  {                                                                   
    size = fs->group_inodes;                                          
400118a0:	e0 06 20 2c 	ld  [ %i0 + 0x2c ], %l0                        
400118a4:	b2 06 7f ff 	add  %i1, -1, %i1                              
    goal -= RTEMS_RFS_ROOT_INO;                                       
  }                                                                   
  else                                                                
    size = fs->group_blocks;                                          
                                                                      
  group_start = goal / size;                                          
400118a8:	92 10 00 10 	mov  %l0, %o1                                  
400118ac:	7f ff c3 6a 	call  40002654 <.udiv>                         
400118b0:	90 10 00 19 	mov  %i1, %o0                                  
  bit = (rtems_rfs_bitmap_bit) (goal % size);                         
400118b4:	92 10 00 10 	mov  %l0, %o1                                  
    goal -= RTEMS_RFS_ROOT_INO;                                       
  }                                                                   
  else                                                                
    size = fs->group_blocks;                                          
                                                                      
  group_start = goal / size;                                          
400118b8:	aa 10 00 08 	mov  %o0, %l5                                  
  bit = (rtems_rfs_bitmap_bit) (goal % size);                         
  offset = 0;                                                         
  updown = true;                                                      
  direction = 1;                                                      
400118bc:	ba 10 20 01 	mov  1, %i5                                    
  }                                                                   
  else                                                                
    size = fs->group_blocks;                                          
                                                                      
  group_start = goal / size;                                          
  bit = (rtems_rfs_bitmap_bit) (goal % size);                         
400118c0:	90 10 00 19 	mov  %i1, %o0                                  
400118c4:	40 00 74 4e 	call  4002e9fc <.urem>                         
400118c8:	a2 10 20 01 	mov  1, %l1                                    
  offset = 0;                                                         
400118cc:	b8 10 20 00 	clr  %i4                                       
  }                                                                   
  else                                                                
    size = fs->group_blocks;                                          
                                                                      
  group_start = goal / size;                                          
  bit = (rtems_rfs_bitmap_bit) (goal % size);                         
400118d0:	d0 27 bf fc 	st  %o0, [ %fp + -4 ]                          
   */                                                                 
  while (true)                                                        
  {                                                                   
    rtems_rfs_bitmap_control* bitmap;                                 
    int                       group;                                  
    bool                      allocated = false;                      
400118d4:	c0 2f bf fb 	clrb  [ %fp + -5 ]                             
                                                                      
    /*                                                                
     * 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);                       
400118d8:	90 10 00 1d 	mov  %i5, %o0                                  
400118dc:	7f ff c3 24 	call  4000256c <.umul>                         
400118e0:	92 10 00 1c 	mov  %i4, %o1                                  
    if (offset)                                                       
400118e4:	80 a7 20 00 	cmp  %i4, 0                                    
400118e8:	02 80 00 07 	be  40011904 <rtems_rfs_group_bitmap_alloc+0x74>
400118ec:	b2 05 40 08 	add  %l5, %o0, %i1                             
      bit = direction > 0 ? 0 : size - 1;                             
400118f0:	80 a7 60 00 	cmp  %i5, 0                                    
400118f4:	14 80 00 03 	bg  40011900 <rtems_rfs_group_bitmap_alloc+0x70>
400118f8:	82 10 20 00 	clr  %g1                                       
400118fc:	82 04 3f ff 	add  %l0, -1, %g1                              
40011900:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
    /*                                                                
     * 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))                    
40011904:	80 a6 60 00 	cmp  %i1, 0                                    
40011908:	06 80 00 07 	bl  40011924 <rtems_rfs_group_bitmap_alloc+0x94>
4001190c:	80 8c 60 ff 	btst  0xff, %l1                                
40011910:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
40011914:	80 a6 40 01 	cmp  %i1, %g1                                  
40011918:	26 80 00 0a 	bl,a   40011940 <rtems_rfs_group_bitmap_alloc+0xb0>
4001191c:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1                        
    {                                                                 
      if (!updown)                                                    
40011920:	80 8c 60 ff 	btst  0xff, %l1                                
40011924:	02 80 00 4d 	be  40011a58 <rtems_rfs_group_bitmap_alloc+0x1c8>
40011928:	80 a7 60 00 	cmp  %i5, 0                                    
        break;                                                        
      direction = direction > 0 ? -1 : 1;                             
4001192c:	24 80 00 03 	ble,a   40011938 <rtems_rfs_group_bitmap_alloc+0xa8><== ALWAYS TAKEN
40011930:	ba 10 20 01 	mov  1, %i5                                    
40011934:	ba 10 3f ff 	mov  -1, %i5                                   <== NOT EXECUTED
      updown = false;                                                 
40011938:	10 bf ff e7 	b  400118d4 <rtems_rfs_group_bitmap_alloc+0x44>
4001193c:	a2 10 20 00 	clr  %l1                                       
40011940:	a7 2e 60 04 	sll  %i1, 4, %l3                               
40011944:	a5 2e 60 06 	sll  %i1, 6, %l2                               
      continue;                                                       
    }                                                                 
                                                                      
   if (inode)                                                         
40011948:	80 a6 a0 00 	cmp  %i2, 0                                    
      bitmap = &fs->groups[group].inode_bitmap;                       
4001194c:	a8 04 c0 12 	add  %l3, %l2, %l4                             
      direction = direction > 0 ? -1 : 1;                             
      updown = false;                                                 
      continue;                                                       
    }                                                                 
                                                                      
   if (inode)                                                         
40011950:	02 80 00 04 	be  40011960 <rtems_rfs_group_bitmap_alloc+0xd0>
40011954:	a8 00 40 14 	add  %g1, %l4, %l4                             
40011958:	10 80 00 03 	b  40011964 <rtems_rfs_group_bitmap_alloc+0xd4>
4001195c:	a8 05 20 2c 	add  %l4, 0x2c, %l4                            
      bitmap = &fs->groups[group].inode_bitmap;                       
    else                                                              
      bitmap = &fs->groups[group].block_bitmap;                       
40011960:	a8 05 20 08 	add  %l4, 8, %l4                               
                                                                      
    rc = rtems_rfs_bitmap_map_alloc (bitmap, bit, &allocated, &bit);  
40011964:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
40011968:	90 10 00 14 	mov  %l4, %o0                                  
4001196c:	94 07 bf fb 	add  %fp, -5, %o2                              
40011970:	40 00 20 cd 	call  40019ca4 <rtems_rfs_bitmap_map_alloc>    
40011974:	96 07 bf fc 	add  %fp, -4, %o3                              
    if (rc > 0)                                                       
40011978:	80 a2 20 00 	cmp  %o0, 0                                    
4001197c:	14 80 00 41 	bg  40011a80 <rtems_rfs_group_bitmap_alloc+0x1f0><== NEVER TAKEN
40011980:	01 00 00 00 	nop                                            
      return rc;                                                      
                                                                      
    if (rtems_rfs_fs_release_bitmaps (fs))                            
40011984:	c2 06 00 00 	ld  [ %i0 ], %g1                               
40011988:	80 88 60 01 	btst  1, %g1                                   
4001198c:	12 80 00 06 	bne  400119a4 <rtems_rfs_group_bitmap_alloc+0x114><== NEVER TAKEN
40011990:	c2 0f bf fb 	ldub  [ %fp + -5 ], %g1                        
      rtems_rfs_bitmap_release_buffer (fs, bitmap);                   
40011994:	d2 05 00 00 	ld  [ %l4 ], %o1                               
40011998:	40 00 25 a8 	call  4001b038 <rtems_rfs_buffer_handle_release>
4001199c:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
    if (allocated)                                                    
400119a0:	c2 0f bf fb 	ldub  [ %fp + -5 ], %g1                        
400119a4:	80 a0 60 00 	cmp  %g1, 0                                    
400119a8:	02 80 00 25 	be  40011a3c <rtems_rfs_group_bitmap_alloc+0x1ac>
400119ac:	80 8c 60 ff 	btst  0xff, %l1                                
    {                                                                 
      if (inode)                                                      
400119b0:	80 a6 a0 00 	cmp  %i2, 0                                    
400119b4:	02 80 00 09 	be  400119d8 <rtems_rfs_group_bitmap_alloc+0x148>
400119b8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
        *result = rtems_rfs_group_inode (fs, group, bit);             
400119bc:	d2 06 20 2c 	ld  [ %i0 + 0x2c ], %o1                        
400119c0:	ba 00 60 01 	add  %g1, 1, %i5                               
400119c4:	7f ff c2 ea 	call  4000256c <.umul>                         
400119c8:	90 10 00 19 	mov  %i1, %o0                                  
400119cc:	90 07 40 08 	add  %i5, %o0, %o0                             
400119d0:	10 80 00 07 	b  400119ec <rtems_rfs_group_bitmap_alloc+0x15c>
400119d4:	d0 26 c0 00 	st  %o0, [ %i3 ]                               
      else                                                            
        *result = rtems_rfs_group_block (&fs->groups[group], bit);    
400119d8:	c4 06 20 20 	ld  [ %i0 + 0x20 ], %g2                        
400119dc:	a4 04 c0 12 	add  %l3, %l2, %l2                             
400119e0:	c4 00 80 12 	ld  [ %g2 + %l2 ], %g2                         
400119e4:	82 00 40 02 	add  %g1, %g2, %g1                             
400119e8:	c2 26 c0 00 	st  %g1, [ %i3 ]                               
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))            
400119ec:	90 10 20 00 	clr  %o0                                       
400119f0:	13 00 00 80 	sethi  %hi(0x20000), %o1                       
400119f4:	40 00 07 16 	call  4001364c <rtems_rfs_trace>               
400119f8:	b0 10 20 00 	clr  %i0                                       
400119fc:	80 a2 20 00 	cmp  %o0, 0                                    
40011a00:	02 80 00 0d 	be  40011a34 <rtems_rfs_group_bitmap_alloc+0x1a4><== ALWAYS TAKEN
40011a04:	80 a6 a0 00 	cmp  %i2, 0                                    
        printf ("rtems-rfs: group-bitmap-alloc: %s allocated: %" PRId32 "\n",
40011a08:	22 80 00 05 	be,a   40011a1c <rtems_rfs_group_bitmap_alloc+0x18c><== NOT EXECUTED
40011a0c:	13 10 00 ce 	sethi  %hi(0x40033800), %o1                    <== NOT EXECUTED
40011a10:	13 10 00 ce 	sethi  %hi(0x40033800), %o1                    <== NOT EXECUTED
40011a14:	10 80 00 03 	b  40011a20 <rtems_rfs_group_bitmap_alloc+0x190><== NOT EXECUTED
40011a18:	92 12 63 e8 	or  %o1, 0x3e8, %o1	! 40033be8 <_Semaphore_Translate_core_mutex_return_code_+0xa58><== NOT EXECUTED
40011a1c:	92 12 63 f0 	or  %o1, 0x3f0, %o1                            <== NOT EXECUTED
40011a20:	d4 06 c0 00 	ld  [ %i3 ], %o2                               <== NOT EXECUTED
40011a24:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
                inode ? "inode" : "block", *result);                  
      return 0;                                                       
40011a28:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
      if (inode)                                                      
        *result = rtems_rfs_group_inode (fs, group, bit);             
      else                                                            
        *result = rtems_rfs_group_block (&fs->groups[group], bit);    
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))            
        printf ("rtems-rfs: group-bitmap-alloc: %s allocated: %" PRId32 "\n",
40011a2c:	40 00 42 17 	call  40022288 <printf>                        <== NOT EXECUTED
40011a30:	90 12 23 f8 	or  %o0, 0x3f8, %o0                            <== NOT EXECUTED
40011a34:	81 c7 e0 08 	ret                                            
40011a38:	81 e8 00 00 	restore                                        
     * group_start, then alternate the direction and                  
     * increment the offset on every other iteration.                 
     * Otherwise we are marching through the groups, so just          
     * increment the offset.                                          
     */                                                               
    if (updown)                                                       
40011a3c:	22 bf ff a6 	be,a   400118d4 <rtems_rfs_group_bitmap_alloc+0x44><== NEVER TAKEN
40011a40:	b8 07 20 01 	inc  %i4                                       <== NOT EXECUTED
    {                                                                 
      direction = direction > 0 ? -1 : 1;                             
40011a44:	80 a7 60 00 	cmp  %i5, 0                                    
40011a48:	34 80 00 12 	bg,a   40011a90 <rtems_rfs_group_bitmap_alloc+0x200><== ALWAYS TAKEN
40011a4c:	b8 07 20 01 	inc  %i4                                       
40011a50:	10 bf ff a1 	b  400118d4 <rtems_rfs_group_bitmap_alloc+0x44><== NOT EXECUTED
40011a54:	ba 10 20 01 	mov  1, %i5                                    <== NOT EXECUTED
       offset++;                                                      
    }                                                                 
                                                                      
  }                                                                   
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))                
40011a58:	90 10 20 00 	clr  %o0                                       
40011a5c:	40 00 06 fc 	call  4001364c <rtems_rfs_trace>               
40011a60:	13 00 00 80 	sethi  %hi(0x20000), %o1                       
40011a64:	80 a2 20 00 	cmp  %o0, 0                                    
40011a68:	02 80 00 08 	be  40011a88 <rtems_rfs_group_bitmap_alloc+0x1f8><== ALWAYS TAKEN
40011a6c:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    
    printf ("rtems-rfs: group-bitmap-alloc: no blocks available\n");  
40011a70:	40 00 42 95 	call  400224c4 <puts>                          <== NOT EXECUTED
40011a74:	90 12 20 30 	or  %o0, 0x30, %o0	! 40033c30 <_Semaphore_Translate_core_mutex_return_code_+0xaa0><== NOT EXECUTED
                                                                      
  return ENOSPC;                                                      
40011a78:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011a7c:	91 e8 20 1c 	restore  %g0, 0x1c, %o0                        <== 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);  
40011a80:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011a84:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
  }                                                                   
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))                
    printf ("rtems-rfs: group-bitmap-alloc: no blocks available\n");  
                                                                      
  return ENOSPC;                                                      
40011a88:	81 c7 e0 08 	ret                                            
40011a8c:	91 e8 20 1c 	restore  %g0, 0x1c, %o0                        
     */                                                               
    if (updown)                                                       
    {                                                                 
      direction = direction > 0 ? -1 : 1;                             
      if ( direction == -1 )                                          
        offset++;                                                     
40011a90:	10 bf ff 91 	b  400118d4 <rtems_rfs_group_bitmap_alloc+0x44>
40011a94:	ba 10 3f ff 	mov  -1, %i5                                   
                                                                      

40011a98 <rtems_rfs_group_bitmap_free>: int rtems_rfs_group_bitmap_free (rtems_rfs_file_system* fs, bool inode, rtems_rfs_bitmap_bit no) {
40011a98:	9d e3 bf a0 	save  %sp, -96, %sp                            
  unsigned int              group;                                    
  rtems_rfs_bitmap_bit      bit;                                      
  size_t                    size;                                     
  int                       rc;                                       
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_BITMAPS))                
40011a9c:	90 10 20 00 	clr  %o0                                       
40011aa0:	13 00 00 80 	sethi  %hi(0x20000), %o1                       
40011aa4:	40 00 06 ea 	call  4001364c <rtems_rfs_trace>               
40011aa8:	ba 10 00 18 	mov  %i0, %i5                                  
40011aac:	80 a2 20 00 	cmp  %o0, 0                                    
40011ab0:	02 80 00 0d 	be  40011ae4 <rtems_rfs_group_bitmap_free+0x4c><== ALWAYS TAKEN
40011ab4:	80 a6 60 00 	cmp  %i1, 0                                    
    printf ("rtems-rfs: group-bitmap-free: %s free: %" PRId32 "\n",   
40011ab8:	22 80 00 05 	be,a   40011acc <rtems_rfs_group_bitmap_free+0x34><== NOT EXECUTED
40011abc:	13 10 00 ce 	sethi  %hi(0x40033800), %o1                    <== NOT EXECUTED
40011ac0:	13 10 00 ce 	sethi  %hi(0x40033800), %o1                    <== NOT EXECUTED
40011ac4:	10 80 00 03 	b  40011ad0 <rtems_rfs_group_bitmap_free+0x38> <== NOT EXECUTED
40011ac8:	92 12 63 e8 	or  %o1, 0x3e8, %o1	! 40033be8 <_Semaphore_Translate_core_mutex_return_code_+0xa58><== NOT EXECUTED
40011acc:	92 12 63 f0 	or  %o1, 0x3f0, %o1                            <== NOT EXECUTED
40011ad0:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011ad4:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
40011ad8:	40 00 41 ec 	call  40022288 <printf>                        <== NOT EXECUTED
40011adc:	90 12 20 68 	or  %o0, 0x68, %o0                             <== NOT EXECUTED
            inode ? "inode" : "block", no);                           
                                                                      
  if (inode)                                                          
40011ae0:	80 a6 60 00 	cmp  %i1, 0                                    <== NOT EXECUTED
40011ae4:	02 80 00 04 	be  40011af4 <rtems_rfs_group_bitmap_free+0x5c>
40011ae8:	b4 06 bf ff 	add  %i2, -1, %i2                              
40011aec:	10 80 00 03 	b  40011af8 <rtems_rfs_group_bitmap_free+0x60> 
40011af0:	f6 07 60 2c 	ld  [ %i5 + 0x2c ], %i3                        
    size = fs->group_inodes;                                          
  }                                                                   
  else                                                                
  {                                                                   
    no -= RTEMS_RFS_SUPERBLOCK_SIZE;                                  
    size = fs->group_blocks;                                          
40011af4:	f6 07 60 28 	ld  [ %i5 + 0x28 ], %i3                        
  }                                                                   
                                                                      
  group = no / size;                                                  
40011af8:	92 10 00 1b 	mov  %i3, %o1                                  
40011afc:	7f ff c2 d6 	call  40002654 <.udiv>                         
40011b00:	90 10 00 1a 	mov  %i2, %o0                                  
  bit = (rtems_rfs_bitmap_bit) (no % size);                           
40011b04:	92 10 00 1b 	mov  %i3, %o1                                  
  {                                                                   
    no -= RTEMS_RFS_SUPERBLOCK_SIZE;                                  
    size = fs->group_blocks;                                          
  }                                                                   
                                                                      
  group = no / size;                                                  
40011b08:	b0 10 00 08 	mov  %o0, %i0                                  
  bit = (rtems_rfs_bitmap_bit) (no % size);                           
40011b0c:	40 00 73 bc 	call  4002e9fc <.urem>                         
40011b10:	90 10 00 1a 	mov  %i2, %o0                                  
40011b14:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
40011b18:	b9 2e 20 04 	sll  %i0, 4, %i4                               
40011b1c:	92 10 00 08 	mov  %o0, %o1                                  
40011b20:	b1 2e 20 06 	sll  %i0, 6, %i0                               
                                                                      
  if (inode)                                                          
40011b24:	80 a6 60 00 	cmp  %i1, 0                                    
    bitmap = &fs->groups[group].inode_bitmap;                         
40011b28:	b8 07 00 18 	add  %i4, %i0, %i4                             
  }                                                                   
                                                                      
  group = no / size;                                                  
  bit = (rtems_rfs_bitmap_bit) (no % size);                           
                                                                      
  if (inode)                                                          
40011b2c:	02 80 00 04 	be  40011b3c <rtems_rfs_group_bitmap_free+0xa4>
40011b30:	b8 00 40 1c 	add  %g1, %i4, %i4                             
40011b34:	10 80 00 03 	b  40011b40 <rtems_rfs_group_bitmap_free+0xa8> 
40011b38:	b8 07 20 2c 	add  %i4, 0x2c, %i4                            
    bitmap = &fs->groups[group].inode_bitmap;                         
  else                                                                
    bitmap = &fs->groups[group].block_bitmap;                         
40011b3c:	b8 07 20 08 	add  %i4, 8, %i4                               
                                                                      
  rc = rtems_rfs_bitmap_map_clear (bitmap, bit);                      
40011b40:	40 00 20 09 	call  40019b64 <rtems_rfs_bitmap_map_clear>    
40011b44:	90 10 00 1c 	mov  %i4, %o0                                  
                                                                      
  rtems_rfs_bitmap_release_buffer (fs, bitmap);                       
40011b48:	d2 07 00 00 	ld  [ %i4 ], %o1                               
  if (inode)                                                          
    bitmap = &fs->groups[group].inode_bitmap;                         
  else                                                                
    bitmap = &fs->groups[group].block_bitmap;                         
                                                                      
  rc = rtems_rfs_bitmap_map_clear (bitmap, bit);                      
40011b4c:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
  rtems_rfs_bitmap_release_buffer (fs, bitmap);                       
40011b50:	40 00 25 3a 	call  4001b038 <rtems_rfs_buffer_handle_release>
40011b54:	90 10 00 1d 	mov  %i5, %o0                                  
                                                                      
  return rc;                                                          
}                                                                     
40011b58:	81 c7 e0 08 	ret                                            
40011b5c:	81 e8 00 00 	restore                                        
                                                                      

40011800 <rtems_rfs_group_close>: int rtems_rfs_group_close (rtems_rfs_file_system* fs, rtems_rfs_group* group) {
40011800:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int result = 0;                                                     
  int rc;                                                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_CLOSE))                  
40011804:	90 10 20 00 	clr  %o0                                       
40011808:	13 00 00 40 	sethi  %hi(0x10000), %o1                       
4001180c:	40 00 07 90 	call  4001364c <rtems_rfs_trace>               
40011810:	ba 10 00 18 	mov  %i0, %i5                                  
40011814:	80 a2 20 00 	cmp  %o0, 0                                    
40011818:	02 80 00 06 	be  40011830 <rtems_rfs_group_close+0x30>      <== ALWAYS TAKEN
4001181c:	01 00 00 00 	nop                                            
    printf ("rtems-rfs: group-close: base=%" PRId32 "\n", group->base);
40011820:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
40011824:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011828:	40 00 42 98 	call  40022288 <printf>                        <== NOT EXECUTED
4001182c:	90 12 23 c0 	or  %o0, 0x3c0, %o0	! 40033bc0 <_Semaphore_Translate_core_mutex_return_code_+0xa30><== 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);                 
40011830:	40 00 21 a6 	call  40019ec8 <rtems_rfs_bitmap_close>        
40011834:	90 06 60 2c 	add  %i1, 0x2c, %o0                            
 */                                                                   
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);                       
40011838:	92 06 60 44 	add  %i1, 0x44, %o1                            
4001183c:	b8 10 00 08 	mov  %o0, %i4                                  
40011840:	40 00 25 fe 	call  4001b038 <rtems_rfs_buffer_handle_release>
40011844:	90 10 00 1d 	mov  %i5, %o0                                  
  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);                 
40011848:	90 06 60 08 	add  %i1, 8, %o0                               
  handle->dirty = false;                                              
4001184c:	c0 2e 60 44 	clrb  [ %i1 + 0x44 ]                           
  handle->bnum  = 0;                                                  
40011850:	c0 26 60 48 	clr  [ %i1 + 0x48 ]                            
40011854:	40 00 21 9d 	call  40019ec8 <rtems_rfs_bitmap_close>        
40011858:	c0 26 60 4c 	clr  [ %i1 + 0x4c ]                            
  if (rc > 0)                                                         
4001185c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011860:	14 80 00 05 	bg  40011874 <rtems_rfs_group_close+0x74>      <== NEVER TAKEN
40011864:	90 10 00 1d 	mov  %i5, %o0                                  
40011868:	b0 38 00 1c 	xnor  %g0, %i4, %i0                            
4001186c:	b1 3e 20 1f 	sra  %i0, 0x1f, %i0                            
40011870:	b0 0f 00 18 	and  %i4, %i0, %i0                             
 */                                                                   
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);                       
40011874:	40 00 25 f1 	call  4001b038 <rtems_rfs_buffer_handle_release>
40011878:	92 06 60 20 	add  %i1, 0x20, %o1                            
  handle->dirty = false;                                              
4001187c:	c0 2e 60 20 	clrb  [ %i1 + 0x20 ]                           
  handle->bnum  = 0;                                                  
40011880:	c0 26 60 24 	clr  [ %i1 + 0x24 ]                            
  handle->buffer = NULL;                                              
40011884:	c0 26 60 28 	clr  [ %i1 + 0x28 ]                            
  rc = rtems_rfs_buffer_handle_close (fs, &group->block_bitmap_buffer);
  if (rc > 0)                                                         
    result = rc;                                                      
                                                                      
  return result;                                                      
}                                                                     
40011888:	81 c7 e0 08 	ret                                            
4001188c:	81 e8 00 00 	restore                                        
                                                                      

40011604 <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) {
40011604:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc;                                                             
                                                                      
  if (base >= rtems_rfs_fs_blocks (fs))                               
40011608:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
4001160c:	80 a6 40 01 	cmp  %i1, %g1                                  
40011610:	0a 80 00 10 	bcs  40011650 <rtems_rfs_group_open+0x4c>      <== ALWAYS TAKEN
40011614:	ba 10 00 18 	mov  %i0, %i5                                  
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_OPEN))                 
40011618:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001161c:	13 00 00 20 	sethi  %hi(0x8000), %o1                        <== NOT EXECUTED
40011620:	40 00 08 0b 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
40011624:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
40011628:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001162c:	02 80 00 73 	be  400117f8 <rtems_rfs_group_open+0x1f4>      <== NOT EXECUTED
40011630:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: group-open: base outside file system range: %d: %s\n",
40011634:	40 00 47 56 	call  4002338c <strerror>                      <== NOT EXECUTED
40011638:	90 10 20 05 	mov  5, %o0	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
4001163c:	92 10 20 05 	mov  5, %o1                                    <== NOT EXECUTED
40011640:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011644:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
40011648:	10 80 00 37 	b  40011724 <rtems_rfs_group_open+0x120>       <== NOT EXECUTED
4001164c:	90 12 22 c8 	or  %o0, 0x2c8, %o0	! 40033ac8 <_Semaphore_Translate_core_mutex_return_code_+0x938><== NOT EXECUTED
              EIO, strerror (EIO));                                   
    return EIO;                                                       
  }                                                                   
                                                                      
  if ((base + size) >= rtems_rfs_fs_blocks (fs))                      
40011650:	84 06 40 1a 	add  %i1, %i2, %g2                             
40011654:	80 a0 80 01 	cmp  %g2, %g1                                  
40011658:	3a 80 00 02 	bcc,a   40011660 <rtems_rfs_group_open+0x5c>   <== ALWAYS TAKEN
4001165c:	b4 20 40 19 	sub  %g1, %i1, %i2                             
40011660:	80 a6 80 1b 	cmp  %i2, %i3                                  
40011664:	08 80 00 03 	bleu  40011670 <rtems_rfs_group_open+0x6c>     <== NEVER TAKEN
40011668:	a0 10 00 1a 	mov  %i2, %l0                                  
4001166c:	a0 10 00 1b 	mov  %i3, %l0                                  
   * the format configuration needs reviewing.                        
   */                                                                 
  if (inodes > size)                                                  
    inodes = size;                                                    
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_OPEN))                   
40011670:	90 10 20 00 	clr  %o0                                       
40011674:	40 00 07 f6 	call  4001364c <rtems_rfs_trace>               
40011678:	13 00 00 20 	sethi  %hi(0x8000), %o1                        
4001167c:	80 a2 20 00 	cmp  %o0, 0                                    
40011680:	22 80 00 09 	be,a   400116a4 <rtems_rfs_group_open+0xa0>    <== ALWAYS TAKEN
40011684:	f2 27 00 00 	st  %i1, [ %i4 ]                               
    printf ("rtems-rfs: group-open: base=%" PRId32 ", blocks=%zd inodes=%zd\n",
40011688:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
4001168c:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
40011690:	90 12 23 08 	or  %o0, 0x308, %o0                            <== NOT EXECUTED
40011694:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
40011698:	40 00 42 fc 	call  40022288 <printf>                        <== NOT EXECUTED
4001169c:	96 10 00 10 	mov  %l0, %o3                                  <== NOT EXECUTED
            base, size, inodes);                                      
                                                                      
  group->base = base;                                                 
400116a0:	f2 27 00 00 	st  %i1, [ %i4 ]                               <== NOT EXECUTED
  group->size = size;                                                 
400116a4:	f4 27 20 04 	st  %i2, [ %i4 + 4 ]                           
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
400116a8:	c0 2f 20 20 	clrb  [ %i4 + 0x20 ]                           
  handle->bnum  = 0;                                                  
400116ac:	c0 27 20 24 	clr  [ %i4 + 0x24 ]                            
  handle->buffer = NULL;                                              
400116b0:	c0 27 20 28 	clr  [ %i4 + 0x28 ]                            
      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,               
400116b4:	a2 07 20 08 	add  %i4, 8, %l1                               
400116b8:	b6 07 20 20 	add  %i4, 0x20, %i3                            
400116bc:	90 10 00 11 	mov  %l1, %o0                                  
400116c0:	92 10 00 1d 	mov  %i5, %o1                                  
400116c4:	94 10 00 1b 	mov  %i3, %o2                                  
400116c8:	96 10 00 1a 	mov  %i2, %o3                                  
400116cc:	40 00 21 ee 	call  40019e84 <rtems_rfs_bitmap_open>         
400116d0:	98 10 00 19 	mov  %i1, %o4                                  
                              &group->block_bitmap_buffer, size,      
                              group->base + RTEMS_RFS_GROUP_BLOCK_BITMAP_BLOCK);
  if (rc > 0)                                                         
400116d4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400116d8:	04 80 00 17 	ble  40011734 <rtems_rfs_group_open+0x130>     <== ALWAYS TAKEN
400116dc:	92 10 00 1b 	mov  %i3, %o1                                  
 */                                                                   
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);                       
400116e0:	40 00 26 56 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
400116e4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &group->block_bitmap_buffer);  
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_OPEN))                 
400116e8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
  handle->dirty = false;                                              
400116ec:	c0 2f 20 20 	clrb  [ %i4 + 0x20 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
400116f0:	c0 27 20 24 	clr  [ %i4 + 0x24 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
400116f4:	c0 27 20 28 	clr  [ %i4 + 0x28 ]                            <== NOT EXECUTED
400116f8:	40 00 07 d5 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
400116fc:	13 00 00 20 	sethi  %hi(0x8000), %o1                        <== NOT EXECUTED
40011700:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40011704:	02 80 00 3d 	be  400117f8 <rtems_rfs_group_open+0x1f4>      <== NOT EXECUTED
40011708:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: group-open: could not open block bitmap: %d: %s\n",
4001170c:	40 00 47 20 	call  4002338c <strerror>                      <== NOT EXECUTED
40011710:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40011714:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
40011718:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
4001171c:	90 12 23 40 	or  %o0, 0x340, %o0	! 40033b40 <_Semaphore_Translate_core_mutex_return_code_+0x9b0><== NOT EXECUTED
40011720:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
40011724:	40 00 42 d9 	call  40022288 <printf>                        <== NOT EXECUTED
40011728:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001172c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011730:	81 e8 00 00 	restore                                        <== 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,               
40011734:	d8 07 00 00 	ld  [ %i4 ], %o4                               
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
40011738:	c0 2f 20 44 	clrb  [ %i4 + 0x44 ]                           
  handle->bnum  = 0;                                                  
4001173c:	c0 27 20 48 	clr  [ %i4 + 0x48 ]                            
  handle->buffer = NULL;                                              
40011740:	c0 27 20 4c 	clr  [ %i4 + 0x4c ]                            
40011744:	b4 07 20 44 	add  %i4, 0x44, %i2                            
40011748:	90 07 20 2c 	add  %i4, 0x2c, %o0                            
4001174c:	92 10 00 1d 	mov  %i5, %o1                                  
40011750:	94 10 00 1a 	mov  %i2, %o2                                  
40011754:	96 10 00 10 	mov  %l0, %o3                                  
40011758:	40 00 21 cb 	call  40019e84 <rtems_rfs_bitmap_open>         
4001175c:	98 03 20 01 	inc  %o4                                       
                              &group->inode_bitmap_buffer, inodes,    
                              group->base + RTEMS_RFS_GROUP_INODE_BITMAP_BLOCK);
  if (rc > 0)                                                         
40011760:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011764:	04 80 00 1b 	ble  400117d0 <rtems_rfs_group_open+0x1cc>     <== ALWAYS TAKEN
40011768:	92 10 00 1a 	mov  %i2, %o1                                  
 */                                                                   
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);                       
4001176c:	40 00 26 33 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
40011770:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  {                                                                   
    rtems_rfs_buffer_handle_close (fs, &group->inode_bitmap_buffer);  
    rtems_rfs_bitmap_close (&group->block_bitmap);                    
40011774:	90 10 00 11 	mov  %l1, %o0                                  <== NOT EXECUTED
  handle->dirty = false;                                              
40011778:	c0 2f 20 44 	clrb  [ %i4 + 0x44 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001177c:	c0 27 20 48 	clr  [ %i4 + 0x48 ]                            <== NOT EXECUTED
40011780:	40 00 21 d2 	call  40019ec8 <rtems_rfs_bitmap_close>        <== NOT EXECUTED
40011784:	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);                       
40011788:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001178c:	40 00 26 2b 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
40011790:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    rtems_rfs_buffer_handle_close (fs, &group->block_bitmap_buffer);  
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_GROUP_OPEN))                 
40011794:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
  handle->dirty = false;                                              
40011798:	c0 2f 20 20 	clrb  [ %i4 + 0x20 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001179c:	c0 27 20 24 	clr  [ %i4 + 0x24 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
400117a0:	c0 27 20 28 	clr  [ %i4 + 0x28 ]                            <== NOT EXECUTED
400117a4:	40 00 07 aa 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
400117a8:	13 00 00 20 	sethi  %hi(0x8000), %o1                        <== NOT EXECUTED
400117ac:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
400117b0:	02 80 00 12 	be  400117f8 <rtems_rfs_group_open+0x1f4>      <== NOT EXECUTED
400117b4:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: group-open: could not open inode bitmap: %d: %s\n",
400117b8:	40 00 46 f5 	call  4002338c <strerror>                      <== NOT EXECUTED
400117bc:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
400117c0:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
400117c4:	11 10 00 ce 	sethi  %hi(0x40033800), %o0                    <== NOT EXECUTED
400117c8:	10 bf ff d6 	b  40011720 <rtems_rfs_group_open+0x11c>       <== NOT EXECUTED
400117cc:	90 12 23 80 	or  %o0, 0x380, %o0	! 40033b80 <_Semaphore_Translate_core_mutex_return_code_+0x9f0><== NOT EXECUTED
              rc, strerror (rc));                                     
    return rc;                                                        
  }                                                                   
                                                                      
  if (rtems_rfs_fs_release_bitmaps (fs))                              
400117d0:	c2 07 40 00 	ld  [ %i5 ], %g1                               
400117d4:	80 88 60 01 	btst  1, %g1                                   
400117d8:	12 bf ff d5 	bne  4001172c <rtems_rfs_group_open+0x128>     <== NEVER TAKEN
400117dc:	b0 10 20 00 	clr  %i0                                       
  {                                                                   
    rtems_rfs_bitmap_release_buffer (fs, &group->block_bitmap);       
400117e0:	d2 07 20 08 	ld  [ %i4 + 8 ], %o1                           
400117e4:	40 00 26 15 	call  4001b038 <rtems_rfs_buffer_handle_release>
400117e8:	90 10 00 1d 	mov  %i5, %o0                                  
    rtems_rfs_bitmap_release_buffer (fs, &group->inode_bitmap);       
400117ec:	d2 07 20 2c 	ld  [ %i4 + 0x2c ], %o1                        
400117f0:	40 00 26 12 	call  4001b038 <rtems_rfs_buffer_handle_release>
400117f4:	90 10 00 1d 	mov  %i5, %o0                                  
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
400117f8:	81 c7 e0 08 	ret                                            
400117fc:	81 e8 00 00 	restore                                        
                                                                      

40011b60 <rtems_rfs_group_usage>: size_t* blocks, size_t* inodes) { int g; *blocks = 0;
40011b60:	c0 22 40 00 	clr  [ %o1 ]                                   <== NOT EXECUTED
  *inodes = 0;                                                        
40011b64:	c0 22 80 00 	clr  [ %o2 ]                                   <== NOT EXECUTED
                                                                      
  for (g = 0; g < fs->group_count; g++)                               
40011b68:	86 10 20 00 	clr  %g3                                       <== NOT EXECUTED
40011b6c:	84 10 20 00 	clr  %g2                                       <== NOT EXECUTED
40011b70:	c2 02 20 24 	ld  [ %o0 + 0x24 ], %g1                        <== NOT EXECUTED
40011b74:	80 a0 80 01 	cmp  %g2, %g1                                  <== NOT EXECUTED
40011b78:	16 80 00 12 	bge  40011bc0 <rtems_rfs_group_usage+0x60>     <== NOT EXECUTED
40011b7c:	c8 02 40 00 	ld  [ %o1 ], %g4                               <== NOT EXECUTED
  {                                                                   
    rtems_rfs_group* group = &fs->groups[g];                          
40011b80:	c2 02 20 20 	ld  [ %o0 + 0x20 ], %g1                        <== NOT EXECUTED
  int g;                                                              
                                                                      
  *blocks = 0;                                                        
  *inodes = 0;                                                        
                                                                      
  for (g = 0; g < fs->group_count; g++)                               
40011b84:	84 00 a0 01 	inc  %g2                                       <== NOT EXECUTED
  {                                                                   
    rtems_rfs_group* group = &fs->groups[g];                          
40011b88:	82 00 40 03 	add  %g1, %g3, %g1                             <== NOT EXECUTED
    *blocks +=                                                        
      rtems_rfs_bitmap_map_size(&group->block_bitmap) -               
40011b8c:	d8 00 60 14 	ld  [ %g1 + 0x14 ], %o4                        <== NOT EXECUTED
40011b90:	da 00 60 18 	ld  [ %g1 + 0x18 ], %o5                        <== NOT EXECUTED
40011b94:	86 00 e0 50 	add  %g3, 0x50, %g3                            <== NOT EXECUTED
40011b98:	9a 23 00 0d 	sub  %o4, %o5, %o5                             <== NOT EXECUTED
  *inodes = 0;                                                        
                                                                      
  for (g = 0; g < fs->group_count; g++)                               
  {                                                                   
    rtems_rfs_group* group = &fs->groups[g];                          
    *blocks +=                                                        
40011b9c:	88 01 00 0d 	add  %g4, %o5, %g4                             <== NOT EXECUTED
40011ba0:	c8 22 40 00 	st  %g4, [ %o1 ]                               <== NOT EXECUTED
      rtems_rfs_bitmap_map_size(&group->block_bitmap) -               
      rtems_rfs_bitmap_map_free (&group->block_bitmap);               
    *inodes +=                                                        
      rtems_rfs_bitmap_map_size (&group->inode_bitmap) -              
40011ba4:	c8 00 60 38 	ld  [ %g1 + 0x38 ], %g4                        <== NOT EXECUTED
40011ba8:	c2 00 60 3c 	ld  [ %g1 + 0x3c ], %g1                        <== NOT EXECUTED
40011bac:	82 21 00 01 	sub  %g4, %g1, %g1                             <== NOT EXECUTED
  {                                                                   
    rtems_rfs_group* group = &fs->groups[g];                          
    *blocks +=                                                        
      rtems_rfs_bitmap_map_size(&group->block_bitmap) -               
      rtems_rfs_bitmap_map_free (&group->block_bitmap);               
    *inodes +=                                                        
40011bb0:	c8 02 80 00 	ld  [ %o2 ], %g4                               <== NOT EXECUTED
40011bb4:	82 01 00 01 	add  %g4, %g1, %g1                             <== NOT EXECUTED
40011bb8:	10 bf ff ee 	b  40011b70 <rtems_rfs_group_usage+0x10>       <== NOT EXECUTED
40011bbc:	c2 22 80 00 	st  %g1, [ %o2 ]                               <== NOT EXECUTED
      rtems_rfs_bitmap_map_size (&group->inode_bitmap) -              
      rtems_rfs_bitmap_map_free (&group->inode_bitmap);               
  }                                                                   
                                                                      
  if (*blocks > rtems_rfs_fs_blocks (fs))                             
40011bc0:	c2 02 20 04 	ld  [ %o0 + 4 ], %g1                           <== NOT EXECUTED
40011bc4:	80 a1 00 01 	cmp  %g4, %g1                                  <== NOT EXECUTED
40011bc8:	38 80 00 02 	bgu,a   40011bd0 <rtems_rfs_group_usage+0x70>  <== NOT EXECUTED
40011bcc:	c2 22 40 00 	st  %g1, [ %o1 ]                               <== NOT EXECUTED
    *blocks = rtems_rfs_fs_blocks (fs);                               
  if (*inodes > rtems_rfs_fs_inodes (fs))                             
40011bd0:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        <== NOT EXECUTED
40011bd4:	c4 02 80 00 	ld  [ %o2 ], %g2                               <== NOT EXECUTED
40011bd8:	80 a0 80 01 	cmp  %g2, %g1                                  <== NOT EXECUTED
40011bdc:	38 80 00 02 	bgu,a   40011be4 <rtems_rfs_group_usage+0x84>  <== NOT EXECUTED
40011be0:	c2 22 80 00 	st  %g1, [ %o2 ]                               <== NOT EXECUTED
    *inodes = rtems_rfs_fs_inodes (fs);                               
                                                                      
  return 0;                                                           
}                                                                     
40011be4:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
40011be8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
                                                                      

40011ea4 <rtems_rfs_inode_close>: } int rtems_rfs_inode_close (rtems_rfs_file_system* fs, rtems_rfs_inode_handle* handle) {
40011ea4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc;                                                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_CLOSE))                  
40011ea8:	90 10 20 00 	clr  %o0                                       
40011eac:	40 00 05 e8 	call  4001364c <rtems_rfs_trace>               
40011eb0:	13 00 02 00 	sethi  %hi(0x80000), %o1                       
40011eb4:	80 a2 20 00 	cmp  %o0, 0                                    
40011eb8:	22 80 00 07 	be,a   40011ed4 <rtems_rfs_inode_close+0x30>   <== ALWAYS TAKEN
40011ebc:	90 10 00 18 	mov  %i0, %o0                                  
    printf ("rtems-rfs: inode-close: ino: %" PRIu32 "\n", handle->ino);
40011ec0:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
40011ec4:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011ec8:	40 00 40 f0 	call  40022288 <printf>                        <== NOT EXECUTED
40011ecc:	90 12 21 68 	or  %o0, 0x168, %o0	! 40033d68 <_Semaphore_Translate_core_mutex_return_code_+0xbd8><== NOT EXECUTED
                                                                      
  rc = rtems_rfs_inode_unload (fs, handle, true);                     
40011ed0:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40011ed4:	92 10 00 19 	mov  %i1, %o1                                  
40011ed8:	7f ff ff b7 	call  40011db4 <rtems_rfs_inode_unload>        
40011edc:	94 10 20 01 	mov  1, %o2                                    
                                                                      
  if ((rc == 0) && (handle->loads > 0))                               
40011ee0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011ee4:	32 80 00 11 	bne,a   40011f28 <rtems_rfs_inode_close+0x84>  <== NEVER TAKEN
40011ee8:	c0 26 60 08 	clr  [ %i1 + 8 ]                               <== NOT EXECUTED
40011eec:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
40011ef0:	80 a0 60 00 	cmp  %g1, 0                                    
40011ef4:	04 80 00 0c 	ble  40011f24 <rtems_rfs_inode_close+0x80>     <== ALWAYS TAKEN
40011ef8:	13 00 02 00 	sethi  %hi(0x80000), %o1                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_CLOSE))                
40011efc:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
40011f00:	40 00 05 d3 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
40011f04:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
40011f08:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40011f0c:	22 80 00 07 	be,a   40011f28 <rtems_rfs_inode_close+0x84>   <== NOT EXECUTED
40011f10:	c0 26 60 08 	clr  [ %i1 + 8 ]                               <== NOT EXECUTED
      printf ("rtems-rfs: inode-close: bad loads number: %d\n",       
40011f14:	d2 06 60 24 	ld  [ %i1 + 0x24 ], %o1                        <== NOT EXECUTED
40011f18:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011f1c:	40 00 40 db 	call  40022288 <printf>                        <== NOT EXECUTED
40011f20:	90 12 21 90 	or  %o0, 0x190, %o0	! 40033d90 <_Semaphore_Translate_core_mutex_return_code_+0xc00><== NOT EXECUTED
              handle->loads);                                         
    rc = EIO;                                                         
  }                                                                   
                                                                      
  handle->ino = 0;                                                    
40011f24:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
  return rc;                                                          
}                                                                     
40011f28:	81 c7 e0 08 	ret                                            
40011f2c:	81 e8 00 00 	restore                                        
                                                                      

40012204 <rtems_rfs_inode_create>: uint16_t mode, uint16_t links, uid_t uid, gid_t gid, rtems_rfs_ino* ino) {
40012204:	9d e3 bf 50 	save  %sp, -176, %sp                           
  rtems_rfs_inode_handle parent_inode;                                
  rtems_rfs_inode_handle inode;                                       
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_CREATE))                 
40012208:	90 10 20 00 	clr  %o0                                       
                        uint16_t                mode,                 
                        uint16_t                links,                
                        uid_t                   uid,                  
                        gid_t                   gid,                  
                        rtems_rfs_ino*          ino)                  
{                                                                     
4001220c:	e2 07 a0 64 	ld  [ %fp + 0x64 ], %l1                        
40012210:	e8 17 a0 5e 	lduh  [ %fp + 0x5e ], %l4                      
40012214:	e6 17 a0 62 	lduh  [ %fp + 0x62 ], %l3                      
  rtems_rfs_inode_handle parent_inode;                                
  rtems_rfs_inode_handle inode;                                       
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_CREATE))                 
40012218:	13 00 10 00 	sethi  %hi(0x400000), %o1                      
4001221c:	40 00 05 0c 	call  4001364c <rtems_rfs_trace>               
40012220:	a0 10 00 18 	mov  %i0, %l0                                  
40012224:	80 a2 20 00 	cmp  %o0, 0                                    
40012228:	02 80 00 34 	be  400122f8 <rtems_rfs_inode_create+0xf4>     <== ALWAYS TAKEN
4001222c:	aa 0f 30 00 	and  %i4, -4096, %l5                           
  {                                                                   
    const char* type = "unknown";                                     
    int         c;                                                    
    if (RTEMS_RFS_S_ISDIR (mode))                                     
40012230:	05 00 00 10 	sethi  %hi(0x4000), %g2                        <== NOT EXECUTED
40012234:	80 a5 40 02 	cmp  %l5, %g2                                  <== NOT EXECUTED
40012238:	02 80 00 12 	be  40012280 <rtems_rfs_inode_create+0x7c>     <== NOT EXECUTED
4001223c:	05 00 00 08 	sethi  %hi(0x2000), %g2                        <== NOT EXECUTED
      type = "dir";                                                   
    else if (RTEMS_RFS_S_ISCHR (mode))                                
40012240:	80 a5 40 02 	cmp  %l5, %g2                                  <== NOT EXECUTED
40012244:	02 80 00 12 	be  4001228c <rtems_rfs_inode_create+0x88>     <== NOT EXECUTED
40012248:	05 00 00 18 	sethi  %hi(0x6000), %g2                        <== NOT EXECUTED
      type = "char";                                                  
    else if (RTEMS_RFS_S_ISBLK (mode))                                
4001224c:	80 a5 40 02 	cmp  %l5, %g2                                  <== NOT EXECUTED
40012250:	02 80 00 12 	be  40012298 <rtems_rfs_inode_create+0x94>     <== NOT EXECUTED
40012254:	05 00 00 20 	sethi  %hi(0x8000), %g2                        <== NOT EXECUTED
      type = "block";                                                 
    else if (RTEMS_RFS_S_ISREG (mode))                                
40012258:	80 a5 40 02 	cmp  %l5, %g2                                  <== NOT EXECUTED
4001225c:	02 80 00 12 	be  400122a4 <rtems_rfs_inode_create+0xa0>     <== NOT EXECUTED
40012260:	31 10 00 cf 	sethi  %hi(0x40033c00), %i0                    <== NOT EXECUTED
      type = "file";                                                  
    else if (RTEMS_RFS_S_ISLNK (mode))                                
40012264:	05 00 00 28 	sethi  %hi(0xa000), %g2                        <== NOT EXECUTED
40012268:	80 a5 40 02 	cmp  %l5, %g2                                  <== NOT EXECUTED
4001226c:	12 80 00 10 	bne  400122ac <rtems_rfs_inode_create+0xa8>    <== NOT EXECUTED
40012270:	b0 16 22 08 	or  %i0, 0x208, %i0                            <== NOT EXECUTED
      type = "link";                                                  
40012274:	31 10 00 cf 	sethi  %hi(0x40033c00), %i0                    <== NOT EXECUTED
40012278:	10 80 00 0d 	b  400122ac <rtems_rfs_inode_create+0xa8>      <== NOT EXECUTED
4001227c:	b0 16 22 10 	or  %i0, 0x210, %i0	! 40033e10 <_Semaphore_Translate_core_mutex_return_code_+0xc80><== NOT EXECUTED
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_CREATE))                 
  {                                                                   
    const char* type = "unknown";                                     
    int         c;                                                    
    if (RTEMS_RFS_S_ISDIR (mode))                                     
      type = "dir";                                                   
40012280:	31 10 00 cf 	sethi  %hi(0x40033c00), %i0                    <== NOT EXECUTED
40012284:	10 80 00 0a 	b  400122ac <rtems_rfs_inode_create+0xa8>      <== NOT EXECUTED
40012288:	b0 16 21 f0 	or  %i0, 0x1f0, %i0	! 40033df0 <_Semaphore_Translate_core_mutex_return_code_+0xc60><== NOT EXECUTED
    else if (RTEMS_RFS_S_ISCHR (mode))                                
      type = "char";                                                  
4001228c:	31 10 00 cf 	sethi  %hi(0x40033c00), %i0                    <== NOT EXECUTED
40012290:	10 80 00 07 	b  400122ac <rtems_rfs_inode_create+0xa8>      <== NOT EXECUTED
40012294:	b0 16 21 f8 	or  %i0, 0x1f8, %i0	! 40033df8 <_Semaphore_Translate_core_mutex_return_code_+0xc68><== NOT EXECUTED
    else if (RTEMS_RFS_S_ISBLK (mode))                                
      type = "block";                                                 
40012298:	31 10 00 ce 	sethi  %hi(0x40033800), %i0                    <== NOT EXECUTED
4001229c:	10 80 00 04 	b  400122ac <rtems_rfs_inode_create+0xa8>      <== NOT EXECUTED
400122a0:	b0 16 23 f0 	or  %i0, 0x3f0, %i0	! 40033bf0 <_Semaphore_Translate_core_mutex_return_code_+0xa60><== NOT EXECUTED
    else if (RTEMS_RFS_S_ISREG (mode))                                
      type = "file";                                                  
400122a4:	31 10 00 cf 	sethi  %hi(0x40033c00), %i0                    <== NOT EXECUTED
400122a8:	b0 16 22 00 	or  %i0, 0x200, %i0	! 40033e00 <_Semaphore_Translate_core_mutex_return_code_+0xc70><== NOT EXECUTED
    else if (RTEMS_RFS_S_ISLNK (mode))                                
      type = "link";                                                  
    printf("rtems-rfs: inode-create: parent:%" PRIu32 " name:", parent);
400122ac:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
400122b0:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
400122b4:	90 12 22 18 	or  %o0, 0x218, %o0                            <== NOT EXECUTED
400122b8:	40 00 3f f4 	call  40022288 <printf>                        <== NOT EXECUTED
400122bc:	a4 10 00 1a 	mov  %i2, %l2                                  <== NOT EXECUTED
400122c0:	ac 06 80 1b 	add  %i2, %i3, %l6                             <== NOT EXECUTED
    for (c = 0; c < length; c++)                                      
400122c4:	80 a4 80 16 	cmp  %l2, %l6                                  <== NOT EXECUTED
400122c8:	02 80 00 07 	be  400122e4 <rtems_rfs_inode_create+0xe0>     <== NOT EXECUTED
400122cc:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
      printf ("%c", name[c]);                                         
400122d0:	d0 4c 80 00 	ldsb  [ %l2 ], %o0                             <== NOT EXECUTED
400122d4:	40 00 40 53 	call  40022420 <putchar>                       <== NOT EXECUTED
400122d8:	a4 04 a0 01 	inc  %l2                                       <== NOT EXECUTED
    else if (RTEMS_RFS_S_ISREG (mode))                                
      type = "file";                                                  
    else if (RTEMS_RFS_S_ISLNK (mode))                                
      type = "link";                                                  
    printf("rtems-rfs: inode-create: parent:%" PRIu32 " name:", parent);
    for (c = 0; c < length; c++)                                      
400122dc:	10 bf ff fb 	b  400122c8 <rtems_rfs_inode_create+0xc4>      <== NOT EXECUTED
400122e0:	80 a4 80 16 	cmp  %l2, %l6                                  <== NOT EXECUTED
      printf ("%c", name[c]);                                         
    printf (" type:%s mode:%04x (%03o)\n", type, mode, mode & ((1 << 10) - 1));
400122e4:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
400122e8:	90 12 22 48 	or  %o0, 0x248, %o0                            <== NOT EXECUTED
400122ec:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
400122f0:	40 00 3f e6 	call  40022288 <printf>                        <== NOT EXECUTED
400122f4:	96 0f 23 ff 	and  %i4, 0x3ff, %o3                           <== NOT EXECUTED
  }                                                                   
                                                                      
  /*                                                                  
   * The file type is field within the mode. Check we have a sane mode set.
   */                                                                 
  switch (mode & RTEMS_RFS_S_IFMT)                                    
400122f8:	a5 2d 60 10 	sll  %l5, 0x10, %l2                            
400122fc:	05 00 00 18 	sethi  %hi(0x6000), %g2                        
40012300:	83 34 a0 10 	srl  %l2, 0x10, %g1                            
40012304:	80 a0 40 02 	cmp  %g1, %g2                                  
40012308:	02 80 00 11 	be  4001234c <rtems_rfs_inode_create+0x148>    <== NEVER TAKEN
4001230c:	90 10 00 10 	mov  %l0, %o0                                  
40012310:	18 80 00 07 	bgu  4001232c <rtems_rfs_inode_create+0x128>   
40012314:	05 00 00 08 	sethi  %hi(0x2000), %g2                        
40012318:	80 a0 40 02 	cmp  %g1, %g2                                  
4001231c:	02 80 00 0c 	be  4001234c <rtems_rfs_inode_create+0x148>    <== NEVER TAKEN
40012320:	05 00 00 10 	sethi  %hi(0x4000), %g2                        
40012324:	10 80 00 07 	b  40012340 <rtems_rfs_inode_create+0x13c>     
40012328:	80 a0 40 02 	cmp  %g1, %g2                                  
4001232c:	05 00 00 20 	sethi  %hi(0x8000), %g2                        
40012330:	80 a0 40 02 	cmp  %g1, %g2                                  
40012334:	02 80 00 05 	be  40012348 <rtems_rfs_inode_create+0x144>    
40012338:	05 00 00 28 	sethi  %hi(0xa000), %g2                        
4001233c:	80 a0 40 02 	cmp  %g1, %g2                                  
40012340:	12 80 00 1f 	bne  400123bc <rtems_rfs_inode_create+0x1b8>   <== NEVER TAKEN
40012344:	b0 10 20 16 	mov  0x16, %i0                                 
      break;                                                          
    default:                                                          
      return EINVAL;                                                  
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_alloc (fs, parent, ino);                       
40012348:	90 10 00 10 	mov  %l0, %o0                                  
4001234c:	92 10 00 19 	mov  %i1, %o1                                  
40012350:	7f ff fe 27 	call  40011bec <rtems_rfs_inode_alloc>         
40012354:	94 10 00 11 	mov  %l1, %o2                                  
  if (rc > 0)                                                         
40012358:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001235c:	14 80 00 18 	bg  400123bc <rtems_rfs_inode_create+0x1b8>    
40012360:	90 10 00 10 	mov  %l0, %o0                                  
    return rc;                                                        
                                                                      
  rc = rtems_rfs_inode_open (fs, *ino, &inode, true);                 
40012364:	d2 04 40 00 	ld  [ %l1 ], %o1                               
40012368:	94 07 bf d8 	add  %fp, -40, %o2                             
4001236c:	7f ff fe 5c 	call  40011cdc <rtems_rfs_inode_open>          
40012370:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
40012374:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40012378:	34 80 00 0f 	bg,a   400123b4 <rtems_rfs_inode_create+0x1b0> <== NEVER TAKEN
4001237c:	d2 04 40 00 	ld  [ %l1 ], %o1                               <== NOT EXECUTED
  {                                                                   
    rtems_rfs_inode_free (fs, *ino);                                  
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_initialise (&inode, links, mode, uid, gid);    
40012380:	90 07 bf d8 	add  %fp, -40, %o0                             
40012384:	92 10 00 1d 	mov  %i5, %o1                                  
40012388:	94 10 00 1c 	mov  %i4, %o2                                  
4001238c:	96 10 00 14 	mov  %l4, %o3                                  
40012390:	7f ff ff 49 	call  400120b4 <rtems_rfs_inode_initialise>    
40012394:	98 10 00 13 	mov  %l3, %o4                                  
  if (rc > 0)                                                         
40012398:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001239c:	04 80 00 0a 	ble  400123c4 <rtems_rfs_inode_create+0x1c0>   <== ALWAYS TAKEN
400123a0:	03 10 00 00 	sethi  %hi(0x40000000), %g1                    
  {                                                                   
    rtems_rfs_inode_close (fs, &inode);                               
400123a4:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
400123a8:	7f ff fe bf 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
400123ac:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
    rtems_rfs_inode_free (fs, *ino);                                  
400123b0:	d2 04 40 00 	ld  [ %l1 ], %o1                               <== NOT EXECUTED
400123b4:	7f ff fe 18 	call  40011c14 <rtems_rfs_inode_free>          <== NOT EXECUTED
400123b8:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    return rc;                                                        
400123bc:	81 c7 e0 08 	ret                                            
400123c0:	81 e8 00 00 	restore                                        
  /*                                                                  
   * 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))                                       
400123c4:	80 a4 80 01 	cmp  %l2, %g1                                  
400123c8:	12 80 00 17 	bne  40012424 <rtems_rfs_inode_create+0x220>   
400123cc:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    rc = rtems_rfs_dir_add_entry (fs, &inode, ".", 1, *ino);          
400123d0:	d8 04 40 00 	ld  [ %l1 ], %o4                               
400123d4:	92 07 bf d8 	add  %fp, -40, %o1                             
400123d8:	15 10 00 c7 	sethi  %hi(0x40031c00), %o2                    
400123dc:	96 10 20 01 	mov  1, %o3                                    
400123e0:	40 00 26 9a 	call  4001be48 <rtems_rfs_dir_add_entry>       
400123e4:	94 12 a0 10 	or  %o2, 0x10, %o2                             
    if (rc == 0)                                                      
400123e8:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400123ec:	12 80 00 0b 	bne  40012418 <rtems_rfs_inode_create+0x214>   <== NEVER TAKEN
400123f0:	80 a6 20 00 	cmp  %i0, 0                                    
      rc = rtems_rfs_dir_add_entry (fs, &inode, "..", 2, parent);     
400123f4:	90 10 00 10 	mov  %l0, %o0                                  
400123f8:	92 07 bf d8 	add  %fp, -40, %o1                             
400123fc:	15 10 00 c7 	sethi  %hi(0x40031c00), %o2                    
40012400:	96 10 20 02 	mov  2, %o3                                    
40012404:	94 12 a0 18 	or  %o2, 0x18, %o2                             
40012408:	40 00 26 90 	call  4001be48 <rtems_rfs_dir_add_entry>       
4001240c:	98 10 00 19 	mov  %i1, %o4                                  
40012410:	b0 10 00 08 	mov  %o0, %i0                                  
    if (rc > 0)                                                       
40012414:	80 a6 20 00 	cmp  %i0, 0                                    
40012418:	14 80 00 39 	bg  400124fc <rtems_rfs_inode_create+0x2f8>    <== NEVER TAKEN
4001241c:	90 10 00 10 	mov  %l0, %o0                                  
      rtems_rfs_inode_close (fs, &inode);                             
      return rc;                                                      
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);        
40012420:	90 10 00 10 	mov  %l0, %o0                                  
40012424:	92 10 00 19 	mov  %i1, %o1                                  
40012428:	94 07 bf b0 	add  %fp, -80, %o2                             
4001242c:	7f ff fe 2c 	call  40011cdc <rtems_rfs_inode_open>          
40012430:	96 10 20 01 	mov  1, %o3                                    
40012434:	b0 10 00 08 	mov  %o0, %i0                                  
  if (rc > 0)                                                         
40012438:	80 a6 20 00 	cmp  %i0, 0                                    
4001243c:	14 80 00 30 	bg  400124fc <rtems_rfs_inode_create+0x2f8>    <== NEVER TAKEN
40012440:	90 10 00 10 	mov  %l0, %o0                                  
    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);
40012444:	d8 04 40 00 	ld  [ %l1 ], %o4                               
40012448:	92 07 bf b0 	add  %fp, -80, %o1                             
4001244c:	94 10 00 1a 	mov  %i2, %o2                                  
40012450:	40 00 26 7e 	call  4001be48 <rtems_rfs_dir_add_entry>       
40012454:	96 10 00 1b 	mov  %i3, %o3                                  
  if (rc > 0)                                                         
40012458:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001245c:	04 80 00 0b 	ble  40012488 <rtems_rfs_inode_create+0x284>   <== ALWAYS TAKEN
40012460:	03 10 00 00 	sethi  %hi(0x40000000), %g1                    
  {                                                                   
    rtems_rfs_inode_delete (fs, &inode);                              
40012464:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
40012468:	7f ff fe b2 	call  40011f30 <rtems_rfs_inode_delete>        <== NOT EXECUTED
4001246c:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    rtems_rfs_inode_close (fs, &inode);                               
40012470:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
40012474:	7f ff fe 8c 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
40012478:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    rtems_rfs_inode_close (fs, &parent_inode);                        
4001247c:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
40012480:	10 80 00 2c 	b  40012530 <rtems_rfs_inode_create+0x32c>     <== NOT EXECUTED
40012484:	92 07 bf b0 	add  %fp, -80, %o1                             <== 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))                                       
40012488:	80 a4 80 01 	cmp  %l2, %g1                                  
4001248c:	12 80 00 15 	bne  400124e0 <rtems_rfs_inode_create+0x2dc>   
40012490:	90 07 bf b0 	add  %fp, -80, %o0                             
    rtems_rfs_inode_set_links (&parent_inode,                         
                               rtems_rfs_inode_get_links (&parent_inode) + 1);
40012494:	c2 07 bf bc 	ld  [ %fp + -68 ], %g1                         
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)                                                
40012498:	09 3f ff c0 	sethi  %hi(0xffff0000), %g4                    
 */                                                                   
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);                  
4001249c:	c6 08 60 01 	ldub  [ %g1 + 1 ], %g3                         
400124a0:	c4 08 40 00 	ldub  [ %g1 ], %g2                             
400124a4:	85 28 a0 08 	sll  %g2, 8, %g2                               
400124a8:	84 10 80 03 	or  %g2, %g3, %g2                              
  if (links == 0xffff)                                                
400124ac:	87 28 a0 10 	sll  %g2, 0x10, %g3                            
400124b0:	87 30 e0 10 	srl  %g3, 0x10, %g3                            
    links = 0;                                                        
400124b4:	86 39 00 03 	xnor  %g4, %g3, %g3                            
400124b8:	80 a0 00 03 	cmp  %g0, %g3                                  
400124bc:	86 60 20 00 	subx  %g0, 0, %g3                              
400124c0:	84 08 80 03 	and  %g2, %g3, %g2                             
  /*                                                                  
   * 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))                                       
    rtems_rfs_inode_set_links (&parent_inode,                         
400124c4:	84 00 a0 01 	inc  %g2                                       
 * @param[in] links are 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);                  
400124c8:	87 30 a0 08 	srl  %g2, 8, %g3                               
400124cc:	c6 28 40 00 	stb  %g3, [ %g1 ]                              
400124d0:	c2 07 bf bc 	ld  [ %fp + -68 ], %g1                         
400124d4:	c4 28 60 01 	stb  %g2, [ %g1 + 1 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
400124d8:	82 10 20 01 	mov  1, %g1                                    
400124dc:	c2 2f bf c0 	stb  %g1, [ %fp + -64 ]                        
                               rtems_rfs_inode_get_links (&parent_inode) + 1);
                                                                      
  /*                                                                  
   * Update the parent's mtime.                                       
   */                                                                 
  rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);    
400124e0:	92 10 20 01 	mov  1, %o1                                    
400124e4:	7f ff fe cb 	call  40012010 <rtems_rfs_inode_time_stamp_now>
400124e8:	94 10 20 01 	mov  1, %o2                                    
400124ec:	b0 10 00 08 	mov  %o0, %i0                                  
  if (rc > 0)                                                         
400124f0:	80 a6 20 00 	cmp  %i0, 0                                    
400124f4:	04 80 00 04 	ble  40012504 <rtems_rfs_inode_create+0x300>   <== ALWAYS TAKEN
400124f8:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    rtems_rfs_inode_delete (fs, &inode);                              
400124fc:	10 80 00 09 	b  40012520 <rtems_rfs_inode_create+0x31c>     <== NOT EXECUTED
40012500:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
    rtems_rfs_inode_close (fs, &inode);                               
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &parent_inode);                     
40012504:	7f ff fe 68 	call  40011ea4 <rtems_rfs_inode_close>         
40012508:	92 07 bf b0 	add  %fp, -80, %o1                             
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_inode_delete (fs, &inode);                              
4001250c:	92 07 bf d8 	add  %fp, -40, %o1                             
    rtems_rfs_inode_delete (fs, &inode);                              
    rtems_rfs_inode_close (fs, &inode);                               
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &parent_inode);                     
40012510:	b0 10 00 08 	mov  %o0, %i0                                  
  if (rc > 0)                                                         
40012514:	80 a6 20 00 	cmp  %i0, 0                                    
40012518:	04 80 00 0a 	ble  40012540 <rtems_rfs_inode_create+0x33c>   <== ALWAYS TAKEN
4001251c:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    rtems_rfs_inode_delete (fs, &inode);                              
40012520:	7f ff fe 84 	call  40011f30 <rtems_rfs_inode_delete>        <== NOT EXECUTED
40012524:	01 00 00 00 	nop                                            <== NOT EXECUTED
    rtems_rfs_inode_close (fs, &inode);                               
40012528:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001252c:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
40012530:	7f ff fe 5d 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
40012534:	01 00 00 00 	nop                                            <== NOT EXECUTED
    return rc;                                                        
40012538:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001253c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
40012540:	7f ff fe 59 	call  40011ea4 <rtems_rfs_inode_close>         
40012544:	b0 10 20 00 	clr  %i0                                       
  if (rc > 0)                                                         
40012548:	80 a2 20 00 	cmp  %o0, 0                                    
4001254c:	04 bf ff 9c 	ble  400123bc <rtems_rfs_inode_create+0x1b8>   <== ALWAYS TAKEN
40012550:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    rtems_rfs_inode_free (fs, *ino);                                  
40012554:	d2 04 40 00 	ld  [ %l1 ], %o1                               <== NOT EXECUTED
40012558:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001255c:	7f ff fd ae 	call  40011c14 <rtems_rfs_inode_free>          <== NOT EXECUTED
40012560:	b0 10 00 1d 	mov  %i5, %i0                                  <== NOT EXECUTED
    return rc;                                                        
40012564:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012568:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40011f30 <rtems_rfs_inode_delete>: } int rtems_rfs_inode_delete (rtems_rfs_file_system* fs, rtems_rfs_inode_handle* handle) {
40011f30:	9d e3 bf 50 	save  %sp, -176, %sp                           
  int rc = 0;                                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_DELETE))                 
40011f34:	90 10 20 00 	clr  %o0                                       
40011f38:	13 00 20 00 	sethi  %hi(0x800000), %o1                      
40011f3c:	40 00 05 c4 	call  4001364c <rtems_rfs_trace>               
40011f40:	ba 10 00 18 	mov  %i0, %i5                                  
40011f44:	80 a2 20 00 	cmp  %o0, 0                                    
40011f48:	02 80 00 0e 	be  40011f80 <rtems_rfs_inode_delete+0x50>     <== ALWAYS TAKEN
40011f4c:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
    printf("rtems-rfs: inode-delete: ino:%" PRIu32 " loaded:%s\n",    
40011f50:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40011f54:	02 80 00 05 	be  40011f68 <rtems_rfs_inode_delete+0x38>     <== NOT EXECUTED
40011f58:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
40011f5c:	15 10 00 cf 	sethi  %hi(0x40033c00), %o2                    <== NOT EXECUTED
40011f60:	10 80 00 04 	b  40011f70 <rtems_rfs_inode_delete+0x40>      <== NOT EXECUTED
40011f64:	94 12 a0 c8 	or  %o2, 0xc8, %o2	! 40033cc8 <_Semaphore_Translate_core_mutex_return_code_+0xb38><== NOT EXECUTED
40011f68:	15 10 00 c8 	sethi  %hi(0x40032000), %o2                    <== NOT EXECUTED
40011f6c:	94 12 a2 a0 	or  %o2, 0x2a0, %o2	! 400322a0 <__FUNCTION__.6501+0x238><== NOT EXECUTED
40011f70:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011f74:	40 00 40 c5 	call  40022288 <printf>                        <== NOT EXECUTED
40011f78:	90 12 21 c0 	or  %o0, 0x1c0, %o0	! 40033dc0 <_Semaphore_Translate_core_mutex_return_code_+0xc30><== NOT EXECUTED
           rtems_rfs_inode_ino (handle),                              
           rtems_rfs_inode_is_loaded (handle) ? "yes" : "no");        
                                                                      
  if (rtems_rfs_inode_is_loaded (handle))                             
40011f7c:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         <== NOT EXECUTED
40011f80:	80 a0 60 00 	cmp  %g1, 0                                    
40011f84:	02 80 00 21 	be  40012008 <rtems_rfs_inode_delete+0xd8>     <== NEVER TAKEN
40011f88:	b0 10 20 00 	clr  %i0                                       
    rtems_rfs_block_map map;                                          
                                                                      
    /*                                                                
     * Free the ino number.                                           
     */                                                               
    rc = rtems_rfs_inode_free (fs, handle->ino);                      
40011f8c:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           
40011f90:	7f ff ff 21 	call  40011c14 <rtems_rfs_inode_free>          
40011f94:	90 10 00 1d 	mov  %i5, %o0                                  
    if (rc > 0)                                                       
40011f98:	80 a2 20 00 	cmp  %o0, 0                                    
40011f9c:	14 80 00 1b 	bg  40012008 <rtems_rfs_inode_delete+0xd8>     <== NEVER TAKEN
40011fa0:	b0 10 00 08 	mov  %o0, %i0                                  
      return rc;                                                      
                                                                      
    /*                                                                
     * Free the blocks the inode may have attached.                   
     */                                                               
    rc = rtems_rfs_block_map_open (fs, handle, &map);                 
40011fa4:	90 10 00 1d 	mov  %i5, %o0                                  
40011fa8:	92 10 00 19 	mov  %i1, %o1                                  
40011fac:	40 00 20 b2 	call  4001a274 <rtems_rfs_block_map_open>      
40011fb0:	94 07 bf b0 	add  %fp, -80, %o2                             
    if (rc == 0)                                                      
40011fb4:	80 a2 20 00 	cmp  %o0, 0                                    
40011fb8:	32 80 00 14 	bne,a   40012008 <rtems_rfs_inode_delete+0xd8> <== NEVER TAKEN
40011fbc:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
    {                                                                 
      int rrc;                                                        
      rrc = rtems_rfs_block_map_free_all (fs, &map);                  
40011fc0:	92 07 bf b0 	add  %fp, -80, %o1                             
40011fc4:	40 00 23 b9 	call  4001aea8 <rtems_rfs_block_map_free_all>  
40011fc8:	90 10 00 1d 	mov  %i5, %o0                                  
      rc = rtems_rfs_block_map_close (fs, &map);                      
40011fcc:	92 07 bf b0 	add  %fp, -80, %o1                             
40011fd0:	40 00 21 07 	call  4001a3ec <rtems_rfs_block_map_close>     
40011fd4:	90 10 00 1d 	mov  %i5, %o0                                  
      if (rc > 0)                                                     
        rrc = rc;                                                     
      memset (handle->node, 0xff, RTEMS_RFS_INODE_SIZE);              
40011fd8:	d0 06 60 0c 	ld  [ %i1 + 0xc ], %o0                         
40011fdc:	92 10 20 ff 	mov  0xff, %o1                                 
40011fe0:	40 00 40 31 	call  400220a4 <memset>                        
40011fe4:	94 10 20 38 	mov  0x38, %o2                                 
      rtems_rfs_buffer_mark_dirty (&handle->buffer);                  
40011fe8:	82 10 20 01 	mov  1, %g1                                    
      /*                                                              
       * 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);     
40011fec:	90 10 00 1d 	mov  %i5, %o0                                  
      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);                  
40011ff0:	c2 2e 60 10 	stb  %g1, [ %i1 + 0x10 ]                       
      /*                                                              
       * 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);     
40011ff4:	40 00 24 11 	call  4001b038 <rtems_rfs_buffer_handle_release>
40011ff8:	92 06 60 10 	add  %i1, 0x10, %o1                            
      handle->loads = 0;                                              
40011ffc:	c0 26 60 24 	clr  [ %i1 + 0x24 ]                            
      handle->node = NULL;                                            
40012000:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
40012004:	b0 10 00 08 	mov  %o0, %i0                                  
    }                                                                 
  }                                                                   
  return rc;                                                          
}                                                                     
40012008:	81 c7 e0 08 	ret                                            
4001200c:	81 e8 00 00 	restore                                        
                                                                      

40011c28 <rtems_rfs_inode_load>: } int rtems_rfs_inode_load (rtems_rfs_file_system* fs, rtems_rfs_inode_handle* handle) {
40011c28:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_LOAD))                   
40011c2c:	90 10 20 00 	clr  %o0                                       
40011c30:	40 00 06 87 	call  4001364c <rtems_rfs_trace>               
40011c34:	13 00 04 00 	sethi  %hi(0x100000), %o1                      
40011c38:	80 a2 20 00 	cmp  %o0, 0                                    
40011c3c:	02 80 00 0f 	be  40011c78 <rtems_rfs_inode_load+0x50>       <== ALWAYS TAKEN
40011c40:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
    printf ("rtems-rfs: inode-load: ino=%" PRIu32 " loads=%i loaded=%s\n",
40011c44:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
40011c48:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40011c4c:	02 80 00 05 	be  40011c60 <rtems_rfs_inode_load+0x38>       <== NOT EXECUTED
40011c50:	d4 06 60 24 	ld  [ %i1 + 0x24 ], %o2                        <== NOT EXECUTED
40011c54:	17 10 00 cf 	sethi  %hi(0x40033c00), %o3                    <== NOT EXECUTED
40011c58:	10 80 00 04 	b  40011c68 <rtems_rfs_inode_load+0x40>        <== NOT EXECUTED
40011c5c:	96 12 e0 c8 	or  %o3, 0xc8, %o3	! 40033cc8 <_Semaphore_Translate_core_mutex_return_code_+0xb38><== NOT EXECUTED
40011c60:	17 10 00 c8 	sethi  %hi(0x40032000), %o3                    <== NOT EXECUTED
40011c64:	96 12 e2 a0 	or  %o3, 0x2a0, %o3	! 400322a0 <__FUNCTION__.6501+0x238><== NOT EXECUTED
40011c68:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011c6c:	40 00 41 87 	call  40022288 <printf>                        <== NOT EXECUTED
40011c70:	90 12 20 d0 	or  %o0, 0xd0, %o0	! 40033cd0 <_Semaphore_Translate_core_mutex_return_code_+0xb40><== NOT EXECUTED
                                                                      
  /*                                                                  
   * An inode does not move so once loaded no need to do again.       
   */                                                                 
                                                                      
  if (!rtems_rfs_inode_is_loaded (handle))                            
40011c74:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         <== NOT EXECUTED
40011c78:	80 a0 60 00 	cmp  %g1, 0                                    
40011c7c:	32 80 00 13 	bne,a   40011cc8 <rtems_rfs_inode_load+0xa0>   
40011c80:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
  {                                                                   
    int rc;                                                           
                                                                      
    rc = rtems_rfs_buffer_handle_request (fs,&handle->buffer,         
40011c84:	d4 06 60 1c 	ld  [ %i1 + 0x1c ], %o2                        
40011c88:	90 10 00 18 	mov  %i0, %o0                                  
40011c8c:	92 06 60 10 	add  %i1, 0x10, %o1                            
40011c90:	40 00 25 73 	call  4001b25c <rtems_rfs_buffer_handle_request>
40011c94:	96 10 20 01 	mov  1, %o3                                    
                                          handle->block, true);       
    if (rc > 0)                                                       
40011c98:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40011c9c:	14 80 00 0e 	bg  40011cd4 <rtems_rfs_inode_load+0xac>       <== NEVER TAKEN
40011ca0:	01 00 00 00 	nop                                            
      return rc;                                                      
                                                                      
    handle->node = rtems_rfs_buffer_data (&handle->buffer);           
40011ca4:	c4 06 60 18 	ld  [ %i1 + 0x18 ], %g2                        
    handle->node += handle->offset;                                   
40011ca8:	c2 06 60 20 	ld  [ %i1 + 0x20 ], %g1                        
40011cac:	c4 00 a0 1c 	ld  [ %g2 + 0x1c ], %g2                        
40011cb0:	87 28 60 03 	sll  %g1, 3, %g3                               
40011cb4:	83 28 60 06 	sll  %g1, 6, %g1                               
40011cb8:	82 20 40 03 	sub  %g1, %g3, %g1                             
40011cbc:	82 00 80 01 	add  %g2, %g1, %g1                             
40011cc0:	c2 26 60 0c 	st  %g1, [ %i1 + 0xc ]                         
  }                                                                   
                                                                      
  handle->loads++;                                                    
40011cc4:	c2 06 60 24 	ld  [ %i1 + 0x24 ], %g1                        
                                                                      
  return 0;                                                           
40011cc8:	b0 10 20 00 	clr  %i0                                       
                                                                      
    handle->node = rtems_rfs_buffer_data (&handle->buffer);           
    handle->node += handle->offset;                                   
  }                                                                   
                                                                      
  handle->loads++;                                                    
40011ccc:	82 00 60 01 	inc  %g1                                       
40011cd0:	c2 26 60 24 	st  %g1, [ %i1 + 0x24 ]                        
                                                                      
  return 0;                                                           
}                                                                     
40011cd4:	81 c7 e0 08 	ret                                            
40011cd8:	81 e8 00 00 	restore                                        
                                                                      

40011cdc <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) {
40011cdc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int group;                                                          
  int gino;                                                           
  int index;                                                          
  int rc;                                                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_OPEN))                   
40011ce0:	90 10 20 00 	clr  %o0                                       
40011ce4:	40 00 06 5a 	call  4001364c <rtems_rfs_trace>               
40011ce8:	13 00 01 00 	sethi  %hi(0x40000), %o1                       
40011cec:	80 a2 20 00 	cmp  %o0, 0                                    
40011cf0:	02 80 00 07 	be  40011d0c <rtems_rfs_inode_open+0x30>       <== ALWAYS TAKEN
40011cf4:	80 a6 60 00 	cmp  %i1, 0                                    
    printf ("rtems-rfs: inode-open: ino: %" PRIu32 "\n", ino);        
40011cf8:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011cfc:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
40011d00:	40 00 41 62 	call  40022288 <printf>                        <== NOT EXECUTED
40011d04:	90 12 21 08 	or  %o0, 0x108, %o0                            <== NOT EXECUTED
                                                                      
  if (ino == RTEMS_RFS_EMPTY_INO)                                     
40011d08:	80 a6 60 00 	cmp  %i1, 0                                    <== NOT EXECUTED
40011d0c:	02 80 00 28 	be  40011dac <rtems_rfs_inode_open+0xd0>       <== NEVER TAKEN
40011d10:	82 10 20 16 	mov  0x16, %g1                                 
    return EINVAL;                                                    
                                                                      
  if ((ino - RTEMS_RFS_ROOT_INO) > rtems_rfs_fs_inodes (fs))          
40011d14:	c4 06 20 14 	ld  [ %i0 + 0x14 ], %g2                        
40011d18:	ba 06 7f ff 	add  %i1, -1, %i5                              
40011d1c:	80 a7 40 02 	cmp  %i5, %g2                                  
40011d20:	18 80 00 23 	bgu  40011dac <rtems_rfs_inode_open+0xd0>      <== NEVER TAKEN
40011d24:	90 10 00 1d 	mov  %i5, %o0                                  
    return EINVAL;                                                    
                                                                      
  handle->ino = ino;                                                  
40011d28:	f2 26 a0 08 	st  %i1, [ %i2 + 8 ]                           
  handle->node = NULL;                                                
  handle->loads = 0;                                                  
                                                                      
  gino  = ino - RTEMS_RFS_ROOT_INO;                                   
  group = gino / fs->group_inodes;                                    
40011d2c:	f2 06 20 2c 	ld  [ %i0 + 0x2c ], %i1                        
  gino  = gino % fs->group_inodes;                                    
40011d30:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  if ((ino - RTEMS_RFS_ROOT_INO) > rtems_rfs_fs_inodes (fs))          
    return EINVAL;                                                    
                                                                      
  handle->ino = ino;                                                  
  handle->node = NULL;                                                
40011d34:	c0 26 a0 0c 	clr  [ %i2 + 0xc ]                             
  handle->loads = 0;                                                  
                                                                      
  gino  = ino - RTEMS_RFS_ROOT_INO;                                   
  group = gino / fs->group_inodes;                                    
  gino  = gino % fs->group_inodes;                                    
40011d38:	40 00 73 31 	call  4002e9fc <.urem>                         
40011d3c:	c0 26 a0 24 	clr  [ %i2 + 0x24 ]                            
  index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
40011d40:	f8 06 20 30 	ld  [ %i0 + 0x30 ], %i4                        
  handle->node = NULL;                                                
  handle->loads = 0;                                                  
                                                                      
  gino  = ino - RTEMS_RFS_ROOT_INO;                                   
  group = gino / fs->group_inodes;                                    
  gino  = gino % fs->group_inodes;                                    
40011d44:	a0 10 00 08 	mov  %o0, %l0                                  
  index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
                                                                      
  handle->offset = gino % fs->inodes_per_block;                       
40011d48:	40 00 73 2d 	call  4002e9fc <.urem>                         
40011d4c:	92 10 00 1c 	mov  %i4, %o1                                  
  handle->ino = ino;                                                  
  handle->node = NULL;                                                
  handle->loads = 0;                                                  
                                                                      
  gino  = ino - RTEMS_RFS_ROOT_INO;                                   
  group = gino / fs->group_inodes;                                    
40011d50:	92 10 00 19 	mov  %i1, %o1                                  
  gino  = gino % fs->group_inodes;                                    
  index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
                                                                      
  handle->offset = gino % fs->inodes_per_block;                       
40011d54:	d0 26 a0 20 	st  %o0, [ %i2 + 0x20 ]                        
  handle->ino = ino;                                                  
  handle->node = NULL;                                                
  handle->loads = 0;                                                  
                                                                      
  gino  = ino - RTEMS_RFS_ROOT_INO;                                   
  group = gino / fs->group_inodes;                                    
40011d58:	7f ff c2 3f 	call  40002654 <.udiv>                         
40011d5c:	90 10 00 1d 	mov  %i5, %o0                                  
  gino  = gino % fs->group_inodes;                                    
  index = (gino / fs->inodes_per_block) + RTEMS_RFS_GROUP_INODE_BLOCK;
                                                                      
  handle->offset = gino % fs->inodes_per_block;                       
  handle->block  = rtems_rfs_group_block (&fs->groups[group], index); 
40011d60:	c4 06 20 20 	ld  [ %i0 + 0x20 ], %g2                        
40011d64:	87 2a 20 04 	sll  %o0, 4, %g3                               
40011d68:	83 2a 20 06 	sll  %o0, 6, %g1                               
40011d6c:	82 00 c0 01 	add  %g3, %g1, %g1                             
  handle->loads = 0;                                                  
                                                                      
  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;
40011d70:	fa 00 80 01 	ld  [ %g2 + %g1 ], %i5                         
40011d74:	90 10 00 10 	mov  %l0, %o0                                  
40011d78:	ba 07 60 02 	add  %i5, 2, %i5                               
40011d7c:	7f ff c2 36 	call  40002654 <.udiv>                         
40011d80:	92 10 00 1c 	mov  %i4, %o1                                  
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
40011d84:	c0 2e a0 10 	clrb  [ %i2 + 0x10 ]                           
                                                                      
  handle->offset = gino % fs->inodes_per_block;                       
  handle->block  = rtems_rfs_group_block (&fs->groups[group], index); 
40011d88:	90 07 40 08 	add  %i5, %o0, %o0                             
  handle->bnum  = 0;                                                  
40011d8c:	c0 26 a0 14 	clr  [ %i2 + 0x14 ]                            
40011d90:	d0 26 a0 1c 	st  %o0, [ %i2 + 0x1c ]                        
  handle->buffer = NULL;                                              
40011d94:	c0 26 a0 18 	clr  [ %i2 + 0x18 ]                            
                                                                      
  rc = rtems_rfs_buffer_handle_open (fs, &handle->buffer);            
  if ((rc == 0) && load)                                              
40011d98:	80 a6 e0 00 	cmp  %i3, 0                                    
40011d9c:	02 80 00 04 	be  40011dac <rtems_rfs_inode_open+0xd0>       <== NEVER TAKEN
40011da0:	82 10 20 00 	clr  %g1                                       
    rc = rtems_rfs_inode_load (fs, handle);                           
40011da4:	7f ff ff a1 	call  40011c28 <rtems_rfs_inode_load>          
40011da8:	93 e8 00 1a 	restore  %g0, %i2, %o1                         
  return rc;                                                          
}                                                                     
40011dac:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40011db0:	91 e8 00 01 	restore  %g0, %g1, %o0                         <== NOT EXECUTED
                                                                      

40012010 <rtems_rfs_inode_time_stamp_now>: int rtems_rfs_inode_time_stamp_now (rtems_rfs_inode_handle* handle, bool atime, bool mtime) {
40012010:	9d e3 bf a0 	save  %sp, -96, %sp                            
  time_t now;                                                         
  if (!rtems_rfs_inode_is_loaded (handle))                            
40012014:	c2 06 20 0c 	ld  [ %i0 + 0xc ], %g1                         
                                                                      
int                                                                   
rtems_rfs_inode_time_stamp_now (rtems_rfs_inode_handle* handle,       
                                bool                    atime,        
                                bool                    mtime)        
{                                                                     
40012018:	ba 10 00 18 	mov  %i0, %i5                                  
  time_t now;                                                         
  if (!rtems_rfs_inode_is_loaded (handle))                            
4001201c:	80 a0 60 00 	cmp  %g1, 0                                    
40012020:	02 80 00 23 	be  400120ac <rtems_rfs_inode_time_stamp_now+0x9c><== NEVER TAKEN
40012024:	b0 10 20 06 	mov  6, %i0                                    
    return ENXIO;                                                     
  now = time (NULL);                                                  
40012028:	40 00 50 a9 	call  400262cc <time>                          
4001202c:	90 10 20 00 	clr  %o0                                       
  if (atime)                                                          
40012030:	80 a6 60 00 	cmp  %i1, 0                                    
40012034:	02 80 00 0f 	be  40012070 <rtems_rfs_inode_time_stamp_now+0x60><== NEVER TAKEN
40012038:	80 a6 a0 00 	cmp  %i2, 0                                    
 */                                                                   
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);                  
4001203c:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40012040:	85 32 20 18 	srl  %o0, 0x18, %g2                            
40012044:	c4 28 60 10 	stb  %g2, [ %g1 + 0x10 ]                       
40012048:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4001204c:	85 32 20 10 	srl  %o0, 0x10, %g2                            
40012050:	c4 28 60 11 	stb  %g2, [ %g1 + 0x11 ]                       
40012054:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40012058:	85 32 20 08 	srl  %o0, 8, %g2                               
4001205c:	c4 28 60 12 	stb  %g2, [ %g1 + 0x12 ]                       
40012060:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40012064:	d0 28 60 13 	stb  %o0, [ %g1 + 0x13 ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
40012068:	82 10 20 01 	mov  1, %g1                                    
4001206c:	c2 2f 60 10 	stb  %g1, [ %i5 + 0x10 ]                       
    rtems_rfs_inode_set_atime (handle, now);                          
  if (mtime)                                                          
40012070:	02 80 00 0f 	be  400120ac <rtems_rfs_inode_time_stamp_now+0x9c><== NEVER TAKEN
40012074:	b0 10 20 00 	clr  %i0                                       
 */                                                                   
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);                  
40012078:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
4001207c:	85 32 20 18 	srl  %o0, 0x18, %g2                            
40012080:	c4 28 60 14 	stb  %g2, [ %g1 + 0x14 ]                       
40012084:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40012088:	85 32 20 10 	srl  %o0, 0x10, %g2                            
4001208c:	c4 28 60 15 	stb  %g2, [ %g1 + 0x15 ]                       
40012090:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40012094:	85 32 20 08 	srl  %o0, 8, %g2                               
40012098:	c4 28 60 16 	stb  %g2, [ %g1 + 0x16 ]                       
4001209c:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
400120a0:	d0 28 60 17 	stb  %o0, [ %g1 + 0x17 ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
400120a4:	82 10 20 01 	mov  1, %g1                                    
400120a8:	c2 2f 60 10 	stb  %g1, [ %i5 + 0x10 ]                       
    rtems_rfs_inode_set_mtime (handle, now);                          
  return 0;                                                           
}                                                                     
400120ac:	81 c7 e0 08 	ret                                            
400120b0:	81 e8 00 00 	restore                                        
                                                                      

40011db4 <rtems_rfs_inode_unload>: int rtems_rfs_inode_unload (rtems_rfs_file_system* fs, rtems_rfs_inode_handle* handle, bool update_ctime) {
40011db4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int rc = 0;                                                         
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_INODE_UNLOAD))                 
40011db8:	90 10 20 00 	clr  %o0                                       
40011dbc:	40 00 06 24 	call  4001364c <rtems_rfs_trace>               
40011dc0:	13 00 08 00 	sethi  %hi(0x200000), %o1                      
40011dc4:	80 a2 20 00 	cmp  %o0, 0                                    
40011dc8:	02 80 00 0f 	be  40011e04 <rtems_rfs_inode_unload+0x50>     <== ALWAYS TAKEN
40011dcc:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
    printf ("rtems-rfs: inode-unload: ino=%" PRIu32 " loads=%i loaded=%s\n",
40011dd0:	d2 06 60 08 	ld  [ %i1 + 8 ], %o1                           <== NOT EXECUTED
40011dd4:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40011dd8:	02 80 00 05 	be  40011dec <rtems_rfs_inode_unload+0x38>     <== NOT EXECUTED
40011ddc:	d4 06 60 24 	ld  [ %i1 + 0x24 ], %o2                        <== NOT EXECUTED
40011de0:	17 10 00 cf 	sethi  %hi(0x40033c00), %o3                    <== NOT EXECUTED
40011de4:	10 80 00 04 	b  40011df4 <rtems_rfs_inode_unload+0x40>      <== NOT EXECUTED
40011de8:	96 12 e0 c8 	or  %o3, 0xc8, %o3	! 40033cc8 <_Semaphore_Translate_core_mutex_return_code_+0xb38><== NOT EXECUTED
40011dec:	17 10 00 c8 	sethi  %hi(0x40032000), %o3                    <== NOT EXECUTED
40011df0:	96 12 e2 a0 	or  %o3, 0x2a0, %o3	! 400322a0 <__FUNCTION__.6501+0x238><== NOT EXECUTED
40011df4:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40011df8:	40 00 41 24 	call  40022288 <printf>                        <== NOT EXECUTED
40011dfc:	90 12 21 30 	or  %o0, 0x130, %o0	! 40033d30 <_Semaphore_Translate_core_mutex_return_code_+0xba0><== NOT EXECUTED
            handle->ino, handle->loads,                               
            rtems_rfs_inode_is_loaded (handle) ? "yes" : "no");       
                                                                      
  if (rtems_rfs_inode_is_loaded (handle))                             
40011e00:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         <== NOT EXECUTED
40011e04:	80 a0 60 00 	cmp  %g1, 0                                    
40011e08:	32 80 00 04 	bne,a   40011e18 <rtems_rfs_inode_unload+0x64> 
40011e0c:	c4 06 60 24 	ld  [ %i1 + 0x24 ], %g2                        
int                                                                   
rtems_rfs_inode_unload (rtems_rfs_file_system*  fs,                   
                        rtems_rfs_inode_handle* handle,               
                        bool                    update_ctime)         
{                                                                     
  int rc = 0;                                                         
40011e10:	10 80 00 23 	b  40011e9c <rtems_rfs_inode_unload+0xe8>      
40011e14:	90 10 20 00 	clr  %o0                                       
            handle->ino, handle->loads,                               
            rtems_rfs_inode_is_loaded (handle) ? "yes" : "no");       
                                                                      
  if (rtems_rfs_inode_is_loaded (handle))                             
  {                                                                   
    if (handle->loads == 0)                                           
40011e18:	80 a0 a0 00 	cmp  %g2, 0                                    
40011e1c:	02 80 00 20 	be  40011e9c <rtems_rfs_inode_unload+0xe8>     <== NEVER TAKEN
40011e20:	90 10 20 05 	mov  5, %o0                                    
      return EIO;                                                     
                                                                      
    handle->loads--;                                                  
40011e24:	82 00 bf ff 	add  %g2, -1, %g1                              
                                                                      
    if (handle->loads == 0)                                           
40011e28:	80 a0 60 00 	cmp  %g1, 0                                    
40011e2c:	12 bf ff f9 	bne  40011e10 <rtems_rfs_inode_unload+0x5c>    
40011e30:	c2 26 60 24 	st  %g1, [ %i1 + 0x24 ]                        
    {                                                                 
      /*                                                              
       * If the buffer is dirty it will be release. Also set the ctime.
       */                                                             
      if (rtems_rfs_buffer_dirty (&handle->buffer) && update_ctime)   
40011e34:	c2 0e 60 10 	ldub  [ %i1 + 0x10 ], %g1                      
40011e38:	80 a0 60 00 	cmp  %g1, 0                                    
40011e3c:	02 80 00 15 	be  40011e90 <rtems_rfs_inode_unload+0xdc>     
40011e40:	90 10 00 18 	mov  %i0, %o0                                  
40011e44:	80 a6 a0 00 	cmp  %i2, 0                                    
40011e48:	02 80 00 12 	be  40011e90 <rtems_rfs_inode_unload+0xdc>     <== NEVER TAKEN
40011e4c:	01 00 00 00 	nop                                            
        rtems_rfs_inode_set_ctime (handle, time (NULL));              
40011e50:	40 00 51 1f 	call  400262cc <time>                          
40011e54:	90 10 20 00 	clr  %o0	! 0 <_TLS_BSS_size>                   
 */                                                                   
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);                  
40011e58:	c4 06 60 0c 	ld  [ %i1 + 0xc ], %g2                         
40011e5c:	87 32 20 18 	srl  %o0, 0x18, %g3                            
40011e60:	c6 28 a0 18 	stb  %g3, [ %g2 + 0x18 ]                       
40011e64:	c4 06 60 0c 	ld  [ %i1 + 0xc ], %g2                         
40011e68:	87 32 20 10 	srl  %o0, 0x10, %g3                            
40011e6c:	c6 28 a0 19 	stb  %g3, [ %g2 + 0x19 ]                       
40011e70:	c4 06 60 0c 	ld  [ %i1 + 0xc ], %g2                         
40011e74:	87 32 20 08 	srl  %o0, 8, %g3                               
40011e78:	c6 28 a0 1a 	stb  %g3, [ %g2 + 0x1a ]                       
40011e7c:	c4 06 60 0c 	ld  [ %i1 + 0xc ], %g2                         
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
40011e80:	82 10 20 01 	mov  1, %g1                                    
 */                                                                   
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);                  
40011e84:	d0 28 a0 1b 	stb  %o0, [ %g2 + 0x1b ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
40011e88:	c2 2e 60 10 	stb  %g1, [ %i1 + 0x10 ]                       
      rc = rtems_rfs_buffer_handle_release (fs, &handle->buffer);     
40011e8c:	90 10 00 18 	mov  %i0, %o0                                  
40011e90:	40 00 24 6a 	call  4001b038 <rtems_rfs_buffer_handle_release>
40011e94:	92 06 60 10 	add  %i1, 0x10, %o1                            
      handle->node = NULL;                                            
40011e98:	c0 26 60 0c 	clr  [ %i1 + 0xc ]                             
    }                                                                 
  }                                                                   
                                                                      
  return rc;                                                          
}                                                                     
40011e9c:	81 c7 e0 08 	ret                                            
40011ea0:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001e2ec <rtems_rfs_link>: const char* name, int length, rtems_rfs_ino parent, rtems_rfs_ino target, bool link_dir) {
4001e2ec:	9d e3 bf 50 	save  %sp, -176, %sp                           
  rtems_rfs_inode_handle parent_inode;                                
  rtems_rfs_inode_handle target_inode;                                
  uint16_t               links;                                       
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_LINK))                         
4001e2f0:	90 10 20 00 	clr  %o0                                       
4001e2f4:	13 00 40 00 	sethi  %hi(0x1000000), %o1                     
4001e2f8:	7f ff d4 d5 	call  4001364c <rtems_rfs_trace>               
4001e2fc:	a0 10 00 18 	mov  %i0, %l0                                  
4001e300:	80 a2 20 00 	cmp  %o0, 0                                    
4001e304:	02 80 00 13 	be  4001e350 <rtems_rfs_link+0x64>             <== ALWAYS TAKEN
4001e308:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: link: parent(%" PRIu32 ") -> ", parent);      
4001e30c:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e310:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001e314:	90 12 23 58 	or  %o0, 0x358, %o0                            <== NOT EXECUTED
4001e318:	40 00 0f dc 	call  40022288 <printf>                        <== NOT EXECUTED
4001e31c:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
    for (c = 0; c < length; c++)                                      
4001e320:	80 a6 00 1a 	cmp  %i0, %i2                                  <== NOT EXECUTED
4001e324:	16 80 00 07 	bge  4001e340 <rtems_rfs_link+0x54>            <== NOT EXECUTED
4001e328:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
      printf ("%c", name[c]);                                         
4001e32c:	d0 4e 40 18 	ldsb  [ %i1 + %i0 ], %o0                       <== NOT EXECUTED
4001e330:	40 00 10 3c 	call  40022420 <putchar>                       <== NOT EXECUTED
4001e334:	b0 06 20 01 	inc  %i0                                       <== NOT EXECUTED
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_LINK))                         
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: link: parent(%" PRIu32 ") -> ", parent);      
    for (c = 0; c < length; c++)                                      
4001e338:	10 bf ff fb 	b  4001e324 <rtems_rfs_link+0x38>              <== NOT EXECUTED
4001e33c:	80 a6 00 1a 	cmp  %i0, %i2                                  <== NOT EXECUTED
      printf ("%c", name[c]);                                         
    printf ("(%" PRIu32 ")\n", target);                               
4001e340:	92 10 00 1c 	mov  %i4, %o1                                  <== NOT EXECUTED
4001e344:	40 00 0f d1 	call  40022288 <printf>                        <== NOT EXECUTED
4001e348:	90 12 23 80 	or  %o0, 0x380, %o0                            <== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, target, &target_inode, true);        
4001e34c:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001e350:	92 10 00 1c 	mov  %i4, %o1                                  
4001e354:	94 07 bf d8 	add  %fp, -40, %o2                             
4001e358:	7f ff ce 61 	call  40011cdc <rtems_rfs_inode_open>          
4001e35c:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001e360:	80 a2 20 00 	cmp  %o0, 0                                    
4001e364:	12 80 00 4f 	bne  4001e4a0 <rtems_rfs_link+0x1b4>           <== NEVER TAKEN
4001e368:	80 a7 60 00 	cmp  %i5, 0                                    
                                                                      
  /*                                                                  
   * 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)))
4001e36c:	12 80 00 0f 	bne  4001e3a8 <rtems_rfs_link+0xbc>            <== NEVER TAKEN
4001e370:	90 10 00 10 	mov  %l0, %o0                                  
4001e374:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
4001e378:	c4 08 60 02 	ldub  [ %g1 + 2 ], %g2                         
4001e37c:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
4001e380:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001e384:	84 08 80 01 	and  %g2, %g1, %g2                             
4001e388:	03 00 00 10 	sethi  %hi(0x4000), %g1                        
4001e38c:	80 a0 80 01 	cmp  %g2, %g1                                  
4001e390:	12 80 00 07 	bne  4001e3ac <rtems_rfs_link+0xc0>            <== ALWAYS TAKEN
4001e394:	92 10 00 1b 	mov  %i3, %o1                                  
  {                                                                   
    rtems_rfs_inode_close (fs, &target_inode);                        
4001e398:	7f ff ce c3 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001e39c:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
    return ENOTSUP;                                                   
4001e3a0:	10 80 00 40 	b  4001e4a0 <rtems_rfs_link+0x1b4>             <== NOT EXECUTED
4001e3a4:	90 10 20 86 	mov  0x86, %o0                                 <== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);        
4001e3a8:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
4001e3ac:	94 07 bf b0 	add  %fp, -80, %o2                             
4001e3b0:	7f ff ce 4b 	call  40011cdc <rtems_rfs_inode_open>          
4001e3b4:	96 10 20 01 	mov  1, %o3                                    
4001e3b8:	ba 10 00 08 	mov  %o0, %i5                                  
  if (rc)                                                             
4001e3bc:	80 a7 60 00 	cmp  %i5, 0                                    
4001e3c0:	12 80 00 0e 	bne  4001e3f8 <rtems_rfs_link+0x10c>           <== NEVER TAKEN
4001e3c4:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    rtems_rfs_inode_close (fs, &target_inode);                        
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_dir_add_entry (fs, &parent_inode, name, length, target);
4001e3c8:	92 07 bf b0 	add  %fp, -80, %o1                             
4001e3cc:	94 10 00 19 	mov  %i1, %o2                                  
4001e3d0:	96 10 00 1a 	mov  %i2, %o3                                  
4001e3d4:	7f ff f6 9d 	call  4001be48 <rtems_rfs_dir_add_entry>       
4001e3d8:	98 10 00 1c 	mov  %i4, %o4                                  
  if (rc > 0)                                                         
4001e3dc:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001e3e0:	04 80 00 0b 	ble  4001e40c <rtems_rfs_link+0x120>           <== ALWAYS TAKEN
4001e3e4:	92 07 bf b0 	add  %fp, -80, %o1                             
  {                                                                   
    rtems_rfs_inode_close (fs, &parent_inode);                        
4001e3e8:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001e3ec:	7f ff ce ae 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001e3f0:	01 00 00 00 	nop                                            <== NOT EXECUTED
    rtems_rfs_inode_close (fs, &target_inode);                        
4001e3f4:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001e3f8:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
4001e3fc:	7f ff ce aa 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001e400:	01 00 00 00 	nop                                            <== NOT EXECUTED
    return rc;                                                        
4001e404:	10 80 00 27 	b  4001e4a0 <rtems_rfs_link+0x1b4>             <== NOT EXECUTED
4001e408:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  links = rtems_rfs_inode_get_links (&target_inode) + 1;              
4001e40c:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
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)                                                
4001e410:	09 3f ff c0 	sethi  %hi(0xffff0000), %g4                    
 */                                                                   
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);                  
4001e414:	c6 08 60 01 	ldub  [ %g1 + 1 ], %g3                         
4001e418:	c4 08 40 00 	ldub  [ %g1 ], %g2                             
  rtems_rfs_inode_set_links (&target_inode, links);                   
                                                                      
  rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);    
4001e41c:	92 10 20 01 	mov  1, %o1                                    
4001e420:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001e424:	84 10 80 03 	or  %g2, %g3, %g2                              
  if (links == 0xffff)                                                
4001e428:	87 28 a0 10 	sll  %g2, 0x10, %g3                            
4001e42c:	87 30 e0 10 	srl  %g3, 0x10, %g3                            
    links = 0;                                                        
4001e430:	86 39 00 03 	xnor  %g4, %g3, %g3                            
4001e434:	80 a0 00 03 	cmp  %g0, %g3                                  
4001e438:	86 60 20 00 	subx  %g0, 0, %g3                              
4001e43c:	84 08 80 03 	and  %g2, %g3, %g2                             
    rtems_rfs_inode_close (fs, &parent_inode);                        
    rtems_rfs_inode_close (fs, &target_inode);                        
    return rc;                                                        
  }                                                                   
                                                                      
  links = rtems_rfs_inode_get_links (&target_inode) + 1;              
4001e440:	84 00 a0 01 	inc  %g2                                       
 * @param[in] links are 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);                  
4001e444:	87 30 a0 08 	srl  %g2, 8, %g3                               
4001e448:	c6 28 40 00 	stb  %g3, [ %g1 ]                              
4001e44c:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  rtems_rfs_inode_set_links (&target_inode, links);                   
                                                                      
  rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);    
4001e450:	90 07 bf b0 	add  %fp, -80, %o0                             
4001e454:	c4 28 60 01 	stb  %g2, [ %g1 + 1 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001e458:	82 10 20 01 	mov  1, %g1                                    
4001e45c:	94 10 20 01 	mov  1, %o2                                    
4001e460:	7f ff ce ec 	call  40012010 <rtems_rfs_inode_time_stamp_now>
4001e464:	c2 2f bf e8 	stb  %g1, [ %fp + -24 ]                        
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_inode_close (fs, &parent_inode);                        
4001e468:	92 07 bf b0 	add  %fp, -80, %o1                             
  }                                                                   
                                                                      
  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);    
4001e46c:	ba 10 00 08 	mov  %o0, %i5                                  
  if (rc > 0)                                                         
4001e470:	80 a7 60 00 	cmp  %i5, 0                                    
4001e474:	14 bf ff de 	bg  4001e3ec <rtems_rfs_link+0x100>            <== NEVER TAKEN
4001e478:	90 10 00 10 	mov  %l0, %o0                                  
    rtems_rfs_inode_close (fs, &parent_inode);                        
    rtems_rfs_inode_close (fs, &target_inode);                        
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &parent_inode);                     
4001e47c:	7f ff ce 8a 	call  40011ea4 <rtems_rfs_inode_close>         
4001e480:	01 00 00 00 	nop                                            
  if (rc > 0)                                                         
  {                                                                   
    rtems_rfs_inode_close (fs, &target_inode);                        
4001e484:	92 07 bf d8 	add  %fp, -40, %o1                             
    rtems_rfs_inode_close (fs, &parent_inode);                        
    rtems_rfs_inode_close (fs, &target_inode);                        
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &parent_inode);                     
4001e488:	ba 10 00 08 	mov  %o0, %i5                                  
  if (rc > 0)                                                         
4001e48c:	80 a7 60 00 	cmp  %i5, 0                                    
4001e490:	14 bf ff db 	bg  4001e3fc <rtems_rfs_link+0x110>            <== NEVER TAKEN
4001e494:	90 10 00 10 	mov  %l0, %o0                                  
  {                                                                   
    rtems_rfs_inode_close (fs, &target_inode);                        
    return rc;                                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &target_inode);                     
4001e498:	7f ff ce 83 	call  40011ea4 <rtems_rfs_inode_close>         
4001e49c:	01 00 00 00 	nop                                            
                                                                      
  return rc;                                                          
}                                                                     
4001e4a0:	81 c7 e0 08 	ret                                            
4001e4a4:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001eca8 <rtems_rfs_mutex_create>: RTEMS_INHERIT_PRIORITY | RTEMS_NO_PRIORITY_CEILING | RTEMS_LOCAL) #endif int rtems_rfs_mutex_create (rtems_rfs_mutex* mutex) {
4001eca8:	9d e3 bf a0 	save  %sp, -96, %sp                            
#if __rtems__                                                         
  rtems_status_code sc;                                               
  sc = rtems_semaphore_create (rtems_build_name ('R', 'F', 'S', 'm'), 
4001ecac:	11 14 91 94 	sethi  %hi(0x52465000), %o0                    
4001ecb0:	98 10 00 18 	mov  %i0, %o4                                  
4001ecb4:	90 12 23 6d 	or  %o0, 0x36d, %o0                            
4001ecb8:	92 10 20 01 	mov  1, %o1                                    
4001ecbc:	94 10 20 54 	mov  0x54, %o2                                 
4001ecc0:	96 10 20 00 	clr  %o3                                       
4001ecc4:	7f ff b6 67 	call  4000c660 <rtems_semaphore_create>        
4001ecc8:	b0 10 20 00 	clr  %i0                                       
                               1, RTEMS_RFS_MUTEX_ATTRIBS, 0,         
                               mutex);                                
  if (sc != RTEMS_SUCCESSFUL)                                         
4001eccc:	80 a2 20 00 	cmp  %o0, 0                                    
4001ecd0:	02 80 00 0f 	be  4001ed0c <rtems_rfs_mutex_create+0x64>     <== ALWAYS TAKEN
4001ecd4:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
4001ecd8:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001ecdc:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
4001ece0:	7f ff d2 5b 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001ece4:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
4001ece8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ecec:	02 80 00 08 	be  4001ed0c <rtems_rfs_mutex_create+0x64>     <== NOT EXECUTED
4001ecf0:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: mutex: open failed: %s\n",                  
4001ecf4:	7f ff e4 9e 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
4001ecf8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001ecfc:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4001ed00:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001ed04:	40 00 0d 61 	call  40022288 <printf>                        <== NOT EXECUTED
4001ed08:	90 12 21 b0 	or  %o0, 0x1b0, %o0	! 40035db0 <CSWTCH.1+0x1660><== NOT EXECUTED
              rtems_status_text (sc));                                
    return EIO;                                                       
  }                                                                   
#endif                                                                
  return 0;                                                           
}                                                                     
4001ed0c:	81 c7 e0 08 	ret                                            
4001ed10:	81 e8 00 00 	restore                                        
                                                                      

4001ed14 <rtems_rfs_mutex_destroy>: int rtems_rfs_mutex_destroy (rtems_rfs_mutex* mutex) {
4001ed14:	9d e3 bf a0 	save  %sp, -96, %sp                            
#if __rtems__                                                         
  rtems_status_code sc;                                               
  sc = rtems_semaphore_delete (*mutex);                               
4001ed18:	d0 06 00 00 	ld  [ %i0 ], %o0                               
4001ed1c:	7f ff b6 cc 	call  4000c84c <rtems_semaphore_delete>        
4001ed20:	b0 10 20 00 	clr  %i0                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
4001ed24:	80 a2 20 00 	cmp  %o0, 0                                    
4001ed28:	02 80 00 0f 	be  4001ed64 <rtems_rfs_mutex_destroy+0x50>    <== ALWAYS TAKEN
4001ed2c:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
4001ed30:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001ed34:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
4001ed38:	7f ff d2 45 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001ed3c:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
4001ed40:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ed44:	02 80 00 08 	be  4001ed64 <rtems_rfs_mutex_destroy+0x50>    <== NOT EXECUTED
4001ed48:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: mutex: close failed: %s\n",                 
4001ed4c:	7f ff e4 88 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
4001ed50:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001ed54:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4001ed58:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001ed5c:	40 00 0d 4b 	call  40022288 <printf>                        <== NOT EXECUTED
4001ed60:	90 12 21 d8 	or  %o0, 0x1d8, %o0	! 40035dd8 <CSWTCH.1+0x1688><== NOT EXECUTED
              rtems_status_text (sc));                                
    return EIO;                                                       
  }                                                                   
#endif                                                                
  return 0;                                                           
}                                                                     
4001ed64:	81 c7 e0 08 	ret                                            
4001ed68:	81 e8 00 00 	restore                                        
                                                                      

4001f1f8 <rtems_rfs_mutex_lock.isra.0>: * * @retval 0 Successful operation. * @retval EIO An error occurred. */ static inline int rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
4001f1f8:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
#if __rtems__                                                         
  rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
4001f1fc:	92 10 20 00 	clr  %o1                                       
4001f200:	90 10 00 18 	mov  %i0, %o0                                  
4001f204:	94 10 20 00 	clr  %o2                                       
4001f208:	7f ff b5 c9 	call  4000c92c <rtems_semaphore_obtain>        
4001f20c:	b0 10 20 00 	clr  %i0                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
4001f210:	80 a2 20 00 	cmp  %o0, 0                                    
4001f214:	02 80 00 0f 	be  4001f250 <rtems_rfs_mutex_lock.isra.0+0x58><== ALWAYS TAKEN
4001f218:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
#if RTEMS_RFS_TRACE                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
4001f21c:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001f220:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
4001f224:	7f ff d1 0a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001f228:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
4001f22c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001f230:	02 80 00 08 	be  4001f250 <rtems_rfs_mutex_lock.isra.0+0x58><== NOT EXECUTED
4001f234:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: mutex: obtain failed: %s\n",                
4001f238:	7f ff e3 4d 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
4001f23c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001f240:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4001f244:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
4001f248:	40 00 0c 10 	call  40022288 <printf>                        <== NOT EXECUTED
4001f24c:	90 12 22 90 	or  %o0, 0x290, %o0	! 40033e90 <_Semaphore_Translate_core_mutex_return_code_+0xd00><== NOT EXECUTED
#endif                                                                
    return EIO;                                                       
  }                                                                   
#endif                                                                
  return 0;                                                           
}                                                                     
4001f250:	81 c7 e0 08 	ret                                            
4001f254:	81 e8 00 00 	restore                                        
                                                                      

4001ef8c <rtems_rfs_mutex_lock.isra.1>: * * @retval 0 Successful operation. * @retval EIO An error occurred. */ static inline int rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
4001ef8c:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
#if __rtems__                                                         
  rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
4001ef90:	92 10 20 00 	clr  %o1                                       
4001ef94:	90 10 00 18 	mov  %i0, %o0                                  
4001ef98:	94 10 20 00 	clr  %o2                                       
4001ef9c:	7f ff b6 64 	call  4000c92c <rtems_semaphore_obtain>        
4001efa0:	b0 10 20 00 	clr  %i0                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
4001efa4:	80 a2 20 00 	cmp  %o0, 0                                    
4001efa8:	02 80 00 0f 	be  4001efe4 <rtems_rfs_mutex_lock.isra.1+0x58><== ALWAYS TAKEN
4001efac:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
#if RTEMS_RFS_TRACE                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
4001efb0:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001efb4:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
4001efb8:	7f ff d1 a5 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001efbc:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
4001efc0:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001efc4:	02 80 00 08 	be  4001efe4 <rtems_rfs_mutex_lock.isra.1+0x58><== NOT EXECUTED
4001efc8:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: mutex: obtain failed: %s\n",                
4001efcc:	7f ff e3 e8 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
4001efd0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001efd4:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4001efd8:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
4001efdc:	40 00 0c ab 	call  40022288 <printf>                        <== NOT EXECUTED
4001efe0:	90 12 22 90 	or  %o0, 0x290, %o0	! 40033e90 <_Semaphore_Translate_core_mutex_return_code_+0xd00><== NOT EXECUTED
#endif                                                                
    return EIO;                                                       
  }                                                                   
#endif                                                                
  return 0;                                                           
}                                                                     
4001efe4:	81 c7 e0 08 	ret                                            
4001efe8:	81 e8 00 00 	restore                                        
                                                                      

40012c80 <rtems_rfs_mutex_lock.isra.20>: * * @retval 0 Successful operation. * @retval EIO An error occurred. */ static inline int rtems_rfs_mutex_lock (rtems_rfs_mutex* mutex)
40012c80:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
#if __rtems__                                                         
  rtems_status_code sc = rtems_semaphore_obtain (*mutex, RTEMS_WAIT, 0);
40012c84:	92 10 20 00 	clr  %o1                                       
40012c88:	90 10 00 18 	mov  %i0, %o0                                  
40012c8c:	94 10 20 00 	clr  %o2                                       
40012c90:	7f ff e7 27 	call  4000c92c <rtems_semaphore_obtain>        
40012c94:	b0 10 20 00 	clr  %i0                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
40012c98:	80 a2 20 00 	cmp  %o0, 0                                    
40012c9c:	02 80 00 0f 	be  40012cd8 <rtems_rfs_mutex_lock.isra.20+0x58><== ALWAYS TAKEN
40012ca0:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
#if RTEMS_RFS_TRACE                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
40012ca4:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
40012ca8:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
40012cac:	40 00 02 68 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
40012cb0:	b0 10 20 05 	mov  5, %i0                                    <== NOT EXECUTED
40012cb4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40012cb8:	02 80 00 08 	be  40012cd8 <rtems_rfs_mutex_lock.isra.20+0x58><== NOT EXECUTED
40012cbc:	01 00 00 00 	nop                                            <== NOT EXECUTED
      printf ("rtems-rfs: mutex: obtain failed: %s\n",                
40012cc0:	40 00 14 ab 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
40012cc4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40012cc8:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
40012ccc:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
40012cd0:	40 00 3d 6e 	call  40022288 <printf>                        <== NOT EXECUTED
40012cd4:	90 12 22 90 	or  %o0, 0x290, %o0	! 40033e90 <_Semaphore_Translate_core_mutex_return_code_+0xd00><== NOT EXECUTED
#endif                                                                
    return EIO;                                                       
  }                                                                   
#endif                                                                
  return 0;                                                           
}                                                                     
40012cd8:	81 c7 e0 08 	ret                                            
40012cdc:	81 e8 00 00 	restore                                        
                                                                      

4001afa8 <rtems_rfs_release_chain>: static int rtems_rfs_release_chain (rtems_chain_control* chain, uint32_t* count, bool modified) {
4001afa8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_buffer* buffer;                                           
  int               rrc = 0;                                          
  int               rc;                                               
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))                
4001afac:	90 10 20 00 	clr  %o0                                       
4001afb0:	92 10 20 80 	mov  0x80, %o1                                 
4001afb4:	7f ff e1 a6 	call  4001364c <rtems_rfs_trace>               
4001afb8:	ba 10 00 18 	mov  %i0, %i5                                  
4001afbc:	80 a2 20 00 	cmp  %o0, 0                                    
4001afc0:	02 80 00 07 	be  4001afdc <rtems_rfs_release_chain+0x34>    <== ALWAYS TAKEN
4001afc4:	b0 10 20 00 	clr  %i0                                       
    printf ("rtems-rfs: release-chain: count=%" PRIu32 "\n", *count); 
4001afc8:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
4001afcc:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001afd0:	40 00 1c ae 	call  40022288 <printf>                        <== NOT EXECUTED
4001afd4:	90 12 20 b8 	or  %o0, 0xb8, %o0	! 400348b8 <CSWTCH.1+0x168> <== NOT EXECUTED
    (*count)--;                                                       
                                                                      
    buffer->user = (void*) 0;                                         
                                                                      
    rc = rtems_rfs_buffer_io_release (buffer, modified);              
    if ((rc > 0) && (rrc == 0))                                       
4001afd8:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(                            
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_first( the_chain )                          
    == _Chain_Immutable_tail( the_chain );                            
4001afdc:	b8 07 60 04 	add  %i5, 4, %i4                               
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4001afe0:	d0 07 40 00 	ld  [ %i5 ], %o0                               
  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))                               
4001afe4:	80 a2 00 1c 	cmp  %o0, %i4                                  
4001afe8:	02 80 00 12 	be  4001b030 <rtems_rfs_release_chain+0x88>    
4001afec:	92 10 00 1a 	mov  %i2, %o1                                  
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  Chain_Node *head = _Chain_Head( the_chain );                        
  Chain_Node *old_first = head->next;                                 
  Chain_Node *new_first = old_first->next;                            
4001aff0:	c2 02 00 00 	ld  [ %o0 ], %g1                               
                                                                      
  head->next = new_first;                                             
4001aff4:	c2 27 40 00 	st  %g1, [ %i5 ]                               
  new_first->previous = head;                                         
4001aff8:	fa 20 60 04 	st  %i5, [ %g1 + 4 ]                           
  {                                                                   
    buffer = (rtems_rfs_buffer*) rtems_chain_get_unprotected (chain); 
    (*count)--;                                                       
4001affc:	c2 06 40 00 	ld  [ %i1 ], %g1                               
4001b000:	82 00 7f ff 	add  %g1, -1, %g1                              
4001b004:	c2 26 40 00 	st  %g1, [ %i1 ]                               
                                                                      
    buffer->user = (void*) 0;                                         
                                                                      
    rc = rtems_rfs_buffer_io_release (buffer, modified);              
4001b008:	40 00 16 8d 	call  40020a3c <rtems_rfs_buffer_bdbuf_release>
4001b00c:	c0 22 20 34 	clr  [ %o0 + 0x34 ]                            
    if ((rc > 0) && (rrc == 0))                                       
4001b010:	80 a2 20 00 	cmp  %o0, 0                                    
4001b014:	24 bf ff f4 	ble,a   4001afe4 <rtems_rfs_release_chain+0x3c><== ALWAYS TAKEN
4001b018:	d0 07 40 00 	ld  [ %i5 ], %o0                               
4001b01c:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
4001b020:	22 bf ff f0 	be,a   4001afe0 <rtems_rfs_release_chain+0x38> <== NOT EXECUTED
4001b024:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
 */                                                                   
RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first(        
  const Chain_Control *the_chain                                      
)                                                                     
{                                                                     
  return _Chain_Immutable_head( the_chain )->next;                    
4001b028:	10 bf ff ef 	b  4001afe4 <rtems_rfs_release_chain+0x3c>     <== NOT EXECUTED
4001b02c:	d0 07 40 00 	ld  [ %i5 ], %o0                               <== NOT EXECUTED
      rrc = rc;                                                       
  }                                                                   
  return rrc;                                                         
}                                                                     
4001b030:	81 c7 e0 08 	ret                                            
4001b034:	81 e8 00 00 	restore                                        
                                                                      

400129f4 <rtems_rfs_rtems_chown>: static int rtems_rfs_rtems_chown (const rtems_filesystem_location_info_t *pathloc, uid_t owner, gid_t group) {
400129f4:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
400129f8:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_CHOWN))            
    printf ("rtems-rfs-rtems: chown: in: ino:%" PRId32 " uid:%d gid:%d\n",
            ino, owner, group);                                       
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
400129fc:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
static int                                                            
rtems_rfs_rtems_chown (const rtems_filesystem_location_info_t *pathloc,
                       uid_t                                   owner, 
                       gid_t                                   group) 
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
40012a00:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_CHOWN))            
    printf ("rtems-rfs-rtems: chown: in: ino:%" PRId32 " uid:%d gid:%d\n",
            ino, owner, group);                                       
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012a04:	94 07 bf d8 	add  %fp, -40, %o2                             
40012a08:	90 10 00 1d 	mov  %i5, %o0                                  
40012a0c:	7f ff fc b4 	call  40011cdc <rtems_rfs_inode_open>          
40012a10:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
40012a14:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40012a18:	04 80 00 07 	ble  40012a34 <rtems_rfs_rtems_chown+0x40>     <== ALWAYS TAKEN
40012a1c:	01 00 00 00 	nop                                            
  {                                                                   
    return rtems_rfs_rtems_error ("chown: opening inode", rc);        
40012a20:	40 00 39 1f 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012a24:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
40012a28:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
40012a2c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012a30:	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();                                                    
40012a34:	40 00 0f 8f 	call  40016870 <geteuid>                       
40012a38:	01 00 00 00 	nop                                            
                                                                      
  if ((uid != rtems_rfs_inode_get_uid (&inode)) && (uid != 0))        
40012a3c:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
40012a40:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
 * @retval uid The used id.                                           
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;          
40012a44:	c6 08 60 07 	ldub  [ %g1 + 7 ], %g3                         
40012a48:	c4 08 60 06 	ldub  [ %g1 + 6 ], %g2                         
40012a4c:	85 28 a0 08 	sll  %g2, 8, %g2                               
40012a50:	84 10 80 03 	or  %g2, %g3, %g2                              
40012a54:	85 28 a0 10 	sll  %g2, 0x10, %g2                            
40012a58:	80 a0 80 08 	cmp  %g2, %o0                                  
40012a5c:	02 80 00 0e 	be  40012a94 <rtems_rfs_rtems_chown+0xa0>      <== ALWAYS TAKEN
40012a60:	87 32 20 10 	srl  %o0, 0x10, %g3                            
40012a64:	80 a0 e0 00 	cmp  %g3, 0                                    <== NOT EXECUTED
40012a68:	22 80 00 0c 	be,a   40012a98 <rtems_rfs_rtems_chown+0xa4>   <== NOT EXECUTED
40012a6c:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            <== NOT EXECUTED
  {                                                                   
    rtems_rfs_inode_close (fs, &inode);                               
40012a70:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
40012a74:	7f ff fd 0c 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
40012a78:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("chown: not able", EPERM);          
40012a7c:	40 00 39 08 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012a80:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012a84:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
40012a88:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40012a8c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012a90:	81 e8 00 00 	restore                                        <== 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);
40012a94:	b5 2e a0 10 	sll  %i2, 0x10, %i2                            
40012a98:	b4 16 40 1a 	or  %i1, %i2, %i2                              
40012a9c:	85 36 a0 18 	srl  %i2, 0x18, %g2                            
40012aa0:	c4 28 60 04 	stb  %g2, [ %g1 + 4 ]                          
40012aa4:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
40012aa8:	85 36 a0 10 	srl  %i2, 0x10, %g2                            
40012aac:	c4 28 60 05 	stb  %g2, [ %g1 + 5 ]                          
40012ab0:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
40012ab4:	b5 36 a0 08 	srl  %i2, 8, %i2                               
40012ab8:	f4 28 60 06 	stb  %i2, [ %g1 + 6 ]                          
40012abc:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  }                                                                   
#endif                                                                
                                                                      
  rtems_rfs_inode_set_uid_gid (&inode, owner, group);                 
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
40012ac0:	90 10 00 1d 	mov  %i5, %o0                                  
40012ac4:	f2 28 60 07 	stb  %i1, [ %g1 + 7 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
40012ac8:	82 10 20 01 	mov  1, %g1                                    
40012acc:	92 07 bf d8 	add  %fp, -40, %o1                             
40012ad0:	c2 2f bf e8 	stb  %g1, [ %fp + -24 ]                        
40012ad4:	7f ff fc f4 	call  40011ea4 <rtems_rfs_inode_close>         
40012ad8:	b0 10 20 00 	clr  %i0                                       
  if (rc)                                                             
40012adc:	80 a2 20 00 	cmp  %o0, 0                                    
40012ae0:	02 80 00 05 	be  40012af4 <rtems_rfs_rtems_chown+0x100>     <== ALWAYS TAKEN
40012ae4:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("chown: closing inode", rc);        
40012ae8:	40 00 38 ed 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012aec:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012af0:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40012af4:	81 c7 e0 08 	ret                                            
40012af8:	81 e8 00 00 	restore                                        
                                                                      

4001edb0 <rtems_rfs_rtems_device_close>: rtems_device_major_number major; rtems_device_minor_number minor; rtems_rfs_rtems_device_get_major_and_minor (iop, &major, &minor); return rtems_deviceio_close (iop, major, minor);
4001edb0:	d2 02 20 2c 	ld  [ %o0 + 0x2c ], %o1                        <== NOT EXECUTED
4001edb4:	d4 02 20 30 	ld  [ %o0 + 0x30 ], %o2                        <== NOT EXECUTED
4001edb8:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
4001edbc:	40 00 03 43 	call  4001fac8 <rtems_deviceio_close>          <== NOT EXECUTED
4001edc0:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                                                      

4001ed6c <rtems_rfs_rtems_device_ftruncate>: static int rtems_rfs_rtems_device_ftruncate (rtems_libio_t* iop, off_t length) { return 0; }
4001ed6c:	81 c3 e0 08 	retl                                           <== NOT EXECUTED
4001ed70:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
                                                                      

4001ed74 <rtems_rfs_rtems_device_ioctl>: rtems_device_major_number major; rtems_device_minor_number minor; rtems_rfs_rtems_device_get_major_and_minor (iop, &major, &minor); return rtems_deviceio_control (iop, command, buffer, major, minor);
4001ed74:	d6 02 20 2c 	ld  [ %o0 + 0x2c ], %o3                        <== NOT EXECUTED
4001ed78:	d8 02 20 30 	ld  [ %o0 + 0x30 ], %o4                        <== NOT EXECUTED
4001ed7c:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
4001ed80:	40 00 03 92 	call  4001fbc8 <rtems_deviceio_control>        <== NOT EXECUTED
4001ed84:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                                                      

4001ee18 <rtems_rfs_rtems_device_open>: static int rtems_rfs_rtems_device_open ( rtems_libio_t *iop, const char *pathname, int oflag, mode_t mode) {
4001ee18:	9d e3 bf 78 	save  %sp, -136, %sp                           <== NOT EXECUTED
  rtems_rfs_file_system*        fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
4001ee1c:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        <== NOT EXECUTED
  rtems_rfs_ino                 ino = rtems_rfs_rtems_get_iop_ino (iop);
4001ee20:	e0 06 20 1c 	ld  [ %i0 + 0x1c ], %l0                        <== NOT EXECUTED
rtems_rfs_rtems_device_open ( rtems_libio_t *iop,                     
                              const char    *pathname,                
                              int            oflag,                   
                              mode_t         mode)                    
{                                                                     
  rtems_rfs_file_system*        fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
4001ee24:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           <== 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);
4001ee28:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
 */                                                                   
static inline void                                                    
 rtems_rfs_rtems_lock (rtems_rfs_file_system* fs)                     
{                                                                     
  rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);            
  rtems_rfs_mutex_lock (&rtems->access);                              
4001ee2c:	c2 07 60 80 	ld  [ %i5 + 0x80 ], %g1                        <== NOT EXECUTED
4001ee30:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4001ee34:	7f ff b6 be 	call  4000c92c <rtems_semaphore_obtain>        <== NOT EXECUTED
4001ee38:	d0 00 40 00 	ld  [ %g1 ], %o0                               <== NOT EXECUTED
  if (sc != RTEMS_SUCCESSFUL)                                         
4001ee3c:	b8 92 20 00 	orcc  %o0, 0, %i4                              <== NOT EXECUTED
4001ee40:	02 80 00 0f 	be  4001ee7c <rtems_rfs_rtems_device_open+0x64><== NOT EXECUTED
4001ee44:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  {                                                                   
#if RTEMS_RFS_TRACE                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
4001ee48:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001ee4c:	7f ff d2 00 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001ee50:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
4001ee54:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001ee58:	22 80 00 09 	be,a   4001ee7c <rtems_rfs_rtems_device_open+0x64><== NOT EXECUTED
4001ee5c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: mutex: obtain failed: %s\n",                
4001ee60:	7f ff e4 43 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
4001ee64:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
4001ee68:	92 10 00 08 	mov  %o0, %o1                                  <== NOT EXECUTED
4001ee6c:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
4001ee70:	40 00 0d 06 	call  40022288 <printf>                        <== NOT EXECUTED
4001ee74:	90 12 22 90 	or  %o0, 0x290, %o0	! 40033e90 <_Semaphore_Translate_core_mutex_return_code_+0xd00><== NOT EXECUTED
  rtems_device_minor_number     minor;                                
  int                           rc;                                   
                                                                      
  rtems_rfs_rtems_lock (fs);                                          
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
4001ee78:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001ee7c:	92 10 00 10 	mov  %l0, %o1                                  <== NOT EXECUTED
4001ee80:	94 07 bf d8 	add  %fp, -40, %o2                             <== NOT EXECUTED
4001ee84:	7f ff cb 96 	call  40011cdc <rtems_rfs_inode_open>          <== NOT EXECUTED
4001ee88:	96 10 20 01 	mov  1, %o3                                    <== NOT EXECUTED
  if (rc > 0)                                                         
4001ee8c:	b8 92 20 00 	orcc  %o0, 0, %i4                              <== NOT EXECUTED
4001ee90:	04 80 00 09 	ble  4001eeb4 <rtems_rfs_rtems_device_open+0x9c><== NOT EXECUTED
4001ee94:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         <== NOT EXECUTED
  {                                                                   
    rtems_rfs_rtems_unlock (fs);                                      
4001ee98:	7f ff ff cb 	call  4001edc4 <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001ee9c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("device_open: opening inode", rc);  
4001eea0:	40 00 07 ff 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001eea4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001eea8:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
4001eeac:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001eeb0:	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);                            
4001eeb4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
 * @retval block 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]);      
4001eeb8:	f8 08 60 1c 	ldub  [ %g1 + 0x1c ], %i4                      <== NOT EXECUTED
4001eebc:	ee 08 60 1d 	ldub  [ %g1 + 0x1d ], %l7                      <== NOT EXECUTED
4001eec0:	ea 08 60 1e 	ldub  [ %g1 + 0x1e ], %l5                      <== NOT EXECUTED
4001eec4:	ec 08 60 1f 	ldub  [ %g1 + 0x1f ], %l6                      <== NOT EXECUTED
4001eec8:	e0 08 60 20 	ldub  [ %g1 + 0x20 ], %l0                      <== NOT EXECUTED
4001eecc:	e8 08 60 21 	ldub  [ %g1 + 0x21 ], %l4                      <== NOT EXECUTED
4001eed0:	e4 08 60 22 	ldub  [ %g1 + 0x22 ], %l2                      <== NOT EXECUTED
4001eed4:	e6 08 60 23 	ldub  [ %g1 + 0x23 ], %l3                      <== NOT EXECUTED
4001eed8:	7f ff cb f3 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001eedc:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
  if (rc > 0)                                                         
4001eee0:	a2 92 20 00 	orcc  %o0, 0, %l1                              <== NOT EXECUTED
4001eee4:	04 80 00 09 	ble  4001ef08 <rtems_rfs_rtems_device_open+0xf0><== NOT EXECUTED
4001eee8:	01 00 00 00 	nop                                            <== NOT EXECUTED
  {                                                                   
    rtems_rfs_rtems_unlock (fs);                                      
4001eeec:	7f ff ff b6 	call  4001edc4 <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001eef0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("device_open: closing inode", rc);  
4001eef4:	40 00 07 ea 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001eef8:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001eefc:	e2 22 00 00 	st  %l1, [ %o0 ]                               <== NOT EXECUTED
4001ef00:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001ef04:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
4001ef08:	7f ff ff af 	call  4001edc4 <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001ef0c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001ef10:	ac 0d a0 ff 	and  %l6, 0xff, %l6                            <== NOT EXECUTED
4001ef14:	a6 0c e0 ff 	and  %l3, 0xff, %l3                            <== NOT EXECUTED
                                                                      
  iop->data0 = major;                                                 
  iop->data1 = (void *) minor;                                        
                                                                      
  return rtems_deviceio_open (iop, pathname, oflag, mode, minor, major);
4001ef18:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001ef1c:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4001ef20:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
4001ef24:	96 10 00 1b 	mov  %i3, %o3                                  <== NOT EXECUTED
4001ef28:	b9 2f 20 18 	sll  %i4, 0x18, %i4                            <== NOT EXECUTED
4001ef2c:	ae 0d e0 ff 	and  %l7, 0xff, %l7                            <== NOT EXECUTED
4001ef30:	aa 0d 60 ff 	and  %l5, 0xff, %l5                            <== NOT EXECUTED
4001ef34:	af 2d e0 10 	sll  %l7, 0x10, %l7                            <== NOT EXECUTED
4001ef38:	ab 2d 60 08 	sll  %l5, 8, %l5                               <== NOT EXECUTED
4001ef3c:	b8 17 00 17 	or  %i4, %l7, %i4                              <== NOT EXECUTED
4001ef40:	a1 2c 20 18 	sll  %l0, 0x18, %l0                            <== NOT EXECUTED
4001ef44:	b8 17 00 16 	or  %i4, %l6, %i4                              <== NOT EXECUTED
4001ef48:	a8 0d 20 ff 	and  %l4, 0xff, %l4                            <== NOT EXECUTED
4001ef4c:	b8 17 00 15 	or  %i4, %l5, %i4                              <== NOT EXECUTED
4001ef50:	a9 2d 20 10 	sll  %l4, 0x10, %l4                            <== NOT EXECUTED
    return rtems_rfs_rtems_error ("device_open: closing inode", rc);  
  }                                                                   
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
                                                                      
  iop->data0 = major;                                                 
4001ef54:	f8 26 20 2c 	st  %i4, [ %i0 + 0x2c ]                        <== NOT EXECUTED
4001ef58:	a0 14 00 14 	or  %l0, %l4, %l0                              <== NOT EXECUTED
  iop->data1 = (void *) minor;                                        
                                                                      
  return rtems_deviceio_open (iop, pathname, oflag, mode, minor, major);
4001ef5c:	9a 10 00 1c 	mov  %i4, %o5                                  <== NOT EXECUTED
4001ef60:	a0 14 00 13 	or  %l0, %l3, %l0                              <== NOT EXECUTED
4001ef64:	a4 0c a0 ff 	and  %l2, 0xff, %l2                            <== NOT EXECUTED
4001ef68:	a5 2c a0 08 	sll  %l2, 8, %l2                               <== NOT EXECUTED
4001ef6c:	a0 14 00 12 	or  %l0, %l2, %l0                              <== NOT EXECUTED
  }                                                                   
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
                                                                      
  iop->data0 = major;                                                 
  iop->data1 = (void *) minor;                                        
4001ef70:	e0 26 20 30 	st  %l0, [ %i0 + 0x30 ]                        <== NOT EXECUTED
                                                                      
  return rtems_deviceio_open (iop, pathname, oflag, mode, minor, major);
4001ef74:	40 00 02 c8 	call  4001fa94 <rtems_deviceio_open>           <== NOT EXECUTED
4001ef78:	98 10 00 10 	mov  %l0, %o4                                  <== NOT EXECUTED
}                                                                     
4001ef7c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001ef80:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

4001ed9c <rtems_rfs_rtems_device_read>: rtems_device_major_number major; rtems_device_minor_number minor; rtems_rfs_rtems_device_get_major_and_minor (iop, &major, &minor); return rtems_deviceio_read (iop, buffer, count, major, minor);
4001ed9c:	d6 02 20 2c 	ld  [ %o0 + 0x2c ], %o3                        <== NOT EXECUTED
4001eda0:	d8 02 20 30 	ld  [ %o0 + 0x30 ], %o4                        <== NOT EXECUTED
4001eda4:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
4001eda8:	40 00 03 54 	call  4001faf8 <rtems_deviceio_read>           <== NOT EXECUTED
4001edac:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                                                      

4001ed88 <rtems_rfs_rtems_device_write>: rtems_device_major_number major; rtems_device_minor_number minor; rtems_rfs_rtems_device_get_major_and_minor (iop, &major, &minor); return rtems_deviceio_write (iop, buffer, count, major, minor);
4001ed88:	d6 02 20 2c 	ld  [ %o0 + 0x2c ], %o3                        <== NOT EXECUTED
4001ed8c:	d8 02 20 30 	ld  [ %o0 + 0x30 ], %o4                        <== NOT EXECUTED
4001ed90:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
4001ed94:	40 00 03 73 	call  4001fb60 <rtems_deviceio_write>          <== NOT EXECUTED
4001ed98:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                                                      

4001f040 <rtems_rfs_rtems_dir_open>: static int rtems_rfs_rtems_dir_open (rtems_libio_t* iop, const char* pathname, int oflag, mode_t mode) {
4001f040:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
4001f044:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
  rtems_rfs_ino          ino = rtems_rfs_rtems_get_iop_ino (iop);     
4001f048:	f8 06 20 1c 	ld  [ %i0 + 0x1c ], %i4                        
rtems_rfs_rtems_dir_open (rtems_libio_t* iop,                         
                          const char*    pathname,                    
                          int            oflag,                       
                          mode_t         mode)                        
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
4001f04c:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
 */                                                                   
static inline void                                                    
 rtems_rfs_rtems_lock (rtems_rfs_file_system* fs)                     
{                                                                     
  rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);            
  rtems_rfs_mutex_lock (&rtems->access);                              
4001f050:	c2 07 60 80 	ld  [ %i5 + 0x80 ], %g1                        
4001f054:	7f ff ff ce 	call  4001ef8c <rtems_rfs_mutex_lock.isra.1>   
4001f058:	d0 00 40 00 	ld  [ %g1 ], %o0                               
  rtems_rfs_inode_handle inode;                                       
  int                    rc;                                          
                                                                      
  rtems_rfs_rtems_lock (fs);                                          
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
4001f05c:	92 10 00 1c 	mov  %i4, %o1                                  
4001f060:	90 10 00 1d 	mov  %i5, %o0                                  
4001f064:	94 07 bf d8 	add  %fp, -40, %o2                             
4001f068:	7f ff cb 1d 	call  40011cdc <rtems_rfs_inode_open>          
4001f06c:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001f070:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001f074:	02 80 00 09 	be  4001f098 <rtems_rfs_rtems_dir_open+0x58>   <== ALWAYS TAKEN
4001f078:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  {                                                                   
    rtems_rfs_rtems_unlock (fs);                                      
4001f07c:	7f ff ff dc 	call  4001efec <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001f080:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("dir_open: opening inode", rc);     
4001f084:	40 00 07 86 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f088:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001f08c:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
4001f090:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001f094:	81 e8 00 00 	restore                                        <== NOT EXECUTED
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
4001f098:	c4 08 60 02 	ldub  [ %g1 + 2 ], %g2                         
  }                                                                   
                                                                      
  if (!RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&inode)))         
4001f09c:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
4001f0a0:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001f0a4:	84 08 80 01 	and  %g2, %g1, %g2                             
4001f0a8:	03 00 00 10 	sethi  %hi(0x4000), %g1                        
4001f0ac:	80 a0 80 01 	cmp  %g2, %g1                                  
4001f0b0:	02 80 00 0c 	be  4001f0e0 <rtems_rfs_rtems_dir_open+0xa0>   <== ALWAYS TAKEN
4001f0b4:	92 07 bf d8 	add  %fp, -40, %o1                             
  {                                                                   
    rtems_rfs_inode_close (fs, &inode);                               
4001f0b8:	7f ff cb 7b 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001f0bc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    rtems_rfs_rtems_unlock (fs);                                      
4001f0c0:	7f ff ff cb 	call  4001efec <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001f0c4:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("dir_open: not dir", ENOTDIR);      
4001f0c8:	40 00 07 75 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f0cc:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001f0d0:	82 10 20 14 	mov  0x14, %g1                                 <== NOT EXECUTED
4001f0d4:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
4001f0d8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001f0dc:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  iop->offset = 0;                                                    
4001f0e0:	c0 26 20 08 	clr  [ %i0 + 8 ]                               
4001f0e4:	c0 26 20 0c 	clr  [ %i0 + 0xc ]                             
                                                                      
  rtems_rfs_inode_close (fs, &inode);                                 
4001f0e8:	7f ff cb 6f 	call  40011ea4 <rtems_rfs_inode_close>         
4001f0ec:	90 10 00 1d 	mov  %i5, %o0                                  
  rtems_rfs_rtems_unlock (fs);                                        
4001f0f0:	90 10 00 1d 	mov  %i5, %o0                                  
4001f0f4:	7f ff ff be 	call  4001efec <rtems_rfs_rtems_unlock>        
4001f0f8:	b0 10 20 00 	clr  %i0                                       
  return 0;                                                           
}                                                                     
4001f0fc:	81 c7 e0 08 	ret                                            
4001f100:	81 e8 00 00 	restore                                        
                                                                      

4001f104 <rtems_rfs_rtems_dir_read>: */ static ssize_t rtems_rfs_rtems_dir_read (rtems_libio_t* iop, void* buffer, size_t count) {
4001f104:	9d e3 bf 70 	save  %sp, -144, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
4001f108:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
  rtems_rfs_ino          ino = rtems_rfs_rtems_get_iop_ino (iop);     
4001f10c:	f8 06 20 1c 	ld  [ %i0 + 0x1c ], %i4                        
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);
4001f110:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
4001f114:	c2 07 60 80 	ld  [ %i5 + 0x80 ], %g1                        
4001f118:	7f ff ff 9d 	call  4001ef8c <rtems_rfs_mutex_lock.isra.1>   
4001f11c:	d0 00 40 00 	ld  [ %g1 ], %o0                               
  count  = count / sizeof (struct dirent);                            
  dirent = buffer;                                                    
                                                                      
  rtems_rfs_rtems_lock (fs);                                          
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
4001f120:	92 10 00 1c 	mov  %i4, %o1                                  
4001f124:	90 10 00 1d 	mov  %i5, %o0                                  
4001f128:	94 07 bf d8 	add  %fp, -40, %o2                             
4001f12c:	7f ff ca ec 	call  40011cdc <rtems_rfs_inode_open>          
4001f130:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001f134:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001f138:	02 80 00 0a 	be  4001f160 <rtems_rfs_rtems_dir_read+0x5c>   <== ALWAYS TAKEN
4001f13c:	90 10 00 1a 	mov  %i2, %o0                                  
  {                                                                   
    rtems_rfs_rtems_unlock (fs);                                      
4001f140:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001f144:	7f ff ff aa 	call  4001efec <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001f148:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
    return rtems_rfs_rtems_error ("dir_read: read inode", rc);        
4001f14c:	40 00 07 54 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f150:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001f154:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
4001f158:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001f15c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  struct dirent*         dirent;                                      
  ssize_t                bytes_transferred;                           
  int                    d;                                           
  int                    rc;                                          
                                                                      
  count  = count / sizeof (struct dirent);                            
4001f160:	92 10 21 18 	mov  0x118, %o1                                
4001f164:	7f ff 8d 3c 	call  40002654 <.udiv>                         
4001f168:	b6 10 20 00 	clr  %i3                                       
4001f16c:	b8 10 20 00 	clr  %i4                                       
4001f170:	a0 10 00 08 	mov  %o0, %l0                                  
    return rtems_rfs_rtems_error ("dir_read: read inode", rc);        
  }                                                                   
                                                                      
  bytes_transferred = 0;                                              
                                                                      
  for (d = 0; d < count; d++, dirent++)                               
4001f174:	80 a6 c0 10 	cmp  %i3, %l0                                  
4001f178:	02 80 00 18 	be  4001f1d8 <rtems_rfs_rtems_dir_read+0xd4>   
4001f17c:	98 06 40 1c 	add  %i1, %i4, %o4                             
  {                                                                   
    size_t size;                                                      
    rc = rtems_rfs_dir_read (fs, &inode, iop->offset, dirent, &size); 
4001f180:	d4 1e 20 08 	ldd  [ %i0 + 8 ], %o2                          
4001f184:	90 10 00 1d 	mov  %i5, %o0                                  
4001f188:	92 07 bf d8 	add  %fp, -40, %o1                             
4001f18c:	7f ff f5 08 	call  4001c5ac <rtems_rfs_dir_read>            
4001f190:	9a 07 bf d4 	add  %fp, -44, %o5                             
    if (rc == ENOENT)                                                 
4001f194:	80 a2 20 02 	cmp  %o0, 2                                    
4001f198:	02 80 00 10 	be  4001f1d8 <rtems_rfs_rtems_dir_read+0xd4>   
4001f19c:	b4 10 00 08 	mov  %o0, %i2                                  
    {                                                                 
      rc = 0;                                                         
      break;                                                          
    }                                                                 
    if (rc > 0)                                                       
4001f1a0:	80 a2 20 00 	cmp  %o0, 0                                    
4001f1a4:	24 80 00 06 	ble,a   4001f1bc <rtems_rfs_rtems_dir_read+0xb8><== ALWAYS TAKEN
4001f1a8:	c4 1e 20 08 	ldd  [ %i0 + 8 ], %g2                          
    {                                                                 
      bytes_transferred = rtems_rfs_rtems_error ("dir_read: dir read", rc);
4001f1ac:	40 00 07 3c 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f1b0:	b8 10 3f ff 	mov  -1, %i4                                   <== NOT EXECUTED
4001f1b4:	10 80 00 09 	b  4001f1d8 <rtems_rfs_rtems_dir_read+0xd4>    <== NOT EXECUTED
4001f1b8:	f4 22 00 00 	st  %i2, [ %o0 ]                               <== NOT EXECUTED
      break;                                                          
    }                                                                 
    iop->offset += size;                                              
4001f1bc:	c2 07 bf d4 	ld  [ %fp + -44 ], %g1                         
4001f1c0:	b8 07 21 18 	add  %i4, 0x118, %i4                           
4001f1c4:	86 80 c0 01 	addcc  %g3, %g1, %g3                           
    return rtems_rfs_rtems_error ("dir_read: read inode", rc);        
  }                                                                   
                                                                      
  bytes_transferred = 0;                                              
                                                                      
  for (d = 0; d < count; d++, dirent++)                               
4001f1c8:	b6 06 e0 01 	inc  %i3                                       
    if (rc > 0)                                                       
    {                                                                 
      bytes_transferred = rtems_rfs_rtems_error ("dir_read: dir read", rc);
      break;                                                          
    }                                                                 
    iop->offset += size;                                              
4001f1cc:	84 40 a0 00 	addx  %g2, 0, %g2                              
4001f1d0:	10 bf ff e9 	b  4001f174 <rtems_rfs_rtems_dir_read+0x70>    
4001f1d4:	c4 3e 20 08 	std  %g2, [ %i0 + 8 ]                          
    bytes_transferred += sizeof (struct dirent);                      
  }                                                                   
                                                                      
  rtems_rfs_inode_close (fs, &inode);                                 
4001f1d8:	92 07 bf d8 	add  %fp, -40, %o1                             
4001f1dc:	7f ff cb 32 	call  40011ea4 <rtems_rfs_inode_close>         
4001f1e0:	90 10 00 1d 	mov  %i5, %o0                                  
  rtems_rfs_rtems_unlock (fs);                                        
4001f1e4:	90 10 00 1d 	mov  %i5, %o0                                  
4001f1e8:	7f ff ff 81 	call  4001efec <rtems_rfs_rtems_unlock>        
4001f1ec:	b0 10 00 1c 	mov  %i4, %i0                                  
                                                                      
  return bytes_transferred;                                           
}                                                                     
4001f1f0:	81 c7 e0 08 	ret                                            
4001f1f4:	81 e8 00 00 	restore                                        
                                                                      

40012b78 <rtems_rfs_rtems_eval_path>: .eval_token = rtems_rfs_rtems_eval_token }; static void rtems_rfs_rtems_eval_path (rtems_filesystem_eval_path_context_t *ctx) {
40012b78:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_filesystem_location_info_t *currentloc =                      
    rtems_filesystem_eval_path_get_currentloc (ctx);                  
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (currentloc);
40012b7c:	c2 06 20 2c 	ld  [ %i0 + 0x2c ], %g1                        
  rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (currentloc);   
  rtems_rfs_inode_handle inode;                                       
  int rc;                                                             
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012b80:	d2 06 20 20 	ld  [ %i0 + 0x20 ], %o1                        
static void                                                           
rtems_rfs_rtems_eval_path (rtems_filesystem_eval_path_context_t *ctx) 
{                                                                     
  rtems_filesystem_location_info_t *currentloc =                      
    rtems_filesystem_eval_path_get_currentloc (ctx);                  
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (currentloc);
40012b84:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
  rtems_rfs_ino ino = rtems_rfs_rtems_get_pathloc_ino (currentloc);   
  rtems_rfs_inode_handle inode;                                       
  int rc;                                                             
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012b88:	94 07 bf d8 	add  %fp, -40, %o2                             
40012b8c:	90 10 00 1d 	mov  %i5, %o0                                  
40012b90:	7f ff fc 53 	call  40011cdc <rtems_rfs_inode_open>          
40012b94:	96 10 20 01 	mov  1, %o3                                    
  if (rc == 0) {                                                      
40012b98:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40012b9c:	12 80 00 10 	bne  40012bdc <rtems_rfs_rtems_eval_path+0x64> <== NEVER TAKEN
40012ba0:	90 10 00 18 	mov  %i0, %o0                                  
    rtems_filesystem_eval_path_generic (                              
40012ba4:	92 07 bf d8 	add  %fp, -40, %o1                             
40012ba8:	15 10 00 cf 	sethi  %hi(0x40033c00), %o2                    
40012bac:	40 00 0f dc 	call  40016b1c <rtems_filesystem_eval_path_generic>
40012bb0:	94 12 a3 88 	or  %o2, 0x388, %o2	! 40033f88 <rtems_rfs_rtems_eval_config>
      ctx,                                                            
      &inode,                                                         
      &rtems_rfs_rtems_eval_config                                    
    );                                                                
    rc = rtems_rfs_inode_close (fs, &inode);                          
40012bb4:	90 10 00 1d 	mov  %i5, %o0                                  
40012bb8:	7f ff fc bb 	call  40011ea4 <rtems_rfs_inode_close>         
40012bbc:	92 07 bf d8 	add  %fp, -40, %o1                             
    if (rc != 0) {                                                    
40012bc0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40012bc4:	02 80 00 0c 	be  40012bf4 <rtems_rfs_rtems_eval_path+0x7c>  <== ALWAYS TAKEN
40012bc8:	01 00 00 00 	nop                                            
      rtems_filesystem_eval_path_error (                              
        ctx,                                                          
        rtems_rfs_rtems_error ("eval_path: closing inode", rc)        
40012bcc:	40 00 38 b4 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012bd0:	01 00 00 00 	nop                                            <== NOT EXECUTED
40012bd4:	10 80 00 05 	b  40012be8 <rtems_rfs_rtems_eval_path+0x70>   <== NOT EXECUTED
40012bd8:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
      );                                                              
    }                                                                 
  } else {                                                            
    rtems_filesystem_eval_path_error (                                
      ctx,                                                            
      rtems_rfs_rtems_error ("eval_path: opening inode", rc)          
40012bdc:	40 00 38 b0 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012be0:	01 00 00 00 	nop                                            <== NOT EXECUTED
40012be4:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
        ctx,                                                          
        rtems_rfs_rtems_error ("eval_path: closing inode", rc)        
      );                                                              
    }                                                                 
  } else {                                                            
    rtems_filesystem_eval_path_error (                                
40012be8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40012bec:	7f ff da 18 	call  4000944c <rtems_filesystem_eval_path_error><== NOT EXECUTED
40012bf0:	92 10 3f ff 	mov  -1, %o1                                   <== NOT EXECUTED
40012bf4:	81 c7 e0 08 	ret                                            
40012bf8:	81 e8 00 00 	restore                                        
                                                                      

40012ee0 <rtems_rfs_rtems_eval_token>: rtems_filesystem_eval_path_context_t *ctx, void *arg, const char *token, size_t tokenlen ) {
40012ee0:	9d e3 bf 90 	save  %sp, -112, %sp                           
#include "rtems-rfs-rtems.h"                                          
                                                                      
static bool                                                           
rtems_rfs_rtems_eval_perms (rtems_filesystem_eval_path_context_t *ctx,
                            int eval_flags,                           
                            rtems_rfs_inode_handle* inode)            
40012ee4:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
{                                                                     
  return rtems_filesystem_eval_path_check_access(                     
40012ee8:	90 10 00 18 	mov  %i0, %o0                                  
 * @retval uid The used id.                                           
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;          
40012eec:	c6 08 60 06 	ldub  [ %g1 + 6 ], %g3                         
40012ef0:	d6 08 60 07 	ldub  [ %g1 + 7 ], %o3                         
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
40012ef4:	c4 08 60 02 	ldub  [ %g1 + 2 ], %g2                         
40012ef8:	d4 08 60 03 	ldub  [ %g1 + 3 ], %o2                         
 * @retval gid The grpup id.                                          
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_gid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return (rtems_rfs_read_u32 (&handle->node->owner) >> 16) & 0xffff;  
40012efc:	d8 08 60 04 	ldub  [ %g1 + 4 ], %o4                         
40012f00:	c2 08 60 05 	ldub  [ %g1 + 5 ], %g1                         
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
40012f04:	85 28 a0 08 	sll  %g2, 8, %g2                               
 * @retval uid The used id.                                           
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;          
40012f08:	87 28 e0 08 	sll  %g3, 8, %g3                               
 * @retval gid The grpup id.                                          
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_gid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return (rtems_rfs_read_u32 (&handle->node->owner) >> 16) & 0xffff;  
40012f0c:	83 28 60 10 	sll  %g1, 0x10, %g1                            
 * @retval uid The used id.                                           
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;          
40012f10:	96 10 c0 0b 	or  %g3, %o3, %o3                              
  rtems_filesystem_eval_path_context_t *ctx,                          
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
40012f14:	ba 10 00 18 	mov  %i0, %i5                                  
static bool                                                           
rtems_rfs_rtems_eval_perms (rtems_filesystem_eval_path_context_t *ctx,
                            int eval_flags,                           
                            rtems_rfs_inode_handle* inode)            
{                                                                     
  return rtems_filesystem_eval_path_check_access(                     
40012f18:	97 2a e0 10 	sll  %o3, 0x10, %o3                            
 * @retval gid The grpup id.                                          
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_gid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return (rtems_rfs_read_u32 (&handle->node->owner) >> 16) & 0xffff;  
40012f1c:	99 2b 20 18 	sll  %o4, 0x18, %o4                            
40012f20:	92 10 20 01 	mov  1, %o1                                    
40012f24:	98 13 00 01 	or  %o4, %g1, %o4                              
40012f28:	94 12 80 02 	or  %o2, %g2, %o2                              
40012f2c:	97 32 e0 10 	srl  %o3, 0x10, %o3                            
40012f30:	99 33 20 10 	srl  %o4, 0x10, %o4                            
40012f34:	40 00 0e ed 	call  40016ae8 <rtems_filesystem_eval_path_check_access>
40012f38:	b0 10 20 01 	mov  1, %i0                                    
  rtems_filesystem_eval_path_generic_status status =                  
    RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_DONE;                          
  rtems_rfs_inode_handle* inode = arg;                                
  bool access_ok = rtems_rfs_rtems_eval_perms (ctx, RTEMS_FS_PERMS_EXEC, inode);
                                                                      
  if (access_ok) {                                                    
40012f3c:	80 a2 20 00 	cmp  %o0, 0                                    
40012f40:	02 80 00 6d 	be  400130f4 <rtems_rfs_rtems_eval_token+0x214>
40012f44:	80 a6 e0 01 	cmp  %i3, 1                                    
static inline bool rtems_filesystem_is_current_directory(             
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  return tokenlen == 1 && token [0] == '.';                           
40012f48:	12 80 00 06 	bne  40012f60 <rtems_rfs_rtems_eval_token+0x80>
40012f4c:	82 10 20 00 	clr  %g1                                       
40012f50:	c2 4e 80 00 	ldsb  [ %i2 ], %g1                             
40012f54:	82 18 60 2e 	xor  %g1, 0x2e, %g1                            
40012f58:	80 a0 00 01 	cmp  %g0, %g1                                  
40012f5c:	82 60 3f ff 	subx  %g0, -1, %g1                             
    if (rtems_filesystem_is_current_directory (token, tokenlen)) {    
40012f60:	80 a0 60 00 	cmp  %g1, 0                                    
40012f64:	22 80 00 04 	be,a   40012f74 <rtems_rfs_rtems_eval_token+0x94>
40012f68:	c2 07 60 2c 	ld  [ %i5 + 0x2c ], %g1                        
                                                                      
static inline void rtems_filesystem_eval_path_clear_token(            
  rtems_filesystem_eval_path_context_t *ctx                           
)                                                                     
{                                                                     
  ctx->tokenlen = 0;                                                  
40012f6c:	10 80 00 43 	b  40013078 <rtems_rfs_rtems_eval_token+0x198> 
40012f70:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
      rtems_filesystem_location_info_t *currentloc =                  
        rtems_filesystem_eval_path_get_currentloc( ctx );             
      rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (currentloc);
      rtems_rfs_ino entry_ino;                                        
      uint32_t entry_doff;                                            
      int rc = rtems_rfs_dir_lookup_ino (                             
40012f74:	92 10 00 19 	mov  %i1, %o1                                  
    if (rtems_filesystem_is_current_directory (token, tokenlen)) {    
      rtems_filesystem_eval_path_clear_token (ctx);                   
    } else {                                                          
      rtems_filesystem_location_info_t *currentloc =                  
        rtems_filesystem_eval_path_get_currentloc( ctx );             
      rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (currentloc);
40012f78:	f8 00 60 08 	ld  [ %g1 + 8 ], %i4                           
      rtems_rfs_ino entry_ino;                                        
      uint32_t entry_doff;                                            
      int rc = rtems_rfs_dir_lookup_ino (                             
40012f7c:	94 10 00 1a 	mov  %i2, %o2                                  
40012f80:	90 10 00 1c 	mov  %i4, %o0                                  
40012f84:	96 10 00 1b 	mov  %i3, %o3                                  
40012f88:	98 07 bf f4 	add  %fp, -12, %o4                             
40012f8c:	9a 07 bf f8 	add  %fp, -8, %o5                              
40012f90:	40 00 22 74 	call  4001b960 <rtems_rfs_dir_lookup_ino>      
40012f94:	b0 10 20 02 	mov  2, %i0                                    
        tokenlen,                                                     
        &entry_ino,                                                   
        &entry_doff                                                   
      );                                                              
                                                                      
      if (rc == 0) {                                                  
40012f98:	80 a2 20 00 	cmp  %o0, 0                                    
40012f9c:	12 80 00 56 	bne  400130f4 <rtems_rfs_rtems_eval_token+0x214>
40012fa0:	90 10 00 1c 	mov  %i4, %o0                                  
        rc = rtems_rfs_inode_close (fs, inode);                       
40012fa4:	7f ff fb c0 	call  40011ea4 <rtems_rfs_inode_close>         
40012fa8:	92 10 00 19 	mov  %i1, %o1                                  
        if (rc == 0) {                                                
40012fac:	80 a2 20 00 	cmp  %o0, 0                                    
40012fb0:	02 80 00 08 	be  40012fd0 <rtems_rfs_rtems_eval_token+0xf0> <== ALWAYS TAKEN
40012fb4:	d2 07 bf f4 	ld  [ %fp + -12 ], %o1                         
        if (rc != 0) {                                                
          /*                                                          
           * This prevents the rtems_rfs_inode_close() from doing something in
           * rtems_rfs_rtems_eval_path().                             
           */                                                         
          memset (inode, 0, sizeof(*inode));                          
40012fb8:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40012fbc:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
40012fc0:	40 00 3c 39 	call  400220a4 <memset>                        <== NOT EXECUTED
40012fc4:	94 10 20 28 	mov  0x28, %o2                                 <== NOT EXECUTED
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
40012fc8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012fcc:	91 e8 20 01 	restore  %g0, 1, %o0                           <== NOT EXECUTED
      );                                                              
                                                                      
      if (rc == 0) {                                                  
        rc = rtems_rfs_inode_close (fs, inode);                       
        if (rc == 0) {                                                
          rc = rtems_rfs_inode_open (fs, entry_ino, inode, true);     
40012fd0:	90 10 00 1c 	mov  %i4, %o0                                  
40012fd4:	94 10 00 19 	mov  %i1, %o2                                  
40012fd8:	7f ff fb 41 	call  40011cdc <rtems_rfs_inode_open>          
40012fdc:	96 10 20 01 	mov  1, %o3                                    
        }                                                             
                                                                      
        if (rc != 0) {                                                
40012fe0:	80 a2 20 00 	cmp  %o0, 0                                    
40012fe4:	12 bf ff f6 	bne  40012fbc <rtems_rfs_rtems_eval_token+0xdc><== NEVER TAKEN
40012fe8:	90 10 00 19 	mov  %i1, %o0                                  
        status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY;         
        rc = -1;                                                      
      }                                                               
                                                                      
      if (rc == 0) {                                                  
        bool is_sym_link = rtems_rfs_rtems_node_type_by_inode (inode) 
40012fec:	7f ff fd 78 	call  400125cc <rtems_rfs_rtems_node_type_by_inode>
40012ff0:	90 10 00 19 	mov  %i1, %o0                                  
          == RTEMS_FILESYSTEM_SYM_LINK;                               
        int eval_flags = rtems_filesystem_eval_path_get_flags (ctx);  
        bool follow_sym_link = (eval_flags & RTEMS_FS_FOLLOW_SYM_LINK) != 0;
        bool terminal = !rtems_filesystem_eval_path_has_path (ctx);   
40012ff4:	c4 07 60 04 	ld  [ %i5 + 4 ], %g2                           
                                                                      
      if (rc == 0) {                                                  
        bool is_sym_link = rtems_rfs_rtems_node_type_by_inode (inode) 
          == RTEMS_FILESYSTEM_SYM_LINK;                               
        int eval_flags = rtems_filesystem_eval_path_get_flags (ctx);  
        bool follow_sym_link = (eval_flags & RTEMS_FS_FOLLOW_SYM_LINK) != 0;
40012ff8:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
        bool terminal = !rtems_filesystem_eval_path_has_path (ctx);   
40012ffc:	80 a0 00 02 	cmp  %g0, %g2                                  
40013000:	c0 27 60 0c 	clr  [ %i5 + 0xc ]                             
                                                                      
      if (rc == 0) {                                                  
        bool is_sym_link = rtems_rfs_rtems_node_type_by_inode (inode) 
          == RTEMS_FILESYSTEM_SYM_LINK;                               
        int eval_flags = rtems_filesystem_eval_path_get_flags (ctx);  
        bool follow_sym_link = (eval_flags & RTEMS_FS_FOLLOW_SYM_LINK) != 0;
40013004:	83 30 60 04 	srl  %g1, 4, %g1                               
        bool terminal = !rtems_filesystem_eval_path_has_path (ctx);   
40013008:	b0 60 3f ff 	subx  %g0, -1, %i0                             
                                                                      
        rtems_filesystem_eval_path_clear_token (ctx);                 
                                                                      
        if (is_sym_link && (follow_sym_link || !terminal)) {          
4001300c:	80 a2 20 03 	cmp  %o0, 3                                    
40013010:	12 80 00 28 	bne  400130b0 <rtems_rfs_rtems_eval_token+0x1d0>
40013014:	82 08 60 01 	and  %g1, 1, %g1                               
40013018:	80 a6 20 00 	cmp  %i0, 0                                    
4001301c:	12 80 00 19 	bne  40013080 <rtems_rfs_rtems_eval_token+0x1a0>
40013020:	80 a0 60 00 	cmp  %g1, 0                                    
  rtems_filesystem_eval_path_context_t* ctx,                          
  rtems_rfs_file_system* fs,                                          
  rtems_rfs_ino ino                                                   
)                                                                     
{                                                                     
  size_t len = MAXPATHLEN;                                            
40013024:	82 10 20 ff 	mov  0xff, %g1                                 
        bool terminal = !rtems_filesystem_eval_path_has_path (ctx);   
                                                                      
        rtems_filesystem_eval_path_clear_token (ctx);                 
                                                                      
        if (is_sym_link && (follow_sym_link || !terminal)) {          
          rtems_rfs_rtems_follow_link (ctx, fs, entry_ino);           
40013028:	f4 07 bf f4 	ld  [ %fp + -12 ], %i2                         
  rtems_filesystem_eval_path_context_t* ctx,                          
  rtems_rfs_file_system* fs,                                          
  rtems_rfs_ino ino                                                   
)                                                                     
{                                                                     
  size_t len = MAXPATHLEN;                                            
4001302c:	c2 27 bf fc 	st  %g1, [ %fp + -4 ]                          
  char *link = malloc(len + 1);                                       
40013030:	7f ff d5 4d 	call  40008564 <malloc>                        
40013034:	90 10 21 00 	mov  0x100, %o0                                
                                                                      
  if (link != NULL) {                                                 
40013038:	b6 92 20 00 	orcc  %o0, 0, %i3                              
4001303c:	02 80 00 18 	be  4001309c <rtems_rfs_rtems_eval_token+0x1bc><== NEVER TAKEN
40013040:	90 10 00 1c 	mov  %i4, %o0                                  
    int rc = rtems_rfs_symlink_read (fs, ino, link, len, &len);       
40013044:	92 10 00 1a 	mov  %i2, %o1                                  
40013048:	94 10 00 1b 	mov  %i3, %o2                                  
4001304c:	96 10 20 ff 	mov  0xff, %o3                                 
40013050:	40 00 2e a7 	call  4001eaec <rtems_rfs_symlink_read>        
40013054:	98 07 bf fc 	add  %fp, -4, %o4                              
                                                                      
    if (rc == 0) {                                                    
40013058:	80 a2 20 00 	cmp  %o0, 0                                    
4001305c:	12 80 00 0d 	bne  40013090 <rtems_rfs_rtems_eval_token+0x1b0><== NEVER TAKEN
40013060:	90 10 00 1d 	mov  %i5, %o0                                  
      rtems_filesystem_eval_path_recursive (ctx, link, len);          
40013064:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
40013068:	7f ff d9 e0 	call  400097e8 <rtems_filesystem_eval_path_recursive>
4001306c:	92 10 00 1b 	mov  %i3, %o1                                  
    } else {                                                          
      rtems_filesystem_eval_path_error (ctx, 0);                      
    }                                                                 
                                                                      
    free(link);                                                       
40013070:	7f ff d3 af 	call  40007f2c <free>                          
40013074:	90 10 00 1b 	mov  %i3, %o0                                  
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
40013078:	81 c7 e0 08 	ret                                            
4001307c:	91 e8 20 01 	restore  %g0, 1, %o0                           
        bool follow_sym_link = (eval_flags & RTEMS_FS_FOLLOW_SYM_LINK) != 0;
        bool terminal = !rtems_filesystem_eval_path_has_path (ctx);   
                                                                      
        rtems_filesystem_eval_path_clear_token (ctx);                 
                                                                      
        if (is_sym_link && (follow_sym_link || !terminal)) {          
40013080:	02 80 00 0d 	be  400130b4 <rtems_rfs_rtems_eval_token+0x1d4>
40013084:	90 07 60 18 	add  %i5, 0x18, %o0                            
  rtems_filesystem_eval_path_context_t* ctx,                          
  rtems_rfs_file_system* fs,                                          
  rtems_rfs_ino ino                                                   
)                                                                     
{                                                                     
  size_t len = MAXPATHLEN;                                            
40013088:	10 bf ff e8 	b  40013028 <rtems_rfs_rtems_eval_token+0x148> 
4001308c:	82 10 20 ff 	mov  0xff, %g1                                 
    int rc = rtems_rfs_symlink_read (fs, ino, link, len, &len);       
                                                                      
    if (rc == 0) {                                                    
      rtems_filesystem_eval_path_recursive (ctx, link, len);          
    } else {                                                          
      rtems_filesystem_eval_path_error (ctx, 0);                      
40013090:	7f ff d8 ef 	call  4000944c <rtems_filesystem_eval_path_error><== NOT EXECUTED
40013094:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
40013098:	30 bf ff f6 	b,a   40013070 <rtems_rfs_rtems_eval_token+0x190><== NOT EXECUTED
    }                                                                 
                                                                      
    free(link);                                                       
  } else {                                                            
    rtems_filesystem_eval_path_error (ctx, ENOMEM);                   
4001309c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
400130a0:	92 10 20 0c 	mov  0xc, %o1                                  <== NOT EXECUTED
400130a4:	7f ff d8 ea 	call  4000944c <rtems_filesystem_eval_path_error><== NOT EXECUTED
400130a8:	b0 10 20 01 	mov  1, %i0                                    <== NOT EXECUTED
400130ac:	30 80 00 12 	b,a   400130f4 <rtems_rfs_rtems_eval_token+0x214><== NOT EXECUTED
        rtems_filesystem_eval_path_clear_token (ctx);                 
                                                                      
        if (is_sym_link && (follow_sym_link || !terminal)) {          
          rtems_rfs_rtems_follow_link (ctx, fs, entry_ino);           
        } else {                                                      
          rc = rtems_rfs_rtems_set_handlers (currentloc, inode) ? 0 : EIO;
400130b0:	90 07 60 18 	add  %i5, 0x18, %o0                            
400130b4:	40 00 01 33 	call  40013580 <rtems_rfs_rtems_set_handlers>  
400130b8:	92 10 00 19 	mov  %i1, %o1                                  
400130bc:	80 a2 20 00 	cmp  %o0, 0                                    
400130c0:	12 80 00 09 	bne  400130e4 <rtems_rfs_rtems_eval_token+0x204><== ALWAYS TAKEN
400130c4:	c2 07 bf f4 	ld  [ %fp + -12 ], %g1                         
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE;   
            }                                                         
          } else {                                                    
            rtems_filesystem_eval_path_error (                        
              ctx,                                                    
              rtems_rfs_rtems_error ("eval_path: set handlers", rc)   
400130c8:	40 00 37 75 	call  40020e9c <__errno>                       <== NOT EXECUTED
400130cc:	01 00 00 00 	nop                                            <== NOT EXECUTED
400130d0:	82 10 20 05 	mov  5, %g1	! 5 <_TLS_Alignment+0x4>           <== NOT EXECUTED
                                                                      
            if (!terminal) {                                          
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE;   
            }                                                         
          } else {                                                    
            rtems_filesystem_eval_path_error (                        
400130d4:	92 10 3f ff 	mov  -1, %o1                                   <== NOT EXECUTED
              ctx,                                                    
              rtems_rfs_rtems_error ("eval_path: set handlers", rc)   
400130d8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
                                                                      
            if (!terminal) {                                          
              status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE;   
            }                                                         
          } else {                                                    
            rtems_filesystem_eval_path_error (                        
400130dc:	10 bf ff f2 	b  400130a4 <rtems_rfs_rtems_eval_token+0x1c4> <== NOT EXECUTED
400130e0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  void *arg,                                                          
  const char *token,                                                  
  size_t tokenlen                                                     
)                                                                     
{                                                                     
  rtems_filesystem_eval_path_generic_status status =                  
400130e4:	b0 0e 20 ff 	and  %i0, 0xff, %i0                            
        if (is_sym_link && (follow_sym_link || !terminal)) {          
          rtems_rfs_rtems_follow_link (ctx, fs, entry_ino);           
        } else {                                                      
          rc = rtems_rfs_rtems_set_handlers (currentloc, inode) ? 0 : EIO;
          if (rc == 0) {                                              
            rtems_rfs_rtems_set_pathloc_ino (currentloc, entry_ino);  
400130e8:	c2 27 60 20 	st  %g1, [ %i5 + 0x20 ]                        
            rtems_rfs_rtems_set_pathloc_doff (currentloc, entry_doff);
400130ec:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
400130f0:	c2 27 60 24 	st  %g1, [ %i5 + 0x24 ]                        
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  return status;                                                      
}                                                                     
400130f4:	81 c7 e0 08 	ret                                            
400130f8:	81 e8 00 00 	restore                                        
                                                                      

40012700 <rtems_rfs_rtems_fchmod>: } static int rtems_rfs_rtems_fchmod (const rtems_filesystem_location_info_t* pathloc, mode_t mode) {
40012700:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_rfs_file_system*  fs = rtems_rfs_rtems_pathloc_dev (pathloc); 
40012704:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FCHMOD))           
    printf ("rtems-rfs-rtems: fchmod: in: ino:%" PRId32 " mode:%06" PRIomode_t "\n",
            ino, mode);                                               
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012708:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
                                                                      
static int                                                            
rtems_rfs_rtems_fchmod (const rtems_filesystem_location_info_t* pathloc,
                        mode_t                                  mode) 
{                                                                     
  rtems_rfs_file_system*  fs = rtems_rfs_rtems_pathloc_dev (pathloc); 
4001270c:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FCHMOD))           
    printf ("rtems-rfs-rtems: fchmod: in: ino:%" PRId32 " mode:%06" PRIomode_t "\n",
            ino, mode);                                               
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012710:	94 07 bf d8 	add  %fp, -40, %o2                             
40012714:	90 10 00 1d 	mov  %i5, %o0                                  
40012718:	7f ff fd 71 	call  40011cdc <rtems_rfs_inode_open>          
4001271c:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
40012720:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40012724:	02 80 00 07 	be  40012740 <rtems_rfs_rtems_fchmod+0x40>     <== ALWAYS TAKEN
40012728:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  {                                                                   
    return rtems_rfs_rtems_error ("fchmod: opening inode", rc);       
4001272c:	40 00 39 dc 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012730:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012734:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
40012738:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001273c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
 * @param[in] mode is 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);                    
40012740:	85 36 60 08 	srl  %i1, 8, %g2                               
40012744:	c4 28 60 02 	stb  %g2, [ %g1 + 2 ]                          
40012748:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  }                                                                   
                                                                      
  rtems_rfs_inode_set_mode (&inode, mode);                            
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
4001274c:	90 10 00 1d 	mov  %i5, %o0                                  
40012750:	f2 28 60 03 	stb  %i1, [ %g1 + 3 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
40012754:	82 10 20 01 	mov  1, %g1                                    
40012758:	92 07 bf d8 	add  %fp, -40, %o1                             
4001275c:	c2 2f bf e8 	stb  %g1, [ %fp + -24 ]                        
40012760:	7f ff fd d1 	call  40011ea4 <rtems_rfs_inode_close>         
40012764:	b0 10 20 00 	clr  %i0                                       
  if (rc > 0)                                                         
40012768:	80 a2 20 00 	cmp  %o0, 0                                    
4001276c:	04 80 00 05 	ble  40012780 <rtems_rfs_rtems_fchmod+0x80>    <== ALWAYS TAKEN
40012770:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("fchmod: closing inode", rc);       
40012774:	40 00 39 ca 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012778:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001277c:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40012780:	81 c7 e0 08 	ret                                            
40012784:	81 e8 00 00 	restore                                        
                                                                      

4001354c <rtems_rfs_rtems_fdatasync>: * @param iop * @return int */ int rtems_rfs_rtems_fdatasync (rtems_libio_t* iop) {
4001354c:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  int rc;                                                             
                                                                      
  rc = rtems_rfs_buffer_sync (rtems_rfs_rtems_pathloc_dev (&iop->pathinfo));
40013550:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        <== NOT EXECUTED
  if (rc)                                                             
    return rtems_rfs_rtems_error ("fdatasync: sync", rc);             
                                                                      
  return 0;                                                           
40013554:	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));
40013558:	40 00 20 47 	call  4001b674 <rtems_rfs_buffer_sync>         <== NOT EXECUTED
4001355c:	d0 00 60 08 	ld  [ %g1 + 8 ], %o0                           <== NOT EXECUTED
  if (rc)                                                             
40013560:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40013564:	02 80 00 05 	be  40013578 <rtems_rfs_rtems_fdatasync+0x2c>  <== NOT EXECUTED
40013568:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("fdatasync: sync", rc);             
4001356c:	40 00 36 4c 	call  40020e9c <__errno>                       <== NOT EXECUTED
40013570:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40013574:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
                                                                      
  return 0;                                                           
}                                                                     
40013578:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001357c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

4001f6ac <rtems_rfs_rtems_file_close>: * @param iop * @return int */ static int rtems_rfs_rtems_file_close (rtems_libio_t* iop) {
4001f6ac:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_file_handle* file = rtems_rfs_rtems_get_iop_file_handle (iop);
4001f6b0:	f8 06 20 20 	ld  [ %i0 + 0x20 ], %i4                        
  rtems_rfs_file_system* fs = rtems_rfs_file_fs (file);               
4001f6b4:	c2 07 20 1c 	ld  [ %i4 + 0x1c ], %g1                        
4001f6b8:	fa 00 60 98 	ld  [ %g1 + 0x98 ], %i5                        
4001f6bc:	c2 07 60 80 	ld  [ %i5 + 0x80 ], %g1                        
4001f6c0:	7f ff fe ce 	call  4001f1f8 <rtems_rfs_mutex_lock.isra.0>   
4001f6c4:	d0 00 40 00 	ld  [ %g1 ], %o0                               
  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);                               
4001f6c8:	90 10 00 1d 	mov  %i5, %o0                                  
4001f6cc:	7f ff f5 1d 	call  4001cb40 <rtems_rfs_file_close>          
4001f6d0:	92 10 00 1c 	mov  %i4, %o1                                  
  if (rc > 0)                                                         
4001f6d4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001f6d8:	04 80 00 06 	ble  4001f6f0 <rtems_rfs_rtems_file_close+0x44><== ALWAYS TAKEN
4001f6dc:	01 00 00 00 	nop                                            
    rc = rtems_rfs_rtems_error ("file-close: file close", rc);        
4001f6e0:	40 00 05 ef 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f6e4:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001f6e8:	f0 22 00 00 	st  %i0, [ %o0 ]                               <== NOT EXECUTED
4001f6ec:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
4001f6f0:	7f ff fe da 	call  4001f258 <rtems_rfs_rtems_unlock>        
4001f6f4:	90 10 00 1d 	mov  %i5, %o0                                  
  return rc;                                                          
}                                                                     
4001f6f8:	81 c7 e0 08 	ret                                            
4001f6fc:	81 e8 00 00 	restore                                        
                                                                      

4001f650 <rtems_rfs_rtems_file_ftruncate>: * @return int */ static int rtems_rfs_rtems_file_ftruncate (rtems_libio_t* iop, off_t length) {
4001f650:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_file_handle* file = rtems_rfs_rtems_get_iop_file_handle (iop);
4001f654:	f6 06 20 20 	ld  [ %i0 + 0x20 ], %i3                        
  int                    rc;                                          
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_FTRUNC))      
    printf("rtems-rfs: file-ftrunc: handle:%p length:%" PRIdoff_t "\n", file, length);
                                                                      
  rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));                    
4001f658:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
4001f65c:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
4001f660:	c2 00 60 80 	ld  [ %g1 + 0x80 ], %g1                        
4001f664:	7f ff fe e5 	call  4001f1f8 <rtems_rfs_mutex_lock.isra.0>   
4001f668:	d0 00 40 00 	ld  [ %g1 ], %o0                               
                                                                      
  rc = rtems_rfs_file_set_size (file, length);                        
4001f66c:	90 10 00 1b 	mov  %i3, %o0                                  
4001f670:	92 10 00 19 	mov  %i1, %o1                                  
4001f674:	7f ff f7 53 	call  4001d3c0 <rtems_rfs_file_set_size>       
4001f678:	94 10 00 1a 	mov  %i2, %o2                                  
  if (rc)                                                             
4001f67c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001f680:	22 80 00 07 	be,a   4001f69c <rtems_rfs_rtems_file_ftruncate+0x4c><== ALWAYS TAKEN
4001f684:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        
    rc = rtems_rfs_rtems_error ("file_ftruncate: set size", rc);      
4001f688:	40 00 06 05 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f68c:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001f690:	f0 22 00 00 	st  %i0, [ %o0 ]                               <== NOT EXECUTED
4001f694:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
                                                                      
  rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));                  
4001f698:	c2 06 e0 1c 	ld  [ %i3 + 0x1c ], %g1                        <== NOT EXECUTED
4001f69c:	7f ff fe ef 	call  4001f258 <rtems_rfs_rtems_unlock>        
4001f6a0:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
                                                                      
  return rc;                                                          
}                                                                     
4001f6a4:	81 c7 e0 08 	ret                                            
4001f6a8:	81 e8 00 00 	restore                                        
                                                                      

4001f2ac <rtems_rfs_rtems_file_lseek>: */ static off_t rtems_rfs_rtems_file_lseek (rtems_libio_t* iop, off_t offset, int whence) {
4001f2ac:	9d e3 bf 98 	save  %sp, -104, %sp                           
4001f2b0:	a2 10 00 1a 	mov  %i2, %l1                                  
  rtems_rfs_file_handle* file = rtems_rfs_rtems_get_iop_file_handle (iop);
4001f2b4:	f4 06 20 20 	ld  [ %i0 + 0x20 ], %i2                        
  off_t                  new_offset;                                  
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_LSEEK))       
    printf("rtems-rfs: file-lseek: handle:%p offset:%" PRIdoff_t "\n", file, offset);
                                                                      
  rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));                    
4001f2b8:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
4001f2bc:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
 */                                                                   
static inline void                                                    
 rtems_rfs_rtems_lock (rtems_rfs_file_system* fs)                     
{                                                                     
  rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);            
  rtems_rfs_mutex_lock (&rtems->access);                              
4001f2c0:	c2 00 60 80 	ld  [ %g1 + 0x80 ], %g1                        
4001f2c4:	7f ff ff cd 	call  4001f1f8 <rtems_rfs_mutex_lock.isra.0>   
4001f2c8:	d0 00 40 00 	ld  [ %g1 ], %o0                               
                                                                      
  old_offset = iop->offset;                                           
  new_offset = rtems_filesystem_default_lseek_file (iop, offset, whence);
4001f2cc:	92 10 00 19 	mov  %i1, %o1                                  
4001f2d0:	96 10 00 1b 	mov  %i3, %o3                                  
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_FILE_LSEEK))       
    printf("rtems-rfs: file-lseek: handle:%p offset:%" PRIdoff_t "\n", file, offset);
                                                                      
  rtems_rfs_rtems_lock (rtems_rfs_file_fs (file));                    
                                                                      
  old_offset = iop->offset;                                           
4001f2d4:	f8 1e 20 08 	ldd  [ %i0 + 8 ], %i4                          
  new_offset = rtems_filesystem_default_lseek_file (iop, offset, whence);
4001f2d8:	90 10 00 18 	mov  %i0, %o0                                  
4001f2dc:	40 00 01 43 	call  4001f7e8 <rtems_filesystem_default_lseek_file>
4001f2e0:	94 10 00 11 	mov  %l1, %o2                                  
4001f2e4:	b6 10 00 08 	mov  %o0, %i3                                  
  if (new_offset != -1)                                               
4001f2e8:	80 a6 ff ff 	cmp  %i3, -1                                   
4001f2ec:	12 80 00 05 	bne  4001f300 <rtems_rfs_rtems_file_lseek+0x54>
4001f2f0:	b2 10 00 09 	mov  %o1, %i1                                  
4001f2f4:	80 a2 7f ff 	cmp  %o1, -1                                   
4001f2f8:	22 80 00 12 	be,a   4001f340 <rtems_rfs_rtems_file_lseek+0x94><== ALWAYS TAKEN
4001f2fc:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
  {                                                                   
    rtems_rfs_pos pos = iop->offset;                                  
4001f300:	c4 1e 20 08 	ldd  [ %i0 + 8 ], %g2                          
    int           rc = rtems_rfs_file_seek (file, pos, &pos);         
4001f304:	90 10 00 1a 	mov  %i2, %o0                                  
                                                                      
  old_offset = iop->offset;                                           
  new_offset = rtems_filesystem_default_lseek_file (iop, offset, whence);
  if (new_offset != -1)                                               
  {                                                                   
    rtems_rfs_pos pos = iop->offset;                                  
4001f308:	c4 3f bf f8 	std  %g2, [ %fp + -8 ]                         
    int           rc = rtems_rfs_file_seek (file, pos, &pos);         
4001f30c:	92 10 00 02 	mov  %g2, %o1                                  
4001f310:	94 10 00 03 	mov  %g3, %o2                                  
4001f314:	7f ff f7 ed 	call  4001d2c8 <rtems_rfs_file_seek>           
4001f318:	96 07 bf f8 	add  %fp, -8, %o3                              
                                                                      
    if (rc)                                                           
4001f31c:	a0 92 20 00 	orcc  %o0, 0, %l0                              
4001f320:	22 80 00 08 	be,a   4001f340 <rtems_rfs_rtems_file_lseek+0x94><== ALWAYS TAKEN
4001f324:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        
    {                                                                 
      rtems_rfs_rtems_error ("file_lseek: lseek", rc);                
4001f328:	40 00 06 dd 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f32c:	b6 10 3f ff 	mov  -1, %i3                                   <== NOT EXECUTED
4001f330:	e0 22 00 00 	st  %l0, [ %o0 ]                               <== NOT EXECUTED
      iop->offset = old_offset;                                       
4001f334:	f8 3e 20 08 	std  %i4, [ %i0 + 8 ]                          <== NOT EXECUTED
      new_offset = -1;                                                
4001f338:	b2 10 3f ff 	mov  -1, %i1                                   <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));                  
4001f33c:	c2 06 a0 1c 	ld  [ %i2 + 0x1c ], %g1                        <== NOT EXECUTED
                                                                      
  return new_offset;                                                  
}                                                                     
4001f340:	b0 10 00 1b 	mov  %i3, %i0                                  
      iop->offset = old_offset;                                       
      new_offset = -1;                                                
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));                  
4001f344:	7f ff ff c5 	call  4001f258 <rtems_rfs_rtems_unlock>        
4001f348:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
                                                                      
  return new_offset;                                                  
}                                                                     
4001f34c:	81 c7 e0 08 	ret                                            
4001f350:	81 e8 00 00 	restore                                        
                                                                      

4001f700 <rtems_rfs_rtems_file_open>: static int rtems_rfs_rtems_file_open (rtems_libio_t* iop, const char* pathname, int oflag, mode_t mode) {
4001f700:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (&iop->pathinfo);
4001f704:	c2 06 20 28 	ld  [ %i0 + 0x28 ], %g1                        
4001f708:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
4001f70c:	c2 07 60 80 	ld  [ %i5 + 0x80 ], %g1                        
4001f710:	7f ff fe ba 	call  4001f1f8 <rtems_rfs_mutex_lock.isra.0>   
4001f714:	d0 00 40 00 	ld  [ %g1 ], %o0                               
                                                                      
  rtems_rfs_rtems_lock (fs);                                          
                                                                      
  ino = rtems_rfs_rtems_get_iop_ino (iop);                            
                                                                      
  rc = rtems_rfs_file_open (fs, ino, flags, &file);                   
4001f718:	d2 06 20 1c 	ld  [ %i0 + 0x1c ], %o1                        
4001f71c:	90 10 00 1d 	mov  %i5, %o0                                  
4001f720:	94 10 20 00 	clr  %o2                                       
4001f724:	7f ff f7 ff 	call  4001d720 <rtems_rfs_file_open>           
4001f728:	96 07 bf fc 	add  %fp, -4, %o3                              
  if (rc > 0)                                                         
4001f72c:	b8 92 20 00 	orcc  %o0, 0, %i4                              
4001f730:	04 80 00 09 	ble  4001f754 <rtems_rfs_rtems_file_open+0x54> <== ALWAYS TAKEN
4001f734:	90 10 00 1d 	mov  %i5, %o0                                  
  {                                                                   
    rtems_rfs_rtems_unlock (fs);                                      
4001f738:	7f ff fe c8 	call  4001f258 <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001f73c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
    return rtems_rfs_rtems_error ("file-open: open", rc);             
4001f740:	40 00 05 d7 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f744:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001f748:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
4001f74c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001f750:	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);                
                                                                      
  rtems_rfs_rtems_set_iop_file_handle (iop, file);                    
4001f754:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4001f758:	c2 26 20 20 	st  %g1, [ %i0 + 0x20 ]                        
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
4001f75c:	7f ff fe bf 	call  4001f258 <rtems_rfs_rtems_unlock>        
4001f760:	b0 10 20 00 	clr  %i0                                       
  return 0;                                                           
}                                                                     
4001f764:	81 c7 e0 08 	ret                                            
4001f768:	81 e8 00 00 	restore                                        
                                                                      

4001f354 <rtems_rfs_rtems_file_read>: */ static ssize_t rtems_rfs_rtems_file_read (rtems_libio_t* iop, void* buffer, size_t count) {
4001f354:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_rfs_file_handle* file = rtems_rfs_rtems_get_iop_file_handle (iop);
4001f358:	e0 06 20 20 	ld  [ %i0 + 0x20 ], %l0                        
 */                                                                   
static ssize_t                                                        
rtems_rfs_rtems_file_read (rtems_libio_t* iop,                        
                           void*          buffer,                     
                           size_t         count)                      
{                                                                     
4001f35c:	a2 10 00 18 	mov  %i0, %l1                                  
  int                    rc;                                          
                                                                      
  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));                    
4001f360:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        
4001f364:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
4001f368:	c2 00 60 80 	ld  [ %g1 + 0x80 ], %g1                        
4001f36c:	7f ff ff a3 	call  4001f1f8 <rtems_rfs_mutex_lock.isra.0>   
4001f370:	d0 00 40 00 	ld  [ %g1 ], %o0                               
                                                                      
  pos = iop->offset;                                                  
                                                                      
  if (pos < rtems_rfs_file_size (file))                               
4001f374:	d2 04 20 1c 	ld  [ %l0 + 0x1c ], %o1                        
  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;                                                  
4001f378:	f8 1e 20 08 	ldd  [ %i0 + 8 ], %i4                          
4001f37c:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001f380:	7f ff eb a5 	call  4001a214 <rtems_rfs_block_get_size>      
4001f384:	92 02 60 84 	add  %o1, 0x84, %o1                            
                                                                      
  if (pos < rtems_rfs_file_size (file))                               
4001f388:	80 a2 00 1c 	cmp  %o0, %i4                                  
4001f38c:	38 80 00 0a 	bgu,a   4001f3b4 <rtems_rfs_rtems_file_read+0x60><== NEVER TAKEN
4001f390:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
4001f394:	80 a2 00 1c 	cmp  %o0, %i4                                  
4001f398:	12 80 00 2e 	bne  4001f450 <rtems_rfs_rtems_file_read+0xfc> <== NEVER TAKEN
4001f39c:	b0 10 20 00 	clr  %i0                                       
4001f3a0:	80 a2 40 1d 	cmp  %o1, %i5                                  
4001f3a4:	18 80 00 04 	bgu  4001f3b4 <rtems_rfs_rtems_file_read+0x60> 
4001f3a8:	01 00 00 00 	nop                                            
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  if (read >= 0)                                                      
    iop->offset = pos + read;                                         
4001f3ac:	10 80 00 2a 	b  4001f454 <rtems_rfs_rtems_file_read+0x100>  
4001f3b0:	b6 86 00 1d 	addcc  %i0, %i5, %i3                           
                                                                      
  pos = iop->offset;                                                  
                                                                      
  if (pos < rtems_rfs_file_size (file))                               
  {                                                                   
    while (count)                                                     
4001f3b4:	80 a6 a0 00 	cmp  %i2, 0                                    
4001f3b8:	02 80 00 23 	be  4001f444 <rtems_rfs_rtems_file_read+0xf0>  
4001f3bc:	90 10 00 10 	mov  %l0, %o0                                  
    {                                                                 
      size_t size;                                                    
                                                                      
      rc = rtems_rfs_file_io_start (file, &size, true);               
4001f3c0:	92 07 bf fc 	add  %fp, -4, %o1                              
4001f3c4:	7f ff f6 8d 	call  4001cdf8 <rtems_rfs_file_io_start>       
4001f3c8:	94 10 20 01 	mov  1, %o2                                    
      if (rc > 0)                                                     
4001f3cc:	b6 92 20 00 	orcc  %o0, 0, %i3                              
4001f3d0:	14 80 00 19 	bg  4001f434 <rtems_rfs_rtems_file_read+0xe0>  <== NEVER TAKEN
4001f3d4:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
      {                                                               
        read = rtems_rfs_rtems_error ("file-read: read: io-start", rc);
        break;                                                        
      }                                                               
                                                                      
      if (size == 0)                                                  
4001f3d8:	80 a0 60 00 	cmp  %g1, 0                                    
4001f3dc:	02 80 00 1a 	be  4001f444 <rtems_rfs_rtems_file_read+0xf0>  
4001f3e0:	80 a0 40 1a 	cmp  %g1, %i2                                  
        break;                                                        
                                                                      
      if (size > count)                                               
4001f3e4:	38 80 00 02 	bgu,a   4001f3ec <rtems_rfs_rtems_file_read+0x98>
4001f3e8:	f4 27 bf fc 	st  %i2, [ %fp + -4 ]                          
        size = count;                                                 
                                                                      
      memcpy (data, rtems_rfs_file_data (file), size);                
4001f3ec:	c2 04 20 0c 	ld  [ %l0 + 0xc ], %g1                         
4001f3f0:	f6 07 bf fc 	ld  [ %fp + -4 ], %i3                          
4001f3f4:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1                        
4001f3f8:	c2 04 20 14 	ld  [ %l0 + 0x14 ], %g1                        
4001f3fc:	94 10 00 1b 	mov  %i3, %o2                                  
4001f400:	92 02 40 01 	add  %o1, %g1, %o1                             
4001f404:	40 00 0a 95 	call  40021e58 <memcpy>                        
4001f408:	90 10 00 19 	mov  %i1, %o0                                  
                                                                      
      data  += size;                                                  
      count -= size;                                                  
      read  += size;                                                  
                                                                      
      rc = rtems_rfs_file_io_end (file, size, true);                  
4001f40c:	92 10 00 1b 	mov  %i3, %o1                                  
      if (size > count)                                               
        size = count;                                                 
                                                                      
      memcpy (data, rtems_rfs_file_data (file), size);                
                                                                      
      data  += size;                                                  
4001f410:	b2 06 40 1b 	add  %i1, %i3, %i1                             
      count -= size;                                                  
4001f414:	b4 26 80 1b 	sub  %i2, %i3, %i2                             
      read  += size;                                                  
4001f418:	b0 06 00 1b 	add  %i0, %i3, %i0                             
                                                                      
      rc = rtems_rfs_file_io_end (file, size, true);                  
4001f41c:	90 10 00 10 	mov  %l0, %o0                                  
4001f420:	7f ff f6 ff 	call  4001d01c <rtems_rfs_file_io_end>         
4001f424:	94 10 20 01 	mov  1, %o2                                    
      if (rc > 0)                                                     
4001f428:	b6 92 20 00 	orcc  %o0, 0, %i3                              
4001f42c:	04 bf ff e3 	ble  4001f3b8 <rtems_rfs_rtems_file_read+0x64> <== ALWAYS TAKEN
4001f430:	80 a6 a0 00 	cmp  %i2, 0                                    
      {                                                               
        read = rtems_rfs_rtems_error ("file-read: read: io-end", rc); 
4001f434:	40 00 06 9a 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f438:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001f43c:	10 80 00 09 	b  4001f460 <rtems_rfs_rtems_file_read+0x10c>  <== NOT EXECUTED
4001f440:	f6 22 00 00 	st  %i3, [ %o0 ]                               <== NOT EXECUTED
        break;                                                        
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  if (read >= 0)                                                      
4001f444:	80 a6 20 00 	cmp  %i0, 0                                    
4001f448:	26 80 00 07 	bl,a   4001f464 <rtems_rfs_rtems_file_read+0x110><== NEVER TAKEN
4001f44c:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        <== NOT EXECUTED
    iop->offset = pos + read;                                         
4001f450:	b6 86 00 1d 	addcc  %i0, %i5, %i3                           
4001f454:	85 3e 20 1f 	sra  %i0, 0x1f, %g2                            
4001f458:	b4 40 80 1c 	addx  %g2, %i4, %i2                            
4001f45c:	f4 3c 60 08 	std  %i2, [ %l1 + 8 ]                          
                                                                      
  rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));                  
4001f460:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        
4001f464:	7f ff ff 7d 	call  4001f258 <rtems_rfs_rtems_unlock>        
4001f468:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
                                                                      
  return read;                                                        
}                                                                     
4001f46c:	81 c7 e0 08 	ret                                            
4001f470:	81 e8 00 00 	restore                                        
                                                                      

4001f474 <rtems_rfs_rtems_file_write>: */ static ssize_t rtems_rfs_rtems_file_write (rtems_libio_t* iop, const void* buffer, size_t count) {
4001f474:	9d e3 bf 90 	save  %sp, -112, %sp                           
  rtems_rfs_file_handle* file = rtems_rfs_rtems_get_iop_file_handle (iop);
4001f478:	e0 06 20 20 	ld  [ %i0 + 0x20 ], %l0                        
  int                    rc;                                          
                                                                      
  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));                    
4001f47c:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        
4001f480:	c2 00 60 98 	ld  [ %g1 + 0x98 ], %g1                        
4001f484:	c2 00 60 80 	ld  [ %g1 + 0x80 ], %g1                        
4001f488:	7f ff ff 5c 	call  4001f1f8 <rtems_rfs_mutex_lock.isra.0>   
4001f48c:	d0 00 40 00 	ld  [ %g1 ], %o0                               
                                                                      
  pos = iop->offset;                                                  
  file_size = rtems_rfs_file_size (file);                             
4001f490:	d2 04 20 1c 	ld  [ %l0 + 0x1c ], %o1                        
  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;                                                  
4001f494:	c4 1e 20 08 	ldd  [ %i0 + 8 ], %g2                          
4001f498:	d0 02 60 98 	ld  [ %o1 + 0x98 ], %o0                        
4001f49c:	c4 3f bf f8 	std  %g2, [ %fp + -8 ]                         
4001f4a0:	7f ff eb 5d 	call  4001a214 <rtems_rfs_block_get_size>      
4001f4a4:	92 02 60 84 	add  %o1, 0x84, %o1                            
4001f4a8:	86 10 00 09 	mov  %o1, %g3                                  
  file_size = rtems_rfs_file_size (file);                             
  if (pos > file_size)                                                
4001f4ac:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
4001f4b0:	82 10 00 08 	mov  %o0, %g1                                  
4001f4b4:	80 a2 40 01 	cmp  %o1, %g1                                  
4001f4b8:	18 80 00 08 	bgu  4001f4d8 <rtems_rfs_rtems_file_write+0x64><== NEVER TAKEN
4001f4bc:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
4001f4c0:	80 a2 40 01 	cmp  %o1, %g1                                  
4001f4c4:	12 80 00 11 	bne  4001f508 <rtems_rfs_rtems_file_write+0x94><== NEVER TAKEN
4001f4c8:	80 a0 40 09 	cmp  %g1, %o1                                  
4001f4cc:	80 a2 80 03 	cmp  %o2, %g3                                  
4001f4d0:	08 80 00 0e 	bleu  4001f508 <rtems_rfs_rtems_file_write+0x94>
4001f4d4:	80 a0 40 09 	cmp  %g1, %o1                                  
    /*                                                                
     * If the iop position is past the physical end of the file we need to set
     * the file size to the new length before writing.  The           
     * rtems_rfs_file_io_end() will grow the file subsequently.       
     */                                                               
    rc = rtems_rfs_file_set_size (file, pos);                         
4001f4d8:	7f ff f7 ba 	call  4001d3c0 <rtems_rfs_file_set_size>       
4001f4dc:	90 10 00 10 	mov  %l0, %o0                                  
4001f4e0:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        
    if (rc)                                                           
4001f4e4:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001f4e8:	12 80 00 20 	bne  4001f568 <rtems_rfs_rtems_file_write+0xf4><== NEVER TAKEN
4001f4ec:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
    {                                                                 
      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);                              
4001f4f0:	d2 07 bf f8 	ld  [ %fp + -8 ], %o1                          
4001f4f4:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
4001f4f8:	7f ff eb 2e 	call  4001a1b0 <rtems_rfs_block_get_bpos>      
4001f4fc:	96 04 20 10 	add  %l0, 0x10, %o3                            
    write  += size;                                                   
                                                                      
    rc = rtems_rfs_file_io_end (file, size, false);                   
    if (rc)                                                           
    {                                                                 
      write = rtems_rfs_rtems_error ("file-write: write close", rc);  
4001f500:	10 80 00 3c 	b  4001f5f0 <rtems_rfs_rtems_file_write+0x17c> 
4001f504:	a2 10 20 00 	clr  %l1                                       
      return rtems_rfs_rtems_error ("file-write: write extend", rc);  
    }                                                                 
                                                                      
    rtems_rfs_file_set_bpos (file, pos);                              
  }                                                                   
  else if (pos < file_size && (iop->flags & LIBIO_FLAGS_APPEND) != 0) 
4001f508:	38 80 00 09 	bgu,a   4001f52c <rtems_rfs_rtems_file_write+0xb8><== NEVER TAKEN
4001f50c:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        <== NOT EXECUTED
4001f510:	80 a0 40 09 	cmp  %g1, %o1                                  
4001f514:	12 80 00 37 	bne  4001f5f0 <rtems_rfs_rtems_file_write+0x17c><== NEVER TAKEN
4001f518:	a2 10 20 00 	clr  %l1                                       
4001f51c:	80 a0 c0 0a 	cmp  %g3, %o2                                  
4001f520:	08 80 00 35 	bleu  4001f5f4 <rtems_rfs_rtems_file_write+0x180>
4001f524:	80 a6 a0 00 	cmp  %i2, 0                                    
4001f528:	c4 06 20 10 	ld  [ %i0 + 0x10 ], %g2                        
4001f52c:	80 88 a2 00 	btst  0x200, %g2                               
4001f530:	22 80 00 30 	be,a   4001f5f0 <rtems_rfs_rtems_file_write+0x17c>
4001f534:	a2 10 20 00 	clr  %l1                                       
  {                                                                   
    pos = file_size;                                                  
4001f538:	c2 27 bf f8 	st  %g1, [ %fp + -8 ]                          
4001f53c:	c6 27 bf fc 	st  %g3, [ %fp + -4 ]                          
    rc = rtems_rfs_file_seek (file, pos, &pos);                       
4001f540:	90 10 00 10 	mov  %l0, %o0                                  
4001f544:	92 10 00 01 	mov  %g1, %o1                                  
4001f548:	94 10 00 03 	mov  %g3, %o2                                  
4001f54c:	7f ff f7 5f 	call  4001d2c8 <rtems_rfs_file_seek>           
4001f550:	96 07 bf f8 	add  %fp, -8, %o3                              
    if (rc)                                                           
4001f554:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001f558:	22 80 00 26 	be,a   4001f5f0 <rtems_rfs_rtems_file_write+0x17c><== ALWAYS TAKEN
4001f55c:	a2 10 20 00 	clr  %l1                                       
    {                                                                 
      rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));              
4001f560:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        <== NOT EXECUTED
4001f564:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        <== NOT EXECUTED
4001f568:	7f ff ff 3c 	call  4001f258 <rtems_rfs_rtems_unlock>        <== NOT EXECUTED
4001f56c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
      return rtems_rfs_rtems_error ("file-write: write append seek", rc);
4001f570:	40 00 06 4b 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001f574:	01 00 00 00 	nop                                            <== NOT EXECUTED
4001f578:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
4001f57c:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001f580:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      
  while (count)                                                       
  {                                                                   
    size_t size = count;                                              
                                                                      
    rc = rtems_rfs_file_io_start (file, &size, false);                
4001f584:	90 10 00 10 	mov  %l0, %o0                                  
4001f588:	92 07 bf f4 	add  %fp, -12, %o1                             
4001f58c:	7f ff f6 1b 	call  4001cdf8 <rtems_rfs_file_io_start>       
4001f590:	94 10 20 00 	clr  %o2                                       
    if (rc)                                                           
4001f594:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001f598:	12 80 00 1b 	bne  4001f604 <rtems_rfs_rtems_file_write+0x190>
4001f59c:	c2 07 bf f4 	ld  [ %fp + -12 ], %g1                         
      if (!write)                                                     
        write = rtems_rfs_rtems_error ("file-write: write open", rc); 
      break;                                                          
    }                                                                 
                                                                      
    if (size > count)                                                 
4001f5a0:	80 a0 40 1a 	cmp  %g1, %i2                                  
4001f5a4:	38 80 00 02 	bgu,a   4001f5ac <rtems_rfs_rtems_file_write+0x138>
4001f5a8:	f4 27 bf f4 	st  %i2, [ %fp + -12 ]                         
      size = count;                                                   
                                                                      
    memcpy (rtems_rfs_file_data (file), data, size);                  
4001f5ac:	c2 04 20 0c 	ld  [ %l0 + 0xc ], %g1                         
4001f5b0:	d4 07 bf f4 	ld  [ %fp + -12 ], %o2                         
4001f5b4:	d0 00 60 1c 	ld  [ %g1 + 0x1c ], %o0                        
4001f5b8:	c2 04 20 14 	ld  [ %l0 + 0x14 ], %g1                        
4001f5bc:	92 10 00 19 	mov  %i1, %o1                                  
4001f5c0:	40 00 0a 26 	call  40021e58 <memcpy>                        
4001f5c4:	90 02 00 01 	add  %o0, %g1, %o0                             
                                                                      
    data  += size;                                                    
4001f5c8:	d2 07 bf f4 	ld  [ %fp + -12 ], %o1                         
    count -= size;                                                    
    write  += size;                                                   
                                                                      
    rc = rtems_rfs_file_io_end (file, size, false);                   
4001f5cc:	90 10 00 10 	mov  %l0, %o0                                  
    if (size > count)                                                 
      size = count;                                                   
                                                                      
    memcpy (rtems_rfs_file_data (file), data, size);                  
                                                                      
    data  += size;                                                    
4001f5d0:	b2 06 40 09 	add  %i1, %o1, %i1                             
    count -= size;                                                    
4001f5d4:	b4 26 80 09 	sub  %i2, %o1, %i2                             
    write  += size;                                                   
4001f5d8:	a2 04 40 09 	add  %l1, %o1, %l1                             
                                                                      
    rc = rtems_rfs_file_io_end (file, size, false);                   
4001f5dc:	7f ff f6 90 	call  4001d01c <rtems_rfs_file_io_end>         
4001f5e0:	94 10 20 00 	clr  %o2                                       
    if (rc)                                                           
4001f5e4:	ba 92 20 00 	orcc  %o0, 0, %i5                              
4001f5e8:	12 80 00 0a 	bne  4001f610 <rtems_rfs_rtems_file_write+0x19c><== NEVER TAKEN
4001f5ec:	01 00 00 00 	nop                                            
      rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));              
      return rtems_rfs_rtems_error ("file-write: write append seek", rc);
    }                                                                 
  }                                                                   
                                                                      
  while (count)                                                       
4001f5f0:	80 a6 a0 00 	cmp  %i2, 0                                    
4001f5f4:	32 bf ff e4 	bne,a   4001f584 <rtems_rfs_rtems_file_write+0x110>
4001f5f8:	f4 27 bf f4 	st  %i2, [ %fp + -12 ]                         
4001f5fc:	10 80 00 09 	b  4001f620 <rtems_rfs_rtems_file_write+0x1ac> 
4001f600:	80 a4 60 00 	cmp  %l1, 0                                    
      /*                                                              
       * If we have run out of space and have written some data return that
       * amount first as the inode will have accounted for it. This means
       * there was no error and the return code from can be ignored.  
       */                                                             
      if (!write)                                                     
4001f604:	80 a4 60 00 	cmp  %l1, 0                                    
4001f608:	12 80 00 06 	bne  4001f620 <rtems_rfs_rtems_file_write+0x1ac>
4001f60c:	01 00 00 00 	nop                                            
    write  += size;                                                   
                                                                      
    rc = rtems_rfs_file_io_end (file, size, false);                   
    if (rc)                                                           
    {                                                                 
      write = rtems_rfs_rtems_error ("file-write: write close", rc);  
4001f610:	40 00 06 23 	call  40020e9c <__errno>                       
4001f614:	a2 10 3f ff 	mov  -1, %l1	! ffffffff <RAM_END+0xbfbfffff>   
4001f618:	10 80 00 08 	b  4001f638 <rtems_rfs_rtems_file_write+0x1c4> 
4001f61c:	fa 22 00 00 	st  %i5, [ %o0 ]                               
      break;                                                          
    }                                                                 
  }                                                                   
                                                                      
  if (write >= 0)                                                     
4001f620:	06 80 00 06 	bl  4001f638 <rtems_rfs_rtems_file_write+0x1c4><== NEVER TAKEN
4001f624:	f8 1f bf f8 	ldd  [ %fp + -8 ], %i4                         
    iop->offset = pos + write;                                        
4001f628:	85 3c 60 1f 	sra  %l1, 0x1f, %g2                            
4001f62c:	b6 84 40 1d 	addcc  %l1, %i5, %i3                           
4001f630:	b4 40 80 1c 	addx  %g2, %i4, %i2                            
4001f634:	f4 3e 20 08 	std  %i2, [ %i0 + 8 ]                          
                                                                      
  rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));                  
4001f638:	c2 04 20 1c 	ld  [ %l0 + 0x1c ], %g1                        
                                                                      
  return write;                                                       
4001f63c:	b0 10 00 11 	mov  %l1, %i0                                  
  }                                                                   
                                                                      
  if (write >= 0)                                                     
    iop->offset = pos + write;                                        
                                                                      
  rtems_rfs_rtems_unlock (rtems_rfs_file_fs (file));                  
4001f640:	7f ff ff 06 	call  4001f258 <rtems_rfs_rtems_unlock>        
4001f644:	d0 00 60 98 	ld  [ %g1 + 0x98 ], %o0                        
                                                                      
  return write;                                                       
}                                                                     
4001f648:	81 c7 e0 08 	ret                                            
4001f64c:	81 e8 00 00 	restore                                        
                                                                      

400130fc <rtems_rfs_rtems_fstat>: } int rtems_rfs_rtems_fstat (const rtems_filesystem_location_info_t* pathloc, struct stat* buf) {
400130fc:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
40013100:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  int                    rc;                                          
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_STAT))             
    printf ("rtems-rfs-rtems: stat: in: ino:%" PRId32 "\n", ino);     
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40013104:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
                                                                      
int                                                                   
rtems_rfs_rtems_fstat (const rtems_filesystem_location_info_t* pathloc,
                       struct stat*                            buf)   
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
40013108:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
  int                    rc;                                          
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_STAT))             
    printf ("rtems-rfs-rtems: stat: in: ino:%" PRId32 "\n", ino);     
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
4001310c:	94 07 bf d8 	add  %fp, -40, %o2                             
40013110:	90 10 00 1d 	mov  %i5, %o0                                  
40013114:	7f ff fa f2 	call  40011cdc <rtems_rfs_inode_open>          
40013118:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001311c:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40013120:	02 80 00 07 	be  4001313c <rtems_rfs_rtems_fstat+0x40>      <== ALWAYS TAKEN
40013124:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  {                                                                   
    return rtems_rfs_rtems_error ("stat: opening inode", rc);         
40013128:	40 00 37 5d 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001312c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40013130:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
40013134:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013138:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  mode = rtems_rfs_inode_get_mode (&inode);                           
                                                                      
  if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK (mode))           
4001313c:	07 3f ff ec 	sethi  %hi(0xffffb000), %g3                    
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
40013140:	c4 08 60 02 	ldub  [ %g1 + 2 ], %g2                         
40013144:	d0 08 60 03 	ldub  [ %g1 + 3 ], %o0                         
40013148:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001314c:	90 10 80 08 	or  %g2, %o0, %o0                              
40013150:	84 08 80 03 	and  %g2, %g3, %g2                             
40013154:	07 00 00 08 	sethi  %hi(0x2000), %g3                        
40013158:	80 a0 80 03 	cmp  %g2, %g3                                  
4001315c:	32 80 00 19 	bne,a   400131c0 <rtems_rfs_rtems_fstat+0xc4>  <== ALWAYS TAKEN
40013160:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
 * @retval block 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]);      
40013164:	c6 08 60 20 	ldub  [ %g1 + 0x20 ], %g3                      <== NOT EXECUTED
40013168:	c4 08 60 21 	ldub  [ %g1 + 0x21 ], %g2                      <== NOT EXECUTED
4001316c:	87 28 e0 18 	sll  %g3, 0x18, %g3                            <== NOT EXECUTED
40013170:	85 28 a0 10 	sll  %g2, 0x10, %g2                            <== NOT EXECUTED
40013174:	84 10 c0 02 	or  %g3, %g2, %g2                              <== NOT EXECUTED
40013178:	c6 08 60 23 	ldub  [ %g1 + 0x23 ], %g3                      <== NOT EXECUTED
4001317c:	c8 08 60 1c 	ldub  [ %g1 + 0x1c ], %g4                      <== NOT EXECUTED
40013180:	84 10 80 03 	or  %g2, %g3, %g2                              <== NOT EXECUTED
40013184:	c6 08 60 22 	ldub  [ %g1 + 0x22 ], %g3                      <== NOT EXECUTED
40013188:	89 29 20 18 	sll  %g4, 0x18, %g4                            <== NOT EXECUTED
4001318c:	87 28 e0 08 	sll  %g3, 8, %g3                               <== NOT EXECUTED
40013190:	84 10 80 03 	or  %g2, %g3, %g2                              <== NOT EXECUTED
40013194:	c6 08 60 1d 	ldub  [ %g1 + 0x1d ], %g3                      <== NOT EXECUTED
40013198:	87 28 e0 10 	sll  %g3, 0x10, %g3                            <== NOT EXECUTED
4001319c:	88 11 00 03 	or  %g4, %g3, %g4                              <== NOT EXECUTED
400131a0:	c6 08 60 1f 	ldub  [ %g1 + 0x1f ], %g3                      <== NOT EXECUTED
400131a4:	88 11 00 03 	or  %g4, %g3, %g4                              <== NOT EXECUTED
400131a8:	c6 08 60 1e 	ldub  [ %g1 + 0x1e ], %g3                      <== NOT EXECUTED
  {                                                                   
    buf->st_rdev =                                                    
400131ac:	c4 26 60 1c 	st  %g2, [ %i1 + 0x1c ]                        <== NOT EXECUTED
400131b0:	87 28 e0 08 	sll  %g3, 8, %g3                               <== NOT EXECUTED
400131b4:	82 11 00 03 	or  %g4, %g3, %g1                              <== NOT EXECUTED
400131b8:	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);                         
400131bc:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        <== NOT EXECUTED
  buf->st_ino     = rtems_rfs_inode_ino (&inode);                     
  buf->st_mode    = rtems_rfs_rtems_mode (mode);                      
400131c0:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
    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);                         
400131c4:	c2 26 60 04 	st  %g1, [ %i1 + 4 ]                           
400131c8:	83 38 60 1f 	sra  %g1, 0x1f, %g1                            
400131cc:	c2 26 40 00 	st  %g1, [ %i1 ]                               
  buf->st_ino     = rtems_rfs_inode_ino (&inode);                     
400131d0:	c2 07 bf e0 	ld  [ %fp + -32 ], %g1                         
  buf->st_mode    = rtems_rfs_rtems_mode (mode);                      
400131d4:	91 32 20 10 	srl  %o0, 0x10, %o0                            
400131d8:	40 00 01 1b 	call  40013644 <rtems_rfs_rtems_mode>          
400131dc:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]                           
  buf->st_nlink   = rtems_rfs_inode_get_links (&inode);               
400131e0:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
                                   rtems_rfs_inode_get_block (&inode, 1));
  }                                                                   
                                                                      
  buf->st_dev     = rtems_rfs_fs_device (fs);                         
  buf->st_ino     = rtems_rfs_inode_ino (&inode);                     
  buf->st_mode    = rtems_rfs_rtems_mode (mode);                      
400131e4:	d0 26 60 0c 	st  %o0, [ %i1 + 0xc ]                         
 */                                                                   
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);                  
400131e8:	c6 08 60 01 	ldub  [ %g1 + 1 ], %g3                         
400131ec:	c4 08 40 00 	ldub  [ %g1 ], %g2                             
  if (links == 0xffff)                                                
400131f0:	09 3f ff c0 	sethi  %hi(0xffff0000), %g4                    
 */                                                                   
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);                  
400131f4:	85 28 a0 08 	sll  %g2, 8, %g2                               
400131f8:	84 10 80 03 	or  %g2, %g3, %g2                              
  if (links == 0xffff)                                                
400131fc:	87 28 a0 10 	sll  %g2, 0x10, %g3                            
40013200:	87 30 e0 10 	srl  %g3, 0x10, %g3                            
    links = 0;                                                        
40013204:	86 39 00 03 	xnor  %g4, %g3, %g3                            
40013208:	80 a0 00 03 	cmp  %g0, %g3                                  
4001320c:	86 60 20 00 	subx  %g0, 0, %g3                              
40013210:	84 08 80 03 	and  %g2, %g3, %g2                             
  buf->st_nlink   = rtems_rfs_inode_get_links (&inode);               
40013214:	c4 36 60 10 	sth  %g2, [ %i1 + 0x10 ]                       
 * @retval uid The used id.                                           
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_uid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return rtems_rfs_read_u32 (&handle->node->owner) & 0xffff;          
40013218:	c4 08 60 06 	ldub  [ %g1 + 6 ], %g2                         
4001321c:	c6 08 60 07 	ldub  [ %g1 + 7 ], %g3                         
40013220:	85 28 a0 08 	sll  %g2, 8, %g2                               
40013224:	84 10 80 03 	or  %g2, %g3, %g2                              
  buf->st_uid     = rtems_rfs_inode_get_uid (&inode);                 
40013228:	c4 36 60 12 	sth  %g2, [ %i1 + 0x12 ]                       
 * @retval gid The grpup id.                                          
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_gid (rtems_rfs_inode_handle* handle)              
{                                                                     
  return (rtems_rfs_read_u32 (&handle->node->owner) >> 16) & 0xffff;  
4001322c:	c4 08 60 04 	ldub  [ %g1 + 4 ], %g2                         
40013230:	c2 08 60 05 	ldub  [ %g1 + 5 ], %g1                         
                                                                      
  /*                                                                  
   * 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, rtems_rfs_inode_ino (&inode));
40013234:	d2 07 bf e0 	ld  [ %fp + -32 ], %o1                         
40013238:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001323c:	83 28 60 10 	sll  %g1, 0x10, %g1                            
40013240:	82 10 80 01 	or  %g2, %g1, %g1                              
40013244:	83 30 60 10 	srl  %g1, 0x10, %g1                            
40013248:	90 10 00 1d 	mov  %i5, %o0                                  
4001324c:	40 00 29 26 	call  4001d6e4 <rtems_rfs_file_get_shared>     
40013250:	c2 36 60 14 	sth  %g1, [ %i1 + 0x14 ]                       
                                                                      
  if (shared)                                                         
40013254:	92 92 20 00 	orcc  %o0, 0, %o1                              
40013258:	02 80 00 16 	be  400132b0 <rtems_rfs_rtems_fstat+0x1b4>     
4001325c:	c4 06 60 0c 	ld  [ %i1 + 0xc ], %g2                         
  {                                                                   
    buf->st_atime   = rtems_rfs_file_shared_get_atime (shared);       
40013260:	c2 02 60 8c 	ld  [ %o1 + 0x8c ], %g1                        
40013264:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        
    buf->st_mtime   = rtems_rfs_file_shared_get_mtime (shared);       
40013268:	c2 02 60 90 	ld  [ %o1 + 0x90 ], %g1                        
4001326c:	c2 26 60 30 	st  %g1, [ %i1 + 0x30 ]                        
    buf->st_ctime   = rtems_rfs_file_shared_get_ctime (shared);       
40013270:	c2 02 60 94 	ld  [ %o1 + 0x94 ], %g1                        
40013274:	c2 26 60 38 	st  %g1, [ %i1 + 0x38 ]                        
    buf->st_blocks  = rtems_rfs_file_shared_get_block_count (shared); 
40013278:	c2 02 60 84 	ld  [ %o1 + 0x84 ], %g1                        
4001327c:	c2 26 60 44 	st  %g1, [ %i1 + 0x44 ]                        
                                                                      
    if (S_ISLNK (buf->st_mode))                                       
40013280:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
40013284:	84 08 80 01 	and  %g2, %g1, %g2                             
40013288:	03 00 00 28 	sethi  %hi(0xa000), %g1                        
4001328c:	80 a0 80 01 	cmp  %g2, %g1                                  
40013290:	12 80 00 04 	bne  400132a0 <rtems_rfs_rtems_fstat+0x1a4>    <== ALWAYS TAKEN
40013294:	90 10 00 1d 	mov  %i5, %o0                                  
      buf->st_size = rtems_rfs_file_shared_get_block_offset (shared); 
40013298:	10 80 00 3d 	b  4001338c <rtems_rfs_rtems_fstat+0x290>      <== NOT EXECUTED
4001329c:	c2 12 60 8a 	lduh  [ %o1 + 0x8a ], %g1                      <== 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);                
400132a0:	40 00 1b dd 	call  4001a214 <rtems_rfs_block_get_size>      
400132a4:	92 02 60 84 	add  %o1, 0x84, %o1                            
    buf->st_blocks  = rtems_rfs_inode_get_block_count (&inode);       
                                                                      
    if (S_ISLNK (buf->st_mode))                                       
      buf->st_size = rtems_rfs_inode_get_block_offset (&inode);       
    else                                                              
      buf->st_size = rtems_rfs_inode_get_size (fs, &inode);           
400132a8:	10 80 00 3f 	b  400133a4 <rtems_rfs_rtems_fstat+0x2a8>      
400132ac:	d0 3e 60 20 	std  %o0, [ %i1 + 0x20 ]                       
    else                                                              
      buf->st_size = rtems_rfs_file_shared_get_size (fs, shared);     
  }                                                                   
  else                                                                
  {                                                                   
    buf->st_atime   = rtems_rfs_inode_get_atime (&inode);             
400132b0:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
 * @retval atime 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);                   
400132b4:	c8 08 60 10 	ldub  [ %g1 + 0x10 ], %g4                      
400132b8:	c6 08 60 11 	ldub  [ %g1 + 0x11 ], %g3                      
400132bc:	89 29 20 18 	sll  %g4, 0x18, %g4                            
400132c0:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
400132c4:	86 11 00 03 	or  %g4, %g3, %g3                              
400132c8:	c8 08 60 13 	ldub  [ %g1 + 0x13 ], %g4                      
400132cc:	86 10 c0 04 	or  %g3, %g4, %g3                              
400132d0:	c8 08 60 12 	ldub  [ %g1 + 0x12 ], %g4                      
400132d4:	89 29 20 08 	sll  %g4, 8, %g4                               
400132d8:	86 10 c0 04 	or  %g3, %g4, %g3                              
400132dc:	c6 26 60 28 	st  %g3, [ %i1 + 0x28 ]                        
 * @retval mtime 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);                   
400132e0:	c8 08 60 14 	ldub  [ %g1 + 0x14 ], %g4                      
400132e4:	c6 08 60 15 	ldub  [ %g1 + 0x15 ], %g3                      
400132e8:	89 29 20 18 	sll  %g4, 0x18, %g4                            
400132ec:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
400132f0:	86 11 00 03 	or  %g4, %g3, %g3                              
400132f4:	c8 08 60 17 	ldub  [ %g1 + 0x17 ], %g4                      
400132f8:	86 10 c0 04 	or  %g3, %g4, %g3                              
400132fc:	c8 08 60 16 	ldub  [ %g1 + 0x16 ], %g4                      
40013300:	89 29 20 08 	sll  %g4, 8, %g4                               
40013304:	86 10 c0 04 	or  %g3, %g4, %g3                              
    buf->st_mtime   = rtems_rfs_inode_get_mtime (&inode);             
40013308:	c6 26 60 30 	st  %g3, [ %i1 + 0x30 ]                        
 * @retval ctime 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);                   
4001330c:	c8 08 60 18 	ldub  [ %g1 + 0x18 ], %g4                      
40013310:	c6 08 60 19 	ldub  [ %g1 + 0x19 ], %g3                      
40013314:	89 29 20 18 	sll  %g4, 0x18, %g4                            
40013318:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
4001331c:	86 11 00 03 	or  %g4, %g3, %g3                              
40013320:	c8 08 60 1b 	ldub  [ %g1 + 0x1b ], %g4                      
40013324:	86 10 c0 04 	or  %g3, %g4, %g3                              
40013328:	c8 08 60 1a 	ldub  [ %g1 + 0x1a ], %g4                      
4001332c:	89 29 20 08 	sll  %g4, 8, %g4                               
40013330:	86 10 c0 04 	or  %g3, %g4, %g3                              
    buf->st_ctime   = rtems_rfs_inode_get_ctime (&inode);             
40013334:	c6 26 60 38 	st  %g3, [ %i1 + 0x38 ]                        
 * @retval count 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);             
40013338:	c8 08 60 0c 	ldub  [ %g1 + 0xc ], %g4                       
4001333c:	c6 08 60 0d 	ldub  [ %g1 + 0xd ], %g3                       
40013340:	89 29 20 18 	sll  %g4, 0x18, %g4                            
40013344:	87 28 e0 10 	sll  %g3, 0x10, %g3                            
40013348:	86 11 00 03 	or  %g4, %g3, %g3                              
4001334c:	c8 08 60 0f 	ldub  [ %g1 + 0xf ], %g4                       
40013350:	86 10 c0 04 	or  %g3, %g4, %g3                              
40013354:	c8 08 60 0e 	ldub  [ %g1 + 0xe ], %g4                       
40013358:	89 29 20 08 	sll  %g4, 8, %g4                               
4001335c:	86 10 c0 04 	or  %g3, %g4, %g3                              
    buf->st_blocks  = rtems_rfs_inode_get_block_count (&inode);       
40013360:	c6 26 60 44 	st  %g3, [ %i1 + 0x44 ]                        
                                                                      
    if (S_ISLNK (buf->st_mode))                                       
40013364:	07 00 00 3c 	sethi  %hi(0xf000), %g3                        
40013368:	84 08 80 03 	and  %g2, %g3, %g2                             
4001336c:	07 00 00 28 	sethi  %hi(0xa000), %g3                        
40013370:	80 a0 80 03 	cmp  %g2, %g3                                  
40013374:	12 80 00 09 	bne  40013398 <rtems_rfs_rtems_fstat+0x29c>    
40013378:	90 10 00 1d 	mov  %i5, %o0                                  
 * @retval offset The block offset.                                   
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_block_offset (rtems_rfs_inode_handle* handle)     
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->block_offset);            
4001337c:	c4 08 60 0a 	ldub  [ %g1 + 0xa ], %g2                       
      buf->st_size = rtems_rfs_inode_get_block_offset (&inode);       
40013380:	c2 08 60 0b 	ldub  [ %g1 + 0xb ], %g1                       
40013384:	85 28 a0 08 	sll  %g2, 8, %g2                               
40013388:	82 10 40 02 	or  %g1, %g2, %g1                              
4001338c:	c0 26 60 20 	clr  [ %i1 + 0x20 ]                            
40013390:	10 80 00 05 	b  400133a4 <rtems_rfs_rtems_fstat+0x2a8>      
40013394:	c2 26 60 24 	st  %g1, [ %i1 + 0x24 ]                        
    else                                                              
      buf->st_size = rtems_rfs_inode_get_size (fs, &inode);           
40013398:	7f ff fc 75 	call  4001256c <rtems_rfs_inode_get_size>      
4001339c:	92 07 bf d8 	add  %fp, -40, %o1                             
400133a0:	d0 3e 60 20 	std  %o0, [ %i1 + 0x20 ]                       
  }                                                                   
                                                                      
  buf->st_blksize = rtems_rfs_fs_block_size (fs);                     
400133a4:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
400133a8:	90 10 00 1d 	mov  %i5, %o0                                  
      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);                     
400133ac:	c2 26 60 40 	st  %g1, [ %i1 + 0x40 ]                        
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
400133b0:	92 07 bf d8 	add  %fp, -40, %o1                             
400133b4:	7f ff fa bc 	call  40011ea4 <rtems_rfs_inode_close>         
400133b8:	b0 10 20 00 	clr  %i0                                       
  if (rc > 0)                                                         
400133bc:	80 a2 20 00 	cmp  %o0, 0                                    
400133c0:	04 80 00 05 	ble  400133d4 <rtems_rfs_rtems_fstat+0x2d8>    <== ALWAYS TAKEN
400133c4:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("stat: closing inode", rc);         
400133c8:	40 00 36 b5 	call  40020e9c <__errno>                       <== NOT EXECUTED
400133cc:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400133d0:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
400133d4:	81 c7 e0 08 	ret                                            
400133d8:	81 e8 00 00 	restore                                        
                                                                      

40012ce0 <rtems_rfs_rtems_initialise>: */ int rtems_rfs_rtems_initialise (rtems_filesystem_mount_table_entry_t* mt_entry, const void* data) {
40012ce0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  /*                                                                  
   * Parse the options the user specifiies.                           
   */                                                                 
  while (options)                                                     
  {                                                                   
    printf ("options=%s\n", options);                                 
40012ce4:	3b 10 00 cf 	sethi  %hi(0x40033c00), %i5                    
    if (strncmp (options, "hold-bitmaps",                             
40012ce8:	35 10 00 cf 	sethi  %hi(0x40033c00), %i2                    
                 sizeof ("hold-bitmaps") - 1) == 0)                   
      flags |= RTEMS_RFS_FS_BITMAPS_HOLD;                             
    else if (strncmp (options, "no-local-cache",                      
40012cec:	21 10 00 cf 	sethi  %hi(0x40033c00), %l0                    
                      sizeof ("no-local-cache") - 1) == 0)            
      flags |= RTEMS_RFS_FS_NO_LOCAL_CACHE;                           
    else if (strncmp (options, "max-held-bufs",                       
40012cf0:	23 10 00 cf 	sethi  %hi(0x40033c00), %l1                    
                            const void*                           data)
{                                                                     
  rtems_rfs_rtems_private* rtems;                                     
  rtems_rfs_file_system*   fs;                                        
  uint32_t                 flags = 0;                                 
  uint32_t                 max_held_buffers = RTEMS_RFS_FS_MAX_HELD_BUFFERS;
40012cf4:	b6 10 20 05 	mov  5, %i3                                    
rtems_rfs_rtems_initialise (rtems_filesystem_mount_table_entry_t* mt_entry,
                            const void*                           data)
{                                                                     
  rtems_rfs_rtems_private* rtems;                                     
  rtems_rfs_file_system*   fs;                                        
  uint32_t                 flags = 0;                                 
40012cf8:	b8 10 20 00 	clr  %i4                                       
  /*                                                                  
   * Parse the options the user specifiies.                           
   */                                                                 
  while (options)                                                     
  {                                                                   
    printf ("options=%s\n", options);                                 
40012cfc:	ba 17 62 b8 	or  %i5, 0x2b8, %i5                            
    if (strncmp (options, "hold-bitmaps",                             
40012d00:	b4 16 a2 c8 	or  %i2, 0x2c8, %i2                            
                 sizeof ("hold-bitmaps") - 1) == 0)                   
      flags |= RTEMS_RFS_FS_BITMAPS_HOLD;                             
    else if (strncmp (options, "no-local-cache",                      
40012d04:	a0 14 22 d8 	or  %l0, 0x2d8, %l0                            
                      sizeof ("no-local-cache") - 1) == 0)            
      flags |= RTEMS_RFS_FS_NO_LOCAL_CACHE;                           
    else if (strncmp (options, "max-held-bufs",                       
40012d08:	a2 14 62 e8 	or  %l1, 0x2e8, %l1                            
  int                      rc;                                        
                                                                      
  /*                                                                  
   * Parse the options the user specifiies.                           
   */                                                                 
  while (options)                                                     
40012d0c:	80 a6 60 00 	cmp  %i1, 0                                    
40012d10:	02 80 00 2e 	be  40012dc8 <rtems_rfs_rtems_initialise+0xe8> <== ALWAYS TAKEN
40012d14:	92 10 00 19 	mov  %i1, %o1                                  
  {                                                                   
    printf ("options=%s\n", options);                                 
40012d18:	40 00 3d 5c 	call  40022288 <printf>                        <== NOT EXECUTED
40012d1c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    if (strncmp (options, "hold-bitmaps",                             
40012d20:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40012d24:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
40012d28:	40 00 41 ed 	call  400234dc <strncmp>                       <== NOT EXECUTED
40012d2c:	94 10 20 0c 	mov  0xc, %o2                                  <== NOT EXECUTED
40012d30:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40012d34:	12 80 00 04 	bne  40012d44 <rtems_rfs_rtems_initialise+0x64><== NOT EXECUTED
40012d38:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40012d3c:	10 80 00 1a 	b  40012da4 <rtems_rfs_rtems_initialise+0xc4>  <== NOT EXECUTED
40012d40:	b8 17 20 01 	or  %i4, 1, %i4                                <== NOT EXECUTED
                 sizeof ("hold-bitmaps") - 1) == 0)                   
      flags |= RTEMS_RFS_FS_BITMAPS_HOLD;                             
    else if (strncmp (options, "no-local-cache",                      
40012d44:	92 10 00 10 	mov  %l0, %o1                                  <== NOT EXECUTED
40012d48:	40 00 41 e5 	call  400234dc <strncmp>                       <== NOT EXECUTED
40012d4c:	94 10 20 0e 	mov  0xe, %o2                                  <== NOT EXECUTED
40012d50:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40012d54:	12 80 00 04 	bne  40012d64 <rtems_rfs_rtems_initialise+0x84><== NOT EXECUTED
40012d58:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40012d5c:	10 80 00 12 	b  40012da4 <rtems_rfs_rtems_initialise+0xc4>  <== NOT EXECUTED
40012d60:	b8 17 20 02 	or  %i4, 2, %i4                                <== NOT EXECUTED
                      sizeof ("no-local-cache") - 1) == 0)            
      flags |= RTEMS_RFS_FS_NO_LOCAL_CACHE;                           
    else if (strncmp (options, "max-held-bufs",                       
40012d64:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
40012d68:	40 00 41 dd 	call  400234dc <strncmp>                       <== NOT EXECUTED
40012d6c:	94 10 20 0d 	mov  0xd, %o2                                  <== NOT EXECUTED
40012d70:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40012d74:	12 80 00 07 	bne  40012d90 <rtems_rfs_rtems_initialise+0xb0><== NOT EXECUTED
40012d78:	92 10 20 00 	clr  %o1                                       <== NOT EXECUTED
                      sizeof ("max-held-bufs") - 1) == 0)             
    {                                                                 
      max_held_buffers = strtoul (options + sizeof ("max-held-bufs"), 0, 0);
40012d7c:	90 06 60 0e 	add  %i1, 0xe, %o0                             <== NOT EXECUTED
40012d80:	40 00 42 b0 	call  40023840 <strtoul>                       <== NOT EXECUTED
40012d84:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
40012d88:	10 80 00 06 	b  40012da0 <rtems_rfs_rtems_initialise+0xc0>  <== NOT EXECUTED
40012d8c:	b6 10 00 08 	mov  %o0, %i3                                  <== NOT EXECUTED
    }                                                                 
    else                                                              
      return rtems_rfs_rtems_error ("initialise: invalid option", EINVAL);
40012d90:	40 00 38 43 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012d94:	01 00 00 00 	nop                                            <== NOT EXECUTED
40012d98:	10 80 00 14 	b  40012de8 <rtems_rfs_rtems_initialise+0x108> <== NOT EXECUTED
40012d9c:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
                                                                      
    options = strchr (options, ',');                                  
40012da0:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
40012da4:	40 00 3f 1e 	call  40022a1c <strchr>                        <== NOT EXECUTED
40012da8:	92 10 20 2c 	mov  0x2c, %o1                                 <== NOT EXECUTED
    if (options)                                                      
40012dac:	b2 92 20 00 	orcc  %o0, 0, %i1                              <== NOT EXECUTED
40012db0:	02 80 00 06 	be  40012dc8 <rtems_rfs_rtems_initialise+0xe8> <== NOT EXECUTED
40012db4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    {                                                                 
      ++options;                                                      
      if (*options == '\0')                                           
40012db8:	c2 4e 60 01 	ldsb  [ %i1 + 1 ], %g1                         <== NOT EXECUTED
40012dbc:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40012dc0:	12 bf ff d3 	bne  40012d0c <rtems_rfs_rtems_initialise+0x2c><== NOT EXECUTED
40012dc4:	b2 06 60 01 	inc  %i1                                       <== NOT EXECUTED
        options = NULL;                                               
    }                                                                 
  }                                                                   
                                                                      
  rtems = malloc (sizeof (rtems_rfs_rtems_private));                  
40012dc8:	7f ff d5 e7 	call  40008564 <malloc>                        
40012dcc:	90 10 20 04 	mov  4, %o0                                    
  if (!rtems)                                                         
40012dd0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40012dd4:	12 80 00 08 	bne  40012df4 <rtems_rfs_rtems_initialise+0x114><== ALWAYS TAKEN
40012dd8:	01 00 00 00 	nop                                            
    return rtems_rfs_rtems_error ("initialise: local data", ENOMEM);  
40012ddc:	40 00 38 30 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012de0:	01 00 00 00 	nop                                            <== NOT EXECUTED
40012de4:	82 10 20 0c 	mov  0xc, %g1	! c <_TLS_Alignment+0xb>         <== NOT EXECUTED
40012de8:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40012dec:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012df0:	91 e8 3f ff 	restore  %g0, -1, %o0                          <== NOT EXECUTED
                                                                      
  memset (rtems, 0, sizeof (rtems_rfs_rtems_private));                
                                                                      
  rc = rtems_rfs_mutex_create (&rtems->access);                       
40012df4:	40 00 2f ad 	call  4001eca8 <rtems_rfs_mutex_create>        
40012df8:	c0 27 40 00 	clr  [ %i5 ]                                   
  if (rc > 0)                                                         
40012dfc:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40012e00:	14 80 00 09 	bg  40012e24 <rtems_rfs_rtems_initialise+0x144><== NEVER TAKEN
40012e04:	01 00 00 00 	nop                                            
  {                                                                   
    free (rtems);                                                     
    return rtems_rfs_rtems_error ("initialise: cannot create mutex", rc);
  }                                                                   
                                                                      
  rc = rtems_rfs_mutex_lock (&rtems->access);                         
40012e08:	7f ff ff 9e 	call  40012c80 <rtems_rfs_mutex_lock.isra.20>  
40012e0c:	d0 07 40 00 	ld  [ %i5 ], %o0                               
  if (rc > 0)                                                         
40012e10:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40012e14:	24 80 00 0b 	ble,a   40012e40 <rtems_rfs_rtems_initialise+0x160><== ALWAYS TAKEN
40012e18:	d0 06 20 38 	ld  [ %i0 + 0x38 ], %o0                        
  {                                                                   
    rtems_rfs_mutex_destroy (&rtems->access);                         
40012e1c:	40 00 2f be 	call  4001ed14 <rtems_rfs_mutex_destroy>       <== NOT EXECUTED
40012e20:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    free (rtems);                                                     
40012e24:	7f ff d4 42 	call  40007f2c <free>                          <== NOT EXECUTED
40012e28:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("initialise: cannot lock access  mutex", rc);
40012e2c:	40 00 38 1c 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012e30:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012e34:	f4 22 00 00 	st  %i2, [ %o0 ]                               <== NOT EXECUTED
40012e38:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012e3c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_fs_open (mt_entry->dev, rtems, flags, max_held_buffers, &fs);
40012e40:	92 10 00 1d 	mov  %i5, %o1                                  
40012e44:	94 10 00 1c 	mov  %i4, %o2                                  
40012e48:	96 10 00 1b 	mov  %i3, %o3                                  
40012e4c:	40 00 2b 0a 	call  4001da74 <rtems_rfs_fs_open>             
40012e50:	98 07 bf fc 	add  %fp, -4, %o4                              
  if (rc)                                                             
40012e54:	80 a2 20 00 	cmp  %o0, 0                                    
40012e58:	02 80 00 0e 	be  40012e90 <rtems_rfs_rtems_initialise+0x1b0><== ALWAYS TAKEN
40012e5c:	d0 07 bf fc 	ld  [ %fp + -4 ], %o0                          
  {                                                                   
    free (rtems);                                                     
40012e60:	7f ff d4 33 	call  40007f2c <free>                          <== NOT EXECUTED
40012e64:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("initialise: open", errno);         
40012e68:	40 00 38 0d 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012e6c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40012e70:	40 00 38 0b 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012e74:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
40012e78:	c2 02 00 00 	ld  [ %o0 ], %g1                               <== NOT EXECUTED
40012e7c:	80 a0 00 01 	cmp  %g0, %g1                                  <== NOT EXECUTED
40012e80:	c2 27 40 00 	st  %g1, [ %i5 ]                               <== NOT EXECUTED
40012e84:	b0 60 20 00 	subx  %g0, 0, %i0                              <== NOT EXECUTED
40012e88:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012e8c:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  mt_entry->fs_info                          = fs;                    
  mt_entry->ops                              = &rtems_rfs_ops;        
40012e90:	03 10 00 cf 	sethi  %hi(0x40033c00), %g1                    
40012e94:	82 10 62 f8 	or  %g1, 0x2f8, %g1	! 40033ef8 <rtems_rfs_ops> 
40012e98:	c2 26 20 0c 	st  %g1, [ %i0 + 0xc ]                         
  mt_entry->mt_fs_root->location.node_access = (void*) RTEMS_RFS_ROOT_INO;
40012e9c:	c2 06 20 24 	ld  [ %i0 + 0x24 ], %g1                        
  {                                                                   
    free (rtems);                                                     
    return rtems_rfs_rtems_error ("initialise: open", errno);         
  }                                                                   
                                                                      
  mt_entry->fs_info                          = fs;                    
40012ea0:	d0 26 20 08 	st  %o0, [ %i0 + 8 ]                           
  mt_entry->ops                              = &rtems_rfs_ops;        
  mt_entry->mt_fs_root->location.node_access = (void*) RTEMS_RFS_ROOT_INO;
40012ea4:	84 10 20 01 	mov  1, %g2                                    
40012ea8:	c4 20 60 08 	st  %g2, [ %g1 + 8 ]                           
  mt_entry->mt_fs_root->location.handlers    = &rtems_rfs_rtems_dir_handlers;
40012eac:	05 10 00 d7 	sethi  %hi(0x40035c00), %g2                    
40012eb0:	84 10 a2 38 	or  %g2, 0x238, %g2	! 40035e38 <rtems_rfs_rtems_dir_handlers>
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
                                                                      
  return 0;                                                           
40012eb4:	b0 10 20 00 	clr  %i0                                       
  mt_entry->fs_info                          = fs;                    
  mt_entry->ops                              = &rtems_rfs_ops;        
  mt_entry->mt_fs_root->location.node_access = (void*) RTEMS_RFS_ROOT_INO;
  mt_entry->mt_fs_root->location.handlers    = &rtems_rfs_rtems_dir_handlers;
                                                                      
  rtems_rfs_rtems_unlock (fs);                                        
40012eb8:	7f ff ff 59 	call  40012c1c <rtems_rfs_rtems_unlock>        
40012ebc:	c4 20 60 10 	st  %g2, [ %g1 + 0x10 ]                        
                                                                      
  return 0;                                                           
}                                                                     
40012ec0:	81 c7 e0 08 	ret                                            
40012ec4:	81 e8 00 00 	restore                                        
                                                                      

40012968 <rtems_rfs_rtems_link>: static int rtems_rfs_rtems_link (const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *targetloc, const char *name, size_t namelen) {
40012968:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (targetloc);
4001296c:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_LINK))             
    printf ("rtems-rfs-rtems: link: in: parent:%" PRId32 " target:%" PRId32 "\n",
            parent, target);                                          
                                                                      
  rc = rtems_rfs_link (fs, name, namelen, parent, target, false);     
40012970:	d6 06 20 08 	ld  [ %i0 + 8 ], %o3                           
40012974:	d0 00 60 08 	ld  [ %g1 + 8 ], %o0                           
40012978:	d8 06 60 08 	ld  [ %i1 + 8 ], %o4                           
4001297c:	92 10 00 1a 	mov  %i2, %o1                                  
40012980:	94 10 00 1b 	mov  %i3, %o2                                  
40012984:	9a 10 20 00 	clr  %o5                                       
40012988:	40 00 2e 59 	call  4001e2ec <rtems_rfs_link>                
4001298c:	b0 10 20 00 	clr  %i0                                       
  if (rc)                                                             
40012990:	80 a2 20 00 	cmp  %o0, 0                                    
40012994:	02 80 00 05 	be  400129a8 <rtems_rfs_rtems_link+0x40>       <== ALWAYS TAKEN
40012998:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("link: linking", rc);               
4001299c:	40 00 39 40 	call  40020e9c <__errno>                       <== NOT EXECUTED
400129a0:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400129a4:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
	}                                                                    
                                                                      
                                                                      
	return 0;                                                            
}                                                                     
400129a8:	81 c7 e0 08 	ret                                            
400129ac:	81 e8 00 00 	restore                                        
                                                                      

400133dc <rtems_rfs_rtems_mknod>: rtems_rfs_rtems_mknod (const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, mode_t mode, dev_t dev) {
400133dc:	9d e3 bf 60 	save  %sp, -160, %sp                           
  rtems_rfs_file_system*  fs = rtems_rfs_rtems_pathloc_dev (parentloc);
400133e0:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  rtems_rfs_ino           parent = rtems_rfs_rtems_get_pathloc_ino (parentloc);
400133e4:	f0 06 20 08 	ld  [ %i0 + 8 ], %i0                           
  rtems_rfs_inode_handle  inode;                                      
  uid_t                   uid;                                        
  gid_t                   gid;                                        
  int                     rc;                                         
                                                                      
  uid = geteuid ();                                                   
400133e8:	40 00 0d 22 	call  40016870 <geteuid>                       
400133ec:	e0 00 60 08 	ld  [ %g1 + 8 ], %l0                           
  gid = getegid ();                                                   
400133f0:	40 00 0d 1a 	call  40016858 <getegid>                       
400133f4:	a4 10 00 08 	mov  %o0, %l2                                  
400133f8:	a2 10 00 08 	mov  %o0, %l1                                  
                                                                      
  rc = rtems_rfs_inode_create (fs, parent, name, namelen,             
400133fc:	40 00 00 8f 	call  40013638 <rtems_rfs_rtems_imode>         
40013400:	90 10 00 1b 	mov  %i3, %o0                                  
40013404:	82 07 bf d4 	add  %fp, -44, %g1                             
40013408:	99 2a 20 10 	sll  %o0, 0x10, %o4                            
4001340c:	96 10 00 1a 	mov  %i2, %o3                                  
40013410:	a5 2c a0 10 	sll  %l2, 0x10, %l2                            
40013414:	a3 2c 60 10 	sll  %l1, 0x10, %l1                            
40013418:	a5 34 a0 10 	srl  %l2, 0x10, %l2                            
4001341c:	a3 34 60 10 	srl  %l1, 0x10, %l1                            
40013420:	e4 23 a0 5c 	st  %l2, [ %sp + 0x5c ]                        
40013424:	e2 23 a0 60 	st  %l1, [ %sp + 0x60 ]                        
40013428:	c2 23 a0 64 	st  %g1, [ %sp + 0x64 ]                        
4001342c:	90 10 00 10 	mov  %l0, %o0                                  
40013430:	92 10 00 18 	mov  %i0, %o1                                  
40013434:	94 10 00 19 	mov  %i1, %o2                                  
40013438:	99 33 20 10 	srl  %o4, 0x10, %o4                            
4001343c:	7f ff fb 72 	call  40012204 <rtems_rfs_inode_create>        
40013440:	9a 10 20 01 	mov  1, %o5                                    
                               rtems_rfs_rtems_imode (mode),          
                               1, uid, gid, &ino);                    
  if (rc > 0)                                                         
40013444:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40013448:	14 80 00 09 	bg  4001346c <rtems_rfs_rtems_mknod+0x90>      
4001344c:	d2 07 bf d4 	ld  [ %fp + -44 ], %o1                         
  {                                                                   
    return rtems_rfs_rtems_error ("mknod: inode create", rc);         
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40013450:	90 10 00 10 	mov  %l0, %o0                                  
40013454:	94 07 bf d8 	add  %fp, -40, %o2                             
40013458:	7f ff fa 21 	call  40011cdc <rtems_rfs_inode_open>          
4001345c:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
40013460:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40013464:	04 80 00 07 	ble  40013480 <rtems_rfs_rtems_mknod+0xa4>     <== ALWAYS TAKEN
40013468:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
  {                                                                   
    return rtems_rfs_rtems_error ("mknod: inode open", rc);           
4001346c:	40 00 36 8c 	call  40020e9c <__errno>                       
40013470:	b0 10 3f ff 	mov  -1, %i0                                   
40013474:	f4 22 00 00 	st  %i2, [ %o0 ]                               
40013478:	81 c7 e0 08 	ret                                            
4001347c:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  if (S_ISDIR(mode) || S_ISREG(mode))                                 
40013480:	05 00 00 20 	sethi  %hi(0x8000), %g2                        
40013484:	82 0e c0 01 	and  %i3, %g1, %g1                             
40013488:	80 a0 40 02 	cmp  %g1, %g2                                  
4001348c:	02 80 00 24 	be  4001351c <rtems_rfs_rtems_mknod+0x140>     
40013490:	05 00 00 10 	sethi  %hi(0x4000), %g2                        
40013494:	80 a0 40 02 	cmp  %g1, %g2                                  
40013498:	02 80 00 21 	be  4001351c <rtems_rfs_rtems_mknod+0x140>     <== ALWAYS TAKEN
4001349c:	03 00 00 2c 	sethi  %hi(0xb000), %g1                        
  {                                                                   
  }                                                                   
  else if (S_ISCHR (mode) || S_ISBLK (mode))                          
400134a0:	b6 0e c0 01 	and  %i3, %g1, %i3                             <== NOT EXECUTED
400134a4:	03 00 00 08 	sethi  %hi(0x2000), %g1                        <== NOT EXECUTED
400134a8:	80 a6 c0 01 	cmp  %i3, %g1                                  <== NOT EXECUTED
400134ac:	12 80 00 13 	bne  400134f8 <rtems_rfs_rtems_mknod+0x11c>    <== NOT EXECUTED
400134b0:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         <== NOT EXECUTED
 * @param[in] bno is 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);       
400134b4:	85 37 20 18 	srl  %i4, 0x18, %g2                            <== NOT EXECUTED
400134b8:	c4 28 60 1c 	stb  %g2, [ %g1 + 0x1c ]                       <== NOT EXECUTED
400134bc:	85 37 20 10 	srl  %i4, 0x10, %g2                            <== NOT EXECUTED
400134c0:	c4 28 60 1d 	stb  %g2, [ %g1 + 0x1d ]                       <== NOT EXECUTED
400134c4:	85 37 20 08 	srl  %i4, 8, %g2                               <== NOT EXECUTED
400134c8:	c4 28 60 1e 	stb  %g2, [ %g1 + 0x1e ]                       <== NOT EXECUTED
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
400134cc:	84 10 20 01 	mov  1, %g2                                    <== NOT EXECUTED
400134d0:	c4 2f bf e8 	stb  %g2, [ %fp + -24 ]                        <== NOT EXECUTED
 * @param[in] bno is 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);       
400134d4:	85 37 60 18 	srl  %i5, 0x18, %g2                            <== NOT EXECUTED
400134d8:	c4 28 60 20 	stb  %g2, [ %g1 + 0x20 ]                       <== NOT EXECUTED
400134dc:	85 37 60 10 	srl  %i5, 0x10, %g2                            <== NOT EXECUTED
400134e0:	f8 28 60 1f 	stb  %i4, [ %g1 + 0x1f ]                       <== NOT EXECUTED
400134e4:	c4 28 60 21 	stb  %g2, [ %g1 + 0x21 ]                       <== NOT EXECUTED
400134e8:	fa 28 60 23 	stb  %i5, [ %g1 + 0x23 ]                       <== NOT EXECUTED
400134ec:	85 37 60 08 	srl  %i5, 8, %g2                               <== NOT EXECUTED
400134f0:	10 80 00 0b 	b  4001351c <rtems_rfs_rtems_mknod+0x140>      <== NOT EXECUTED
400134f4:	c4 28 60 22 	stb  %g2, [ %g1 + 0x22 ]                       <== 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);                               
400134f8:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
400134fc:	7f ff fa 6a 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
40013500:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    return rtems_rfs_rtems_error ("mknod: bad mode", EINVAL);         
40013504:	40 00 36 66 	call  40020e9c <__errno>                       <== NOT EXECUTED
40013508:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001350c:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
40013510:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
40013514:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013518:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
4001351c:	90 10 00 10 	mov  %l0, %o0                                  
40013520:	92 07 bf d8 	add  %fp, -40, %o1                             
40013524:	7f ff fa 60 	call  40011ea4 <rtems_rfs_inode_close>         
40013528:	b0 10 20 00 	clr  %i0                                       
  if (rc > 0)                                                         
4001352c:	80 a2 20 00 	cmp  %o0, 0                                    
40013530:	04 80 00 05 	ble  40013544 <rtems_rfs_rtems_mknod+0x168>    <== ALWAYS TAKEN
40013534:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("mknod: closing inode", rc);        
40013538:	40 00 36 59 	call  40020e9c <__errno>                       <== NOT EXECUTED
4001353c:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40013540:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40013544:	81 c7 e0 08 	ret                                            
40013548:	81 e8 00 00 	restore                                        
                                                                      

40012788 <rtems_rfs_rtems_node_type>: * @return rtems_filesystem_node_types_t */ static rtems_filesystem_node_types_t rtems_rfs_rtems_node_type (const rtems_filesystem_location_info_t* pathloc) {
40012788:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_rfs_file_system*        fs = rtems_rfs_rtems_pathloc_dev (pathloc);
4001278c:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  rtems_rfs_ino                 ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
  rtems_filesystem_node_types_t type;                                 
  rtems_rfs_inode_handle        inode;                                
  int                           rc;                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012790:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
 */                                                                   
                                                                      
static rtems_filesystem_node_types_t                                  
rtems_rfs_rtems_node_type (const rtems_filesystem_location_info_t* pathloc)
{                                                                     
  rtems_rfs_file_system*        fs = rtems_rfs_rtems_pathloc_dev (pathloc);
40012794:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
  rtems_rfs_ino                 ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
  rtems_filesystem_node_types_t type;                                 
  rtems_rfs_inode_handle        inode;                                
  int                           rc;                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012798:	94 07 bf d8 	add  %fp, -40, %o2                             
4001279c:	90 10 00 1d 	mov  %i5, %o0                                  
400127a0:	7f ff fd 4f 	call  40011cdc <rtems_rfs_inode_open>          
400127a4:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
400127a8:	b8 92 20 00 	orcc  %o0, 0, %i4                              
400127ac:	04 80 00 07 	ble  400127c8 <rtems_rfs_rtems_node_type+0x40> <== ALWAYS TAKEN
400127b0:	01 00 00 00 	nop                                            
  {                                                                   
    return rtems_rfs_rtems_error ("node_type: opening inode", rc);    
400127b4:	40 00 39 ba 	call  40020e9c <__errno>                       <== NOT EXECUTED
400127b8:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
400127bc:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
400127c0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400127c4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
                                                                      
  type = rtems_rfs_rtems_node_type_by_inode (&inode);                 
400127c8:	7f ff ff 81 	call  400125cc <rtems_rfs_rtems_node_type_by_inode>
400127cc:	90 07 bf d8 	add  %fp, -40, %o0                             
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
400127d0:	92 07 bf d8 	add  %fp, -40, %o1                             
  if (rc > 0)                                                         
  {                                                                   
    return rtems_rfs_rtems_error ("node_type: opening inode", rc);    
  }                                                                   
                                                                      
  type = rtems_rfs_rtems_node_type_by_inode (&inode);                 
400127d4:	b0 10 00 08 	mov  %o0, %i0                                  
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
400127d8:	7f ff fd b3 	call  40011ea4 <rtems_rfs_inode_close>         
400127dc:	90 10 00 1d 	mov  %i5, %o0                                  
  if (rc > 0)                                                         
400127e0:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400127e4:	04 80 00 05 	ble  400127f8 <rtems_rfs_rtems_node_type+0x70> <== ALWAYS TAKEN
400127e8:	01 00 00 00 	nop                                            
  {                                                                   
    return rtems_rfs_rtems_error ("node_type: closing inode", rc);    
400127ec:	40 00 39 ac 	call  40020e9c <__errno>                       <== NOT EXECUTED
400127f0:	b0 10 3f ff 	mov  -1, %i0	! ffffffff <RAM_END+0xbfbfffff>   <== NOT EXECUTED
400127f4:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return type;                                                        
}                                                                     
400127f8:	81 c7 e0 08 	ret                                            
400127fc:	81 e8 00 00 	restore                                        
                                                                      

400129b0 <rtems_rfs_rtems_readlink>: static ssize_t rtems_rfs_rtems_readlink (const rtems_filesystem_location_info_t* pathloc, char* buf, size_t bufsize) {
400129b0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_rfs_file_system*  fs = rtems_rfs_rtems_pathloc_dev (pathloc); 
400129b4:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  int                     rc;                                         
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_READLINK))         
    printf ("rtems-rfs-rtems: readlink: in: ino:%" PRId32 "\n", ino); 
                                                                      
  rc = rtems_rfs_symlink_read (fs, ino, buf, bufsize, &length);       
400129b8:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
400129bc:	d0 00 60 08 	ld  [ %g1 + 8 ], %o0                           
400129c0:	94 10 00 19 	mov  %i1, %o2                                  
400129c4:	96 10 00 1a 	mov  %i2, %o3                                  
400129c8:	40 00 30 49 	call  4001eaec <rtems_rfs_symlink_read>        
400129cc:	98 07 bf fc 	add  %fp, -4, %o4                              
  if (rc)                                                             
  {                                                                   
    return rtems_rfs_rtems_error ("readlink: reading link", rc);      
  }                                                                   
                                                                      
  return (ssize_t) length;                                            
400129d0:	f0 07 bf fc 	ld  [ %fp + -4 ], %i0                          
                                                                      
  if (rtems_rfs_rtems_trace (RTEMS_RFS_RTEMS_DEBUG_READLINK))         
    printf ("rtems-rfs-rtems: readlink: in: ino:%" PRId32 "\n", ino); 
                                                                      
  rc = rtems_rfs_symlink_read (fs, ino, buf, bufsize, &length);       
  if (rc)                                                             
400129d4:	80 a2 20 00 	cmp  %o0, 0                                    
400129d8:	02 80 00 05 	be  400129ec <rtems_rfs_rtems_readlink+0x3c>   <== ALWAYS TAKEN
400129dc:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("readlink: reading link", rc);      
400129e0:	40 00 39 2f 	call  40020e9c <__errno>                       <== NOT EXECUTED
400129e4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400129e8:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return (ssize_t) length;                                            
}                                                                     
400129ec:	81 c7 e0 08 	ret                                            
400129f0:	81 e8 00 00 	restore                                        
                                                                      

400128dc <rtems_rfs_rtems_rename>: rtems_rfs_rtems_rename(const rtems_filesystem_location_info_t* old_parent_loc, const rtems_filesystem_location_info_t* old_loc, const rtems_filesystem_location_info_t* new_parent_loc, const char* new_name, size_t new_name_len) {
400128dc:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  rtems_rfs_file_system*  fs = rtems_rfs_rtems_pathloc_dev (old_loc); 
400128e0:	c2 06 60 14 	ld  [ %i1 + 0x14 ], %g1                        <== 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);      
400128e4:	e0 06 20 08 	ld  [ %i0 + 8 ], %l0                           <== NOT EXECUTED
                       const rtems_filesystem_location_info_t* old_loc,
                       const rtems_filesystem_location_info_t* new_parent_loc,
                       const char*                             new_name,
                       size_t                                  new_name_len)
{                                                                     
  rtems_rfs_file_system*  fs = rtems_rfs_rtems_pathloc_dev (old_loc); 
400128e8:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           <== 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);                   
400128ec:	f0 06 60 08 	ld  [ %i1 + 8 ], %i0                           <== NOT EXECUTED
                                                                      
  /*                                                                  
   * Link to the inode before unlinking so the inode is not erased when
   * unlinked.                                                        
   */                                                                 
  rc = rtems_rfs_link (fs, new_name, new_name_len, new_parent, ino, true);
400128f0:	d6 06 a0 08 	ld  [ %i2 + 8 ], %o3                           <== NOT EXECUTED
400128f4:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
                                                                      
  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);                   
  doff = rtems_rfs_rtems_get_pathloc_doff (old_loc);                  
400128f8:	f2 06 60 0c 	ld  [ %i1 + 0xc ], %i1                         <== NOT EXECUTED
                                                                      
  /*                                                                  
   * Link to the inode before unlinking so the inode is not erased when
   * unlinked.                                                        
   */                                                                 
  rc = rtems_rfs_link (fs, new_name, new_name_len, new_parent, ino, true);
400128fc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40012900:	92 10 00 1b 	mov  %i3, %o1                                  <== NOT EXECUTED
40012904:	98 10 00 18 	mov  %i0, %o4                                  <== NOT EXECUTED
40012908:	40 00 2e 79 	call  4001e2ec <rtems_rfs_link>                <== NOT EXECUTED
4001290c:	9a 10 20 01 	mov  1, %o5                                    <== NOT EXECUTED
  if (rc)                                                             
40012910:	b8 92 20 00 	orcc  %o0, 0, %i4                              <== NOT EXECUTED
40012914:	02 80 00 07 	be  40012930 <rtems_rfs_rtems_rename+0x54>     <== NOT EXECUTED
40012918:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  {                                                                   
    return rtems_rfs_rtems_error ("rename: linking", rc);             
4001291c:	40 00 39 60 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012920:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012924:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
40012928:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001292c:	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,                   
40012930:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
40012934:	92 10 00 10 	mov  %l0, %o1                                  <== NOT EXECUTED
40012938:	96 10 00 19 	mov  %i1, %o3                                  <== NOT EXECUTED
4001293c:	98 10 20 02 	mov  2, %o4                                    <== NOT EXECUTED
40012940:	40 00 2e da 	call  4001e4a8 <rtems_rfs_unlink>              <== NOT EXECUTED
40012944:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
                         rtems_rfs_unlink_dir_allowed);               
  if (rc)                                                             
40012948:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001294c:	02 80 00 05 	be  40012960 <rtems_rfs_rtems_rename+0x84>     <== NOT EXECUTED
40012950:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
  {                                                                   
    return rtems_rfs_rtems_error ("rename: unlinking", rc);           
40012954:	40 00 39 52 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012958:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4001295c:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40012960:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012964:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40013580 <rtems_rfs_rtems_set_handlers>: */ bool rtems_rfs_rtems_set_handlers (rtems_filesystem_location_info_t* loc, rtems_rfs_inode_handle* inode) {
40013580:	9d e3 bf a0 	save  %sp, -96, %sp                            
 * The following sets the handlers based on the type of inode.        
 */                                                                   
                                                                      
bool                                                                  
rtems_rfs_rtems_set_handlers (rtems_filesystem_location_info_t* loc,  
                              rtems_rfs_inode_handle*           inode)
40013584:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
{                                                                     
  uint16_t mode = rtems_rfs_inode_get_mode (inode);                   
  loc->handlers = NULL;                                               
  if (RTEMS_RFS_S_ISDIR (mode))                                       
40013588:	05 00 00 10 	sethi  %hi(0x4000), %g2                        
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
4001358c:	d2 08 60 02 	ldub  [ %g1 + 2 ], %o1                         
40013590:	c2 08 60 03 	ldub  [ %g1 + 3 ], %g1                         
40013594:	93 2a 60 08 	sll  %o1, 8, %o1                               
40013598:	92 12 40 01 	or  %o1, %g1, %o1                              
4001359c:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
400135a0:	82 0a 40 01 	and  %o1, %g1, %g1                             
400135a4:	80 a0 40 02 	cmp  %g1, %g2                                  
400135a8:	12 80 00 05 	bne  400135bc <rtems_rfs_rtems_set_handlers+0x3c>
400135ac:	c0 26 20 10 	clr  [ %i0 + 0x10 ]                            
    loc->handlers = rtems_rfs_rtems_handlers (dir);                   
400135b0:	03 10 00 d7 	sethi  %hi(0x40035c00), %g1                    
400135b4:	10 80 00 0a 	b  400135dc <rtems_rfs_rtems_set_handlers+0x5c>
400135b8:	82 10 62 38 	or  %g1, 0x238, %g1	! 40035e38 <rtems_rfs_rtems_dir_handlers>
  else if (RTEMS_RFS_S_ISCHR (mode) || RTEMS_RFS_S_ISBLK(mode))       
400135bc:	07 00 00 2c 	sethi  %hi(0xb000), %g3                        
400135c0:	05 00 00 08 	sethi  %hi(0x2000), %g2                        
400135c4:	86 0a 40 03 	and  %o1, %g3, %g3                             
400135c8:	80 a0 c0 02 	cmp  %g3, %g2                                  
400135cc:	12 80 00 07 	bne  400135e8 <rtems_rfs_rtems_set_handlers+0x68><== ALWAYS TAKEN
400135d0:	05 00 00 28 	sethi  %hi(0xa000), %g2                        
    loc->handlers = rtems_rfs_rtems_handlers (device);                
400135d4:	03 10 00 d7 	sethi  %hi(0x40035c00), %g1                    <== NOT EXECUTED
400135d8:	82 10 61 fc 	or  %g1, 0x1fc, %g1	! 40035dfc <rtems_rfs_rtems_device_handlers><== NOT EXECUTED
400135dc:	c2 26 20 10 	st  %g1, [ %i0 + 0x10 ]                        
400135e0:	10 80 00 13 	b  4001362c <rtems_rfs_rtems_set_handlers+0xac>
400135e4:	b0 10 20 01 	mov  1, %i0                                    
  else if (RTEMS_RFS_S_ISLNK (mode))                                  
400135e8:	80 a0 40 02 	cmp  %g1, %g2                                  
400135ec:	12 80 00 05 	bne  40013600 <rtems_rfs_rtems_set_handlers+0x80>
400135f0:	05 00 00 20 	sethi  %hi(0x8000), %g2                        
    loc->handlers = rtems_rfs_rtems_handlers (link);                  
400135f4:	03 10 00 cf 	sethi  %hi(0x40033c00), %g1                    
400135f8:	10 bf ff f9 	b  400135dc <rtems_rfs_rtems_set_handlers+0x5c>
400135fc:	82 10 63 4c 	or  %g1, 0x34c, %g1	! 40033f4c <rtems_rfs_rtems_link_handlers>
  else if (RTEMS_RFS_S_ISREG (mode))                                  
40013600:	80 a0 40 02 	cmp  %g1, %g2                                  
40013604:	32 80 00 05 	bne,a   40013618 <rtems_rfs_rtems_set_handlers+0x98><== NEVER TAKEN
40013608:	93 2a 60 10 	sll  %o1, 0x10, %o1                            <== NOT EXECUTED
    loc->handlers = rtems_rfs_rtems_handlers (file);                  
4001360c:	03 10 00 d7 	sethi  %hi(0x40035c00), %g1                    
40013610:	10 bf ff f3 	b  400135dc <rtems_rfs_rtems_set_handlers+0x5c>
40013614:	82 10 62 74 	or  %g1, 0x274, %g1	! 40035e74 <rtems_rfs_rtems_file_handlers>
  else                                                                
  {                                                                   
    printf ("rtems-rfs: mode type unknown: %04x\n", mode);            
40013618:	11 10 00 cf 	sethi  %hi(0x40033c00), %o0                    <== NOT EXECUTED
4001361c:	93 32 60 10 	srl  %o1, 0x10, %o1                            <== NOT EXECUTED
40013620:	90 12 23 90 	or  %o0, 0x390, %o0                            <== NOT EXECUTED
40013624:	40 00 3b 19 	call  40022288 <printf>                        <== NOT EXECUTED
40013628:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
    return false;                                                     
  }                                                                   
  return true;                                                        
}                                                                     
4001362c:	b0 0e 20 01 	and  %i0, 1, %i0                               
40013630:	81 c7 e0 08 	ret                                            
40013634:	81 e8 00 00 	restore                                        
                                                                      

40012844 <rtems_rfs_rtems_statvfs>: */ static int rtems_rfs_rtems_statvfs ( const rtems_filesystem_location_info_t *__restrict pathloc, struct statvfs *__restrict sb) {
40012844:	9d e3 bf 98 	save  %sp, -104, %sp                           <== NOT EXECUTED
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
40012848:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        <== NOT EXECUTED
  size_t                 blocks;                                      
  size_t                 inodes;                                      
                                                                      
  rtems_rfs_group_usage (fs, &blocks, &inodes);                       
4001284c:	92 07 bf f8 	add  %fp, -8, %o1                              <== NOT EXECUTED
static int                                                            
rtems_rfs_rtems_statvfs (                                             
  const rtems_filesystem_location_info_t *__restrict pathloc,         
  struct statvfs *__restrict                         sb)              
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
40012850:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           <== NOT EXECUTED
  size_t                 blocks;                                      
  size_t                 inodes;                                      
                                                                      
  rtems_rfs_group_usage (fs, &blocks, &inodes);                       
40012854:	94 07 bf fc 	add  %fp, -4, %o2                              <== NOT EXECUTED
40012858:	7f ff fc c2 	call  40011b60 <rtems_rfs_group_usage>         <== NOT EXECUTED
4001285c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
                                                                      
  sb->f_bsize   = rtems_rfs_fs_block_size (fs);                       
40012860:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           <== NOT EXECUTED
40012864:	c2 26 40 00 	st  %g1, [ %i1 ]                               <== NOT EXECUTED
  sb->f_frsize  = rtems_rfs_fs_media_block_size (fs);                 
40012868:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        <== NOT EXECUTED
4001286c:	c4 00 60 20 	ld  [ %g1 + 0x20 ], %g2                        <== NOT EXECUTED
  sb->f_blocks  = rtems_rfs_fs_media_blocks (fs);                     
40012870:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        <== 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);                 
40012874:	c4 26 60 04 	st  %g2, [ %i1 + 4 ]                           <== NOT EXECUTED
  sb->f_blocks  = rtems_rfs_fs_media_blocks (fs);                     
40012878:	c2 26 60 0c 	st  %g1, [ %i1 + 0xc ]                         <== NOT EXECUTED
  sb->f_bfree   = rtems_rfs_fs_blocks (fs) - blocks - 1; /* do not count the superblock */
4001287c:	c4 07 bf f8 	ld  [ %fp + -8 ], %g2                          <== NOT EXECUTED
40012880:	c2 07 60 04 	ld  [ %i5 + 4 ], %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);                     
40012884:	c0 26 60 08 	clr  [ %i1 + 8 ]                               <== NOT EXECUTED
  sb->f_bfree   = rtems_rfs_fs_blocks (fs) - blocks - 1; /* do not count the superblock */
40012888:	82 00 7f ff 	add  %g1, -1, %g1                              <== NOT EXECUTED
4001288c:	82 20 40 02 	sub  %g1, %g2, %g1                             <== 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;                  
40012890:	c4 07 bf fc 	ld  [ %fp + -4 ], %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);                     
  sb->f_bfree   = rtems_rfs_fs_blocks (fs) - blocks - 1; /* do not count the superblock */
40012894:	c2 26 60 14 	st  %g1, [ %i1 + 0x14 ]                        <== NOT EXECUTED
  sb->f_bavail  = sb->f_bfree;                                        
40012898:	c2 26 60 1c 	st  %g1, [ %i1 + 0x1c ]                        <== NOT EXECUTED
  sb->f_files   = rtems_rfs_fs_inodes (fs);                           
4001289c:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %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 - 1; /* do not count the superblock */
400128a0:	c0 26 60 10 	clr  [ %i1 + 0x10 ]                            <== NOT EXECUTED
  sb->f_bavail  = sb->f_bfree;                                        
  sb->f_files   = rtems_rfs_fs_inodes (fs);                           
400128a4:	c2 26 60 20 	st  %g1, [ %i1 + 0x20 ]                        <== NOT EXECUTED
  sb->f_ffree   = rtems_rfs_fs_inodes (fs) - inodes;                  
400128a8:	82 20 40 02 	sub  %g1, %g2, %g1                             <== NOT EXECUTED
400128ac:	c2 26 60 24 	st  %g1, [ %i1 + 0x24 ]                        <== NOT EXECUTED
  sb->f_favail  = sb->f_ffree;                                        
400128b0:	c2 26 60 28 	st  %g1, [ %i1 + 0x28 ]                        <== NOT EXECUTED
  sb->f_fsid    = RTEMS_RFS_SB_MAGIC;                                 
400128b4:	03 0a 02 48 	sethi  %hi(0x28092000), %g1                    <== NOT EXECUTED
400128b8:	82 10 60 01 	or  %g1, 1, %g1	! 28092001 <RAM_SIZE+0x27c92001><== NOT EXECUTED
400128bc:	c2 26 60 2c 	st  %g1, [ %i1 + 0x2c ]                        <== NOT EXECUTED
  sb->f_flag    = rtems_rfs_fs_flags (fs);                            
400128c0:	c2 07 40 00 	ld  [ %i5 ], %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 - 1; /* do not count the superblock */
  sb->f_bavail  = sb->f_bfree;                                        
400128c4:	c0 26 60 18 	clr  [ %i1 + 0x18 ]                            <== 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);                            
400128c8:	c2 26 60 30 	st  %g1, [ %i1 + 0x30 ]                        <== NOT EXECUTED
  sb->f_namemax = rtems_rfs_fs_max_name (fs);                         
400128cc:	c2 07 60 1c 	ld  [ %i5 + 0x1c ], %g1                        <== NOT EXECUTED
400128d0:	c2 26 60 34 	st  %g1, [ %i1 + 0x34 ]                        <== NOT EXECUTED
                                                                      
  return 0;                                                           
}                                                                     
400128d4:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400128d8:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
                                                                      

40012afc <rtems_rfs_rtems_symlink>: static int rtems_rfs_rtems_symlink (const rtems_filesystem_location_info_t* parent_loc, const char* node_name, size_t node_name_len, const char* target) {
40012afc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (parent_loc);
40012b00:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  rtems_rfs_ino          parent = rtems_rfs_rtems_get_pathloc_ino (parent_loc);
40012b04:	f0 06 20 08 	ld  [ %i0 + 8 ], %i0                           
rtems_rfs_rtems_symlink (const rtems_filesystem_location_info_t* parent_loc,
                         const char*                             node_name,
                         size_t                                  node_name_len,
                         const char*                             target)
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (parent_loc);
40012b08:	f8 00 60 08 	ld  [ %g1 + 8 ], %i4                           
  rtems_rfs_ino          parent = rtems_rfs_rtems_get_pathloc_ino (parent_loc);
  int                    rc;                                          
                                                                      
  rc = rtems_rfs_symlink (fs, node_name, node_name_len,               
                          target, strlen (target),                    
40012b0c:	40 00 42 44 	call  4002341c <strlen>                        
40012b10:	90 10 00 1b 	mov  %i3, %o0                                  
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (parent_loc);
  rtems_rfs_ino          parent = rtems_rfs_rtems_get_pathloc_ino (parent_loc);
  int                    rc;                                          
                                                                      
  rc = rtems_rfs_symlink (fs, node_name, node_name_len,               
40012b14:	40 00 0f 57 	call  40016870 <geteuid>                       
40012b18:	ba 10 00 08 	mov  %o0, %i5                                  
40012b1c:	40 00 0f 4f 	call  40016858 <getegid>                       
40012b20:	a0 10 00 08 	mov  %o0, %l0                                  
40012b24:	91 2a 20 10 	sll  %o0, 0x10, %o0                            
40012b28:	91 32 20 10 	srl  %o0, 0x10, %o0                            
40012b2c:	f0 23 a0 60 	st  %i0, [ %sp + 0x60 ]                        
40012b30:	d0 23 a0 5c 	st  %o0, [ %sp + 0x5c ]                        
40012b34:	98 10 00 1d 	mov  %i5, %o4                                  
40012b38:	9b 2c 20 10 	sll  %l0, 0x10, %o5                            
40012b3c:	90 10 00 1c 	mov  %i4, %o0                                  
40012b40:	92 10 00 19 	mov  %i1, %o1                                  
40012b44:	94 10 00 1a 	mov  %i2, %o2                                  
40012b48:	96 10 00 1b 	mov  %i3, %o3                                  
40012b4c:	9b 33 60 10 	srl  %o5, 0x10, %o5                            
40012b50:	40 00 2f 53 	call  4001e89c <rtems_rfs_symlink>             
40012b54:	b0 10 20 00 	clr  %i0                                       
                          target, strlen (target),                    
                          geteuid(), getegid(), parent);              
  if (rc)                                                             
40012b58:	80 a2 20 00 	cmp  %o0, 0                                    
40012b5c:	02 80 00 05 	be  40012b70 <rtems_rfs_rtems_symlink+0x74>    <== ALWAYS TAKEN
40012b60:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("symlink: linking", rc);            
40012b64:	40 00 38 ce 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012b68:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012b6c:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
40012b70:	81 c7 e0 08 	ret                                            
40012b74:	81 e8 00 00 	restore                                        
                                                                      

40012c1c <rtems_rfs_rtems_unlock>: /** * Unlock the RFS file system. */ static inline void rtems_rfs_rtems_unlock (rtems_rfs_file_system* fs) {
40012c1c:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_rtems_private* rtems = rtems_rfs_fs_user (fs);            
40012c20:	fa 06 20 80 	ld  [ %i0 + 0x80 ], %i5                        
  rtems_rfs_buffers_release (fs);                                     
40012c24:	40 00 22 b6 	call  4001b6fc <rtems_rfs_buffers_release>     
40012c28:	90 10 00 18 	mov  %i0, %o0                                  
 */                                                                   
static inline int                                                     
rtems_rfs_mutex_unlock (rtems_rfs_mutex* mutex)                       
{                                                                     
#if __rtems__                                                         
  rtems_status_code sc = rtems_semaphore_release (*mutex);            
40012c2c:	7f ff e7 88 	call  4000ca4c <rtems_semaphore_release>       
40012c30:	d0 07 40 00 	ld  [ %i5 ], %o0                               
  if (sc != RTEMS_SUCCESSFUL)                                         
40012c34:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40012c38:	02 80 00 0c 	be  40012c68 <rtems_rfs_rtems_unlock+0x4c>     <== ALWAYS TAKEN
40012c3c:	90 10 20 00 	clr  %o0                                       
  {                                                                   
#if RTEMS_RFS_TRACE                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_MUTEX))                      
40012c40:	40 00 02 83 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
40012c44:	92 10 20 04 	mov  4, %o1                                    <== NOT EXECUTED
40012c48:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
40012c4c:	02 80 00 07 	be  40012c68 <rtems_rfs_rtems_unlock+0x4c>     <== NOT EXECUTED
40012c50:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: mutex: release failed: %s\n",               
40012c54:	40 00 14 c6 	call  40017f6c <rtems_status_text>             <== NOT EXECUTED
40012c58:	31 10 00 cf 	sethi  %hi(0x40033c00), %i0                    <== NOT EXECUTED
40012c5c:	b0 16 22 68 	or  %i0, 0x268, %i0	! 40033e68 <_Semaphore_Translate_core_mutex_return_code_+0xcd8><== NOT EXECUTED
40012c60:	40 00 3d 8a 	call  40022288 <printf>                        <== NOT EXECUTED
40012c64:	93 e8 00 08 	restore  %g0, %o0, %o1                         <== NOT EXECUTED
40012c68:	81 c7 e0 08 	ret                                            
40012c6c:	81 e8 00 00 	restore                                        
                                                                      

40012650 <rtems_rfs_rtems_utime>: static int rtems_rfs_rtems_utime(const rtems_filesystem_location_info_t* pathloc, time_t atime, time_t mtime) {
40012650:	9d e3 bf 78 	save  %sp, -136, %sp                           
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
40012654:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  rtems_rfs_ino          ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
  rtems_rfs_inode_handle inode;                                       
  int                    rc;                                          
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012658:	d2 06 20 08 	ld  [ %i0 + 8 ], %o1                           
static int                                                            
rtems_rfs_rtems_utime(const rtems_filesystem_location_info_t* pathloc,
                      time_t                                  atime,  
                      time_t                                  mtime)  
{                                                                     
  rtems_rfs_file_system* fs = rtems_rfs_rtems_pathloc_dev (pathloc);  
4001265c:	fa 00 60 08 	ld  [ %g1 + 8 ], %i5                           
  rtems_rfs_ino          ino = rtems_rfs_rtems_get_pathloc_ino (pathloc);
  rtems_rfs_inode_handle inode;                                       
  int                    rc;                                          
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
40012660:	94 07 bf d8 	add  %fp, -40, %o2                             
40012664:	90 10 00 1d 	mov  %i5, %o0                                  
40012668:	7f ff fd 9d 	call  40011cdc <rtems_rfs_inode_open>          
4001266c:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
40012670:	b8 92 20 00 	orcc  %o0, 0, %i4                              
40012674:	02 80 00 07 	be  40012690 <rtems_rfs_rtems_utime+0x40>      <== ALWAYS TAKEN
40012678:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  {                                                                   
    return rtems_rfs_rtems_error ("utime: read inode", rc);           
4001267c:	40 00 3a 08 	call  40020e9c <__errno>                       <== NOT EXECUTED
40012680:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
40012684:	f8 22 00 00 	st  %i4, [ %o0 ]                               <== NOT EXECUTED
40012688:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001268c:	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);                  
40012690:	85 36 60 18 	srl  %i1, 0x18, %g2                            
40012694:	c4 28 60 10 	stb  %g2, [ %g1 + 0x10 ]                       
40012698:	85 36 60 10 	srl  %i1, 0x10, %g2                            
4001269c:	c4 28 60 11 	stb  %g2, [ %g1 + 0x11 ]                       
400126a0:	85 36 60 08 	srl  %i1, 8, %g2                               
400126a4:	c4 28 60 12 	stb  %g2, [ %g1 + 0x12 ]                       
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
400126a8:	84 10 20 01 	mov  1, %g2                                    
400126ac:	c4 2f bf e8 	stb  %g2, [ %fp + -24 ]                        
 */                                                                   
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);                  
400126b0:	85 36 a0 18 	srl  %i2, 0x18, %g2                            
400126b4:	c4 28 60 14 	stb  %g2, [ %g1 + 0x14 ]                       
400126b8:	85 36 a0 10 	srl  %i2, 0x10, %g2                            
400126bc:	c4 28 60 15 	stb  %g2, [ %g1 + 0x15 ]                       
400126c0:	85 36 a0 08 	srl  %i2, 8, %g2                               
  }                                                                   
                                                                      
  rtems_rfs_inode_set_atime (&inode, atime);                          
  rtems_rfs_inode_set_mtime (&inode, mtime);                          
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
400126c4:	90 10 00 1d 	mov  %i5, %o0                                  
 */                                                                   
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);                  
400126c8:	f2 28 60 13 	stb  %i1, [ %g1 + 0x13 ]                       
 */                                                                   
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);                  
400126cc:	c4 28 60 16 	stb  %g2, [ %g1 + 0x16 ]                       
400126d0:	f4 28 60 17 	stb  %i2, [ %g1 + 0x17 ]                       
400126d4:	92 07 bf d8 	add  %fp, -40, %o1                             
400126d8:	7f ff fd f3 	call  40011ea4 <rtems_rfs_inode_close>         
400126dc:	b0 10 20 00 	clr  %i0                                       
  if (rc)                                                             
400126e0:	80 a2 20 00 	cmp  %o0, 0                                    
400126e4:	02 80 00 05 	be  400126f8 <rtems_rfs_rtems_utime+0xa8>      <== ALWAYS TAKEN
400126e8:	ba 10 00 08 	mov  %o0, %i5                                  
  {                                                                   
    return rtems_rfs_rtems_error ("utime: closing inode", rc);        
400126ec:	40 00 39 ec 	call  40020e9c <__errno>                       <== NOT EXECUTED
400126f0:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
400126f4:	fa 22 00 00 	st  %i5, [ %o0 ]                               <== NOT EXECUTED
  }                                                                   
                                                                      
  return 0;                                                           
}                                                                     
400126f8:	81 c7 e0 08 	ret                                            
400126fc:	81 e8 00 00 	restore                                        
                                                                      

4001aeb8 <rtems_rfs_scan_chain>: */ static rtems_rfs_buffer* rtems_rfs_scan_chain (rtems_chain_control* chain, uint32_t* count, rtems_rfs_buffer_block block) {
4001aeb8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_rfs_buffer* buffer;                                           
  rtems_chain_node* node;                                             
                                                                      
  node = rtems_chain_last (chain);                                    
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))                
4001aebc:	90 10 20 00 	clr  %o0                                       
 */                                                                   
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Last(                         
  Chain_Control *the_chain                                            
)                                                                     
{                                                                     
  return _Chain_Tail( the_chain )->previous;                          
4001aec0:	fa 06 20 08 	ld  [ %i0 + 8 ], %i5                           
4001aec4:	7f ff e1 e2 	call  4001364c <rtems_rfs_trace>               
4001aec8:	92 10 20 80 	mov  0x80, %o1                                 
4001aecc:	80 a2 20 00 	cmp  %o0, 0                                    
4001aed0:	02 80 00 08 	be  4001aef0 <rtems_rfs_scan_chain+0x38>       <== ALWAYS TAKEN
4001aed4:	39 10 00 d2 	sethi  %hi(0x40034800), %i4                    
    printf ("rtems-rfs: buffer-scan: count=%" PRIu32 ", block=%" PRIu32 ": ", *count, block);
4001aed8:	d2 06 40 00 	ld  [ %i1 ], %o1                               <== NOT EXECUTED
4001aedc:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001aee0:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
4001aee4:	40 00 1c e9 	call  40022288 <printf>                        <== NOT EXECUTED
4001aee8:	90 12 20 58 	or  %o0, 0x58, %o0                             <== NOT EXECUTED
  while (!rtems_chain_is_head (chain, node))                          
  {                                                                   
    buffer = (rtems_rfs_buffer*) node;                                
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))              
      printf ("%" PRIuPTR " ", ((intptr_t) buffer->user));            
4001aeec:	39 10 00 d2 	sethi  %hi(0x40034800), %i4                    <== NOT EXECUTED
4001aef0:	b8 17 20 88 	or  %i4, 0x88, %i4	! 40034888 <CSWTCH.1+0x138> 
                                                                      
  while (!rtems_chain_is_head (chain, node))                          
  {                                                                   
    buffer = (rtems_rfs_buffer*) node;                                
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))              
4001aef4:	90 10 20 00 	clr  %o0                                       
  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))                          
4001aef8:	80 a7 40 18 	cmp  %i5, %i0                                  
4001aefc:	02 80 00 22 	be  4001af84 <rtems_rfs_scan_chain+0xcc>       
4001af00:	92 10 20 80 	mov  0x80, %o1                                 
  {                                                                   
    buffer = (rtems_rfs_buffer*) node;                                
                                                                      
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))              
4001af04:	7f ff e1 d2 	call  4001364c <rtems_rfs_trace>               
4001af08:	01 00 00 00 	nop                                            
4001af0c:	80 a2 20 00 	cmp  %o0, 0                                    
4001af10:	22 80 00 06 	be,a   4001af28 <rtems_rfs_scan_chain+0x70>    <== ALWAYS TAKEN
4001af14:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
      printf ("%" PRIuPTR " ", ((intptr_t) buffer->user));            
4001af18:	d2 07 60 34 	ld  [ %i5 + 0x34 ], %o1                        <== NOT EXECUTED
4001af1c:	40 00 1c db 	call  40022288 <printf>                        <== NOT EXECUTED
4001af20:	90 10 00 1c 	mov  %i4, %o0                                  <== NOT EXECUTED
                                                                      
    if (((rtems_rfs_buffer_block) ((intptr_t)(buffer->user))) == block)
4001af24:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        <== NOT EXECUTED
4001af28:	80 a0 40 1a 	cmp  %g1, %i2                                  
4001af2c:	32 bf ff f2 	bne,a   4001aef4 <rtems_rfs_scan_chain+0x3c>   
4001af30:	fa 07 60 04 	ld  [ %i5 + 4 ], %i5                           
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))            
4001af34:	90 10 20 00 	clr  %o0                                       
4001af38:	7f ff e1 c5 	call  4001364c <rtems_rfs_trace>               
4001af3c:	92 10 20 80 	mov  0x80, %o1                                 
4001af40:	80 a2 20 00 	cmp  %o0, 0                                    
4001af44:	22 80 00 07 	be,a   4001af60 <rtems_rfs_scan_chain+0xa8>    <== ALWAYS TAKEN
4001af48:	c2 06 40 00 	ld  [ %i1 ], %g1                               
        printf (": found block=%" PRIuPTR "\n",                       
4001af4c:	d2 07 60 34 	ld  [ %i5 + 0x34 ], %o1                        <== NOT EXECUTED
4001af50:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    <== NOT EXECUTED
4001af54:	40 00 1c cd 	call  40022288 <printf>                        <== NOT EXECUTED
4001af58:	90 12 20 90 	or  %o0, 0x90, %o0	! 40034890 <CSWTCH.1+0x140> <== NOT EXECUTED
                ((intptr_t)(buffer->user)));                          
                                                                      
      (*count)--;                                                     
4001af5c:	c2 06 40 00 	ld  [ %i1 ], %g1                               <== NOT EXECUTED
)                                                                     
{                                                                     
  Chain_Node *next;                                                   
  Chain_Node *previous;                                               
                                                                      
  next           = the_node->next;                                    
4001af60:	c4 07 40 00 	ld  [ %i5 ], %g2                               
4001af64:	82 00 7f ff 	add  %g1, -1, %g1                              
4001af68:	c2 26 40 00 	st  %g1, [ %i1 ]                               
  previous       = the_node->previous;                                
4001af6c:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
  next->previous = previous;                                          
4001af70:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
  previous->next = next;                                              
4001af74:	c4 20 40 00 	st  %g2, [ %g1 ]                               
 */                                                                   
RTEMS_INLINE_ROUTINE void _Chain_Set_off_chain(                       
  Chain_Node *node                                                    
)                                                                     
{                                                                     
  node->next = NULL;                                                  
4001af78:	c0 27 40 00 	clr  [ %i5 ]                                   
      rtems_chain_extract_unprotected (node);                         
      rtems_chain_set_off_chain (node);                               
      return buffer;                                                  
4001af7c:	81 c7 e0 08 	ret                                            
4001af80:	91 e8 00 1d 	restore  %g0, %i5, %o0                         
    }                                                                 
    node = rtems_chain_previous (node);                               
  }                                                                   
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_BUFFER_CHAINS))                
4001af84:	7f ff e1 b2 	call  4001364c <rtems_rfs_trace>               
4001af88:	b0 10 20 00 	clr  %i0                                       
4001af8c:	80 a2 20 00 	cmp  %o0, 0                                    
4001af90:	02 80 00 04 	be  4001afa0 <rtems_rfs_scan_chain+0xe8>       <== ALWAYS TAKEN
4001af94:	11 10 00 d2 	sethi  %hi(0x40034800), %o0                    
    printf (": not found\n");                                         
4001af98:	40 00 1d 4b 	call  400224c4 <puts>                          <== NOT EXECUTED
4001af9c:	90 12 20 a8 	or  %o0, 0xa8, %o0	! 400348a8 <CSWTCH.1+0x158> <== NOT EXECUTED
                                                                      
  return NULL;                                                        
}                                                                     
4001afa0:	81 c7 e0 08 	ret                                            
4001afa4:	81 e8 00 00 	restore                                        
                                                                      

40019830 <rtems_rfs_search_map_for_clear_bit.constprop.1>: return 0; } static int rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
40019830:	9d e3 bf 88 	save  %sp, -120, %sp                           
  *found = false;                                                     
                                                                      
  /*                                                                  
   * Load the bitmap.                                                 
   */                                                                 
  rc = rtems_rfs_bitmap_load_map (control, &map);                     
40019834:	90 10 00 18 	mov  %i0, %o0                                  
                                                                      
  return 0;                                                           
}                                                                     
                                                                      
static int                                                            
rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
40019838:	a2 10 00 18 	mov  %i0, %l1                                  
  rtems_rfs_bitmap_element* map_bits;                                 
  int                       map_index;                                
  int                       map_offset;                               
  int                       rc;                                       
                                                                      
  *found = false;                                                     
4001983c:	c0 2e 80 00 	clrb  [ %i2 ]                                  
                                                                      
  /*                                                                  
   * Load the bitmap.                                                 
   */                                                                 
  rc = rtems_rfs_bitmap_load_map (control, &map);                     
40019840:	7f ff ff e7 	call  400197dc <rtems_rfs_bitmap_load_map>     
40019844:	92 07 bf fc 	add  %fp, -4, %o1                              
  if (rc > 0)                                                         
40019848:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001984c:	14 80 00 95 	bg  40019aa0 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x270><== NEVER TAKEN
40019850:	a1 2e e0 0b 	sll  %i3, 0xb, %l0                             
    return rc;                                                        
                                                                      
  /*                                                                  
   * Calculate the bit we are testing plus the end point we search over.
   */                                                                 
  test_bit = *bit;                                                    
40019854:	fa 06 40 00 	ld  [ %i1 ], %i5                               
  end_bit  = test_bit + (window * direction);                         
                                                                      
  if (end_bit < 0)                                                    
40019858:	a0 87 40 10 	addcc  %i5, %l0, %l0                           
4001985c:	2c 80 00 08 	bneg,a   4001987c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x4c>
40019860:	a0 10 20 00 	clr  %l0                                       
    end_bit = 0;                                                      
  else if (end_bit >= control->size)                                  
40019864:	c2 04 60 0c 	ld  [ %l1 + 0xc ], %g1                         
40019868:	80 a4 00 01 	cmp  %l0, %g1                                  
4001986c:	3a 80 00 04 	bcc,a   4001987c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x4c>
40019870:	a0 00 7f ff 	add  %g1, -1, %l0                              
  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];                  
40019874:	10 80 00 03 	b  40019880 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x50>
40019878:	c4 04 60 14 	ld  [ %l1 + 0x14 ], %g2                        
4001987c:	c4 04 60 14 	ld  [ %l1 + 0x14 ], %g2                        
  map_bits    = &map[map_index];                                      
40019880:	f0 07 bf fc 	ld  [ %fp + -4 ], %i0                          
  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);              
40019884:	b9 3f 60 05 	sra  %i5, 5, %i4                               
  map_offset    = rtems_rfs_bitmap_map_offset (test_bit);             
  search_index  = rtems_rfs_bitmap_map_index (map_index);             
40019888:	a7 3f 60 0a 	sra  %i5, 0xa, %l3                             
    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);             
4001988c:	a4 0f 60 1f 	and  %i5, 0x1f, %l2                            
  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];                  
40019890:	a7 2c e0 02 	sll  %l3, 2, %l3                               
    end_bit = control->size - 1;                                      
                                                                      
  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);            
40019894:	82 0f 20 1f 	and  %i4, 0x1f, %g1                            
                                                                      
  search_bits = &control->search_bits[search_index];                  
40019898:	a6 00 80 13 	add  %g2, %l3, %l3                             
            map_offset += direction;                                  
            test_bit   += direction;                                  
          }                                                           
        }                                                             
                                                                      
        map_bits  += direction;                                       
4001989c:	ad 2e e0 02 	sll  %i3, 2, %l6                               
  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];                                      
400198a0:	85 2f 20 02 	sll  %i4, 2, %g2                               
400198a4:	a8 10 20 1f 	mov  0x1f, %l4                                 
400198a8:	80 a6 e0 00 	cmp  %i3, 0                                    
400198ac:	04 80 00 03 	ble  400198b8 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x88>
400198b0:	b0 06 00 02 	add  %i0, %g2, %i0                             
400198b4:	a8 10 20 00 	clr  %l4                                       
        test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
                                                                      
        search_offset += direction;                                   
                                                                      
        if (((direction < 0) && (test_bit <= end_bit))                
            || ((direction > 0) && (test_bit >= end_bit)))            
400198b8:	ab 3e e0 1f 	sra  %i3, 0x1f, %l5                            
400198bc:	89 2e e0 05 	sll  %i3, 5, %g4                               
400198c0:	aa 25 40 1b 	sub  %l5, %i3, %l5                             
       */                                                             
      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;
400198c4:	9a 10 20 20 	mov  0x20, %o5                                 
 */                                                                   
static bool                                                           
rtems_rfs_bitmap_test (rtems_rfs_bitmap_element target,               
                       rtems_rfs_bitmap_bit     bit)                  
{                                                                     
  return RTEMS_RFS_BITMAP_TEST_BIT (target, bit);                     
400198c8:	ae 10 20 01 	mov  1, %l7                                    
                                                                      
        test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
                                                                      
        search_offset += direction;                                   
                                                                      
        if (((direction < 0) && (test_bit <= end_bit))                
400198cc:	87 36 e0 1f 	srl  %i3, 0x1f, %g3                            
            || ((direction > 0) && (test_bit >= end_bit)))            
400198d0:	ab 35 60 1f 	srl  %l5, 0x1f, %l5                            
    /*                                                                
     * 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))
400198d4:	d8 04 c0 00 	ld  [ %l3 ], %o4                               
400198d8:	80 a3 20 00 	cmp  %o4, 0                                    
400198dc:	02 80 00 41 	be  400199e0 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x1b0>
400198e0:	80 a6 e0 00 	cmp  %i3, 0                                    
400198e4:	96 07 00 1b 	add  %i4, %i3, %o3                             
400198e8:	84 10 20 00 	clr  %g2                                       
400198ec:	97 2a e0 05 	sll  %o3, 5, %o3                               
400198f0:	82 20 40 1c 	sub  %g1, %i4, %g1                             
400198f4:	96 02 c0 14 	add  %o3, %l4, %o3                             
400198f8:	9e 00 40 1c 	add  %g1, %i4, %o7                             
    {                                                                 
      while ((search_offset >= 0)                                     
400198fc:	80 a3 e0 1f 	cmp  %o7, 0x1f                                 
40019900:	18 80 00 4f 	bgu  40019a3c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x20c>
40019904:	9f 2d c0 0f 	sll  %l7, %o7, %o7                             
             && (search_offset < rtems_rfs_bitmap_element_bits ()))   
      {                                                               
        if (!rtems_rfs_bitmap_test (*search_bits, search_offset))     
40019908:	80 8b c0 0c 	btst  %o7, %o4                                 
4001990c:	02 80 00 1c 	be  4001997c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x14c>
40019910:	a4 24 80 1d 	sub  %l2, %i5, %l2                             
40019914:	94 04 80 1d 	add  %l2, %i5, %o2                             
        {                                                             
          /*                                                          
           * 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)                                    
40019918:	80 a2 a0 1f 	cmp  %o2, 0x1f                                 
4001991c:	18 80 00 18 	bgu  4001997c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x14c><== NEVER TAKEN
40019920:	95 2d c0 0a 	sll  %l7, %o2, %o2                             
                 && (map_offset < rtems_rfs_bitmap_element_bits ()))  
          {                                                           
            if (!rtems_rfs_bitmap_test (*map_bits, map_offset))       
40019924:	d2 06 00 00 	ld  [ %i0 ], %o1                               
40019928:	80 8a 80 09 	btst  %o2, %o1                                 
4001992c:	02 80 00 12 	be  40019974 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x144>
40019930:	80 a7 40 10 	cmp  %i5, %l0                                  
 */                                                                   
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);                    
40019934:	94 2a 40 0a 	andn  %o1, %o2, %o2                            
                 && (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,                   
40019938:	80 a2 a0 00 	cmp  %o2, 0                                    
4001993c:	12 80 00 05 	bne  40019950 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x120>
40019940:	d4 26 00 00 	st  %o2, [ %i0 ]                               
 */                                                                   
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);                    
40019944:	c2 04 c0 00 	ld  [ %l3 ], %g1                               
40019948:	9e 28 40 0f 	andn  %g1, %o7, %o7                            
            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,                   
                                         RTEMS_RFS_BITMAP_ELEMENT_SET))
                *search_bits = rtems_rfs_bitmap_set (*search_bits,    
4001994c:	de 24 c0 00 	st  %o7, [ %l3 ]                               
                                                     1 << search_offset);
              control->free--;                                        
40019950:	c2 04 60 10 	ld  [ %l1 + 0x10 ], %g1                        
              *bit = test_bit;                                        
              *found = true;                                          
              rtems_rfs_buffer_mark_dirty (control->buffer);          
40019954:	c4 04 40 00 	ld  [ %l1 ], %g2                               
              *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--;                                        
40019958:	82 00 7f ff 	add  %g1, -1, %g1                              
4001995c:	c2 24 60 10 	st  %g1, [ %l1 + 0x10 ]                        
              *bit = test_bit;                                        
40019960:	fa 26 40 00 	st  %i5, [ %i1 ]                               
              *found = true;                                          
40019964:	82 10 20 01 	mov  1, %g1                                    
40019968:	c2 2e 80 00 	stb  %g1, [ %i2 ]                              
              rtems_rfs_buffer_mark_dirty (control->buffer);          
4001996c:	10 80 00 4c 	b  40019a9c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x26c>
40019970:	c2 28 80 00 	stb  %g1, [ %g2 ]                              
              return 0;                                               
            }                                                         
                                                                      
            if (test_bit == end_bit)                                  
40019974:	12 bf ff e8 	bne  40019914 <rtems_rfs_search_map_for_clear_bit.constprop.1+0xe4>
40019978:	ba 07 40 1b 	add  %i5, %i3, %i5                             
4001997c:	ba 00 80 0b 	add  %g2, %o3, %i5                             
            map_offset += direction;                                  
            test_bit   += direction;                                  
          }                                                           
        }                                                             
                                                                      
        map_bits  += direction;                                       
40019980:	b0 06 00 16 	add  %i0, %l6, %i0                             
        map_index += direction;                                       
40019984:	b8 07 00 1b 	add  %i4, %i3, %i4                             
                                                                      
        test_bit = (map_index * rtems_rfs_bitmap_element_bits ()) + map_offset;
                                                                      
        search_offset += direction;                                   
                                                                      
        if (((direction < 0) && (test_bit <= end_bit))                
40019988:	80 a7 40 10 	cmp  %i5, %l0                                  
4001998c:	04 80 00 03 	ble  40019998 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x168>
40019990:	9e 10 20 01 	mov  1, %o7                                    
40019994:	9e 10 20 00 	clr  %o7                                       
40019998:	80 8b e0 ff 	btst  0xff, %o7                                
4001999c:	02 80 00 05 	be  400199b0 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x180>
400199a0:	84 00 80 04 	add  %g2, %g4, %g2                             
400199a4:	80 a0 e0 00 	cmp  %g3, 0                                    
400199a8:	32 80 00 25 	bne,a   40019a3c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x20c>
400199ac:	a4 10 00 14 	mov  %l4, %l2                                  
            || ((direction > 0) && (test_bit >= end_bit)))            
400199b0:	80 a7 40 10 	cmp  %i5, %l0                                  
400199b4:	16 80 00 03 	bge  400199c0 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x190>
400199b8:	9e 10 20 01 	mov  1, %o7                                    
400199bc:	9e 10 20 00 	clr  %o7                                       
400199c0:	80 8b e0 ff 	btst  0xff, %o7                                
400199c4:	02 bf ff cd 	be  400198f8 <rtems_rfs_search_map_for_clear_bit.constprop.1+0xc8>
400199c8:	a4 10 00 14 	mov  %l4, %l2                                  
400199cc:	80 a5 60 00 	cmp  %l5, 0                                    
400199d0:	02 bf ff cb 	be  400198fc <rtems_rfs_search_map_for_clear_bit.constprop.1+0xcc>
400199d4:	9e 00 40 1c 	add  %g1, %i4, %o7                             
      }                                                               
      map_bits += direction * bits_skipped;                           
      map_index += direction * bits_skipped;                          
    }                                                                 
                                                                      
    search_bits  += direction;                                        
400199d8:	10 80 00 1a 	b  40019a40 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x210>
400199dc:	a6 04 c0 16 	add  %l3, %l6, %l3                             
       * 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)                                              
400199e0:	04 80 00 07 	ble  400199fc <rtems_rfs_search_map_for_clear_bit.constprop.1+0x1cc>
400199e4:	ba 0f 7f e0 	and  %i5, -32, %i5                             
      {                                                               
        bits_skipped = rtems_rfs_bitmap_element_bits () - search_offset;
400199e8:	92 23 40 01 	sub  %o5, %g1, %o1                             
        test_bit += bits_skipped * rtems_rfs_bitmap_element_bits ();  
        map_offset = 0;                                               
400199ec:	a4 10 20 00 	clr  %l2                                       
      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;
        test_bit += bits_skipped * rtems_rfs_bitmap_element_bits ();  
400199f0:	83 2a 60 05 	sll  %o1, 5, %g1                               
400199f4:	10 80 00 07 	b  40019a10 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x1e0>
400199f8:	ba 00 40 1d 	add  %g1, %i5, %i5                             
        map_offset = 0;                                               
      }                                                               
      else                                                            
      {                                                               
        bits_skipped = search_offset + 1;                             
400199fc:	92 00 60 01 	add  %g1, 1, %o1                               
        /*                                                            
         * 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;
40019a00:	ba 07 7f ff 	add  %i5, -1, %i5                              
40019a04:	83 28 60 05 	sll  %g1, 5, %g1                               
        map_offset = rtems_rfs_bitmap_element_bits () - 1;            
40019a08:	a4 10 20 1f 	mov  0x1f, %l2                                 
        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;
40019a0c:	ba 27 40 01 	sub  %i5, %g1, %i5                             
        map_offset = rtems_rfs_bitmap_element_bits () - 1;            
      }                                                               
      map_bits += direction * bits_skipped;                           
40019a10:	c6 27 bf f4 	st  %g3, [ %fp + -12 ]                         
40019a14:	c8 27 bf f0 	st  %g4, [ %fp + -16 ]                         
40019a18:	da 27 bf ec 	st  %o5, [ %fp + -20 ]                         
40019a1c:	7f ff a2 d4 	call  4000256c <.umul>                         
40019a20:	90 10 00 1b 	mov  %i3, %o0                                  
40019a24:	c6 07 bf f4 	ld  [ %fp + -12 ], %g3                         
40019a28:	83 2a 20 02 	sll  %o0, 2, %g1                               
      map_index += direction * bits_skipped;                          
40019a2c:	b8 07 00 08 	add  %i4, %o0, %i4                             
         * 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;                           
40019a30:	b0 06 00 01 	add  %i0, %g1, %i0                             
40019a34:	c8 07 bf f0 	ld  [ %fp + -16 ], %g4                         
40019a38:	da 07 bf ec 	ld  [ %fp + -20 ], %o5                         
      map_index += direction * bits_skipped;                          
    }                                                                 
                                                                      
    search_bits  += direction;                                        
40019a3c:	a6 04 c0 16 	add  %l3, %l6, %l3                             
    search_offset = direction > 0 ? 0 : rtems_rfs_bitmap_element_bits () - 1;
40019a40:	80 a6 e0 00 	cmp  %i3, 0                                    
40019a44:	04 80 00 03 	ble  40019a50 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x220>
40019a48:	82 10 20 1f 	mov  0x1f, %g1                                 
40019a4c:	82 10 20 00 	clr  %g1                                       
  }                                                                   
  while (((direction < 0) && (test_bit >= end_bit))                   
40019a50:	80 a7 40 10 	cmp  %i5, %l0                                  
40019a54:	16 80 00 03 	bge  40019a60 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x230>
40019a58:	84 10 20 01 	mov  1, %g2                                    
40019a5c:	84 10 20 00 	clr  %g2                                       
         || ((direction > 0) && (test_bit <= end_bit)));              
40019a60:	80 88 a0 ff 	btst  0xff, %g2                                
40019a64:	02 80 00 06 	be  40019a7c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x24c>
40019a68:	80 a7 40 10 	cmp  %i5, %l0                                  
40019a6c:	80 a0 e0 00 	cmp  %g3, 0                                    
40019a70:	32 bf ff 9a 	bne,a   400198d8 <rtems_rfs_search_map_for_clear_bit.constprop.1+0xa8>
40019a74:	d8 04 c0 00 	ld  [ %l3 ], %o4                               
40019a78:	80 a7 40 10 	cmp  %i5, %l0                                  
40019a7c:	04 80 00 03 	ble  40019a88 <rtems_rfs_search_map_for_clear_bit.constprop.1+0x258>
40019a80:	84 10 20 01 	mov  1, %g2                                    
40019a84:	84 10 20 00 	clr  %g2                                       
40019a88:	80 88 a0 ff 	btst  0xff, %g2                                
40019a8c:	02 80 00 04 	be  40019a9c <rtems_rfs_search_map_for_clear_bit.constprop.1+0x26c>
40019a90:	80 a5 60 00 	cmp  %l5, 0                                    
40019a94:	32 bf ff 91 	bne,a   400198d8 <rtems_rfs_search_map_for_clear_bit.constprop.1+0xa8>
40019a98:	d8 04 c0 00 	ld  [ %l3 ], %o4                               
                                                                      
  return 0;                                                           
40019a9c:	b0 10 20 00 	clr  %i0                                       
}                                                                     
40019aa0:	81 c7 e0 08 	ret                                            
40019aa4:	81 e8 00 00 	restore                                        
                                                                      

4001e89c <rtems_rfs_symlink>: const char* link, int link_length, uid_t uid, gid_t gid, rtems_rfs_ino parent) {
4001e89c:	9d e3 bf 00 	save  %sp, -256, %sp                           
  rtems_rfs_inode_handle inode;                                       
  rtems_rfs_ino          ino;                                         
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK))                      
4001e8a0:	90 10 20 02 	mov  2, %o0                                    
                   const char*            link,                       
                   int                    link_length,                
                   uid_t                  uid,                        
                   gid_t                  gid,                        
                   rtems_rfs_ino          parent)                     
{                                                                     
4001e8a4:	e2 07 a0 60 	ld  [ %fp + 0x60 ], %l1                        
4001e8a8:	e4 17 a0 5e 	lduh  [ %fp + 0x5e ], %l2                      
  rtems_rfs_inode_handle inode;                                       
  rtems_rfs_ino          ino;                                         
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK))                      
4001e8ac:	92 10 20 00 	clr  %o1                                       
4001e8b0:	7f ff d3 67 	call  4001364c <rtems_rfs_trace>               
4001e8b4:	a0 10 00 18 	mov  %i0, %l0                                  
4001e8b8:	80 a2 20 00 	cmp  %o0, 0                                    
4001e8bc:	32 80 00 07 	bne,a   4001e8d8 <rtems_rfs_symlink+0x3c>      <== NEVER TAKEN
4001e8c0:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
    printf (" link:");                                                
    for (c = 0; c < link_length; c++)                                 
      printf ("%c", link[c]);                                         
  }                                                                   
                                                                      
  if (link_length >= rtems_rfs_fs_block_size (fs))                    
4001e8c4:	c2 04 20 08 	ld  [ %l0 + 8 ], %g1                           
4001e8c8:	80 a7 00 01 	cmp  %i4, %g1                                  
4001e8cc:	1a 80 00 86 	bcc  4001eae4 <rtems_rfs_symlink+0x248>        <== NEVER TAKEN
4001e8d0:	90 10 20 5b 	mov  0x5b, %o0                                 
4001e8d4:	30 80 00 18 	b,a   4001e934 <rtems_rfs_symlink+0x98>        
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK))                      
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: symlink: parent:%" PRIu32 " name:", parent);  
4001e8d8:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
4001e8dc:	90 12 21 58 	or  %o0, 0x158, %o0                            <== NOT EXECUTED
4001e8e0:	40 00 0e 6a 	call  40022288 <printf>                        <== NOT EXECUTED
4001e8e4:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
    for (c = 0; c < length; c++)                                      
4001e8e8:	80 a6 00 1a 	cmp  %i0, %i2                                  <== NOT EXECUTED
4001e8ec:	16 80 00 07 	bge  4001e908 <rtems_rfs_symlink+0x6c>         <== NOT EXECUTED
4001e8f0:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
      printf ("%c", name[c]);                                         
4001e8f4:	d0 4e 40 18 	ldsb  [ %i1 + %i0 ], %o0                       <== NOT EXECUTED
4001e8f8:	40 00 0e ca 	call  40022420 <putchar>                       <== NOT EXECUTED
4001e8fc:	b0 06 20 01 	inc  %i0                                       <== NOT EXECUTED
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK))                      
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: symlink: parent:%" PRIu32 " name:", parent);  
    for (c = 0; c < length; c++)                                      
4001e900:	10 bf ff fb 	b  4001e8ec <rtems_rfs_symlink+0x50>           <== NOT EXECUTED
4001e904:	80 a6 00 1a 	cmp  %i0, %i2                                  <== NOT EXECUTED
      printf ("%c", name[c]);                                         
    printf (" link:");                                                
    for (c = 0; c < link_length; c++)                                 
4001e908:	b4 10 20 00 	clr  %i2                                       <== NOT EXECUTED
  {                                                                   
    int c;                                                            
    printf ("rtems-rfs: symlink: parent:%" PRIu32 " name:", parent);  
    for (c = 0; c < length; c++)                                      
      printf ("%c", name[c]);                                         
    printf (" link:");                                                
4001e90c:	40 00 0e 5f 	call  40022288 <printf>                        <== NOT EXECUTED
4001e910:	90 12 21 80 	or  %o0, 0x180, %o0                            <== NOT EXECUTED
    for (c = 0; c < link_length; c++)                                 
4001e914:	80 a6 80 1c 	cmp  %i2, %i4                                  <== NOT EXECUTED
4001e918:	36 bf ff ec 	bge,a   4001e8c8 <rtems_rfs_symlink+0x2c>      <== NOT EXECUTED
4001e91c:	c2 04 20 08 	ld  [ %l0 + 8 ], %g1                           <== NOT EXECUTED
      printf ("%c", link[c]);                                         
4001e920:	d0 4e c0 1a 	ldsb  [ %i3 + %i2 ], %o0                       <== NOT EXECUTED
4001e924:	40 00 0e bf 	call  40022420 <putchar>                       <== NOT EXECUTED
4001e928:	b4 06 a0 01 	inc  %i2                                       <== NOT EXECUTED
    int c;                                                            
    printf ("rtems-rfs: symlink: parent:%" PRIu32 " name:", parent);  
    for (c = 0; c < length; c++)                                      
      printf ("%c", name[c]);                                         
    printf (" link:");                                                
    for (c = 0; c < link_length; c++)                                 
4001e92c:	10 bf ff fb 	b  4001e918 <rtems_rfs_symlink+0x7c>           <== NOT EXECUTED
4001e930:	80 a6 80 1c 	cmp  %i2, %i4                                  <== NOT EXECUTED
  }                                                                   
                                                                      
  if (link_length >= rtems_rfs_fs_block_size (fs))                    
    return ENAMETOOLONG;                                              
                                                                      
  rc = rtems_rfs_inode_create (fs, parent, name, strlen (name),       
4001e934:	40 00 12 ba 	call  4002341c <strlen>                        
4001e938:	90 10 00 19 	mov  %i1, %o0                                  
4001e93c:	82 07 bf 74 	add  %fp, -140, %g1                            
4001e940:	96 10 00 08 	mov  %o0, %o3                                  
4001e944:	fa 23 a0 5c 	st  %i5, [ %sp + 0x5c ]                        
4001e948:	e4 23 a0 60 	st  %l2, [ %sp + 0x60 ]                        
4001e94c:	c2 23 a0 64 	st  %g1, [ %sp + 0x64 ]                        
4001e950:	90 10 00 10 	mov  %l0, %o0                                  
4001e954:	92 10 00 11 	mov  %l1, %o1                                  
4001e958:	94 10 00 19 	mov  %i1, %o2                                  
4001e95c:	19 00 00 28 	sethi  %hi(0xa000), %o4                        
4001e960:	9a 10 20 01 	mov  1, %o5                                    
4001e964:	7f ff ce 28 	call  40012204 <rtems_rfs_inode_create>        
4001e968:	98 13 21 ff 	or  %o4, 0x1ff, %o4                            
                               RTEMS_RFS_S_SYMLINK,                   
                               1, uid, gid, &ino);                    
  if (rc > 0)                                                         
4001e96c:	80 a2 20 00 	cmp  %o0, 0                                    
4001e970:	14 80 00 5d 	bg  4001eae4 <rtems_rfs_symlink+0x248>         <== NEVER TAKEN
4001e974:	d2 07 bf 74 	ld  [ %fp + -140 ], %o1                        
    return rc;                                                        
                                                                      
  rc = rtems_rfs_inode_open (fs, ino, &inode, true);                  
4001e978:	90 10 00 10 	mov  %l0, %o0                                  
4001e97c:	94 07 bf 88 	add  %fp, -120, %o2                            
4001e980:	7f ff cc d7 	call  40011cdc <rtems_rfs_inode_open>          
4001e984:	96 10 20 01 	mov  1, %o3                                    
  if (rc > 0)                                                         
4001e988:	80 a2 20 00 	cmp  %o0, 0                                    
4001e98c:	14 80 00 56 	bg  4001eae4 <rtems_rfs_symlink+0x248>         <== NEVER TAKEN
4001e990:	80 a7 20 13 	cmp  %i4, 0x13                                 
  /*                                                                  
   * 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)                   
4001e994:	38 80 00 15 	bgu,a   4001e9e8 <rtems_rfs_symlink+0x14c>     <== NEVER TAKEN
4001e998:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
  {                                                                   
    memset (inode.node->data.name, 0, RTEMS_RFS_INODE_DATA_NAME_SIZE);
4001e99c:	d0 07 bf 94 	ld  [ %fp + -108 ], %o0                        
4001e9a0:	92 10 20 00 	clr  %o1                                       
4001e9a4:	94 10 20 14 	mov  0x14, %o2                                 
4001e9a8:	40 00 0d bf 	call  400220a4 <memset>                        
4001e9ac:	90 02 20 1c 	add  %o0, 0x1c, %o0                            
    memcpy (inode.node->data.name, link, link_length);                
4001e9b0:	d0 07 bf 94 	ld  [ %fp + -108 ], %o0                        
4001e9b4:	92 10 00 1b 	mov  %i3, %o1                                  
4001e9b8:	90 02 20 1c 	add  %o0, 0x1c, %o0                            
4001e9bc:	40 00 0d 27 	call  40021e58 <memcpy>                        
4001e9c0:	94 10 00 1c 	mov  %i4, %o2                                  
 * @param[in] block_count is 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);      
4001e9c4:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
4001e9c8:	c0 28 60 0c 	clrb  [ %g1 + 0xc ]                            
4001e9cc:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
4001e9d0:	c0 28 60 0d 	clrb  [ %g1 + 0xd ]                            
4001e9d4:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
4001e9d8:	c0 28 60 0e 	clrb  [ %g1 + 0xe ]                            
4001e9dc:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
4001e9e0:	10 80 00 37 	b  4001eabc <rtems_rfs_symlink+0x220>          
4001e9e4:	c0 28 60 0f 	clrb  [ %g1 + 0xf ]                            
    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);                 
4001e9e8:	92 07 bf 88 	add  %fp, -120, %o1                            <== NOT EXECUTED
4001e9ec:	7f ff ee 22 	call  4001a274 <rtems_rfs_block_map_open>      <== NOT EXECUTED
4001e9f0:	94 07 bf b0 	add  %fp, -80, %o2                             <== NOT EXECUTED
4001e9f4:	ba 10 00 08 	mov  %o0, %i5                                  <== NOT EXECUTED
    if (rc > 0)                                                       
4001e9f8:	80 a7 60 00 	cmp  %i5, 0                                    <== NOT EXECUTED
4001e9fc:	14 80 00 2c 	bg  4001eaac <rtems_rfs_symlink+0x210>         <== NOT EXECUTED
4001ea00:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    {                                                                 
      rtems_rfs_inode_close (fs, &inode);                             
      return rc;                                                      
    }                                                                 
                                                                      
    rc = rtems_rfs_block_map_grow (fs, &map, 1, &block);              
4001ea04:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
4001ea08:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
4001ea0c:	7f ff ef 75 	call  4001a7e0 <rtems_rfs_block_map_grow>      <== NOT EXECUTED
4001ea10:	96 07 bf 78 	add  %fp, -136, %o3                            <== NOT EXECUTED
    if (rc > 0)                                                       
4001ea14:	ba 92 20 00 	orcc  %o0, 0, %i5                              <== NOT EXECUTED
4001ea18:	14 80 00 0d 	bg  4001ea4c <rtems_rfs_symlink+0x1b0>         <== NOT EXECUTED
4001ea1c:	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_buffer_handle_request (fs, &buffer, block, false); 
4001ea20:	d4 07 bf 78 	ld  [ %fp + -136 ], %o2                        <== NOT EXECUTED
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001ea24:	c0 2f bf 7c 	clrb  [ %fp + -132 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001ea28:	c0 27 bf 80 	clr  [ %fp + -128 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
4001ea2c:	c0 27 bf 84 	clr  [ %fp + -124 ]                            <== NOT EXECUTED
4001ea30:	92 07 bf 7c 	add  %fp, -132, %o1                            <== NOT EXECUTED
4001ea34:	7f ff f2 0a 	call  4001b25c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
4001ea38:	96 10 20 00 	clr  %o3                                       <== NOT EXECUTED
    if (rc > 0)                                                       
4001ea3c:	ba 92 20 00 	orcc  %o0, 0, %i5                              <== NOT EXECUTED
4001ea40:	04 80 00 07 	ble  4001ea5c <rtems_rfs_symlink+0x1c0>        <== NOT EXECUTED
4001ea44:	c2 07 bf 84 	ld  [ %fp + -124 ], %g1                        <== NOT EXECUTED
    {                                                                 
      rtems_rfs_block_map_close (fs, &map);                           
4001ea48:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
4001ea4c:	7f ff ee 68 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001ea50:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
    }                                                                 
                                                                      
    rc = rtems_rfs_block_map_close (fs, &map);                        
    if (rc > 0)                                                       
    {                                                                 
      rtems_rfs_inode_close (fs, &inode);                             
4001ea54:	10 80 00 16 	b  4001eaac <rtems_rfs_symlink+0x210>          <== NOT EXECUTED
4001ea58:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
      return rc;                                                      
    }                                                                 
                                                                      
    data = rtems_rfs_buffer_data (&buffer);                           
                                                                      
    memset (data, 0xff, rtems_rfs_fs_block_size (fs));                
4001ea5c:	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);                           
4001ea60:	c2 00 60 1c 	ld  [ %g1 + 0x1c ], %g1                        <== NOT EXECUTED
                                                                      
    memset (data, 0xff, rtems_rfs_fs_block_size (fs));                
4001ea64:	92 10 20 ff 	mov  0xff, %o1                                 <== NOT EXECUTED
4001ea68:	40 00 0d 8f 	call  400220a4 <memset>                        <== NOT EXECUTED
4001ea6c:	90 10 00 01 	mov  %g1, %o0                                  <== NOT EXECUTED
    memcpy (data, link, link_length);                                 
4001ea70:	94 10 00 1c 	mov  %i4, %o2                                  <== NOT EXECUTED
4001ea74:	40 00 0c f9 	call  40021e58 <memcpy>                        <== NOT EXECUTED
4001ea78:	92 10 00 1b 	mov  %i3, %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);                       
4001ea7c:	92 07 bf 7c 	add  %fp, -132, %o1                            <== NOT EXECUTED
4001ea80:	7f ff f1 6e 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001ea84:	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);                        
4001ea88:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
  handle->dirty = false;                                              
4001ea8c:	c0 2f bf 7c 	clrb  [ %fp + -132 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001ea90:	c0 27 bf 80 	clr  [ %fp + -128 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
4001ea94:	c0 27 bf 84 	clr  [ %fp + -124 ]                            <== NOT EXECUTED
4001ea98:	7f ff ee 55 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001ea9c:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
    if (rc > 0)                                                       
4001eaa0:	ba 92 20 00 	orcc  %o0, 0, %i5                              <== NOT EXECUTED
4001eaa4:	04 80 00 06 	ble  4001eabc <rtems_rfs_symlink+0x220>        <== NOT EXECUTED
4001eaa8:	90 10 00 10 	mov  %l0, %o0                                  <== NOT EXECUTED
    {                                                                 
      rtems_rfs_inode_close (fs, &inode);                             
4001eaac:	7f ff cc fe 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001eab0:	92 07 bf 88 	add  %fp, -120, %o1                            <== NOT EXECUTED
      return rc;                                                      
4001eab4:	10 80 00 0c 	b  4001eae4 <rtems_rfs_symlink+0x248>          <== NOT EXECUTED
4001eab8:	90 10 00 1d 	mov  %i5, %o0                                  <== 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);    
4001eabc:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
4001eac0:	85 37 20 08 	srl  %i4, 8, %g2                               
4001eac4:	c4 28 60 0a 	stb  %g2, [ %g1 + 0xa ]                        
4001eac8:	c2 07 bf 94 	ld  [ %fp + -108 ], %g1                        
    }                                                                 
  }                                                                   
                                                                      
  rtems_rfs_inode_set_block_offset (&inode, link_length);             
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
4001eacc:	90 10 00 10 	mov  %l0, %o0                                  
4001ead0:	f8 28 60 0b 	stb  %i4, [ %g1 + 0xb ]                        
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001ead4:	82 10 20 01 	mov  1, %g1                                    
4001ead8:	92 07 bf 88 	add  %fp, -120, %o1                            
4001eadc:	7f ff cc f2 	call  40011ea4 <rtems_rfs_inode_close>         
4001eae0:	c2 2f bf 98 	stb  %g1, [ %fp + -104 ]                       
                                                                      
  return rc;                                                          
}                                                                     
4001eae4:	81 c7 e0 08 	ret                                            
4001eae8:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001eaec <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) {
4001eaec:	9d e3 bf 18 	save  %sp, -232, %sp                           
  rtems_rfs_inode_handle inode;                                       
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_SYMLINK_READ))                 
4001eaf0:	90 10 20 04 	mov  4, %o0                                    
4001eaf4:	92 10 20 00 	clr  %o1                                       
4001eaf8:	7f ff d2 d5 	call  4001364c <rtems_rfs_trace>               
4001eafc:	ba 10 00 18 	mov  %i0, %i5                                  
4001eb00:	80 a2 20 00 	cmp  %o0, 0                                    
4001eb04:	22 80 00 07 	be,a   4001eb20 <rtems_rfs_symlink_read+0x34>  <== ALWAYS TAKEN
4001eb08:	90 10 00 1d 	mov  %i5, %o0                                  
    printf ("rtems-rfs: symlink-read: link:%" PRIu32 "\n", link);     
4001eb0c:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001eb10:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4001eb14:	40 00 0d dd 	call  40022288 <printf>                        <== NOT EXECUTED
4001eb18:	90 12 21 88 	or  %o0, 0x188, %o0                            <== NOT EXECUTED
                                                                      
  rc = rtems_rfs_inode_open (fs, link, &inode, true);                 
4001eb1c:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001eb20:	92 10 00 19 	mov  %i1, %o1                                  
4001eb24:	94 07 bf 88 	add  %fp, -120, %o2                            
4001eb28:	7f ff cc 6d 	call  40011cdc <rtems_rfs_inode_open>          
4001eb2c:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001eb30:	80 a2 20 00 	cmp  %o0, 0                                    
4001eb34:	12 80 00 5b 	bne  4001eca0 <rtems_rfs_symlink_read+0x1b4>   <== NEVER TAKEN
4001eb38:	d2 07 bf 94 	ld  [ %fp + -108 ], %o1                        
    return rc;                                                        
                                                                      
  if (!RTEMS_RFS_S_ISLNK (rtems_rfs_inode_get_mode (&inode)))         
4001eb3c:	03 00 00 3c 	sethi  %hi(0xf000), %g1                        
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
4001eb40:	c4 0a 60 02 	ldub  [ %o1 + 2 ], %g2                         
4001eb44:	85 28 a0 08 	sll  %g2, 8, %g2                               
4001eb48:	84 08 80 01 	and  %g2, %g1, %g2                             
4001eb4c:	03 00 00 28 	sethi  %hi(0xa000), %g1                        
4001eb50:	80 a0 80 01 	cmp  %g2, %g1                                  
4001eb54:	02 80 00 06 	be  4001eb6c <rtems_rfs_symlink_read+0x80>     <== ALWAYS TAKEN
4001eb58:	90 10 00 1d 	mov  %i5, %o0                                  
  {                                                                   
    rtems_rfs_inode_close (fs, &inode);                               
4001eb5c:	7f ff cc d2 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001eb60:	92 07 bf 88 	add  %fp, -120, %o1                            <== NOT EXECUTED
    return EINVAL;                                                    
4001eb64:	10 80 00 4f 	b  4001eca0 <rtems_rfs_symlink_read+0x1b4>     <== NOT EXECUTED
4001eb68:	90 10 20 16 	mov  0x16, %o0                                 <== NOT EXECUTED
 * @retval offset The block offset.                                   
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_block_offset (rtems_rfs_inode_handle* handle)     
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->block_offset);            
4001eb6c:	d4 0a 60 0a 	ldub  [ %o1 + 0xa ], %o2                       
  }                                                                   
                                                                      
  *length = rtems_rfs_inode_get_block_offset (&inode);                
4001eb70:	c2 0a 60 0b 	ldub  [ %o1 + 0xb ], %g1                       
4001eb74:	95 2a a0 08 	sll  %o2, 8, %o2                               
4001eb78:	94 10 40 0a 	or  %g1, %o2, %o2                              
4001eb7c:	80 a2 80 1b 	cmp  %o2, %i3                                  
4001eb80:	38 80 00 02 	bgu,a   4001eb88 <rtems_rfs_symlink_read+0x9c> 
4001eb84:	94 10 00 1b 	mov  %i3, %o2                                  
4001eb88:	d4 27 00 00 	st  %o2, [ %i4 ]                               
 * @retval count 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);             
4001eb8c:	c2 0a 60 0d 	ldub  [ %o1 + 0xd ], %g1                       
4001eb90:	c4 0a 60 0c 	ldub  [ %o1 + 0xc ], %g2                       
4001eb94:	83 28 60 10 	sll  %g1, 0x10, %g1                            
4001eb98:	85 28 a0 18 	sll  %g2, 0x18, %g2                            
4001eb9c:	84 10 80 01 	or  %g2, %g1, %g2                              
4001eba0:	c2 0a 60 0f 	ldub  [ %o1 + 0xf ], %g1                       
4001eba4:	84 10 80 01 	or  %g2, %g1, %g2                              
4001eba8:	c2 0a 60 0e 	ldub  [ %o1 + 0xe ], %g1                       
4001ebac:	83 28 60 08 	sll  %g1, 8, %g1                               
  if (size < *length)                                                 
  {                                                                   
    *length = size;                                                   
  }                                                                   
                                                                      
  if (rtems_rfs_inode_get_block_count (&inode) == 0)                  
4001ebb0:	80 90 80 01 	orcc  %g2, %g1, %g0                            
4001ebb4:	32 80 00 07 	bne,a   4001ebd0 <rtems_rfs_symlink_read+0xe4> <== NEVER TAKEN
4001ebb8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  {                                                                   
    memcpy (path, inode.node->data.name, *length);                    
4001ebbc:	90 10 00 1a 	mov  %i2, %o0                                  
4001ebc0:	40 00 0c a6 	call  40021e58 <memcpy>                        
4001ebc4:	92 02 60 1c 	add  %o1, 0x1c, %o1                            
4001ebc8:	10 80 00 34 	b  4001ec98 <rtems_rfs_symlink_read+0x1ac>     
4001ebcc:	90 10 00 1d 	mov  %i5, %o0                                  
    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);                 
4001ebd0:	92 07 bf 88 	add  %fp, -120, %o1                            <== NOT EXECUTED
4001ebd4:	7f ff ed a8 	call  4001a274 <rtems_rfs_block_map_open>      <== NOT EXECUTED
4001ebd8:	94 07 bf b0 	add  %fp, -80, %o2                             <== NOT EXECUTED
4001ebdc:	b0 10 00 08 	mov  %o0, %i0                                  <== NOT EXECUTED
    if (rc > 0)                                                       
4001ebe0:	80 a6 20 00 	cmp  %i0, 0                                    <== NOT EXECUTED
4001ebe4:	14 80 00 29 	bg  4001ec88 <rtems_rfs_symlink_read+0x19c>    <== NOT EXECUTED
4001ebe8:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    {                                                                 
      rtems_rfs_inode_close (fs, &inode);                             
      return rc;                                                      
    }                                                                 
                                                                      
    rc = rtems_rfs_block_map_seek (fs, &map, 0, &block);              
4001ebec:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
4001ebf0:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
4001ebf4:	96 10 20 00 	clr  %o3                                       <== NOT EXECUTED
4001ebf8:	7f ff ee d0 	call  4001a738 <rtems_rfs_block_map_seek>      <== NOT EXECUTED
4001ebfc:	98 07 bf 78 	add  %fp, -136, %o4                            <== NOT EXECUTED
    if (rc > 0)                                                       
4001ec00:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
4001ec04:	14 80 00 0c 	bg  4001ec34 <rtems_rfs_symlink_read+0x148>    <== NOT EXECUTED
4001ec08:	90 10 00 1d 	mov  %i5, %o0                                  <== 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); 
4001ec0c:	d4 07 bf 78 	ld  [ %fp + -136 ], %o2                        <== NOT EXECUTED
 */                                                                   
static inline int                                                     
rtems_rfs_buffer_handle_open (rtems_rfs_file_system*   fs,            
                              rtems_rfs_buffer_handle* handle)        
{                                                                     
  handle->dirty = false;                                              
4001ec10:	c0 2f bf 7c 	clrb  [ %fp + -132 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001ec14:	c0 27 bf 80 	clr  [ %fp + -128 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
4001ec18:	c0 27 bf 84 	clr  [ %fp + -124 ]                            <== NOT EXECUTED
4001ec1c:	92 07 bf 7c 	add  %fp, -132, %o1                            <== NOT EXECUTED
4001ec20:	7f ff f1 8f 	call  4001b25c <rtems_rfs_buffer_handle_request><== NOT EXECUTED
4001ec24:	96 10 20 00 	clr  %o3                                       <== NOT EXECUTED
    if (rc > 0)                                                       
4001ec28:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
4001ec2c:	04 80 00 06 	ble  4001ec44 <rtems_rfs_symlink_read+0x158>   <== NOT EXECUTED
4001ec30:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    {                                                                 
      rtems_rfs_block_map_close (fs, &map);                           
4001ec34:	7f ff ed ee 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001ec38:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
    }                                                                 
                                                                      
    rc = rtems_rfs_block_map_close (fs, &map);                        
    if (rc > 0)                                                       
    {                                                                 
      rtems_rfs_inode_close (fs, &inode);                             
4001ec3c:	10 80 00 13 	b  4001ec88 <rtems_rfs_symlink_read+0x19c>     <== NOT EXECUTED
4001ec40:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      rtems_rfs_inode_close (fs, &inode);                             
      return rc;                                                      
    }                                                                 
                                                                      
    data = rtems_rfs_buffer_data (&buffer);                           
    memcpy (path, data, *length);                                     
4001ec44:	c2 07 bf 84 	ld  [ %fp + -124 ], %g1                        <== NOT EXECUTED
4001ec48:	d4 07 00 00 	ld  [ %i4 ], %o2                               <== NOT EXECUTED
4001ec4c:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1                        <== NOT EXECUTED
4001ec50:	40 00 0c 82 	call  40021e58 <memcpy>                        <== NOT EXECUTED
4001ec54:	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);                       
4001ec58:	92 07 bf 7c 	add  %fp, -132, %o1                            <== NOT EXECUTED
4001ec5c:	7f ff f0 f7 	call  4001b038 <rtems_rfs_buffer_handle_release><== NOT EXECUTED
4001ec60:	90 10 00 1d 	mov  %i5, %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);                        
4001ec64:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
  handle->dirty = false;                                              
4001ec68:	c0 2f bf 7c 	clrb  [ %fp + -132 ]                           <== NOT EXECUTED
  handle->bnum  = 0;                                                  
4001ec6c:	c0 27 bf 80 	clr  [ %fp + -128 ]                            <== NOT EXECUTED
  handle->buffer = NULL;                                              
4001ec70:	c0 27 bf 84 	clr  [ %fp + -124 ]                            <== NOT EXECUTED
4001ec74:	7f ff ed de 	call  4001a3ec <rtems_rfs_block_map_close>     <== NOT EXECUTED
4001ec78:	92 07 bf b0 	add  %fp, -80, %o1                             <== NOT EXECUTED
    if (rc > 0)                                                       
4001ec7c:	b0 92 20 00 	orcc  %o0, 0, %i0                              <== NOT EXECUTED
4001ec80:	04 80 00 06 	ble  4001ec98 <rtems_rfs_symlink_read+0x1ac>   <== NOT EXECUTED
4001ec84:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
    {                                                                 
      rtems_rfs_inode_close (fs, &inode);                             
4001ec88:	7f ff cc 87 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001ec8c:	92 07 bf 88 	add  %fp, -120, %o1                            <== NOT EXECUTED
      return rc;                                                      
4001ec90:	10 80 00 04 	b  4001eca0 <rtems_rfs_symlink_read+0x1b4>     <== NOT EXECUTED
4001ec94:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &inode);                            
4001ec98:	7f ff cc 83 	call  40011ea4 <rtems_rfs_inode_close>         
4001ec9c:	92 07 bf 88 	add  %fp, -120, %o1                            
                                                                      
  return rc;                                                          
}                                                                     
4001eca0:	81 c7 e0 08 	ret                                            
4001eca4:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4001e4a8 <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) {
4001e4a8:	9d e3 bf 50 	save  %sp, -176, %sp                           
  rtems_rfs_inode_handle target_inode;                                
  uint16_t               links;                                       
  bool                   dir;                                         
  int                    rc;                                          
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                       
4001e4ac:	90 10 20 00 	clr  %o0                                       
4001e4b0:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     
4001e4b4:	7f ff d4 66 	call  4001364c <rtems_rfs_trace>               
4001e4b8:	ba 10 00 18 	mov  %i0, %i5                                  
4001e4bc:	80 a2 20 00 	cmp  %o0, 0                                    
4001e4c0:	02 80 00 08 	be  4001e4e0 <rtems_rfs_unlink+0x38>           <== ALWAYS TAKEN
4001e4c4:	90 10 00 1d 	mov  %i5, %o0                                  
    printf ("rtems-rfs: unlink: parent(%" PRIu32 ") -X-> (%" PRIu32 ")\n", parent, target);
4001e4c8:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e4cc:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
4001e4d0:	90 12 23 88 	or  %o0, 0x388, %o0                            <== NOT EXECUTED
4001e4d4:	40 00 0f 6d 	call  40022288 <printf>                        <== NOT EXECUTED
4001e4d8:	94 10 00 1a 	mov  %i2, %o2                                  <== NOT EXECUTED
                                                                      
  rc = rtems_rfs_inode_open (fs, target, &target_inode, true);        
4001e4dc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001e4e0:	92 10 00 1a 	mov  %i2, %o1                                  
4001e4e4:	94 07 bf d8 	add  %fp, -40, %o2                             
4001e4e8:	7f ff cd fd 	call  40011cdc <rtems_rfs_inode_open>          
4001e4ec:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001e4f0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e4f4:	12 80 00 20 	bne  4001e574 <rtems_rfs_unlink+0xcc>          <== NEVER TAKEN
4001e4f8:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
                                                                      
  /*                                                                  
   * If a directory process the unlink mode.                          
   */                                                                 
                                                                      
  dir = RTEMS_RFS_S_ISDIR (rtems_rfs_inode_get_mode (&target_inode)); 
4001e4fc:	05 00 00 3c 	sethi  %hi(0xf000), %g2                        
 * @retval mode The mode.                                             
 */                                                                   
static inline uint16_t                                                
rtems_rfs_inode_get_mode (rtems_rfs_inode_handle* handle)             
{                                                                     
  return rtems_rfs_read_u16 (&handle->node->mode);                    
4001e500:	c2 08 60 02 	ldub  [ %g1 + 2 ], %g1                         
4001e504:	83 28 60 08 	sll  %g1, 8, %g1                               
4001e508:	82 08 40 02 	and  %g1, %g2, %g1                             
4001e50c:	05 00 00 10 	sethi  %hi(0x4000), %g2                        
4001e510:	82 18 40 02 	xor  %g1, %g2, %g1                             
  if (dir)                                                            
4001e514:	80 a0 00 01 	cmp  %g0, %g1                                  
4001e518:	a0 60 3f ff 	subx  %g0, -1, %l0                             
4001e51c:	80 a4 20 00 	cmp  %l0, 0                                    
4001e520:	02 80 00 27 	be  4001e5bc <rtems_rfs_unlink+0x114>          
4001e524:	80 a7 20 00 	cmp  %i4, 0                                    
  {                                                                   
    switch (dir_mode)                                                 
4001e528:	02 80 00 06 	be  4001e540 <rtems_rfs_unlink+0x98>           <== NEVER TAKEN
4001e52c:	80 a7 20 01 	cmp  %i4, 1                                    
4001e530:	02 80 00 13 	be  4001e57c <rtems_rfs_unlink+0xd4>           <== ALWAYS TAKEN
4001e534:	90 10 00 1d 	mov  %i5, %o0                                  
      default:                                                        
        break;                                                        
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);        
4001e538:	10 80 00 23 	b  4001e5c4 <rtems_rfs_unlink+0x11c>           <== NOT EXECUTED
4001e53c:	92 10 00 19 	mov  %i1, %o1                                  <== NOT EXECUTED
  if (dir)                                                            
  {                                                                   
    switch (dir_mode)                                                 
    {                                                                 
      case rtems_rfs_unlink_dir_denied:                               
        if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                 
4001e540:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e544:	7f ff d4 42 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e548:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e54c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e550:	22 80 00 06 	be,a   4001e568 <rtems_rfs_unlink+0xc0>        <== NOT EXECUTED
4001e554:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
          printf ("rtems-rfs: link is a directory\n");                
4001e558:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e55c:	40 00 0f da 	call  400224c4 <puts>                          <== NOT EXECUTED
4001e560:	90 12 23 b8 	or  %o0, 0x3b8, %o0	! 40035bb8 <CSWTCH.1+0x1468><== NOT EXECUTED
        rtems_rfs_inode_close (fs, &target_inode);                    
4001e564:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001e568:	92 07 bf d8 	add  %fp, -40, %o1                             <== NOT EXECUTED
4001e56c:	7f ff ce 4e 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001e570:	b0 10 20 15 	mov  0x15, %i0                                 <== NOT EXECUTED
        return EISDIR;                                                
4001e574:	81 c7 e0 08 	ret                                            
4001e578:	81 e8 00 00 	restore                                        
                                                                      
      case rtems_rfs_unlink_dir_if_empty:                             
        rc = rtems_rfs_dir_empty (fs, &target_inode);                 
4001e57c:	7f ff f8 eb 	call  4001c928 <rtems_rfs_dir_empty>           
4001e580:	92 07 bf d8 	add  %fp, -40, %o1                             
        if (rc > 0)                                                   
4001e584:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e588:	04 80 00 0d 	ble  4001e5bc <rtems_rfs_unlink+0x114>         
4001e58c:	90 10 20 00 	clr  %o0                                       
        {                                                             
          if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))               
4001e590:	7f ff d4 2f 	call  4001364c <rtems_rfs_trace>               
4001e594:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     
4001e598:	80 a2 20 00 	cmp  %o0, 0                                    
4001e59c:	22 80 00 a8 	be,a   4001e83c <rtems_rfs_unlink+0x394>       <== ALWAYS TAKEN
4001e5a0:	90 10 00 1d 	mov  %i5, %o0                                  
            printf ("rtems-rfs: dir-empty: %d: %s\n", rc, strerror (rc));
4001e5a4:	40 00 13 7a 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e5a8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e5ac:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e5b0:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e5b4:	10 80 00 9f 	b  4001e830 <rtems_rfs_unlink+0x388>           <== NOT EXECUTED
4001e5b8:	90 12 23 d8 	or  %o0, 0x3d8, %o0	! 40035bd8 <CSWTCH.1+0x1488><== NOT EXECUTED
      default:                                                        
        break;                                                        
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_open (fs, parent, &parent_inode, true);        
4001e5bc:	90 10 00 1d 	mov  %i5, %o0                                  
4001e5c0:	92 10 00 19 	mov  %i1, %o1                                  
4001e5c4:	94 07 bf b0 	add  %fp, -80, %o2                             
4001e5c8:	7f ff cd c5 	call  40011cdc <rtems_rfs_inode_open>          
4001e5cc:	96 10 20 01 	mov  1, %o3                                    
  if (rc)                                                             
4001e5d0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e5d4:	02 80 00 0e 	be  4001e60c <rtems_rfs_unlink+0x164>          <== ALWAYS TAKEN
4001e5d8:	90 10 00 1d 	mov  %i5, %o0                                  
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                     
4001e5dc:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
4001e5e0:	7f ff d4 1b 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e5e4:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e5e8:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e5ec:	22 80 00 94 	be,a   4001e83c <rtems_rfs_unlink+0x394>       <== NOT EXECUTED
4001e5f0:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: link: inode-open failed: %d: %s\n",         
4001e5f4:	40 00 13 66 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e5f8:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e5fc:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e600:	11 10 00 d6 	sethi  %hi(0x40035800), %o0                    <== NOT EXECUTED
4001e604:	10 80 00 8b 	b  4001e830 <rtems_rfs_unlink+0x388>           <== NOT EXECUTED
4001e608:	90 12 23 f8 	or  %o0, 0x3f8, %o0	! 40035bf8 <CSWTCH.1+0x14a8><== 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);     
4001e60c:	92 07 bf b0 	add  %fp, -80, %o1                             
4001e610:	94 10 00 1a 	mov  %i2, %o2                                  
4001e614:	7f ff f6 ee 	call  4001c1cc <rtems_rfs_dir_del_entry>       
4001e618:	96 10 00 1b 	mov  %i3, %o3                                  
  if (rc > 0)                                                         
4001e61c:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e620:	04 80 00 0d 	ble  4001e654 <rtems_rfs_unlink+0x1ac>         <== ALWAYS TAKEN
4001e624:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                     
4001e628:	7f ff d4 09 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e62c:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e630:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e634:	22 80 00 6b 	be,a   4001e7e0 <rtems_rfs_unlink+0x338>       <== NOT EXECUTED
4001e638:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: unlink: dir-del failed: %d: %s\n",          
4001e63c:	40 00 13 54 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e640:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e644:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e648:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001e64c:	10 80 00 62 	b  4001e7d4 <rtems_rfs_unlink+0x32c>           <== NOT EXECUTED
4001e650:	90 12 20 28 	or  %o0, 0x28, %o0	! 40035c28 <CSWTCH.1+0x14d8><== NOT EXECUTED
    rtems_rfs_inode_close (fs, &parent_inode);                        
    rtems_rfs_inode_close (fs, &target_inode);                        
    return rc;                                                        
  }                                                                   
                                                                      
  links = rtems_rfs_inode_get_links (&target_inode);                  
4001e654:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
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)                                                
4001e658:	05 3f ff c0 	sethi  %hi(0xffff0000), %g2                    
 */                                                                   
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);                  
4001e65c:	f8 08 40 00 	ldub  [ %g1 ], %i4                             
4001e660:	c2 08 60 01 	ldub  [ %g1 + 1 ], %g1                         
4001e664:	b9 2f 20 08 	sll  %i4, 8, %i4                               
4001e668:	b8 17 00 01 	or  %i4, %g1, %i4                              
  if (links == 0xffff)                                                
4001e66c:	83 2f 20 10 	sll  %i4, 0x10, %g1                            
4001e670:	83 30 60 10 	srl  %g1, 0x10, %g1                            
    links = 0;                                                        
4001e674:	82 38 80 01 	xnor  %g2, %g1, %g1                            
4001e678:	80 a0 00 01 	cmp  %g0, %g1                                  
4001e67c:	82 60 20 00 	subx  %g0, 0, %g1                              
4001e680:	b8 0f 00 01 	and  %i4, %g1, %i4                             
                                                                      
  if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                       
4001e684:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     
4001e688:	7f ff d3 f1 	call  4001364c <rtems_rfs_trace>               
4001e68c:	b7 2f 20 10 	sll  %i4, 0x10, %i3                            
4001e690:	80 a2 20 00 	cmp  %o0, 0                                    
4001e694:	22 80 00 08 	be,a   4001e6b4 <rtems_rfs_unlink+0x20c>       <== ALWAYS TAKEN
4001e698:	b7 36 e0 10 	srl  %i3, 0x10, %i3                            
    printf ("rtems-rfs: unlink: target:%" PRIu32 " links:%u\n", target, links);
4001e69c:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001e6a0:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
4001e6a4:	90 12 20 58 	or  %o0, 0x58, %o0                             <== NOT EXECUTED
4001e6a8:	40 00 0e f8 	call  40022288 <printf>                        <== NOT EXECUTED
4001e6ac:	95 36 e0 10 	srl  %i3, 0x10, %o2                            <== NOT EXECUTED
                                                                      
  if (links > 1)                                                      
4001e6b0:	b7 36 e0 10 	srl  %i3, 0x10, %i3                            <== NOT EXECUTED
4001e6b4:	80 a6 e0 01 	cmp  %i3, 1                                    
4001e6b8:	08 80 00 0a 	bleu  4001e6e0 <rtems_rfs_unlink+0x238>        
4001e6bc:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
  {                                                                   
    links--;                                                          
4001e6c0:	b8 07 3f ff 	add  %i4, -1, %i4                              
 * @param[in] links are 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);                  
4001e6c4:	85 37 20 08 	srl  %i4, 8, %g2                               
4001e6c8:	c4 28 40 00 	stb  %g2, [ %g1 ]                              
4001e6cc:	c2 07 bf e4 	ld  [ %fp + -28 ], %g1                         
4001e6d0:	f8 28 60 01 	stb  %i4, [ %g1 + 1 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001e6d4:	82 10 20 01 	mov  1, %g1                                    
4001e6d8:	10 80 00 2e 	b  4001e790 <rtems_rfs_unlink+0x2e8>           
4001e6dc:	c2 2f bf e8 	stb  %g1, [ %fp + -24 ]                        
  else                                                                
  {                                                                   
    /*                                                                
     * Erasing the inode releases all blocks attached to it.          
     */                                                               
    rc = rtems_rfs_inode_delete (fs, &target_inode);                  
4001e6e0:	90 10 00 1d 	mov  %i5, %o0                                  
4001e6e4:	7f ff ce 13 	call  40011f30 <rtems_rfs_inode_delete>        
4001e6e8:	92 07 bf d8 	add  %fp, -40, %o1                             
    if (rc > 0)                                                       
4001e6ec:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e6f0:	04 80 00 0d 	ble  4001e724 <rtems_rfs_unlink+0x27c>         <== ALWAYS TAKEN
4001e6f4:	90 10 20 00 	clr  %o0                                       
    {                                                                 
      if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                   
4001e6f8:	7f ff d3 d5 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e6fc:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e700:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e704:	22 80 00 37 	be,a   4001e7e0 <rtems_rfs_unlink+0x338>       <== NOT EXECUTED
4001e708:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
        printf ("rtems-rfs: unlink: inode-del failed: %d: %s\n",      
4001e70c:	40 00 13 20 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e710:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e714:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e718:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001e71c:	10 80 00 2e 	b  4001e7d4 <rtems_rfs_unlink+0x32c>           <== NOT EXECUTED
4001e720:	90 12 20 80 	or  %o0, 0x80, %o0	! 40035c80 <CSWTCH.1+0x1530><== NOT EXECUTED
      rtems_rfs_inode_close (fs, &parent_inode);                      
      rtems_rfs_inode_close (fs, &target_inode);                      
      return rc;                                                      
    }                                                                 
                                                                      
    if (dir)                                                          
4001e724:	80 a4 20 00 	cmp  %l0, 0                                    
4001e728:	02 80 00 1b 	be  4001e794 <rtems_rfs_unlink+0x2ec>          
4001e72c:	90 07 bf b0 	add  %fp, -80, %o0                             
    {                                                                 
      links = rtems_rfs_inode_get_links (&parent_inode);              
4001e730:	c4 07 bf bc 	ld  [ %fp + -68 ], %g2                         
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)                                                
4001e734:	39 00 00 3f 	sethi  %hi(0xfc00), %i4                        
 */                                                                   
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);                  
4001e738:	c2 08 a0 01 	ldub  [ %g2 + 1 ], %g1                         
4001e73c:	c6 08 80 00 	ldub  [ %g2 ], %g3                             
  if (links == 0xffff)                                                
4001e740:	b8 17 23 ff 	or  %i4, 0x3ff, %i4                            
 */                                                                   
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);                  
4001e744:	87 28 e0 08 	sll  %g3, 8, %g3                               
4001e748:	86 10 c0 01 	or  %g3, %g1, %g3                              
  if (links == 0xffff)                                                
4001e74c:	89 28 e0 10 	sll  %g3, 0x10, %g4                            
4001e750:	89 31 20 10 	srl  %g4, 0x10, %g4                            
4001e754:	80 a1 00 1c 	cmp  %g4, %i4                                  
4001e758:	02 80 00 07 	be  4001e774 <rtems_rfs_unlink+0x2cc>          <== NEVER TAKEN
4001e75c:	82 10 00 03 	mov  %g3, %g1                                  
      if (links > 1)                                                  
4001e760:	80 a1 20 01 	cmp  %g4, 1                                    
4001e764:	38 80 00 05 	bgu,a   4001e778 <rtems_rfs_unlink+0x2d0>      
4001e768:	82 00 ff ff 	add  %g3, -1, %g1                              
 * @param[in] links are 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);                  
4001e76c:	10 80 00 04 	b  4001e77c <rtems_rfs_unlink+0x2d4>           
4001e770:	87 30 60 08 	srl  %g1, 8, %g3                               
rtems_rfs_inode_get_links (rtems_rfs_inode_handle* handle)            
{                                                                     
  uint16_t links;                                                     
  links = rtems_rfs_read_u16 (&handle->node->links);                  
  if (links == 0xffff)                                                
    links = 0;                                                        
4001e774:	82 10 20 00 	clr  %g1                                       <== NOT EXECUTED
 * @param[in] links are 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);                  
4001e778:	87 30 60 08 	srl  %g1, 8, %g3                               
4001e77c:	c6 28 80 00 	stb  %g3, [ %g2 ]                              
4001e780:	c4 07 bf bc 	ld  [ %fp + -68 ], %g2                         
4001e784:	c2 28 a0 01 	stb  %g1, [ %g2 + 1 ]                          
  rtems_rfs_buffer_mark_dirty (&handle->buffer);                      
4001e788:	82 10 20 01 	mov  1, %g1                                    
4001e78c:	c2 2f bf c0 	stb  %g1, [ %fp + -64 ]                        
        links--;                                                      
      rtems_rfs_inode_set_links (&parent_inode, links);               
    }                                                                 
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_time_stamp_now (&parent_inode, true, true);    
4001e790:	90 07 bf b0 	add  %fp, -80, %o0                             
4001e794:	92 10 20 01 	mov  1, %o1                                    
4001e798:	7f ff ce 1e 	call  40012010 <rtems_rfs_inode_time_stamp_now>
4001e79c:	94 10 20 01 	mov  1, %o2                                    
  if (rc > 0)                                                         
4001e7a0:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e7a4:	04 80 00 13 	ble  4001e7f0 <rtems_rfs_unlink+0x348>         <== ALWAYS TAKEN
4001e7a8:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                     
4001e7ac:	7f ff d3 a8 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e7b0:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e7b4:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e7b8:	22 80 00 0a 	be,a   4001e7e0 <rtems_rfs_unlink+0x338>       <== NOT EXECUTED
4001e7bc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: link: inode-time-stamp failed: %d: %s\n",   
4001e7c0:	40 00 12 f3 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e7c4:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e7c8:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e7cc:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001e7d0:	90 12 20 b0 	or  %o0, 0xb0, %o0	! 40035cb0 <CSWTCH.1+0x1560><== NOT EXECUTED
4001e7d4:	40 00 0e ad 	call  40022288 <printf>                        <== NOT EXECUTED
4001e7d8:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
              rc, strerror (rc));                                     
    rtems_rfs_inode_close (fs, &parent_inode);                        
4001e7dc:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001e7e0:	7f ff cd b1 	call  40011ea4 <rtems_rfs_inode_close>         <== NOT EXECUTED
4001e7e4:	92 07 bf b0 	add  %fp, -80, %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);                        
4001e7e8:	10 80 00 15 	b  4001e83c <rtems_rfs_unlink+0x394>           <== NOT EXECUTED
4001e7ec:	90 10 00 1d 	mov  %i5, %o0                                  <== 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);                     
4001e7f0:	90 10 00 1d 	mov  %i5, %o0                                  
4001e7f4:	7f ff cd ac 	call  40011ea4 <rtems_rfs_inode_close>         
4001e7f8:	92 07 bf b0 	add  %fp, -80, %o1                             
  if (rc > 0)                                                         
4001e7fc:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e800:	04 80 00 13 	ble  4001e84c <rtems_rfs_unlink+0x3a4>         <== ALWAYS TAKEN
4001e804:	90 10 20 00 	clr  %o0                                       
  {                                                                   
    if (rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))                     
4001e808:	7f ff d3 91 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e80c:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e810:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e814:	02 80 00 0a 	be  4001e83c <rtems_rfs_unlink+0x394>          <== NOT EXECUTED
4001e818:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
      printf ("rtems-rfs: link: parent inode-close failed: %d: %s\n", 
4001e81c:	40 00 12 dc 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e820:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e824:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e828:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001e82c:	90 12 20 e8 	or  %o0, 0xe8, %o0	! 40035ce8 <CSWTCH.1+0x1598><== NOT EXECUTED
4001e830:	40 00 0e 96 	call  40022288 <printf>                        <== NOT EXECUTED
4001e834:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
              rc, strerror (rc));                                     
    rtems_rfs_inode_close (fs, &target_inode);                        
4001e838:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
4001e83c:	7f ff cd 9a 	call  40011ea4 <rtems_rfs_inode_close>         
4001e840:	92 07 bf d8 	add  %fp, -40, %o1                             
    return rc;                                                        
4001e844:	81 c7 e0 08 	ret                                            
4001e848:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  rc = rtems_rfs_inode_close (fs, &target_inode);                     
4001e84c:	90 10 00 1d 	mov  %i5, %o0                                  
4001e850:	7f ff cd 95 	call  40011ea4 <rtems_rfs_inode_close>         
4001e854:	92 07 bf d8 	add  %fp, -40, %o1                             
                                                                      
  if ((rc > 0) && rtems_rfs_trace (RTEMS_RFS_TRACE_UNLINK))           
4001e858:	b0 92 20 00 	orcc  %o0, 0, %i0                              
4001e85c:	04 bf ff 46 	ble  4001e574 <rtems_rfs_unlink+0xcc>          <== ALWAYS TAKEN
4001e860:	90 10 20 00 	clr  %o0                                       
4001e864:	7f ff d3 7a 	call  4001364c <rtems_rfs_trace>               <== NOT EXECUTED
4001e868:	13 00 80 00 	sethi  %hi(0x2000000), %o1                     <== NOT EXECUTED
4001e86c:	80 a2 20 00 	cmp  %o0, 0                                    <== NOT EXECUTED
4001e870:	02 80 00 09 	be  4001e894 <rtems_rfs_unlink+0x3ec>          <== NOT EXECUTED
4001e874:	01 00 00 00 	nop                                            <== NOT EXECUTED
    printf ("rtems-rfs: link: target inode-close failed: %d: %s\n",   
4001e878:	40 00 12 c5 	call  4002338c <strerror>                      <== NOT EXECUTED
4001e87c:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
4001e880:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
4001e884:	94 10 00 08 	mov  %o0, %o2                                  <== NOT EXECUTED
4001e888:	11 10 00 d7 	sethi  %hi(0x40035c00), %o0                    <== NOT EXECUTED
4001e88c:	40 00 0e 7f 	call  40022288 <printf>                        <== NOT EXECUTED
4001e890:	90 12 21 20 	or  %o0, 0x120, %o0	! 40035d20 <CSWTCH.1+0x15d0><== NOT EXECUTED
            rc, strerror (rc));                                       
                                                                      
  return rc;                                                          
}                                                                     
4001e894:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4001e898:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40007f0c <rtems_scheduler_ident>: rtems_id *id ) { rtems_status_code sc; if ( id != NULL ) {
40007f0c:	80 a2 60 00 	cmp  %o1, 0                                    
40007f10:	02 80 00 13 	be  40007f5c <rtems_scheduler_ident+0x50>      
40007f14:	82 10 20 09 	mov  9, %g1                                    
    sc = RTEMS_INVALID_NAME;                                          
                                                                      
    for ( i = 0 ; i < n && sc == RTEMS_INVALID_NAME ; ++i ) {         
      const Scheduler_Control *scheduler = &_Scheduler_Table[ i ];    
                                                                      
      if ( scheduler->name == name ) {                                
40007f18:	03 10 00 59 	sethi  %hi(0x40016400), %g1                    
        if ( _Scheduler_Get_processor_count( scheduler ) > 0 ) {      
          *id = _Scheduler_Build_id( i );                             
40007f1c:	09 03 c0 40 	sethi  %hi(0xf010000), %g4                     
    sc = RTEMS_INVALID_NAME;                                          
                                                                      
    for ( i = 0 ; i < n && sc == RTEMS_INVALID_NAME ; ++i ) {         
      const Scheduler_Control *scheduler = &_Scheduler_Table[ i ];    
                                                                      
      if ( scheduler->name == name ) {                                
40007f20:	c6 00 61 b4 	ld  [ %g1 + 0x1b4 ], %g3                       
40007f24:	84 10 20 00 	clr  %g2                                       
40007f28:	82 10 20 03 	mov  3, %g1                                    
        if ( _Scheduler_Get_processor_count( scheduler ) > 0 ) {      
          *id = _Scheduler_Build_id( i );                             
40007f2c:	88 11 20 01 	or  %g4, 1, %g4                                
    size_t n = _Scheduler_Count;                                      
    size_t i;                                                         
                                                                      
    sc = RTEMS_INVALID_NAME;                                          
                                                                      
    for ( i = 0 ; i < n && sc == RTEMS_INVALID_NAME ; ++i ) {         
40007f30:	80 a0 a0 00 	cmp  %g2, 0                                    
40007f34:	12 80 00 0a 	bne  40007f5c <rtems_scheduler_ident+0x50>     
40007f38:	80 a0 60 03 	cmp  %g1, 3                                    
40007f3c:	12 80 00 08 	bne  40007f5c <rtems_scheduler_ident+0x50>     <== NEVER TAKEN
40007f40:	80 a0 c0 08 	cmp  %g3, %o0                                  
      const Scheduler_Control *scheduler = &_Scheduler_Table[ i ];    
                                                                      
      if ( scheduler->name == name ) {                                
40007f44:	12 80 00 04 	bne  40007f54 <rtems_scheduler_ident+0x48>     
40007f48:	82 10 20 03 	mov  3, %g1                                    
        if ( _Scheduler_Get_processor_count( scheduler ) > 0 ) {      
          *id = _Scheduler_Build_id( i );                             
40007f4c:	c8 22 40 00 	st  %g4, [ %o1 ]                               
          sc = RTEMS_SUCCESSFUL;                                      
40007f50:	82 10 20 00 	clr  %g1                                       
    size_t n = _Scheduler_Count;                                      
    size_t i;                                                         
                                                                      
    sc = RTEMS_INVALID_NAME;                                          
                                                                      
    for ( i = 0 ; i < n && sc == RTEMS_INVALID_NAME ; ++i ) {         
40007f54:	10 bf ff f7 	b  40007f30 <rtems_scheduler_ident+0x24>       
40007f58:	84 10 20 01 	mov  1, %g2                                    
  } else {                                                            
    sc = RTEMS_INVALID_ADDRESS;                                       
  }                                                                   
                                                                      
  return sc;                                                          
}                                                                     
40007f5c:	81 c3 e0 08 	retl                                           
40007f60:	90 10 00 01 	mov  %g1, %o0                                  
                                                                      

4000888c <rtems_signal_send>: rtems_status_code rtems_signal_send( rtems_id id, rtems_signal_set signal_set ) {
4000888c:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Thread_Control          *the_thread;                                
  Objects_Locations        location;                                  
  RTEMS_API_Control       *api;                                       
  ASR_Information         *asr;                                       
                                                                      
  if ( !signal_set )                                                  
40008890:	80 a6 60 00 	cmp  %i1, 0                                    
40008894:	02 80 00 41 	be  40008998 <rtems_signal_send+0x10c>         
40008898:	82 10 20 0a 	mov  0xa, %g1                                  
    return RTEMS_INVALID_NUMBER;                                      
                                                                      
  the_thread = _Thread_Get( id, &location );                          
4000889c:	90 10 00 18 	mov  %i0, %o0                                  
400088a0:	40 00 0a 4d 	call  4000b1d4 <_Thread_Get>                   
400088a4:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
400088a8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
400088ac:	80 a0 60 00 	cmp  %g1, 0                                    
400088b0:	12 80 00 39 	bne  40008994 <rtems_signal_send+0x108>        
400088b4:	b8 10 00 08 	mov  %o0, %i4                                  
                                                                      
    case OBJECTS_LOCAL:                                               
      api = the_thread->API_Extensions[ THREAD_API_RTEMS ];           
400088b8:	fa 02 21 2c 	ld  [ %o0 + 0x12c ], %i5                       
      asr = &api->Signal;                                             
                                                                      
      if ( ! _ASR_Is_null_handler( asr->handler ) ) {                 
400088bc:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
400088c0:	80 a0 60 00 	cmp  %g1, 0                                    
400088c4:	02 80 00 30 	be  40008984 <rtems_signal_send+0xf8>          
400088c8:	01 00 00 00 	nop                                            
        if ( asr->is_enabled ) {                                      
400088cc:	c2 0f 60 08 	ldub  [ %i5 + 8 ], %g1                         
400088d0:	80 a0 60 00 	cmp  %g1, 0                                    
400088d4:	02 80 00 21 	be  40008958 <rtems_signal_send+0xcc>          
400088d8:	01 00 00 00 	nop                                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
400088dc:	7f ff ea be 	call  400033d4 <sparc_disable_interrupts>      
400088e0:	01 00 00 00 	nop                                            
)                                                                     
{                                                                     
  ISR_lock_Context lock_context;                                      
                                                                      
  _ISR_lock_ISR_disable_and_acquire( &asr->Lock, &lock_context );     
    *signal_set |= signals;                                           
400088e4:	c2 07 60 14 	ld  [ %i5 + 0x14 ], %g1                        
400088e8:	b2 10 40 19 	or  %g1, %i1, %i1                              
400088ec:	f2 27 60 14 	st  %i1, [ %i5 + 0x14 ]                        
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
400088f0:	7f ff ea bc 	call  400033e0 <sparc_enable_interrupts>       
400088f4:	01 00 00 00 	nop                                            
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
400088f8:	7f ff ea b7 	call  400033d4 <sparc_disable_interrupts>      
400088fc:	01 00 00 00 	nop                                            
RTEMS_INLINE_ROUTINE void _Chain_Append_if_is_off_chain_unprotected(  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  if ( _Chain_Is_node_off_chain( the_node ) ) {                       
40008900:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
40008904:	80 a0 60 00 	cmp  %g1, 0                                    
40008908:	12 80 00 08 	bne  40008928 <rtems_signal_send+0x9c>         
4000890c:	86 07 20 c8 	add  %i4, 0xc8, %g3                            
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
40008910:	c2 07 20 cc 	ld  [ %i4 + 0xcc ], %g1                        
                                                                      
  the_node->next = tail;                                              
40008914:	c6 27 60 20 	st  %g3, [ %i5 + 0x20 ]                        
{                                                                     
  Per_CPU_Control *cpu;                                               
  ISR_Level        level;                                             
                                                                      
  cpu = _Thread_Action_ISR_disable_and_acquire( thread, &level );     
  _Chain_Append_if_is_off_chain_unprotected(                          
40008918:	84 07 60 20 	add  %i5, 0x20, %g2                            
  tail->previous = the_node;                                          
4000891c:	c4 27 20 cc 	st  %g2, [ %i4 + 0xcc ]                        
  old_last->next = the_node;                                          
40008920:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  the_node->previous = old_last;                                      
40008924:	c2 27 60 24 	st  %g1, [ %i5 + 0x24 ]                        
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
40008928:	7f ff ea ae 	call  400033e0 <sparc_enable_interrupts>       
4000892c:	01 00 00 00 	nop                                            
#endif                                                                
}                                                                     
                                                                      
RTEMS_INLINE_ROUTINE void _Thread_Signal_notification( Thread_Control *thread )
{                                                                     
  if ( _ISR_Is_in_progress() && _Thread_Is_executing( thread ) ) {    
40008930:	c4 01 a0 0c 	ld  [ %g6 + 0xc ], %g2                         
40008934:	80 a0 a0 00 	cmp  %g2, 0                                    
40008938:	02 80 00 0f 	be  40008974 <rtems_signal_send+0xe8>          
4000893c:	01 00 00 00 	nop                                            
40008940:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
40008944:	80 a7 00 02 	cmp  %i4, %g2                                  
40008948:	12 80 00 0b 	bne  40008974 <rtems_signal_send+0xe8>         <== NEVER TAKEN
4000894c:	84 10 20 01 	mov  1, %g2                                    
    _Thread_Dispatch_necessary = true;                                
40008950:	c4 29 a0 14 	stb  %g2, [ %g6 + 0x14 ]                       
40008954:	30 80 00 08 	b,a   40008974 <rtems_signal_send+0xe8>        
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
40008958:	7f ff ea 9f 	call  400033d4 <sparc_disable_interrupts>      
4000895c:	01 00 00 00 	nop                                            
40008960:	c2 07 60 18 	ld  [ %i5 + 0x18 ], %g1                        
40008964:	b2 10 40 19 	or  %g1, %i1, %i1                              
40008968:	f2 27 60 18 	st  %i1, [ %i5 + 0x18 ]                        
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
4000896c:	7f ff ea 9d 	call  400033e0 <sparc_enable_interrupts>       
40008970:	01 00 00 00 	nop                                            
40008974:	40 00 0a 0d 	call  4000b1a8 <_Thread_Enable_dispatch>       
40008978:	01 00 00 00 	nop                                            
          _Thread_Signal_notification( the_thread );                  
        } else {                                                      
          _ASR_Post_signals( asr, signal_set, &asr->signals_pending );
        }                                                             
        _Objects_Put( &the_thread->Object );                          
        return RTEMS_SUCCESSFUL;                                      
4000897c:	10 80 00 07 	b  40008998 <rtems_signal_send+0x10c>          
40008980:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
40008984:	40 00 0a 09 	call  4000b1a8 <_Thread_Enable_dispatch>       
40008988:	01 00 00 00 	nop                                            
      }                                                               
      _Objects_Put( &the_thread->Object );                            
      return RTEMS_NOT_DEFINED;                                       
4000898c:	10 80 00 03 	b  40008998 <rtems_signal_send+0x10c>          
40008990:	82 10 20 0b 	mov  0xb, %g1	! b <_TLS_Alignment+0xa>         
                                                                      
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return RTEMS_INVALID_ID;                                            
40008994:	82 10 20 04 	mov  4, %g1                                    
}                                                                     
40008998:	81 c7 e0 08 	ret                                            
4000899c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000ebd8 <rtems_sparse_disk_create_and_register>: const char *device_file_name, uint32_t media_block_size, rtems_blkdev_bnum blocks_with_buffer, rtems_blkdev_bnum media_block_count, uint8_t fill_pattern ) {
4000ebd8:	9d e3 bf 98 	save  %sp, -104, %sp                           
4000ebdc:	92 10 00 1a 	mov  %i2, %o1                                  
4000ebe0:	7f ff ce cc 	call  40002710 <.umul>                         
4000ebe4:	90 06 60 08 	add  %i1, 8, %o0                               
                                * sizeof( rtems_sparse_disk_key );    
  size_t const data_size      = blocks_with_buffer * media_block_size;
  size_t const alloc_size     = sizeof( rtems_sparse_disk )           
                                + key_table_size + data_size;         
                                                                      
  rtems_sparse_disk *const sd = (rtems_sparse_disk *) malloc(         
4000ebe8:	7f ff d9 ad 	call  4000529c <malloc>                        
4000ebec:	90 02 20 1c 	add  %o0, 0x1c, %o0                            
4000ebf0:	92 10 00 08 	mov  %o0, %o1                                  
  rtems_sparse_disk *sparse_disk = sparse_disk_allocate(              
    media_block_size,                                                 
    blocks_with_buffer                                                
  );                                                                  
                                                                      
  if ( sparse_disk != NULL ) {                                        
4000ebf4:	80 a2 60 00 	cmp  %o1, 0                                    
4000ebf8:	02 80 00 0b 	be  4000ec24 <rtems_sparse_disk_create_and_register+0x4c><== NEVER TAKEN
4000ebfc:	90 10 20 1a 	mov  0x1a, %o0                                 
    sc = rtems_sparse_disk_register(                                  
4000ec00:	03 10 00 3a 	sethi  %hi(0x4000e800), %g1                    
4000ec04:	82 10 60 58 	or  %g1, 0x58, %g1	! 4000e858 <rtems_sparse_disk_free>
4000ec08:	90 10 00 18 	mov  %i0, %o0                                  
4000ec0c:	c2 23 a0 5c 	st  %g1, [ %sp + 0x5c ]                        
4000ec10:	94 10 00 19 	mov  %i1, %o2                                  
4000ec14:	96 10 00 1a 	mov  %i2, %o3                                  
4000ec18:	98 10 00 1b 	mov  %i3, %o4                                  
4000ec1c:	7f ff ff b7 	call  4000eaf8 <rtems_sparse_disk_register>    
4000ec20:	9a 10 00 1c 	mov  %i4, %o5                                  
  } else {                                                            
    sc = RTEMS_NO_MEMORY;                                             
  }                                                                   
                                                                      
  return sc;                                                          
}                                                                     
4000ec24:	81 c7 e0 08 	ret                                            
4000ec28:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000eaf8 <rtems_sparse_disk_register>: uint32_t media_block_size, rtems_blkdev_bnum blocks_with_buffer, rtems_blkdev_bnum media_block_count, uint8_t fill_pattern, rtems_sparse_disk_delete_handler sparse_disk_delete ) {
4000eaf8:	9d e3 bf a0 	save  %sp, -96, %sp                            
        sparse_disk_ioctl,                                            
        sparse_disk                                                   
      );                                                              
    }                                                                 
  } else {                                                            
    sc = RTEMS_INVALID_NUMBER;                                        
4000eafc:	90 10 20 0a 	mov  0xa, %o0                                  
  uint32_t                         media_block_size,                  
  rtems_blkdev_bnum                blocks_with_buffer,                
  rtems_blkdev_bnum                media_block_count,                 
  uint8_t                          fill_pattern,                      
  rtems_sparse_disk_delete_handler sparse_disk_delete )               
{                                                                     
4000eb00:	a0 10 00 19 	mov  %i1, %l0                                  
4000eb04:	e4 07 a0 5c 	ld  [ %fp + 0x5c ], %l2                        
  rtems_status_code sc;                                               
                                                                      
  if ( blocks_with_buffer <= media_block_count ) {                    
4000eb08:	80 a6 c0 1c 	cmp  %i3, %i4                                  
4000eb0c:	18 80 00 31 	bgu  4000ebd0 <rtems_sparse_disk_register+0xd8><== NEVER TAKEN
4000eb10:	b2 10 00 1a 	mov  %i2, %i1                                  
  const uint8_t                                                     fill_pattern )
{                                                                     
  rtems_status_code sc;                                               
  rtems_blkdev_bnum i;                                                
                                                                      
  if ( NULL == sd )                                                   
4000eb14:	80 a4 20 00 	cmp  %l0, 0                                    
4000eb18:	02 80 00 2d 	be  4000ebcc <rtems_sparse_disk_register+0xd4> <== NEVER TAKEN
4000eb1c:	92 10 20 00 	clr  %o1                                       
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  uint8_t     *data           = (uint8_t *) sd;                       
  size_t const key_table_size = blocks_with_buffer                    
4000eb20:	b5 2e e0 03 	sll  %i3, 3, %i2                               
                                * sizeof( rtems_sparse_disk_key );    
  size_t const data_size      = blocks_with_buffer * media_block_size;
                                                                      
  memset( data, 0, sizeof( rtems_sparse_disk ) + key_table_size );    
4000eb24:	90 10 00 10 	mov  %l0, %o0                                  
4000eb28:	a2 06 a0 1c 	add  %i2, 0x1c, %l1                            
4000eb2c:	40 00 38 ec 	call  4001cedc <memset>                        
4000eb30:	94 10 00 11 	mov  %l1, %o2                                  
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  uint8_t     *data           = (uint8_t *) sd;                       
  size_t const key_table_size = blocks_with_buffer                    
                                * sizeof( rtems_sparse_disk_key );    
  size_t const data_size      = blocks_with_buffer * media_block_size;
4000eb34:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  memset( data, 0, sizeof( rtems_sparse_disk ) + key_table_size );    
                                                                      
  sd->fill_pattern = fill_pattern;                                    
4000eb38:	fa 2c 20 14 	stb  %i5, [ %l0 + 0x14 ]                       
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  uint8_t     *data           = (uint8_t *) sd;                       
  size_t const key_table_size = blocks_with_buffer                    
                                * sizeof( rtems_sparse_disk_key );    
  size_t const data_size      = blocks_with_buffer * media_block_size;
4000eb3c:	7f ff ce f5 	call  40002710 <.umul>                         
4000eb40:	90 10 00 1b 	mov  %i3, %o0                                  
                                                                      
  memset( data, 0, sizeof( rtems_sparse_disk ) + key_table_size );    
                                                                      
  sd->fill_pattern = fill_pattern;                                    
  memset( (uint8_t *) ( data + sizeof( rtems_sparse_disk ) + key_table_size ),
4000eb44:	92 10 00 1d 	mov  %i5, %o1                                  
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  uint8_t     *data           = (uint8_t *) sd;                       
  size_t const key_table_size = blocks_with_buffer                    
                                * sizeof( rtems_sparse_disk_key );    
  size_t const data_size      = blocks_with_buffer * media_block_size;
4000eb48:	94 10 00 08 	mov  %o0, %o2                                  
                                                                      
  memset( data, 0, sizeof( rtems_sparse_disk ) + key_table_size );    
                                                                      
  sd->fill_pattern = fill_pattern;                                    
  memset( (uint8_t *) ( data + sizeof( rtems_sparse_disk ) + key_table_size ),
4000eb4c:	a2 04 00 11 	add  %l0, %l1, %l1                             
4000eb50:	40 00 38 e3 	call  4001cedc <memset>                        
4000eb54:	90 10 00 11 	mov  %l1, %o0                                  
          sd->fill_pattern,                                           
          data_size );                                                
                                                                      
  sd->delete_handler = sparse_disk_delete;                            
                                                                      
  sc                 = rtems_semaphore_create(                        
4000eb58:	11 14 d4 10 	sethi  %hi(0x53504000), %o0                    
  sd->fill_pattern = fill_pattern;                                    
  memset( (uint8_t *) ( data + sizeof( rtems_sparse_disk ) + key_table_size ),
          sd->fill_pattern,                                           
          data_size );                                                
                                                                      
  sd->delete_handler = sparse_disk_delete;                            
4000eb5c:	e4 24 20 10 	st  %l2, [ %l0 + 0x10 ]                        
                                                                      
  sc                 = rtems_semaphore_create(                        
4000eb60:	90 12 21 52 	or  %o0, 0x152, %o0                            
4000eb64:	92 10 20 01 	mov  1, %o1                                    
4000eb68:	94 10 20 54 	mov  0x54, %o2                                 
4000eb6c:	96 10 20 00 	clr  %o3                                       
4000eb70:	7f ff e8 f8 	call  40008f50 <rtems_semaphore_create>        
4000eb74:	98 10 00 10 	mov  %l0, %o4                                  
    RTEMS_PRIORITY | RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY, 
    0,                                                                
    &sd->mutex                                                        
    );                                                                
                                                                      
  if ( sc != RTEMS_SUCCESSFUL ) {                                     
4000eb78:	80 a2 20 00 	cmp  %o0, 0                                    
4000eb7c:	12 80 00 15 	bne  4000ebd0 <rtems_sparse_disk_register+0xd8><== NEVER TAKEN
4000eb80:	84 04 20 1c 	add  %l0, 0x1c, %g2                            
    return sc;                                                        
  }                                                                   
                                                                      
  data                  += sizeof( rtems_sparse_disk );               
                                                                      
  sd->blocks_with_buffer = blocks_with_buffer;                        
4000eb84:	f6 24 20 04 	st  %i3, [ %l0 + 4 ]                           
  sd->key_table          = (rtems_sparse_disk_key *) data;            
4000eb88:	c4 24 20 18 	st  %g2, [ %l0 + 0x18 ]                        
                                                                      
  data                  += key_table_size;                            
                                                                      
  for ( i = 0; i < blocks_with_buffer; ++i, data += media_block_size ) {
4000eb8c:	82 10 20 00 	clr  %g1                                       
  data                  += sizeof( rtems_sparse_disk );               
                                                                      
  sd->blocks_with_buffer = blocks_with_buffer;                        
  sd->key_table          = (rtems_sparse_disk_key *) data;            
                                                                      
  data                  += key_table_size;                            
4000eb90:	84 00 80 1a 	add  %g2, %i2, %g2                             
                                                                      
  for ( i = 0; i < blocks_with_buffer; ++i, data += media_block_size ) {
4000eb94:	80 a0 40 1b 	cmp  %g1, %i3                                  
4000eb98:	02 80 00 07 	be  4000ebb4 <rtems_sparse_disk_register+0xbc> 
4000eb9c:	87 28 60 03 	sll  %g1, 3, %g3                               
4000eba0:	82 00 60 01 	inc  %g1                                       
4000eba4:	86 04 00 03 	add  %l0, %g3, %g3                             
    sd->key_table[i].data = data;                                     
4000eba8:	c4 20 e0 20 	st  %g2, [ %g3 + 0x20 ]                        
  sd->blocks_with_buffer = blocks_with_buffer;                        
  sd->key_table          = (rtems_sparse_disk_key *) data;            
                                                                      
  data                  += key_table_size;                            
                                                                      
  for ( i = 0; i < blocks_with_buffer; ++i, data += media_block_size ) {
4000ebac:	10 bf ff fa 	b  4000eb94 <rtems_sparse_disk_register+0x9c>  
4000ebb0:	84 00 80 19 	add  %g2, %i1, %g2                             
      sparse_disk_delete,                                             
      fill_pattern                                                    
    );                                                                
                                                                      
    if ( RTEMS_SUCCESSFUL == sc ) {                                   
      sc = rtems_blkdev_create(                                       
4000ebb4:	b4 10 00 1c 	mov  %i4, %i2                                  
4000ebb8:	37 10 00 3a 	sethi  %hi(0x4000e800), %i3                    
                                                                      
  for ( i = 0; i < blocks_with_buffer; ++i, data += media_block_size ) {
    sd->key_table[i].data = data;                                     
  }                                                                   
                                                                      
  sd->media_block_size = media_block_size;                            
4000ebbc:	f2 24 20 0c 	st  %i1, [ %l0 + 0xc ]                         
      sparse_disk_delete,                                             
      fill_pattern                                                    
    );                                                                
                                                                      
    if ( RTEMS_SUCCESSFUL == sc ) {                                   
      sc = rtems_blkdev_create(                                       
4000ebc0:	b6 16 e0 64 	or  %i3, 0x64, %i3                             
4000ebc4:	40 00 0a 20 	call  40011444 <rtems_blkdev_create>           
4000ebc8:	99 e8 00 10 	restore  %g0, %l0, %o4                         
{                                                                     
  rtems_status_code sc;                                               
  rtems_blkdev_bnum i;                                                
                                                                      
  if ( NULL == sd )                                                   
    return RTEMS_INVALID_ADDRESS;                                     
4000ebcc:	90 10 20 09 	mov  9, %o0                                    <== NOT EXECUTED
  } else {                                                            
    sc = RTEMS_INVALID_NUMBER;                                        
  }                                                                   
                                                                      
  return sc;                                                          
}                                                                     
4000ebd0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000ebd4:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
                                                                      

40002cfc <rtems_stack_checker_begin_extension>: * rtems_stack_checker_Begin_extension */ void rtems_stack_checker_begin_extension( Thread_Control *the_thread ) {
40002cfc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  Stack_check_Control  *the_pattern;                                  
                                                                      
  if ( the_thread->Object.id == 0 )        /* skip system tasks */    
40002d00:	c2 06 20 08 	ld  [ %i0 + 8 ], %g1                           
40002d04:	80 a0 60 00 	cmp  %g1, 0                                    
40002d08:	02 80 00 07 	be  40002d24 <rtems_stack_checker_begin_extension+0x28><== NEVER TAKEN
40002d0c:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
    return;                                                           
                                                                      
  the_pattern = Stack_check_Get_pattern_area(&the_thread->Start.Initial_stack);
                                                                      
  *the_pattern = Stack_check_Pattern;                                 
40002d10:	d0 06 20 b8 	ld  [ %i0 + 0xb8 ], %o0                        
40002d14:	90 02 20 08 	add  %o0, 8, %o0                               
40002d18:	92 12 62 a0 	or  %o1, 0x2a0, %o1                            
40002d1c:	40 00 32 9c 	call  4000f78c <memcpy>                        
40002d20:	94 10 20 10 	mov  0x10, %o2                                 
40002d24:	81 c7 e0 08 	ret                                            
40002d28:	81 e8 00 00 	restore                                        
                                                                      

40002c4c <rtems_stack_checker_create_extension>: */ bool rtems_stack_checker_create_extension( Thread_Control *running __attribute__((unused)), Thread_Control *the_thread ) {
40002c4c:	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 )                                      
40002c50:	03 10 00 5d 	sethi  %hi(0x40017400), %g1                    
40002c54:	c4 00 62 70 	ld  [ %g1 + 0x270 ], %g2	! 40017670 <Stack_check_Initialized>
40002c58:	80 a0 a0 00 	cmp  %g2, 0                                    
40002c5c:	12 80 00 1f 	bne  40002cd8 <rtems_stack_checker_create_extension+0x8c>
40002c60:	ba 10 00 01 	mov  %g1, %i5                                  
  /*                                                                  
   * Dope the pattern and fill areas                                  
   */                                                                 
  p = Stack_check_Pattern.pattern;                                    
  for ( i = 0; i < PATTERN_SIZE_WORDS; i++ ) {                        
      p[i] = pattern[ i%4 ];                                          
40002c64:	05 10 00 5e 	sethi  %hi(0x40017800), %g2                    
40002c68:	07 3f bb 7c 	sethi  %hi(0xfeedf000), %g3                    
40002c6c:	82 10 a2 a0 	or  %g2, 0x2a0, %g1                            
40002c70:	86 10 e0 0d 	or  %g3, 0xd, %g3                              
40002c74:	c6 20 a2 a0 	st  %g3, [ %g2 + 0x2a0 ]                       
40002c78:	05 02 eb 43 	sethi  %hi(0xbad0c00), %g2                     
40002c7c:	84 10 a1 06 	or  %g2, 0x106, %g2	! bad0d06 <RAM_SIZE+0xb6d0d06>
  /*                                                                  
   * 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) {      
40002c80:	d0 01 a0 04 	ld  [ %g6 + 4 ], %o0                           
  /*                                                                  
   * Dope the pattern and fill areas                                  
   */                                                                 
  p = Stack_check_Pattern.pattern;                                    
  for ( i = 0; i < PATTERN_SIZE_WORDS; i++ ) {                        
      p[i] = pattern[ i%4 ];                                          
40002c84:	c4 20 60 04 	st  %g2, [ %g1 + 4 ]                           
40002c88:	05 37 ab 7c 	sethi  %hi(0xdeadf000), %g2                    
40002c8c:	84 10 a0 0d 	or  %g2, 0xd, %g2	! deadf00d <RAM_END+0x9e6df00d>
40002c90:	c4 20 60 08 	st  %g2, [ %g1 + 8 ]                           
40002c94:	05 18 03 43 	sethi  %hi(0x600d0c00), %g2                    
40002c98:	84 10 a1 06 	or  %g2, 0x106, %g2	! 600d0d06 <RAM_END+0x1fcd0d06>
  /*                                                                  
   * 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) {      
40002c9c:	80 a2 20 00 	cmp  %o0, 0                                    
40002ca0:	02 80 00 0c 	be  40002cd0 <rtems_stack_checker_create_extension+0x84><== NEVER TAKEN
40002ca4:	c4 20 60 0c 	st  %g2, [ %g1 + 0xc ]                         
40002ca8:	d4 01 a0 08 	ld  [ %g6 + 8 ], %o2                           
40002cac:	80 a2 a0 00 	cmp  %o2, 0                                    
40002cb0:	02 80 00 08 	be  40002cd0 <rtems_stack_checker_create_extension+0x84><== NEVER TAKEN
40002cb4:	03 10 00 5e 	sethi  %hi(0x40017800), %g1                    
      Stack_check_Interrupt_stack.area = _CPU_Interrupt_stack_low;    
40002cb8:	84 10 62 b0 	or  %g1, 0x2b0, %g2	! 40017ab0 <Stack_check_Interrupt_stack>
      Stack_check_Interrupt_stack.size = (char *) _CPU_Interrupt_stack_high -
40002cbc:	94 22 80 08 	sub  %o2, %o0, %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;    
40002cc0:	d0 20 a0 04 	st  %o0, [ %g2 + 4 ]                           
      Stack_check_Interrupt_stack.size = (char *) _CPU_Interrupt_stack_high -
40002cc4:	d4 20 62 b0 	st  %o2, [ %g1 + 0x2b0 ]                       
                                  (char *) _CPU_Interrupt_stack_low;  
      Stack_check_Dope_stack(&Stack_check_Interrupt_stack);           
40002cc8:	40 00 32 f0 	call  4000f888 <memset>                        
40002ccc:	92 10 20 a5 	mov  0xa5, %o1                                 
   }                                                                  
  #endif                                                              
                                                                      
  Stack_check_Initialized = 1;                                        
40002cd0:	82 10 20 01 	mov  1, %g1                                    
40002cd4:	c2 27 62 70 	st  %g1, [ %i5 + 0x270 ]                       
  Thread_Control *the_thread                                          
)                                                                     
{                                                                     
  Stack_check_Initialize();                                           
                                                                      
  if (the_thread)                                                     
40002cd8:	80 a6 60 00 	cmp  %i1, 0                                    
40002cdc:	02 80 00 06 	be  40002cf4 <rtems_stack_checker_create_extension+0xa8><== NEVER TAKEN
40002ce0:	01 00 00 00 	nop                                            
    Stack_check_Dope_stack(&the_thread->Start.Initial_stack);         
40002ce4:	d0 06 60 b8 	ld  [ %i1 + 0xb8 ], %o0                        
40002ce8:	d4 06 60 b4 	ld  [ %i1 + 0xb4 ], %o2                        
40002cec:	40 00 32 e7 	call  4000f888 <memset>                        
40002cf0:	92 10 20 a5 	mov  0xa5, %o1                                 
                                                                      
  return true;                                                        
}                                                                     
40002cf4:	81 c7 e0 08 	ret                                            
40002cf8:	91 e8 20 01 	restore  %g0, 1, %o0                           
                                                                      

40002e40 <rtems_stack_checker_is_blown>: /* * Check if blown */ bool rtems_stack_checker_is_blown( void ) {
40002e40:	9d e3 bf a0 	save  %sp, -96, %sp                            
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable_without_giant( level );                              
  #endif                                                              
                                                                      
  executing = _Thread_Executing;                                      
40002e44:	fa 01 a0 18 	ld  [ %g6 + 0x18 ], %i5                        
)                                                                     
{                                                                     
  #if defined(__GNUC__)                                               
    void *sp = __builtin_frame_address(0);                            
                                                                      
    if ( sp < the_stack->area ) {                                     
40002e48:	d0 07 60 b8 	ld  [ %i5 + 0xb8 ], %o0                        
40002e4c:	80 a7 80 08 	cmp  %fp, %o0                                  
40002e50:	0a 80 00 06 	bcs  40002e68 <rtems_stack_checker_is_blown+0x28><== NEVER TAKEN
40002e54:	b8 10 20 00 	clr  %i4                                       
      return false;                                                   
    }                                                                 
    if ( sp > (the_stack->area + the_stack->size) ) {                 
40002e58:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40002e5c:	82 02 00 01 	add  %o0, %g1, %g1                             
40002e60:	80 a0 40 1e 	cmp  %g1, %fp                                  
40002e64:	b8 60 3f ff 	subx  %g0, -1, %i4                             
                                                                      
  /*                                                                  
   * The stack checker must be initialized before the pattern is there
   * to check.                                                        
   */                                                                 
  if ( Stack_check_Initialized ) {                                    
40002e68:	03 10 00 5d 	sethi  %hi(0x40017400), %g1                    
40002e6c:	c2 00 62 70 	ld  [ %g1 + 0x270 ], %g1	! 40017670 <Stack_check_Initialized>
40002e70:	80 a0 60 00 	cmp  %g1, 0                                    
40002e74:	02 80 00 09 	be  40002e98 <rtems_stack_checker_is_blown+0x58><== NEVER TAKEN
40002e78:	92 10 20 01 	mov  1, %o1                                    
    pattern_ok = (!memcmp(                                            
40002e7c:	90 02 20 08 	add  %o0, 8, %o0                               
40002e80:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
40002e84:	94 10 20 10 	mov  0x10, %o2                                 
40002e88:	40 00 32 17 	call  4000f6e4 <memcmp>                        
40002e8c:	92 12 62 a0 	or  %o1, 0x2a0, %o1                            
40002e90:	80 a0 00 08 	cmp  %g0, %o0                                  
40002e94:	92 60 3f ff 	subx  %g0, -1, %o1                             
                                                                      
                                                                      
  /*                                                                  
   * Let's report as much as we can.                                  
   */                                                                 
  if ( !sp_ok || !pattern_ok ) {                                      
40002e98:	80 8a 60 ff 	btst  0xff, %o1                                
40002e9c:	02 80 00 04 	be  40002eac <rtems_stack_checker_is_blown+0x6c><== NEVER TAKEN
40002ea0:	80 8f 20 ff 	btst  0xff, %i4                                
40002ea4:	12 80 00 05 	bne  40002eb8 <rtems_stack_checker_is_blown+0x78><== ALWAYS TAKEN
40002ea8:	01 00 00 00 	nop                                            
    Stack_check_report_blown_task( executing, pattern_ok );           
40002eac:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40002eb0:	7f ff ff 9f 	call  40002d2c <Stack_check_report_blown_task> <== NOT EXECUTED
40002eb4:	92 0a 60 01 	and  %o1, 1, %o1                               <== NOT EXECUTED
                                                                      
  /*                                                                  
   * The Stack Pointer and the Pattern Area are OK so return false.   
   */                                                                 
  return false;                                                       
}                                                                     
40002eb8:	81 c7 e0 08 	ret                                            
40002ebc:	91 e8 20 00 	restore  %g0, 0, %o0                           
                                                                      

40003ca8 <rtems_stack_checker_report_usage>: } void rtems_stack_checker_report_usage( void ) { rtems_stack_checker_report_usage_with_plugin( NULL, printk_plugin );
40003ca8:	13 10 00 14 	sethi  %hi(0x40005000), %o1                    <== NOT EXECUTED
40003cac:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
40003cb0:	92 12 60 08 	or  %o1, 8, %o1                                <== NOT EXECUTED
40003cb4:	82 13 c0 00 	mov  %o7, %g1                                  <== NOT EXECUTED
40003cb8:	7f ff ff e4 	call  40003c48 <rtems_stack_checker_report_usage_with_plugin><== NOT EXECUTED
40003cbc:	9e 10 40 00 	mov  %g1, %o7                                  <== NOT EXECUTED
                                                                      

40003c48 <rtems_stack_checker_report_usage_with_plugin>: void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) {
40003c48:	9d e3 bf a0 	save  %sp, -96, %sp                            <== NOT EXECUTED
  if ( !print )                                                       
40003c4c:	80 a6 60 00 	cmp  %i1, 0                                    <== NOT EXECUTED
40003c50:	02 80 00 14 	be  40003ca0 <rtems_stack_checker_report_usage_with_plugin+0x58><== NOT EXECUTED
40003c54:	39 10 00 65 	sethi  %hi(0x40019400), %i4                    <== NOT EXECUTED
    return;                                                           
                                                                      
  print_context = context;                                            
  print_handler = print;                                              
40003c58:	3b 10 00 65 	sethi  %hi(0x40019400), %i5                    <== NOT EXECUTED
)                                                                     
{                                                                     
  if ( !print )                                                       
    return;                                                           
                                                                      
  print_context = context;                                            
40003c5c:	f0 27 21 54 	st  %i0, [ %i4 + 0x154 ]                       <== NOT EXECUTED
  print_handler = print;                                              
40003c60:	f2 27 61 50 	st  %i1, [ %i5 + 0x150 ]                       <== NOT EXECUTED
                                                                      
  (*print)( context, "Stack usage by thread\n");                      
40003c64:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40003c68:	13 10 00 5c 	sethi  %hi(0x40017000), %o1                    <== NOT EXECUTED
40003c6c:	9f c6 40 00 	call  %i1                                      <== NOT EXECUTED
40003c70:	92 12 60 28 	or  %o1, 0x28, %o1	! 40017028 <__FUNCTION__.6501+0x260><== NOT EXECUTED
  (*print)( context,                                                  
40003c74:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40003c78:	13 10 00 5c 	sethi  %hi(0x40017000), %o1                    <== NOT EXECUTED
40003c7c:	9f c6 40 00 	call  %i1                                      <== NOT EXECUTED
40003c80:	92 12 60 40 	or  %o1, 0x40, %o1	! 40017040 <__FUNCTION__.6501+0x278><== 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 );   
40003c84:	11 10 00 0e 	sethi  %hi(0x40003800), %o0                    <== NOT EXECUTED
40003c88:	40 00 18 0e 	call  40009cc0 <rtems_iterate_over_all_threads><== NOT EXECUTED
40003c8c:	90 12 20 ec 	or  %o0, 0xec, %o0	! 400038ec <Stack_check_Dump_threads_usage><== NOT EXECUTED
                                                                      
  #if (CPU_ALLOCATE_INTERRUPT_STACK == TRUE)                          
    /* dump interrupt stack info if any */                            
    Stack_check_Dump_threads_usage((Thread_Control *) -1);            
40003c90:	7f ff ff 17 	call  400038ec <Stack_check_Dump_threads_usage><== NOT EXECUTED
40003c94:	90 10 3f ff 	mov  -1, %o0                                   <== NOT EXECUTED
  #endif                                                              
                                                                      
  print_context = NULL;                                               
40003c98:	c0 27 21 54 	clr  [ %i4 + 0x154 ]                           <== NOT EXECUTED
  print_handler = NULL;                                               
40003c9c:	c0 27 61 50 	clr  [ %i5 + 0x150 ]                           <== NOT EXECUTED
40003ca0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40003ca4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40002ddc <rtems_stack_checker_switch_extension>: */ void rtems_stack_checker_switch_extension( Thread_Control *running __attribute__((unused)), Thread_Control *heir __attribute__((unused)) ) {
40002ddc:	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 = Stack_check_Get_pattern_area(the_stack);                  
40002de0:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        
{                                                                     
  #if defined(__GNUC__)                                               
    void *sp = __builtin_frame_address(0);                            
                                                                      
    if ( sp < the_stack->area ) {                                     
      return false;                                                   
40002de4:	ba 10 20 00 	clr  %i5                                       
)                                                                     
{                                                                     
  #if defined(__GNUC__)                                               
    void *sp = __builtin_frame_address(0);                            
                                                                      
    if ( sp < the_stack->area ) {                                     
40002de8:	80 a7 80 01 	cmp  %fp, %g1                                  
40002dec:	0a 80 00 06 	bcs  40002e04 <rtems_stack_checker_switch_extension+0x28><== NEVER TAKEN
40002df0:	90 00 60 08 	add  %g1, 8, %o0                               
      return false;                                                   
    }                                                                 
    if ( sp > (the_stack->area + the_stack->size) ) {                 
40002df4:	c4 06 20 b4 	ld  [ %i0 + 0xb4 ], %g2                        
40002df8:	82 00 40 02 	add  %g1, %g2, %g1                             
40002dfc:	80 a0 40 1e 	cmp  %g1, %fp                                  
40002e00:	ba 60 3f ff 	subx  %g0, -1, %i5                             
  /*                                                                  
   *  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,                                     
40002e04:	13 10 00 5e 	sethi  %hi(0x40017800), %o1                    
40002e08:	94 10 20 10 	mov  0x10, %o2                                 
40002e0c:	40 00 32 36 	call  4000f6e4 <memcmp>                        
40002e10:	92 12 62 a0 	or  %o1, 0x2a0, %o1                            
40002e14:	80 a0 00 08 	cmp  %g0, %o0                                  
40002e18:	92 60 3f ff 	subx  %g0, -1, %o1                             
            (void *) Stack_check_Pattern.pattern, PATTERN_SIZE_BYTES));
                                                                      
  if ( !sp_ok || !pattern_ok ) {                                      
40002e1c:	80 a2 60 00 	cmp  %o1, 0                                    
40002e20:	02 80 00 04 	be  40002e30 <rtems_stack_checker_switch_extension+0x54><== NEVER TAKEN
40002e24:	80 8f 60 ff 	btst  0xff, %i5                                
40002e28:	12 80 00 04 	bne  40002e38 <rtems_stack_checker_switch_extension+0x5c><== ALWAYS TAKEN
40002e2c:	01 00 00 00 	nop                                            
    Stack_check_report_blown_task( running, pattern_ok );             
40002e30:	7f ff ff bf 	call  40002d2c <Stack_check_report_blown_task> <== NOT EXECUTED
40002e34:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
40002e38:	81 c7 e0 08 	ret                                            
40002e3c:	81 e8 00 00 	restore                                        
                                                                      

4000d0c4 <rtems_status_code_to_errno>: [RTEMS_IO_ERROR] = EIO, [RTEMS_PROXY_BLOCKING] = EIO }; int rtems_status_code_to_errno(rtems_status_code sc) {
4000d0c4:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if (sc == RTEMS_SUCCESSFUL) {                                       
4000d0c8:	80 a6 20 00 	cmp  %i0, 0                                    
4000d0cc:	02 80 00 0d 	be  4000d100 <rtems_status_code_to_errno+0x3c> 
4000d0d0:	82 10 20 00 	clr  %g1                                       
    return 0;                                                         
  } else {                                                            
    int eno = EINVAL;                                                 
                                                                      
    if ((unsigned) sc <= RTEMS_STATUS_CODES_LAST) {                   
4000d0d4:	80 a6 20 1c 	cmp  %i0, 0x1c                                 
4000d0d8:	18 80 00 06 	bgu  4000d0f0 <rtems_status_code_to_errno+0x2c><== NEVER TAKEN
4000d0dc:	ba 10 20 16 	mov  0x16, %i5                                 
      eno = status_code_to_errno [sc];                                
4000d0e0:	b1 2e 20 02 	sll  %i0, 2, %i0                               
4000d0e4:	03 10 00 59 	sethi  %hi(0x40016400), %g1                    
4000d0e8:	82 10 60 bc 	or  %g1, 0xbc, %g1	! 400164bc <status_code_to_errno>
4000d0ec:	fa 00 40 18 	ld  [ %g1 + %i0 ], %i5                         
    }                                                                 
                                                                      
    errno = eno;                                                      
4000d0f0:	40 00 0a 4c 	call  4000fa20 <__errno>                       
4000d0f4:	01 00 00 00 	nop                                            
                                                                      
    return -1;                                                        
4000d0f8:	82 10 3f ff 	mov  -1, %g1	! ffffffff <RAM_END+0xbfbfffff>   
                                                                      
    if ((unsigned) sc <= RTEMS_STATUS_CODES_LAST) {                   
      eno = status_code_to_errno [sc];                                
    }                                                                 
                                                                      
    errno = eno;                                                      
4000d0fc:	fa 22 00 00 	st  %i5, [ %o0 ]                               
                                                                      
    return -1;                                                        
  }                                                                   
}                                                                     
4000d100:	81 c7 e0 08 	ret                                            
4000d104:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e048 <rtems_string_to_double>: rtems_status_code rtems_string_to_double ( const char *s, double *n, char **endptr ) {
4000e048:	9d e3 bf 98 	save  %sp, -104, %sp                           
  double result;                                                      
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e04c:	80 a6 60 00 	cmp  %i1, 0                                    
4000e050:	02 80 00 34 	be  4000e120 <rtems_string_to_double+0xd8>     
4000e054:	b6 10 20 09 	mov  9, %i3                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e058:	40 00 0c 62 	call  400111e0 <__errno>                       
4000e05c:	01 00 00 00 	nop                                            
4000e060:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e064:	c0 26 40 00 	clr  [ %i1 ]                                   
4000e068:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
                                                                      
  result = strtod( s, &end );                                         
4000e06c:	90 10 00 18 	mov  %i0, %o0                                  
4000e070:	40 00 13 d9 	call  40012fd4 <strtod>                        
4000e074:	92 07 bf fc 	add  %fp, -4, %o1                              
                                                                      
  if ( endptr )                                                       
4000e078:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtod( s, &end );                                         
4000e07c:	b8 10 00 08 	mov  %o0, %i4                                  
4000e080:	ba 10 00 09 	mov  %o1, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e084:	02 80 00 03 	be  4000e090 <rtems_string_to_double+0x48>     
4000e088:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
    *endptr = end;                                                    
4000e08c:	c2 26 80 00 	st  %g1, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e090:	80 a0 40 18 	cmp  %g1, %i0                                  
4000e094:	02 80 00 23 	be  4000e120 <rtems_string_to_double+0xd8>     
4000e098:	b6 10 20 0b 	mov  0xb, %i3                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e09c:	40 00 0c 51 	call  400111e0 <__errno>                       
4000e0a0:	01 00 00 00 	nop                                            
4000e0a4:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e0a8:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e0ac:	32 80 00 1c 	bne,a   4000e11c <rtems_string_to_double+0xd4> 
4000e0b0:	f8 3e 40 00 	std  %i4, [ %i1 ]                              
4000e0b4:	90 10 00 1c 	mov  %i4, %o0                                  
4000e0b8:	92 10 00 1d 	mov  %i5, %o1                                  
4000e0bc:	94 10 20 00 	clr  %o2                                       
4000e0c0:	96 10 20 00 	clr  %o3                                       
4000e0c4:	40 00 30 22 	call  4001a14c <__eqdf2>                       
4000e0c8:	b6 10 20 0a 	mov  0xa, %i3                                  
4000e0cc:	80 a2 20 00 	cmp  %o0, 0                                    
4000e0d0:	02 80 00 14 	be  4000e120 <rtems_string_to_double+0xd8>     <== NEVER TAKEN
4000e0d4:	90 10 00 1c 	mov  %i4, %o0                                  
    (( result == 0 ) || ( result == HUGE_VAL ) || ( result == -HUGE_VAL )))
4000e0d8:	92 10 00 1d 	mov  %i5, %o1                                  
4000e0dc:	15 1f fb ff 	sethi  %hi(0x7feffc00), %o2                    
4000e0e0:	96 10 3f ff 	mov  -1, %o3                                   
4000e0e4:	40 00 30 30 	call  4001a1a4 <__gtdf2>                       
4000e0e8:	94 12 a3 ff 	or  %o2, 0x3ff, %o2                            
4000e0ec:	80 a2 20 00 	cmp  %o0, 0                                    
4000e0f0:	14 80 00 0c 	bg  4000e120 <rtems_string_to_double+0xd8>     
4000e0f4:	90 10 00 1c 	mov  %i4, %o0                                  
4000e0f8:	92 10 00 1d 	mov  %i5, %o1                                  
4000e0fc:	15 3f fb ff 	sethi  %hi(0xffeffc00), %o2                    
4000e100:	96 10 3f ff 	mov  -1, %o3                                   
4000e104:	40 00 30 54 	call  4001a254 <__ltdf2>                       
4000e108:	94 12 a3 ff 	or  %o2, 0x3ff, %o2                            
4000e10c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e110:	06 80 00 04 	bl  4000e120 <rtems_string_to_double+0xd8>     <== ALWAYS TAKEN
4000e114:	01 00 00 00 	nop                                            
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
  *n = result;                                                        
4000e118:	f8 3e 40 00 	std  %i4, [ %i1 ]                              <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e11c:	b6 10 20 00 	clr  %i3                                       
}                                                                     
4000e120:	81 c7 e0 08 	ret                                            
4000e124:	91 e8 00 1b 	restore  %g0, %i3, %o0                         
                                                                      

4000e128 <rtems_string_to_float>: rtems_status_code rtems_string_to_float ( const char *s, float *n, char **endptr ) {
4000e128:	9d e3 bf 98 	save  %sp, -104, %sp                           
  float result;                                                       
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e12c:	80 a6 60 00 	cmp  %i1, 0                                    
4000e130:	02 80 00 2c 	be  4000e1e0 <rtems_string_to_float+0xb8>      
4000e134:	b8 10 20 09 	mov  9, %i4                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e138:	40 00 0c 2a 	call  400111e0 <__errno>                       
4000e13c:	01 00 00 00 	nop                                            
4000e140:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e144:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
  result = strtof( s, &end );                                         
4000e148:	90 10 00 18 	mov  %i0, %o0                                  
4000e14c:	40 00 13 a9 	call  40012ff0 <strtof>                        
4000e150:	92 07 bf fc 	add  %fp, -4, %o1                              
                                                                      
  if ( endptr )                                                       
4000e154:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtof( s, &end );                                         
4000e158:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e15c:	02 80 00 03 	be  4000e168 <rtems_string_to_float+0x40>      
4000e160:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
    *endptr = end;                                                    
4000e164:	c2 26 80 00 	st  %g1, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e168:	80 a0 40 18 	cmp  %g1, %i0                                  
4000e16c:	02 80 00 1d 	be  4000e1e0 <rtems_string_to_float+0xb8>      
4000e170:	b8 10 20 0b 	mov  0xb, %i4                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e174:	40 00 0c 1b 	call  400111e0 <__errno>                       
4000e178:	01 00 00 00 	nop                                            
4000e17c:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e180:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e184:	32 80 00 16 	bne,a   4000e1dc <rtems_string_to_float+0xb4>  
4000e188:	fa 26 40 00 	st  %i5, [ %i1 ]                               
4000e18c:	90 10 00 1d 	mov  %i5, %o0                                  
4000e190:	92 10 20 00 	clr  %o1                                       
4000e194:	40 00 2d 57 	call  400196f0 <__eqsf2>                       
4000e198:	b8 10 20 0a 	mov  0xa, %i4                                  
4000e19c:	80 a2 20 00 	cmp  %o0, 0                                    
4000e1a0:	02 80 00 10 	be  4000e1e0 <rtems_string_to_float+0xb8>      <== NEVER TAKEN
4000e1a4:	90 10 00 1d 	mov  %i5, %o0                                  
    (( result == 0 ) || ( result == HUGE_VALF ) || ( result == -HUGE_VALF )))
4000e1a8:	13 1f df ff 	sethi  %hi(0x7f7ffc00), %o1                    
4000e1ac:	40 00 2d 66 	call  40019744 <__gtsf2>                       
4000e1b0:	92 12 63 ff 	or  %o1, 0x3ff, %o1	! 7f7fffff <RAM_END+0x3f3fffff>
4000e1b4:	80 a2 20 00 	cmp  %o0, 0                                    
4000e1b8:	14 80 00 0a 	bg  4000e1e0 <rtems_string_to_float+0xb8>      
4000e1bc:	90 10 00 1d 	mov  %i5, %o0                                  
4000e1c0:	13 3f df ff 	sethi  %hi(0xff7ffc00), %o1                    
4000e1c4:	40 00 2d 75 	call  40019798 <__ltsf2>                       
4000e1c8:	92 12 63 ff 	or  %o1, 0x3ff, %o1	! ff7fffff <RAM_END+0xbf3fffff>
4000e1cc:	80 a2 20 00 	cmp  %o0, 0                                    
4000e1d0:	06 80 00 04 	bl  4000e1e0 <rtems_string_to_float+0xb8>      <== ALWAYS TAKEN
4000e1d4:	01 00 00 00 	nop                                            
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
  *n = result;                                                        
4000e1d8:	fa 26 40 00 	st  %i5, [ %i1 ]                               <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e1dc:	b8 10 20 00 	clr  %i4                                       
}                                                                     
4000e1e0:	81 c7 e0 08 	ret                                            
4000e1e4:	91 e8 00 1c 	restore  %g0, %i4, %o0                         
                                                                      

4000e1e8 <rtems_string_to_int>: const char *s, int *n, char **endptr, int base ) {
4000e1e8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  long result;                                                        
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e1ec:	80 a6 60 00 	cmp  %i1, 0                                    
4000e1f0:	02 80 00 22 	be  4000e278 <rtems_string_to_int+0x90>        
4000e1f4:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e1f8:	40 00 0b fa 	call  400111e0 <__errno>                       
4000e1fc:	01 00 00 00 	nop                                            
4000e200:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e204:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
  result = strtol( s, &end, base );                                   
4000e208:	90 10 00 18 	mov  %i0, %o0                                  
4000e20c:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e210:	40 00 14 33 	call  400132dc <strtol>                        
4000e214:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e218:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtol( s, &end, base );                                   
4000e21c:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e220:	02 80 00 03 	be  4000e22c <rtems_string_to_int+0x44>        
4000e224:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e228:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e22c:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e230:	02 80 00 12 	be  4000e278 <rtems_string_to_int+0x90>        
4000e234:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e238:	40 00 0b ea 	call  400111e0 <__errno>                       
4000e23c:	01 00 00 00 	nop                                            
4000e240:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e244:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e248:	32 80 00 0b 	bne,a   4000e274 <rtems_string_to_int+0x8c>    
4000e24c:	fa 26 40 00 	st  %i5, [ %i1 ]                               
4000e250:	05 1f ff ff 	sethi  %hi(0x7ffffc00), %g2                    
4000e254:	84 10 a3 ff 	or  %g2, 0x3ff, %g2	! 7fffffff <RAM_END+0x3fbfffff>
4000e258:	80 a7 40 02 	cmp  %i5, %g2                                  
4000e25c:	02 80 00 07 	be  4000e278 <rtems_string_to_int+0x90>        
4000e260:	82 10 20 0a 	mov  0xa, %g1                                  
    (( result == 0 ) || ( result == LONG_MAX ) || ( result == LONG_MIN )))
4000e264:	80 8f 40 02 	btst  %i5, %g2                                 
4000e268:	02 80 00 04 	be  4000e278 <rtems_string_to_int+0x90>        <== ALWAYS TAKEN
4000e26c:	01 00 00 00 	nop                                            
    errno = ERANGE;                                                   
    return RTEMS_INVALID_NUMBER;                                      
  }                                                                   
#endif                                                                
                                                                      
  *n = result;                                                        
4000e270:	fa 26 40 00 	st  %i5, [ %i1 ]                               <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e274:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e278:	81 c7 e0 08 	ret                                            
4000e27c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e340 <rtems_string_to_long>: const char *s, long *n, char **endptr, int base ) {
4000e340:	9d e3 bf 98 	save  %sp, -104, %sp                           
  long result;                                                        
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e344:	80 a6 60 00 	cmp  %i1, 0                                    
4000e348:	02 80 00 22 	be  4000e3d0 <rtems_string_to_long+0x90>       
4000e34c:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e350:	40 00 0b a4 	call  400111e0 <__errno>                       
4000e354:	01 00 00 00 	nop                                            
4000e358:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e35c:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
  result = strtol( s, &end, base );                                   
4000e360:	90 10 00 18 	mov  %i0, %o0                                  
4000e364:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e368:	40 00 13 dd 	call  400132dc <strtol>                        
4000e36c:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e370:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtol( s, &end, base );                                   
4000e374:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e378:	02 80 00 03 	be  4000e384 <rtems_string_to_long+0x44>       
4000e37c:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e380:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e384:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e388:	02 80 00 12 	be  4000e3d0 <rtems_string_to_long+0x90>       
4000e38c:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e390:	40 00 0b 94 	call  400111e0 <__errno>                       
4000e394:	01 00 00 00 	nop                                            
4000e398:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e39c:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e3a0:	32 80 00 0b 	bne,a   4000e3cc <rtems_string_to_long+0x8c>   
4000e3a4:	fa 26 40 00 	st  %i5, [ %i1 ]                               
4000e3a8:	05 1f ff ff 	sethi  %hi(0x7ffffc00), %g2                    
4000e3ac:	84 10 a3 ff 	or  %g2, 0x3ff, %g2	! 7fffffff <RAM_END+0x3fbfffff>
4000e3b0:	80 a7 40 02 	cmp  %i5, %g2                                  
4000e3b4:	02 80 00 07 	be  4000e3d0 <rtems_string_to_long+0x90>       
4000e3b8:	82 10 20 0a 	mov  0xa, %g1                                  
    (( result == 0 ) || ( result == LONG_MAX ) || ( result == LONG_MIN )))
4000e3bc:	80 8f 40 02 	btst  %i5, %g2                                 
4000e3c0:	02 80 00 04 	be  4000e3d0 <rtems_string_to_long+0x90>       <== ALWAYS TAKEN
4000e3c4:	01 00 00 00 	nop                                            
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
  *n = result;                                                        
4000e3c8:	fa 26 40 00 	st  %i5, [ %i1 ]                               <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e3cc:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e3d0:	81 c7 e0 08 	ret                                            
4000e3d4:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e280 <rtems_string_to_long_long>: const char *s, long long *n, char **endptr, int base ) {
4000e280:	9d e3 bf 98 	save  %sp, -104, %sp                           
  long long result;                                                   
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e284:	80 a6 60 00 	cmp  %i1, 0                                    
4000e288:	02 80 00 2c 	be  4000e338 <rtems_string_to_long_long+0xb8>  
4000e28c:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e290:	40 00 0b d4 	call  400111e0 <__errno>                       
4000e294:	01 00 00 00 	nop                                            
4000e298:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e29c:	c0 26 40 00 	clr  [ %i1 ]                                   
4000e2a0:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
                                                                      
  result = strtoll( s, &end, base );                                  
4000e2a4:	90 10 00 18 	mov  %i0, %o0                                  
4000e2a8:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e2ac:	40 00 14 15 	call  40013300 <strtoll>                       
4000e2b0:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e2b4:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtoll( s, &end, base );                                  
4000e2b8:	b8 10 00 08 	mov  %o0, %i4                                  
4000e2bc:	ba 10 00 09 	mov  %o1, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e2c0:	02 80 00 03 	be  4000e2cc <rtems_string_to_long_long+0x4c>  
4000e2c4:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e2c8:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e2cc:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e2d0:	02 80 00 1a 	be  4000e338 <rtems_string_to_long_long+0xb8>  
4000e2d4:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e2d8:	40 00 0b c2 	call  400111e0 <__errno>                       
4000e2dc:	01 00 00 00 	nop                                            
4000e2e0:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e2e4:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e2e8:	32 80 00 13 	bne,a   4000e334 <rtems_string_to_long_long+0xb4>
4000e2ec:	f8 3e 40 00 	std  %i4, [ %i1 ]                              
4000e2f0:	03 1f ff ff 	sethi  %hi(0x7ffffc00), %g1                    
4000e2f4:	82 10 63 ff 	or  %g1, 0x3ff, %g1	! 7fffffff <RAM_END+0x3fbfffff>
4000e2f8:	80 a7 00 01 	cmp  %i4, %g1                                  
4000e2fc:	12 80 00 04 	bne  4000e30c <rtems_string_to_long_long+0x8c> 
4000e300:	80 a7 7f ff 	cmp  %i5, -1                                   
4000e304:	02 80 00 0d 	be  4000e338 <rtems_string_to_long_long+0xb8>  <== ALWAYS TAKEN
4000e308:	82 10 20 0a 	mov  0xa, %g1                                  
    (( result == 0 ) || ( result == LONG_LONG_MAX ) || ( result == LONG_LONG_MIN )))
4000e30c:	05 1f ff ff 	sethi  %hi(0x7ffffc00), %g2                    
4000e310:	07 3f ff ff 	sethi  %hi(0xfffffc00), %g3                    
4000e314:	84 10 a3 ff 	or  %g2, 0x3ff, %g2                            
4000e318:	86 10 e3 ff 	or  %g3, 0x3ff, %g3                            
4000e31c:	84 0f 00 02 	and  %i4, %g2, %g2                             
4000e320:	86 0f 40 03 	and  %i5, %g3, %g3                             
4000e324:	80 90 80 03 	orcc  %g2, %g3, %g0                            
4000e328:	02 80 00 04 	be  4000e338 <rtems_string_to_long_long+0xb8>  <== ALWAYS TAKEN
4000e32c:	82 10 20 0a 	mov  0xa, %g1                                  
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
  *n = result;                                                        
4000e330:	f8 3e 40 00 	std  %i4, [ %i1 ]                              <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e334:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e338:	81 c7 e0 08 	ret                                            
4000e33c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e3e8 <rtems_string_to_unsigned_char>: const char *s, unsigned char *n, char **endptr, int base ) {
4000e3e8:	9d e3 bf 98 	save  %sp, -104, %sp                           
  unsigned long result;                                               
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e3ec:	80 a6 60 00 	cmp  %i1, 0                                    
4000e3f0:	02 80 00 26 	be  4000e488 <rtems_string_to_unsigned_char+0xa0>
4000e3f4:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e3f8:	40 00 0b 7a 	call  400111e0 <__errno>                       
4000e3fc:	01 00 00 00 	nop                                            
4000e400:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e404:	c0 2e 40 00 	clrb  [ %i1 ]                                  
                                                                      
  result = strtoul( s, &end, base );                                  
4000e408:	90 10 00 18 	mov  %i0, %o0                                  
4000e40c:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e410:	40 00 15 09 	call  40013834 <strtoul>                       
4000e414:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e418:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtoul( s, &end, base );                                  
4000e41c:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e420:	02 80 00 03 	be  4000e42c <rtems_string_to_unsigned_char+0x44>
4000e424:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e428:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e42c:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e430:	02 80 00 16 	be  4000e488 <rtems_string_to_unsigned_char+0xa0>
4000e434:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e438:	40 00 0b 6a 	call  400111e0 <__errno>                       
4000e43c:	01 00 00 00 	nop                                            
4000e440:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e444:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e448:	12 80 00 07 	bne  4000e464 <rtems_string_to_unsigned_char+0x7c>
4000e44c:	80 a7 60 ff 	cmp  %i5, 0xff                                 
    (( result == 0 ) || ( result == ULONG_MAX )))                     
4000e450:	84 07 7f ff 	add  %i5, -1, %g2                              
    *endptr = end;                                                    
                                                                      
  if ( end == s )                                                     
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e454:	80 a0 bf fd 	cmp  %g2, -3                                   
4000e458:	18 80 00 0c 	bgu  4000e488 <rtems_string_to_unsigned_char+0xa0><== ALWAYS TAKEN
4000e45c:	82 10 20 0a 	mov  0xa, %g1                                  
    (( result == 0 ) || ( result == ULONG_MAX )))                     
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
#if (UCHAR_MAX < ULONG_MAX)                                           
  if ( result > UCHAR_MAX ) {                                         
4000e460:	80 a7 60 ff 	cmp  %i5, 0xff                                 <== NOT EXECUTED
4000e464:	28 80 00 08 	bleu,a   4000e484 <rtems_string_to_unsigned_char+0x9c>
4000e468:	fa 2e 40 00 	stb  %i5, [ %i1 ]                              
    errno = ERANGE;                                                   
4000e46c:	40 00 0b 5d 	call  400111e0 <__errno>                       
4000e470:	01 00 00 00 	nop                                            
4000e474:	82 10 20 22 	mov  0x22, %g1	! 22 <_TLS_Alignment+0x21>      
4000e478:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    return RTEMS_INVALID_NUMBER;                                      
4000e47c:	10 80 00 03 	b  4000e488 <rtems_string_to_unsigned_char+0xa0>
4000e480:	82 10 20 0a 	mov  0xa, %g1                                  
  }                                                                   
#endif                                                                
                                                                      
  *n = result;                                                        
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e484:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e488:	81 c7 e0 08 	ret                                            
4000e48c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e490 <rtems_string_to_unsigned_int>: const char *s, unsigned int *n, char **endptr, int base ) {
4000e490:	9d e3 bf 98 	save  %sp, -104, %sp                           
  unsigned long result;                                               
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e494:	80 a6 60 00 	cmp  %i1, 0                                    
4000e498:	02 80 00 1e 	be  4000e510 <rtems_string_to_unsigned_int+0x80>
4000e49c:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e4a0:	40 00 0b 50 	call  400111e0 <__errno>                       
4000e4a4:	01 00 00 00 	nop                                            
4000e4a8:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e4ac:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
  result = strtoul( s, &end, base );                                  
4000e4b0:	90 10 00 18 	mov  %i0, %o0                                  
4000e4b4:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e4b8:	40 00 14 df 	call  40013834 <strtoul>                       
4000e4bc:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e4c0:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtoul( s, &end, base );                                  
4000e4c4:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e4c8:	02 80 00 03 	be  4000e4d4 <rtems_string_to_unsigned_int+0x44>
4000e4cc:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e4d0:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e4d4:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e4d8:	02 80 00 0e 	be  4000e510 <rtems_string_to_unsigned_int+0x80>
4000e4dc:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e4e0:	40 00 0b 40 	call  400111e0 <__errno>                       
4000e4e4:	01 00 00 00 	nop                                            
4000e4e8:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e4ec:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e4f0:	32 80 00 07 	bne,a   4000e50c <rtems_string_to_unsigned_int+0x7c>
4000e4f4:	fa 26 40 00 	st  %i5, [ %i1 ]                               
    (( result == 0 ) || ( result == ULONG_MAX )))                     
4000e4f8:	84 07 7f ff 	add  %i5, -1, %g2                              
    *endptr = end;                                                    
                                                                      
  if ( end == s )                                                     
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e4fc:	80 a0 bf fd 	cmp  %g2, -3                                   
4000e500:	18 80 00 04 	bgu  4000e510 <rtems_string_to_unsigned_int+0x80><== ALWAYS TAKEN
4000e504:	82 10 20 0a 	mov  0xa, %g1                                  
    errno = ERANGE;                                                   
    return RTEMS_INVALID_NUMBER;                                      
  }                                                                   
#endif                                                                
                                                                      
  *n = result;                                                        
4000e508:	fa 26 40 00 	st  %i5, [ %i1 ]                               <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e50c:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e510:	81 c7 e0 08 	ret                                            
4000e514:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e5b4 <rtems_string_to_unsigned_long>: const char *s, unsigned long *n, char **endptr, int base ) {
4000e5b4:	9d e3 bf 98 	save  %sp, -104, %sp                           
  unsigned long result;                                               
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e5b8:	80 a6 60 00 	cmp  %i1, 0                                    
4000e5bc:	02 80 00 1e 	be  4000e634 <rtems_string_to_unsigned_long+0x80>
4000e5c0:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e5c4:	40 00 0b 07 	call  400111e0 <__errno>                       
4000e5c8:	01 00 00 00 	nop                                            
4000e5cc:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e5d0:	c0 26 40 00 	clr  [ %i1 ]                                   
                                                                      
  result = strtoul( s, &end, base );                                  
4000e5d4:	90 10 00 18 	mov  %i0, %o0                                  
4000e5d8:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e5dc:	40 00 14 96 	call  40013834 <strtoul>                       
4000e5e0:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e5e4:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtoul( s, &end, base );                                  
4000e5e8:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e5ec:	02 80 00 03 	be  4000e5f8 <rtems_string_to_unsigned_long+0x44>
4000e5f0:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e5f4:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e5f8:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e5fc:	02 80 00 0e 	be  4000e634 <rtems_string_to_unsigned_long+0x80>
4000e600:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e604:	40 00 0a f7 	call  400111e0 <__errno>                       
4000e608:	01 00 00 00 	nop                                            
4000e60c:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e610:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e614:	32 80 00 07 	bne,a   4000e630 <rtems_string_to_unsigned_long+0x7c>
4000e618:	fa 26 40 00 	st  %i5, [ %i1 ]                               
    (( result == 0 ) || ( result == ULONG_MAX )))                     
4000e61c:	84 07 7f ff 	add  %i5, -1, %g2                              
    *endptr = end;                                                    
                                                                      
  if ( end == s )                                                     
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e620:	80 a0 bf fd 	cmp  %g2, -3                                   
4000e624:	18 80 00 04 	bgu  4000e634 <rtems_string_to_unsigned_long+0x80><== ALWAYS TAKEN
4000e628:	82 10 20 0a 	mov  0xa, %g1                                  
    (( result == 0 ) || ( result == ULONG_MAX )))                     
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
  *n = result;                                                        
4000e62c:	fa 26 40 00 	st  %i5, [ %i1 ]                               <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e630:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e634:	81 c7 e0 08 	ret                                            
4000e638:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000e518 <rtems_string_to_unsigned_long_long>: const char *s, unsigned long long *n, char **endptr, int base ) {
4000e518:	9d e3 bf 98 	save  %sp, -104, %sp                           
  unsigned long long result;                                          
  char *end;                                                          
                                                                      
  if ( !n )                                                           
4000e51c:	80 a6 60 00 	cmp  %i1, 0                                    
4000e520:	02 80 00 23 	be  4000e5ac <rtems_string_to_unsigned_long_long+0x94>
4000e524:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
4000e528:	40 00 0b 2e 	call  400111e0 <__errno>                       
4000e52c:	01 00 00 00 	nop                                            
4000e530:	c0 22 00 00 	clr  [ %o0 ]                                   
  *n = 0;                                                             
4000e534:	c0 26 40 00 	clr  [ %i1 ]                                   
4000e538:	c0 26 60 04 	clr  [ %i1 + 4 ]                               
                                                                      
  result = strtoull( s, &end, base );                                 
4000e53c:	90 10 00 18 	mov  %i0, %o0                                  
4000e540:	92 07 bf fc 	add  %fp, -4, %o1                              
4000e544:	40 00 14 c5 	call  40013858 <strtoull>                      
4000e548:	94 10 00 1b 	mov  %i3, %o2                                  
                                                                      
  if ( endptr )                                                       
4000e54c:	80 a6 a0 00 	cmp  %i2, 0                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  errno = 0;                                                          
  *n = 0;                                                             
                                                                      
  result = strtoull( s, &end, base );                                 
4000e550:	b8 10 00 08 	mov  %o0, %i4                                  
4000e554:	ba 10 00 09 	mov  %o1, %i5                                  
                                                                      
  if ( endptr )                                                       
4000e558:	02 80 00 03 	be  4000e564 <rtems_string_to_unsigned_long_long+0x4c>
4000e55c:	c4 07 bf fc 	ld  [ %fp + -4 ], %g2                          
    *endptr = end;                                                    
4000e560:	c4 26 80 00 	st  %g2, [ %i2 ]                               
                                                                      
  if ( end == s )                                                     
4000e564:	80 a0 80 18 	cmp  %g2, %i0                                  
4000e568:	02 80 00 11 	be  4000e5ac <rtems_string_to_unsigned_long_long+0x94>
4000e56c:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e570:	40 00 0b 1c 	call  400111e0 <__errno>                       
4000e574:	01 00 00 00 	nop                                            
4000e578:	c2 02 00 00 	ld  [ %o0 ], %g1                               
4000e57c:	80 a0 60 22 	cmp  %g1, 0x22                                 
4000e580:	32 80 00 0a 	bne,a   4000e5a8 <rtems_string_to_unsigned_long_long+0x90>
4000e584:	f8 3e 40 00 	std  %i4, [ %i1 ]                              
    (( result == 0 ) || ( result == ULONG_LONG_MAX )))                
4000e588:	86 87 7f ff 	addcc  %i5, -1, %g3                            
4000e58c:	84 47 3f ff 	addx  %i4, -1, %g2                             
    *endptr = end;                                                    
                                                                      
  if ( end == s )                                                     
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( ( errno == ERANGE ) &&                                         
4000e590:	80 a0 bf ff 	cmp  %g2, -1                                   
4000e594:	12 80 00 04 	bne  4000e5a4 <rtems_string_to_unsigned_long_long+0x8c><== NEVER TAKEN
4000e598:	80 a0 ff fd 	cmp  %g3, -3                                   
4000e59c:	18 80 00 04 	bgu  4000e5ac <rtems_string_to_unsigned_long_long+0x94><== ALWAYS TAKEN
4000e5a0:	82 10 20 0a 	mov  0xa, %g1                                  
    (( result == 0 ) || ( result == ULONG_LONG_MAX )))                
      return RTEMS_INVALID_NUMBER;                                    
                                                                      
  *n = result;                                                        
4000e5a4:	f8 3e 40 00 	std  %i4, [ %i1 ]                              <== NOT EXECUTED
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000e5a8:	82 10 20 00 	clr  %g1                                       
}                                                                     
4000e5ac:	81 c7 e0 08 	ret                                            
4000e5b0:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40003390 <rtems_tarfs_load>: int rtems_tarfs_load( const char *mountpoint, uint8_t *tar_image, size_t tar_size ) {
40003390:	9d e3 bd e0 	save  %sp, -544, %sp                           
   IMFS_jnode_t                    *node;                             
   int rv = 0;                                                        
   int eval_flags = RTEMS_FS_FOLLOW_LINK;                             
   rtems_filesystem_eval_path_context_t ctx;                          
   rtems_filesystem_location_info_t rootloc;                          
   rtems_filesystem_location_info_t *currentloc =                     
40003394:	94 10 20 18 	mov  0x18, %o2                                 
40003398:	92 10 00 18 	mov  %i0, %o1                                  
4000339c:	40 00 06 53 	call  40004ce8 <rtems_filesystem_eval_path_start>
400033a0:	90 07 be 60 	add  %fp, -416, %o0                            
static inline void rtems_filesystem_eval_path_extract_currentloc(     
  rtems_filesystem_eval_path_context_t *ctx,                          
  rtems_filesystem_location_info_t *get                               
)                                                                     
{                                                                     
  rtems_filesystem_location_copy_and_detach(                          
400033a4:	92 07 be 78 	add  %fp, -392, %o1                            
400033a8:	b8 10 00 08 	mov  %o0, %i4                                  
400033ac:	40 00 07 7c 	call  4000519c <rtems_filesystem_location_copy_and_detach>
400033b0:	90 07 be 48 	add  %fp, -440, %o0                            
static inline void rtems_filesystem_eval_path_set_flags(              
  rtems_filesystem_eval_path_context_t *ctx,                          
  int flags                                                           
)                                                                     
{                                                                     
  ctx->flags = flags;                                                 
400033b4:	82 10 20 60 	mov  0x60, %g1                                 
400033b8:	c2 27 be 70 	st  %g1, [ %fp + -400 ]                        
     &ctx,                                                            
     RTEMS_FS_MAKE | RTEMS_FS_EXCLUSIVE                               
   );                                                                 
                                                                      
   if (                                                               
     rootloc.mt_entry->ops != &IMFS_ops                               
400033bc:	c2 07 be 5c 	ld  [ %fp + -420 ], %g1                        
   rtems_filesystem_eval_path_set_flags(                              
     &ctx,                                                            
     RTEMS_FS_MAKE | RTEMS_FS_EXCLUSIVE                               
   );                                                                 
                                                                      
   if (                                                               
400033c0:	05 10 00 81 	sethi  %hi(0x40020400), %g2                    
     rootloc.mt_entry->ops != &IMFS_ops                               
400033c4:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
   rtems_filesystem_eval_path_set_flags(                              
     &ctx,                                                            
     RTEMS_FS_MAKE | RTEMS_FS_EXCLUSIVE                               
   );                                                                 
                                                                      
   if (                                                               
400033c8:	84 10 a0 cc 	or  %g2, 0xcc, %g2                             
400033cc:	80 a0 40 02 	cmp  %g1, %g2                                  
400033d0:	02 80 00 08 	be  400033f0 <rtems_tarfs_load+0x60>           
400033d4:	a2 10 00 18 	mov  %i0, %l1                                  
     rootloc.mt_entry->ops != &IMFS_ops                               
       && rootloc.mt_entry->ops != &fifoIMFS_ops                      
400033d8:	05 10 00 83 	sethi  %hi(0x40020c00), %g2                    
400033dc:	84 10 a0 f8 	or  %g2, 0xf8, %g2	! 40020cf8 <fifoIMFS_ops>   
400033e0:	82 18 40 02 	xor  %g1, %g2, %g1                             
400033e4:	80 a0 00 01 	cmp  %g0, %g1                                  
400033e8:	10 80 00 03 	b  400033f4 <rtems_tarfs_load+0x64>            
400033ec:	b0 60 20 00 	subx  %g0, 0, %i0                              
   unsigned long                    file_size;                        
   unsigned long                    file_mode;                        
   int                              offset;                           
   unsigned long                    nblocks;                          
   IMFS_jnode_t                    *node;                             
   int rv = 0;                                                        
400033f0:	b0 10 20 00 	clr  %i0                                       
        filename,                                                     
        strlen( filename )                                            
      );                                                              
      rtems_filesystem_eval_path_continue( &ctx );                    
                                                                      
      if ( !rtems_filesystem_location_is_null( currentloc ) ) {       
400033f4:	27 10 00 82 	sethi  %hi(0x40020800), %l3                    
     */                                                               
    if (linkflag == DIRTYPE) {                                        
      int len;                                                        
      strncpy(full_filename, mountpoint, 255);                        
      if (full_filename[(len=strlen(full_filename))-1] != '/')        
        strcat(full_filename, "/");                                   
400033f8:	2d 10 00 75 	sethi  %hi(0x4001d400), %l6                    
   unsigned long                    file_size;                        
   unsigned long                    file_mode;                        
   int                              offset;                           
   unsigned long                    nblocks;                          
   IMFS_jnode_t                    *node;                             
   int rv = 0;                                                        
400033fc:	ba 10 20 00 	clr  %i5                                       
    hdr_ptr = (char *) &tar_image[offset];                            
    offset += 512;                                                    
    if (strncmp(&hdr_ptr[257], "ustar", 5))                           
      break;                                                          
                                                                      
    strncpy(filename, hdr_ptr, MAX_NAME_FIELD_SIZE);                  
40003400:	a0 07 be 98 	add  %fp, -360, %l0                            
        filename,                                                     
        strlen( filename )                                            
      );                                                              
      rtems_filesystem_eval_path_continue( &ctx );                    
                                                                      
      if ( !rtems_filesystem_location_is_null( currentloc ) ) {       
40003404:	a6 14 e0 b0 	or  %l3, 0xb0, %l3                             
        node = IMFS_create_node(                                      
40003408:	29 00 00 20 	sethi  %hi(0x8000), %l4                        
      int len;                                                        
      strncpy(full_filename, mountpoint, 255);                        
      if (full_filename[(len=strlen(full_filename))-1] != '/')        
        strcat(full_filename, "/");                                   
      ++len;                                                          
      strncat(full_filename, filename, 256-len-1);                    
4000340c:	aa 10 20 fe 	mov  0xfe, %l5                                 
     */                                                               
    if (linkflag == DIRTYPE) {                                        
      int len;                                                        
      strncpy(full_filename, mountpoint, 255);                        
      if (full_filename[(len=strlen(full_filename))-1] != '/')        
        strcat(full_filename, "/");                                   
40003410:	ac 15 a3 10 	or  %l6, 0x310, %l6                            
                                                                      
   /*                                                                 
    * Create an IMFS node structure pointing to tar image memory.     
    */                                                                
   offset = 0;                                                        
   while ( rv == 0 ) {                                                
40003414:	80 a6 20 00 	cmp  %i0, 0                                    
40003418:	12 80 00 63 	bne  400035a4 <rtems_tarfs_load+0x214>         
4000341c:	b6 07 62 00 	add  %i5, 0x200, %i3                           
    if (offset + 512 > tar_size)                                      
40003420:	80 a6 c0 1a 	cmp  %i3, %i2                                  
40003424:	18 80 00 60 	bgu  400035a4 <rtems_tarfs_load+0x214>         <== NEVER TAKEN
40003428:	ba 06 40 1d 	add  %i1, %i5, %i5                             
    /*                                                                
     * Read a header.                                                 
     */                                                               
    hdr_ptr = (char *) &tar_image[offset];                            
    offset += 512;                                                    
    if (strncmp(&hdr_ptr[257], "ustar", 5))                           
4000342c:	13 10 00 81 	sethi  %hi(0x40020400), %o1                    
40003430:	90 07 61 01 	add  %i5, 0x101, %o0                           
40003434:	92 12 61 38 	or  %o1, 0x138, %o1                            
40003438:	40 00 3f 7f 	call  40013234 <strncmp>                       
4000343c:	94 10 20 05 	mov  5, %o2                                    
40003440:	80 a2 20 00 	cmp  %o0, 0                                    
40003444:	12 80 00 58 	bne  400035a4 <rtems_tarfs_load+0x214>         
40003448:	94 10 20 63 	mov  0x63, %o2                                 
      break;                                                          
                                                                      
    strncpy(filename, hdr_ptr, MAX_NAME_FIELD_SIZE);                  
4000344c:	92 10 00 1d 	mov  %i5, %o1                                  
40003450:	40 00 3f c7 	call  4001336c <strncpy>                       
40003454:	90 10 00 10 	mov  %l0, %o0                                  
    filename[MAX_NAME_FIELD_SIZE] = '\0';                             
                                                                      
    linkflag   = hdr_ptr[156];                                        
40003458:	c2 0f 60 9c 	ldub  [ %i5 + 0x9c ], %g1                      
    file_mode  = _rtems_octal2ulong(&hdr_ptr[100], 8);                
4000345c:	92 10 20 08 	mov  8, %o1                                    
40003460:	c2 27 be 44 	st  %g1, [ %fp + -444 ]                        
    offset += 512;                                                    
    if (strncmp(&hdr_ptr[257], "ustar", 5))                           
      break;                                                          
                                                                      
    strncpy(filename, hdr_ptr, MAX_NAME_FIELD_SIZE);                  
    filename[MAX_NAME_FIELD_SIZE] = '\0';                             
40003464:	c0 2f be fb 	clrb  [ %fp + -261 ]                           
                                                                      
    linkflag   = hdr_ptr[156];                                        
    file_mode  = _rtems_octal2ulong(&hdr_ptr[100], 8);                
40003468:	40 00 21 21 	call  4000b8ec <_rtems_octal2ulong>            
4000346c:	90 07 60 64 	add  %i5, 0x64, %o0                            
    file_size  = _rtems_octal2ulong(&hdr_ptr[124], 12);               
40003470:	92 10 20 0c 	mov  0xc, %o1                                  
                                                                      
    strncpy(filename, hdr_ptr, MAX_NAME_FIELD_SIZE);                  
    filename[MAX_NAME_FIELD_SIZE] = '\0';                             
                                                                      
    linkflag   = hdr_ptr[156];                                        
    file_mode  = _rtems_octal2ulong(&hdr_ptr[100], 8);                
40003474:	ae 10 00 08 	mov  %o0, %l7                                  
    file_size  = _rtems_octal2ulong(&hdr_ptr[124], 12);               
40003478:	40 00 21 1d 	call  4000b8ec <_rtems_octal2ulong>            
4000347c:	90 07 60 7c 	add  %i5, 0x7c, %o0                            
    hdr_chksum = _rtems_octal2ulong(&hdr_ptr[148], 8);                
40003480:	92 10 20 08 	mov  8, %o1                                    
    strncpy(filename, hdr_ptr, MAX_NAME_FIELD_SIZE);                  
    filename[MAX_NAME_FIELD_SIZE] = '\0';                             
                                                                      
    linkflag   = hdr_ptr[156];                                        
    file_mode  = _rtems_octal2ulong(&hdr_ptr[100], 8);                
    file_size  = _rtems_octal2ulong(&hdr_ptr[124], 12);               
40003484:	a4 10 00 08 	mov  %o0, %l2                                  
    hdr_chksum = _rtems_octal2ulong(&hdr_ptr[148], 8);                
40003488:	40 00 21 19 	call  4000b8ec <_rtems_octal2ulong>            
4000348c:	90 07 60 94 	add  %i5, 0x94, %o0                            
40003490:	84 10 00 08 	mov  %o0, %g2                                  
                                                                      
    if (_rtems_tar_header_checksum(hdr_ptr) != hdr_chksum)            
40003494:	90 10 00 1d 	mov  %i5, %o0                                  
40003498:	40 00 21 29 	call  4000b93c <_rtems_tar_header_checksum>    
4000349c:	c4 27 be 40 	st  %g2, [ %fp + -448 ]                        
400034a0:	c4 07 be 40 	ld  [ %fp + -448 ], %g2                        
400034a4:	80 a2 00 02 	cmp  %o0, %g2                                  
400034a8:	12 80 00 3f 	bne  400035a4 <rtems_tarfs_load+0x214>         <== NEVER TAKEN
400034ac:	c2 07 be 44 	ld  [ %fp + -444 ], %g1                        
     * Generate an IMFS node depending on the file type.              
     * - For directories, just create directories as usual.  IMFS     
     *   will take care of the rest.                                  
     * - For files, create a file node with special tarfs properties. 
     */                                                               
    if (linkflag == DIRTYPE) {                                        
400034b0:	82 08 60 ff 	and  %g1, 0xff, %g1                            
400034b4:	80 a0 60 35 	cmp  %g1, 0x35                                 
400034b8:	12 80 00 19 	bne  4000351c <rtems_tarfs_load+0x18c>         
400034bc:	80 a0 60 30 	cmp  %g1, 0x30                                 
      int len;                                                        
      strncpy(full_filename, mountpoint, 255);                        
400034c0:	92 10 00 11 	mov  %l1, %o1                                  
400034c4:	94 10 20 ff 	mov  0xff, %o2                                 
400034c8:	40 00 3f a9 	call  4001336c <strncpy>                       
400034cc:	90 07 bf 00 	add  %fp, -256, %o0                            
      if (full_filename[(len=strlen(full_filename))-1] != '/')        
400034d0:	40 00 3e f4 	call  400130a0 <strlen>                        
400034d4:	90 07 bf 00 	add  %fp, -256, %o0                            
400034d8:	82 07 80 08 	add  %fp, %o0, %g1                             
400034dc:	c2 48 7e ff 	ldsb  [ %g1 + -257 ], %g1                      
400034e0:	80 a0 60 2f 	cmp  %g1, 0x2f                                 
400034e4:	02 80 00 05 	be  400034f8 <rtems_tarfs_load+0x168>          <== ALWAYS TAKEN
400034e8:	ba 10 00 08 	mov  %o0, %i5                                  
        strcat(full_filename, "/");                                   
400034ec:	90 07 bf 00 	add  %fp, -256, %o0                            <== NOT EXECUTED
400034f0:	40 00 3c d7 	call  4001284c <strcat>                        <== NOT EXECUTED
400034f4:	92 10 00 16 	mov  %l6, %o1                                  <== NOT EXECUTED
      ++len;                                                          
      strncat(full_filename, filename, 256-len-1);                    
400034f8:	92 10 00 10 	mov  %l0, %o1                                  
400034fc:	94 25 40 1d 	sub  %l5, %i5, %o2                             
40003500:	40 00 3f 18 	call  40013160 <strncat>                       
40003504:	90 07 bf 00 	add  %fp, -256, %o0                            
      rv = mkdir(full_filename, S_IRWXU | S_IRWXG | S_IRWXO);         
40003508:	90 07 bf 00 	add  %fp, -256, %o0                            
4000350c:	40 00 03 16 	call  40004164 <mkdir>                         
40003510:	92 10 21 ff 	mov  0x1ff, %o1                                
40003514:	10 80 00 22 	b  4000359c <rtems_tarfs_load+0x20c>           
40003518:	b0 10 00 08 	mov  %o0, %i0                                  
    }                                                                 
    /*                                                                
     * Create a LINEAR_FILE node                                      
     */                                                               
    else if (linkflag == REGTYPE) {                                   
4000351c:	12 bf ff be 	bne  40003414 <rtems_tarfs_load+0x84>          
40003520:	ba 10 00 1b 	mov  %i3, %i5                                  
      rtems_filesystem_location_free( currentloc );                   
40003524:	40 00 01 95 	call  40003b78 <rtems_filesystem_location_free>
40003528:	90 10 00 1c 	mov  %i4, %o0                                  
      rtems_filesystem_location_clone( currentloc, &rootloc );        
4000352c:	92 07 be 48 	add  %fp, -440, %o1                            
40003530:	40 00 01 5d 	call  40003aa4 <rtems_filesystem_location_clone>
40003534:	90 10 00 1c 	mov  %i4, %o0                                  
      rtems_filesystem_eval_path_set_path(                            
40003538:	40 00 3e da 	call  400130a0 <strlen>                        
4000353c:	90 10 00 10 	mov  %l0, %o0                                  
  rtems_filesystem_eval_path_context_t *ctx,                          
  const char *path,                                                   
  size_t pathlen                                                      
)                                                                     
{                                                                     
  ctx->path = path;                                                   
40003540:	e0 27 be 60 	st  %l0, [ %fp + -416 ]                        
  ctx->pathlen = pathlen;                                             
40003544:	d0 27 be 64 	st  %o0, [ %fp + -412 ]                        
        &ctx,                                                         
        filename,                                                     
        strlen( filename )                                            
      );                                                              
      rtems_filesystem_eval_path_continue( &ctx );                    
40003548:	40 00 05 b1 	call  40004c0c <rtems_filesystem_eval_path_continue>
4000354c:	90 07 be 60 	add  %fp, -416, %o0                            
                                                                      
      if ( !rtems_filesystem_location_is_null( currentloc ) ) {       
40003550:	c2 07 20 10 	ld  [ %i4 + 0x10 ], %g1                        
40003554:	80 a0 40 13 	cmp  %g1, %l3                                  
40003558:	02 80 00 0e 	be  40003590 <rtems_tarfs_load+0x200>          <== NEVER TAKEN
4000355c:	d4 1f be 68 	ldd  [ %fp + -408 ], %o2                       
  size_t namelen,                                                     
  mode_t mode,                                                        
  const IMFS_types_union *info                                        
)                                                                     
{                                                                     
  const IMFS_fs_info_t *fs_info =                                     
40003560:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
    (const IMFS_fs_info_t *) parentloc->mt_entry->fs_info;            
                                                                      
  return IMFS_create_node_with_control(                               
40003564:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
        node = IMFS_create_node(                                      
          currentloc,                                                 
          IMFS_LINEAR_FILE,                                           
          rtems_filesystem_eval_path_get_token( &ctx ),               
          rtems_filesystem_eval_path_get_tokenlen( &ctx ),            
          (file_mode & (S_IRWXU | S_IRWXG | S_IRWXO)) | S_IFREG,      
40003568:	98 0d e1 ff 	and  %l7, 0x1ff, %o4                           
4000356c:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1                        
40003570:	90 10 00 1c 	mov  %i4, %o0                                  
40003574:	98 13 00 14 	or  %o4, %l4, %o4                              
40003578:	40 00 21 e8 	call  4000bd18 <IMFS_create_node_with_control> 
4000357c:	9a 10 20 00 	clr  %o5                                       
          NULL                                                        
        );                                                            
        node->info.linearfile.size   = file_size;                     
        node->info.linearfile.direct = &tar_image[offset];            
40003580:	82 06 40 1b 	add  %i1, %i3, %g1                             
          rtems_filesystem_eval_path_get_token( &ctx ),               
          rtems_filesystem_eval_path_get_tokenlen( &ctx ),            
          (file_mode & (S_IRWXU | S_IRWXG | S_IRWXO)) | S_IFREG,      
          NULL                                                        
        );                                                            
        node->info.linearfile.size   = file_size;                     
40003584:	c0 22 20 50 	clr  [ %o0 + 0x50 ]                            
40003588:	e4 22 20 54 	st  %l2, [ %o0 + 0x54 ]                        
        node->info.linearfile.direct = &tar_image[offset];            
4000358c:	c2 22 20 58 	st  %g1, [ %o0 + 0x58 ]                        
      }                                                               
                                                                      
      nblocks = (((file_size) + 511) & ~511) / 512;                   
40003590:	a4 04 a1 ff 	add  %l2, 0x1ff, %l2                           
      offset += 512 * nblocks;                                        
40003594:	a4 0c be 00 	and  %l2, -512, %l2                            
40003598:	b6 04 80 1b 	add  %l2, %i3, %i3                             
   unsigned long                    file_size;                        
   unsigned long                    file_mode;                        
   int                              offset;                           
   unsigned long                    nblocks;                          
   IMFS_jnode_t                    *node;                             
   int rv = 0;                                                        
4000359c:	10 bf ff 9e 	b  40003414 <rtems_tarfs_load+0x84>            
400035a0:	ba 10 00 1b 	mov  %i3, %i5                                  
      nblocks = (((file_size) + 511) & ~511) / 512;                   
      offset += 512 * nblocks;                                        
    }                                                                 
  }                                                                   
                                                                      
  rtems_filesystem_location_free( &rootloc );                         
400035a4:	40 00 01 75 	call  40003b78 <rtems_filesystem_location_free>
400035a8:	90 07 be 48 	add  %fp, -440, %o0                            
  rtems_filesystem_eval_path_cleanup( &ctx );                         
400035ac:	40 00 05 d7 	call  40004d08 <rtems_filesystem_eval_path_cleanup>
400035b0:	90 07 be 60 	add  %fp, -416, %o0                            
                                                                      
  return rv;                                                          
}                                                                     
400035b4:	81 c7 e0 08 	ret                                            
400035b8:	81 e8 00 00 	restore                                        
                                                                      

4000efdc <rtems_task_mode>: rtems_status_code rtems_task_mode( rtems_mode mode_set, rtems_mode mask, rtems_mode *previous_mode_set ) {
4000efdc:	9d e3 bf a0 	save  %sp, -96, %sp                            
  RTEMS_API_Control  *api;                                            
  ASR_Information    *asr;                                            
  bool                needs_asr_dispatching;                          
  rtems_mode          old_mode;                                       
                                                                      
  if ( !previous_mode_set )                                           
4000efe0:	80 a6 a0 00 	cmp  %i2, 0                                    
4000efe4:	02 80 00 65 	be  4000f178 <rtems_task_mode+0x19c>           
4000efe8:	82 10 20 09 	mov  9, %g1                                    
4000efec:	fa 01 a0 18 	ld  [ %g6 + 0x18 ], %i5                        
                                                                      
  executing     = _Thread_Get_executing();                            
  api = executing->API_Extensions[ THREAD_API_RTEMS ];                
  asr = &api->Signal;                                                 
                                                                      
  old_mode  = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
4000eff0:	c2 0f 60 70 	ldub  [ %i5 + 0x70 ], %g1                      
                                                                      
  if ( !previous_mode_set )                                           
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  executing     = _Thread_Get_executing();                            
  api = executing->API_Extensions[ THREAD_API_RTEMS ];                
4000eff4:	f8 07 61 2c 	ld  [ %i5 + 0x12c ], %i4                       
  asr = &api->Signal;                                                 
                                                                      
  old_mode  = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
4000eff8:	80 a0 00 01 	cmp  %g0, %g1                                  
                                                                      
  if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
4000effc:	c2 07 60 78 	ld  [ %i5 + 0x78 ], %g1                        
                                                                      
  executing     = _Thread_Get_executing();                            
  api = executing->API_Extensions[ THREAD_API_RTEMS ];                
  asr = &api->Signal;                                                 
                                                                      
  old_mode  = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
4000f000:	b6 60 3f ff 	subx  %g0, -1, %i3                             
                                                                      
  if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
4000f004:	80 a0 60 00 	cmp  %g1, 0                                    
4000f008:	02 80 00 03 	be  4000f014 <rtems_task_mode+0x38>            
4000f00c:	b7 2e e0 08 	sll  %i3, 8, %i3                               
    old_mode |= RTEMS_NO_TIMESLICE;                                   
  else                                                                
    old_mode |= RTEMS_TIMESLICE;                                      
4000f010:	b6 16 e2 00 	or  %i3, 0x200, %i3                            
                                                                      
  old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;           
4000f014:	c2 0f 20 08 	ldub  [ %i4 + 8 ], %g1                         
4000f018:	80 a0 00 01 	cmp  %g0, %g1                                  
  old_mode |= _ISR_Get_level();                                       
4000f01c:	7f ff f0 fe 	call  4000b414 <_CPU_ISR_Get_level>            
4000f020:	a0 60 3f ff 	subx  %g0, -1, %l0                             
  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;           
4000f024:	a1 2c 20 0a 	sll  %l0, 0xa, %l0                             
4000f028:	90 14 00 08 	or  %l0, %o0, %o0                              
  old_mode |= _ISR_Get_level();                                       
4000f02c:	b6 12 00 1b 	or  %o0, %i3, %i3                              
  *previous_mode_set = old_mode;                                      
                                                                      
  /*                                                                  
   *  These are generic thread scheduling characteristics.            
   */                                                                 
  if ( mask & RTEMS_PREEMPT_MASK ) {                                  
4000f030:	80 8e 61 00 	btst  0x100, %i1                               
4000f034:	02 80 00 06 	be  4000f04c <rtems_task_mode+0x70>            
4000f038:	f6 26 80 00 	st  %i3, [ %i2 ]                               
 */                                                                   
RTEMS_INLINE_ROUTINE bool _Modes_Is_preempt (                         
  Modes_Control mode_set                                              
)                                                                     
{                                                                     
   return (mode_set & RTEMS_PREEMPT_MASK) == RTEMS_PREEMPT;           
4000f03c:	83 36 20 08 	srl  %i0, 8, %g1                               
4000f040:	82 18 60 01 	xor  %g1, 1, %g1                               
4000f044:	82 08 60 01 	and  %g1, 1, %g1                               
         !_Modes_Is_preempt( mode_set ) ) {                           
      return RTEMS_NOT_IMPLEMENTED;                                   
    }                                                                 
#endif                                                                
                                                                      
    executing->is_preemptible = _Modes_Is_preempt( mode_set );        
4000f048:	c2 2f 60 70 	stb  %g1, [ %i5 + 0x70 ]                       
  }                                                                   
                                                                      
  if ( mask & RTEMS_TIMESLICE_MASK ) {                                
4000f04c:	80 8e 62 00 	btst  0x200, %i1                               
4000f050:	02 80 00 0b 	be  4000f07c <rtems_task_mode+0xa0>            
4000f054:	80 8e 60 0f 	btst  0xf, %i1                                 
    if ( _Modes_Is_timeslice(mode_set) ) {                            
4000f058:	80 8e 22 00 	btst  0x200, %i0                               
4000f05c:	22 80 00 07 	be,a   4000f078 <rtems_task_mode+0x9c>         
4000f060:	c0 27 60 78 	clr  [ %i5 + 0x78 ]                            
      executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
4000f064:	82 10 20 01 	mov  1, %g1                                    
4000f068:	c2 27 60 78 	st  %g1, [ %i5 + 0x78 ]                        
      executing->cpu_time_budget =                                    
        rtems_configuration_get_ticks_per_timeslice();                
4000f06c:	03 10 00 55 	sethi  %hi(0x40015400), %g1                    
  }                                                                   
                                                                      
  if ( mask & RTEMS_TIMESLICE_MASK ) {                                
    if ( _Modes_Is_timeslice(mode_set) ) {                            
      executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
      executing->cpu_time_budget =                                    
4000f070:	c2 00 61 a4 	ld  [ %g1 + 0x1a4 ], %g1	! 400155a4 <Configuration+0x1c>
4000f074:	c2 27 60 74 	st  %g1, [ %i5 + 0x74 ]                        
  }                                                                   
                                                                      
  /*                                                                  
   *  Set the new interrupt level                                     
   */                                                                 
  if ( mask & RTEMS_INTERRUPT_MASK )                                  
4000f078:	80 8e 60 0f 	btst  0xf, %i1                                 
4000f07c:	02 80 00 06 	be  4000f094 <rtems_task_mode+0xb8>            
4000f080:	80 8e 64 00 	btst  0x400, %i1                               
 */                                                                   
RTEMS_INLINE_ROUTINE ISR_Level _Modes_Get_interrupt_level (           
  Modes_Control mode_set                                              
)                                                                     
{                                                                     
  return ( mode_set & RTEMS_INTERRUPT_MASK );                         
4000f084:	90 0e 20 0f 	and  %i0, 0xf, %o0                             
 */                                                                   
RTEMS_INLINE_ROUTINE void _Modes_Set_interrupt_level (                
  Modes_Control mode_set                                              
)                                                                     
{                                                                     
  _ISR_Set_level( _Modes_Get_interrupt_level( mode_set ) );           
4000f088:	7f ff cc ee 	call  40002440 <sparc_enable_interrupts>       
4000f08c:	91 2a 20 08 	sll  %o0, 8, %o0                               
                                                                      
  /*                                                                  
   *  This is specific to the RTEMS API                               
   */                                                                 
  needs_asr_dispatching = false;                                      
  if ( mask & RTEMS_ASR_MASK ) {                                      
4000f090:	80 8e 64 00 	btst  0x400, %i1                               
4000f094:	32 80 00 04 	bne,a   4000f0a4 <rtems_task_mode+0xc8>        
4000f098:	c2 0f 20 08 	ldub  [ %i4 + 8 ], %g1                         
    _Modes_Set_interrupt_level( mode_set );                           
                                                                      
  /*                                                                  
   *  This is specific to the RTEMS API                               
   */                                                                 
  needs_asr_dispatching = false;                                      
4000f09c:	10 80 00 23 	b  4000f128 <rtems_task_mode+0x14c>            
4000f0a0:	86 10 20 00 	clr  %g3                                       
  if ( mask & RTEMS_ASR_MASK ) {                                      
    bool is_asr_enabled = !_Modes_Is_asr_disabled( mode_set );        
4000f0a4:	b1 36 20 0a 	srl  %i0, 0xa, %i0                             
4000f0a8:	b0 1e 20 01 	xor  %i0, 1, %i0                               
4000f0ac:	b0 0e 20 01 	and  %i0, 1, %i0                               
                                                                      
    if ( is_asr_enabled != asr->is_enabled ) {                        
4000f0b0:	80 a6 00 01 	cmp  %i0, %g1                                  
4000f0b4:	02 80 00 1d 	be  4000f128 <rtems_task_mode+0x14c>           
4000f0b8:	86 10 20 00 	clr  %g3                                       
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
4000f0bc:	7f ff cc de 	call  40002434 <sparc_disable_interrupts>      
4000f0c0:	f0 2f 20 08 	stb  %i0, [ %i4 + 8 ]                          
{                                                                     
  rtems_signal_set _signals;                                          
  ISR_lock_Context lock_context;                                      
                                                                      
  _ISR_lock_ISR_disable_and_acquire( &asr->Lock, &lock_context );     
    _signals             = asr->signals_pending;                      
4000f0c4:	c2 07 20 18 	ld  [ %i4 + 0x18 ], %g1                        
    asr->signals_pending = asr->signals_posted;                       
4000f0c8:	c4 07 20 14 	ld  [ %i4 + 0x14 ], %g2                        
    asr->signals_posted  = _signals;                                  
4000f0cc:	c2 27 20 14 	st  %g1, [ %i4 + 0x14 ]                        
  rtems_signal_set _signals;                                          
  ISR_lock_Context lock_context;                                      
                                                                      
  _ISR_lock_ISR_disable_and_acquire( &asr->Lock, &lock_context );     
    _signals             = asr->signals_pending;                      
    asr->signals_pending = asr->signals_posted;                       
4000f0d0:	c4 27 20 18 	st  %g2, [ %i4 + 0x18 ]                        
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
4000f0d4:	7f ff cc db 	call  40002440 <sparc_enable_interrupts>       
4000f0d8:	01 00 00 00 	nop                                            
      asr->is_enabled = is_asr_enabled;                               
      _ASR_Swap_signals( asr );                                       
      if ( _ASR_Are_signals_pending( asr ) ) {                        
4000f0dc:	c2 07 20 14 	ld  [ %i4 + 0x14 ], %g1                        
4000f0e0:	80 a0 60 00 	cmp  %g1, 0                                    
4000f0e4:	02 80 00 11 	be  4000f128 <rtems_task_mode+0x14c>           
4000f0e8:	86 10 20 00 	clr  %g3                                       
  ISR_Level      *level                                               
)                                                                     
{                                                                     
  Per_CPU_Control *cpu;                                               
                                                                      
  _ISR_Disable_without_giant( *level );                               
4000f0ec:	7f ff cc d2 	call  40002434 <sparc_disable_interrupts>      
4000f0f0:	01 00 00 00 	nop                                            
RTEMS_INLINE_ROUTINE void _Chain_Append_if_is_off_chain_unprotected(  
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  if ( _Chain_Is_node_off_chain( the_node ) ) {                       
4000f0f4:	c2 07 20 20 	ld  [ %i4 + 0x20 ], %g1                        
4000f0f8:	80 a0 60 00 	cmp  %g1, 0                                    
4000f0fc:	12 80 00 08 	bne  4000f11c <rtems_task_mode+0x140>          <== NEVER TAKEN
4000f100:	86 07 60 c8 	add  %i5, 0xc8, %g3                            
  Chain_Control *the_chain,                                           
  Chain_Node    *the_node                                             
)                                                                     
{                                                                     
  Chain_Node *tail = _Chain_Tail( the_chain );                        
  Chain_Node *old_last = tail->previous;                              
4000f104:	c2 07 60 cc 	ld  [ %i5 + 0xcc ], %g1                        
                                                                      
  the_node->next = tail;                                              
4000f108:	c6 27 20 20 	st  %g3, [ %i4 + 0x20 ]                        
{                                                                     
  Per_CPU_Control *cpu;                                               
  ISR_Level        level;                                             
                                                                      
  cpu = _Thread_Action_ISR_disable_and_acquire( thread, &level );     
  _Chain_Append_if_is_off_chain_unprotected(                          
4000f10c:	84 07 20 20 	add  %i4, 0x20, %g2                            
  tail->previous = the_node;                                          
4000f110:	c4 27 60 cc 	st  %g2, [ %i5 + 0xcc ]                        
  old_last->next = the_node;                                          
4000f114:	c4 20 40 00 	st  %g2, [ %g1 ]                               
  the_node->previous = old_last;                                      
4000f118:	c2 27 20 24 	st  %g1, [ %i4 + 0x24 ]                        
RTEMS_INLINE_ROUTINE void _Thread_Action_release_and_ISR_enable(      
  Per_CPU_Control *cpu,                                               
  ISR_Level level                                                     
)                                                                     
{                                                                     
  _Per_CPU_Release_and_ISR_enable( cpu, level );                      
4000f11c:	7f ff cc c9 	call  40002440 <sparc_enable_interrupts>       
4000f120:	01 00 00 00 	nop                                            
        needs_asr_dispatching = true;                                 
4000f124:	86 10 20 01 	mov  1, %g3	! 1 <_TLS_Alignment>               
  ISR_Level level;                                                    
                                                                      
  _ISR_Disable_without_giant( level );                                
#endif                                                                
                                                                      
  enabled = _Thread_Dispatch_disable_level == 0;                      
4000f128:	c8 01 a0 10 	ld  [ %g6 + 0x10 ], %g4                        
static void _RTEMS_Tasks_Dispatch_if_necessary(                       
  Thread_Control *executing,                                          
  bool            needs_asr_dispatching                               
)                                                                     
{                                                                     
  if ( _Thread_Dispatch_is_enabled() ) {                              
4000f12c:	80 a1 20 00 	cmp  %g4, 0                                    
4000f130:	12 80 00 12 	bne  4000f178 <rtems_task_mode+0x19c>          <== NEVER TAKEN
4000f134:	82 10 20 00 	clr  %g1                                       
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable_without_giant( level );                              
#endif                                                                
                                                                      
    if ( !_Thread_Is_heir( executing ) && executing->is_preemptible ) {
4000f138:	c2 01 a0 1c 	ld  [ %g6 + 0x1c ], %g1                        
4000f13c:	80 a7 40 01 	cmp  %i5, %g1                                  
4000f140:	02 80 00 09 	be  4000f164 <rtems_task_mode+0x188>           
4000f144:	80 88 e0 ff 	btst  0xff, %g3                                
4000f148:	c2 0f 60 70 	ldub  [ %i5 + 0x70 ], %g1                      
4000f14c:	80 a0 60 00 	cmp  %g1, 0                                    
4000f150:	02 80 00 05 	be  4000f164 <rtems_task_mode+0x188>           <== NEVER TAKEN
4000f154:	80 88 e0 ff 	btst  0xff, %g3                                
      dispatch_necessary = true;                                      
      _Thread_Dispatch_necessary = dispatch_necessary;                
4000f158:	82 10 20 01 	mov  1, %g1                                    
4000f15c:	c2 29 a0 14 	stb  %g1, [ %g6 + 0x14 ]                       
4000f160:	30 80 00 03 	b,a   4000f16c <rtems_task_mode+0x190>         
                                                                      
#if defined( RTEMS_SMP )                                              
    _ISR_Enable_without_giant( level );                               
#endif                                                                
                                                                      
    if ( dispatch_necessary ) {                                       
4000f164:	02 80 00 05 	be  4000f178 <rtems_task_mode+0x19c>           
4000f168:	82 10 20 00 	clr  %g1                                       
      _Thread_Dispatch();                                             
4000f16c:	7f ff ea ce 	call  40009ca4 <_Thread_Dispatch>              
4000f170:	01 00 00 00 	nop                                            
    }                                                                 
  }                                                                   
                                                                      
  _RTEMS_Tasks_Dispatch_if_necessary( executing, needs_asr_dispatching );
                                                                      
  return RTEMS_SUCCESSFUL;                                            
4000f174:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
}                                                                     
4000f178:	81 c7 e0 08 	ret                                            
4000f17c:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

4000c290 <rtems_task_set_priority>: rtems_status_code rtems_task_set_priority( rtems_id id, rtems_task_priority new_priority, rtems_task_priority *old_priority ) {
4000c290:	9d e3 bf 98 	save  %sp, -104, %sp                           
  Thread_Control          *the_thread;                                
  Objects_Locations        location;                                  
                                                                      
  if ( new_priority != RTEMS_CURRENT_PRIORITY &&                      
4000c294:	80 a6 60 00 	cmp  %i1, 0                                    
4000c298:	02 80 00 08 	be  4000c2b8 <rtems_task_set_priority+0x28>    
4000c29c:	80 a6 a0 00 	cmp  %i2, 0                                    
RTEMS_INLINE_ROUTINE bool _RTEMS_tasks_Priority_is_valid (            
  rtems_task_priority the_priority                                    
)                                                                     
{                                                                     
  return (  ( the_priority >= RTEMS_MINIMUM_PRIORITY ) &&             
            ( the_priority <= RTEMS_MAXIMUM_PRIORITY ) );             
4000c2a0:	03 10 00 6c 	sethi  %hi(0x4001b000), %g1                    
4000c2a4:	c4 08 62 54 	ldub  [ %g1 + 0x254 ], %g2	! 4001b254 <rtems_maximum_priority>
4000c2a8:	80 a6 40 02 	cmp  %i1, %g2                                  
4000c2ac:	18 80 00 1e 	bgu  4000c324 <rtems_task_set_priority+0x94>   
4000c2b0:	82 10 20 13 	mov  0x13, %g1                                 
       !_RTEMS_tasks_Priority_is_valid( new_priority ) )              
    return RTEMS_INVALID_PRIORITY;                                    
                                                                      
  if ( !old_priority )                                                
4000c2b4:	80 a6 a0 00 	cmp  %i2, 0                                    
4000c2b8:	02 80 00 1b 	be  4000c324 <rtems_task_set_priority+0x94>    
4000c2bc:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  the_thread = _Thread_Get( id, &location );                          
4000c2c0:	90 10 00 18 	mov  %i0, %o0                                  
4000c2c4:	40 00 09 6f 	call  4000e880 <_Thread_Get>                   
4000c2c8:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch ( location ) {                                               
4000c2cc:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000c2d0:	80 a0 60 00 	cmp  %g1, 0                                    
4000c2d4:	12 80 00 14 	bne  4000c324 <rtems_task_set_priority+0x94>   
4000c2d8:	82 10 20 04 	mov  4, %g1                                    
                                                                      
    case OBJECTS_LOCAL:                                               
      *old_priority = _RTEMS_tasks_Priority_from_Core(                
4000c2dc:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
                        the_thread->current_priority                  
                      );                                              
      if ( new_priority != RTEMS_CURRENT_PRIORITY ) {                 
4000c2e0:	80 a6 60 00 	cmp  %i1, 0                                    
4000c2e4:	02 80 00 0d 	be  4000c318 <rtems_task_set_priority+0x88>    
4000c2e8:	c2 26 80 00 	st  %g1, [ %i2 ]                               
        the_thread->real_priority = _RTEMS_tasks_Priority_to_Core(    
                                      new_priority                    
                                    );                                
        if ( !_Thread_Owns_resources( the_thread ) ||                 
4000c2ec:	c2 02 20 1c 	ld  [ %o0 + 0x1c ], %g1                        
4000c2f0:	80 a0 60 00 	cmp  %g1, 0                                    
4000c2f4:	02 80 00 06 	be  4000c30c <rtems_task_set_priority+0x7c>    
4000c2f8:	f2 22 20 18 	st  %i1, [ %o0 + 0x18 ]                        
4000c2fc:	c2 02 20 14 	ld  [ %o0 + 0x14 ], %g1                        
4000c300:	80 a0 40 19 	cmp  %g1, %i1                                  
4000c304:	08 80 00 05 	bleu  4000c318 <rtems_task_set_priority+0x88>  <== ALWAYS TAKEN
4000c308:	01 00 00 00 	nop                                            
             the_thread->current_priority > new_priority )            
          _Thread_Change_priority( the_thread, new_priority, false ); 
4000c30c:	92 10 00 19 	mov  %i1, %o1                                  
4000c310:	40 00 08 64 	call  4000e4a0 <_Thread_Change_priority>       
4000c314:	94 10 20 00 	clr  %o2                                       
4000c318:	40 00 09 4f 	call  4000e854 <_Thread_Enable_dispatch>       
4000c31c:	01 00 00 00 	nop                                            
4000c320:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return RTEMS_INVALID_ID;                                            
}                                                                     
4000c324:	81 c7 e0 08 	ret                                            
4000c328:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40009d90 <rtems_task_variable_add>: rtems_status_code rtems_task_variable_add( rtems_id tid, void **ptr, void (*dtor)(void *) ) {
40009d90:	9d e3 bf 98 	save  %sp, -104, %sp                           
  if ( rtems_configuration_is_smp_enabled() ) {                       
    return RTEMS_NOT_IMPLEMENTED;                                     
  }                                                                   
#endif                                                                
                                                                      
  if ( !ptr )                                                         
40009d94:	80 a6 60 00 	cmp  %i1, 0                                    
40009d98:	02 80 00 27 	be  40009e34 <rtems_task_variable_add+0xa4>    <== NEVER TAKEN
40009d9c:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  the_thread = _Thread_Get (tid, &location);                          
40009da0:	90 10 00 18 	mov  %i0, %o0                                  
40009da4:	40 00 09 cd 	call  4000c4d8 <_Thread_Get>                   
40009da8:	92 07 bf fc 	add  %fp, -4, %o1                              
  switch (location) {                                                 
40009dac:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40009db0:	80 a0 60 00 	cmp  %g1, 0                                    
40009db4:	12 80 00 1f 	bne  40009e30 <rtems_task_variable_add+0xa0>   <== NEVER TAKEN
40009db8:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    case OBJECTS_LOCAL:                                               
      /*                                                              
       *  Figure out if the variable is already in this task's list.  
       */                                                             
      tvp = the_thread->task_variables;                               
40009dbc:	c2 02 21 34 	ld  [ %o0 + 0x134 ], %g1                       
      while (tvp) {                                                   
40009dc0:	80 a0 60 00 	cmp  %g1, 0                                    
40009dc4:	02 80 00 08 	be  40009de4 <rtems_task_variable_add+0x54>    
40009dc8:	01 00 00 00 	nop                                            
        if (tvp->ptr == ptr) {                                        
40009dcc:	c4 00 60 04 	ld  [ %g1 + 4 ], %g2                           
40009dd0:	80 a0 80 19 	cmp  %g2, %i1                                  
40009dd4:	32 bf ff fb 	bne,a   40009dc0 <rtems_task_variable_add+0x30><== NEVER TAKEN
40009dd8:	c2 00 40 00 	ld  [ %g1 ], %g1                               <== NOT EXECUTED
          tvp->dtor = dtor;                                           
40009ddc:	10 80 00 11 	b  40009e20 <rtems_task_variable_add+0x90>     
40009de0:	f4 20 60 10 	st  %i2, [ %g1 + 0x10 ]                        
      }                                                               
                                                                      
      /*                                                              
       *  Now allocate memory for this task variable.                 
       */                                                             
      new = (rtems_task_variable_t *)                                 
40009de4:	40 00 0f 3f 	call  4000dae0 <_Workspace_Allocate>           
40009de8:	90 10 20 14 	mov  0x14, %o0                                 
         _Workspace_Allocate(sizeof(rtems_task_variable_t));          
      if (new == NULL) {                                              
40009dec:	80 a2 20 00 	cmp  %o0, 0                                    
40009df0:	32 80 00 06 	bne,a   40009e08 <rtems_task_variable_add+0x78><== ALWAYS TAKEN
40009df4:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40009df8:	40 00 09 ad 	call  4000c4ac <_Thread_Enable_dispatch>       <== NOT EXECUTED
40009dfc:	01 00 00 00 	nop                                            <== NOT EXECUTED
        _Objects_Put( &the_thread->Object );                          
        return RTEMS_NO_MEMORY;                                       
40009e00:	10 80 00 0d 	b  40009e34 <rtems_task_variable_add+0xa4>     <== NOT EXECUTED
40009e04:	82 10 20 1a 	mov  0x1a, %g1	! 1a <_TLS_Alignment+0x19>      <== NOT EXECUTED
      }                                                               
      new->gval = *ptr;                                               
      new->ptr = ptr;                                                 
40009e08:	f2 22 20 04 	st  %i1, [ %o0 + 4 ]                           
         _Workspace_Allocate(sizeof(rtems_task_variable_t));          
      if (new == NULL) {                                              
        _Objects_Put( &the_thread->Object );                          
        return RTEMS_NO_MEMORY;                                       
      }                                                               
      new->gval = *ptr;                                               
40009e0c:	c4 22 20 08 	st  %g2, [ %o0 + 8 ]                           
      new->ptr = ptr;                                                 
      new->dtor = dtor;                                               
                                                                      
      new->next = (struct rtems_task_variable_tt *)the_thread->task_variables;
40009e10:	c4 07 61 34 	ld  [ %i5 + 0x134 ], %g2                       
        _Objects_Put( &the_thread->Object );                          
        return RTEMS_NO_MEMORY;                                       
      }                                                               
      new->gval = *ptr;                                               
      new->ptr = ptr;                                                 
      new->dtor = dtor;                                               
40009e14:	f4 22 20 10 	st  %i2, [ %o0 + 0x10 ]                        
                                                                      
      new->next = (struct rtems_task_variable_tt *)the_thread->task_variables;
40009e18:	c4 22 00 00 	st  %g2, [ %o0 ]                               
      the_thread->task_variables = new;                               
40009e1c:	d0 27 61 34 	st  %o0, [ %i5 + 0x134 ]                       
40009e20:	40 00 09 a3 	call  4000c4ac <_Thread_Enable_dispatch>       
40009e24:	01 00 00 00 	nop                                            
      _Objects_Put( &the_thread->Object );                            
      return RTEMS_SUCCESSFUL;                                        
40009e28:	10 80 00 03 	b  40009e34 <rtems_task_variable_add+0xa4>     
40009e2c:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
#endif                                                                
                                                                      
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
  return RTEMS_INVALID_ID;                                            
40009e30:	82 10 20 04 	mov  4, %g1                                    <== NOT EXECUTED
}                                                                     
40009e34:	81 c7 e0 08 	ret                                            
40009e38:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

400053e0 <rtems_termios_close>: rtems_termios_interrupt_lock_release (tty, &lock_context); } rtems_status_code rtems_termios_close (void *arg) {
400053e0:	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(                                        
400053e4:	39 10 00 60 	sethi  %hi(0x40018000), %i4                    
                                                                      
rtems_status_code                                                     
rtems_termios_close (void *arg)                                       
{                                                                     
  rtems_libio_open_close_args_t *args = arg;                          
  struct rtems_termios_tty *tty = args->iop->data1;                   
400053e8:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  rtems_status_code sc;                                               
                                                                      
  sc = rtems_semaphore_obtain(                                        
400053ec:	d0 07 23 70 	ld  [ %i4 + 0x370 ], %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;                   
400053f0:	fa 00 60 30 	ld  [ %g1 + 0x30 ], %i5                        
  rtems_status_code sc;                                               
                                                                      
  sc = rtems_semaphore_obtain(                                        
400053f4:	92 10 20 00 	clr  %o1                                       
400053f8:	40 00 08 9a 	call  40007660 <rtems_semaphore_obtain>        
400053fc:	94 10 20 00 	clr  %o2                                       
    rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);            
  if (sc != RTEMS_SUCCESSFUL)                                         
40005400:	80 a2 20 00 	cmp  %o0, 0                                    
40005404:	12 80 00 32 	bne  400054cc <rtems_termios_close+0xec>       <== NEVER TAKEN
40005408:	01 00 00 00 	nop                                            
    rtems_fatal_error_occurred (sc);                                  
  if (--tty->refcount == 0) {                                         
4000540c:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
40005410:	82 00 7f ff 	add  %g1, -1, %g1                              
40005414:	80 a0 60 00 	cmp  %g1, 0                                    
40005418:	12 80 00 64 	bne  400055a8 <rtems_termios_close+0x1c8>      
4000541c:	c2 27 60 08 	st  %g1, [ %i5 + 8 ]                           
    if (rtems_termios_linesw[tty->t_line].l_close != NULL) {          
40005420:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        
40005424:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
40005428:	85 28 a0 05 	sll  %g2, 5, %g2                               
4000542c:	82 10 61 7c 	or  %g1, 0x17c, %g1                            
40005430:	82 00 40 02 	add  %g1, %g2, %g1                             
40005434:	c2 00 60 04 	ld  [ %g1 + 4 ], %g1                           
40005438:	80 a0 60 00 	cmp  %g1, 0                                    
4000543c:	22 80 00 06 	be,a   40005454 <rtems_termios_close+0x74>     
40005440:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
      /*                                                              
       * call discipline-specific close                               
       */                                                             
      sc = rtems_termios_linesw[tty->t_line].l_close(tty);            
40005444:	9f c0 40 00 	call  %g1                                      
40005448:	90 10 00 1d 	mov  %i5, %o0                                  
4000544c:	10 80 00 11 	b  40005490 <rtems_termios_close+0xb0>         
40005450:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
    } else {                                                          
      /*                                                              
       * default: just flush output buffer                            
       */                                                             
      sc = rtems_semaphore_obtain(tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
40005454:	92 10 20 00 	clr  %o1                                       
40005458:	40 00 08 82 	call  40007660 <rtems_semaphore_obtain>        
4000545c:	94 10 20 00 	clr  %o2                                       
      if (sc != RTEMS_SUCCESSFUL) {                                   
40005460:	80 a2 20 00 	cmp  %o0, 0                                    
40005464:	12 80 00 1a 	bne  400054cc <rtems_termios_close+0xec>       <== NEVER TAKEN
40005468:	01 00 00 00 	nop                                            
drainOutput (struct rtems_termios_tty *tty)                           
{                                                                     
  rtems_interrupt_lock_context lock_context;                          
  rtems_status_code sc;                                               
                                                                      
  if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {           
4000546c:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40005470:	80 a0 60 00 	cmp  %g1, 0                                    
40005474:	02 80 00 04 	be  40005484 <rtems_termios_close+0xa4>        
40005478:	01 00 00 00 	nop                                            
4000547c:	7f ff fe b7 	call  40004f58 <drainOutput.part.4>            
40005480:	90 10 00 1d 	mov  %i5, %o0                                  
      sc = rtems_semaphore_obtain(tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
      if (sc != RTEMS_SUCCESSFUL) {                                   
        rtems_fatal_error_occurred (sc);                              
      }                                                               
      drainOutput (tty);                                              
      rtems_semaphore_release (tty->osem);                            
40005484:	40 00 08 bf 	call  40007780 <rtems_semaphore_release>       
40005488:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
    }                                                                 
                                                                      
    if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {    
4000548c:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40005490:	80 a0 60 02 	cmp  %g1, 2                                    
40005494:	32 80 00 10 	bne,a   400054d4 <rtems_termios_close+0xf4>    
40005498:	c2 07 60 9c 	ld  [ %i5 + 0x9c ], %g1                        
      /*                                                              
       * send "terminate" to I/O tasks                                
       */                                                             
      sc = rtems_event_send( tty->rxTaskId, TERMIOS_RX_TERMINATE_EVENT );
4000549c:	d0 07 60 c4 	ld  [ %i5 + 0xc4 ], %o0                        
400054a0:	40 00 07 37 	call  4000717c <rtems_event_send>              
400054a4:	92 10 20 01 	mov  1, %o1                                    
      if (sc != RTEMS_SUCCESSFUL)                                     
400054a8:	80 a2 20 00 	cmp  %o0, 0                                    
400054ac:	12 80 00 08 	bne  400054cc <rtems_termios_close+0xec>       <== NEVER TAKEN
400054b0:	01 00 00 00 	nop                                            
        rtems_fatal_error_occurred (sc);                              
      sc = rtems_event_send( tty->txTaskId, TERMIOS_TX_TERMINATE_EVENT );
400054b4:	d0 07 60 c8 	ld  [ %i5 + 0xc8 ], %o0                        
400054b8:	40 00 07 31 	call  4000717c <rtems_event_send>              
400054bc:	92 10 20 01 	mov  1, %o1                                    
      if (sc != RTEMS_SUCCESSFUL)                                     
400054c0:	80 a2 20 00 	cmp  %o0, 0                                    
400054c4:	22 80 00 04 	be,a   400054d4 <rtems_termios_close+0xf4>     <== ALWAYS TAKEN
400054c8:	c2 07 60 9c 	ld  [ %i5 + 0x9c ], %g1                        
        rtems_fatal_error_occurred (sc);                              
400054cc:	40 00 0a 2e 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
400054d0:	01 00 00 00 	nop                                            <== NOT EXECUTED
    }                                                                 
    if (tty->device.lastClose)                                        
400054d4:	80 a0 60 00 	cmp  %g1, 0                                    
400054d8:	22 80 00 07 	be,a   400054f4 <rtems_termios_close+0x114>    <== ALWAYS TAKEN
400054dc:	c4 07 40 00 	ld  [ %i5 ], %g2                               
       (*tty->device.lastClose)(tty->major, tty->minor, arg);         
400054e0:	d0 07 60 0c 	ld  [ %i5 + 0xc ], %o0                         <== NOT EXECUTED
400054e4:	d2 07 60 10 	ld  [ %i5 + 0x10 ], %o1                        <== NOT EXECUTED
400054e8:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
400054ec:	94 10 00 18 	mov  %i0, %o2                                  <== NOT EXECUTED
    if (tty->forw == NULL) {                                          
400054f0:	c4 07 40 00 	ld  [ %i5 ], %g2                               <== NOT EXECUTED
400054f4:	80 a0 a0 00 	cmp  %g2, 0                                    
400054f8:	12 80 00 08 	bne  40005518 <rtems_termios_close+0x138>      
400054fc:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
      rtems_termios_ttyTail = tty->back;                              
40005500:	05 10 00 60 	sethi  %hi(0x40018000), %g2                    
      if ( rtems_termios_ttyTail != NULL ) {                          
40005504:	80 a0 60 00 	cmp  %g1, 0                                    
40005508:	02 80 00 05 	be  4000551c <rtems_termios_close+0x13c>       <== ALWAYS TAKEN
4000550c:	c2 20 a3 74 	st  %g1, [ %g2 + 0x374 ]                       
        rtems_termios_ttyTail->forw = NULL;                           
40005510:	10 80 00 03 	b  4000551c <rtems_termios_close+0x13c>        <== NOT EXECUTED
40005514:	c0 20 40 00 	clr  [ %g1 ]                                   <== NOT EXECUTED
      }                                                               
    } else {                                                          
      tty->forw->back = tty->back;                                    
40005518:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]                           
    }                                                                 
                                                                      
    if (tty->back == NULL) {                                          
4000551c:	c4 07 60 04 	ld  [ %i5 + 4 ], %g2                           
40005520:	80 a0 a0 00 	cmp  %g2, 0                                    
40005524:	12 80 00 08 	bne  40005544 <rtems_termios_close+0x164>      <== NEVER TAKEN
40005528:	c2 07 40 00 	ld  [ %i5 ], %g1                               
      rtems_termios_ttyHead = tty->forw;                              
4000552c:	05 10 00 60 	sethi  %hi(0x40018000), %g2                    
      if ( rtems_termios_ttyHead != NULL ) {                          
40005530:	80 a0 60 00 	cmp  %g1, 0                                    
40005534:	02 80 00 05 	be  40005548 <rtems_termios_close+0x168>       
40005538:	c2 20 a3 78 	st  %g1, [ %g2 + 0x378 ]                       
        rtems_termios_ttyHead->back = NULL;                           
4000553c:	10 80 00 03 	b  40005548 <rtems_termios_close+0x168>        
40005540:	c0 20 60 04 	clr  [ %g1 + 4 ]                               
      }                                                               
    } else {                                                          
      tty->back->forw = tty->forw;                                    
40005544:	c2 20 80 00 	st  %g1, [ %g2 ]                               <== NOT EXECUTED
    }                                                                 
                                                                      
    rtems_semaphore_delete (tty->isem);                               
40005548:	40 00 08 0e 	call  40007580 <rtems_semaphore_delete>        
4000554c:	d0 07 60 14 	ld  [ %i5 + 0x14 ], %o0                        
    rtems_semaphore_delete (tty->osem);                               
40005550:	40 00 08 0c 	call  40007580 <rtems_semaphore_delete>        
40005554:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
    rtems_semaphore_delete (tty->rawOutBuf.Semaphore);                
40005558:	40 00 08 0a 	call  40007580 <rtems_semaphore_delete>        
4000555c:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        
    if ((tty->device.pollRead == NULL) ||                             
40005560:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
40005564:	80 a0 60 00 	cmp  %g1, 0                                    
40005568:	02 80 00 06 	be  40005580 <rtems_termios_close+0x1a0>       
4000556c:	01 00 00 00 	nop                                            
40005570:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40005574:	80 a0 60 02 	cmp  %g1, 2                                    
40005578:	12 80 00 04 	bne  40005588 <rtems_termios_close+0x1a8>      
4000557c:	01 00 00 00 	nop                                            
        (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN))    
      rtems_semaphore_delete (tty->rawInBuf.Semaphore);               
40005580:	40 00 08 00 	call  40007580 <rtems_semaphore_delete>        
40005584:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        
    rtems_interrupt_lock_destroy (&tty->interrupt_lock);              
    free (tty->rawInBuf.theBuf);                                      
40005588:	7f ff f8 a1 	call  4000380c <free>                          
4000558c:	d0 07 60 58 	ld  [ %i5 + 0x58 ], %o0                        
    free (tty->rawOutBuf.theBuf);                                     
40005590:	7f ff f8 9f 	call  4000380c <free>                          
40005594:	d0 07 60 7c 	ld  [ %i5 + 0x7c ], %o0                        
    free (tty->cbuf);                                                 
40005598:	7f ff f8 9d 	call  4000380c <free>                          
4000559c:	d0 07 60 1c 	ld  [ %i5 + 0x1c ], %o0                        
    free (tty);                                                       
400055a0:	7f ff f8 9b 	call  4000380c <free>                          
400055a4:	90 10 00 1d 	mov  %i5, %o0                                  
  }                                                                   
  rtems_semaphore_release (rtems_termios_ttyMutex);                   
400055a8:	d0 07 23 70 	ld  [ %i4 + 0x370 ], %o0                       
400055ac:	40 00 08 75 	call  40007780 <rtems_semaphore_release>       
400055b0:	b0 10 20 00 	clr  %i0                                       
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
400055b4:	81 c7 e0 08 	ret                                            
400055b8:	81 e8 00 00 	restore                                        
                                                                      

40006e34 <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) {
40006e34:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_status_code sc;                                               
                                                                      
  /*                                                                  
   * sum up character count already sent                              
   */                                                                 
  tty->t_dqlen += len;                                                
40006e38:	c2 06 20 90 	ld  [ %i0 + 0x90 ], %g1                        
 * for each transmitted character.                                    
 * It returns number of characters left to transmit                   
 */                                                                   
int                                                                   
rtems_termios_dequeue_characters (void *ttyp, int len)                
{                                                                     
40006e3c:	90 10 00 18 	mov  %i0, %o0                                  
  rtems_status_code sc;                                               
                                                                      
  /*                                                                  
   * sum up character count already sent                              
   */                                                                 
  tty->t_dqlen += len;                                                
40006e40:	b2 00 40 19 	add  %g1, %i1, %i1                             
                                                                      
  if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {      
40006e44:	c2 06 20 b4 	ld  [ %i0 + 0xb4 ], %g1                        
40006e48:	80 a0 60 02 	cmp  %g1, 2                                    
40006e4c:	12 80 00 0a 	bne  40006e74 <rtems_termios_dequeue_characters+0x40>
40006e50:	f2 26 20 90 	st  %i1, [ %i0 + 0x90 ]                        
    /*                                                                
     * send wake up to transmitter task                               
     */                                                               
    sc = rtems_event_send(tty->txTaskId, TERMIOS_TX_START_EVENT);     
40006e54:	d0 06 20 c8 	ld  [ %i0 + 0xc8 ], %o0                        
40006e58:	40 00 02 0e 	call  40007690 <rtems_event_send>              
40006e5c:	92 10 20 02 	mov  2, %o1                                    
    if (sc != RTEMS_SUCCESSFUL)                                       
40006e60:	80 a2 20 00 	cmp  %o0, 0                                    
40006e64:	02 80 00 11 	be  40006ea8 <rtems_termios_dequeue_characters+0x74><== ALWAYS TAKEN
40006e68:	b0 10 20 00 	clr  %i0                                       
      rtems_fatal_error_occurred (sc);                                
40006e6c:	40 00 05 46 	call  40008384 <rtems_fatal_error_occurred>    <== NOT EXECUTED
40006e70:	01 00 00 00 	nop                                            <== NOT EXECUTED
    return 0; /* nothing to output in IRQ... */                       
  }                                                                   
                                                                      
  if (tty->t_line == PPPDISC ) {                                      
40006e74:	c2 06 20 cc 	ld  [ %i0 + 0xcc ], %g1                        
40006e78:	80 a0 60 05 	cmp  %g1, 5                                    
40006e7c:	12 80 00 09 	bne  40006ea0 <rtems_termios_dequeue_characters+0x6c>
40006e80:	03 10 00 8f 	sethi  %hi(0x40023c00), %g1                    
    /*                                                                
     * call any line discipline start function                        
     */                                                               
    if (rtems_termios_linesw[tty->t_line].l_start != NULL) {          
40006e84:	c2 00 61 a0 	ld  [ %g1 + 0x1a0 ], %g1	! 40023da0 <rtems_termios_linesw+0xb4>
40006e88:	80 a0 60 00 	cmp  %g1, 0                                    
40006e8c:	02 80 00 07 	be  40006ea8 <rtems_termios_dequeue_characters+0x74><== NEVER TAKEN
40006e90:	b0 10 20 00 	clr  %i0                                       
      rtems_termios_linesw[tty->t_line].l_start(tty);                 
40006e94:	9f c0 40 00 	call  %g1                                      
40006e98:	01 00 00 00 	nop                                            
40006e9c:	30 80 00 03 	b,a   40006ea8 <rtems_termios_dequeue_characters+0x74>
    }                                                                 
    return 0; /* nothing to output in IRQ... */                       
  }                                                                   
                                                                      
  return rtems_termios_refill_transmitter(tty);                       
40006ea0:	7f ff f8 bd 	call  40005194 <rtems_termios_refill_transmitter>
40006ea4:	81 e8 00 00 	restore                                        
}                                                                     
40006ea8:	81 c7 e0 08 	ret                                            
40006eac:	81 e8 00 00 	restore                                        
                                                                      

40006630 <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, const char *buf, int len) {
40006630:	9d e3 bf 98 	save  %sp, -104, %sp                           
  char c;                                                             
  int dropped = 0;                                                    
  bool flow_rcv = false; /* true, if flow control char received */    
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  if (rtems_termios_linesw[tty->t_line].l_rint != NULL) {             
40006634:	c4 06 20 cc 	ld  [ %i0 + 0xcc ], %g2                        
40006638:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
4000663c:	85 28 a0 05 	sll  %g2, 5, %g2                               
40006640:	82 10 61 7c 	or  %g1, 0x17c, %g1                            
40006644:	84 00 40 02 	add  %g1, %g2, %g2                             
40006648:	c4 00 a0 10 	ld  [ %g2 + 0x10 ], %g2                        
 *       device receive interrupt handler.                            
 * Returns the number of characters dropped because of overflow.      
 */                                                                   
int                                                                   
rtems_termios_enqueue_raw_characters (void *ttyp, const char *buf, int len)
{                                                                     
4000664c:	ba 10 00 18 	mov  %i0, %i5                                  
  char c;                                                             
  int dropped = 0;                                                    
  bool flow_rcv = false; /* true, if flow control char received */    
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  if (rtems_termios_linesw[tty->t_line].l_rint != NULL) {             
40006650:	80 a0 a0 00 	cmp  %g2, 0                                    
40006654:	b8 10 00 01 	mov  %g1, %i4                                  
40006658:	12 80 00 07 	bne  40006674 <rtems_termios_enqueue_raw_characters+0x44>
4000665c:	b4 06 40 1a 	add  %i1, %i2, %i2                             
40006660:	b6 10 20 00 	clr  %i3                                       
40006664:	b0 10 20 00 	clr  %i0                                       
                                                                      
        /*                                                            
         * 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); 
40006668:	a2 07 60 30 	add  %i5, 0x30, %l1                            
              (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,                          
                (void *)&(tty->termios.c_cc[VSTOP]), 1);              
4000666c:	10 80 00 34 	b  4000673c <rtems_termios_enqueue_raw_characters+0x10c>
40006670:	a4 07 60 4a 	add  %i5, 0x4a, %l2                            
  int dropped = 0;                                                    
  bool flow_rcv = false; /* true, if flow control char received */    
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  if (rtems_termios_linesw[tty->t_line].l_rint != NULL) {             
    while (len--) {                                                   
40006674:	80 a6 40 1a 	cmp  %i1, %i2                                  
40006678:	02 80 00 0b 	be  400066a4 <rtems_termios_enqueue_raw_characters+0x74>
4000667c:	b2 06 60 01 	inc  %i1                                       
      c = *buf++;                                                     
      rtems_termios_linesw[tty->t_line].l_rint(c,tty);                
40006680:	c2 07 60 cc 	ld  [ %i5 + 0xcc ], %g1                        
40006684:	83 28 60 05 	sll  %g1, 5, %g1                               
40006688:	d0 4e 7f ff 	ldsb  [ %i1 + -1 ], %o0                        
4000668c:	82 07 00 01 	add  %i4, %g1, %g1                             
40006690:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
40006694:	9f c0 40 00 	call  %g1                                      
40006698:	92 10 00 1d 	mov  %i5, %o1                                  
  int dropped = 0;                                                    
  bool flow_rcv = false; /* true, if flow control char received */    
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  if (rtems_termios_linesw[tty->t_line].l_rint != NULL) {             
    while (len--) {                                                   
4000669c:	10 bf ff f7 	b  40006678 <rtems_termios_enqueue_raw_characters+0x48>
400066a0:	80 a6 40 1a 	cmp  %i1, %i2                                  
    }                                                                 
                                                                      
    /*                                                                
     * check to see if rcv wakeup callback was set                    
     */                                                               
    if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) { 
400066a4:	f0 07 60 e4 	ld  [ %i5 + 0xe4 ], %i0                        
400066a8:	80 a6 20 00 	cmp  %i0, 0                                    
400066ac:	32 80 00 0b 	bne,a   400066d8 <rtems_termios_enqueue_raw_characters+0xa8><== NEVER TAKEN
400066b0:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
400066b4:	c2 07 60 dc 	ld  [ %i5 + 0xdc ], %g1                        
400066b8:	80 a0 60 00 	cmp  %g1, 0                                    
400066bc:	02 80 00 9c 	be  4000692c <rtems_termios_enqueue_raw_characters+0x2fc>
400066c0:	01 00 00 00 	nop                                            
      (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);     
400066c4:	d2 07 60 e0 	ld  [ %i5 + 0xe0 ], %o1                        
400066c8:	9f c0 40 00 	call  %g1                                      
400066cc:	90 07 60 30 	add  %i5, 0x30, %o0                            
      tty->tty_rcvwakeup = 1;                                         
400066d0:	82 10 20 01 	mov  1, %g1                                    
400066d4:	c2 27 60 e4 	st  %g1, [ %i5 + 0xe4 ]                        
400066d8:	81 c7 e0 08 	ret                                            
400066dc:	81 e8 00 00 	restore                                        
                                                                      
  while (len--) {                                                     
    c = *buf++;                                                       
    /* FIXME: implement IXANY: any character restarts output */       
    /* if incoming XON/XOFF controls outgoing stream: */              
    if (tty->flow_ctrl & FL_MDXON) {                                  
400066e0:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
        }                                                             
    return 0;                                                         
  }                                                                   
                                                                      
  while (len--) {                                                     
    c = *buf++;                                                       
400066e4:	b2 06 60 01 	inc  %i1                                       
    /* FIXME: implement IXANY: any character restarts output */       
    /* if incoming XON/XOFF controls outgoing stream: */              
    if (tty->flow_ctrl & FL_MDXON) {                                  
400066e8:	80 88 62 00 	btst  0x200, %g1                               
400066ec:	02 80 00 1f 	be  40006768 <rtems_termios_enqueue_raw_characters+0x138>
400066f0:	e0 0e 7f ff 	ldub  [ %i1 + -1 ], %l0                        
      /* if received char is V_STOP and V_START (both are equal value) */
      if (c == tty->termios.c_cc[VSTOP]) {                            
400066f4:	c4 0f 60 4a 	ldub  [ %i5 + 0x4a ], %g2                      
400066f8:	83 2c 20 18 	sll  %l0, 0x18, %g1                            
400066fc:	83 38 60 18 	sra  %g1, 0x18, %g1                            
40006700:	80 a0 40 02 	cmp  %g1, %g2                                  
40006704:	c4 0f 60 49 	ldub  [ %i5 + 0x49 ], %g2                      
40006708:	12 80 00 12 	bne  40006750 <rtems_termios_enqueue_raw_characters+0x120>
4000670c:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
        if (c == tty->termios.c_cc[VSTART]) {                         
40006710:	80 a0 40 02 	cmp  %g1, %g2                                  
          /* received VSTOP and VSTART==VSTOP? */                     
          /* then toggle "stop output" status  */                     
          tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;               
40006714:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
    /* 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]) {                         
40006718:	32 80 00 03 	bne,a   40006724 <rtems_termios_enqueue_raw_characters+0xf4><== ALWAYS TAKEN
4000671c:	82 10 60 10 	or  %g1, 0x10, %g1                             
          /* received VSTOP and VSTART==VSTOP? */                     
          /* then toggle "stop output" status  */                     
          tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;               
40006720:	82 18 60 10 	xor  %g1, 0x10, %g1                            <== NOT EXECUTED
        flow_rcv = true;                                              
      }                                                               
      else if (c == tty->termios.c_cc[VSTART]) {                      
        /* VSTART received */                                         
        /* restart output  */                                         
        tty->flow_ctrl &= ~FL_ORCVXOF;                                
40006724:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        
        flow_rcv = true;                                              
      }                                                               
    }                                                                 
    if (flow_rcv) {                                                   
      /* restart output according to FL_ORCVXOF flag */               
      if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) {   
40006728:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
4000672c:	82 08 60 30 	and  %g1, 0x30, %g1                            
40006730:	80 a0 60 20 	cmp  %g1, 0x20                                 
40006734:	02 80 00 11 	be  40006778 <rtems_termios_enqueue_raw_characters+0x148><== NEVER TAKEN
40006738:	b6 10 20 01 	mov  1, %i3                                    
      tty->tty_rcvwakeup = 1;                                         
        }                                                             
    return 0;                                                         
  }                                                                   
                                                                      
  while (len--) {                                                     
4000673c:	80 a6 40 1a 	cmp  %i1, %i2                                  
40006740:	12 bf ff e8 	bne  400066e0 <rtems_termios_enqueue_raw_characters+0xb0>
40006744:	01 00 00 00 	nop                                            
40006748:	10 80 00 73 	b  40006914 <rtems_termios_enqueue_raw_characters+0x2e4>
4000674c:	c2 07 60 78 	ld  [ %i5 + 0x78 ], %g1                        
          /* stop output                             */               
          tty->flow_ctrl |= FL_ORCVXOF;                               
        }                                                             
        flow_rcv = true;                                              
      }                                                               
      else if (c == tty->termios.c_cc[VSTART]) {                      
40006750:	80 a0 40 02 	cmp  %g1, %g2                                  
40006754:	12 80 00 06 	bne  4000676c <rtems_termios_enqueue_raw_characters+0x13c><== ALWAYS TAKEN
40006758:	80 8e e0 ff 	btst  0xff, %i3                                
        /* VSTART received */                                         
        /* restart output  */                                         
        tty->flow_ctrl &= ~FL_ORCVXOF;                                
4000675c:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40006760:	10 bf ff f1 	b  40006724 <rtems_termios_enqueue_raw_characters+0xf4><== NOT EXECUTED
40006764:	82 08 7f ef 	and  %g1, -17, %g1                             <== NOT EXECUTED
        flow_rcv = true;                                              
      }                                                               
    }                                                                 
    if (flow_rcv) {                                                   
40006768:	80 8e e0 ff 	btst  0xff, %i3                                
4000676c:	12 bf ff ef 	bne  40006728 <rtems_termios_enqueue_raw_characters+0xf8><== NEVER TAKEN
40006770:	01 00 00 00 	nop                                            
40006774:	30 80 00 16 	b,a   400067cc <rtems_termios_enqueue_raw_characters+0x19c>
      /* restart output according to FL_ORCVXOF flag */               
      if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) {   
        /* disable interrupts    */                                   
        rtems_termios_interrupt_lock_acquire (tty, &lock_context);    
40006778:	7f ff f9 57 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2><== NOT EXECUTED
4000677c:	90 07 bf fc 	add  %fp, -4, %o0                              <== NOT EXECUTED
        tty->flow_ctrl &= ~FL_OSTOP;                                  
40006780:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40006784:	82 08 7f df 	and  %g1, -33, %g1                             <== NOT EXECUTED
40006788:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
        /* check for chars in output buffer (or rob_state?) */        
        if (tty->rawOutBufState != rob_idle) {                        
4000678c:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        <== NOT EXECUTED
40006790:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40006794:	02 80 00 0a 	be  400067bc <rtems_termios_enqueue_raw_characters+0x18c><== NOT EXECUTED
40006798:	90 07 bf fc 	add  %fp, -4, %o0                              <== NOT EXECUTED
          /* if chars available, call write function... */            
          (*tty->device.write)(                                       
            tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1);
4000679c:	c4 07 60 84 	ld  [ %i5 + 0x84 ], %g2                        <== NOT EXECUTED
        rtems_termios_interrupt_lock_acquire (tty, &lock_context);    
        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)(                                       
400067a0:	d2 07 60 7c 	ld  [ %i5 + 0x7c ], %o1                        <== NOT EXECUTED
400067a4:	c2 07 60 a4 	ld  [ %i5 + 0xa4 ], %g1                        <== NOT EXECUTED
400067a8:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        <== NOT EXECUTED
400067ac:	92 02 40 02 	add  %o1, %g2, %o1                             <== NOT EXECUTED
400067b0:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
400067b4:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
            tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1);
        }                                                             
        /* reenable interrupts */                                     
        rtems_termios_interrupt_lock_release (tty, &lock_context);    
400067b8:	90 07 bf fc 	add  %fp, -4, %o0                              <== NOT EXECUTED
400067bc:	7f ff f9 4c 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3><== NOT EXECUTED
400067c0:	b6 10 20 01 	mov  1, %i3                                    <== NOT EXECUTED
      tty->tty_rcvwakeup = 1;                                         
        }                                                             
    return 0;                                                         
  }                                                                   
                                                                      
  while (len--) {                                                     
400067c4:	10 bf ff df 	b  40006740 <rtems_termios_enqueue_raw_characters+0x110><== NOT EXECUTED
400067c8:	80 a6 40 1a 	cmp  %i1, %i2                                  <== NOT EXECUTED
        }                                                             
        /* reenable interrupts */                                     
        rtems_termios_interrupt_lock_release (tty, &lock_context);    
      }                                                               
    } else {                                                          
      newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;        
400067cc:	d0 07 60 60 	ld  [ %i5 + 0x60 ], %o0                        
400067d0:	d2 07 60 64 	ld  [ %i5 + 0x64 ], %o1                        
400067d4:	40 00 33 ed 	call  40013788 <.urem>                         
400067d8:	90 02 20 01 	inc  %o0                                       
400067dc:	b8 10 00 08 	mov  %o0, %i4                                  
      /* if chars_in_buffer > highwater                */             
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
400067e0:	7f ff f9 3d 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
400067e4:	90 07 bf fc 	add  %fp, -4, %o0                              
      if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)       
400067e8:	c2 07 60 5c 	ld  [ %i5 + 0x5c ], %g1                        
400067ec:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        
            % tty->rawInBuf.Size) > tty->highwater) &&                
400067f0:	d2 07 60 64 	ld  [ %i5 + 0x64 ], %o1                        
      }                                                               
    } else {                                                          
      newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;        
      /* if chars_in_buffer > highwater                */             
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
      if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)       
400067f4:	90 22 00 01 	sub  %o0, %g1, %o0                             
            % tty->rawInBuf.Size) > tty->highwater) &&                
400067f8:	40 00 33 e4 	call  40013788 <.urem>                         
400067fc:	90 02 00 1c 	add  %o0, %i4, %o0                             
      }                                                               
    } else {                                                          
      newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;        
      /* if chars_in_buffer > highwater                */             
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
      if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)       
40006800:	c2 07 60 c0 	ld  [ %i5 + 0xc0 ], %g1                        
40006804:	80 a2 00 01 	cmp  %o0, %g1                                  
40006808:	08 80 00 2b 	bleu  400068b4 <rtems_termios_enqueue_raw_characters+0x284><== ALWAYS TAKEN
4000680c:	01 00 00 00 	nop                                            
            % tty->rawInBuf.Size) > tty->highwater) &&                
          !(tty->flow_ctrl & FL_IREQXOF)) {                           
40006810:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
    } else {                                                          
      newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;        
      /* if chars_in_buffer > highwater                */             
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
      if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)       
            % tty->rawInBuf.Size) > tty->highwater) &&                
40006814:	80 88 60 01 	btst  1, %g1                                   <== NOT EXECUTED
40006818:	12 80 00 27 	bne  400068b4 <rtems_termios_enqueue_raw_characters+0x284><== NOT EXECUTED
4000681c:	01 00 00 00 	nop                                            <== NOT EXECUTED
          !(tty->flow_ctrl & FL_IREQXOF)) {                           
        /* incoming data stream should be stopped */                  
        tty->flow_ctrl |= FL_IREQXOF;                                 
40006820:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40006824:	82 10 60 01 	or  %g1, 1, %g1                                <== NOT EXECUTED
40006828:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
        if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))                
4000682c:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40006830:	82 08 64 02 	and  %g1, 0x402, %g1                           <== NOT EXECUTED
40006834:	80 a0 64 00 	cmp  %g1, 0x400                                <== NOT EXECUTED
            ==                (FL_MDXOF             ) ) {             
          if ((tty->flow_ctrl & FL_OSTOP) ||                          
40006838:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
      if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)       
            % tty->rawInBuf.Size) > tty->highwater) &&                
          !(tty->flow_ctrl & FL_IREQXOF)) {                           
        /* incoming data stream should be stopped */                  
        tty->flow_ctrl |= FL_IREQXOF;                                 
        if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))                
4000683c:	32 80 00 12 	bne,a   40006884 <rtems_termios_enqueue_raw_characters+0x254><== NOT EXECUTED
40006840:	82 08 61 04 	and  %g1, 0x104, %g1                           <== NOT EXECUTED
            ==                (FL_MDXOF             ) ) {             
          if ((tty->flow_ctrl & FL_OSTOP) ||                          
40006844:	80 88 60 20 	btst  0x20, %g1                                <== NOT EXECUTED
40006848:	12 80 00 06 	bne  40006860 <rtems_termios_enqueue_raw_characters+0x230><== NOT EXECUTED
4000684c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40006850:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        <== NOT EXECUTED
40006854:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40006858:	12 80 00 17 	bne  400068b4 <rtems_termios_enqueue_raw_characters+0x284><== NOT EXECUTED
4000685c:	01 00 00 00 	nop                                            <== NOT EXECUTED
              (tty->rawOutBufState == rob_idle)) {                    
            /* if tx is stopped due to XOFF or out of data */         
            /*    call write function here                 */         
            tty->flow_ctrl |= FL_ISNTXOF;                             
40006860:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
            (*tty->device.write)(tty->minor,                          
40006864:	d0 07 60 10 	ld  [ %i5 + 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;                             
40006868:	82 10 60 02 	or  %g1, 2, %g1                                <== NOT EXECUTED
4000686c:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
            (*tty->device.write)(tty->minor,                          
40006870:	c2 07 60 a4 	ld  [ %i5 + 0xa4 ], %g1                        <== NOT EXECUTED
40006874:	92 10 00 12 	mov  %l2, %o1                                  <== NOT EXECUTED
40006878:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
4000687c:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
40006880:	30 80 00 0d 	b,a   400068b4 <rtems_termios_enqueue_raw_characters+0x284><== NOT EXECUTED
                (void *)&(tty->termios.c_cc[VSTOP]), 1);              
          }                                                           
        } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF)) == (FL_MDRTS) ) {
40006884:	80 a0 61 00 	cmp  %g1, 0x100                                <== NOT EXECUTED
40006888:	12 80 00 0b 	bne  400068b4 <rtems_termios_enqueue_raw_characters+0x284><== NOT EXECUTED
4000688c:	01 00 00 00 	nop                                            <== NOT EXECUTED
          tty->flow_ctrl |= FL_IRTSOFF;                               
40006890:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40006894:	82 10 60 04 	or  %g1, 4, %g1                                <== NOT EXECUTED
40006898:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
          /* deactivate RTS line */                                   
          if (tty->device.stopRemoteTx != NULL) {                     
4000689c:	c2 07 60 ac 	ld  [ %i5 + 0xac ], %g1                        <== NOT EXECUTED
400068a0:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
400068a4:	02 80 00 04 	be  400068b4 <rtems_termios_enqueue_raw_characters+0x284><== NOT EXECUTED
400068a8:	01 00 00 00 	nop                                            <== NOT EXECUTED
            tty->device.stopRemoteTx(tty->minor);                     
400068ac:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
400068b0:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        <== NOT EXECUTED
          }                                                           
        }                                                             
      }                                                               
                                                                      
      /* reenable interrupts */                                       
      rtems_termios_interrupt_lock_release (tty, &lock_context);      
400068b4:	7f ff f9 0e 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
400068b8:	90 07 bf fc 	add  %fp, -4, %o0                              
                                                                      
      if (newTail == tty->rawInBuf.Head) {                            
400068bc:	c2 07 60 5c 	ld  [ %i5 + 0x5c ], %g1                        
400068c0:	80 a7 00 01 	cmp  %i4, %g1                                  
400068c4:	32 80 00 04 	bne,a   400068d4 <rtems_termios_enqueue_raw_characters+0x2a4><== ALWAYS TAKEN
400068c8:	c2 07 60 58 	ld  [ %i5 + 0x58 ], %g1                        
400068cc:	10 bf ff 9c 	b  4000673c <rtems_termios_enqueue_raw_characters+0x10c><== NOT EXECUTED
400068d0:	b0 06 20 01 	inc  %i0                                       <== NOT EXECUTED
        dropped++;                                                    
      } else {                                                        
        tty->rawInBuf.theBuf[newTail] = c;                            
400068d4:	e0 28 40 1c 	stb  %l0, [ %g1 + %i4 ]                        
        tty->rawInBuf.Tail = newTail;                                 
                                                                      
        /*                                                            
         * check to see if rcv wakeup callback was set                
         */                                                           
        if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
400068d8:	c2 07 60 e4 	ld  [ %i5 + 0xe4 ], %g1                        
                                                                      
      if (newTail == tty->rawInBuf.Head) {                            
        dropped++;                                                    
      } else {                                                        
        tty->rawInBuf.theBuf[newTail] = c;                            
        tty->rawInBuf.Tail = newTail;                                 
400068dc:	f8 27 60 60 	st  %i4, [ %i5 + 0x60 ]                        
                                                                      
        /*                                                            
         * check to see if rcv wakeup callback was set                
         */                                                           
        if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
400068e0:	80 a0 60 00 	cmp  %g1, 0                                    
400068e4:	12 bf ff 97 	bne  40006740 <rtems_termios_enqueue_raw_characters+0x110><== NEVER TAKEN
400068e8:	80 a6 40 1a 	cmp  %i1, %i2                                  
400068ec:	c2 07 60 dc 	ld  [ %i5 + 0xdc ], %g1                        
400068f0:	80 a0 60 00 	cmp  %g1, 0                                    
400068f4:	02 bf ff 93 	be  40006740 <rtems_termios_enqueue_raw_characters+0x110><== ALWAYS TAKEN
400068f8:	80 a6 40 1a 	cmp  %i1, %i2                                  
          (*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg); 
400068fc:	d2 07 60 e0 	ld  [ %i5 + 0xe0 ], %o1                        <== NOT EXECUTED
40006900:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40006904:	90 10 00 11 	mov  %l1, %o0                                  <== NOT EXECUTED
          tty->tty_rcvwakeup = 1;                                     
40006908:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
4000690c:	10 bf ff 8c 	b  4000673c <rtems_termios_enqueue_raw_characters+0x10c><== NOT EXECUTED
40006910:	c2 27 60 e4 	st  %g1, [ %i5 + 0xe4 ]                        <== NOT EXECUTED
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  tty->rawInBufDropped += dropped;                                    
  rtems_semaphore_release (tty->rawInBuf.Semaphore);                  
40006914:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        
        }                                                             
      }                                                               
    }                                                                 
  }                                                                   
                                                                      
  tty->rawInBufDropped += dropped;                                    
40006918:	82 00 40 18 	add  %g1, %i0, %g1                             
  rtems_semaphore_release (tty->rawInBuf.Semaphore);                  
4000691c:	40 00 03 99 	call  40007780 <rtems_semaphore_release>       
40006920:	c2 27 60 78 	st  %g1, [ %i5 + 0x78 ]                        
  return dropped;                                                     
40006924:	81 c7 e0 08 	ret                                            
40006928:	81 e8 00 00 	restore                                        
}                                                                     
4000692c:	81 c7 e0 08 	ret                                            
40006930:	81 e8 00 00 	restore                                        
                                                                      

400055bc <rtems_termios_ioctl>: } } rtems_status_code rtems_termios_ioctl (void *arg) {
400055bc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_libio_ioctl_args_t *args = arg;                               
  struct rtems_termios_tty *tty = args->iop->data1;                   
400055c0:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  struct ttywakeup         *wakeup = (struct ttywakeup *)args->buffer;
400055c4:	f6 06 20 08 	ld  [ %i0 + 8 ], %i3                           
                                                                      
rtems_status_code                                                     
rtems_termios_ioctl (void *arg)                                       
{                                                                     
  rtems_libio_ioctl_args_t *args = arg;                               
  struct rtems_termios_tty *tty = args->iop->data1;                   
400055c8:	fa 00 60 30 	ld  [ %g1 + 0x30 ], %i5                        
  }                                                                   
}                                                                     
                                                                      
rtems_status_code                                                     
rtems_termios_ioctl (void *arg)                                       
{                                                                     
400055cc:	b8 10 00 18 	mov  %i0, %i4                                  
  struct rtems_termios_tty *tty = args->iop->data1;                   
  struct ttywakeup         *wakeup = (struct ttywakeup *)args->buffer;
  rtems_status_code sc;                                               
                                                                      
  args->ioctl_return = 0;                                             
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
400055d0:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
  rtems_libio_ioctl_args_t *args = arg;                               
  struct rtems_termios_tty *tty = args->iop->data1;                   
  struct ttywakeup         *wakeup = (struct ttywakeup *)args->buffer;
  rtems_status_code sc;                                               
                                                                      
  args->ioctl_return = 0;                                             
400055d4:	c0 26 20 0c 	clr  [ %i0 + 0xc ]                             
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
400055d8:	92 10 20 00 	clr  %o1                                       
400055dc:	40 00 08 21 	call  40007660 <rtems_semaphore_obtain>        
400055e0:	94 10 20 00 	clr  %o2                                       
  if (sc != RTEMS_SUCCESSFUL) {                                       
400055e4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
400055e8:	12 80 01 16 	bne  40005a40 <rtems_termios_ioctl+0x484>      <== NEVER TAKEN
400055ec:	01 00 00 00 	nop                                            
    return sc;                                                        
  }                                                                   
  switch (args->command) {                                            
400055f0:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
400055f4:	80 a0 60 05 	cmp  %g1, 5                                    
400055f8:	22 80 00 e1 	be,a   4000597c <rtems_termios_ioctl+0x3c0>    
400055fc:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
40005600:	18 80 00 12 	bgu  40005648 <rtems_termios_ioctl+0x8c>       
40005604:	05 10 01 19 	sethi  %hi(0x40046400), %g2                    
40005608:	80 a0 60 02 	cmp  %g1, 2                                    
4000560c:	22 80 00 35 	be,a   400056e0 <rtems_termios_ioctl+0x124>    
40005610:	d2 07 20 08 	ld  [ %i4 + 8 ], %o1                           
40005614:	18 80 00 07 	bgu  40005630 <rtems_termios_ioctl+0x74>       
40005618:	80 a0 60 03 	cmp  %g1, 3                                    
4000561c:	80 a0 60 01 	cmp  %g1, 1                                    
40005620:	22 80 00 2c 	be,a   400056d0 <rtems_termios_ioctl+0x114>    <== ALWAYS TAKEN
40005624:	d0 07 20 08 	ld  [ %i4 + 8 ], %o0                           
  default:                                                            
    if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {          
40005628:	10 80 00 1d 	b  4000569c <rtems_termios_ioctl+0xe0>         <== NOT EXECUTED
4000562c:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        <== NOT EXECUTED
  args->ioctl_return = 0;                                             
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
  switch (args->command) {                                            
40005630:	02 80 00 b0 	be  400058f0 <rtems_termios_ioctl+0x334>       
40005634:	80 a0 60 04 	cmp  %g1, 4                                    
40005638:	22 80 00 d5 	be,a   4000598c <rtems_termios_ioctl+0x3d0>    <== ALWAYS TAKEN
4000563c:	c2 06 c0 00 	ld  [ %i3 ], %g1                               
  default:                                                            
    if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {          
40005640:	10 80 00 17 	b  4000569c <rtems_termios_ioctl+0xe0>         <== NOT EXECUTED
40005644:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        <== NOT EXECUTED
  args->ioctl_return = 0;                                             
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
  switch (args->command) {                                            
40005648:	84 10 a2 7f 	or  %g2, 0x27f, %g2                            
4000564c:	80 a0 40 02 	cmp  %g1, %g2                                  
40005650:	02 80 00 ed 	be  40005a04 <rtems_termios_ioctl+0x448>       <== NEVER TAKEN
40005654:	01 00 00 00 	nop                                            
40005658:	18 80 00 07 	bgu  40005674 <rtems_termios_ioctl+0xb8>       
4000565c:	05 10 01 1d 	sethi  %hi(0x40047400), %g2                    
40005660:	80 a0 60 06 	cmp  %g1, 6                                    
40005664:	22 80 00 aa 	be,a   4000590c <rtems_termios_ioctl+0x350>    
40005668:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           
  default:                                                            
    if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {          
4000566c:	10 80 00 0c 	b  4000569c <rtems_termios_ioctl+0xe0>         
40005670:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        
  args->ioctl_return = 0;                                             
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
  if (sc != RTEMS_SUCCESSFUL) {                                       
    return sc;                                                        
  }                                                                   
  switch (args->command) {                                            
40005674:	84 10 a0 1a 	or  %g2, 0x1a, %g2                             
40005678:	80 a0 40 02 	cmp  %g1, %g2                                  
4000567c:	02 80 00 df 	be  400059f8 <rtems_termios_ioctl+0x43c>       
40005680:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        
40005684:	07 20 01 1d 	sethi  %hi(0x80047400), %g3                    
40005688:	86 10 e0 1b 	or  %g3, 0x1b, %g3	! 8004741b <RAM_END+0x3fc4741b>
4000568c:	80 a0 40 03 	cmp  %g1, %g3                                  
40005690:	02 80 00 c3 	be  4000599c <rtems_termios_ioctl+0x3e0>       <== ALWAYS TAKEN
40005694:	07 10 00 5f 	sethi  %hi(0x40017c00), %g3                    
  default:                                                            
    if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {          
40005698:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        <== NOT EXECUTED
4000569c:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
400056a0:	85 28 a0 05 	sll  %g2, 5, %g2                               
400056a4:	82 10 61 7c 	or  %g1, 0x17c, %g1                            
400056a8:	82 00 40 02 	add  %g1, %g2, %g1                             
400056ac:	c2 00 60 18 	ld  [ %g1 + 0x18 ], %g1                        
400056b0:	80 a0 60 00 	cmp  %g1, 0                                    
400056b4:	02 80 00 e1 	be  40005a38 <rtems_termios_ioctl+0x47c>       <== NEVER TAKEN
400056b8:	b0 10 20 0a 	mov  0xa, %i0                                  
      sc = rtems_termios_linesw[tty->t_line].l_ioctl(tty,args);       
400056bc:	90 10 00 1d 	mov  %i5, %o0                                  
400056c0:	9f c0 40 00 	call  %g1                                      
400056c4:	92 10 00 1c 	mov  %i4, %o1                                  
    tty->t_sc = NULL; /* ensure that no more valid data */            
    /*                                                                
     * open new line discipline                                       
     */                                                               
    if (rtems_termios_linesw[tty->t_line].l_open != NULL) {           
      sc = rtems_termios_linesw[tty->t_line].l_open(tty);             
400056c8:	10 80 00 dc 	b  40005a38 <rtems_termios_ioctl+0x47c>        
400056cc:	b0 10 00 08 	mov  %o0, %i0                                  
      sc = RTEMS_INVALID_NUMBER;                                      
    }                                                                 
    break;                                                            
                                                                      
  case RTEMS_IO_GET_ATTRIBUTES:                                       
    *(struct termios *)args->buffer = tty->termios;                   
400056d0:	92 07 60 30 	add  %i5, 0x30, %o1                            
400056d4:	40 00 2a b9 	call  400101b8 <memcpy>                        
400056d8:	94 10 20 24 	mov  0x24, %o2                                 
    break;                                                            
400056dc:	30 80 00 d7 	b,a   40005a38 <rtems_termios_ioctl+0x47c>     
                                                                      
  case RTEMS_IO_SET_ATTRIBUTES:                                       
    tty->termios = *(struct termios *)args->buffer;                   
400056e0:	b6 07 60 30 	add  %i5, 0x30, %i3                            
400056e4:	94 10 20 24 	mov  0x24, %o2                                 
400056e8:	40 00 2a b4 	call  400101b8 <memcpy>                        
400056ec:	90 10 00 1b 	mov  %i3, %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) &&                                 
400056f0:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
400056f4:	80 88 62 00 	btst  0x200, %g1                               
400056f8:	02 80 00 1f 	be  40005774 <rtems_termios_ioctl+0x1b8>       
400056fc:	01 00 00 00 	nop                                            
      !(tty->termios.c_iflag & IXON)) {                               
40005700:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        
  /*                                                                  
   * check for flow control options to be switched off                
   */                                                                 
                                                                      
  /* check for outgoing XON/XOFF flow control switched off */         
  if (( tty->flow_ctrl & FL_MDXON) &&                                 
40005704:	80 88 64 00 	btst  0x400, %g1                               
40005708:	12 80 00 1b 	bne  40005774 <rtems_termios_ioctl+0x1b8>      
4000570c:	01 00 00 00 	nop                                            
      !(tty->termios.c_iflag & IXON)) {                               
    /* clear related flags in flow_ctrl */                            
    tty->flow_ctrl &= ~(FL_MDXON | FL_ORCVXOF);                       
40005710:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
40005714:	82 08 7d ef 	and  %g1, -529, %g1                            
40005718:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        
                                                                      
    /* has output been stopped due to received XOFF? */               
    if (tty->flow_ctrl & FL_OSTOP) {                                  
4000571c:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
40005720:	80 88 60 20 	btst  0x20, %g1                                
40005724:	02 80 00 14 	be  40005774 <rtems_termios_ioctl+0x1b8>       <== ALWAYS TAKEN
40005728:	01 00 00 00 	nop                                            
      /* disable interrupts    */                                     
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
4000572c:	7f ff fd 6a 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2><== NOT EXECUTED
40005730:	90 07 bf fc 	add  %fp, -4, %o0                              <== NOT EXECUTED
      tty->flow_ctrl &= ~FL_OSTOP;                                    
40005734:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40005738:	82 08 7f df 	and  %g1, -33, %g1                             <== NOT EXECUTED
4000573c:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
      /* check for chars in output buffer (or rob_state?) */          
      if (tty->rawOutBufState != rob_idle) {                          
40005740:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        <== NOT EXECUTED
40005744:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
40005748:	02 80 00 09 	be  4000576c <rtems_termios_ioctl+0x1b0>       <== NOT EXECUTED
4000574c:	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); 
40005750:	c4 07 60 84 	ld  [ %i5 + 0x84 ], %g2                        <== NOT EXECUTED
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
      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)(                                         
40005754:	d2 07 60 7c 	ld  [ %i5 + 0x7c ], %o1                        <== NOT EXECUTED
40005758:	c2 07 60 a4 	ld  [ %i5 + 0xa4 ], %g1                        <== NOT EXECUTED
4000575c:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        <== NOT EXECUTED
40005760:	92 02 40 02 	add  %o1, %g2, %o1                             <== NOT EXECUTED
40005764:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40005768:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
          tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); 
      }                                                               
      /* reenable interrupts */                                       
      rtems_termios_interrupt_lock_release (tty, &lock_context);      
4000576c:	7f ff fd 60 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3><== NOT EXECUTED
40005770:	90 07 bf fc 	add  %fp, -4, %o0                              <== NOT EXECUTED
    }                                                                 
  }                                                                   
  /* check for incoming XON/XOFF flow control switched off */         
  if (( tty->flow_ctrl & FL_MDXOF) && !(tty->termios.c_iflag & IXOFF)) {
40005774:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
40005778:	80 88 64 00 	btst  0x400, %g1                               
4000577c:	02 80 00 0c 	be  400057ac <rtems_termios_ioctl+0x1f0>       
40005780:	03 00 00 04 	sethi  %hi(0x1000), %g1                        
40005784:	c4 07 60 30 	ld  [ %i5 + 0x30 ], %g2                        
40005788:	80 88 80 01 	btst  %g2, %g1                                 
4000578c:	12 80 00 08 	bne  400057ac <rtems_termios_ioctl+0x1f0>      <== NEVER TAKEN
40005790:	01 00 00 00 	nop                                            
    /* clear related flags in flow_ctrl */                            
    tty->flow_ctrl &= ~(FL_MDXOF);                                    
40005794:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
40005798:	82 08 7b ff 	and  %g1, -1025, %g1                           
4000579c:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        
    /* FIXME: what happens, if we had sent XOFF but not yet XON? */   
    tty->flow_ctrl &= ~(FL_ISNTXOF);                                  
400057a0:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
400057a4:	82 08 7f fd 	and  %g1, -3, %g1                              
400057a8:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        
  }                                                                   
                                                                      
  /* check for incoming RTS/CTS flow control switched off */          
  if (( tty->flow_ctrl & FL_MDRTS) && !(tty->termios.c_cflag & CRTSCTS)) {
400057ac:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
400057b0:	80 88 61 00 	btst  0x100, %g1                               
400057b4:	02 80 00 16 	be  4000580c <rtems_termios_ioctl+0x250>       <== ALWAYS TAKEN
400057b8:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        
400057bc:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
400057c0:	06 80 00 14 	bl  40005810 <rtems_termios_ioctl+0x254>       <== NOT EXECUTED
400057c4:	01 00 00 00 	nop                                            <== NOT EXECUTED
    /* clear related flags in flow_ctrl */                            
    tty->flow_ctrl &= ~(FL_MDRTS);                                    
400057c8:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
400057cc:	82 08 7e ff 	and  %g1, -257, %g1                            <== NOT EXECUTED
400057d0:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
                                                                      
    /* restart remote Tx, if it was stopped */                        
    if ((tty->flow_ctrl & FL_IRTSOFF) && (tty->device.startRemoteTx != NULL)) {
400057d4:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
400057d8:	80 88 60 04 	btst  4, %g1                                   <== NOT EXECUTED
400057dc:	02 80 00 08 	be  400057fc <rtems_termios_ioctl+0x240>       <== NOT EXECUTED
400057e0:	01 00 00 00 	nop                                            <== NOT EXECUTED
400057e4:	c2 07 60 b0 	ld  [ %i5 + 0xb0 ], %g1                        <== NOT EXECUTED
400057e8:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
400057ec:	02 80 00 04 	be  400057fc <rtems_termios_ioctl+0x240>       <== NOT EXECUTED
400057f0:	01 00 00 00 	nop                                            <== NOT EXECUTED
      tty->device.startRemoteTx(tty->minor);                          
400057f4:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
400057f8:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        <== NOT EXECUTED
    }                                                                 
    tty->flow_ctrl &= ~(FL_IRTSOFF);                                  
400057fc:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40005800:	82 08 7f fb 	and  %g1, -5, %g1                              <== NOT EXECUTED
40005804:	c2 27 60 b8 	st  %g1, [ %i5 + 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) {                               
40005808:	c2 07 60 38 	ld  [ %i5 + 0x38 ], %g1                        <== NOT EXECUTED
4000580c:	80 a0 60 00 	cmp  %g1, 0                                    
40005810:	36 80 00 06 	bge,a   40005828 <rtems_termios_ioctl+0x26c>   <== ALWAYS TAKEN
40005814:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        
    tty->flow_ctrl |= FL_MDRTS;                                       
40005818:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
4000581c:	82 10 61 00 	or  %g1, 0x100, %g1                            <== NOT EXECUTED
40005820:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
  }                                                                   
  /* check for incoming XON/XOF flow control switched on */           
  if (tty->termios.c_iflag & IXOFF) {                                 
40005824:	c2 07 60 30 	ld  [ %i5 + 0x30 ], %g1                        <== NOT EXECUTED
40005828:	05 00 00 04 	sethi  %hi(0x1000), %g2                        
4000582c:	80 88 40 02 	btst  %g1, %g2                                 
40005830:	02 80 00 06 	be  40005848 <rtems_termios_ioctl+0x28c>       
40005834:	80 88 64 00 	btst  0x400, %g1                               
    tty->flow_ctrl |= FL_MDXOF;                                       
40005838:	c4 07 60 b8 	ld  [ %i5 + 0xb8 ], %g2                        
4000583c:	84 10 a4 00 	or  %g2, 0x400, %g2                            
40005840:	c4 27 60 b8 	st  %g2, [ %i5 + 0xb8 ]                        
  }                                                                   
  /* check for outgoing XON/XOF flow control switched on */           
  if (tty->termios.c_iflag & IXON) {                                  
40005844:	80 88 64 00 	btst  0x400, %g1                               
40005848:	22 80 00 06 	be,a   40005860 <rtems_termios_ioctl+0x2a4>    
4000584c:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
    tty->flow_ctrl |= FL_MDXON;                                       
40005850:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
40005854:	82 10 62 00 	or  %g1, 0x200, %g1                            
40005858:	c2 27 60 b8 	st  %g1, [ %i5 + 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) {                              
4000585c:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
40005860:	80 88 60 02 	btst  2, %g1                                   
40005864:	32 80 00 17 	bne,a   400058c0 <rtems_termios_ioctl+0x304>   
40005868:	c0 27 60 6c 	clr  [ %i5 + 0x6c ]                            
      tty->rawInBufSemaphoreOptions = RTEMS_WAIT;                     
      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;          
4000586c:	40 00 05 b5 	call  40006f40 <rtems_clock_get_ticks_per_second>
40005870:	f8 0f 60 46 	ldub  [ %i5 + 0x46 ], %i4                      
    if (tty->termios.c_lflag & ICANON) {                              
      tty->rawInBufSemaphoreOptions = RTEMS_WAIT;                     
      tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;               
      tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;          
    } else {                                                          
      tty->vtimeTicks = tty->termios.c_cc[VTIME] *                    
40005874:	40 00 36 df 	call  400133f0 <.umul>                         
40005878:	92 10 00 1c 	mov  %i4, %o1                                  
                    rtems_clock_get_ticks_per_second() / 10;          
4000587c:	40 00 37 17 	call  400134d8 <.udiv>                         
40005880:	92 10 20 0a 	mov  0xa, %o1                                  
      if (tty->termios.c_cc[VTIME]) {                                 
40005884:	c2 0f 60 46 	ldub  [ %i5 + 0x46 ], %g1                      
    if (tty->termios.c_lflag & ICANON) {                              
      tty->rawInBufSemaphoreOptions = RTEMS_WAIT;                     
      tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;               
      tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;          
    } else {                                                          
      tty->vtimeTicks = tty->termios.c_cc[VTIME] *                    
40005888:	d0 27 60 54 	st  %o0, [ %i5 + 0x54 ]                        
                    rtems_clock_get_ticks_per_second() / 10;          
      if (tty->termios.c_cc[VTIME]) {                                 
4000588c:	80 a0 60 00 	cmp  %g1, 0                                    
40005890:	02 80 00 08 	be  400058b0 <rtems_termios_ioctl+0x2f4>       
40005894:	c2 0f 60 47 	ldub  [ %i5 + 0x47 ], %g1                      
        tty->rawInBufSemaphoreOptions = RTEMS_WAIT;                   
40005898:	c0 27 60 6c 	clr  [ %i5 + 0x6c ]                            
        tty->rawInBufSemaphoreTimeout = tty->vtimeTicks;              
        if (tty->termios.c_cc[VMIN])                                  
4000589c:	80 88 60 ff 	btst  0xff, %g1                                
400058a0:	12 80 00 09 	bne  400058c4 <rtems_termios_ioctl+0x308>      
400058a4:	d0 27 60 70 	st  %o0, [ %i5 + 0x70 ]                        
          tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;      
        else                                                          
          tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks;       
400058a8:	10 80 00 0a 	b  400058d0 <rtems_termios_ioctl+0x314>        
400058ac:	d0 27 60 74 	st  %o0, [ %i5 + 0x74 ]                        
      } else {                                                        
        if (tty->termios.c_cc[VMIN]) {                                
400058b0:	80 88 60 ff 	btst  0xff, %g1                                
400058b4:	02 80 00 06 	be  400058cc <rtems_termios_ioctl+0x310>       <== ALWAYS TAKEN
400058b8:	82 10 20 01 	mov  1, %g1                                    
          tty->rawInBufSemaphoreOptions = RTEMS_WAIT;                 
400058bc:	c0 27 60 6c 	clr  [ %i5 + 0x6c ]                            <== NOT EXECUTED
          tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;           
400058c0:	c0 27 60 70 	clr  [ %i5 + 0x70 ]                            
400058c4:	10 80 00 03 	b  400058d0 <rtems_termios_ioctl+0x314>        
400058c8:	c0 27 60 74 	clr  [ %i5 + 0x74 ]                            
          tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;      
        } else {                                                      
          tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT;              
400058cc:	c2 27 60 6c 	st  %g1, [ %i5 + 0x6c ]                        
        }                                                             
      }                                                               
    }                                                                 
    if (tty->device.setAttributes)                                    
400058d0:	c2 07 60 a8 	ld  [ %i5 + 0xa8 ], %g1                        
400058d4:	80 a0 60 00 	cmp  %g1, 0                                    
400058d8:	02 80 00 58 	be  40005a38 <rtems_termios_ioctl+0x47c>       <== NEVER TAKEN
400058dc:	01 00 00 00 	nop                                            
      (*tty->device.setAttributes)(tty->minor, &tty->termios);        
400058e0:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
400058e4:	9f c0 40 00 	call  %g1                                      
400058e8:	92 10 00 1b 	mov  %i3, %o1                                  
400058ec:	30 80 00 53 	b,a   40005a38 <rtems_termios_ioctl+0x47c>     
drainOutput (struct rtems_termios_tty *tty)                           
{                                                                     
  rtems_interrupt_lock_context lock_context;                          
  rtems_status_code sc;                                               
                                                                      
  if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {           
400058f0:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
400058f4:	80 a0 60 00 	cmp  %g1, 0                                    
400058f8:	02 80 00 50 	be  40005a38 <rtems_termios_ioctl+0x47c>       <== ALWAYS TAKEN
400058fc:	01 00 00 00 	nop                                            
40005900:	7f ff fd 96 	call  40004f58 <drainOutput.part.4>            <== NOT EXECUTED
40005904:	90 10 00 1d 	mov  %i5, %o0                                  <== NOT EXECUTED
40005908:	30 80 00 4c 	b,a   40005a38 <rtems_termios_ioctl+0x47c>     <== NOT EXECUTED
  case RTEMS_IO_TCDRAIN:                                              
    drainOutput (tty);                                                
    break;                                                            
                                                                      
  case RTEMS_IO_TCFLUSH:                                              
    switch ((intptr_t) args->buffer) {                                
4000590c:	80 a0 60 01 	cmp  %g1, 1                                    
40005910:	02 80 00 07 	be  4000592c <rtems_termios_ioctl+0x370>       
40005914:	80 a0 60 02 	cmp  %g1, 2                                    
40005918:	02 80 00 0b 	be  40005944 <rtems_termios_ioctl+0x388>       
4000591c:	80 a0 60 00 	cmp  %g1, 0                                    
40005920:	32 80 00 46 	bne,a   40005a38 <rtems_termios_ioctl+0x47c>   
40005924:	b0 10 20 03 	mov  3, %i0                                    
40005928:	30 80 00 0e 	b,a   40005960 <rtems_termios_ioctl+0x3a4>     
static void                                                           
flushOutput (struct rtems_termios_tty *tty)                           
{                                                                     
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  rtems_termios_interrupt_lock_acquire (tty, &lock_context);          
4000592c:	7f ff fc ea 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
40005930:	90 07 bf fc 	add  %fp, -4, %o0                              
  tty->rawOutBuf.Tail = 0;                                            
40005934:	c0 27 60 84 	clr  [ %i5 + 0x84 ]                            
  tty->rawOutBuf.Head = 0;                                            
40005938:	c0 27 60 80 	clr  [ %i5 + 0x80 ]                            
  tty->rawOutBufState = rob_idle;                                     
4000593c:	10 80 00 0d 	b  40005970 <rtems_termios_ioctl+0x3b4>        
40005940:	c0 27 60 94 	clr  [ %i5 + 0x94 ]                            
static void                                                           
flushOutput (struct rtems_termios_tty *tty)                           
{                                                                     
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  rtems_termios_interrupt_lock_acquire (tty, &lock_context);          
40005944:	7f ff fc e4 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
40005948:	90 07 bf fc 	add  %fp, -4, %o0                              
  tty->rawOutBuf.Tail = 0;                                            
4000594c:	c0 27 60 84 	clr  [ %i5 + 0x84 ]                            
  tty->rawOutBuf.Head = 0;                                            
40005950:	c0 27 60 80 	clr  [ %i5 + 0x80 ]                            
  tty->rawOutBufState = rob_idle;                                     
40005954:	c0 27 60 94 	clr  [ %i5 + 0x94 ]                            
  rtems_termios_interrupt_lock_release (tty, &lock_context);          
40005958:	7f ff fc e5 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
4000595c:	90 07 bf fc 	add  %fp, -4, %o0                              
static void                                                           
flushInput (struct rtems_termios_tty *tty)                            
{                                                                     
  rtems_interrupt_lock_context lock_context;                          
                                                                      
  rtems_termios_interrupt_lock_acquire (tty, &lock_context);          
40005960:	7f ff fc dd 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
40005964:	90 07 bf fc 	add  %fp, -4, %o0                              
  tty->rawInBuf.Tail = 0;                                             
40005968:	c0 27 60 60 	clr  [ %i5 + 0x60 ]                            
  tty->rawInBuf.Head = 0;                                             
4000596c:	c0 27 60 5c 	clr  [ %i5 + 0x5c ]                            
  rtems_termios_interrupt_lock_release (tty, &lock_context);          
40005970:	7f ff fc df 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
40005974:	90 07 bf fc 	add  %fp, -4, %o0                              
40005978:	30 80 00 30 	b,a   40005a38 <rtems_termios_ioctl+0x47c>     
        break;                                                        
    }                                                                 
    break;                                                            
                                                                      
  case RTEMS_IO_SNDWAKEUP:                                            
    tty->tty_snd = *wakeup;                                           
4000597c:	c2 27 60 d4 	st  %g1, [ %i5 + 0xd4 ]                        
40005980:	c2 06 e0 04 	ld  [ %i3 + 4 ], %g1                           
    break;                                                            
40005984:	10 80 00 2d 	b  40005a38 <rtems_termios_ioctl+0x47c>        
40005988:	c2 27 60 d8 	st  %g1, [ %i5 + 0xd8 ]                        
                                                                      
  case RTEMS_IO_RCVWAKEUP:                                            
    tty->tty_rcv = *wakeup;                                           
4000598c:	c2 27 60 dc 	st  %g1, [ %i5 + 0xdc ]                        
40005990:	c2 06 e0 04 	ld  [ %i3 + 4 ], %g1                           
    break;                                                            
40005994:	10 80 00 29 	b  40005a38 <rtems_termios_ioctl+0x47c>        
40005998:	c2 27 60 e0 	st  %g1, [ %i5 + 0xe0 ]                        
#if 1 /* FIXME */                                                     
  case TIOCSETD:                                                      
    /*                                                                
     * close old line discipline                                      
     */                                                               
    if (rtems_termios_linesw[tty->t_line].l_close != NULL) {          
4000599c:	85 28 a0 05 	sll  %g2, 5, %g2                               
400059a0:	86 10 e1 7c 	or  %g3, 0x17c, %g3                            
400059a4:	84 00 c0 02 	add  %g3, %g2, %g2                             
400059a8:	c2 00 a0 04 	ld  [ %g2 + 4 ], %g1                           
400059ac:	80 a0 60 00 	cmp  %g1, 0                                    
400059b0:	02 80 00 05 	be  400059c4 <rtems_termios_ioctl+0x408>       
400059b4:	b6 10 00 03 	mov  %g3, %i3                                  
      sc = rtems_termios_linesw[tty->t_line].l_close(tty);            
400059b8:	9f c0 40 00 	call  %g1                                      
400059bc:	90 10 00 1d 	mov  %i5, %o0                                  
400059c0:	b0 10 00 08 	mov  %o0, %i0                                  
    }                                                                 
    tty->t_line=*(int*)(args->buffer);                                
400059c4:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           
400059c8:	c2 00 40 00 	ld  [ %g1 ], %g1                               
    tty->t_sc = NULL; /* ensure that no more valid data */            
400059cc:	c0 27 60 d0 	clr  [ %i5 + 0xd0 ]                            
     * 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);                                
400059d0:	c2 27 60 cc 	st  %g1, [ %i5 + 0xcc ]                        
    tty->t_sc = NULL; /* ensure that no more valid data */            
    /*                                                                
     * open new line discipline                                       
     */                                                               
    if (rtems_termios_linesw[tty->t_line].l_open != NULL) {           
400059d4:	83 28 60 05 	sll  %g1, 5, %g1                               
400059d8:	c2 06 c0 01 	ld  [ %i3 + %g1 ], %g1                         
400059dc:	80 a0 60 00 	cmp  %g1, 0                                    
400059e0:	02 80 00 16 	be  40005a38 <rtems_termios_ioctl+0x47c>       
400059e4:	01 00 00 00 	nop                                            
      sc = rtems_termios_linesw[tty->t_line].l_open(tty);             
400059e8:	9f c0 40 00 	call  %g1                                      
400059ec:	90 10 00 1d 	mov  %i5, %o0                                  
400059f0:	10 80 00 12 	b  40005a38 <rtems_termios_ioctl+0x47c>        
400059f4:	b0 10 00 08 	mov  %o0, %i0                                  
    }                                                                 
    break;                                                            
  case TIOCGETD:                                                      
    *(int*)(args->buffer)=tty->t_line;                                
400059f8:	c2 07 20 08 	ld  [ %i4 + 8 ], %g1                           
    break;                                                            
400059fc:	10 80 00 0f 	b  40005a38 <rtems_termios_ioctl+0x47c>        
40005a00:	c4 20 40 00 	st  %g2, [ %g1 ]                               
#endif                                                                
   case FIONREAD: {                                                   
      int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head;            
40005a04:	c4 07 60 60 	ld  [ %i5 + 0x60 ], %g2                        <== NOT EXECUTED
40005a08:	c2 07 60 5c 	ld  [ %i5 + 0x5c ], %g1                        <== NOT EXECUTED
      if ( rawnc < 0 )                                                
40005a0c:	82 a0 80 01 	subcc  %g2, %g1, %g1                           <== NOT EXECUTED
40005a10:	3c 80 00 05 	bpos,a   40005a24 <rtems_termios_ioctl+0x468>  <== NOT EXECUTED
40005a14:	c8 07 60 20 	ld  [ %i5 + 0x20 ], %g4                        <== NOT EXECUTED
        rawnc += tty->rawInBuf.Size;                                  
40005a18:	c4 07 60 64 	ld  [ %i5 + 0x64 ], %g2                        <== NOT EXECUTED
40005a1c:	82 00 40 02 	add  %g1, %g2, %g1                             <== NOT EXECUTED
      /* Half guess that this is the right operation */               
      *(int *)args->buffer = tty->ccount - tty->cindex + rawnc;       
40005a20:	c8 07 60 20 	ld  [ %i5 + 0x20 ], %g4                        <== NOT EXECUTED
40005a24:	c6 07 60 24 	ld  [ %i5 + 0x24 ], %g3                        <== NOT EXECUTED
40005a28:	c4 07 20 08 	ld  [ %i4 + 8 ], %g2                           <== NOT EXECUTED
40005a2c:	86 21 00 03 	sub  %g4, %g3, %g3                             <== NOT EXECUTED
40005a30:	82 00 c0 01 	add  %g3, %g1, %g1                             <== NOT EXECUTED
40005a34:	c2 20 80 00 	st  %g1, [ %g2 ]                               <== NOT EXECUTED
    }                                                                 
    break;                                                            
  }                                                                   
                                                                      
  rtems_semaphore_release (tty->osem);                                
40005a38:	40 00 07 52 	call  40007780 <rtems_semaphore_release>       
40005a3c:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
  return sc;                                                          
}                                                                     
40005a40:	81 c7 e0 08 	ret                                            
40005a44:	81 e8 00 00 	restore                                        
                                                                      

40004fb8 <rtems_termios_open>: rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) {
40004fb8:	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(                                        
40004fbc:	21 10 00 60 	sethi  %hi(0x40018000), %l0                    
40004fc0:	d0 04 23 70 	ld  [ %l0 + 0x370 ], %o0	! 40018370 <rtems_termios_ttyMutex>
40004fc4:	92 10 20 00 	clr  %o1                                       
40004fc8:	40 00 09 a6 	call  40007660 <rtems_semaphore_obtain>        
40004fcc:	94 10 20 00 	clr  %o2                                       
    rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);            
  if (sc != RTEMS_SUCCESSFUL)                                         
40004fd0:	80 a2 20 00 	cmp  %o0, 0                                    
40004fd4:	12 80 00 b5 	bne  400052a8 <rtems_termios_open+0x2f0>       <== NEVER TAKEN
40004fd8:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
    return sc;                                                        
                                                                      
  for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) { 
40004fdc:	f8 00 63 78 	ld  [ %g1 + 0x378 ], %i4	! 40018378 <rtems_termios_ttyHead>
40004fe0:	a6 10 00 01 	mov  %g1, %l3                                  
40004fe4:	ba 10 00 1c 	mov  %i4, %i5                                  
40004fe8:	80 a7 60 00 	cmp  %i5, 0                                    
40004fec:	22 80 00 b1 	be,a   400052b0 <rtems_termios_open+0x2f8>     
40004ff0:	90 10 20 01 	mov  1, %o0                                    
    if ((tty->major == major) && (tty->minor == minor))               
40004ff4:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40004ff8:	80 a0 40 18 	cmp  %g1, %i0                                  
40004ffc:	32 bf ff fb 	bne,a   40004fe8 <rtems_termios_open+0x30>     
40005000:	fa 07 40 00 	ld  [ %i5 ], %i5                               
40005004:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
40005008:	80 a0 40 19 	cmp  %g1, %i1                                  
4000500c:	22 80 00 80 	be,a   4000520c <rtems_termios_open+0x254>     <== ALWAYS TAKEN
40005010:	c2 06 80 00 	ld  [ %i2 ], %g1                               
  sc = rtems_semaphore_obtain(                                        
    rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);            
  if (sc != RTEMS_SUCCESSFUL)                                         
    return sc;                                                        
                                                                      
  for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) { 
40005014:	10 bf ff f5 	b  40004fe8 <rtems_termios_open+0x30>          <== NOT EXECUTED
40005018:	fa 07 40 00 	ld  [ %i5 ], %i5                               <== NOT EXECUTED
      return RTEMS_NO_MEMORY;                                         
    }                                                                 
    /*                                                                
     * Initialize wakeup callbacks                                    
     */                                                               
    tty->tty_snd.sw_pfn = NULL;                                       
4000501c:	c0 27 60 d4 	clr  [ %i5 + 0xd4 ]                            
    tty->tty_snd.sw_arg = NULL;                                       
40005020:	c0 27 60 d8 	clr  [ %i5 + 0xd8 ]                            
    tty->tty_rcv.sw_pfn = NULL;                                       
40005024:	c0 27 60 dc 	clr  [ %i5 + 0xdc ]                            
    tty->tty_rcv.sw_arg = NULL;                                       
40005028:	c0 27 60 e0 	clr  [ %i5 + 0xe0 ]                            
    tty->tty_rcvwakeup  = 0;                                          
4000502c:	c0 27 60 e4 	clr  [ %i5 + 0xe4 ]                            
                                                                      
    /*                                                                
     * link tty                                                       
     */                                                               
    tty->forw = rtems_termios_ttyHead;                                
40005030:	f8 27 40 00 	st  %i4, [ %i5 ]                               
    tty->back = NULL;                                                 
    if (rtems_termios_ttyHead != NULL)                                
40005034:	80 a7 20 00 	cmp  %i4, 0                                    
40005038:	02 80 00 03 	be  40005044 <rtems_termios_open+0x8c>         
4000503c:	c0 27 60 04 	clr  [ %i5 + 4 ]                               
      rtems_termios_ttyHead->back = tty;                              
40005040:	fa 27 20 04 	st  %i5, [ %i4 + 4 ]                           
    rtems_termios_ttyHead = tty;                                      
    if (rtems_termios_ttyTail == NULL)                                
40005044:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40005048:	c4 00 63 74 	ld  [ %g1 + 0x374 ], %g2	! 40018374 <rtems_termios_ttyTail>
4000504c:	80 a0 a0 00 	cmp  %g2, 0                                    
40005050:	12 80 00 03 	bne  4000505c <rtems_termios_open+0xa4>        
40005054:	fa 24 e3 78 	st  %i5, [ %l3 + 0x378 ]                       
      rtems_termios_ttyTail = tty;                                    
40005058:	fa 20 63 74 	st  %i5, [ %g1 + 0x374 ]                       
                                                                      
    /*                                                                
     * Set up mutex semaphores                                        
     */                                                               
    sc = rtems_semaphore_create (                                     
      rtems_build_name ('T', 'R', 'i', c),                            
4000505c:	39 10 00 5a 	sethi  %hi(0x40016800), %i4                    
40005060:	d0 4f 23 58 	ldsb  [ %i4 + 0x358 ], %o0	! 40016b58 <c.6664> 
    tty->major = major;                                               
                                                                      
    /*                                                                
     * Set up mutex semaphores                                        
     */                                                               
    sc = rtems_semaphore_create (                                     
40005064:	03 15 14 9a 	sethi  %hi(0x54526800), %g1                    
40005068:	82 10 61 00 	or  %g1, 0x100, %g1	! 54526900 <RAM_END+0x14126900>
      rtems_termios_ttyHead->back = tty;                              
    rtems_termios_ttyHead = tty;                                      
    if (rtems_termios_ttyTail == NULL)                                
      rtems_termios_ttyTail = tty;                                    
                                                                      
    tty->minor = minor;                                               
4000506c:	f2 27 60 10 	st  %i1, [ %i5 + 0x10 ]                        
    tty->major = major;                                               
40005070:	f0 27 60 0c 	st  %i0, [ %i5 + 0xc ]                         
                                                                      
    /*                                                                
     * Set up mutex semaphores                                        
     */                                                               
    sc = rtems_semaphore_create (                                     
40005074:	90 12 00 01 	or  %o0, %g1, %o0                              
40005078:	92 10 20 01 	mov  1, %o1                                    
4000507c:	94 10 20 54 	mov  0x54, %o2                                 
40005080:	96 10 20 00 	clr  %o3                                       
40005084:	98 07 60 14 	add  %i5, 0x14, %o4                            
40005088:	40 00 08 c3 	call  40007394 <rtems_semaphore_create>        
4000508c:	a2 10 00 1c 	mov  %i4, %l1                                  
      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)                                       
40005090:	80 a2 20 00 	cmp  %o0, 0                                    
40005094:	12 80 00 7e 	bne  4000528c <rtems_termios_open+0x2d4>       
40005098:	03 15 14 9b 	sethi  %hi(0x54526c00), %g1                    
      rtems_fatal_error_occurred (sc);                                
    sc = rtems_semaphore_create (                                     
      rtems_build_name ('T', 'R', 'o', c),                            
4000509c:	d0 4f 23 58 	ldsb  [ %i4 + 0x358 ], %o0                     
      RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY,
      RTEMS_NO_PRIORITY,                                              
      &tty->isem);                                                    
    if (sc != RTEMS_SUCCESSFUL)                                       
      rtems_fatal_error_occurred (sc);                                
    sc = rtems_semaphore_create (                                     
400050a0:	82 10 63 00 	or  %g1, 0x300, %g1                            
400050a4:	92 10 20 01 	mov  1, %o1                                    
400050a8:	90 12 00 01 	or  %o0, %g1, %o0                              
400050ac:	94 10 20 54 	mov  0x54, %o2                                 
400050b0:	96 10 20 00 	clr  %o3                                       
400050b4:	40 00 08 b8 	call  40007394 <rtems_semaphore_create>        
400050b8:	98 07 60 18 	add  %i5, 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)                                       
400050bc:	80 a2 20 00 	cmp  %o0, 0                                    
400050c0:	12 80 00 73 	bne  4000528c <rtems_termios_open+0x2d4>       
400050c4:	03 15 14 9e 	sethi  %hi(0x54527800), %g1                    
      rtems_fatal_error_occurred (sc);                                
    sc = rtems_semaphore_create (                                     
      rtems_build_name ('T', 'R', 'x', c),                            
400050c8:	d0 4f 23 58 	ldsb  [ %i4 + 0x358 ], %o0                     
      RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY,
      RTEMS_NO_PRIORITY,                                              
      &tty->osem);                                                    
    if (sc != RTEMS_SUCCESSFUL)                                       
      rtems_fatal_error_occurred (sc);                                
    sc = rtems_semaphore_create (                                     
400050cc:	92 10 20 00 	clr  %o1                                       
400050d0:	90 12 00 01 	or  %o0, %g1, %o0                              
400050d4:	94 10 20 20 	mov  0x20, %o2                                 
400050d8:	96 10 20 00 	clr  %o3                                       
400050dc:	40 00 08 ae 	call  40007394 <rtems_semaphore_create>        
400050e0:	98 07 60 8c 	add  %i5, 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)                                       
400050e4:	80 a2 20 00 	cmp  %o0, 0                                    
400050e8:	12 80 00 69 	bne  4000528c <rtems_termios_open+0x2d4>       
400050ec:	92 10 00 1b 	mov  %i3, %o1                                  
      rtems_fatal_error_occurred (sc);                                
    tty->rawOutBufState = rob_idle;                                   
400050f0:	c0 27 60 94 	clr  [ %i5 + 0x94 ]                            
                                                                      
    /*                                                                
     * Set callbacks                                                  
     */                                                               
    tty->device = *callbacks;                                         
400050f4:	90 07 60 98 	add  %i5, 0x98, %o0                            
400050f8:	40 00 2c 30 	call  400101b8 <memcpy>                        
400050fc:	94 10 20 20 	mov  0x20, %o2                                 
    rtems_interrupt_lock_initialize (&tty->interrupt_lock, "Termios");
                                                                      
    /*                                                                
     * Create I/O tasks                                               
     */                                                               
    if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {    
40005100:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40005104:	80 a0 60 02 	cmp  %g1, 2                                    
40005108:	02 80 00 93 	be  40005354 <rtems_termios_open+0x39c>        
4000510c:	d0 4f 23 58 	ldsb  [ %i4 + 0x358 ], %o0                     
           &tty->rxTaskId);                                           
      if (sc != RTEMS_SUCCESSFUL)                                     
        rtems_fatal_error_occurred (sc);                              
                                                                      
    }                                                                 
    if ((tty->device.pollRead == NULL) ||                             
40005110:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
40005114:	80 a0 60 00 	cmp  %g1, 0                                    
40005118:	02 80 00 a6 	be  400053b0 <rtems_termios_open+0x3f8>        
4000511c:	d0 4c 63 58 	ldsb  [ %l1 + 0x358 ], %o0                     
40005120:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40005124:	80 a0 60 02 	cmp  %g1, 2                                    
40005128:	22 80 00 a3 	be,a   400053b4 <rtems_termios_open+0x3fc>     
4000512c:	03 15 14 9c 	sethi  %hi(0x54527000), %g1                    
    }                                                                 
                                                                      
    /*                                                                
     * Set default parameters                                         
     */                                                               
    tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL;           
40005130:	03 00 00 09 	sethi  %hi(0x2400), %g1                        
40005134:	82 10 61 02 	or  %g1, 0x102, %g1	! 2502 <_TLS_Alignment+0x2501>
40005138:	c2 27 60 30 	st  %g1, [ %i5 + 0x30 ]                        
    tty->termios.c_oflag = OPOST | ONLCR | XTABS;                     
4000513c:	03 00 00 06 	sethi  %hi(0x1800), %g1                        
40005140:	82 10 60 05 	or  %g1, 5, %g1	! 1805 <_TLS_Alignment+0x1804> 
40005144:	c2 27 60 34 	st  %g1, [ %i5 + 0x34 ]                        
    tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL;              
40005148:	82 10 28 bd 	mov  0x8bd, %g1                                
4000514c:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
    tty->termios.c_lflag =                                            
40005150:	03 00 00 20 	sethi  %hi(0x8000), %g1                        
40005154:	82 10 62 3b 	or  %g1, 0x23b, %g1	! 823b <_TLS_Alignment+0x823a>
40005158:	c2 27 60 3c 	st  %g1, [ %i5 + 0x3c ]                        
       ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL;       
                                                                      
    tty->termios.c_cc[VINTR] = '\003';                                
4000515c:	82 10 20 03 	mov  3, %g1                                    
40005160:	c2 2f 60 41 	stb  %g1, [ %i5 + 0x41 ]                       
    tty->termios.c_cc[VQUIT] = '\034';                                
40005164:	82 10 20 1c 	mov  0x1c, %g1                                 
40005168:	c2 2f 60 42 	stb  %g1, [ %i5 + 0x42 ]                       
    tty->termios.c_cc[VERASE] = '\177';                               
4000516c:	82 10 20 7f 	mov  0x7f, %g1                                 
40005170:	c2 2f 60 43 	stb  %g1, [ %i5 + 0x43 ]                       
    tty->termios.c_cc[VKILL] = '\025';                                
40005174:	82 10 20 15 	mov  0x15, %g1                                 
40005178:	c2 2f 60 44 	stb  %g1, [ %i5 + 0x44 ]                       
    tty->termios.c_cc[VEOF] = '\004';                                 
4000517c:	82 10 20 04 	mov  4, %g1                                    
40005180:	c2 2f 60 45 	stb  %g1, [ %i5 + 0x45 ]                       
    tty->termios.c_cc[VEOL] = '\000';                                 
    tty->termios.c_cc[VEOL2] = '\000';                                
    tty->termios.c_cc[VSTART] = '\021';                               
40005184:	82 10 20 11 	mov  0x11, %g1                                 
40005188:	c2 2f 60 49 	stb  %g1, [ %i5 + 0x49 ]                       
    tty->termios.c_cc[VSTOP] = '\023';                                
4000518c:	82 10 20 13 	mov  0x13, %g1                                 
40005190:	c2 2f 60 4a 	stb  %g1, [ %i5 + 0x4a ]                       
    tty->termios.c_cc[VSUSP] = '\032';                                
40005194:	82 10 20 1a 	mov  0x1a, %g1                                 
40005198:	c2 2f 60 4b 	stb  %g1, [ %i5 + 0x4b ]                       
    tty->termios.c_cc[VREPRINT] = '\022';                             
4000519c:	82 10 20 12 	mov  0x12, %g1                                 
400051a0:	c2 2f 60 4d 	stb  %g1, [ %i5 + 0x4d ]                       
    tty->termios.c_cc[VDISCARD] = '\017';                             
400051a4:	82 10 20 0f 	mov  0xf, %g1                                  
400051a8:	c2 2f 60 4e 	stb  %g1, [ %i5 + 0x4e ]                       
    tty->termios.c_cc[VWERASE] = '\027';                              
400051ac:	82 10 20 17 	mov  0x17, %g1                                 
400051b0:	c2 2f 60 4f 	stb  %g1, [ %i5 + 0x4f ]                       
    tty->termios.c_cc[VLNEXT] = '\026';                               
400051b4:	82 10 20 16 	mov  0x16, %g1                                 
                                                                      
    /* start with no flow control, clear flow control flags */        
    tty->flow_ctrl = 0;                                               
400051b8:	c0 27 60 b8 	clr  [ %i5 + 0xb8 ]                            
    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';                               
400051bc:	c2 2f 60 50 	stb  %g1, [ %i5 + 0x50 ]                       
    /* 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;                        
400051c0:	c2 07 60 64 	ld  [ %i5 + 0x64 ], %g1                        
    tty->highwater = tty->rawInBuf.Size * 3/4;                        
    /*                                                                
     * Bump name characer                                             
     */                                                               
    if (c++ == 'z')                                                   
400051c4:	c6 4c 63 58 	ldsb  [ %l1 + 0x358 ], %g3                     
    /* 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;                        
400051c8:	83 30 60 01 	srl  %g1, 1, %g1                               
400051cc:	c2 27 60 bc 	st  %g1, [ %i5 + 0xbc ]                        
    tty->highwater = tty->rawInBuf.Size * 3/4;                        
400051d0:	c2 07 60 64 	ld  [ %i5 + 0x64 ], %g1                        
    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';                                 
400051d4:	c0 2f 60 4c 	clrb  [ %i5 + 0x4c ]                           
    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;                        
400051d8:	85 28 60 01 	sll  %g1, 1, %g2                               
400051dc:	82 00 80 01 	add  %g2, %g1, %g1                             
    /*                                                                
     * Bump name characer                                             
     */                                                               
    if (c++ == 'z')                                                   
400051e0:	c4 0c 63 58 	ldub  [ %l1 + 0x358 ], %g2                     
    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;                        
400051e4:	83 30 60 02 	srl  %g1, 2, %g1                               
    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';                                
400051e8:	c0 2f 60 51 	clrb  [ %i5 + 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;                        
400051ec:	c2 27 60 c0 	st  %g1, [ %i5 + 0xc0 ]                        
    /*                                                                
     * Bump name characer                                             
     */                                                               
    if (c++ == 'z')                                                   
400051f0:	84 00 a0 01 	inc  %g2                                       
400051f4:	80 a0 e0 7a 	cmp  %g3, 0x7a                                 
400051f8:	12 80 00 03 	bne  40005204 <rtems_termios_open+0x24c>       
400051fc:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
      c = 'a';                                                        
40005200:	84 10 20 61 	mov  0x61, %g2                                 
40005204:	c4 28 63 58 	stb  %g2, [ %g1 + 0x358 ]                      
                                                                      
  }                                                                   
  args->iop->data1 = tty;                                             
40005208:	c2 06 80 00 	ld  [ %i2 ], %g1                               
4000520c:	fa 20 60 30 	st  %i5, [ %g1 + 0x30 ]                        
  if (!tty->refcount++) {                                             
40005210:	c2 07 60 08 	ld  [ %i5 + 8 ], %g1                           
40005214:	84 00 60 01 	add  %g1, 1, %g2                               
40005218:	80 a0 60 00 	cmp  %g1, 0                                    
4000521c:	12 80 00 1e 	bne  40005294 <rtems_termios_open+0x2dc>       
40005220:	c4 27 60 08 	st  %g2, [ %i5 + 8 ]                           
    if (tty->device.firstOpen)                                        
40005224:	c2 07 60 98 	ld  [ %i5 + 0x98 ], %g1                        
40005228:	80 a0 60 00 	cmp  %g1, 0                                    
4000522c:	02 80 00 05 	be  40005240 <rtems_termios_open+0x288>        
40005230:	90 10 00 18 	mov  %i0, %o0                                  
      (*tty->device.firstOpen)(major, minor, arg);                    
40005234:	92 10 00 19 	mov  %i1, %o1                                  
40005238:	9f c0 40 00 	call  %g1                                      
4000523c:	94 10 00 1a 	mov  %i2, %o2                                  
                                                                      
    /*                                                                
     * start I/O tasks, if needed                                     
     */                                                               
    if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {    
40005240:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
40005244:	80 a0 60 02 	cmp  %g1, 2                                    
40005248:	12 80 00 14 	bne  40005298 <rtems_termios_open+0x2e0>       
4000524c:	d0 04 23 70 	ld  [ %l0 + 0x370 ], %o0                       
      sc = rtems_task_start(                                          
40005250:	d0 07 60 c4 	ld  [ %i5 + 0xc4 ], %o0                        
40005254:	13 10 00 1a 	sethi  %hi(0x40006800), %o1                    
40005258:	94 10 00 1d 	mov  %i5, %o2                                  
4000525c:	40 00 0a 2b 	call  40007b08 <rtems_task_start>              
40005260:	92 12 61 34 	or  %o1, 0x134, %o1                            
        tty->rxTaskId, rtems_termios_rxdaemon, (rtems_task_argument)tty);
      if (sc != RTEMS_SUCCESSFUL)                                     
40005264:	80 a2 20 00 	cmp  %o0, 0                                    
40005268:	12 80 00 09 	bne  4000528c <rtems_termios_open+0x2d4>       <== NEVER TAKEN
4000526c:	13 10 00 13 	sethi  %hi(0x40004c00), %o1                    
        rtems_fatal_error_occurred (sc);                              
                                                                      
      sc = rtems_task_start(                                          
40005270:	d0 07 60 c8 	ld  [ %i5 + 0xc8 ], %o0                        
40005274:	94 10 00 1d 	mov  %i5, %o2                                  
40005278:	40 00 0a 24 	call  40007b08 <rtems_task_start>              
4000527c:	92 12 62 e8 	or  %o1, 0x2e8, %o1                            
        tty->txTaskId, rtems_termios_txdaemon, (rtems_task_argument)tty);
      if (sc != RTEMS_SUCCESSFUL)                                     
40005280:	80 a2 20 00 	cmp  %o0, 0                                    
40005284:	22 80 00 05 	be,a   40005298 <rtems_termios_open+0x2e0>     <== ALWAYS TAKEN
40005288:	d0 04 23 70 	ld  [ %l0 + 0x370 ], %o0                       
        rtems_fatal_error_occurred (sc);                              
4000528c:	40 00 0a be 	call  40007d84 <rtems_fatal_error_occurred>    
40005290:	01 00 00 00 	nop                                            
    }                                                                 
  }                                                                   
  rtems_semaphore_release (rtems_termios_ttyMutex);                   
40005294:	d0 04 23 70 	ld  [ %l0 + 0x370 ], %o0                       
40005298:	40 00 09 3a 	call  40007780 <rtems_semaphore_release>       
4000529c:	b0 10 20 00 	clr  %i0                                       
  return RTEMS_SUCCESSFUL;                                            
400052a0:	81 c7 e0 08 	ret                                            
400052a4:	81 e8 00 00 	restore                                        
400052a8:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
400052ac:	91 e8 00 08 	restore  %g0, %o0, %o0                         <== NOT EXECUTED
    static char c = 'a';                                              
                                                                      
    /*                                                                
     * Create a new device                                            
     */                                                               
    tty = calloc (1, sizeof (struct rtems_termios_tty));              
400052b0:	7f ff f9 42 	call  400037b8 <calloc>                        
400052b4:	92 10 20 e8 	mov  0xe8, %o1                                 
    if (tty == NULL) {                                                
400052b8:	ba 92 20 00 	orcc  %o0, 0, %i5                              
400052bc:	02 80 00 21 	be  40005340 <rtems_termios_open+0x388>        
400052c0:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
      return RTEMS_NO_MEMORY;                                         
    }                                                                 
    /*                                                                
     * allocate raw input buffer                                      
     */                                                               
    tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE;                       
400052c4:	c2 00 63 60 	ld  [ %g1 + 0x360 ], %g1	! 40016b60 <rtems_termios_raw_input_size>
400052c8:	c2 27 60 64 	st  %g1, [ %i5 + 0x64 ]                        
    tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size);               
400052cc:	d0 07 60 64 	ld  [ %i5 + 0x64 ], %o0                        
400052d0:	7f ff fa 24 	call  40003b60 <malloc>                        
400052d4:	01 00 00 00 	nop                                            
400052d8:	d0 27 60 58 	st  %o0, [ %i5 + 0x58 ]                        
    if (tty->rawInBuf.theBuf == NULL) {                               
400052dc:	80 a2 20 00 	cmp  %o0, 0                                    
400052e0:	02 80 00 16 	be  40005338 <rtems_termios_open+0x380>        
400052e4:	a2 10 00 08 	mov  %o0, %l1                                  
      return RTEMS_NO_MEMORY;                                         
    }                                                                 
    /*                                                                
     * allocate raw output buffer                                     
     */                                                               
    tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE;                     
400052e8:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
400052ec:	c2 00 63 5c 	ld  [ %g1 + 0x35c ], %g1	! 40016b5c <rtems_termios_raw_output_size>
400052f0:	c2 27 60 88 	st  %g1, [ %i5 + 0x88 ]                        
    tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size);             
400052f4:	d0 07 60 88 	ld  [ %i5 + 0x88 ], %o0                        
400052f8:	7f ff fa 1a 	call  40003b60 <malloc>                        
400052fc:	01 00 00 00 	nop                                            
40005300:	d0 27 60 7c 	st  %o0, [ %i5 + 0x7c ]                        
    if (tty->rawOutBuf.theBuf == NULL) {                              
40005304:	80 a2 20 00 	cmp  %o0, 0                                    
40005308:	02 80 00 0a 	be  40005330 <rtems_termios_open+0x378>        
4000530c:	a4 10 00 08 	mov  %o0, %l2                                  
      return RTEMS_NO_MEMORY;                                         
    }                                                                 
    /*                                                                
     * allocate cooked buffer                                         
     */                                                               
    tty->cbuf  = malloc (CBUFSIZE);                                   
40005310:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
40005314:	7f ff fa 13 	call  40003b60 <malloc>                        
40005318:	d0 00 63 64 	ld  [ %g1 + 0x364 ], %o0	! 40016b64 <rtems_termios_cbufsize>
    if (tty->cbuf == NULL) {                                          
4000531c:	80 a2 20 00 	cmp  %o0, 0                                    
40005320:	12 bf ff 3f 	bne  4000501c <rtems_termios_open+0x64>        
40005324:	d0 27 60 1c 	st  %o0, [ %i5 + 0x1c ]                        
            free((void *)(tty->rawOutBuf.theBuf));                    
40005328:	7f ff f9 39 	call  4000380c <free>                          
4000532c:	90 10 00 12 	mov  %l2, %o0                                  
            free((void *)(tty->rawInBuf.theBuf));                     
40005330:	7f ff f9 37 	call  4000380c <free>                          
40005334:	90 10 00 11 	mov  %l1, %o0                                  
            free(tty);                                                
40005338:	7f ff f9 35 	call  4000380c <free>                          
4000533c:	90 10 00 1d 	mov  %i5, %o0                                  
      rtems_semaphore_release (rtems_termios_ttyMutex);               
40005340:	d0 04 23 70 	ld  [ %l0 + 0x370 ], %o0                       
40005344:	40 00 09 0f 	call  40007780 <rtems_semaphore_release>       
40005348:	b0 10 20 1a 	mov  0x1a, %i0                                 
      return RTEMS_NO_MEMORY;                                         
4000534c:	81 c7 e0 08 	ret                                            
40005350:	81 e8 00 00 	restore                                        
                                                                      
    /*                                                                
     * Create I/O tasks                                               
     */                                                               
    if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {    
      sc = rtems_task_create (                                        
40005354:	03 15 1e 15 	sethi  %hi(0x54785400), %g1                    
40005358:	92 10 20 0a 	mov  0xa, %o1                                  
4000535c:	90 12 00 01 	or  %o0, %g1, %o0                              
40005360:	94 10 24 00 	mov  0x400, %o2                                
40005364:	96 10 25 00 	mov  0x500, %o3                                
40005368:	98 10 20 00 	clr  %o4                                       
4000536c:	40 00 09 47 	call  40007888 <rtems_task_create>             
40005370:	9a 07 60 c8 	add  %i5, 0xc8, %o5                            
           TERMIOS_TXTASK_STACKSIZE,                                  
           RTEMS_NO_PREEMPT | RTEMS_NO_TIMESLICE |                    
           RTEMS_NO_ASR,                                              
           RTEMS_NO_FLOATING_POINT | RTEMS_LOCAL,                     
           &tty->txTaskId);                                           
      if (sc != RTEMS_SUCCESSFUL)                                     
40005374:	80 a2 20 00 	cmp  %o0, 0                                    
40005378:	12 bf ff c5 	bne  4000528c <rtems_termios_open+0x2d4>       <== NEVER TAKEN
4000537c:	03 14 9e 15 	sethi  %hi(0x52785400), %g1                    
        rtems_fatal_error_occurred (sc);                              
      sc = rtems_task_create (                                        
                                   rtems_build_name ('R', 'x', 'T', c),
40005380:	d0 4f 23 58 	ldsb  [ %i4 + 0x358 ], %o0                     
           RTEMS_NO_ASR,                                              
           RTEMS_NO_FLOATING_POINT | RTEMS_LOCAL,                     
           &tty->txTaskId);                                           
      if (sc != RTEMS_SUCCESSFUL)                                     
        rtems_fatal_error_occurred (sc);                              
      sc = rtems_task_create (                                        
40005384:	92 10 20 09 	mov  9, %o1                                    
40005388:	90 12 00 01 	or  %o0, %g1, %o0                              
4000538c:	94 10 24 00 	mov  0x400, %o2                                
40005390:	96 10 25 00 	mov  0x500, %o3                                
40005394:	98 10 20 00 	clr  %o4                                       
40005398:	40 00 09 3c 	call  40007888 <rtems_task_create>             
4000539c:	9a 07 60 c4 	add  %i5, 0xc4, %o5                            
           TERMIOS_RXTASK_STACKSIZE,                                  
           RTEMS_NO_PREEMPT | RTEMS_NO_TIMESLICE |                    
           RTEMS_NO_ASR,                                              
           RTEMS_NO_FLOATING_POINT | RTEMS_LOCAL,                     
           &tty->rxTaskId);                                           
      if (sc != RTEMS_SUCCESSFUL)                                     
400053a0:	80 a2 20 00 	cmp  %o0, 0                                    
400053a4:	22 bf ff 5c 	be,a   40005114 <rtems_termios_open+0x15c>     <== ALWAYS TAKEN
400053a8:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
400053ac:	30 bf ff b8 	b,a   4000528c <rtems_termios_open+0x2d4>      <== NOT EXECUTED
        rtems_fatal_error_occurred (sc);                              
                                                                      
    }                                                                 
    if ((tty->device.pollRead == NULL) ||                             
        (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)){   
      sc = rtems_semaphore_create (                                   
400053b0:	03 15 14 9c 	sethi  %hi(0x54527000), %g1                    
400053b4:	82 10 62 00 	or  %g1, 0x200, %g1	! 54527200 <RAM_END+0x14127200>
400053b8:	92 10 20 00 	clr  %o1                                       
400053bc:	90 12 00 01 	or  %o0, %g1, %o0                              
400053c0:	94 10 20 24 	mov  0x24, %o2                                 
400053c4:	96 10 20 00 	clr  %o3                                       
400053c8:	40 00 07 f3 	call  40007394 <rtems_semaphore_create>        
400053cc:	98 07 60 68 	add  %i5, 0x68, %o4                            
        rtems_build_name ('T', 'R', 'r', c),                          
        0,                                                            
        RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_PRIORITY,               
        RTEMS_NO_PRIORITY,                                            
        &tty->rawInBuf.Semaphore);                                    
      if (sc != RTEMS_SUCCESSFUL)                                     
400053d0:	80 a2 20 00 	cmp  %o0, 0                                    
400053d4:	02 bf ff 58 	be  40005134 <rtems_termios_open+0x17c>        <== ALWAYS TAKEN
400053d8:	03 00 00 09 	sethi  %hi(0x2400), %g1                        
400053dc:	30 bf ff ac 	b,a   4000528c <rtems_termios_open+0x2d4>      <== NOT EXECUTED
                                                                      

40005a48 <rtems_termios_puts>: * Send characters to device-specific code */ void rtems_termios_puts ( const void *_buf, size_t len, struct rtems_termios_tty *tty) {
40005a48:	9d e3 bf 98 	save  %sp, -104, %sp                           
  const char *buf = _buf;                                             
  unsigned int newHead;                                               
  rtems_interrupt_lock_context lock_context;                          
  rtems_status_code sc;                                               
                                                                      
  if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {           
40005a4c:	c2 06 a0 b4 	ld  [ %i2 + 0xb4 ], %g1                        
40005a50:	80 a0 60 00 	cmp  %g1, 0                                    
40005a54:	12 80 00 08 	bne  40005a74 <rtems_termios_puts+0x2c>        
40005a58:	92 10 00 18 	mov  %i0, %o1                                  
    (*tty->device.write)(tty->minor, buf, len);                       
40005a5c:	c2 06 a0 a4 	ld  [ %i2 + 0xa4 ], %g1                        
40005a60:	d0 06 a0 10 	ld  [ %i2 + 0x10 ], %o0                        
40005a64:	9f c0 40 00 	call  %g1                                      
40005a68:	94 10 00 19 	mov  %i1, %o2                                  
40005a6c:	81 c7 e0 08 	ret                                            
40005a70:	81 e8 00 00 	restore                                        
    return;                                                           
  }                                                                   
  newHead = tty->rawOutBuf.Head;                                      
40005a74:	fa 06 a0 80 	ld  [ %i2 + 0x80 ], %i5                        
40005a78:	b2 06 00 19 	add  %i0, %i1, %i1                             
     * with interrupts enabled.                                       
     */                                                               
    newHead = (newHead + 1) % tty->rawOutBuf.Size;                    
    rtems_termios_interrupt_lock_acquire (tty, &lock_context);        
    while (newHead == tty->rawOutBuf.Tail) {                          
      tty->rawOutBufState = rob_wait;                                 
40005a7c:	b8 10 20 02 	mov  2, %i4                                    
          tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); 
      } else {                                                        
        /* remember that output has been stopped due to flow ctrl*/   
        tty->flow_ctrl |= FL_OSTOP;                                   
      }                                                               
      tty->rawOutBufState = rob_busy;                                 
40005a80:	b6 10 20 01 	mov  1, %i3                                    
  if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {           
    (*tty->device.write)(tty->minor, buf, len);                       
    return;                                                           
  }                                                                   
  newHead = tty->rawOutBuf.Head;                                      
  while (len) {                                                       
40005a84:	80 a6 00 19 	cmp  %i0, %i1                                  
40005a88:	02 80 00 36 	be  40005b60 <rtems_termios_puts+0x118>        
40005a8c:	01 00 00 00 	nop                                            
     *  len -= ncopy                                                  
     *                                                                
     * To minimize latency, the memcpy should be done                 
     * with interrupts enabled.                                       
     */                                                               
    newHead = (newHead + 1) % tty->rawOutBuf.Size;                    
40005a90:	d2 06 a0 88 	ld  [ %i2 + 0x88 ], %o1                        
40005a94:	40 00 37 3d 	call  40013788 <.urem>                         
40005a98:	90 07 60 01 	add  %i5, 1, %o0                               
40005a9c:	ba 10 00 08 	mov  %o0, %i5                                  
      rtems_termios_interrupt_lock_release (tty, &lock_context);      
      sc = rtems_semaphore_obtain(                                    
        tty->rawOutBuf.Semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT);      
      if (sc != RTEMS_SUCCESSFUL)                                     
        rtems_fatal_error_occurred (sc);                              
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
40005aa0:	7f ff fc 8d 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
40005aa4:	90 07 bf fc 	add  %fp, -4, %o0                              
     * To minimize latency, the memcpy should be done                 
     * with interrupts enabled.                                       
     */                                                               
    newHead = (newHead + 1) % tty->rawOutBuf.Size;                    
    rtems_termios_interrupt_lock_acquire (tty, &lock_context);        
    while (newHead == tty->rawOutBuf.Tail) {                          
40005aa8:	c2 06 a0 84 	ld  [ %i2 + 0x84 ], %g1                        
40005aac:	80 a7 40 01 	cmp  %i5, %g1                                  
40005ab0:	12 80 00 0d 	bne  40005ae4 <rtems_termios_puts+0x9c>        
40005ab4:	90 07 bf fc 	add  %fp, -4, %o0                              
      tty->rawOutBufState = rob_wait;                                 
      rtems_termios_interrupt_lock_release (tty, &lock_context);      
40005ab8:	7f ff fc 8d 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
40005abc:	f8 26 a0 94 	st  %i4, [ %i2 + 0x94 ]                        
      sc = rtems_semaphore_obtain(                                    
40005ac0:	d0 06 a0 8c 	ld  [ %i2 + 0x8c ], %o0                        
40005ac4:	92 10 20 00 	clr  %o1                                       
40005ac8:	40 00 06 e6 	call  40007660 <rtems_semaphore_obtain>        
40005acc:	94 10 20 00 	clr  %o2                                       
        tty->rawOutBuf.Semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT);      
      if (sc != RTEMS_SUCCESSFUL)                                     
40005ad0:	80 a2 20 00 	cmp  %o0, 0                                    
40005ad4:	02 bf ff f3 	be  40005aa0 <rtems_termios_puts+0x58>         <== ALWAYS TAKEN
40005ad8:	01 00 00 00 	nop                                            
        rtems_fatal_error_occurred (sc);                              
40005adc:	40 00 08 aa 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
40005ae0:	01 00 00 00 	nop                                            <== NOT EXECUTED
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
    }                                                                 
    tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++;              
40005ae4:	c2 06 a0 80 	ld  [ %i2 + 0x80 ], %g1                        
40005ae8:	c6 0e 00 00 	ldub  [ %i0 ], %g3                             
40005aec:	b0 06 20 01 	inc  %i0                                       
40005af0:	c4 06 a0 7c 	ld  [ %i2 + 0x7c ], %g2                        
40005af4:	c6 28 80 01 	stb  %g3, [ %g2 + %g1 ]                        
    tty->rawOutBuf.Head = newHead;                                    
    if (tty->rawOutBufState == rob_idle) {                            
40005af8:	c2 06 a0 94 	ld  [ %i2 + 0x94 ], %g1                        
      if (sc != RTEMS_SUCCESSFUL)                                     
        rtems_fatal_error_occurred (sc);                              
      rtems_termios_interrupt_lock_acquire (tty, &lock_context);      
    }                                                                 
    tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++;              
    tty->rawOutBuf.Head = newHead;                                    
40005afc:	fa 26 a0 80 	st  %i5, [ %i2 + 0x80 ]                        
    if (tty->rawOutBufState == rob_idle) {                            
40005b00:	80 a0 60 00 	cmp  %g1, 0                                    
40005b04:	12 80 00 13 	bne  40005b50 <rtems_termios_puts+0x108>       
40005b08:	01 00 00 00 	nop                                            
      /* check, whether XOFF has been received */                     
      if (!(tty->flow_ctrl & FL_ORCVXOF)) {                           
40005b0c:	c2 06 a0 b8 	ld  [ %i2 + 0xb8 ], %g1                        
40005b10:	80 88 60 10 	btst  0x10, %g1                                
40005b14:	12 80 00 0b 	bne  40005b40 <rtems_termios_puts+0xf8>        <== NEVER TAKEN
40005b18:	01 00 00 00 	nop                                            
        (*tty->device.write)(                                         
          tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); 
40005b1c:	c4 06 a0 84 	ld  [ %i2 + 0x84 ], %g2                        
    tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++;              
    tty->rawOutBuf.Head = newHead;                                    
    if (tty->rawOutBufState == rob_idle) {                            
      /* check, whether XOFF has been received */                     
      if (!(tty->flow_ctrl & FL_ORCVXOF)) {                           
        (*tty->device.write)(                                         
40005b20:	d2 06 a0 7c 	ld  [ %i2 + 0x7c ], %o1                        
40005b24:	c2 06 a0 a4 	ld  [ %i2 + 0xa4 ], %g1                        
40005b28:	d0 06 a0 10 	ld  [ %i2 + 0x10 ], %o0                        
40005b2c:	92 02 40 02 	add  %o1, %g2, %o1                             
40005b30:	9f c0 40 00 	call  %g1                                      
40005b34:	94 10 20 01 	mov  1, %o2                                    
40005b38:	10 80 00 06 	b  40005b50 <rtems_termios_puts+0x108>         
40005b3c:	f6 26 a0 94 	st  %i3, [ %i2 + 0x94 ]                        
          tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); 
      } else {                                                        
        /* remember that output has been stopped due to flow ctrl*/   
        tty->flow_ctrl |= FL_OSTOP;                                   
40005b40:	c2 06 a0 b8 	ld  [ %i2 + 0xb8 ], %g1                        <== NOT EXECUTED
40005b44:	82 10 60 20 	or  %g1, 0x20, %g1                             <== NOT EXECUTED
40005b48:	c2 26 a0 b8 	st  %g1, [ %i2 + 0xb8 ]                        <== NOT EXECUTED
      }                                                               
      tty->rawOutBufState = rob_busy;                                 
40005b4c:	f6 26 a0 94 	st  %i3, [ %i2 + 0x94 ]                        <== NOT EXECUTED
    }                                                                 
    rtems_termios_interrupt_lock_release (tty, &lock_context);        
40005b50:	7f ff fc 67 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
40005b54:	90 07 bf fc 	add  %fp, -4, %o0                              
  if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {           
    (*tty->device.write)(tty->minor, buf, len);                       
    return;                                                           
  }                                                                   
  newHead = tty->rawOutBuf.Head;                                      
  while (len) {                                                       
40005b58:	10 bf ff cc 	b  40005a88 <rtems_termios_puts+0x40>          
40005b5c:	80 a6 00 19 	cmp  %i0, %i1                                  
40005b60:	81 c7 e0 08 	ret                                            
40005b64:	81 e8 00 00 	restore                                        
                                                                      

40006274 <rtems_termios_read>: return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) {
40006274:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_libio_rw_args_t *args = arg;                                  
  struct rtems_termios_tty *tty = args->iop->data1;                   
40006278:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  uint32_t   count = args->count;                                     
4000627c:	f4 06 20 14 	ld  [ %i0 + 0x14 ], %i2                        
                                                                      
rtems_status_code                                                     
rtems_termios_read (void *arg)                                        
{                                                                     
  rtems_libio_rw_args_t *args = arg;                                  
  struct rtems_termios_tty *tty = args->iop->data1;                   
40006280:	fa 00 60 30 	ld  [ %g1 + 0x30 ], %i5                        
  return RTEMS_SUCCESSFUL;                                            
}                                                                     
                                                                      
rtems_status_code                                                     
rtems_termios_read (void *arg)                                        
{                                                                     
40006284:	b8 10 00 18 	mov  %i0, %i4                                  
  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);
40006288:	d0 07 60 14 	ld  [ %i5 + 0x14 ], %o0                        
rtems_termios_read (void *arg)                                        
{                                                                     
  rtems_libio_rw_args_t *args = arg;                                  
  struct rtems_termios_tty *tty = args->iop->data1;                   
  uint32_t   count = args->count;                                     
  char      *buffer = args->buffer;                                   
4000628c:	f0 06 20 10 	ld  [ %i0 + 0x10 ], %i0                        
  rtems_status_code sc;                                               
                                                                      
  sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
40006290:	92 10 20 00 	clr  %o1                                       
40006294:	40 00 04 f3 	call  40007660 <rtems_semaphore_obtain>        
40006298:	94 10 20 00 	clr  %o2                                       
  if (sc != RTEMS_SUCCESSFUL)                                         
4000629c:	80 a2 20 00 	cmp  %o0, 0                                    
400062a0:	12 80 00 e2 	bne  40006628 <rtems_termios_read+0x3b4>       <== NEVER TAKEN
400062a4:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
    return sc;                                                        
                                                                      
  if (rtems_termios_linesw[tty->t_line].l_read != NULL) {             
400062a8:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        
400062ac:	85 28 a0 05 	sll  %g2, 5, %g2                               
400062b0:	82 10 61 7c 	or  %g1, 0x17c, %g1                            
400062b4:	82 00 40 02 	add  %g1, %g2, %g1                             
400062b8:	c2 00 60 08 	ld  [ %g1 + 8 ], %g1                           
400062bc:	80 a0 60 00 	cmp  %g1, 0                                    
400062c0:	02 80 00 0a 	be  400062e8 <rtems_termios_read+0x74>         
400062c4:	92 10 00 1c 	mov  %i4, %o1                                  
    sc = rtems_termios_linesw[tty->t_line].l_read(tty,args);          
400062c8:	9f c0 40 00 	call  %g1                                      
400062cc:	90 10 00 1d 	mov  %i5, %o0                                  
400062d0:	b8 10 00 08 	mov  %o0, %i4                                  
    tty->tty_rcvwakeup = 0;                                           
    rtems_semaphore_release (tty->isem);                              
400062d4:	d0 07 60 14 	ld  [ %i5 + 0x14 ], %o0                        
400062d8:	40 00 05 2a 	call  40007780 <rtems_semaphore_release>       
400062dc:	c0 27 60 e4 	clr  [ %i5 + 0xe4 ]                            
    return sc;                                                        
400062e0:	10 80 00 d2 	b  40006628 <rtems_termios_read+0x3b4>         
400062e4:	90 10 00 1c 	mov  %i4, %o0                                  
  }                                                                   
                                                                      
  if (tty->cindex == tty->ccount) {                                   
400062e8:	c4 07 60 24 	ld  [ %i5 + 0x24 ], %g2                        
400062ec:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
400062f0:	80 a0 80 01 	cmp  %g2, %g1                                  
400062f4:	12 80 00 b6 	bne  400065cc <rtems_termios_read+0x358>       <== NEVER TAKEN
400062f8:	82 10 00 1a 	mov  %i2, %g1                                  
    tty->cindex = tty->ccount = 0;                                    
    tty->read_start_column = tty->column;                             
400062fc:	c2 07 60 28 	ld  [ %i5 + 0x28 ], %g1                        
    rtems_semaphore_release (tty->isem);                              
    return sc;                                                        
  }                                                                   
                                                                      
  if (tty->cindex == tty->ccount) {                                   
    tty->cindex = tty->ccount = 0;                                    
40006300:	c0 27 60 20 	clr  [ %i5 + 0x20 ]                            
    tty->read_start_column = tty->column;                             
40006304:	c2 27 60 2c 	st  %g1, [ %i5 + 0x2c ]                        
    if (tty->device.pollRead != NULL &&                               
40006308:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
4000630c:	80 a0 60 00 	cmp  %g1, 0                                    
40006310:	02 80 00 4b 	be  4000643c <rtems_termios_read+0x1c8>        
40006314:	c0 27 60 24 	clr  [ %i5 + 0x24 ]                            
40006318:	c2 07 60 b4 	ld  [ %i5 + 0xb4 ], %g1                        
4000631c:	80 a0 60 00 	cmp  %g1, 0                                    
40006320:	32 80 00 48 	bne,a   40006440 <rtems_termios_read+0x1cc>    
40006324:	f2 07 60 74 	ld  [ %i5 + 0x74 ], %i1                        
static rtems_status_code                                              
fillBufferPoll (struct rtems_termios_tty *tty)                        
{                                                                     
  int n;                                                              
                                                                      
  if (tty->termios.c_lflag & ICANON) {                                
40006328:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
4000632c:	80 88 60 02 	btst  2, %g1                                   
40006330:	02 80 00 2f 	be  400063ec <rtems_termios_read+0x178>        
40006334:	01 00 00 00 	nop                                            
    for (;;) {                                                        
      n = (*tty->device.pollRead)(tty->minor);                        
40006338:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
4000633c:	9f c0 40 00 	call  %g1                                      
40006340:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
      if (n < 0) {                                                    
40006344:	80 a2 20 00 	cmp  %o0, 0                                    
40006348:	16 80 00 06 	bge  40006360 <rtems_termios_read+0xec>        
4000634c:	90 0a 20 ff 	and  %o0, 0xff, %o0                            
        rtems_task_wake_after (1);                                    
40006350:	40 00 06 06 	call  40007b68 <rtems_task_wake_after>         
40006354:	90 10 20 01 	mov  1, %o0                                    
{                                                                     
  int n;                                                              
                                                                      
  if (tty->termios.c_lflag & ICANON) {                                
    for (;;) {                                                        
      n = (*tty->device.pollRead)(tty->minor);                        
40006358:	10 bf ff f9 	b  4000633c <rtems_termios_read+0xc8>          
4000635c:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
      if (n < 0) {                                                    
        rtems_task_wake_after (1);                                    
      } else {                                                        
        if  (siproc (n, tty))                                         
40006360:	7f ff ff 79 	call  40006144 <siproc>                        
40006364:	92 10 00 1d 	mov  %i5, %o1                                  
40006368:	80 a2 20 00 	cmp  %o0, 0                                    
4000636c:	22 bf ff f4 	be,a   4000633c <rtems_termios_read+0xc8>      
40006370:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
static rtems_status_code                                              
fillBufferQueue (struct rtems_termios_tty *tty)                       
{                                                                     
  rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout;        
  rtems_status_code sc;                                               
  int               wait = 1;                                         
40006374:	10 80 00 96 	b  400065cc <rtems_termios_read+0x358>         
40006378:	82 10 00 1a 	mov  %i2, %g1                                  
                                                                      
    then = rtems_clock_get_ticks_since_boot();                        
    for (;;) {                                                        
      n = (*tty->device.pollRead)(tty->minor);                        
      if (n < 0) {                                                    
        if (tty->termios.c_cc[VMIN]) {                                
4000637c:	c2 0f 60 47 	ldub  [ %i5 + 0x47 ], %g1                      
40006380:	80 a0 60 00 	cmp  %g1, 0                                    
40006384:	02 80 00 22 	be  4000640c <rtems_termios_read+0x198>        
40006388:	c2 0f 60 46 	ldub  [ %i5 + 0x46 ], %g1                      
          if (tty->termios.c_cc[VTIME] && tty->ccount) {              
4000638c:	80 88 60 ff 	btst  0xff, %g1                                
40006390:	32 80 00 1b 	bne,a   400063fc <rtems_termios_read+0x188>    <== ALWAYS TAKEN
40006394:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
          now = rtems_clock_get_ticks_since_boot();                   
          if ((now - then) > tty->vtimeTicks) {                       
            break;                                                    
          }                                                           
        }                                                             
        rtems_task_wake_after (1);                                    
40006398:	40 00 05 f4 	call  40007b68 <rtems_task_wake_after>         
4000639c:	90 10 20 01 	mov  1, %o0                                    
  } else {                                                            
    rtems_interval then, now;                                         
                                                                      
    then = rtems_clock_get_ticks_since_boot();                        
    for (;;) {                                                        
      n = (*tty->device.pollRead)(tty->minor);                        
400063a0:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        
400063a4:	9f c0 40 00 	call  %g1                                      
400063a8:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        
      if (n < 0) {                                                    
400063ac:	80 a2 20 00 	cmp  %o0, 0                                    
400063b0:	06 bf ff f3 	bl  4000637c <rtems_termios_read+0x108>        
400063b4:	90 0a 20 ff 	and  %o0, 0xff, %o0                            
            break;                                                    
          }                                                           
        }                                                             
        rtems_task_wake_after (1);                                    
      } else {                                                        
        siproc (n, tty);                                              
400063b8:	7f ff ff 63 	call  40006144 <siproc>                        
400063bc:	92 10 00 1d 	mov  %i5, %o1                                  
        if (tty->ccount >= tty->termios.c_cc[VMIN])                   
400063c0:	c2 0f 60 47 	ldub  [ %i5 + 0x47 ], %g1                      
400063c4:	c4 07 60 20 	ld  [ %i5 + 0x20 ], %g2                        
400063c8:	80 a0 80 01 	cmp  %g2, %g1                                  
400063cc:	16 80 00 7f 	bge  400065c8 <rtems_termios_read+0x354>       
400063d0:	80 a0 60 00 	cmp  %g1, 0                                    
          break;                                                      
        if (tty->termios.c_cc[VMIN] && tty->termios.c_cc[VTIME])      
400063d4:	22 bf ff f4 	be,a   400063a4 <rtems_termios_read+0x130>     <== NEVER TAKEN
400063d8:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        <== NOT EXECUTED
400063dc:	c2 0f 60 46 	ldub  [ %i5 + 0x46 ], %g1                      
400063e0:	80 a0 60 00 	cmp  %g1, 0                                    
400063e4:	22 bf ff f0 	be,a   400063a4 <rtems_termios_read+0x130>     <== NEVER TAKEN
400063e8:	c2 07 60 a0 	ld  [ %i5 + 0xa0 ], %g1                        <== NOT EXECUTED
      }                                                               
    }                                                                 
  } else {                                                            
    rtems_interval then, now;                                         
                                                                      
    then = rtems_clock_get_ticks_since_boot();                        
400063ec:	40 00 02 dd 	call  40006f60 <rtems_clock_get_ticks_since_boot>
400063f0:	01 00 00 00 	nop                                            
400063f4:	10 bf ff eb 	b  400063a0 <rtems_termios_read+0x12c>         
400063f8:	b6 10 00 08 	mov  %o0, %i3                                  
    for (;;) {                                                        
      n = (*tty->device.pollRead)(tty->minor);                        
      if (n < 0) {                                                    
        if (tty->termios.c_cc[VMIN]) {                                
          if (tty->termios.c_cc[VTIME] && tty->ccount) {              
400063fc:	80 a0 60 00 	cmp  %g1, 0                                    
40006400:	02 bf ff e6 	be  40006398 <rtems_termios_read+0x124>        
40006404:	01 00 00 00 	nop                                            
40006408:	30 80 00 04 	b,a   40006418 <rtems_termios_read+0x1a4>      
            if ((now - then) > tty->vtimeTicks) {                     
              break;                                                  
            }                                                         
          }                                                           
        } else {                                                      
          if (!tty->termios.c_cc[VTIME])                              
4000640c:	80 88 60 ff 	btst  0xff, %g1                                
40006410:	02 80 00 6f 	be  400065cc <rtems_termios_read+0x358>        <== NEVER TAKEN
40006414:	82 10 00 1a 	mov  %i2, %g1                                  
            break;                                                    
          now = rtems_clock_get_ticks_since_boot();                   
40006418:	40 00 02 d2 	call  40006f60 <rtems_clock_get_ticks_since_boot>
4000641c:	01 00 00 00 	nop                                            
          if ((now - then) > tty->vtimeTicks) {                       
40006420:	c2 07 60 54 	ld  [ %i5 + 0x54 ], %g1                        
40006424:	90 22 00 1b 	sub  %o0, %i3, %o0                             
40006428:	80 a2 00 01 	cmp  %o0, %g1                                  
4000642c:	08 bf ff db 	bleu  40006398 <rtems_termios_read+0x124>      
40006430:	82 10 00 1a 	mov  %i2, %g1                                  
      sc = fillBufferQueue (tty);                                     
                                                                      
    if (sc != RTEMS_SUCCESSFUL)                                       
      tty->cindex = tty->ccount = 0;                                  
  }                                                                   
  while (count && (tty->cindex < tty->ccount)) {                      
40006434:	10 80 00 67 	b  400065d0 <rtems_termios_read+0x35c>         
40006438:	80 a0 60 00 	cmp  %g1, 0                                    
 * Fill the input buffer from the raw input queue                     
 */                                                                   
static rtems_status_code                                              
fillBufferQueue (struct rtems_termios_tty *tty)                       
{                                                                     
  rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout;        
4000643c:	f2 07 60 74 	ld  [ %i5 + 0x74 ], %i1                        
  rtems_status_code sc;                                               
  int               wait = 1;                                         
40006440:	b6 10 20 01 	mov  1, %i3                                    
  while ( wait ) {                                                    
    /*                                                                
     * Process characters read from raw queue                         
     */                                                               
    while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&              
                       (tty->ccount < (CBUFSIZE-1))) {                
40006444:	21 10 00 5a 	sethi  %hi(0x40016800), %l0                    
             ==                (FL_MDXON | FL_ISNTXOF))               
            && ((tty->rawOutBufState == rob_idle)                     
          || (tty->flow_ctrl & FL_OSTOP))) {                          
          /* XON should be sent now... */                             
          (*tty->device.write)(                                       
            tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1);     
40006448:	a2 07 60 49 	add  %i5, 0x49, %l1                            
                                                                      
  while ( wait ) {                                                    
    /*                                                                
     * Process characters read from raw queue                         
     */                                                               
    while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&              
4000644c:	c4 07 60 5c 	ld  [ %i5 + 0x5c ], %g2                        
40006450:	c2 07 60 60 	ld  [ %i5 + 0x60 ], %g1                        
40006454:	80 a0 80 01 	cmp  %g2, %g1                                  
40006458:	12 80 00 07 	bne  40006474 <rtems_termios_read+0x200>       
4000645c:	c2 04 23 64 	ld  [ %l0 + 0x364 ], %g1                       
    }                                                                 
                                                                      
    /*                                                                
     * Wait for characters                                            
     */                                                               
    if ( wait ) {                                                     
40006460:	80 a6 e0 00 	cmp  %i3, 0                                    
40006464:	02 80 00 5a 	be  400065cc <rtems_termios_read+0x358>        
40006468:	82 10 00 1a 	mov  %i2, %g1                                  
      sc = rtems_semaphore_obtain(                                    
4000646c:	10 80 00 51 	b  400065b0 <rtems_termios_read+0x33c>         
40006470:	d0 07 60 68 	ld  [ %i5 + 0x68 ], %o0                        
                                                                      
  while ( wait ) {                                                    
    /*                                                                
     * Process characters read from raw queue                         
     */                                                               
    while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&              
40006474:	c4 07 60 20 	ld  [ %i5 + 0x20 ], %g2                        
                       (tty->ccount < (CBUFSIZE-1))) {                
40006478:	82 00 7f ff 	add  %g1, -1, %g1                              
                                                                      
  while ( wait ) {                                                    
    /*                                                                
     * Process characters read from raw queue                         
     */                                                               
    while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&              
4000647c:	80 a0 80 01 	cmp  %g2, %g1                                  
40006480:	1a bf ff f9 	bcc  40006464 <rtems_termios_read+0x1f0>       <== NEVER TAKEN
40006484:	80 a6 e0 00 	cmp  %i3, 0                                    
                       (tty->ccount < (CBUFSIZE-1))) {                
      unsigned char c;                                                
      unsigned int newHead;                                           
                                                                      
      newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size;        
40006488:	d0 07 60 5c 	ld  [ %i5 + 0x5c ], %o0                        
4000648c:	d2 07 60 64 	ld  [ %i5 + 0x64 ], %o1                        
40006490:	40 00 34 be 	call  40013788 <.urem>                         
40006494:	90 02 20 01 	inc  %o0                                       
      c = tty->rawInBuf.theBuf[newHead];                              
40006498:	c2 07 60 58 	ld  [ %i5 + 0x58 ], %g1                        
4000649c:	f2 08 40 08 	ldub  [ %g1 + %o0 ], %i1                       
      tty->rawInBuf.Head = newHead;                                   
400064a0:	d0 27 60 5c 	st  %o0, [ %i5 + 0x5c ]                        
      if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size)             
400064a4:	c2 07 60 60 	ld  [ %i5 + 0x60 ], %g1                        
400064a8:	c4 07 60 64 	ld  [ %i5 + 0x64 ], %g2                        
          % tty->rawInBuf.Size)                                       
400064ac:	d2 07 60 64 	ld  [ %i5 + 0x64 ], %o1                        
      unsigned int newHead;                                           
                                                                      
      newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size;        
      c = tty->rawInBuf.theBuf[newHead];                              
      tty->rawInBuf.Head = newHead;                                   
      if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size)             
400064b0:	82 00 80 01 	add  %g2, %g1, %g1                             
          % tty->rawInBuf.Size)                                       
400064b4:	40 00 34 b5 	call  40013788 <.urem>                         
400064b8:	90 20 40 08 	sub  %g1, %o0, %o0                             
      unsigned int newHead;                                           
                                                                      
      newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size;        
      c = tty->rawInBuf.theBuf[newHead];                              
      tty->rawInBuf.Head = newHead;                                   
      if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size)             
400064bc:	c2 07 60 bc 	ld  [ %i5 + 0xbc ], %g1                        
400064c0:	80 a2 00 01 	cmp  %o0, %g1                                  
400064c4:	3a 80 00 27 	bcc,a   40006560 <rtems_termios_read+0x2ec>    <== NEVER TAKEN
400064c8:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        <== NOT EXECUTED
          % tty->rawInBuf.Size)                                       
         < tty->lowwater) {                                           
        tty->flow_ctrl &= ~FL_IREQXOF;                                
400064cc:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
400064d0:	82 08 7f fe 	and  %g1, -2, %g1                              
400064d4:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        
        /* if tx stopped and XON should be sent... */                 
        if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF))               
400064d8:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
400064dc:	82 08 62 02 	and  %g1, 0x202, %g1                           
400064e0:	80 a0 62 02 	cmp  %g1, 0x202                                
400064e4:	12 80 00 11 	bne  40006528 <rtems_termios_read+0x2b4>       <== ALWAYS TAKEN
400064e8:	01 00 00 00 	nop                                            
             ==                (FL_MDXON | FL_ISNTXOF))               
            && ((tty->rawOutBufState == rob_idle)                     
400064ec:	c2 07 60 94 	ld  [ %i5 + 0x94 ], %g1                        <== NOT EXECUTED
400064f0:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
400064f4:	22 80 00 07 	be,a   40006510 <rtems_termios_read+0x29c>     <== NOT EXECUTED
400064f8:	c2 07 60 a4 	ld  [ %i5 + 0xa4 ], %g1                        <== NOT EXECUTED
          || (tty->flow_ctrl & FL_OSTOP))) {                          
400064fc:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
40006500:	80 88 60 20 	btst  0x20, %g1                                <== NOT EXECUTED
40006504:	02 80 00 09 	be  40006528 <rtems_termios_read+0x2b4>        <== NOT EXECUTED
40006508:	01 00 00 00 	nop                                            <== NOT EXECUTED
          /* XON should be sent now... */                             
          (*tty->device.write)(                                       
4000650c:	c2 07 60 a4 	ld  [ %i5 + 0xa4 ], %g1                        <== NOT EXECUTED
40006510:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        <== NOT EXECUTED
40006514:	92 10 00 11 	mov  %l1, %o1                                  <== NOT EXECUTED
40006518:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
4000651c:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
          }                                                           
        }                                                             
      }                                                               
                                                                      
      /* continue processing new character */                         
      if (tty->termios.c_lflag & ICANON) {                            
40006520:	10 80 00 10 	b  40006560 <rtems_termios_read+0x2ec>         <== NOT EXECUTED
40006524:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        <== NOT EXECUTED
            && ((tty->rawOutBufState == rob_idle)                     
          || (tty->flow_ctrl & FL_OSTOP))) {                          
          /* XON should be sent now... */                             
          (*tty->device.write)(                                       
            tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1);     
        } else if (tty->flow_ctrl & FL_MDRTS) {                       
40006528:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
4000652c:	80 88 61 00 	btst  0x100, %g1                               
40006530:	22 80 00 0c 	be,a   40006560 <rtems_termios_read+0x2ec>     <== ALWAYS TAKEN
40006534:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        
          tty->flow_ctrl &= ~FL_IRTSOFF;                              
40006538:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        <== NOT EXECUTED
4000653c:	82 08 7f fb 	and  %g1, -5, %g1                              <== NOT EXECUTED
40006540:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
          /* activate RTS line */                                     
          if (tty->device.startRemoteTx != NULL) {                    
40006544:	c2 07 60 b0 	ld  [ %i5 + 0xb0 ], %g1                        <== NOT EXECUTED
40006548:	80 a0 60 00 	cmp  %g1, 0                                    <== NOT EXECUTED
4000654c:	22 80 00 05 	be,a   40006560 <rtems_termios_read+0x2ec>     <== NOT EXECUTED
40006550:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        <== NOT EXECUTED
            tty->device.startRemoteTx(tty->minor);                    
40006554:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40006558:	d0 07 60 10 	ld  [ %i5 + 0x10 ], %o0                        <== NOT EXECUTED
          }                                                           
        }                                                             
      }                                                               
                                                                      
      /* continue processing new character */                         
      if (tty->termios.c_lflag & ICANON) {                            
4000655c:	c2 07 60 3c 	ld  [ %i5 + 0x3c ], %g1                        <== NOT EXECUTED
        if (siproc (c, tty))                                          
40006560:	92 10 00 1d 	mov  %i5, %o1                                  
          }                                                           
        }                                                             
      }                                                               
                                                                      
      /* continue processing new character */                         
      if (tty->termios.c_lflag & ICANON) {                            
40006564:	80 88 60 02 	btst  2, %g1                                   
40006568:	02 80 00 09 	be  4000658c <rtems_termios_read+0x318>        <== NEVER TAKEN
4000656c:	90 0e 60 ff 	and  %i1, 0xff, %o0                            
        if (siproc (c, tty))                                          
40006570:	7f ff fe f5 	call  40006144 <siproc>                        
40006574:	01 00 00 00 	nop                                            
40006578:	80 a2 20 00 	cmp  %o0, 0                                    
4000657c:	22 bf ff b4 	be,a   4000644c <rtems_termios_read+0x1d8>     
40006580:	f2 07 60 70 	ld  [ %i5 + 0x70 ], %i1                        
          wait = 0;                                                   
40006584:	10 80 00 09 	b  400065a8 <rtems_termios_read+0x334>         
40006588:	b6 10 20 00 	clr  %i3                                       
      } else {                                                        
        siproc (c, tty);                                              
4000658c:	7f ff fe ee 	call  40006144 <siproc>                        <== NOT EXECUTED
40006590:	01 00 00 00 	nop                                            <== NOT EXECUTED
        if (tty->ccount >= tty->termios.c_cc[VMIN])                   
40006594:	c2 0f 60 47 	ldub  [ %i5 + 0x47 ], %g1                      <== NOT EXECUTED
40006598:	c4 07 60 20 	ld  [ %i5 + 0x20 ], %g2                        <== NOT EXECUTED
4000659c:	80 a0 80 01 	cmp  %g2, %g1                                  <== NOT EXECUTED
400065a0:	36 80 00 02 	bge,a   400065a8 <rtems_termios_read+0x334>    <== NOT EXECUTED
400065a4:	b6 10 20 00 	clr  %i3                                       <== NOT EXECUTED
          wait = 0;                                                   
      }                                                               
      timeout = tty->rawInBufSemaphoreTimeout;                        
400065a8:	10 bf ff a9 	b  4000644c <rtems_termios_read+0x1d8>         
400065ac:	f2 07 60 70 	ld  [ %i5 + 0x70 ], %i1                        
                                                                      
    /*                                                                
     * Wait for characters                                            
     */                                                               
    if ( wait ) {                                                     
      sc = rtems_semaphore_obtain(                                    
400065b0:	d2 07 60 6c 	ld  [ %i5 + 0x6c ], %o1                        
400065b4:	40 00 04 2b 	call  40007660 <rtems_semaphore_obtain>        
400065b8:	94 10 00 19 	mov  %i1, %o2                                  
        tty->rawInBuf.Semaphore, tty->rawInBufSemaphoreOptions, timeout);
      if (sc != RTEMS_SUCCESSFUL)                                     
400065bc:	80 a2 20 00 	cmp  %o0, 0                                    
400065c0:	02 bf ff a3 	be  4000644c <rtems_termios_read+0x1d8>        <== ALWAYS TAKEN
400065c4:	01 00 00 00 	nop                                            
static rtems_status_code                                              
fillBufferQueue (struct rtems_termios_tty *tty)                       
{                                                                     
  rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout;        
  rtems_status_code sc;                                               
  int               wait = 1;                                         
400065c8:	82 10 00 1a 	mov  %i2, %g1                                  
      sc = fillBufferQueue (tty);                                     
                                                                      
    if (sc != RTEMS_SUCCESSFUL)                                       
      tty->cindex = tty->ccount = 0;                                  
  }                                                                   
  while (count && (tty->cindex < tty->ccount)) {                      
400065cc:	80 a0 60 00 	cmp  %g1, 0                                    
400065d0:	22 80 00 10 	be,a   40006610 <rtems_termios_read+0x39c>     
400065d4:	c4 07 20 14 	ld  [ %i4 + 0x14 ], %g2                        
400065d8:	c4 07 60 24 	ld  [ %i5 + 0x24 ], %g2                        
400065dc:	c6 07 60 20 	ld  [ %i5 + 0x20 ], %g3                        
400065e0:	80 a0 80 03 	cmp  %g2, %g3                                  
400065e4:	16 80 00 0a 	bge  4000660c <rtems_termios_read+0x398>       
400065e8:	88 00 a0 01 	add  %g2, 1, %g4                               
    *buffer++ = tty->cbuf[tty->cindex++];                             
400065ec:	c6 07 60 1c 	ld  [ %i5 + 0x1c ], %g3                        
400065f0:	c8 27 60 24 	st  %g4, [ %i5 + 0x24 ]                        
400065f4:	c8 08 c0 02 	ldub  [ %g3 + %g2 ], %g4                       
400065f8:	84 20 00 01 	neg  %g1, %g2                                  
400065fc:	86 06 00 1a 	add  %i0, %i2, %g3                             
    count--;                                                          
40006600:	82 00 7f ff 	add  %g1, -1, %g1                              
                                                                      
    if (sc != RTEMS_SUCCESSFUL)                                       
      tty->cindex = tty->ccount = 0;                                  
  }                                                                   
  while (count && (tty->cindex < tty->ccount)) {                      
    *buffer++ = tty->cbuf[tty->cindex++];                             
40006604:	10 bf ff f2 	b  400065cc <rtems_termios_read+0x358>         
40006608:	c8 28 c0 02 	stb  %g4, [ %g3 + %g2 ]                        
    count--;                                                          
  }                                                                   
  args->bytes_moved = args->count - count;                            
4000660c:	c4 07 20 14 	ld  [ %i4 + 0x14 ], %g2                        
  tty->tty_rcvwakeup = 0;                                             
  rtems_semaphore_release (tty->isem);                                
40006610:	d0 07 60 14 	ld  [ %i5 + 0x14 ], %o0                        
  }                                                                   
  while (count && (tty->cindex < tty->ccount)) {                      
    *buffer++ = tty->cbuf[tty->cindex++];                             
    count--;                                                          
  }                                                                   
  args->bytes_moved = args->count - count;                            
40006614:	82 20 80 01 	sub  %g2, %g1, %g1                             
40006618:	c2 27 20 1c 	st  %g1, [ %i4 + 0x1c ]                        
  tty->tty_rcvwakeup = 0;                                             
  rtems_semaphore_release (tty->isem);                                
4000661c:	40 00 04 59 	call  40007780 <rtems_semaphore_release>       
40006620:	c0 27 60 e4 	clr  [ %i5 + 0xe4 ]                            
  return sc;                                                          
40006624:	90 10 20 00 	clr  %o0                                       
}                                                                     
40006628:	81 c7 e0 08 	ret                                            
4000662c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

40004cfc <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 */ static int rtems_termios_refill_transmitter (struct rtems_termios_tty *tty) {
40004cfc:	9d e3 bf 98 	save  %sp, -104, %sp                           
  unsigned int newTail;                                               
  int nToSend;                                                        
  rtems_interrupt_lock_context lock_context;                          
  int len;                                                            
                                                                      
  rtems_termios_interrupt_lock_acquire (tty, &lock_context);          
40004d00:	7f ff ff f5 	call  40004cd4 <_ISR_lock_ISR_disable_and_acquire.isra.2>
40004d04:	90 07 bf fc 	add  %fp, -4, %o0                              
                                                                      
  /* check for XOF/XON to send */                                     
  if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF))         
40004d08:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        
 * in task-driven mode, this function is called in Tx task context    
 * in interrupt-driven mode, this function is called in TxIRQ context 
 */                                                                   
static int                                                            
rtems_termios_refill_transmitter (struct rtems_termios_tty *tty)      
{                                                                     
40004d0c:	ba 10 00 18 	mov  %i0, %i5                                  
  int len;                                                            
                                                                      
  rtems_termios_interrupt_lock_acquire (tty, &lock_context);          
                                                                      
  /* check for XOF/XON to send */                                     
  if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF))         
40004d10:	82 08 64 03 	and  %g1, 0x403, %g1                           
40004d14:	f4 06 20 10 	ld  [ %i0 + 0x10 ], %i2                        
40004d18:	80 a0 64 01 	cmp  %g1, 0x401                                
40004d1c:	12 80 00 0c 	bne  40004d4c <rtems_termios_refill_transmitter+0x50><== ALWAYS TAKEN
40004d20:	f6 06 20 a4 	ld  [ %i0 + 0xa4 ], %i3                        
      == (FL_MDXOF | FL_IREQXOF)) {                                   
    /* XOFF should be sent now... */                                  
    (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTOP]), 1);
40004d24:	90 10 00 1a 	mov  %i2, %o0                                  <== NOT EXECUTED
40004d28:	92 06 20 4a 	add  %i0, 0x4a, %o1                            <== NOT EXECUTED
40004d2c:	9f c6 c0 00 	call  %i3                                      <== NOT EXECUTED
40004d30:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
                                                                      
    tty->t_dqlen--;                                                   
40004d34:	c2 06 20 90 	ld  [ %i0 + 0x90 ], %g1                        <== NOT EXECUTED
40004d38:	82 00 7f ff 	add  %g1, -1, %g1                              <== NOT EXECUTED
40004d3c:	c2 26 20 90 	st  %g1, [ %i0 + 0x90 ]                        <== NOT EXECUTED
    tty->flow_ctrl |= FL_ISNTXOF;                                     
40004d40:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        <== NOT EXECUTED
40004d44:	10 80 00 0f 	b  40004d80 <rtems_termios_refill_transmitter+0x84><== NOT EXECUTED
40004d48:	82 10 60 02 	or  %g1, 2, %g1                                <== NOT EXECUTED
                                                                      
    nToSend = 1;                                                      
                                                                      
  } else if ((tty->flow_ctrl & (FL_IREQXOF | FL_ISNTXOF)) == FL_ISNTXOF) {
40004d4c:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        
40004d50:	82 08 60 03 	and  %g1, 3, %g1                               
40004d54:	80 a0 60 02 	cmp  %g1, 2                                    
40004d58:	12 80 00 0e 	bne  40004d90 <rtems_termios_refill_transmitter+0x94><== ALWAYS TAKEN
40004d5c:	90 10 00 1a 	mov  %i2, %o0                                  
     * 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, (void *)&(tty->termios.c_cc[VSTART]), 1);
40004d60:	92 06 20 49 	add  %i0, 0x49, %o1                            <== NOT EXECUTED
40004d64:	9f c6 c0 00 	call  %i3                                      <== NOT EXECUTED
40004d68:	94 10 20 01 	mov  1, %o2                                    <== NOT EXECUTED
                                                                      
    tty->t_dqlen--;                                                   
40004d6c:	c2 06 20 90 	ld  [ %i0 + 0x90 ], %g1                        <== NOT EXECUTED
40004d70:	82 00 7f ff 	add  %g1, -1, %g1                              <== NOT EXECUTED
40004d74:	c2 26 20 90 	st  %g1, [ %i0 + 0x90 ]                        <== NOT EXECUTED
    tty->flow_ctrl &= ~FL_ISNTXOF;                                    
40004d78:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        <== NOT EXECUTED
40004d7c:	82 08 7f fd 	and  %g1, -3, %g1                              <== NOT EXECUTED
40004d80:	c2 27 60 b8 	st  %g1, [ %i5 + 0xb8 ]                        <== NOT EXECUTED
                                                                      
    nToSend = 1;                                                      
40004d84:	b0 10 20 01 	mov  1, %i0                                    <== NOT EXECUTED
40004d88:	10 80 00 4f 	b  40004ec4 <rtems_termios_refill_transmitter+0x1c8><== NOT EXECUTED
40004d8c:	b2 10 20 00 	clr  %i1                                       <== NOT EXECUTED
  } else if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) {          
40004d90:	c4 06 20 80 	ld  [ %i0 + 0x80 ], %g2                        
40004d94:	c2 06 20 84 	ld  [ %i0 + 0x84 ], %g1                        
40004d98:	80 a0 80 01 	cmp  %g2, %g1                                  
40004d9c:	12 80 00 0b 	bne  40004dc8 <rtems_termios_refill_transmitter+0xcc>
40004da0:	f2 06 20 94 	ld  [ %i0 + 0x94 ], %i1                        
    /*                                                                
     * buffer was empty                                               
     */                                                               
    if (tty->rawOutBufState == rob_wait) {                            
40004da4:	b2 1e 60 02 	xor  %i1, 2, %i1                               
40004da8:	80 a0 00 19 	cmp  %g0, %i1                                  
       * this should never happen...                                  
       */                                                             
      wakeUpWriterTask = true;                                        
    }                                                                 
                                                                      
    (*tty->device.write) (tty->minor, NULL, 0);                       
40004dac:	90 10 00 1a 	mov  %i2, %o0                                  
    nToSend = 1;                                                      
  } else if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) {          
    /*                                                                
     * buffer was empty                                               
     */                                                               
    if (tty->rawOutBufState == rob_wait) {                            
40004db0:	b2 60 3f ff 	subx  %g0, -1, %i1                             
       * this should never happen...                                  
       */                                                             
      wakeUpWriterTask = true;                                        
    }                                                                 
                                                                      
    (*tty->device.write) (tty->minor, NULL, 0);                       
40004db4:	92 10 20 00 	clr  %o1                                       
40004db8:	94 10 20 00 	clr  %o2                                       
40004dbc:	9f c6 c0 00 	call  %i3                                      
40004dc0:	b0 10 20 00 	clr  %i0                                       
40004dc4:	30 80 00 40 	b,a   40004ec4 <rtems_termios_refill_transmitter+0x1c8>
    nToSend = 0;                                                      
  } else {                                                            
    len = tty->t_dqlen;                                               
    tty->t_dqlen = 0;                                                 
                                                                      
    newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;      
40004dc8:	c2 06 20 84 	ld  [ %i0 + 0x84 ], %g1                        
    }                                                                 
                                                                      
    (*tty->device.write) (tty->minor, NULL, 0);                       
    nToSend = 0;                                                      
  } else {                                                            
    len = tty->t_dqlen;                                               
40004dcc:	d0 06 20 90 	ld  [ %i0 + 0x90 ], %o0                        
    tty->t_dqlen = 0;                                                 
                                                                      
    newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;      
40004dd0:	d2 06 20 88 	ld  [ %i0 + 0x88 ], %o1                        
40004dd4:	90 02 00 01 	add  %o0, %g1, %o0                             
40004dd8:	40 00 3a 6c 	call  40013788 <.urem>                         
40004ddc:	c0 26 20 90 	clr  [ %i0 + 0x90 ]                            
    tty->rawOutBuf.Tail = newTail;                                    
40004de0:	d0 27 60 84 	st  %o0, [ %i5 + 0x84 ]                        
       * wake up any pending writer task                              
       */                                                             
      wakeUpWriterTask = true;                                        
    }                                                                 
                                                                      
    if (newTail == tty->rawOutBuf.Head) {                             
40004de4:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        
    len = tty->t_dqlen;                                               
    tty->t_dqlen = 0;                                                 
                                                                      
    newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;      
    tty->rawOutBuf.Tail = newTail;                                    
    if (tty->rawOutBufState == rob_wait) {                            
40004de8:	b2 1e 60 02 	xor  %i1, 2, %i1                               
40004dec:	80 a0 00 19 	cmp  %g0, %i1                                  
40004df0:	b2 60 3f ff 	subx  %g0, -1, %i1                             
       * wake up any pending writer task                              
       */                                                             
      wakeUpWriterTask = true;                                        
    }                                                                 
                                                                      
    if (newTail == tty->rawOutBuf.Head) {                             
40004df4:	80 a2 00 01 	cmp  %o0, %g1                                  
40004df8:	12 80 00 0f 	bne  40004e34 <rtems_termios_refill_transmitter+0x138>
40004dfc:	b8 10 00 08 	mov  %o0, %i4                                  
      /*                                                              
       * Buffer has become empty                                      
       */                                                             
      tty->rawOutBufState = rob_idle;                                 
40004e00:	c0 26 20 94 	clr  [ %i0 + 0x94 ]                            
      (*tty->device.write) (tty->minor, NULL, 0);                     
40004e04:	90 10 00 1a 	mov  %i2, %o0                                  
40004e08:	92 10 20 00 	clr  %o1                                       
40004e0c:	9f c6 c0 00 	call  %i3                                      
40004e10:	94 10 20 00 	clr  %o2                                       
      nToSend = 0;                                                    
                                                                      
      /*                                                              
       * check to see if snd wakeup callback was set                  
       */                                                             
      if ( tty->tty_snd.sw_pfn != NULL) {                             
40004e14:	c2 06 20 d4 	ld  [ %i0 + 0xd4 ], %g1                        
40004e18:	80 a0 60 00 	cmp  %g1, 0                                    
40004e1c:	02 80 00 29 	be  40004ec0 <rtems_termios_refill_transmitter+0x1c4><== ALWAYS TAKEN
40004e20:	b0 10 20 00 	clr  %i0                                       
        (*tty->tty_snd.sw_pfn)(&tty->termios, tty->tty_snd.sw_arg);   
40004e24:	d2 07 60 d8 	ld  [ %i5 + 0xd8 ], %o1                        <== NOT EXECUTED
40004e28:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40004e2c:	90 07 60 30 	add  %i5, 0x30, %o0                            <== NOT EXECUTED
40004e30:	30 80 00 24 	b,a   40004ec0 <rtems_termios_refill_transmitter+0x1c4><== NOT EXECUTED
      }                                                               
    }                                                                 
    /* check, whether output should stop due to received XOFF */      
    else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF))               
40004e34:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        
40004e38:	82 08 62 10 	and  %g1, 0x210, %g1                           
40004e3c:	80 a0 62 10 	cmp  %g1, 0x210                                
40004e40:	12 80 00 0d 	bne  40004e74 <rtems_termios_refill_transmitter+0x178><== ALWAYS TAKEN
40004e44:	01 00 00 00 	nop                                            
       ==                (FL_MDXON | FL_ORCVXOF)) {                   
      /* Buffer not empty, but output stops due to XOFF */            
      /* set flag, that output has been stopped */                    
      tty->flow_ctrl |= FL_OSTOP;                                     
40004e48:	c2 06 20 b8 	ld  [ %i0 + 0xb8 ], %g1                        <== NOT EXECUTED
      tty->rawOutBufState = rob_busy; /*apm*/                         
      (*tty->device.write) (tty->minor, NULL, 0);                     
40004e4c:	90 10 00 1a 	mov  %i2, %o0                                  <== 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 */                    
      tty->flow_ctrl |= FL_OSTOP;                                     
40004e50:	82 10 60 20 	or  %g1, 0x20, %g1                             <== NOT EXECUTED
40004e54:	c2 26 20 b8 	st  %g1, [ %i0 + 0xb8 ]                        <== NOT EXECUTED
      tty->rawOutBufState = rob_busy; /*apm*/                         
40004e58:	82 10 20 01 	mov  1, %g1                                    <== NOT EXECUTED
      (*tty->device.write) (tty->minor, NULL, 0);                     
40004e5c:	92 10 20 00 	clr  %o1                                       <== 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 */                    
      tty->flow_ctrl |= FL_OSTOP;                                     
      tty->rawOutBufState = rob_busy; /*apm*/                         
40004e60:	c2 26 20 94 	st  %g1, [ %i0 + 0x94 ]                        <== NOT EXECUTED
      (*tty->device.write) (tty->minor, NULL, 0);                     
40004e64:	94 10 20 00 	clr  %o2                                       <== NOT EXECUTED
40004e68:	9f c6 c0 00 	call  %i3                                      <== NOT EXECUTED
40004e6c:	b0 10 20 00 	clr  %i0                                       <== NOT EXECUTED
40004e70:	30 80 00 14 	b,a   40004ec0 <rtems_termios_refill_transmitter+0x1c4><== NOT EXECUTED
      nToSend = 0;                                                    
    } else {                                                          
      /*                                                              
       * Buffer not empty, start tranmitter                           
       */                                                             
      if (newTail > tty->rawOutBuf.Head)                              
40004e74:	c2 06 20 80 	ld  [ %i0 + 0x80 ], %g1                        
40004e78:	80 a2 00 01 	cmp  %o0, %g1                                  
40004e7c:	08 80 00 04 	bleu  40004e8c <rtems_termios_refill_transmitter+0x190>
40004e80:	01 00 00 00 	nop                                            
        nToSend = tty->rawOutBuf.Size - newTail;                      
40004e84:	f0 06 20 88 	ld  [ %i0 + 0x88 ], %i0                        
40004e88:	30 80 00 02 	b,a   40004e90 <rtems_termios_refill_transmitter+0x194>
      else                                                            
        nToSend = tty->rawOutBuf.Head - newTail;                      
40004e8c:	f0 06 20 80 	ld  [ %i0 + 0x80 ], %i0                        
      /* when flow control XON or XOF, don't send blocks of data     */
      /* to allow fast reaction on incoming flow ctrl and low latency*/
      /* for outgoing flow control                                   */
      if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) {                   
40004e90:	c2 07 60 b8 	ld  [ %i5 + 0xb8 ], %g1                        
40004e94:	80 88 66 00 	btst  0x600, %g1                               
40004e98:	02 80 00 03 	be  40004ea4 <rtems_termios_refill_transmitter+0x1a8>
40004e9c:	b0 26 00 1c 	sub  %i0, %i4, %i0                             
        nToSend = 1;                                                  
40004ea0:	b0 10 20 01 	mov  1, %i0                                    
      }                                                               
      tty->rawOutBufState = rob_busy; /*apm*/                         
      (*tty->device.write)(                                           
40004ea4:	d2 07 60 7c 	ld  [ %i5 + 0x7c ], %o1                        
      /* to allow fast reaction on incoming flow ctrl and low latency*/
      /* for outgoing flow control                                   */
      if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) {                   
        nToSend = 1;                                                  
      }                                                               
      tty->rawOutBufState = rob_busy; /*apm*/                         
40004ea8:	82 10 20 01 	mov  1, %g1                                    
      (*tty->device.write)(                                           
40004eac:	90 10 00 1a 	mov  %i2, %o0                                  
      /* to allow fast reaction on incoming flow ctrl and low latency*/
      /* for outgoing flow control                                   */
      if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) {                   
        nToSend = 1;                                                  
      }                                                               
      tty->rawOutBufState = rob_busy; /*apm*/                         
40004eb0:	c2 27 60 94 	st  %g1, [ %i5 + 0x94 ]                        
      (*tty->device.write)(                                           
40004eb4:	92 02 40 1c 	add  %o1, %i4, %o1                             
40004eb8:	9f c6 c0 00 	call  %i3                                      
40004ebc:	94 10 00 18 	mov  %i0, %o2                                  
        tty->minor, &tty->rawOutBuf.theBuf[newTail], nToSend);        
    }                                                                 
    tty->rawOutBuf.Tail = newTail; /*apm*/                            
40004ec0:	f8 27 60 84 	st  %i4, [ %i5 + 0x84 ]                        
  }                                                                   
                                                                      
  rtems_termios_interrupt_lock_release (tty, &lock_context);          
40004ec4:	7f ff ff 8a 	call  40004cec <_ISR_lock_Release_and_ISR_enable.isra.3>
40004ec8:	90 07 bf fc 	add  %fp, -4, %o0                              
                                                                      
  if (wakeUpWriterTask) {                                             
40004ecc:	80 8e 60 ff 	btst  0xff, %i1                                
40004ed0:	02 80 00 04 	be  40004ee0 <rtems_termios_refill_transmitter+0x1e4>
40004ed4:	01 00 00 00 	nop                                            
    rtems_semaphore_release (tty->rawOutBuf.Semaphore);               
40004ed8:	40 00 0a 2a 	call  40007780 <rtems_semaphore_release>       
40004edc:	d0 07 60 8c 	ld  [ %i5 + 0x8c ], %o0                        
  }                                                                   
                                                                      
  return nToSend;                                                     
}                                                                     
40004ee0:	81 c7 e0 08 	ret                                            
40004ee4:	81 e8 00 00 	restore                                        
                                                                      

40006934 <rtems_termios_rxdaemon>: /* * this task actually processes any receive events */ static rtems_task rtems_termios_rxdaemon(rtems_task_argument argument) {
40006934:	9d e3 bf 98 	save  %sp, -104, %sp                           
                                                                      
  while (1) {                                                         
    /*                                                                
     * wait for rtems event                                           
     */                                                               
    rtems_event_receive(                                              
40006938:	90 10 20 03 	mov  3, %o0                                    
4000693c:	92 10 20 02 	mov  2, %o1                                    
40006940:	94 10 20 00 	clr  %o2                                       
40006944:	40 00 01 ae 	call  40006ffc <rtems_event_receive>           
40006948:	96 07 bf fc 	add  %fp, -4, %o3                              
      (TERMIOS_RX_PROC_EVENT | TERMIOS_RX_TERMINATE_EVENT),           
      RTEMS_EVENT_ANY | RTEMS_WAIT,                                   
      RTEMS_NO_TIMEOUT,                                               
      &the_event                                                      
    );                                                                
    if ((the_event & TERMIOS_RX_TERMINATE_EVENT) != 0) {              
4000694c:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40006950:	80 88 60 01 	btst  1, %g1                                   
40006954:	22 80 00 06 	be,a   4000696c <rtems_termios_rxdaemon+0x38>  <== ALWAYS TAKEN
40006958:	c2 06 20 a0 	ld  [ %i0 + 0xa0 ], %g1                        
      tty->rxTaskId = 0;                                              
4000695c:	c0 26 20 c4 	clr  [ %i0 + 0xc4 ]                            <== NOT EXECUTED
      rtems_task_delete(RTEMS_SELF);                                  
40006960:	40 00 04 18 	call  400079c0 <rtems_task_delete>             <== NOT EXECUTED
40006964:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
    }                                                                 
                                                                      
    /*                                                                
     * do something                                                   
     */                                                               
    c = tty->device.pollRead(tty->minor);                             
40006968:	c2 06 20 a0 	ld  [ %i0 + 0xa0 ], %g1                        <== NOT EXECUTED
4000696c:	9f c0 40 00 	call  %g1                                      
40006970:	d0 06 20 10 	ld  [ %i0 + 0x10 ], %o0                        
    if (c != EOF) {                                                   
40006974:	80 a2 3f ff 	cmp  %o0, -1                                   
40006978:	22 bf ff f1 	be,a   4000693c <rtems_termios_rxdaemon+0x8>   
4000697c:	90 10 20 03 	mov  3, %o0                                    
      /*                                                              
       * pollRead did call enqueue on its own                         
       */                                                             
      c_buf = c;                                                      
40006980:	d0 2f bf fb 	stb  %o0, [ %fp + -5 ]                         
      rtems_termios_enqueue_raw_characters ( tty,&c_buf,1);           
40006984:	92 07 bf fb 	add  %fp, -5, %o1                              
40006988:	90 10 00 18 	mov  %i0, %o0                                  
4000698c:	7f ff ff 29 	call  40006630 <rtems_termios_enqueue_raw_characters>
40006990:	94 10 20 01 	mov  1, %o2                                    
                                                                      
  while (1) {                                                         
    /*                                                                
     * wait for rtems event                                           
     */                                                               
    rtems_event_receive(                                              
40006994:	10 bf ff ea 	b  4000693c <rtems_termios_rxdaemon+0x8>       
40006998:	90 10 20 03 	mov  3, %o0                                    
                                                                      

40004ee8 <rtems_termios_txdaemon>: /* * this task actually processes any transmit events */ static rtems_task rtems_termios_txdaemon(rtems_task_argument argument) {
40004ee8:	9d e3 bf 98 	save  %sp, -104, %sp                           
    }                                                                 
                                                                      
    /*                                                                
     * call any line discipline start function                        
     */                                                               
    if (rtems_termios_linesw[tty->t_line].l_start != NULL) {          
40004eec:	3b 10 00 5f 	sethi  %hi(0x40017c00), %i5                    
40004ef0:	ba 17 61 7c 	or  %i5, 0x17c, %i5	! 40017d7c <rtems_termios_linesw>
                                                                      
  while (1) {                                                         
    /*                                                                
     * wait for rtems event                                           
     */                                                               
    rtems_event_receive(                                              
40004ef4:	90 10 20 03 	mov  3, %o0                                    
40004ef8:	92 10 20 02 	mov  2, %o1                                    
40004efc:	94 10 20 00 	clr  %o2                                       
40004f00:	40 00 08 3f 	call  40006ffc <rtems_event_receive>           
40004f04:	96 07 bf fc 	add  %fp, -4, %o3                              
       (TERMIOS_TX_START_EVENT | TERMIOS_TX_TERMINATE_EVENT),         
       RTEMS_EVENT_ANY | RTEMS_WAIT,                                  
       RTEMS_NO_TIMEOUT,                                              
       &the_event                                                     
    );                                                                
    if ((the_event & TERMIOS_TX_TERMINATE_EVENT) != 0) {              
40004f08:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40004f0c:	80 88 60 01 	btst  1, %g1                                   
40004f10:	22 80 00 06 	be,a   40004f28 <rtems_termios_txdaemon+0x40>  <== ALWAYS TAKEN
40004f14:	c2 06 20 cc 	ld  [ %i0 + 0xcc ], %g1                        
      tty->txTaskId = 0;                                              
40004f18:	c0 26 20 c8 	clr  [ %i0 + 0xc8 ]                            <== NOT EXECUTED
      rtems_task_delete(RTEMS_SELF);                                  
40004f1c:	40 00 0a a9 	call  400079c0 <rtems_task_delete>             <== NOT EXECUTED
40004f20:	90 10 20 00 	clr  %o0                                       <== NOT EXECUTED
    }                                                                 
                                                                      
    /*                                                                
     * call any line discipline start function                        
     */                                                               
    if (rtems_termios_linesw[tty->t_line].l_start != NULL) {          
40004f24:	c2 06 20 cc 	ld  [ %i0 + 0xcc ], %g1                        <== NOT EXECUTED
40004f28:	83 28 60 05 	sll  %g1, 5, %g1                               
40004f2c:	82 07 40 01 	add  %i5, %g1, %g1                             
40004f30:	c2 00 60 14 	ld  [ %g1 + 0x14 ], %g1                        
40004f34:	80 a0 60 00 	cmp  %g1, 0                                    
40004f38:	02 80 00 04 	be  40004f48 <rtems_termios_txdaemon+0x60>     <== ALWAYS TAKEN
40004f3c:	01 00 00 00 	nop                                            
      rtems_termios_linesw[tty->t_line].l_start(tty);                 
40004f40:	9f c0 40 00 	call  %g1                                      <== NOT EXECUTED
40004f44:	90 10 00 18 	mov  %i0, %o0                                  <== NOT EXECUTED
    }                                                                 
                                                                      
    /*                                                                
     * try to push further characters to device                       
     */                                                               
    rtems_termios_refill_transmitter(tty);                            
40004f48:	7f ff ff 6d 	call  40004cfc <rtems_termios_refill_transmitter>
40004f4c:	90 10 00 18 	mov  %i0, %o0                                  
  }                                                                   
40004f50:	10 bf ff ea 	b  40004ef8 <rtems_termios_txdaemon+0x10>      
40004f54:	90 10 20 03 	mov  3, %o0                                    
                                                                      

400061ac <rtems_termios_write>: rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) {
400061ac:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_libio_rw_args_t *args = arg;                                  
  struct rtems_termios_tty *tty = args->iop->data1;                   
400061b0:	c2 06 00 00 	ld  [ %i0 ], %g1                               
  rtems_status_code sc;                                               
                                                                      
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
400061b4:	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;                   
400061b8:	fa 00 60 30 	ld  [ %g1 + 0x30 ], %i5                        
  rtems_status_code sc;                                               
                                                                      
  sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
400061bc:	94 10 20 00 	clr  %o2                                       
400061c0:	40 00 05 28 	call  40007660 <rtems_semaphore_obtain>        
400061c4:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
  if (sc != RTEMS_SUCCESSFUL)                                         
400061c8:	80 a2 20 00 	cmp  %o0, 0                                    
400061cc:	12 80 00 28 	bne  4000626c <rtems_termios_write+0xc0>       <== NEVER TAKEN
400061d0:	03 10 00 5f 	sethi  %hi(0x40017c00), %g1                    
    return sc;                                                        
  if (rtems_termios_linesw[tty->t_line].l_write != NULL) {            
400061d4:	c4 07 60 cc 	ld  [ %i5 + 0xcc ], %g2                        
400061d8:	85 28 a0 05 	sll  %g2, 5, %g2                               
400061dc:	82 10 61 7c 	or  %g1, 0x17c, %g1                            
400061e0:	82 00 40 02 	add  %g1, %g2, %g1                             
400061e4:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
400061e8:	80 a0 60 00 	cmp  %g1, 0                                    
400061ec:	02 80 00 09 	be  40006210 <rtems_termios_write+0x64>        
400061f0:	92 10 00 18 	mov  %i0, %o1                                  
    sc = rtems_termios_linesw[tty->t_line].l_write(tty,args);         
400061f4:	9f c0 40 00 	call  %g1                                      
400061f8:	90 10 00 1d 	mov  %i5, %o0                                  
400061fc:	b8 10 00 08 	mov  %o0, %i4                                  
    rtems_semaphore_release (tty->osem);                              
40006200:	40 00 05 60 	call  40007780 <rtems_semaphore_release>       
40006204:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
    return sc;                                                        
40006208:	10 80 00 19 	b  4000626c <rtems_termios_write+0xc0>         
4000620c:	90 10 00 1c 	mov  %i4, %o0                                  
  }                                                                   
  if (tty->termios.c_oflag & OPOST) {                                 
40006210:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
    uint32_t   count = args->count;                                   
    char      *buffer = args->buffer;                                 
    while (count--)                                                   
40006214:	b6 10 20 00 	clr  %i3                                       
  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) {                                 
40006218:	80 88 60 01 	btst  1, %g1                                   
4000621c:	f4 06 20 14 	ld  [ %i0 + 0x14 ], %i2                        
40006220:	02 80 00 0a 	be  40006248 <rtems_termios_write+0x9c>        <== NEVER TAKEN
40006224:	f2 06 20 10 	ld  [ %i0 + 0x10 ], %i1                        
    uint32_t   count = args->count;                                   
    char      *buffer = args->buffer;                                 
    while (count--)                                                   
40006228:	80 a6 c0 1a 	cmp  %i3, %i2                                  
4000622c:	02 80 00 0b 	be  40006258 <rtems_termios_write+0xac>        
40006230:	92 10 00 1d 	mov  %i5, %o1                                  
      oproc (*buffer++, tty);                                         
40006234:	d0 0e 40 1b 	ldub  [ %i1 + %i3 ], %o0                       
40006238:	7f ff fe 4c 	call  40005b68 <oproc>                         
4000623c:	b6 06 e0 01 	inc  %i3                                       
    return sc;                                                        
  }                                                                   
  if (tty->termios.c_oflag & OPOST) {                                 
    uint32_t   count = args->count;                                   
    char      *buffer = args->buffer;                                 
    while (count--)                                                   
40006240:	10 bf ff fb 	b  4000622c <rtems_termios_write+0x80>         
40006244:	80 a6 c0 1a 	cmp  %i3, %i2                                  
      oproc (*buffer++, tty);                                         
    args->bytes_moved = args->count;                                  
  } else {                                                            
    rtems_termios_puts (args->buffer, args->count, tty);              
40006248:	90 10 00 19 	mov  %i1, %o0                                  <== NOT EXECUTED
4000624c:	92 10 00 1a 	mov  %i2, %o1                                  <== NOT EXECUTED
40006250:	7f ff fd fe 	call  40005a48 <rtems_termios_puts>            <== NOT EXECUTED
40006254:	94 10 00 1d 	mov  %i5, %o2                                  <== NOT EXECUTED
    args->bytes_moved = args->count;                                  
40006258:	c2 06 20 14 	ld  [ %i0 + 0x14 ], %g1                        
  }                                                                   
  rtems_semaphore_release (tty->osem);                                
4000625c:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
40006260:	40 00 05 48 	call  40007780 <rtems_semaphore_release>       
40006264:	c2 26 20 1c 	st  %g1, [ %i0 + 0x1c ]                        
  return sc;                                                          
40006268:	90 10 20 00 	clr  %o0                                       
}                                                                     
4000626c:	81 c7 e0 08 	ret                                            
40006270:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000b7c0 <rtems_timer_cancel>: */ rtems_status_code rtems_timer_cancel( rtems_id id ) {
4000b7c0:	9d e3 bf 98 	save  %sp, -104, %sp                           
RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get (                      
  Objects_Id         id,                                              
  Objects_Locations *location                                         
)                                                                     
{                                                                     
  return (Timer_Control *)                                            
4000b7c4:	11 10 00 79 	sethi  %hi(0x4001e400), %o0                    
4000b7c8:	92 10 00 18 	mov  %i0, %o1                                  
4000b7cc:	90 12 20 40 	or  %o0, 0x40, %o0                             
4000b7d0:	40 00 06 19 	call  4000d034 <_Objects_Get>                  
4000b7d4:	94 07 bf fc 	add  %fp, -4, %o2                              
  Timer_Control   *the_timer;                                         
  Objects_Locations       location;                                   
                                                                      
  the_timer = _Timer_Get( id, &location );                            
  switch ( location ) {                                               
4000b7d8:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000b7dc:	80 a0 60 00 	cmp  %g1, 0                                    
4000b7e0:	12 80 00 0c 	bne  4000b810 <rtems_timer_cancel+0x50>        
4000b7e4:	01 00 00 00 	nop                                            
                                                                      
    case OBJECTS_LOCAL:                                               
      if ( !_Timer_Is_dormant_class( the_timer->the_class ) )         
4000b7e8:	c2 02 20 38 	ld  [ %o0 + 0x38 ], %g1                        
4000b7ec:	80 a0 60 04 	cmp  %g1, 4                                    
4000b7f0:	02 80 00 04 	be  4000b800 <rtems_timer_cancel+0x40>         <== NEVER TAKEN
4000b7f4:	01 00 00 00 	nop                                            
        (void) _Watchdog_Remove( &the_timer->Ticker );                
4000b7f8:	40 00 0e 28 	call  4000f098 <_Watchdog_Remove>              
4000b7fc:	90 02 20 10 	add  %o0, 0x10, %o0                            
4000b800:	40 00 09 5e 	call  4000dd78 <_Thread_Enable_dispatch>       
4000b804:	b0 10 20 00 	clr  %i0                                       
      _Objects_Put( &the_timer->Object );                             
      return RTEMS_SUCCESSFUL;                                        
4000b808:	81 c7 e0 08 	ret                                            
4000b80c:	81 e8 00 00 	restore                                        
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return RTEMS_INVALID_ID;                                            
}                                                                     
4000b810:	81 c7 e0 08 	ret                                            
4000b814:	91 e8 20 04 	restore  %g0, 4, %o0                           
                                                                      

4000b830 <rtems_timer_server_fire_when>: rtems_id id, rtems_time_of_day *wall_time, rtems_timer_service_routine_entry routine, void *user_data ) {
4000b830:	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;                 
4000b834:	03 10 00 74 	sethi  %hi(0x4001d000), %g1                    
4000b838:	f8 00 61 9c 	ld  [ %g1 + 0x19c ], %i4	! 4001d19c <_Timer_server>
                                                                      
  if ( !timer_server )                                                
4000b83c:	80 a7 20 00 	cmp  %i4, 0                                    
4000b840:	02 80 00 33 	be  4000b90c <rtems_timer_server_fire_when+0xdc>
4000b844:	82 10 20 0e 	mov  0xe, %g1                                  
    return RTEMS_INCORRECT_STATE;                                     
                                                                      
  if ( !_TOD_Is_set() )                                               
4000b848:	03 10 00 74 	sethi  %hi(0x4001d000), %g1                    
4000b84c:	c4 08 62 38 	ldub  [ %g1 + 0x238 ], %g2	! 4001d238 <_TOD+0x18>
4000b850:	80 a0 a0 00 	cmp  %g2, 0                                    
4000b854:	02 80 00 2e 	be  4000b90c <rtems_timer_server_fire_when+0xdc><== NEVER TAKEN
4000b858:	82 10 20 0b 	mov  0xb, %g1                                  
    return RTEMS_NOT_DEFINED;                                         
                                                                      
  if ( !routine )                                                     
4000b85c:	80 a6 a0 00 	cmp  %i2, 0                                    
4000b860:	02 80 00 2b 	be  4000b90c <rtems_timer_server_fire_when+0xdc>
4000b864:	82 10 20 09 	mov  9, %g1                                    
    return RTEMS_INVALID_ADDRESS;                                     
                                                                      
  if ( !_TOD_Validate( wall_time ) )                                  
4000b868:	7f ff fb c8 	call  4000a788 <_TOD_Validate>                 
4000b86c:	90 10 00 19 	mov  %i1, %o0                                  
4000b870:	80 a2 20 00 	cmp  %o0, 0                                    
4000b874:	02 80 00 26 	be  4000b90c <rtems_timer_server_fire_when+0xdc>
4000b878:	82 10 20 14 	mov  0x14, %g1                                 
    return RTEMS_INVALID_CLOCK;                                       
                                                                      
  seconds = _TOD_To_seconds( wall_time );                             
4000b87c:	7f ff fb 89 	call  4000a6a0 <_TOD_To_seconds>               
4000b880:	90 10 00 19 	mov  %i1, %o0                                  
  if ( seconds <= _TOD_Seconds_since_epoch() )                        
4000b884:	40 00 03 c3 	call  4000c790 <_TOD_Seconds_since_epoch>      
4000b888:	b2 10 00 08 	mov  %o0, %i1                                  
4000b88c:	80 a6 40 08 	cmp  %i1, %o0                                  
4000b890:	08 80 00 1f 	bleu  4000b90c <rtems_timer_server_fire_when+0xdc>
4000b894:	82 10 20 14 	mov  0x14, %g1                                 
4000b898:	11 10 00 74 	sethi  %hi(0x4001d000), %o0                    
4000b89c:	92 10 00 18 	mov  %i0, %o1                                  
4000b8a0:	90 12 21 60 	or  %o0, 0x160, %o0                            
4000b8a4:	40 00 06 b9 	call  4000d388 <_Objects_Get>                  
4000b8a8:	94 07 bf fc 	add  %fp, -4, %o2                              
    return RTEMS_INVALID_CLOCK;                                       
                                                                      
  the_timer = _Timer_Get( id, &location );                            
  switch ( location ) {                                               
4000b8ac:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000b8b0:	80 a0 60 00 	cmp  %g1, 0                                    
4000b8b4:	12 80 00 15 	bne  4000b908 <rtems_timer_server_fire_when+0xd8>
4000b8b8:	ba 10 00 08 	mov  %o0, %i5                                  
                                                                      
    case OBJECTS_LOCAL:                                               
      (void) _Watchdog_Remove( &the_timer->Ticker );                  
4000b8bc:	40 00 0f 1b 	call  4000f528 <_Watchdog_Remove>              
4000b8c0:	90 02 20 10 	add  %o0, 0x10, %o0                            
      the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;               
4000b8c4:	82 10 20 03 	mov  3, %g1                                    
  Watchdog_Service_routine_entry  routine,                            
  Objects_Id                      id,                                 
  void                           *user_data                           
)                                                                     
{                                                                     
  the_watchdog->state     = WATCHDOG_INACTIVE;                        
4000b8c8:	c0 27 60 18 	clr  [ %i5 + 0x18 ]                            
4000b8cc:	c2 27 60 38 	st  %g1, [ %i5 + 0x38 ]                        
  the_watchdog->routine   = routine;                                  
4000b8d0:	f4 27 60 2c 	st  %i2, [ %i5 + 0x2c ]                        
  the_watchdog->id        = id;                                       
4000b8d4:	f0 27 60 30 	st  %i0, [ %i5 + 0x30 ]                        
      _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
      the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
4000b8d8:	40 00 03 ae 	call  4000c790 <_TOD_Seconds_since_epoch>      
4000b8dc:	f6 27 60 34 	st  %i3, [ %i5 + 0x34 ]                        
                                                                      
      (*timer_server->schedule_operation)( timer_server, the_timer ); 
4000b8e0:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1                           
                                                                      
    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();
4000b8e4:	90 26 40 08 	sub  %i1, %o0, %o0                             
                                                                      
      (*timer_server->schedule_operation)( timer_server, the_timer ); 
4000b8e8:	92 10 00 1d 	mov  %i5, %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();
4000b8ec:	d0 27 60 1c 	st  %o0, [ %i5 + 0x1c ]                        
                                                                      
      (*timer_server->schedule_operation)( timer_server, the_timer ); 
4000b8f0:	9f c0 40 00 	call  %g1                                      
4000b8f4:	90 10 00 1c 	mov  %i4, %o0                                  
4000b8f8:	40 00 0a 1a 	call  4000e160 <_Thread_Enable_dispatch>       
4000b8fc:	01 00 00 00 	nop                                            
                                                                      
      _Objects_Put( &the_timer->Object );                             
      return RTEMS_SUCCESSFUL;                                        
4000b900:	10 80 00 03 	b  4000b90c <rtems_timer_server_fire_when+0xdc>
4000b904:	82 10 20 00 	clr  %g1	! 0 <_TLS_BSS_size>                   
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  return RTEMS_INVALID_ID;                                            
4000b908:	82 10 20 04 	mov  4, %g1                                    
}                                                                     
4000b90c:	81 c7 e0 08 	ret                                            
4000b910:	91 e8 00 01 	restore  %g0, %g1, %o0                         
                                                                      

40012c28 <rtems_verror>: int rtems_verror( rtems_error_code_t error_flag, const char *printf_format, va_list arglist ) {
40012c28:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int               local_errno = 0;                                  
  int               chars_written = 0;                                
  rtems_status_code status;                                           
                                                                      
  if (error_flag & RTEMS_ERROR_PANIC) {                               
40012c2c:	03 08 00 00 	sethi  %hi(0x20000000), %g1                    
40012c30:	80 8e 00 01 	btst  %i0, %g1                                 
40012c34:	12 80 00 0c 	bne  40012c64 <rtems_verror+0x3c>              
40012c38:	ba 10 00 18 	mov  %i0, %i5                                  
    /* don't aggravate things */                                      
    if (rtems_panic_in_progress > 2)                                  
      return 0;                                                       
  }                                                                   
                                                                      
  (void) fflush(stdout);            /* in case stdout/stderr same */  
40012c3c:	7f ff b9 cd 	call  40001370 <__getreent>                    
40012c40:	39 1c 00 00 	sethi  %hi(0x70000000), %i4                    
40012c44:	40 00 14 95 	call  40017e98 <fflush>                        
40012c48:	d0 02 20 08 	ld  [ %o0 + 8 ], %o0                           
                                                                      
  status = error_flag & ~RTEMS_ERROR_MASK;                            
  if (error_flag & RTEMS_ERROR_ERRNO)     /* include errno? */        
40012c4c:	03 10 00 00 	sethi  %hi(0x40000000), %g1                    
40012c50:	80 8f 40 01 	btst  %i5, %g1                                 
40012c54:	12 80 00 13 	bne  40012ca0 <rtems_verror+0x78>              
40012c58:	b8 2f 40 1c 	andn  %i5, %i4, %i4                            
  rtems_error_code_t  error_flag,                                     
  const char         *printf_format,                                  
  va_list             arglist                                         
)                                                                     
{                                                                     
  int               local_errno = 0;                                  
40012c5c:	10 80 00 14 	b  40012cac <rtems_verror+0x84>                
40012c60:	ba 10 20 00 	clr  %i5                                       
  int               chars_written = 0;                                
  rtems_status_code status;                                           
                                                                      
  if (error_flag & RTEMS_ERROR_PANIC) {                               
    if (rtems_panic_in_progress++)                                    
40012c64:	03 10 00 c3 	sethi  %hi(0x40030c00), %g1                    
40012c68:	c4 00 60 c8 	ld  [ %g1 + 0xc8 ], %g2	! 40030cc8 <rtems_panic_in_progress>
40012c6c:	86 00 a0 01 	add  %g2, 1, %g3                               
40012c70:	80 a0 a0 00 	cmp  %g2, 0                                    
40012c74:	02 80 00 05 	be  40012c88 <rtems_verror+0x60>               <== ALWAYS TAKEN
40012c78:	c6 20 60 c8 	st  %g3, [ %g1 + 0xc8 ]                        
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40012c7c:	c6 01 a0 10 	ld  [ %g6 + 0x10 ], %g3                        <== NOT EXECUTED
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40012c80:	86 00 e0 01 	inc  %g3                                       <== NOT EXECUTED
    _Thread_Dispatch_disable_level = disable_level;                   
40012c84:	c6 21 a0 10 	st  %g3, [ %g6 + 0x10 ]                        <== NOT EXECUTED
      _Thread_Disable_dispatch();       /* disable task switches */   
                                                                      
    /* don't aggravate things */                                      
    if (rtems_panic_in_progress > 2)                                  
40012c88:	c2 00 60 c8 	ld  [ %g1 + 0xc8 ], %g1                        
40012c8c:	80 a0 60 02 	cmp  %g1, 2                                    
40012c90:	04 bf ff eb 	ble  40012c3c <rtems_verror+0x14>              <== ALWAYS TAKEN
40012c94:	b0 10 20 00 	clr  %i0                                       
40012c98:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40012c9c:	81 e8 00 00 	restore                                        <== 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;                                              
40012ca0:	40 00 13 7b 	call  40017a8c <__errno>                       
40012ca4:	01 00 00 00 	nop                                            
40012ca8:	fa 02 00 00 	ld  [ %o0 ], %i5                               
  #if defined(RTEMS_MULTIPROCESSING)                                  
    if (_System_state_Is_multiprocessing)                             
      fprintf(stderr, "[%" PRIu32 "] ", _Configuration_MP_table->node);
  #endif                                                              
                                                                      
  chars_written += vfprintf(stderr, printf_format, arglist);          
40012cac:	7f ff b9 b1 	call  40001370 <__getreent>                    
40012cb0:	01 00 00 00 	nop                                            
40012cb4:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         
40012cb8:	92 10 00 19 	mov  %i1, %o1                                  
40012cbc:	40 00 37 a7 	call  40020b58 <vfprintf>                      
40012cc0:	94 10 00 1a 	mov  %i2, %o2                                  
                                                                      
  if (status)                                                         
40012cc4:	80 a7 20 00 	cmp  %i4, 0                                    
40012cc8:	02 80 00 0d 	be  40012cfc <rtems_verror+0xd4>               
40012ccc:	b0 10 00 08 	mov  %o0, %i0                                  
    chars_written +=                                                  
      fprintf(stderr, " (status: %s)", rtems_status_text(status));    
40012cd0:	7f ff b9 a8 	call  40001370 <__getreent>                    
40012cd4:	01 00 00 00 	nop                                            
40012cd8:	f6 02 20 0c 	ld  [ %o0 + 0xc ], %i3                         
40012cdc:	7f ff e2 79 	call  4000b6c0 <rtems_status_text>             
40012ce0:	90 10 00 1c 	mov  %i4, %o0                                  
40012ce4:	13 10 00 b3 	sethi  %hi(0x4002cc00), %o1                    
40012ce8:	94 10 00 08 	mov  %o0, %o2                                  
40012cec:	92 12 61 70 	or  %o1, 0x170, %o1                            
40012cf0:	40 00 15 f1 	call  400184b4 <fprintf>                       
40012cf4:	90 10 00 1b 	mov  %i3, %o0                                  
  #endif                                                              
                                                                      
  chars_written += vfprintf(stderr, printf_format, arglist);          
                                                                      
  if (status)                                                         
    chars_written +=                                                  
40012cf8:	b0 06 00 08 	add  %i0, %o0, %i0                             
      fprintf(stderr, " (status: %s)", rtems_status_text(status));    
                                                                      
  if (local_errno) {                                                  
40012cfc:	80 a7 60 00 	cmp  %i5, 0                                    
40012d00:	02 80 00 1d 	be  40012d74 <rtems_verror+0x14c>              
40012d04:	01 00 00 00 	nop                                            
    if ((local_errno > 0) && *strerror(local_errno))                  
40012d08:	04 80 00 12 	ble  40012d50 <rtems_verror+0x128>             
40012d0c:	01 00 00 00 	nop                                            
40012d10:	40 00 21 7a 	call  4001b2f8 <strerror>                      
40012d14:	90 10 00 1d 	mov  %i5, %o0                                  
40012d18:	c2 4a 00 00 	ldsb  [ %o0 ], %g1                             
40012d1c:	80 a0 60 00 	cmp  %g1, 0                                    
40012d20:	02 80 00 0c 	be  40012d50 <rtems_verror+0x128>              <== NEVER TAKEN
40012d24:	01 00 00 00 	nop                                            
      chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno));
40012d28:	7f ff b9 92 	call  40001370 <__getreent>                    
40012d2c:	01 00 00 00 	nop                                            
40012d30:	f8 02 20 0c 	ld  [ %o0 + 0xc ], %i4                         
40012d34:	40 00 21 71 	call  4001b2f8 <strerror>                      
40012d38:	90 10 00 1d 	mov  %i5, %o0                                  
40012d3c:	13 10 00 b3 	sethi  %hi(0x4002cc00), %o1                    
40012d40:	94 10 00 08 	mov  %o0, %o2                                  
40012d44:	92 12 61 80 	or  %o1, 0x180, %o1                            
40012d48:	10 80 00 08 	b  40012d68 <rtems_verror+0x140>               
40012d4c:	90 10 00 1c 	mov  %i4, %o0                                  
    else                                                              
      chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno);
40012d50:	7f ff b9 88 	call  40001370 <__getreent>                    
40012d54:	01 00 00 00 	nop                                            
40012d58:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         
40012d5c:	13 10 00 b3 	sethi  %hi(0x4002cc00), %o1                    
40012d60:	94 10 00 1d 	mov  %i5, %o2                                  
40012d64:	92 12 61 90 	or  %o1, 0x190, %o1                            
40012d68:	40 00 15 d3 	call  400184b4 <fprintf>                       
40012d6c:	01 00 00 00 	nop                                            
40012d70:	b0 06 00 08 	add  %i0, %o0, %i0                             
  }                                                                   
                                                                      
  chars_written += fprintf(stderr, "\n");                             
40012d74:	7f ff b9 7f 	call  40001370 <__getreent>                    
40012d78:	01 00 00 00 	nop                                            
40012d7c:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         
40012d80:	13 10 00 ae 	sethi  %hi(0x4002b800), %o1                    
40012d84:	40 00 15 cc 	call  400184b4 <fprintf>                       
40012d88:	92 12 60 00 	mov  %o1, %o1	! 4002b800 <status_code_text+0x1b8>
                                                                      
  (void) fflush(stderr);                                              
40012d8c:	7f ff b9 79 	call  40001370 <__getreent>                    
40012d90:	b0 06 00 08 	add  %i0, %o0, %i0                             
40012d94:	40 00 14 41 	call  40017e98 <fflush>                        
40012d98:	d0 02 20 0c 	ld  [ %o0 + 0xc ], %o0                         
                                                                      
  return chars_written;                                               
}                                                                     
40012d9c:	81 c7 e0 08 	ret                                            
40012da0:	81 e8 00 00 	restore                                        
                                                                      

40003d54 <scanInt>: /** * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) {
40003d54:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int c;                                                              
  unsigned int i = 0;                                                 
  unsigned int limit = INT_MAX;                                       
40003d58:	37 1f ff ff 	sethi  %hi(0x7ffffc00), %i3                    
  int sign = 0;                                                       
40003d5c:	b8 10 20 00 	clr  %i4                                       
static int                                                            
scanInt(FILE *fp, int *val)                                           
{                                                                     
  int c;                                                              
  unsigned int i = 0;                                                 
  unsigned int limit = INT_MAX;                                       
40003d60:	b6 16 e3 ff 	or  %i3, 0x3ff, %i3                            
 */                                                                   
static int                                                            
scanInt(FILE *fp, int *val)                                           
{                                                                     
  int c;                                                              
  unsigned int i = 0;                                                 
40003d64:	ba 10 20 00 	clr  %i5                                       
        limit++;                                                      
        continue;                                                     
      }                                                               
      sign = 1;                                                       
    }                                                                 
    if (!isdigit(c))                                                  
40003d68:	21 10 00 5f 	sethi  %hi(0x40017c00), %l0                    
  unsigned int limit = INT_MAX;                                       
  int sign = 0;                                                       
  int d;                                                              
                                                                      
  for (;;) {                                                          
    c = getc(fp);                                                     
40003d6c:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
40003d70:	82 00 7f ff 	add  %g1, -1, %g1                              
40003d74:	80 a0 60 00 	cmp  %g1, 0                                    
40003d78:	16 80 00 08 	bge  40003d98 <scanInt+0x44>                   <== ALWAYS TAKEN
40003d7c:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
40003d80:	7f ff f5 45 	call  40001294 <__getreent>                    <== NOT EXECUTED
40003d84:	01 00 00 00 	nop                                            <== NOT EXECUTED
40003d88:	40 00 39 00 	call  40012188 <__srget_r>                     <== NOT EXECUTED
40003d8c:	92 10 00 18 	mov  %i0, %o1                                  <== NOT EXECUTED
40003d90:	10 80 00 07 	b  40003dac <scanInt+0x58>                     <== NOT EXECUTED
40003d94:	80 a2 20 3a 	cmp  %o0, 0x3a                                 <== NOT EXECUTED
40003d98:	c2 06 00 00 	ld  [ %i0 ], %g1                               
40003d9c:	84 00 60 01 	add  %g1, 1, %g2                               
40003da0:	c4 26 00 00 	st  %g2, [ %i0 ]                               
40003da4:	d0 08 40 00 	ldub  [ %g1 ], %o0                             
    if (c == ':')                                                     
40003da8:	80 a2 20 3a 	cmp  %o0, 0x3a                                 
40003dac:	02 80 00 21 	be  40003e30 <scanInt+0xdc>                    
40003db0:	80 a7 20 00 	cmp  %i4, 0                                    
      break;                                                          
    if (sign == 0) {                                                  
40003db4:	12 80 00 08 	bne  40003dd4 <scanInt+0x80>                   
40003db8:	c4 04 23 3c 	ld  [ %l0 + 0x33c ], %g2                       
      if (c == '-') {                                                 
40003dbc:	80 a2 20 2d 	cmp  %o0, 0x2d                                 
40003dc0:	12 80 00 05 	bne  40003dd4 <scanInt+0x80>                   
40003dc4:	b8 10 20 01 	mov  1, %i4                                    
        sign = -1;                                                    
        limit++;                                                      
40003dc8:	b6 06 e0 01 	inc  %i3                                       
        continue;                                                     
40003dcc:	10 bf ff e8 	b  40003d6c <scanInt+0x18>                     
40003dd0:	b8 10 3f ff 	mov  -1, %i4                                   
      }                                                               
      sign = 1;                                                       
    }                                                                 
    if (!isdigit(c))                                                  
40003dd4:	84 00 80 08 	add  %g2, %o0, %g2                             
40003dd8:	c4 08 a0 01 	ldub  [ %g2 + 1 ], %g2                         
40003ddc:	80 88 a0 04 	btst  4, %g2                                   
40003de0:	02 80 00 1d 	be  40003e54 <scanInt+0x100>                   
40003de4:	b4 02 3f d0 	add  %o0, -48, %i2                             
      return 0;                                                       
    d = c - '0';                                                      
    if ((i > (limit / 10))                                            
40003de8:	92 10 20 0a 	mov  0xa, %o1                                  
40003dec:	40 00 42 ba 	call  400148d4 <.udiv>                         
40003df0:	90 10 00 1b 	mov  %i3, %o0                                  
40003df4:	80 a7 40 08 	cmp  %i5, %o0                                  
40003df8:	38 80 00 15 	bgu,a   40003e4c <scanInt+0xf8>                
40003dfc:	b0 10 20 00 	clr  %i0                                       
     || ((i == (limit / 10)) && (d > (limit % 10))))                  
40003e00:	12 80 00 08 	bne  40003e20 <scanInt+0xcc>                   
40003e04:	83 2f 60 01 	sll  %i5, 1, %g1                               
40003e08:	90 10 00 1b 	mov  %i3, %o0                                  
40003e0c:	40 00 43 5e 	call  40014b84 <.urem>                         
40003e10:	92 10 20 0a 	mov  0xa, %o1                                  
40003e14:	80 a6 80 08 	cmp  %i2, %o0                                  
40003e18:	18 80 00 0f 	bgu  40003e54 <scanInt+0x100>                  <== ALWAYS TAKEN
40003e1c:	83 2f 60 01 	sll  %i5, 1, %g1                               
      return 0;                                                       
    i = i * 10 + d;                                                   
40003e20:	bb 2f 60 03 	sll  %i5, 3, %i5                               
40003e24:	ba 00 40 1d 	add  %g1, %i5, %i5                             
40003e28:	10 bf ff d1 	b  40003d6c <scanInt+0x18>                     
40003e2c:	ba 06 80 1d 	add  %i2, %i5, %i5                             
  }                                                                   
  if (sign == 0)                                                      
40003e30:	02 80 00 07 	be  40003e4c <scanInt+0xf8>                    <== NEVER TAKEN
40003e34:	b0 10 20 00 	clr  %i0                                       
    return 0;                                                         
  *val = i * sign;                                                    
40003e38:	90 10 00 1c 	mov  %i4, %o0                                  
40003e3c:	92 10 00 1d 	mov  %i5, %o1                                  
40003e40:	40 00 42 6b 	call  400147ec <.umul>                         
40003e44:	b0 10 20 01 	mov  1, %i0                                    
40003e48:	d0 26 40 00 	st  %o0, [ %i1 ]                               
  return 1;                                                           
40003e4c:	81 c7 e0 08 	ret                                            
40003e50:	81 e8 00 00 	restore                                        
        continue;                                                     
      }                                                               
      sign = 1;                                                       
    }                                                                 
    if (!isdigit(c))                                                  
      return 0;                                                       
40003e54:	b0 10 20 00 	clr  %i0                                       
  }                                                                   
  if (sign == 0)                                                      
    return 0;                                                         
  *val = i * sign;                                                    
  return 1;                                                           
}                                                                     
40003e58:	81 c7 e0 08 	ret                                            
40003e5c:	81 e8 00 00 	restore                                        
                                                                      

40004104 <scangr>: FILE *fp, struct group *grp, char *buffer, size_t bufsize ) {
40004104:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int grgid;                                                          
  char *grmem, *cp;                                                   
  int memcount;                                                       
                                                                      
  if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)            
40004108:	98 10 20 00 	clr  %o4                                       
  FILE *fp,                                                           
  struct group *grp,                                                  
  char *buffer,                                                       
  size_t bufsize                                                      
)                                                                     
{                                                                     
4000410c:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        
40004110:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
  int grgid;                                                          
  char *grmem, *cp;                                                   
  int memcount;                                                       
                                                                      
  if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)            
40004114:	90 10 00 18 	mov  %i0, %o0                                  
40004118:	92 10 00 19 	mov  %i1, %o1                                  
4000411c:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40004120:	7f ff ff 78 	call  40003f00 <scanString>                    
40004124:	96 07 a0 50 	add  %fp, 0x50, %o3                            
40004128:	80 a2 20 00 	cmp  %o0, 0                                    
4000412c:	12 80 00 04 	bne  4000413c <scangr+0x38>                    
40004130:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)          
   || !scanInt(fp, &grgid)                                            
   || !scanString(fp, &grmem, &buffer, &bufsize, 1))                  
    return 0;                                                         
40004134:	81 c7 e0 08 	ret                                            
40004138:	91 e8 20 00 	restore  %g0, 0, %o0                           
  int grgid;                                                          
  char *grmem, *cp;                                                   
  int memcount;                                                       
                                                                      
  if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)            
   || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)          
4000413c:	92 06 60 04 	add  %i1, 4, %o1                               
40004140:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40004144:	96 07 a0 50 	add  %fp, 0x50, %o3                            
40004148:	7f ff ff 6e 	call  40003f00 <scanString>                    
4000414c:	98 10 20 00 	clr  %o4                                       
40004150:	80 a2 20 00 	cmp  %o0, 0                                    
40004154:	02 bf ff f8 	be  40004134 <scangr+0x30>                     <== NEVER TAKEN
40004158:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanInt(fp, &grgid)                                            
4000415c:	7f ff ff 26 	call  40003df4 <scanInt>                       
40004160:	92 07 bf f8 	add  %fp, -8, %o1                              
40004164:	80 a2 20 00 	cmp  %o0, 0                                    
40004168:	02 bf ff f3 	be  40004134 <scangr+0x30>                     <== NEVER TAKEN
4000416c:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanString(fp, &grmem, &buffer, &bufsize, 1))                  
40004170:	92 07 bf fc 	add  %fp, -4, %o1                              
40004174:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40004178:	96 07 a0 50 	add  %fp, 0x50, %o3                            
4000417c:	7f ff ff 61 	call  40003f00 <scanString>                    
40004180:	98 10 20 01 	mov  1, %o4                                    
40004184:	80 a2 20 00 	cmp  %o0, 0                                    
40004188:	02 bf ff eb 	be  40004134 <scangr+0x30>                     <== NEVER TAKEN
4000418c:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
  grp->gr_gid = grgid;                                                
                                                                      
  /*                                                                  
   * Determine number of members                                      
   */                                                                 
  for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {                  
40004190:	c6 07 bf fc 	ld  [ %fp + -4 ], %g3                          
  if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)            
   || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)          
   || !scanInt(fp, &grgid)                                            
   || !scanString(fp, &grmem, &buffer, &bufsize, 1))                  
    return 0;                                                         
  grp->gr_gid = grgid;                                                
40004194:	c2 36 60 08 	sth  %g1, [ %i1 + 8 ]                          
                                                                      
  /*                                                                  
   * Determine number of members                                      
   */                                                                 
  for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {                  
40004198:	84 10 00 03 	mov  %g3, %g2                                  
4000419c:	82 10 20 01 	mov  1, %g1                                    
400041a0:	c8 48 80 00 	ldsb  [ %g2 ], %g4                             
400041a4:	80 a1 20 00 	cmp  %g4, 0                                    
400041a8:	02 80 00 06 	be  400041c0 <scangr+0xbc>                     
400041ac:	88 19 20 2c 	xor  %g4, 0x2c, %g4                            
400041b0:	84 00 a0 01 	inc  %g2                                       
    if(*cp == ',')                                                    
      memcount++;                                                     
400041b4:	80 a0 00 04 	cmp  %g0, %g4                                  
400041b8:	10 bf ff fa 	b  400041a0 <scangr+0x9c>                      
400041bc:	82 60 7f ff 	subx  %g1, -1, %g1                             
  }                                                                   
                                                                      
  /*                                                                  
   * Hack to produce (hopefully) a suitably-aligned array of pointers 
   */                                                                 
  if (bufsize < (((memcount+1)*sizeof(char *)) + 15))                 
400041c0:	c4 07 a0 50 	ld  [ %fp + 0x50 ], %g2                        
400041c4:	83 28 60 02 	sll  %g1, 2, %g1                               
400041c8:	82 00 60 13 	add  %g1, 0x13, %g1                            
400041cc:	80 a0 80 01 	cmp  %g2, %g1                                  
400041d0:	0a bf ff d9 	bcs  40004134 <scangr+0x30>                    <== NEVER TAKEN
400041d4:	c2 07 a0 4c 	ld  [ %fp + 0x4c ], %g1                        
                                                                      
  /*                                                                  
   * Fill in pointer array                                            
   */                                                                 
  grp->gr_mem[0] = grmem;                                             
  for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {                  
400041d8:	84 10 20 01 	mov  1, %g2                                    
  /*                                                                  
   * Hack to produce (hopefully) a suitably-aligned array of pointers 
   */                                                                 
  if (bufsize < (((memcount+1)*sizeof(char *)) + 15))                 
    return 0;                                                         
  grp->gr_mem = (char **)(((uintptr_t)buffer + 15) & ~15);            
400041dc:	82 00 60 0f 	add  %g1, 0xf, %g1                             
400041e0:	82 08 7f f0 	and  %g1, -16, %g1                             
400041e4:	c2 26 60 0c 	st  %g1, [ %i1 + 0xc ]                         
                                                                      
  /*                                                                  
   * Fill in pointer array                                            
   */                                                                 
  grp->gr_mem[0] = grmem;                                             
400041e8:	c6 20 40 00 	st  %g3, [ %g1 ]                               
400041ec:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
400041f0:	82 00 60 01 	inc  %g1                                       
  for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {                  
400041f4:	c6 48 7f ff 	ldsb  [ %g1 + -1 ], %g3                        
400041f8:	80 a0 e0 00 	cmp  %g3, 0                                    
400041fc:	02 80 00 0b 	be  40004228 <scangr+0x124>                    
40004200:	80 a0 e0 2c 	cmp  %g3, 0x2c                                 
    if(*cp == ',') {                                                  
40004204:	32 bf ff fc 	bne,a   400041f4 <scangr+0xf0>                 
40004208:	82 00 60 01 	inc  %g1                                       
      *cp = '\0';                                                     
4000420c:	c0 28 7f ff 	clrb  [ %g1 + -1 ]                             
      grp->gr_mem[memcount++] = cp + 1;                               
40004210:	c8 06 60 0c 	ld  [ %i1 + 0xc ], %g4                         
40004214:	87 28 a0 02 	sll  %g2, 2, %g3                               
40004218:	84 00 a0 01 	inc  %g2                                       
4000421c:	c2 21 00 03 	st  %g1, [ %g4 + %g3 ]                         
40004220:	10 bf ff f5 	b  400041f4 <scangr+0xf0>                      
40004224:	82 00 60 01 	inc  %g1                                       
    }                                                                 
  }                                                                   
  grp->gr_mem[memcount] = NULL;                                       
40004228:	c2 06 60 0c 	ld  [ %i1 + 0xc ], %g1                         
4000422c:	85 28 a0 02 	sll  %g2, 2, %g2                               
40004230:	c0 20 40 02 	clr  [ %g1 + %g2 ]                             
  return 1;                                                           
}                                                                     
40004234:	81 c7 e0 08 	ret                                            
40004238:	91 e8 20 01 	restore  %g0, 1, %o0                           
                                                                      

40003f50 <scanpw>: FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) {
40003f50:	9d e3 bf 98 	save  %sp, -104, %sp                           
  int pwuid, pwgid;                                                   
                                                                      
  if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)            
40003f54:	98 10 20 00 	clr  %o4                                       
  FILE *fp,                                                           
  struct passwd *pwd,                                                 
  char *buffer,                                                       
  size_t bufsize                                                      
)                                                                     
{                                                                     
40003f58:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        
40003f5c:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
  int pwuid, pwgid;                                                   
                                                                      
  if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)            
40003f60:	90 10 00 18 	mov  %i0, %o0                                  
40003f64:	92 10 00 19 	mov  %i1, %o1                                  
40003f68:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40003f6c:	7f ff ff bd 	call  40003e60 <scanString>                    
40003f70:	96 07 a0 50 	add  %fp, 0x50, %o3                            
40003f74:	80 a2 20 00 	cmp  %o0, 0                                    
40003f78:	12 80 00 04 	bne  40003f88 <scanpw+0x38>                    
40003f7c:	90 10 00 18 	mov  %i0, %o0                                  
   || !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))          
    return 0;                                                         
40003f80:	81 c7 e0 08 	ret                                            
40003f84:	91 e8 20 00 	restore  %g0, 0, %o0                           
)                                                                     
{                                                                     
  int pwuid, pwgid;                                                   
                                                                      
  if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)            
   || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0)          
40003f88:	92 06 60 04 	add  %i1, 4, %o1                               
40003f8c:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40003f90:	96 07 a0 50 	add  %fp, 0x50, %o3                            
40003f94:	7f ff ff b3 	call  40003e60 <scanString>                    
40003f98:	98 10 20 00 	clr  %o4                                       
40003f9c:	80 a2 20 00 	cmp  %o0, 0                                    
40003fa0:	02 bf ff f8 	be  40003f80 <scanpw+0x30>                     <== NEVER TAKEN
40003fa4:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanInt(fp, &pwuid)                                            
40003fa8:	7f ff ff 6b 	call  40003d54 <scanInt>                       
40003fac:	92 07 bf f8 	add  %fp, -8, %o1                              
40003fb0:	80 a2 20 00 	cmp  %o0, 0                                    
40003fb4:	02 bf ff f3 	be  40003f80 <scanpw+0x30>                     
40003fb8:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanInt(fp, &pwgid)                                            
40003fbc:	7f ff ff 66 	call  40003d54 <scanInt>                       
40003fc0:	92 07 bf fc 	add  %fp, -4, %o1                              
40003fc4:	80 a2 20 00 	cmp  %o0, 0                                    
40003fc8:	02 bf ff ee 	be  40003f80 <scanpw+0x30>                     
40003fcc:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0)         
40003fd0:	92 06 60 0c 	add  %i1, 0xc, %o1                             
40003fd4:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40003fd8:	96 07 a0 50 	add  %fp, 0x50, %o3                            
40003fdc:	7f ff ff a1 	call  40003e60 <scanString>                    
40003fe0:	98 10 20 00 	clr  %o4                                       
40003fe4:	80 a2 20 00 	cmp  %o0, 0                                    
40003fe8:	02 bf ff e6 	be  40003f80 <scanpw+0x30>                     <== NEVER TAKEN
40003fec:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanString(fp, &pwd->pw_gecos, &buffer, &bufsize, 0)           
40003ff0:	92 06 60 10 	add  %i1, 0x10, %o1                            
40003ff4:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40003ff8:	96 07 a0 50 	add  %fp, 0x50, %o3                            
40003ffc:	7f ff ff 99 	call  40003e60 <scanString>                    
40004000:	98 10 20 00 	clr  %o4                                       
40004004:	80 a2 20 00 	cmp  %o0, 0                                    
40004008:	02 bf ff de 	be  40003f80 <scanpw+0x30>                     <== NEVER TAKEN
4000400c:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanString(fp, &pwd->pw_dir, &buffer, &bufsize, 0)             
40004010:	92 06 60 14 	add  %i1, 0x14, %o1                            
40004014:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40004018:	96 07 a0 50 	add  %fp, 0x50, %o3                            
4000401c:	7f ff ff 91 	call  40003e60 <scanString>                    
40004020:	98 10 20 00 	clr  %o4                                       
40004024:	80 a2 20 00 	cmp  %o0, 0                                    
40004028:	02 bf ff d6 	be  40003f80 <scanpw+0x30>                     <== NEVER TAKEN
4000402c:	90 10 00 18 	mov  %i0, %o0                                  
   || !scanString(fp, &pwd->pw_shell, &buffer, &bufsize, 1))          
40004030:	92 06 60 18 	add  %i1, 0x18, %o1                            
40004034:	94 07 a0 4c 	add  %fp, 0x4c, %o2                            
40004038:	96 07 a0 50 	add  %fp, 0x50, %o3                            
4000403c:	7f ff ff 89 	call  40003e60 <scanString>                    
40004040:	98 10 20 01 	mov  1, %o4                                    
40004044:	80 a2 20 00 	cmp  %o0, 0                                    
40004048:	02 bf ff ce 	be  40003f80 <scanpw+0x30>                     
4000404c:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
    return 0;                                                         
  pwd->pw_uid = pwuid;                                                
40004050:	c2 36 60 08 	sth  %g1, [ %i1 + 8 ]                          
  pwd->pw_gid = pwgid;                                                
40004054:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
40004058:	c2 36 60 0a 	sth  %g1, [ %i1 + 0xa ]                        
  return 1;                                                           
}                                                                     
4000405c:	81 c7 e0 08 	ret                                            
40004060:	91 e8 20 01 	restore  %g0, 1, %o0                           
                                                                      

40007b7c <sched_get_priority_max>: #include <rtems/posix/priorityimpl.h> int sched_get_priority_max( int policy ) {
40007b7c:	9d e3 bf a0 	save  %sp, -96, %sp                            
40007b80:	80 a6 20 04 	cmp  %i0, 4                                    
40007b84:	18 80 00 06 	bgu  40007b9c <sched_get_priority_max+0x20>    
40007b88:	82 10 20 01 	mov  1, %g1                                    
40007b8c:	b1 28 40 18 	sll  %g1, %i0, %i0                             
40007b90:	80 8e 20 17 	btst  0x17, %i0                                
                                                                      
    default:                                                          
      rtems_set_errno_and_return_minus_one( EINVAL );                 
  }                                                                   
                                                                      
  return POSIX_SCHEDULER_MAXIMUM_PRIORITY;                            
40007b94:	12 80 00 08 	bne  40007bb4 <sched_get_priority_max+0x38>    <== ALWAYS TAKEN
40007b98:	03 10 00 7c 	sethi  %hi(0x4001f000), %g1                    
    case SCHED_RR:                                                    
    case SCHED_SPORADIC:                                              
      break;                                                          
                                                                      
    default:                                                          
      rtems_set_errno_and_return_minus_one( EINVAL );                 
40007b9c:	40 00 22 56 	call  400104f4 <__errno>                       
40007ba0:	b0 10 3f ff 	mov  -1, %i0                                   
40007ba4:	82 10 20 16 	mov  0x16, %g1                                 
40007ba8:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40007bac:	81 c7 e0 08 	ret                                            
40007bb0:	81 e8 00 00 	restore                                        
  }                                                                   
                                                                      
  return POSIX_SCHEDULER_MAXIMUM_PRIORITY;                            
40007bb4:	f0 08 61 14 	ldub  [ %g1 + 0x114 ], %i0                     
}                                                                     
40007bb8:	81 c7 e0 08 	ret                                            
40007bbc:	91 ee 3f ff 	restore  %i0, -1, %o0                          
                                                                      

40007bc0 <sched_get_priority_min>: * 13.3.6 Get Scheduling Parameter Limits, P1003.1b-1993, p. 258 */ int sched_get_priority_min( int policy ) {
40007bc0:	9d e3 bf a0 	save  %sp, -96, %sp                            
40007bc4:	80 a6 20 04 	cmp  %i0, 4                                    
40007bc8:	18 80 00 06 	bgu  40007be0 <sched_get_priority_min+0x20>    
40007bcc:	82 10 20 01 	mov  1, %g1                                    
40007bd0:	83 28 40 18 	sll  %g1, %i0, %g1                             
40007bd4:	80 88 60 17 	btst  0x17, %g1                                
                                                                      
    default:                                                          
      rtems_set_errno_and_return_minus_one( EINVAL );                 
  }                                                                   
                                                                      
  return POSIX_SCHEDULER_MINIMUM_PRIORITY;                            
40007bd8:	12 80 00 06 	bne  40007bf0 <sched_get_priority_min+0x30>    <== ALWAYS TAKEN
40007bdc:	b0 10 20 01 	mov  1, %i0                                    
    case SCHED_RR:                                                    
    case SCHED_SPORADIC:                                              
      break;                                                          
                                                                      
    default:                                                          
      rtems_set_errno_and_return_minus_one( EINVAL );                 
40007be0:	40 00 22 45 	call  400104f4 <__errno>                       
40007be4:	b0 10 3f ff 	mov  -1, %i0                                   
40007be8:	82 10 20 16 	mov  0x16, %g1                                 
40007bec:	c2 22 00 00 	st  %g1, [ %o0 ]                               
  }                                                                   
                                                                      
  return POSIX_SCHEDULER_MINIMUM_PRIORITY;                            
}                                                                     
40007bf0:	81 c7 e0 08 	ret                                            
40007bf4:	81 e8 00 00 	restore                                        
                                                                      

40007bf8 <sched_rr_get_interval>: int sched_rr_get_interval( pid_t pid, struct timespec *interval ) {
40007bf8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  /*                                                                  
   *  Only supported for the "calling process" (i.e. this node).      
   */                                                                 
                                                                      
  if ( pid && pid != getpid() )                                       
40007bfc:	80 a6 20 00 	cmp  %i0, 0                                    
40007c00:	02 80 00 0b 	be  40007c2c <sched_rr_get_interval+0x34>      <== NEVER TAKEN
40007c04:	80 a6 60 00 	cmp  %i1, 0                                    
40007c08:	7f ff f0 73 	call  40003dd4 <getpid>                        
40007c0c:	01 00 00 00 	nop                                            
40007c10:	80 a6 00 08 	cmp  %i0, %o0                                  
40007c14:	02 80 00 06 	be  40007c2c <sched_rr_get_interval+0x34>      
40007c18:	80 a6 60 00 	cmp  %i1, 0                                    
    rtems_set_errno_and_return_minus_one( ESRCH );                    
40007c1c:	40 00 22 36 	call  400104f4 <__errno>                       
40007c20:	01 00 00 00 	nop                                            
40007c24:	10 80 00 07 	b  40007c40 <sched_rr_get_interval+0x48>       
40007c28:	82 10 20 03 	mov  3, %g1	! 3 <_TLS_Alignment+0x2>           
                                                                      
  if ( !interval )                                                    
40007c2c:	12 80 00 08 	bne  40007c4c <sched_rr_get_interval+0x54>     
40007c30:	03 10 00 77 	sethi  %hi(0x4001dc00), %g1                    
    rtems_set_errno_and_return_minus_one( EINVAL );                   
40007c34:	40 00 22 30 	call  400104f4 <__errno>                       
40007c38:	01 00 00 00 	nop                                            
40007c3c:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
40007c40:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40007c44:	81 c7 e0 08 	ret                                            
40007c48:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  _Timespec_From_ticks(                                               
40007c4c:	d0 00 60 94 	ld  [ %g1 + 0x94 ], %o0                        
40007c50:	92 10 00 19 	mov  %i1, %o1                                  
40007c54:	40 00 0f 1c 	call  4000b8c4 <_Timespec_From_ticks>          
40007c58:	b0 10 20 00 	clr  %i0                                       
    rtems_configuration_get_ticks_per_timeslice(),                    
    interval                                                          
  );                                                                  
                                                                      
  return 0;                                                           
}                                                                     
40007c5c:	81 c7 e0 08 	ret                                            
40007c60:	81 e8 00 00 	restore                                        
                                                                      

40008b74 <sem_open>: int oflag, ... /* mode_t mode, */ /* unsigned int value */ ) {
40008b74:	9d e3 bf 88 	save  %sp, -120, %sp                           
  POSIX_Semaphore_Control   *the_semaphore;                           
  Objects_Locations          location;                                
  size_t                     name_len;                                
                                                                      
  if ( oflag & O_CREAT ) {                                            
    va_start(arg, oflag);                                             
40008b78:	f4 27 a0 4c 	st  %i2, [ %fp + 0x4c ]                        
40008b7c:	f8 27 a0 54 	st  %i4, [ %fp + 0x54 ]                        
40008b80:	f6 27 a0 50 	st  %i3, [ %fp + 0x50 ]                        
40008b84:	fa 27 a0 58 	st  %i5, [ %fp + 0x58 ]                        
  Objects_Id                 the_semaphore_id;                        
  POSIX_Semaphore_Control   *the_semaphore;                           
  Objects_Locations          location;                                
  size_t                     name_len;                                
                                                                      
  if ( oflag & O_CREAT ) {                                            
40008b88:	b4 8e 62 00 	andcc  %i1, 0x200, %i2                         
40008b8c:	02 80 00 05 	be  40008ba0 <sem_open+0x2c>                   
40008b90:	b8 10 20 00 	clr  %i4                                       
    va_start(arg, oflag);                                             
40008b94:	82 07 a0 4c 	add  %fp, 0x4c, %g1                            
    mode = va_arg( arg, mode_t );                                     
    value = va_arg( arg, unsigned int );                              
40008b98:	b8 10 00 1b 	mov  %i3, %i4                                  
  POSIX_Semaphore_Control   *the_semaphore;                           
  Objects_Locations          location;                                
  size_t                     name_len;                                
                                                                      
  if ( oflag & O_CREAT ) {                                            
    va_start(arg, oflag);                                             
40008b9c:	c2 27 bf ec 	st  %g1, [ %fp + -20 ]                         
 */                                                                   
SCORE_EXTERN API_Mutex_Control *_RTEMS_Allocator_Mutex;               
                                                                      
static inline void _RTEMS_Lock_allocator( void )                      
{                                                                     
  _API_Mutex_Lock( _RTEMS_Allocator_Mutex );                          
40008ba0:	03 10 00 78 	sethi  %hi(0x4001e000), %g1                    
40008ba4:	d0 00 60 d8 	ld  [ %g1 + 0xd8 ], %o0	! 4001e0d8 <_RTEMS_Allocator_Mutex>
40008ba8:	40 00 05 ff 	call  4000a3a4 <_API_Mutex_Lock>               
40008bac:	37 10 00 78 	sethi  %hi(0x4001e000), %i3                    
  const char *name,                                                   
  Objects_Id *id,                                                     
  size_t     *len                                                     
)                                                                     
{                                                                     
  return _POSIX_Name_to_id( &_POSIX_Semaphore_Information, name, id, len );
40008bb0:	90 16 e2 e4 	or  %i3, 0x2e4, %o0	! 4001e2e4 <_POSIX_Semaphore_Information>
40008bb4:	92 10 00 18 	mov  %i0, %o1                                  
40008bb8:	94 07 bf f0 	add  %fp, -16, %o2                             
40008bbc:	7f ff fe 74 	call  4000858c <_POSIX_Name_to_id>             
40008bc0:	96 07 bf fc 	add  %fp, -4, %o3                              
   *  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 ) {                                                     
40008bc4:	ba 92 20 00 	orcc  %o0, 0, %i5                              
40008bc8:	22 80 00 0e 	be,a   40008c00 <sem_open+0x8c>                
40008bcc:	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) ) ) {               
40008bd0:	80 a7 60 02 	cmp  %i5, 2                                    
40008bd4:	12 80 00 04 	bne  40008be4 <sem_open+0x70>                  
40008bd8:	80 a6 a0 00 	cmp  %i2, 0                                    
40008bdc:	12 80 00 20 	bne  40008c5c <sem_open+0xe8>                  
40008be0:	d2 07 bf fc 	ld  [ %fp + -4 ], %o1                          
 * previous thread life protection state and thus may not return if the
 * executing thread was restarted or deleted in the mean-time.        
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Allocator_unlock( void )           
{                                                                     
  _RTEMS_Unlock_allocator();                                          
40008be4:	7f ff ff df 	call  40008b60 <_RTEMS_Unlock_allocator>       
40008be8:	b0 10 3f ff 	mov  -1, %i0                                   
      _Objects_Allocator_unlock();                                    
      rtems_set_errno_and_return_minus_one_cast( status, sem_t * );   
40008bec:	40 00 25 8b 	call  40012218 <__errno>                       
40008bf0:	01 00 00 00 	nop                                            
40008bf4:	fa 22 00 00 	st  %i5, [ %o0 ]                               
40008bf8:	81 c7 e0 08 	ret                                            
40008bfc:	81 e8 00 00 	restore                                        
                                                                      
    /*                                                                
     * Check for existence with creation.                             
     */                                                               
                                                                      
    if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {       
40008c00:	80 a6 6a 00 	cmp  %i1, 0xa00                                
40008c04:	12 80 00 0a 	bne  40008c2c <sem_open+0xb8>                  
40008c08:	d2 07 bf f0 	ld  [ %fp + -16 ], %o1                         
40008c0c:	7f ff ff d5 	call  40008b60 <_RTEMS_Unlock_allocator>       
40008c10:	b0 10 3f ff 	mov  -1, %i0                                   
      _Objects_Allocator_unlock();                                    
      rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );   
40008c14:	40 00 25 81 	call  40012218 <__errno>                       
40008c18:	01 00 00 00 	nop                                            
40008c1c:	82 10 20 11 	mov  0x11, %g1	! 11 <_TLS_Alignment+0x10>      
40008c20:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40008c24:	81 c7 e0 08 	ret                                            
40008c28:	81 e8 00 00 	restore                                        
RTEMS_INLINE_ROUTINE POSIX_Semaphore_Control *_POSIX_Semaphore_Get (  
  sem_t             *id,                                              
  Objects_Locations *location                                         
)                                                                     
{                                                                     
  return (POSIX_Semaphore_Control *)                                  
40008c2c:	94 07 bf f8 	add  %fp, -8, %o2                              
40008c30:	40 00 0a 96 	call  4000b688 <_Objects_Get>                  
40008c34:	90 16 e2 e4 	or  %i3, 0x2e4, %o0                            
    }                                                                 
                                                                      
    the_semaphore = _POSIX_Semaphore_Get( (sem_t *) &the_semaphore_id, &location );
    the_semaphore->open_count += 1;                                   
40008c38:	c2 02 20 18 	ld  [ %o0 + 0x18 ], %g1                        
    if ( (oflag & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL) ) {       
      _Objects_Allocator_unlock();                                    
      rtems_set_errno_and_return_minus_one_cast( EEXIST, sem_t * );   
    }                                                                 
                                                                      
    the_semaphore = _POSIX_Semaphore_Get( (sem_t *) &the_semaphore_id, &location );
40008c3c:	d0 27 bf f4 	st  %o0, [ %fp + -12 ]                         
    the_semaphore->open_count += 1;                                   
40008c40:	82 00 60 01 	inc  %g1                                       
    _Thread_Enable_dispatch();                                        
40008c44:	40 00 0e 1a 	call  4000c4ac <_Thread_Enable_dispatch>       
40008c48:	c2 22 20 18 	st  %g1, [ %o0 + 0x18 ]                        
40008c4c:	7f ff ff c5 	call  40008b60 <_RTEMS_Unlock_allocator>       
40008c50:	01 00 00 00 	nop                                            
return_id:                                                            
  #if defined(RTEMS_USE_16_BIT_OBJECT)                                
    the_semaphore->Semaphore_id = the_semaphore->Object.id;           
    return &the_semaphore->Semaphore_id;                              
  #else                                                               
    return (sem_t *)&the_semaphore->Object.id;                        
40008c54:	10 80 00 0d 	b  40008c88 <sem_open+0x114>                   
40008c58:	f0 07 bf f4 	ld  [ %fp + -12 ], %i0                         
  /*                                                                  
   *  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(                            
40008c5c:	94 10 20 00 	clr  %o2                                       
40008c60:	96 10 00 1c 	mov  %i4, %o3                                  
40008c64:	98 07 bf f4 	add  %fp, -12, %o4                             
40008c68:	40 00 1a a5 	call  4000f6fc <_POSIX_Semaphore_Create_support>
40008c6c:	90 10 00 18 	mov  %i0, %o0                                  
40008c70:	7f ff ff bc 	call  40008b60 <_RTEMS_Unlock_allocator>       
40008c74:	ba 10 00 08 	mov  %o0, %i5                                  
   * errno was set by Create_support, so don't set it again.          
   */                                                                 
                                                                      
  _Objects_Allocator_unlock();                                        
                                                                      
  if ( status == -1 )                                                 
40008c78:	80 a7 7f ff 	cmp  %i5, -1                                   
40008c7c:	22 80 00 04 	be,a   40008c8c <sem_open+0x118>               <== NEVER TAKEN
40008c80:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
return_id:                                                            
  #if defined(RTEMS_USE_16_BIT_OBJECT)                                
    the_semaphore->Semaphore_id = the_semaphore->Object.id;           
    return &the_semaphore->Semaphore_id;                              
  #else                                                               
    return (sem_t *)&the_semaphore->Object.id;                        
40008c84:	f0 07 bf f4 	ld  [ %fp + -12 ], %i0                         
40008c88:	b0 06 20 08 	add  %i0, 8, %i0                               
  #endif                                                              
}                                                                     
40008c8c:	81 c7 e0 08 	ret                                            
40008c90:	81 e8 00 00 	restore                                        
                                                                      

4000aee0 <sem_timedwait>: int sem_timedwait( sem_t *__restrict sem, const struct timespec *__restrict abstime ) {
4000aee0:	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 );       
4000aee4:	92 07 bf fc 	add  %fp, -4, %o1                              
4000aee8:	40 00 16 87 	call  40010904 <_POSIX_Absolute_timeout_to_ticks>
4000aeec:	90 10 00 19 	mov  %i1, %o0                                  
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
    do_wait = false;                                                  
                                                                      
  lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks ); 
4000aef0:	d4 07 bf fc 	ld  [ %fp + -4 ], %o2                          
   *  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 );       
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
4000aef4:	90 1a 20 03 	xor  %o0, 3, %o0                               
4000aef8:	80 a0 00 08 	cmp  %g0, %o0                                  
    do_wait = false;                                                  
                                                                      
  lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks ); 
4000aefc:	90 10 00 18 	mov  %i0, %o0                                  
   *  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 );       
  if ( status != POSIX_ABSOLUTE_TIMEOUT_IS_IN_FUTURE )                
4000af00:	ba 60 3f ff 	subx  %g0, -1, %i5                             
    do_wait = false;                                                  
                                                                      
  lock_status = _POSIX_Semaphore_Wait_support( sem, do_wait, ticks ); 
4000af04:	40 00 19 2e 	call  400113bc <_POSIX_Semaphore_Wait_support> 
4000af08:	92 10 00 1d 	mov  %i5, %o1                                  
   *  This service only gives us the option to block.  We used a polling
   *  attempt to obtain if the abstime was not in the future.  If we did
   *  not obtain the semaphore, then not look at the status immediately,
   *  make sure the right reason is returned.                         
   */                                                                 
  if ( !do_wait && (lock_status == EBUSY) ) {                         
4000af0c:	80 a7 60 00 	cmp  %i5, 0                                    
4000af10:	12 80 00 06 	bne  4000af28 <sem_timedwait+0x48>             <== ALWAYS TAKEN
4000af14:	80 a2 20 10 	cmp  %o0, 0x10                                 
4000af18:	12 80 00 04 	bne  4000af28 <sem_timedwait+0x48>             <== NOT EXECUTED
4000af1c:	01 00 00 00 	nop                                            <== NOT EXECUTED
4000af20:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000af24:	91 e8 20 10 	restore  %g0, 0x10, %o0                        <== NOT EXECUTED
         lock_status == POSIX_ABSOLUTE_TIMEOUT_IS_NOW )               
      rtems_set_errno_and_return_minus_one( ETIMEDOUT );              
  }                                                                   
                                                                      
  return lock_status;                                                 
}                                                                     
4000af28:	81 c7 e0 08 	ret                                            
4000af2c:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

400044c0 <set_startloc>: static void set_startloc( rtems_filesystem_eval_path_context_t *ctx, rtems_filesystem_global_location_t *const *global_root_ptr, rtems_filesystem_global_location_t *const *global_current_ptr ) {
400044c0:	9d e3 bf 98 	save  %sp, -104, %sp                           
  if (ctx->pathlen > 0) {                                             
400044c4:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
400044c8:	80 a0 60 00 	cmp  %g1, 0                                    
400044cc:	22 80 00 1a 	be,a   40004534 <set_startloc+0x74>            
400044d0:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    char c = ctx->path [0];                                           
400044d4:	c2 06 00 00 	ld  [ %i0 ], %g1                               
                                                                      
    ctx->rootloc = rtems_filesystem_global_location_obtain(global_root_ptr);
400044d8:	90 10 00 19 	mov  %i1, %o0                                  
400044dc:	40 00 01 5a 	call  40004a44 <rtems_filesystem_global_location_obtain>
400044e0:	fa 08 40 00 	ldub  [ %g1 ], %i5                             
  gid_t node_gid                                                      
);                                                                    
                                                                      
static inline bool rtems_filesystem_is_delimiter(char c)              
{                                                                     
  return c == '/' || c == '\\';                                       
400044e4:	83 2f 60 18 	sll  %i5, 0x18, %g1                            
400044e8:	83 38 60 18 	sra  %g1, 0x18, %g1                            
                                                                      
    if (rtems_filesystem_is_delimiter(c)) {                           
400044ec:	80 a0 60 5c 	cmp  %g1, 0x5c                                 
400044f0:	02 80 00 05 	be  40004504 <set_startloc+0x44>               <== NEVER TAKEN
400044f4:	d0 26 20 30 	st  %o0, [ %i0 + 0x30 ]                        
400044f8:	80 a0 60 2f 	cmp  %g1, 0x2f                                 
400044fc:	12 80 00 09 	bne  40004520 <set_startloc+0x60>              
40004500:	90 10 00 1a 	mov  %i2, %o0                                  
      ++ctx->path;                                                    
40004504:	c2 06 00 00 	ld  [ %i0 ], %g1                               
      --ctx->pathlen;                                                 
      ctx->startloc = rtems_filesystem_global_location_obtain(        
40004508:	90 06 20 30 	add  %i0, 0x30, %o0                            
    char c = ctx->path [0];                                           
                                                                      
    ctx->rootloc = rtems_filesystem_global_location_obtain(global_root_ptr);
                                                                      
    if (rtems_filesystem_is_delimiter(c)) {                           
      ++ctx->path;                                                    
4000450c:	82 00 60 01 	inc  %g1                                       
40004510:	c2 26 00 00 	st  %g1, [ %i0 ]                               
      --ctx->pathlen;                                                 
40004514:	c2 06 20 04 	ld  [ %i0 + 4 ], %g1                           
40004518:	82 00 7f ff 	add  %g1, -1, %g1                              
4000451c:	c2 26 20 04 	st  %g1, [ %i0 + 4 ]                           
      ctx->startloc = rtems_filesystem_global_location_obtain(        
        &ctx->rootloc                                                 
      );                                                              
    } else {                                                          
      ctx->startloc = rtems_filesystem_global_location_obtain(        
40004520:	40 00 01 49 	call  40004a44 <rtems_filesystem_global_location_obtain>
40004524:	01 00 00 00 	nop                                            
40004528:	d0 26 20 34 	st  %o0, [ %i0 + 0x34 ]                        
4000452c:	81 c7 e0 08 	ret                                            
40004530:	81 e8 00 00 	restore                                        
static inline rtems_filesystem_global_location_t *                    
rtems_filesystem_global_location_obtain_null(void)                    
{                                                                     
  rtems_filesystem_global_location_t *global_loc = NULL;              
                                                                      
  return rtems_filesystem_global_location_obtain( &global_loc );      
40004534:	40 00 01 44 	call  40004a44 <rtems_filesystem_global_location_obtain>
40004538:	90 07 bf fc 	add  %fp, -4, %o0                              
);                                                                    
                                                                      
static inline rtems_filesystem_global_location_t *                    
rtems_filesystem_global_location_obtain_null(void)                    
{                                                                     
  rtems_filesystem_global_location_t *global_loc = NULL;              
4000453c:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
        global_current_ptr                                            
      );                                                              
    }                                                                 
  } else {                                                            
    ctx->rootloc = rtems_filesystem_global_location_obtain_null();    
40004540:	d0 26 20 30 	st  %o0, [ %i0 + 0x30 ]                        
                                                                      
  return rtems_filesystem_global_location_obtain( &global_loc );      
40004544:	40 00 01 40 	call  40004a44 <rtems_filesystem_global_location_obtain>
40004548:	90 07 bf fc 	add  %fp, -4, %o0                              
    ctx->startloc = rtems_filesystem_global_location_obtain_null();   
    errno = ENOENT;                                                   
4000454c:	40 00 2d 35 	call  4000fa20 <__errno>                       
40004550:	d0 26 20 34 	st  %o0, [ %i0 + 0x34 ]                        
40004554:	82 10 20 02 	mov  2, %g1                                    
40004558:	c2 22 00 00 	st  %g1, [ %o0 ]                               
4000455c:	81 c7 e0 08 	ret                                            
40004560:	81 e8 00 00 	restore                                        
                                                                      

40007c64 <sigaction>: int sigaction( int sig, const struct sigaction *__restrict act, struct sigaction *__restrict oact ) {
40007c64:	9d e3 bf a0 	save  %sp, -96, %sp                            
  ISR_Level     level;                                                
                                                                      
  if ( !sig )                                                         
40007c68:	82 06 3f ff 	add  %i0, -1, %g1                              
40007c6c:	80 a0 60 1f 	cmp  %g1, 0x1f                                 
40007c70:	08 80 00 08 	bleu  40007c90 <sigaction+0x2c>                
40007c74:	80 a6 20 09 	cmp  %i0, 9                                    
    rtems_set_errno_and_return_minus_one( EINVAL );                   
40007c78:	40 00 23 d0 	call  40010bb8 <__errno>                       
40007c7c:	b0 10 3f ff 	mov  -1, %i0                                   
40007c80:	82 10 20 16 	mov  0x16, %g1                                 
40007c84:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40007c88:	81 c7 e0 08 	ret                                            
40007c8c:	81 e8 00 00 	restore                                        
   *                                                                  
   *  NOTE: Solaris documentation claims to "silently enforce" this which
   *        contradicts the POSIX specification.                      
   */                                                                 
                                                                      
  if ( sig == SIGKILL )                                               
40007c90:	02 bf ff fa 	be  40007c78 <sigaction+0x14>                  
40007c94:	01 00 00 00 	nop                                            
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40007c98:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40007c9c:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40007ca0:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
    rtems_set_errno_and_return_minus_one( EINVAL );                   
                                                                      
  _Thread_Disable_dispatch();                                         
                                                                      
  if ( oact )                                                         
40007ca4:	80 a6 a0 00 	cmp  %i2, 0                                    
40007ca8:	02 80 00 0a 	be  40007cd0 <sigaction+0x6c>                  
40007cac:	83 2e 20 02 	sll  %i0, 2, %g1                               
    *oact = _POSIX_signals_Vectors[ sig ];                            
40007cb0:	85 2e 20 04 	sll  %i0, 4, %g2                               
40007cb4:	82 20 80 01 	sub  %g2, %g1, %g1                             
40007cb8:	13 10 00 70 	sethi  %hi(0x4001c000), %o1                    
40007cbc:	90 10 00 1a 	mov  %i2, %o0                                  
40007cc0:	92 12 62 a8 	or  %o1, 0x2a8, %o1                            
40007cc4:	94 10 20 0c 	mov  0xc, %o2                                  
40007cc8:	40 00 25 a6 	call  40011360 <memcpy>                        
40007ccc:	92 02 40 01 	add  %o1, %g1, %o1                             
  /*                                                                  
   *  Evaluate the new action structure and set the global signal vector
   *  appropriately.                                                  
   */                                                                 
                                                                      
  if ( act ) {                                                        
40007cd0:	80 a6 60 00 	cmp  %i1, 0                                    
40007cd4:	02 80 00 1b 	be  40007d40 <sigaction+0xdc>                  <== NEVER TAKEN
40007cd8:	01 00 00 00 	nop                                            
    /*                                                                
     *  Unless the user is installing the default signal actions, then
     *  we can just copy the provided sigaction structure into the vectors.
     */                                                               
                                                                      
    _ISR_Disable( level );                                            
40007cdc:	7f ff ea c6 	call  400027f4 <sparc_disable_interrupts>      
40007ce0:	01 00 00 00 	nop                                            
40007ce4:	b4 10 00 08 	mov  %o0, %i2                                  
      if ( act->sa_handler == SIG_DFL ) {                             
40007ce8:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1                           
40007cec:	3b 10 00 70 	sethi  %hi(0x4001c000), %i5                    
40007cf0:	80 a0 60 00 	cmp  %g1, 0                                    
40007cf4:	ba 17 62 a8 	or  %i5, 0x2a8, %i5                            
40007cf8:	b9 2e 20 02 	sll  %i0, 2, %i4                               
40007cfc:	12 80 00 08 	bne  40007d1c <sigaction+0xb8>                 
40007d00:	b7 2e 20 04 	sll  %i0, 4, %i3                               
        _POSIX_signals_Vectors[ sig ] = _POSIX_signals_Default_vectors[ sig ];
40007d04:	b8 26 c0 1c 	sub  %i3, %i4, %i4                             
40007d08:	13 10 00 65 	sethi  %hi(0x40019400), %o1                    
40007d0c:	90 07 40 1c 	add  %i5, %i4, %o0                             
40007d10:	92 12 63 44 	or  %o1, 0x344, %o1                            
40007d14:	10 80 00 07 	b  40007d30 <sigaction+0xcc>                   
40007d18:	92 02 40 1c 	add  %o1, %i4, %o1                             
      } else {                                                        
         _POSIX_signals_Clear_process_signals( sig );                 
40007d1c:	40 00 17 73 	call  4000dae8 <_POSIX_signals_Clear_process_signals>
40007d20:	90 10 00 18 	mov  %i0, %o0                                  
         _POSIX_signals_Vectors[ sig ] = *act;                        
40007d24:	90 26 c0 1c 	sub  %i3, %i4, %o0                             
40007d28:	92 10 00 19 	mov  %i1, %o1                                  
40007d2c:	90 07 40 08 	add  %i5, %o0, %o0                             
40007d30:	40 00 25 8c 	call  40011360 <memcpy>                        
40007d34:	94 10 20 0c 	mov  0xc, %o2                                  
      }                                                               
    _ISR_Enable( level );                                             
40007d38:	7f ff ea b2 	call  40002800 <sparc_enable_interrupts>       
40007d3c:	90 10 00 1a 	mov  %i2, %o0                                  
  }                                                                   
                                                                      
  _Thread_Enable_dispatch();                                          
40007d40:	40 00 0b d5 	call  4000ac94 <_Thread_Enable_dispatch>       
40007d44:	b0 10 20 00 	clr  %i0                                       
                                                                      
  return 0;                                                           
}                                                                     
40007d48:	81 c7 e0 08 	ret                                            
40007d4c:	81 e8 00 00 	restore                                        
                                                                      

400081ec <sigtimedwait>: int sigtimedwait( const sigset_t *__restrict set, siginfo_t *__restrict info, const struct timespec *__restrict timeout ) {
400081ec:	9d e3 bf 90 	save  %sp, -112, %sp                           
  ISR_lock_Context   lock_context;                                    
                                                                      
  /*                                                                  
   *  Error check parameters before disabling interrupts.             
   */                                                                 
  if ( !set )                                                         
400081f0:	80 a6 20 00 	cmp  %i0, 0                                    
400081f4:	02 80 00 0e 	be  4000822c <sigtimedwait+0x40>               
400081f8:	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 ) {                                                    
400081fc:	22 80 00 10 	be,a   4000823c <sigtimedwait+0x50>            
40008200:	b4 10 20 00 	clr  %i2                                       
                                                                      
    if ( !_Timespec_Is_valid( timeout ) )                             
40008204:	40 00 0f c6 	call  4000c11c <_Timespec_Is_valid>            
40008208:	90 10 00 1a 	mov  %i2, %o0                                  
4000820c:	80 a2 20 00 	cmp  %o0, 0                                    
40008210:	02 80 00 07 	be  4000822c <sigtimedwait+0x40>               
40008214:	01 00 00 00 	nop                                            
      rtems_set_errno_and_return_minus_one( EINVAL );                 
                                                                      
    interval = _Timespec_To_ticks( timeout );                         
40008218:	40 00 0f d3 	call  4000c164 <_Timespec_To_ticks>            
4000821c:	90 10 00 1a 	mov  %i2, %o0                                  
                                                                      
    if ( !interval )                                                  
40008220:	b4 92 20 00 	orcc  %o0, 0, %i2                              
40008224:	12 80 00 07 	bne  40008240 <sigtimedwait+0x54>              <== ALWAYS TAKEN
40008228:	80 a6 60 00 	cmp  %i1, 0                                    
      rtems_set_errno_and_return_minus_one( EINVAL );                 
4000822c:	40 00 24 44 	call  4001133c <__errno>                       
40008230:	01 00 00 00 	nop                                            
40008234:	10 80 00 64 	b  400083c4 <sigtimedwait+0x1d8>               
40008238:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
                                                                      
  /*                                                                  
   *  Initialize local variables.                                     
   */                                                                 
                                                                      
  the_info = ( info ) ? info : &signal_information;                   
4000823c:	80 a6 60 00 	cmp  %i1, 0                                    
40008240:	22 80 00 02 	be,a   40008248 <sigtimedwait+0x5c>            
40008244:	b2 07 bf f4 	add  %fp, -12, %i1                             
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable_without_giant( level );                              
  #endif                                                              
                                                                      
  executing = _Thread_Executing;                                      
40008248:	fa 01 a0 18 	ld  [ %g6 + 0x18 ], %i5                        
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
4000824c:	7f ff ea 62 	call  40002bd4 <sparc_disable_interrupts>      
40008250:	f8 07 61 30 	ld  [ %i5 + 0x130 ], %i4                       
40008254:	b6 10 00 08 	mov  %o0, %i3                                  
   */                                                                 
                                                                      
  /* API signals pending? */                                          
                                                                      
  _POSIX_signals_Acquire( &lock_context );                            
  if ( *set & api->signals_pending ) {                                
40008258:	c2 06 00 00 	ld  [ %i0 ], %g1                               
4000825c:	d0 07 20 e0 	ld  [ %i4 + 0xe0 ], %o0                        
40008260:	80 88 40 08 	btst  %g1, %o0                                 
40008264:	02 80 00 13 	be  400082b0 <sigtimedwait+0xc4>               
40008268:	05 10 00 73 	sethi  %hi(0x4001cc00), %g2                    
    /* XXX real info later */                                         
    the_info->si_signo = _POSIX_signals_Get_lowest( api->signals_pending );
4000826c:	7f ff ff c8 	call  4000818c <_POSIX_signals_Get_lowest>     
40008270:	01 00 00 00 	nop                                            
    _POSIX_signals_Clear_signals(                                     
40008274:	94 10 00 19 	mov  %i1, %o2                                  
  /* API signals pending? */                                          
                                                                      
  _POSIX_signals_Acquire( &lock_context );                            
  if ( *set & api->signals_pending ) {                                
    /* XXX real info later */                                         
    the_info->si_signo = _POSIX_signals_Get_lowest( api->signals_pending );
40008278:	92 10 00 08 	mov  %o0, %o1                                  
4000827c:	d0 26 40 00 	st  %o0, [ %i1 ]                               
    _POSIX_signals_Clear_signals(                                     
40008280:	96 10 20 00 	clr  %o3                                       
40008284:	90 10 00 1c 	mov  %i4, %o0                                  
40008288:	98 10 20 00 	clr  %o4                                       
4000828c:	40 00 18 36 	call  4000e364 <_POSIX_signals_Clear_signals>  
40008290:	9a 10 20 00 	clr  %o5                                       
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
40008294:	7f ff ea 53 	call  40002be0 <sparc_enable_interrupts>       
40008298:	90 10 00 1b 	mov  %i3, %o0                                  
      false,                                                          
      false                                                           
    );                                                                
    _POSIX_signals_Release( &lock_context );                          
                                                                      
    the_info->si_code = SI_USER;                                      
4000829c:	82 10 20 01 	mov  1, %g1                                    
    the_info->si_value.sival_int = 0;                                 
400082a0:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
      false,                                                          
      false                                                           
    );                                                                
    _POSIX_signals_Release( &lock_context );                          
                                                                      
    the_info->si_code = SI_USER;                                      
400082a4:	c2 26 60 04 	st  %g1, [ %i1 + 4 ]                           
    the_info->si_value.sival_int = 0;                                 
    return the_info->si_signo;                                        
400082a8:	10 80 00 49 	b  400083cc <sigtimedwait+0x1e0>               
400082ac:	d0 06 40 00 	ld  [ %i1 ], %o0                               
  }                                                                   
                                                                      
  /* Process pending signals? */                                      
                                                                      
  if ( *set & _POSIX_signals_Pending ) {                              
400082b0:	d0 00 a0 d4 	ld  [ %g2 + 0xd4 ], %o0                        
400082b4:	80 88 40 08 	btst  %g1, %o0                                 
400082b8:	02 80 00 14 	be  40008308 <sigtimedwait+0x11c>              
400082bc:	01 00 00 00 	nop                                            
    signo = _POSIX_signals_Get_lowest( _POSIX_signals_Pending );      
400082c0:	7f ff ff b3 	call  4000818c <_POSIX_signals_Get_lowest>     
400082c4:	01 00 00 00 	nop                                            
    _POSIX_signals_Clear_signals( api, signo, the_info, true, false, false );
400082c8:	94 10 00 19 	mov  %i1, %o2                                  
  }                                                                   
                                                                      
  /* Process pending signals? */                                      
                                                                      
  if ( *set & _POSIX_signals_Pending ) {                              
    signo = _POSIX_signals_Get_lowest( _POSIX_signals_Pending );      
400082cc:	ba 10 00 08 	mov  %o0, %i5                                  
    _POSIX_signals_Clear_signals( api, signo, the_info, true, false, false );
400082d0:	96 10 20 01 	mov  1, %o3                                    
400082d4:	90 10 00 1c 	mov  %i4, %o0                                  
400082d8:	92 10 00 1d 	mov  %i5, %o1                                  
400082dc:	98 10 20 00 	clr  %o4                                       
400082e0:	40 00 18 21 	call  4000e364 <_POSIX_signals_Clear_signals>  
400082e4:	9a 10 20 00 	clr  %o5                                       
400082e8:	7f ff ea 3e 	call  40002be0 <sparc_enable_interrupts>       
400082ec:	90 10 00 1b 	mov  %i3, %o0                                  
    _POSIX_signals_Release( &lock_context );                          
                                                                      
    the_info->si_signo = signo;                                       
    the_info->si_code = SI_USER;                                      
400082f0:	82 10 20 01 	mov  1, %g1                                    
  if ( *set & _POSIX_signals_Pending ) {                              
    signo = _POSIX_signals_Get_lowest( _POSIX_signals_Pending );      
    _POSIX_signals_Clear_signals( api, signo, the_info, true, false, false );
    _POSIX_signals_Release( &lock_context );                          
                                                                      
    the_info->si_signo = signo;                                       
400082f4:	fa 26 40 00 	st  %i5, [ %i1 ]                               
    the_info->si_code = SI_USER;                                      
400082f8:	c2 26 60 04 	st  %g1, [ %i1 + 4 ]                           
    the_info->si_value.sival_int = 0;                                 
400082fc:	c0 26 60 08 	clr  [ %i1 + 8 ]                               
    return signo;                                                     
40008300:	10 80 00 33 	b  400083cc <sigtimedwait+0x1e0>               
40008304:	90 10 00 1d 	mov  %i5, %o0                                  
   *                                                                  
   * This rountine increments the thread dispatch level               
   */                                                                 
  RTEMS_INLINE_ROUTINE uint32_t _Thread_Dispatch_increment_disable_level(void)
  {                                                                   
    uint32_t disable_level = _Thread_Dispatch_disable_level;          
40008308:	c4 01 a0 10 	ld  [ %g6 + 0x10 ], %g2                        
  }                                                                   
                                                                      
  the_info->si_signo = -1;                                            
4000830c:	82 10 3f ff 	mov  -1, %g1                                   
40008310:	c2 26 40 00 	st  %g1, [ %i1 ]                               
                                                                      
    _ISR_Disable( level );                                            
    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), disable_level );
#endif                                                                
                                                                      
    ++disable_level;                                                  
40008314:	84 00 a0 01 	inc  %g2                                       
    _Thread_Dispatch_disable_level = disable_level;                   
40008318:	c4 21 a0 10 	st  %g2, [ %g6 + 0x10 ]                        
                                                                      
  _Thread_Disable_dispatch();                                         
    executing->Wait.queue           = &_POSIX_signals_Wait_queue;     
    executing->Wait.return_code     = EINTR;                          
4000831c:	84 10 20 04 	mov  4, %g2                                    
40008320:	c4 27 60 34 	st  %g2, [ %i5 + 0x34 ]                        
    executing->Wait.option          = *set;                           
40008324:	c4 06 00 00 	ld  [ %i0 ], %g2                               
    executing->Wait.return_argument = the_info;                       
40008328:	f2 27 60 28 	st  %i1, [ %i5 + 0x28 ]                        
  the_info->si_signo = -1;                                            
                                                                      
  _Thread_Disable_dispatch();                                         
    executing->Wait.queue           = &_POSIX_signals_Wait_queue;     
    executing->Wait.return_code     = EINTR;                          
    executing->Wait.option          = *set;                           
4000832c:	c4 27 60 30 	st  %g2, [ %i5 + 0x30 ]                        
  }                                                                   
                                                                      
  the_info->si_signo = -1;                                            
                                                                      
  _Thread_Disable_dispatch();                                         
    executing->Wait.queue           = &_POSIX_signals_Wait_queue;     
40008330:	03 10 00 73 	sethi  %hi(0x4001cc00), %g1                    
                                                                      
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;
40008334:	84 10 20 01 	mov  1, %g2                                    
40008338:	82 10 60 94 	or  %g1, 0x94, %g1                             
4000833c:	c2 27 60 44 	st  %g1, [ %i5 + 0x44 ]                        
40008340:	c4 20 60 30 	st  %g2, [ %g1 + 0x30 ]                        
40008344:	7f ff ea 27 	call  40002be0 <sparc_enable_interrupts>       
40008348:	90 10 00 1b 	mov  %i3, %o0                                  
    executing->Wait.return_code     = EINTR;                          
    executing->Wait.option          = *set;                           
    executing->Wait.return_argument = the_info;                       
    _Thread_queue_Enter_critical_section( &_POSIX_signals_Wait_queue );
    _POSIX_signals_Release( &lock_context );                          
    _Thread_queue_Enqueue( &_POSIX_signals_Wait_queue, executing, interval );
4000834c:	92 10 00 1d 	mov  %i5, %o1                                  
40008350:	94 10 00 1a 	mov  %i2, %o2                                  
40008354:	11 10 00 73 	sethi  %hi(0x4001cc00), %o0                    
40008358:	17 10 00 2e 	sethi  %hi(0x4000b800), %o3                    
4000835c:	90 12 20 94 	or  %o0, 0x94, %o0                             
40008360:	40 00 0c f2 	call  4000b728 <_Thread_queue_Enqueue_with_handler>
40008364:	96 12 e2 b8 	or  %o3, 0x2b8, %o3                            
  _Thread_Enable_dispatch();                                          
40008368:	40 00 0b b5 	call  4000b23c <_Thread_Enable_dispatch>       
4000836c:	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(                                       
40008370:	d2 06 40 00 	ld  [ %i1 ], %o1                               
40008374:	90 10 00 1c 	mov  %i4, %o0                                  
40008378:	94 10 00 19 	mov  %i1, %o2                                  
4000837c:	96 10 20 00 	clr  %o3                                       
40008380:	98 10 20 00 	clr  %o4                                       
40008384:	40 00 17 f8 	call  4000e364 <_POSIX_signals_Clear_signals>  
40008388:	9a 10 20 01 	mov  1, %o5                                    
  /* Set errno only if return code is not EINTR or                    
   * if EINTR was caused by a signal being caught, which              
   * was not in our set.                                              
   */                                                                 
                                                                      
  if ( (executing->Wait.return_code != EINTR)                         
4000838c:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
40008390:	80 a0 60 04 	cmp  %g1, 4                                    
40008394:	12 80 00 09 	bne  400083b8 <sigtimedwait+0x1cc>             
40008398:	84 10 20 01 	mov  1, %g2                                    
       || !(*set & signo_to_mask( the_info->si_signo )) ) {           
4000839c:	d0 06 40 00 	ld  [ %i1 ], %o0                               
400083a0:	82 02 3f ff 	add  %o0, -1, %g1                              
400083a4:	85 28 80 01 	sll  %g2, %g1, %g2                             
400083a8:	c2 06 00 00 	ld  [ %i0 ], %g1                               
400083ac:	80 88 80 01 	btst  %g2, %g1                                 
400083b0:	12 80 00 07 	bne  400083cc <sigtimedwait+0x1e0>             
400083b4:	01 00 00 00 	nop                                            
    errno = executing->Wait.return_code;                              
400083b8:	40 00 23 e1 	call  4001133c <__errno>                       
400083bc:	01 00 00 00 	nop                                            
400083c0:	c2 07 60 34 	ld  [ %i5 + 0x34 ], %g1                        
400083c4:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    return -1;                                                        
400083c8:	90 10 3f ff 	mov  -1, %o0                                   
  }                                                                   
                                                                      
  return the_info->si_signo;                                          
}                                                                     
400083cc:	81 c7 e0 08 	ret                                            
400083d0:	91 e8 00 08 	restore  %g0, %o0, %o0                         
                                                                      

4000a1c8 <sigwait>: int sigwait( const sigset_t *__restrict set, int *__restrict sig ) {
4000a1c8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int status;                                                         
                                                                      
  status = sigtimedwait( set, NULL, NULL );                           
4000a1cc:	92 10 20 00 	clr  %o1                                       
4000a1d0:	90 10 00 18 	mov  %i0, %o0                                  
4000a1d4:	7f ff ff 7f 	call  40009fd0 <sigtimedwait>                  
4000a1d8:	94 10 20 00 	clr  %o2                                       
                                                                      
  if ( status != -1 ) {                                               
4000a1dc:	80 a2 3f ff 	cmp  %o0, -1                                   
4000a1e0:	02 80 00 06 	be  4000a1f8 <sigwait+0x30>                    
4000a1e4:	80 a6 60 00 	cmp  %i1, 0                                    
    if ( sig )                                                        
4000a1e8:	32 80 00 09 	bne,a   4000a20c <sigwait+0x44>                <== ALWAYS TAKEN
4000a1ec:	d0 26 40 00 	st  %o0, [ %i1 ]                               
      *sig = status;                                                  
    return 0;                                                         
4000a1f0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000a1f4:	91 e8 20 00 	restore  %g0, 0, %o0                           <== NOT EXECUTED
  }                                                                   
                                                                      
  return errno;                                                       
4000a1f8:	40 00 23 8e 	call  40013030 <__errno>                       
4000a1fc:	01 00 00 00 	nop                                            
4000a200:	f0 02 00 00 	ld  [ %o0 ], %i0                               
4000a204:	81 c7 e0 08 	ret                                            
4000a208:	81 e8 00 00 	restore                                        
  status = sigtimedwait( set, NULL, NULL );                           
                                                                      
  if ( status != -1 ) {                                               
    if ( sig )                                                        
      *sig = status;                                                  
    return 0;                                                         
4000a20c:	b0 10 20 00 	clr  %i0                                       
  }                                                                   
                                                                      
  return errno;                                                       
}                                                                     
4000a210:	81 c7 e0 08 	ret                                            
4000a214:	81 e8 00 00 	restore                                        
                                                                      

40006144 <siproc>: /* * Process input character, with semaphore. */ static int siproc (unsigned char c, struct rtems_termios_tty *tty) {
40006144:	9d e3 bf a0 	save  %sp, -96, %sp                            
  int i;                                                              
                                                                      
  /*                                                                  
   * Obtain output semaphore if character will be echoed              
   */                                                                 
  if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) {
40006148:	c2 06 60 3c 	ld  [ %i1 + 0x3c ], %g1                        
4000614c:	80 88 6e 78 	btst  0xe78, %g1                               
40006150:	02 80 00 13 	be  4000619c <siproc+0x58>                     <== NEVER TAKEN
40006154:	92 10 20 00 	clr  %o1                                       
    rtems_status_code sc;                                             
    sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
40006158:	d0 06 60 18 	ld  [ %i1 + 0x18 ], %o0                        
4000615c:	40 00 05 41 	call  40007660 <rtems_semaphore_obtain>        
40006160:	94 10 20 00 	clr  %o2                                       
    if (sc != RTEMS_SUCCESSFUL)                                       
40006164:	80 a2 20 00 	cmp  %o0, 0                                    
40006168:	12 80 00 0b 	bne  40006194 <siproc+0x50>                    <== NEVER TAKEN
4000616c:	01 00 00 00 	nop                                            
      rtems_fatal_error_occurred (sc);                                
    i = iproc (c, tty);                                               
40006170:	90 10 00 18 	mov  %i0, %o0                                  
40006174:	7f ff ff 81 	call  40005f78 <iproc>                         
40006178:	92 10 00 19 	mov  %i1, %o1                                  
4000617c:	b0 10 00 08 	mov  %o0, %i0                                  
    sc = rtems_semaphore_release (tty->osem);                         
40006180:	40 00 05 80 	call  40007780 <rtems_semaphore_release>       
40006184:	d0 06 60 18 	ld  [ %i1 + 0x18 ], %o0                        
    if (sc != RTEMS_SUCCESSFUL)                                       
40006188:	80 a2 20 00 	cmp  %o0, 0                                    
4000618c:	02 80 00 06 	be  400061a4 <siproc+0x60>                     <== ALWAYS TAKEN
40006190:	01 00 00 00 	nop                                            
      rtems_fatal_error_occurred (sc);                                
40006194:	40 00 06 fc 	call  40007d84 <rtems_fatal_error_occurred>    <== NOT EXECUTED
40006198:	01 00 00 00 	nop                                            <== NOT EXECUTED
  }                                                                   
  else {                                                              
    i = iproc (c, tty);                                               
4000619c:	7f ff ff 77 	call  40005f78 <iproc>                         <== NOT EXECUTED
400061a0:	81 e8 00 00 	restore                                        <== NOT EXECUTED
  }                                                                   
  return i;                                                           
}                                                                     
400061a4:	81 c7 e0 08 	ret                                            
400061a8:	81 e8 00 00 	restore                                        
                                                                      

4000e864 <sparse_disk_ioctl>: /* * ioctl handler to be passed to the block device handler */ static int sparse_disk_ioctl( rtems_disk_device *dd, uint32_t req, void *argp ) {
4000e864:	9d e3 bf 98 	save  %sp, -104, %sp                           
  rtems_status_code  sc;                                              
  rtems_sparse_disk *sd = rtems_disk_get_driver_data( dd );           
                                                                      
  if ( RTEMS_BLKIO_REQUEST == req ) {                                 
4000e868:	03 30 06 10 	sethi  %hi(0xc0184000), %g1                    
4000e86c:	82 10 62 01 	or  %g1, 0x201, %g1	! c0184201 <RAM_END+0x7fd84201>
4000e870:	80 a6 40 01 	cmp  %i1, %g1                                  
4000e874:	12 80 00 83 	bne  4000ea80 <sparse_disk_ioctl+0x21c>        
4000e878:	fa 06 20 3c 	ld  [ %i0 + 0x3c ], %i5                        
    rtems_blkdev_request *r = argp;                                   
                                                                      
    switch ( r->req ) {                                               
4000e87c:	ea 06 80 00 	ld  [ %i2 ], %l5                               
4000e880:	80 a5 60 01 	cmp  %l5, 1                                    
4000e884:	18 80 00 97 	bgu  4000eae0 <sparse_disk_ioctl+0x27c>        <== NEVER TAKEN
4000e888:	92 10 20 00 	clr  %o1                                       
  uint8_t                *buff;                                       
  size_t                  buff_size;                                  
  unsigned int            bytes_handled;                              
  rtems_status_code       sc;                                         
                                                                      
  sc = rtems_semaphore_obtain(sparse_disk->mutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
4000e88c:	d0 07 40 00 	ld  [ %i5 ], %o0                               
4000e890:	7f ff ea 63 	call  4000921c <rtems_semaphore_obtain>        
4000e894:	94 10 20 00 	clr  %o2                                       
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000e898:	80 a2 20 00 	cmp  %o0, 0                                    
4000e89c:	12 80 00 1c 	bne  4000e90c <sparse_disk_ioctl+0xa8>         <== NEVER TAKEN
4000e8a0:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
4000e8a4:	27 10 00 3a 	sethi  %hi(0x4000e800), %l3                    
4000e8a8:	b2 10 00 1a 	mov  %i2, %i1                                  
4000e8ac:	b6 10 20 00 	clr  %i3                                       
4000e8b0:	a4 10 20 00 	clr  %l2                                       
                                                                      
  /* we only need to write the block if it is different from the fill pattern.
   * If the read method does not find a block it will deliver the fill pattern anyway.
   */                                                                 
                                                                      
  key = bsearch(                                                      
4000e8b4:	a6 14 e0 30 	or  %l3, 0x30, %l3                             
  if (sc != RTEMS_SUCCESSFUL) {                                       
      rtems_fatal_error_occurred( 0xdeadbeef );                       
  }                                                                   
                                                                      
  for ( req_buffer = 0;                                               
        ( 0 <= rv ) && ( req_buffer < req->bufnum );                  
4000e8b8:	c2 06 a0 10 	ld  [ %i2 + 0x10 ], %g1                        
4000e8bc:	80 a4 80 01 	cmp  %l2, %g1                                  
4000e8c0:	1a 80 00 0d 	bcc  4000e8f4 <sparse_disk_ioctl+0x90>         
4000e8c4:	01 00 00 00 	nop                                            
        ++req_buffer ) {                                              
    scatter_gather = &req->bufs[req_buffer];                          
                                                                      
    bytes_handled  = 0;                                               
    buff           = (uint8_t *) scatter_gather->buffer;              
4000e8c8:	ec 06 60 20 	ld  [ %i1 + 0x20 ], %l6                        
    block          = scatter_gather->block;                           
4000e8cc:	f0 06 60 18 	ld  [ %i1 + 0x18 ], %i0                        
    buff_size      = scatter_gather->length;                          
4000e8d0:	f8 06 60 1c 	ld  [ %i1 + 0x1c ], %i4                        
  for ( req_buffer = 0;                                               
        ( 0 <= rv ) && ( req_buffer < req->bufnum );                  
        ++req_buffer ) {                                              
    scatter_gather = &req->bufs[req_buffer];                          
                                                                      
    bytes_handled  = 0;                                               
4000e8d4:	a8 10 20 00 	clr  %l4                                       
    buff           = (uint8_t *) scatter_gather->buffer;              
    block          = scatter_gather->block;                           
    buff_size      = scatter_gather->length;                          
                                                                      
    while ( ( 0 <= rv ) && ( 0 < buff_size ) ) {                      
4000e8d8:	80 a7 20 00 	cmp  %i4, 0                                    
4000e8dc:	12 80 00 0e 	bne  4000e914 <sparse_disk_ioctl+0xb0>         
4000e8e0:	80 a6 e0 00 	cmp  %i3, 0                                    
      rtems_fatal_error_occurred( 0xdeadbeef );                       
  }                                                                   
                                                                      
  for ( req_buffer = 0;                                               
        ( 0 <= rv ) && ( req_buffer < req->bufnum );                  
        ++req_buffer ) {                                              
4000e8e4:	a4 04 a0 01 	inc  %l2                                       
  sc = rtems_semaphore_obtain(sparse_disk->mutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
  if (sc != RTEMS_SUCCESSFUL) {                                       
      rtems_fatal_error_occurred( 0xdeadbeef );                       
  }                                                                   
                                                                      
  for ( req_buffer = 0;                                               
4000e8e8:	80 a6 e0 00 	cmp  %i3, 0                                    
4000e8ec:	16 bf ff f3 	bge  4000e8b8 <sparse_disk_ioctl+0x54>         <== ALWAYS TAKEN
4000e8f0:	b2 06 60 10 	add  %i1, 0x10, %i1                            
      bytes_handled += rv;                                            
      buff_size     -= rv;                                            
    }                                                                 
  }                                                                   
                                                                      
  sc = rtems_semaphore_release( sparse_disk->mutex );                 
4000e8f4:	7f ff ea 92 	call  4000933c <rtems_semaphore_release>       
4000e8f8:	d0 07 40 00 	ld  [ %i5 ], %o0                               
  if (sc != RTEMS_SUCCESSFUL) {                                       
4000e8fc:	80 a2 20 00 	cmp  %o0, 0                                    
4000e900:	22 80 00 57 	be,a   4000ea5c <sparse_disk_ioctl+0x1f8>      <== ALWAYS TAKEN
4000e904:	90 10 00 1a 	mov  %i2, %o0                                  
  unsigned int            bytes_handled;                              
  rtems_status_code       sc;                                         
                                                                      
  sc = rtems_semaphore_obtain(sparse_disk->mutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
  if (sc != RTEMS_SUCCESSFUL) {                                       
      rtems_fatal_error_occurred( 0xdeadbeef );                       
4000e908:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    <== NOT EXECUTED
4000e90c:	7f ff ec 0f 	call  40009948 <rtems_fatal_error_occurred>    <== NOT EXECUTED
4000e910:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
    bytes_handled  = 0;                                               
    buff           = (uint8_t *) scatter_gather->buffer;              
    block          = scatter_gather->block;                           
    buff_size      = scatter_gather->length;                          
                                                                      
    while ( ( 0 <= rv ) && ( 0 < buff_size ) ) {                      
4000e914:	06 bf ff f4 	bl  4000e8e4 <sparse_disk_ioctl+0x80>          <== NEVER TAKEN
4000e918:	80 a5 60 00 	cmp  %l5, 0                                    
  const rtems_blkdev_bnum  block,                                     
  uint8_t                 *buffer,                                    
  const size_t             buffer_size )                              
{                                                                     
  rtems_sparse_disk_key *key;                                         
  rtems_sparse_disk_key  block_key = {                                
4000e91c:	f0 27 bf f8 	st  %i0, [ %fp + -8 ]                          
4000e920:	c0 27 bf fc 	clr  [ %fp + -4 ]                              
    .block = block,                                                   
    .data  = NULL                                                     
  };                                                                  
  size_t                 bytes_to_copy = sparse_disk->media_block_size;
4000e924:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
    buff           = (uint8_t *) scatter_gather->buffer;              
    block          = scatter_gather->block;                           
    buff_size      = scatter_gather->length;                          
                                                                      
    while ( ( 0 <= rv ) && ( 0 < buff_size ) ) {                      
      if ( read )                                                     
4000e928:	12 80 00 1a 	bne  4000e990 <sparse_disk_ioctl+0x12c>        
4000e92c:	a2 05 80 14 	add  %l6, %l4, %l1                             
4000e930:	80 a7 00 01 	cmp  %i4, %g1                                  
4000e934:	08 80 00 03 	bleu  4000e940 <sparse_disk_ioctl+0xdc>        
4000e938:	b6 10 00 1c 	mov  %i4, %i3                                  
4000e93c:	b6 10 00 01 	mov  %g1, %i3                                  
  size_t                 bytes_to_copy = sparse_disk->media_block_size;
                                                                      
  if ( buffer_size < bytes_to_copy )                                  
    bytes_to_copy = buffer_size;                                      
                                                                      
  key = bsearch(                                                      
4000e940:	d2 07 60 18 	ld  [ %i5 + 0x18 ], %o1                        
4000e944:	d4 07 60 08 	ld  [ %i5 + 8 ], %o2                           
4000e948:	90 07 bf f8 	add  %fp, -8, %o0                              
4000e94c:	96 10 20 08 	mov  8, %o3                                    
4000e950:	40 00 36 af 	call  4001c40c <bsearch>                       
4000e954:	98 10 00 13 	mov  %l3, %o4                                  
4000e958:	82 10 00 08 	mov  %o0, %g1                                  
    sparse_disk->used_count,                                          
    sizeof( rtems_sparse_disk_key ),                                  
    sparse_disk_compare                                               
    );                                                                
                                                                      
  if ( NULL != key )                                                  
4000e95c:	80 a0 60 00 	cmp  %g1, 0                                    
4000e960:	02 80 00 07 	be  4000e97c <sparse_disk_ioctl+0x118>         
4000e964:	90 10 00 11 	mov  %l1, %o0                                  
    memcpy( buffer, key->data, bytes_to_copy );                       
4000e968:	d2 00 60 04 	ld  [ %g1 + 4 ], %o1                           
4000e96c:	40 00 39 1d 	call  4001cde0 <memcpy>                        
4000e970:	94 10 00 1b 	mov  %i3, %o2                                  
        rv = sparse_disk_write_block( sparse_disk,                    
                                      block,                          
                                      &buff[bytes_handled],           
                                      buff_size );                    
                                                                      
      ++block;                                                        
4000e974:	10 80 00 37 	b  4000ea50 <sparse_disk_ioctl+0x1ec>          
4000e978:	b0 06 20 01 	inc  %i0                                       
    );                                                                
                                                                      
  if ( NULL != key )                                                  
    memcpy( buffer, key->data, bytes_to_copy );                       
  else                                                                
    memset( buffer, sparse_disk->fill_pattern, buffer_size );         
4000e97c:	d2 0f 60 14 	ldub  [ %i5 + 0x14 ], %o1                      
4000e980:	40 00 39 57 	call  4001cedc <memset>                        
4000e984:	94 10 00 1c 	mov  %i4, %o2                                  
        rv = sparse_disk_write_block( sparse_disk,                    
                                      block,                          
                                      &buff[bytes_handled],           
                                      buff_size );                    
                                                                      
      ++block;                                                        
4000e988:	10 80 00 32 	b  4000ea50 <sparse_disk_ioctl+0x1ec>          
4000e98c:	b0 06 20 01 	inc  %i0                                       
4000e990:	80 a7 00 01 	cmp  %i4, %g1                                  
4000e994:	08 80 00 03 	bleu  4000e9a0 <sparse_disk_ioctl+0x13c>       
4000e998:	a0 10 00 1c 	mov  %i4, %l0                                  
4000e99c:	a0 10 00 01 	mov  %g1, %l0                                  
                                                                      
  /* we only need to write the block if it is different from the fill pattern.
   * If the read method does not find a block it will deliver the fill pattern anyway.
   */                                                                 
                                                                      
  key = bsearch(                                                      
4000e9a0:	d2 07 60 18 	ld  [ %i5 + 0x18 ], %o1                        
4000e9a4:	d4 07 60 08 	ld  [ %i5 + 8 ], %o2                           
4000e9a8:	90 07 bf f8 	add  %fp, -8, %o0                              
4000e9ac:	96 10 20 08 	mov  8, %o3                                    
4000e9b0:	40 00 36 97 	call  4001c40c <bsearch>                       
4000e9b4:	98 10 00 13 	mov  %l3, %o4                                  
    sparse_disk->used_count,                                          
    sizeof( rtems_sparse_disk_key ),                                  
    sparse_disk_compare                                               
    );                                                                
                                                                      
  if ( NULL == key ) {                                                
4000e9b8:	84 10 20 00 	clr  %g2                                       
4000e9bc:	b6 92 20 00 	orcc  %o0, 0, %i3                              
4000e9c0:	12 80 00 1e 	bne  4000ea38 <sparse_disk_ioctl+0x1d4>        
4000e9c4:	82 10 20 00 	clr  %g1                                       
    for ( i = 0; ( !block_needs_writing ) && ( i < bytes_to_copy ); ++i ) {
4000e9c8:	80 a0 40 10 	cmp  %g1, %l0                                  
4000e9cc:	1a 80 00 0b 	bcc  4000e9f8 <sparse_disk_ioctl+0x194>        
4000e9d0:	80 88 a0 ff 	btst  0xff, %g2                                
4000e9d4:	12 80 00 09 	bne  4000e9f8 <sparse_disk_ioctl+0x194>        
4000e9d8:	01 00 00 00 	nop                                            
      if ( buffer[i] != sparse_disk->fill_pattern )                   
4000e9dc:	c6 0c 40 01 	ldub  [ %l1 + %g1 ], %g3                       
4000e9e0:	c4 0f 60 14 	ldub  [ %i5 + 0x14 ], %g2                      
    sizeof( rtems_sparse_disk_key ),                                  
    sparse_disk_compare                                               
    );                                                                
                                                                      
  if ( NULL == key ) {                                                
    for ( i = 0; ( !block_needs_writing ) && ( i < bytes_to_copy ); ++i ) {
4000e9e4:	82 00 60 01 	inc  %g1                                       
      if ( buffer[i] != sparse_disk->fill_pattern )                   
4000e9e8:	84 18 c0 02 	xor  %g3, %g2, %g2                             
4000e9ec:	80 a0 00 02 	cmp  %g0, %g2                                  
4000e9f0:	10 bf ff f6 	b  4000e9c8 <sparse_disk_ioctl+0x164>          
4000e9f4:	84 40 20 00 	addx  %g0, 0, %g2                              
        block_needs_writing = true;                                   
    }                                                                 
                                                                      
    if ( block_needs_writing ) {                                      
4000e9f8:	22 80 00 15 	be,a   4000ea4c <sparse_disk_ioctl+0x1e8>      
4000e9fc:	b6 10 00 10 	mov  %l0, %i3                                  
  rtems_sparse_disk      *sparse_disk,                                
  const rtems_blkdev_bnum block )                                     
{                                                                     
  rtems_sparse_disk_key *key;                                         
                                                                      
  if ( sparse_disk->used_count < sparse_disk->blocks_with_buffer ) {  
4000ea00:	d2 07 60 08 	ld  [ %i5 + 8 ], %o1                           
4000ea04:	c2 07 60 04 	ld  [ %i5 + 4 ], %g1                           
4000ea08:	80 a2 40 01 	cmp  %o1, %g1                                  
4000ea0c:	1a 80 00 10 	bcc  4000ea4c <sparse_disk_ioctl+0x1e8>        <== NEVER TAKEN
4000ea10:	b6 10 3f ff 	mov  -1, %i3                                   
    key        = &sparse_disk->key_table[sparse_disk->used_count];    
4000ea14:	d0 07 60 18 	ld  [ %i5 + 0x18 ], %o0                        
4000ea18:	83 2a 60 03 	sll  %o1, 3, %g1                               
    key->block = block;                                               
4000ea1c:	f0 22 00 01 	st  %i0, [ %o0 + %g1 ]                         
    ++sparse_disk->used_count;                                        
4000ea20:	92 02 60 01 	inc  %o1                                       
  const rtems_blkdev_bnum block )                                     
{                                                                     
  rtems_sparse_disk_key *key;                                         
                                                                      
  if ( sparse_disk->used_count < sparse_disk->blocks_with_buffer ) {  
    key        = &sparse_disk->key_table[sparse_disk->used_count];    
4000ea24:	b6 02 00 01 	add  %o0, %g1, %i3                             
    key->block = block;                                               
    ++sparse_disk->used_count;                                        
4000ea28:	d2 27 60 08 	st  %o1, [ %i5 + 8 ]                           
    qsort( sparse_disk->key_table, sparse_disk->used_count,           
4000ea2c:	94 10 20 08 	mov  8, %o2                                    
4000ea30:	40 00 39 73 	call  4001cffc <qsort>                         
4000ea34:	96 10 00 13 	mov  %l3, %o3                                  
      key = sparse_disk_get_new_block( sparse_disk, block );          
    }                                                                 
  }                                                                   
                                                                      
  if ( NULL != key )                                                  
    memcpy( key->data, buffer, bytes_to_copy );                       
4000ea38:	d0 06 e0 04 	ld  [ %i3 + 4 ], %o0                           
4000ea3c:	92 10 00 11 	mov  %l1, %o1                                  
4000ea40:	40 00 38 e8 	call  4001cde0 <memcpy>                        
4000ea44:	94 10 00 10 	mov  %l0, %o2                                  
  else if ( block_needs_writing )                                     
    return -1;                                                        
                                                                      
  return bytes_to_copy;                                               
4000ea48:	b6 10 00 10 	mov  %l0, %i3                                  
        rv = sparse_disk_write_block( sparse_disk,                    
                                      block,                          
                                      &buff[bytes_handled],           
                                      buff_size );                    
                                                                      
      ++block;                                                        
4000ea4c:	b0 06 20 01 	inc  %i0                                       
      bytes_handled += rv;                                            
4000ea50:	a8 05 00 1b 	add  %l4, %i3, %l4                             
      buff_size     -= rv;                                            
4000ea54:	10 bf ff a1 	b  4000e8d8 <sparse_disk_ioctl+0x74>           
4000ea58:	b8 27 00 1b 	sub  %i4, %i3, %i4                             
static inline void rtems_blkdev_request_done(                         
  rtems_blkdev_request *req,                                          
  rtems_status_code status                                            
)                                                                     
{                                                                     
  (*req->done)(req, status);                                          
4000ea5c:	92 10 20 1b 	mov  0x1b, %o1                                 
  sc = rtems_semaphore_release( sparse_disk->mutex );                 
  if (sc != RTEMS_SUCCESSFUL) {                                       
      rtems_fatal_error_occurred( 0xdeadbeef );                       
  }                                                                   
                                                                      
  if ( 0 > rv )                                                       
4000ea60:	80 a6 e0 00 	cmp  %i3, 0                                    
4000ea64:	06 80 00 03 	bl  4000ea70 <sparse_disk_ioctl+0x20c>         <== NEVER TAKEN
4000ea68:	c2 06 a0 04 	ld  [ %i2 + 4 ], %g1                           
4000ea6c:	92 10 20 00 	clr  %o1                                       
4000ea70:	9f c0 40 00 	call  %g1                                      
4000ea74:	b0 10 20 00 	clr  %i0                                       
4000ea78:	81 c7 e0 08 	ret                                            
4000ea7c:	81 e8 00 00 	restore                                        
      case RTEMS_BLKDEV_REQ_WRITE:                                    
        return sparse_disk_read_write( sd, r, r->req == RTEMS_BLKDEV_REQ_READ );
      default:                                                        
        break;                                                        
    }                                                                 
  } else if ( RTEMS_BLKIO_DELETED == req ) {                          
4000ea80:	03 08 00 10 	sethi  %hi(0x20004000), %g1                    
4000ea84:	82 10 62 07 	or  %g1, 0x207, %g1	! 20004207 <RAM_SIZE+0x1fc04207>
4000ea88:	80 a6 40 01 	cmp  %i1, %g1                                  
4000ea8c:	12 80 00 10 	bne  4000eacc <sparse_disk_ioctl+0x268>        
4000ea90:	90 10 00 18 	mov  %i0, %o0                                  
    sc = rtems_semaphore_delete( sd->mutex );                         
4000ea94:	7f ff e9 aa 	call  4000913c <rtems_semaphore_delete>        
4000ea98:	d0 07 40 00 	ld  [ %i5 ], %o0                               
                                                                      
    if ( RTEMS_SUCCESSFUL != sc )                                     
4000ea9c:	80 a2 20 00 	cmp  %o0, 0                                    
4000eaa0:	12 bf ff 9b 	bne  4000e90c <sparse_disk_ioctl+0xa8>         <== NEVER TAKEN
4000eaa4:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
      rtems_fatal_error_occurred( 0xdeadbeef );                       
                                                                      
    sd->mutex = RTEMS_ID_NONE;                                        
                                                                      
    if ( NULL != sd->delete_handler )                                 
4000eaa8:	c2 07 60 10 	ld  [ %i5 + 0x10 ], %g1                        
    sc = rtems_semaphore_delete( sd->mutex );                         
                                                                      
    if ( RTEMS_SUCCESSFUL != sc )                                     
      rtems_fatal_error_occurred( 0xdeadbeef );                       
                                                                      
    sd->mutex = RTEMS_ID_NONE;                                        
4000eaac:	c0 27 40 00 	clr  [ %i5 ]                                   
                                                                      
    if ( NULL != sd->delete_handler )                                 
4000eab0:	80 a0 60 00 	cmp  %g1, 0                                    
4000eab4:	02 bf ff f1 	be  4000ea78 <sparse_disk_ioctl+0x214>         <== NEVER TAKEN
4000eab8:	b0 10 20 00 	clr  %i0                                       
      ( *sd->delete_handler )( sd );                                  
4000eabc:	9f c0 40 00 	call  %g1                                      
4000eac0:	90 10 00 1d 	mov  %i5, %o0                                  
4000eac4:	81 c7 e0 08 	ret                                            
4000eac8:	81 e8 00 00 	restore                                        
                                                                      
    return 0;                                                         
  } else {                                                            
    return rtems_blkdev_ioctl( dd, req, argp );                       
4000eacc:	92 10 00 19 	mov  %i1, %o1                                  
4000ead0:	40 00 0a 81 	call  400114d4 <rtems_blkdev_ioctl>            
4000ead4:	94 10 00 1a 	mov  %i2, %o2                                  
4000ead8:	81 c7 e0 08 	ret                                            
4000eadc:	91 e8 00 08 	restore  %g0, %o0, %o0                         
  }                                                                   
                                                                      
  errno = EINVAL;                                                     
4000eae0:	40 00 36 6b 	call  4001c48c <__errno>                       <== NOT EXECUTED
4000eae4:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
4000eae8:	82 10 20 16 	mov  0x16, %g1                                 <== NOT EXECUTED
4000eaec:	c2 22 00 00 	st  %g1, [ %o0 ]                               <== NOT EXECUTED
  return -1;                                                          
}                                                                     
4000eaf0:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
4000eaf4:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40005cf0 <sync_per_thread>: fdatasync(fn); } /* iterate over all FILE *'s for this thread */ static void sync_per_thread(Thread_Control *t) {
40005cf0:	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;                                        
40005cf4:	c2 06 21 28 	ld  [ %i0 + 0x128 ], %g1                       
   if ( this_reent ) {                                                
40005cf8:	80 a0 60 00 	cmp  %g1, 0                                    
40005cfc:	02 80 00 09 	be  40005d20 <sync_per_thread+0x30>            <== NEVER TAKEN
40005d00:	13 10 00 17 	sethi  %hi(0x40005c00), %o1                    
    ISR_Level level;                                                  
                                                                      
    _ISR_Disable_without_giant( level );                              
  #endif                                                              
                                                                      
  executing = _Thread_Executing;                                      
40005d04:	fa 01 a0 18 	ld  [ %g6 + 0x18 ], %i5                        
     Thread_Control *executing = _Thread_Get_executing();             
     current_reent = executing->libc_reent;                           
40005d08:	f8 07 61 28 	ld  [ %i5 + 0x128 ], %i4                       
     executing->libc_reent = this_reent;                              
40005d0c:	c2 27 61 28 	st  %g1, [ %i5 + 0x128 ]                       
     _fwalk (t->libc_reent, sync_wrapper);                            
40005d10:	d0 06 21 28 	ld  [ %i0 + 0x128 ], %o0                       
40005d14:	40 00 2f 20 	call  40011994 <_fwalk>                        
40005d18:	92 12 61 28 	or  %o1, 0x128, %o1                            
     executing->libc_reent = current_reent;                           
40005d1c:	f8 27 61 28 	st  %i4, [ %i5 + 0x128 ]                       
40005d20:	81 c7 e0 08 	ret                                            
40005d24:	81 e8 00 00 	restore                                        
                                                                      

40006f10 <sysconf>: */ long sysconf( int name ) {
40006f10:	9d e3 bf a0 	save  %sp, -96, %sp                            
  if ( name == _SC_CLK_TCK )                                          
40006f14:	80 a6 20 02 	cmp  %i0, 2                                    
40006f18:	12 80 00 09 	bne  40006f3c <sysconf+0x2c>                   
40006f1c:	03 10 00 5e 	sethi  %hi(0x40017800), %g1                    
    return (TOD_MICROSECONDS_PER_SECOND /                             
40006f20:	03 10 00 58 	sethi  %hi(0x40016000), %g1                    
40006f24:	d2 00 60 1c 	ld  [ %g1 + 0x1c ], %o1	! 4001601c <Configuration+0x14>
40006f28:	11 00 03 d0 	sethi  %hi(0xf4000), %o0                       
40006f2c:	40 00 33 cc 	call  40013e5c <.udiv>                         
40006f30:	90 12 22 40 	or  %o0, 0x240, %o0	! f4240 <_TLS_Alignment+0xf423f>
40006f34:	81 c7 e0 08 	ret                                            
40006f38:	91 e8 00 08 	restore  %g0, %o0, %o0                         
      rtems_configuration_get_microseconds_per_tick());               
                                                                      
  if ( name == _SC_OPEN_MAX )                                         
40006f3c:	80 a6 20 04 	cmp  %i0, 4                                    
40006f40:	02 80 00 13 	be  40006f8c <sysconf+0x7c>                    
40006f44:	d0 00 60 c0 	ld  [ %g1 + 0xc0 ], %o0                        
    return rtems_libio_number_iops;                                   
                                                                      
  if ( name == _SC_GETPW_R_SIZE_MAX )                                 
40006f48:	80 a6 20 33 	cmp  %i0, 0x33                                 
40006f4c:	02 80 00 10 	be  40006f8c <sysconf+0x7c>                    
40006f50:	90 10 24 00 	mov  0x400, %o0                                
    return 1024;                                                      
                                                                      
  if ( name == _SC_PAGESIZE )                                         
40006f54:	80 a6 20 08 	cmp  %i0, 8                                    
40006f58:	02 80 00 0d 	be  40006f8c <sysconf+0x7c>                    
40006f5c:	11 00 00 04 	sethi  %hi(0x1000), %o0                        
    return PAGE_SIZE;                                                 
                                                                      
  if ( name == _SC_SYMLOOP_MAX )                                      
40006f60:	80 a6 20 4f 	cmp  %i0, 0x4f                                 
40006f64:	02 80 00 0a 	be  40006f8c <sysconf+0x7c>                    <== NEVER TAKEN
40006f68:	90 10 20 20 	mov  0x20, %o0                                 
    return RTEMS_FILESYSTEM_SYMLOOP_MAX;                              
                                                                      
#if defined(__sparc__)                                                
  if ( name == 515 ) /* Solaris _SC_STACK_PROT */                     
40006f6c:	80 a6 22 03 	cmp  %i0, 0x203                                
40006f70:	02 80 00 07 	be  40006f8c <sysconf+0x7c>                    <== NEVER TAKEN
40006f74:	90 10 20 00 	clr  %o0                                       
   return 0;                                                          
#endif                                                                
                                                                      
  rtems_set_errno_and_return_minus_one( EINVAL );                     
40006f78:	40 00 23 7e 	call  4000fd70 <__errno>                       
40006f7c:	01 00 00 00 	nop                                            
40006f80:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
40006f84:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40006f88:	90 10 3f ff 	mov  -1, %o0                                   
}                                                                     
40006f8c:	b0 10 00 08 	mov  %o0, %i0                                  
40006f90:	81 c7 e0 08 	ret                                            
40006f94:	81 e8 00 00 	restore                                        
                                                                      

400136d0 <tcsetattr>: int tcsetattr( int fd, int opt, struct termios *tp ) {
400136d0:	9d e3 bf a0 	save  %sp, -96, %sp                            
  switch (opt) {                                                      
400136d4:	80 a6 60 00 	cmp  %i1, 0                                    
400136d8:	02 80 00 10 	be  40013718 <tcsetattr+0x48>                  
400136dc:	80 a6 60 01 	cmp  %i1, 1                                    
400136e0:	02 80 00 08 	be  40013700 <tcsetattr+0x30>                  
400136e4:	90 10 00 18 	mov  %i0, %o0                                  
  default:                                                            
    rtems_set_errno_and_return_minus_one( ENOTSUP );                  
400136e8:	40 00 10 e9 	call  40017a8c <__errno>                       
400136ec:	b0 10 3f ff 	mov  -1, %i0                                   
400136f0:	82 10 20 86 	mov  0x86, %g1                                 
400136f4:	c2 22 00 00 	st  %g1, [ %o0 ]                               
400136f8:	81 c7 e0 08 	ret                                            
400136fc:	81 e8 00 00 	restore                                        
                                                                      
  case TCSADRAIN:                                                     
    if (ioctl( fd, RTEMS_IO_TCDRAIN, NULL ) < 0)                      
40013700:	92 10 20 03 	mov  3, %o1                                    
40013704:	40 00 0c 8e 	call  4001693c <ioctl>                         
40013708:	94 10 20 00 	clr  %o2                                       
4001370c:	80 a2 20 00 	cmp  %o0, 0                                    
40013710:	26 80 00 04 	bl,a   40013720 <tcsetattr+0x50>               <== NEVER TAKEN
40013714:	b0 10 3f ff 	mov  -1, %i0                                   <== NOT EXECUTED
    	return -1;                                                       
    /*                                                                
     * Fall through to....                                            
     */                                                               
  case TCSANOW:                                                       
    return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp );                  
40013718:	40 00 0c 89 	call  4001693c <ioctl>                         
4001371c:	93 e8 20 02 	restore  %g0, 2, %o1                           
  }                                                                   
}                                                                     
40013720:	81 c7 e0 08 	ret                                            <== NOT EXECUTED
40013724:	81 e8 00 00 	restore                                        <== NOT EXECUTED
                                                                      

40008c94 <timer_create>: int timer_create( clockid_t clock_id, struct sigevent *__restrict evp, timer_t *__restrict timerid ) {
40008c94:	9d e3 bf a0 	save  %sp, -96, %sp                            
  POSIX_Timer_Control *ptimer;                                        
                                                                      
  if ( clock_id != CLOCK_REALTIME )                                   
40008c98:	80 a6 20 01 	cmp  %i0, 1                                    
40008c9c:	02 80 00 06 	be  40008cb4 <timer_create+0x20>               
40008ca0:	80 a6 a0 00 	cmp  %i2, 0                                    
    rtems_set_errno_and_return_minus_one( EINVAL );                   
40008ca4:	40 00 25 5d 	call  40012218 <__errno>                       
40008ca8:	01 00 00 00 	nop                                            
40008cac:	10 80 00 1a 	b  40008d14 <timer_create+0x80>                
40008cb0:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
                                                                      
  if ( !timerid )                                                     
40008cb4:	02 bf ff fc 	be  40008ca4 <timer_create+0x10>               
40008cb8:	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) {                                                  
40008cbc:	02 80 00 0c 	be  40008cec <timer_create+0x58>               
40008cc0:	3b 10 00 78 	sethi  %hi(0x4001e000), %i5                    
    /* The structure has data */                                      
    if ( ( evp->sigev_notify != SIGEV_NONE ) &&                       
40008cc4:	c2 06 40 00 	ld  [ %i1 ], %g1                               
40008cc8:	82 00 7f ff 	add  %g1, -1, %g1                              
40008ccc:	80 a0 60 01 	cmp  %g1, 1                                    
40008cd0:	18 bf ff f5 	bgu  40008ca4 <timer_create+0x10>              <== NEVER TAKEN
40008cd4:	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 )                                         
40008cd8:	c2 06 60 04 	ld  [ %i1 + 4 ], %g1                           
40008cdc:	82 00 7f ff 	add  %g1, -1, %g1                              
40008ce0:	80 a0 60 1f 	cmp  %g1, 0x1f                                 
40008ce4:	18 bf ff f0 	bgu  40008ca4 <timer_create+0x10>              <== NEVER TAKEN
40008ce8:	01 00 00 00 	nop                                            
 *  This function allocates a timer control block from                
 *  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 );
40008cec:	40 00 09 39 	call  4000b1d0 <_Objects_Allocate>             
40008cf0:	90 17 63 20 	or  %i5, 0x320, %o0                            
                                                                      
  /*                                                                  
   *  Allocate a timer                                                
   */                                                                 
  ptimer = _POSIX_Timer_Allocate();                                   
  if ( !ptimer ) {                                                    
40008cf4:	80 a2 20 00 	cmp  %o0, 0                                    
40008cf8:	12 80 00 0a 	bne  40008d20 <timer_create+0x8c>              
40008cfc:	03 10 00 78 	sethi  %hi(0x4001e000), %g1                    
}                                                                     
                                                                      
static inline void _RTEMS_Unlock_allocator( void )                    
{                                                                     
  _API_Mutex_Unlock( _RTEMS_Allocator_Mutex );                        
40008d00:	40 00 05 e0 	call  4000a480 <_API_Mutex_Unlock>             
40008d04:	d0 00 60 d8 	ld  [ %g1 + 0xd8 ], %o0	! 4001e0d8 <_RTEMS_Allocator_Mutex>
    _Objects_Allocator_unlock();                                      
    rtems_set_errno_and_return_minus_one( EAGAIN );                   
40008d08:	40 00 25 44 	call  40012218 <__errno>                       
40008d0c:	01 00 00 00 	nop                                            
40008d10:	82 10 20 0b 	mov  0xb, %g1	! b <_TLS_Alignment+0xa>         
40008d14:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40008d18:	81 c7 e0 08 	ret                                            
40008d1c:	91 e8 3f ff 	restore  %g0, -1, %o0                          
  }                                                                   
                                                                      
  /* The data of the created timer are stored to use them later */    
                                                                      
  ptimer->state     = POSIX_TIMER_STATE_CREATE_NEW;                   
40008d20:	84 10 20 02 	mov  2, %g2                                    
40008d24:	c4 2a 20 3c 	stb  %g2, [ %o0 + 0x3c ]                       
  ptimer->thread_id = _Thread_Get_executing()->Object.id;             
40008d28:	c4 01 a0 18 	ld  [ %g6 + 0x18 ], %g2                        
                                                                      
  if ( evp != NULL ) {                                                
40008d2c:	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_Get_executing()->Object.id;             
40008d30:	c4 00 a0 08 	ld  [ %g2 + 8 ], %g2                           
                                                                      
  if ( evp != NULL ) {                                                
40008d34:	02 80 00 08 	be  40008d54 <timer_create+0xc0>               
40008d38:	c4 22 20 38 	st  %g2, [ %o0 + 0x38 ]                        
    ptimer->inf.sigev_notify = evp->sigev_notify;                     
40008d3c:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40008d40:	c4 22 20 40 	st  %g2, [ %o0 + 0x40 ]                        
    ptimer->inf.sigev_signo  = evp->sigev_signo;                      
40008d44:	c4 06 60 04 	ld  [ %i1 + 4 ], %g2                           
40008d48:	c4 22 20 44 	st  %g2, [ %o0 + 0x44 ]                        
    ptimer->inf.sigev_value  = evp->sigev_value;                      
40008d4c:	c4 06 60 08 	ld  [ %i1 + 8 ], %g2                           
40008d50:	c4 22 20 48 	st  %g2, [ %o0 + 0x48 ]                        
  Objects_Control     *the_object,                                    
  uint32_t             name                                           
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
40008d54:	c0 22 20 0c 	clr  [ %o0 + 0xc ]                             
                                                                      
  _Objects_Set_local_object(                                          
40008d58:	c6 12 20 0a 	lduh  [ %o0 + 0xa ], %g3                       
 * @param[in] information points to an Object Information Table       
 * @param[in] the_object is a pointer to an object                    
 * @param[in] name is the name of the object to make accessible       
 */                                                                   
RTEMS_INLINE_ROUTINE void _Objects_Open_u32(                          
  Objects_Information *information,                                   
40008d5c:	ba 17 63 20 	or  %i5, 0x320, %i5                            
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40008d60:	c8 07 60 1c 	ld  [ %i5 + 0x1c ], %g4                        
  }                                                                   
                                                                      
  ptimer->overrun  = 0;                                               
40008d64:	c0 22 20 68 	clr  [ %o0 + 0x68 ]                            
  ptimer->timer_data.it_value.tv_sec     = 0;                         
40008d68:	c0 22 20 5c 	clr  [ %o0 + 0x5c ]                            
  ptimer->timer_data.it_value.tv_nsec    = 0;                         
40008d6c:	c0 22 20 60 	clr  [ %o0 + 0x60 ]                            
  ptimer->timer_data.it_interval.tv_sec  = 0;                         
40008d70:	c0 22 20 54 	clr  [ %o0 + 0x54 ]                            
  ptimer->timer_data.it_interval.tv_nsec = 0;                         
40008d74:	c0 22 20 58 	clr  [ %o0 + 0x58 ]                            
  Watchdog_Service_routine_entry  routine,                            
  Objects_Id                      id,                                 
  void                           *user_data                           
)                                                                     
{                                                                     
  the_watchdog->state     = WATCHDOG_INACTIVE;                        
40008d78:	c0 22 20 18 	clr  [ %o0 + 0x18 ]                            
  the_watchdog->routine   = routine;                                  
40008d7c:	c0 22 20 2c 	clr  [ %o0 + 0x2c ]                            
  the_watchdog->id        = id;                                       
40008d80:	c0 22 20 30 	clr  [ %o0 + 0x30 ]                            
  the_watchdog->user_data = user_data;                                
40008d84:	c0 22 20 34 	clr  [ %o0 + 0x34 ]                            
)                                                                     
{                                                                     
  /* ASSERT: information->is_string == false */                       
  the_object->name.name_u32 = name;                                   
                                                                      
  _Objects_Set_local_object(                                          
40008d88:	c4 02 20 08 	ld  [ %o0 + 8 ], %g2                           
  #if defined(RTEMS_DEBUG)                                            
    if ( index > information->maximum )                               
      return;                                                         
  #endif                                                              
                                                                      
  information->local_table[ index ] = the_object;                     
40008d8c:	87 28 e0 02 	sll  %g3, 2, %g3                               
40008d90:	d0 21 00 03 	st  %o0, [ %g4 + %g3 ]                         
40008d94:	d0 00 60 d8 	ld  [ %g1 + 0xd8 ], %o0                        
                                                                      
  _Watchdog_Initialize( &ptimer->Timer, NULL, 0, NULL );              
  _Objects_Open_u32(&_POSIX_Timer_Information, &ptimer->Object, 0);   
                                                                      
  *timerid  = ptimer->Object.id;                                      
40008d98:	c4 26 80 00 	st  %g2, [ %i2 ]                               
40008d9c:	40 00 05 b9 	call  4000a480 <_API_Mutex_Unlock>             
40008da0:	b0 10 20 00 	clr  %i0                                       
  _Objects_Allocator_unlock();                                        
  return 0;                                                           
}                                                                     
40008da4:	81 c7 e0 08 	ret                                            
40008da8:	81 e8 00 00 	restore                                        
                                                                      

40007118 <timer_settime>: timer_t timerid, int flags, const struct itimerspec *__restrict value, struct itimerspec *__restrict ovalue ) {
40007118:	9d e3 bf 80 	save  %sp, -128, %sp                           
  Objects_Locations    location;                                      
  bool                 activated;                                     
  uint32_t             initial_period;                                
  struct itimerspec    normalize;                                     
                                                                      
  if ( !value )                                                       
4000711c:	80 a6 a0 00 	cmp  %i2, 0                                    
40007120:	02 80 00 84 	be  40007330 <timer_settime+0x218>             <== NEVER TAKEN
40007124:	a0 10 00 18 	mov  %i0, %l0                                  
                                                                      
  /*                                                                  
   * First, it verifies if the structure "value" is correct           
   * if the number of nanoseconds is not correct return EINVAL        
   */                                                                 
  if ( !_Timespec_Is_valid( &(value->it_value) ) ) {                  
40007128:	40 00 10 3f 	call  4000b224 <_Timespec_Is_valid>            
4000712c:	90 06 a0 08 	add  %i2, 8, %o0                               
40007130:	80 a2 20 00 	cmp  %o0, 0                                    
40007134:	02 80 00 7f 	be  40007330 <timer_settime+0x218>             
40007138:	01 00 00 00 	nop                                            
    rtems_set_errno_and_return_minus_one( EINVAL );                   
  }                                                                   
  if ( !_Timespec_Is_valid( &(value->it_interval) ) ) {               
4000713c:	40 00 10 3a 	call  4000b224 <_Timespec_Is_valid>            
40007140:	90 10 00 1a 	mov  %i2, %o0                                  
40007144:	80 a2 20 00 	cmp  %o0, 0                                    
40007148:	02 80 00 7a 	be  40007330 <timer_settime+0x218>             <== NEVER TAKEN
4000714c:	01 00 00 00 	nop                                            
    rtems_set_errno_and_return_minus_one( EINVAL );                   
  }                                                                   
                                                                      
  if ( flags != TIMER_ABSTIME && flags != POSIX_TIMER_RELATIVE ) {    
40007150:	b0 8e 7f fb 	andcc  %i1, -5, %i0                            
40007154:	12 80 00 77 	bne  40007330 <timer_settime+0x218>            
40007158:	90 07 bf f0 	add  %fp, -16, %o0                             
    rtems_set_errno_and_return_minus_one( EINVAL );                   
  }                                                                   
                                                                      
  normalize = *value;                                                 
4000715c:	92 10 00 1a 	mov  %i2, %o1                                  
40007160:	40 00 26 39 	call  40010a44 <memcpy>                        
40007164:	94 10 20 10 	mov  0x10, %o2                                 
                                                                      
  /* Convert absolute to relative time */                             
  if (flags == TIMER_ABSTIME) {                                       
40007168:	80 a6 60 04 	cmp  %i1, 4                                    
4000716c:	12 80 00 1f 	bne  400071e8 <timer_settime+0xd0>             
40007170:	11 10 00 67 	sethi  %hi(0x40019c00), %o0                    
)                                                                     
{                                                                     
  Timestamp_Control  tod_as_timestamp;                                
  Timestamp_Control *tod_as_timestamp_ptr;                            
                                                                      
  tod_as_timestamp_ptr =                                              
40007174:	90 07 bf e0 	add  %fp, -32, %o0                             
40007178:	13 10 00 67 	sethi  %hi(0x40019c00), %o1                    
4000717c:	40 00 06 41 	call  40008a80 <_TOD_Get_with_nanoseconds>     
40007180:	92 12 61 40 	or  %o1, 0x140, %o1	! 40019d40 <_TOD>          
static inline void _TOD_Get(                                          
  struct timespec *tod_as_timespec                                    
)                                                                     
{                                                                     
  Timestamp_Control  tod_as_timestamp;                                
  Timestamp_Control *tod_as_timestamp_ptr;                            
40007184:	f8 1a 00 00 	ldd  [ %o0 ], %i4                              
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
40007188:	94 10 20 00 	clr  %o2                                       
4000718c:	90 10 00 1c 	mov  %i4, %o0                                  
40007190:	92 10 00 1d 	mov  %i5, %o1                                  
40007194:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40007198:	40 00 36 98 	call  40014bf8 <__divdi3>                      
4000719c:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
400071a0:	94 10 20 00 	clr  %o2                                       
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
400071a4:	d2 27 bf e8 	st  %o1, [ %fp + -24 ]                         
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
400071a8:	90 10 00 1c 	mov  %i4, %o0                                  
400071ac:	92 10 00 1d 	mov  %i5, %o1                                  
400071b0:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
400071b4:	40 00 37 83 	call  40014fc0 <__moddi3>                      
400071b8:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
    struct timespec now;                                              
    _TOD_Get( &now );                                                 
    /* Check for seconds in the past */                               
    if ( _Timespec_Greater_than( &now, &normalize.it_value ) )        
400071bc:	90 07 bf f8 	add  %fp, -8, %o0                              
400071c0:	d2 27 bf ec 	st  %o1, [ %fp + -20 ]                         
400071c4:	40 00 10 2a 	call  4000b26c <_Timespec_Less_than>           
400071c8:	92 07 bf e8 	add  %fp, -24, %o1                             
400071cc:	80 a2 20 00 	cmp  %o0, 0                                    
400071d0:	12 80 00 58 	bne  40007330 <timer_settime+0x218>            
400071d4:	92 07 bf f8 	add  %fp, -8, %o1                              
      rtems_set_errno_and_return_minus_one( EINVAL );                 
    _Timespec_Subtract( &now, &normalize.it_value, &normalize.it_value );
400071d8:	90 07 bf e8 	add  %fp, -24, %o0                             
400071dc:	40 00 10 34 	call  4000b2ac <_Timespec_Subtract>            
400071e0:	94 10 00 09 	mov  %o1, %o2                                  
RTEMS_INLINE_ROUTINE POSIX_Timer_Control *_POSIX_Timer_Get (          
  timer_t            id,                                              
  Objects_Locations *location                                         
)                                                                     
{                                                                     
  return (POSIX_Timer_Control *)                                      
400071e4:	11 10 00 67 	sethi  %hi(0x40019c00), %o0                    
400071e8:	92 10 00 10 	mov  %l0, %o1                                  
400071ec:	90 12 23 e4 	or  %o0, 0x3e4, %o0                            
400071f0:	40 00 09 04 	call  40009600 <_Objects_Get>                  
400071f4:	94 07 bf e0 	add  %fp, -32, %o2                             
   * something with the structure of times of the timer: to stop, start
   * or start it again                                                
   */                                                                 
                                                                      
  ptimer = _POSIX_Timer_Get( timerid, &location );                    
  switch ( location ) {                                               
400071f8:	c2 07 bf e0 	ld  [ %fp + -32 ], %g1                         
400071fc:	80 a0 60 00 	cmp  %g1, 0                                    
40007200:	12 80 00 4c 	bne  40007330 <timer_settime+0x218>            
40007204:	b2 10 00 08 	mov  %o0, %i1                                  
                                                                      
    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 ) {
40007208:	c2 07 bf f8 	ld  [ %fp + -8 ], %g1                          
4000720c:	80 a0 60 00 	cmp  %g1, 0                                    
40007210:	12 80 00 16 	bne  40007268 <timer_settime+0x150>            
40007214:	ba 02 20 10 	add  %o0, 0x10, %i5                            
40007218:	c2 07 bf fc 	ld  [ %fp + -4 ], %g1                          
4000721c:	80 a0 60 00 	cmp  %g1, 0                                    
40007220:	12 80 00 12 	bne  40007268 <timer_settime+0x150>            
40007224:	01 00 00 00 	nop                                            
         /* Stop the timer */                                         
         (void) _Watchdog_Remove( &ptimer->Timer );                   
40007228:	40 00 11 36 	call  4000b700 <_Watchdog_Remove>              
4000722c:	90 10 00 1d 	mov  %i5, %o0                                  
         /* The old data of the timer are returned */                 
         if ( ovalue )                                                
40007230:	80 a6 e0 00 	cmp  %i3, 0                                    
40007234:	02 80 00 06 	be  4000724c <timer_settime+0x134>             
40007238:	ba 06 60 54 	add  %i1, 0x54, %i5                            
           *ovalue = ptimer->timer_data;                              
4000723c:	90 10 00 1b 	mov  %i3, %o0                                  
40007240:	92 10 00 1d 	mov  %i5, %o1                                  
40007244:	40 00 26 00 	call  40010a44 <memcpy>                        
40007248:	94 10 20 10 	mov  0x10, %o2                                 
         /* The new data are set */                                   
         ptimer->timer_data = normalize;                              
4000724c:	90 10 00 1d 	mov  %i5, %o0                                  
40007250:	92 07 bf f0 	add  %fp, -16, %o1                             
40007254:	40 00 25 fc 	call  40010a44 <memcpy>                        
40007258:	94 10 20 10 	mov  0x10, %o2                                 
         /* Indicates that the timer is created and stopped */        
         ptimer->state = POSIX_TIMER_STATE_CREATE_STOP;               
4000725c:	82 10 20 04 	mov  4, %g1                                    
40007260:	10 80 00 30 	b  40007320 <timer_settime+0x208>              
40007264:	c2 2e 60 3c 	stb  %g1, [ %i1 + 0x3c ]                       
        _Objects_Put( &ptimer->Object );                              
        return 0;                                                     
       }                                                              
                                                                      
       /* Convert from seconds and nanoseconds to ticks */            
       ptimer->ticks  = _Timespec_To_ticks( &value->it_interval );    
40007268:	40 00 10 22 	call  4000b2f0 <_Timespec_To_ticks>            
4000726c:	90 10 00 1a 	mov  %i2, %o0                                  
40007270:	d0 26 60 64 	st  %o0, [ %i1 + 0x64 ]                        
       initial_period = _Timespec_To_ticks( &normalize.it_value );    
40007274:	40 00 10 1f 	call  4000b2f0 <_Timespec_To_ticks>            
40007278:	90 07 bf f8 	add  %fp, -8, %o0                              
                                                                      
                                                                      
       activated = _POSIX_Timer_Insert_helper(                        
4000727c:	d4 06 60 08 	ld  [ %i1 + 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 );    
40007280:	92 10 00 08 	mov  %o0, %o1                                  
                                                                      
                                                                      
       activated = _POSIX_Timer_Insert_helper(                        
40007284:	17 10 00 1c 	sethi  %hi(0x40007000), %o3                    
40007288:	90 10 00 1d 	mov  %i5, %o0                                  
4000728c:	96 12 e3 48 	or  %o3, 0x348, %o3                            
40007290:	40 00 18 db 	call  4000d5fc <_POSIX_Timer_Insert_helper>    
40007294:	98 10 00 19 	mov  %i1, %o4                                  
         initial_period,                                              
         ptimer->Object.id,                                           
         _POSIX_Timer_TSR,                                            
         ptimer                                                       
       );                                                             
       if ( !activated ) {                                            
40007298:	80 a2 20 00 	cmp  %o0, 0                                    
4000729c:	02 80 00 21 	be  40007320 <timer_settime+0x208>             
400072a0:	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 )                                                  
400072a4:	02 80 00 06 	be  400072bc <timer_settime+0x1a4>             
400072a8:	ba 06 60 54 	add  %i1, 0x54, %i5                            
         *ovalue = ptimer->timer_data;                                
400072ac:	90 10 00 1b 	mov  %i3, %o0                                  
400072b0:	92 10 00 1d 	mov  %i5, %o1                                  
400072b4:	40 00 25 e4 	call  40010a44 <memcpy>                        
400072b8:	94 10 20 10 	mov  0x10, %o2                                 
       ptimer->timer_data = normalize;                                
400072bc:	94 10 20 10 	mov  0x10, %o2                                 
400072c0:	90 10 00 1d 	mov  %i5, %o0                                  
400072c4:	40 00 25 e0 	call  40010a44 <memcpy>                        
400072c8:	92 07 bf f0 	add  %fp, -16, %o1                             
                                                                      
       /* Indicate that the time is running */                        
       ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;                  
400072cc:	82 10 20 03 	mov  3, %g1                                    
                                                                      
  tod_as_timestamp_ptr =                                              
400072d0:	90 07 bf e8 	add  %fp, -24, %o0                             
400072d4:	c2 2e 60 3c 	stb  %g1, [ %i1 + 0x3c ]                       
400072d8:	13 10 00 67 	sethi  %hi(0x40019c00), %o1                    
400072dc:	40 00 05 e9 	call  40008a80 <_TOD_Get_with_nanoseconds>     
400072e0:	92 12 61 40 	or  %o1, 0x140, %o1	! 40019d40 <_TOD>          
static inline void _TOD_Get(                                          
  struct timespec *tod_as_timespec                                    
)                                                                     
{                                                                     
  Timestamp_Control  tod_as_timestamp;                                
  Timestamp_Control *tod_as_timestamp_ptr;                            
400072e4:	f8 1a 00 00 	ldd  [ %o0 ], %i4                              
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
400072e8:	94 10 20 00 	clr  %o2                                       
400072ec:	90 10 00 1c 	mov  %i4, %o0                                  
400072f0:	92 10 00 1d 	mov  %i5, %o1                                  
400072f4:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
400072f8:	40 00 36 40 	call  40014bf8 <__divdi3>                      
400072fc:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
40007300:	90 10 00 1c 	mov  %i4, %o0                                  
static inline void _Timestamp64_implementation_To_timespec(           
  const Timestamp64_Control *_timestamp,                              
  struct timespec           *_timespec                                
)                                                                     
{                                                                     
  _timespec->tv_sec = (time_t) (*_timestamp / 1000000000L);           
40007304:	d2 26 60 6c 	st  %o1, [ %i1 + 0x6c ]                        
  _timespec->tv_nsec = (long) (*_timestamp % 1000000000L);            
40007308:	94 10 20 00 	clr  %o2                                       
4000730c:	92 10 00 1d 	mov  %i5, %o1                                  
40007310:	17 0e e6 b2 	sethi  %hi(0x3b9ac800), %o3                    
40007314:	40 00 37 2b 	call  40014fc0 <__moddi3>                      
40007318:	96 12 e2 00 	or  %o3, 0x200, %o3	! 3b9aca00 <RAM_SIZE+0x3b5aca00>
4000731c:	d2 26 60 70 	st  %o1, [ %i1 + 0x70 ]                        
RTEMS_INLINE_ROUTINE void _Objects_Put(                               
  Objects_Control *the_object                                         
)                                                                     
{                                                                     
  (void) the_object;                                                  
  _Thread_Enable_dispatch();                                          
40007320:	40 00 0c 09 	call  4000a344 <_Thread_Enable_dispatch>       
40007324:	01 00 00 00 	nop                                            
       _TOD_Get( &ptimer->time );                                     
      _Objects_Put( &ptimer->Object );                                
       return 0;                                                      
40007328:	81 c7 e0 08 	ret                                            
4000732c:	81 e8 00 00 	restore                                        
#endif                                                                
    case OBJECTS_ERROR:                                               
      break;                                                          
  }                                                                   
                                                                      
  rtems_set_errno_and_return_minus_one( EINVAL );                     
40007330:	40 00 23 df 	call  400102ac <__errno>                       
40007334:	b0 10 3f ff 	mov  -1, %i0                                   
40007338:	82 10 20 16 	mov  0x16, %g1                                 
4000733c:	c2 22 00 00 	st  %g1, [ %o0 ]                               
}                                                                     
40007340:	81 c7 e0 08 	ret                                            
40007344:	81 e8 00 00 	restore                                        
                                                                      

40006e14 <unmount>: * in some form is supported on most UNIX and POSIX systems. This * routine is necessary to mount instantiations of a file system * into the file system name space. */ int unmount( const char *path ) {
40006e14:	9d e3 bf 60 	save  %sp, -160, %sp                           
  int rv = 0;                                                         
  rtems_filesystem_eval_path_context_t ctx;                           
  int eval_flags = RTEMS_FS_FOLLOW_LINK;                              
  const rtems_filesystem_location_info_t *currentloc =                
40006e18:	94 10 20 18 	mov  0x18, %o2                                 
40006e1c:	92 10 00 18 	mov  %i0, %o1                                  
40006e20:	7f ff f7 59 	call  40004b84 <rtems_filesystem_eval_path_start>
40006e24:	90 07 bf c8 	add  %fp, -56, %o0                             
    rtems_filesystem_eval_path_start( &ctx, path, eval_flags );       
  rtems_filesystem_mount_table_entry_t *mt_entry = currentloc->mt_entry;
40006e28:	fa 02 20 14 	ld  [ %o0 + 0x14 ], %i5                        
  const rtems_filesystem_location_info_t *loc                         
)                                                                     
{                                                                     
  const rtems_filesystem_mount_table_entry_t *mt_entry = loc->mt_entry;
                                                                      
  return (*mt_entry->ops->are_nodes_equal_h)(                         
40006e2c:	c2 07 60 0c 	ld  [ %i5 + 0xc ], %g1                         
40006e30:	c2 00 60 10 	ld  [ %g1 + 0x10 ], %g1                        
40006e34:	9f c0 40 00 	call  %g1                                      
40006e38:	d2 07 60 24 	ld  [ %i5 + 0x24 ], %o1                        
                                                                      
  if ( rtems_filesystem_location_is_instance_root( currentloc ) ) {   
40006e3c:	80 a2 20 00 	cmp  %o0, 0                                    
40006e40:	02 80 00 29 	be  40006ee4 <unmount+0xd0>                    
40006e44:	01 00 00 00 	nop                                            
static bool contains_root_or_current_directory(                       
  const rtems_filesystem_mount_table_entry_t *mt_entry                
)                                                                     
{                                                                     
  const rtems_filesystem_location_info_t *root =                      
    &rtems_filesystem_root->location;                                 
40006e48:	7f ff f5 c2 	call  40004550 <rtems_current_user_env_get>    
40006e4c:	01 00 00 00 	nop                                            
  const rtems_filesystem_location_info_t *current =                   
    &rtems_filesystem_current->location;                              
40006e50:	7f ff f5 c0 	call  40004550 <rtems_current_user_env_get>    
40006e54:	f8 02 20 04 	ld  [ %o0 + 4 ], %i4                           
                                                                      
  return mt_entry == root->mt_entry || mt_entry == current->mt_entry; 
40006e58:	c4 07 20 14 	ld  [ %i4 + 0x14 ], %g2                        
40006e5c:	80 a7 40 02 	cmp  %i5, %g2                                  
40006e60:	02 80 00 07 	be  40006e7c <unmount+0x68>                    
40006e64:	c2 02 00 00 	ld  [ %o0 ], %g1                               
40006e68:	c2 00 60 14 	ld  [ %g1 + 0x14 ], %g1                        
40006e6c:	82 1f 40 01 	xor  %i5, %g1, %g1                             
40006e70:	80 a0 00 01 	cmp  %g0, %g1                                  
40006e74:	10 80 00 03 	b  40006e80 <unmount+0x6c>                     
40006e78:	82 60 3f ff 	subx  %g0, -1, %g1                             
40006e7c:	82 10 20 01 	mov  1, %g1                                    
  const rtems_filesystem_location_info_t *currentloc =                
    rtems_filesystem_eval_path_start( &ctx, path, eval_flags );       
  rtems_filesystem_mount_table_entry_t *mt_entry = currentloc->mt_entry;
                                                                      
  if ( rtems_filesystem_location_is_instance_root( currentloc ) ) {   
    if ( !contains_root_or_current_directory( mt_entry ) ) {          
40006e80:	80 a0 60 00 	cmp  %g1, 0                                    
40006e84:	12 80 00 14 	bne  40006ed4 <unmount+0xc0>                   
40006e88:	01 00 00 00 	nop                                            
      const rtems_filesystem_operations_table *mt_point_ops =         
        mt_entry->mt_point_node->location.mt_entry->ops;              
40006e8c:	c2 07 60 20 	ld  [ %i5 + 0x20 ], %g1                        
    rtems_filesystem_eval_path_start( &ctx, path, eval_flags );       
  rtems_filesystem_mount_table_entry_t *mt_entry = currentloc->mt_entry;
                                                                      
  if ( rtems_filesystem_location_is_instance_root( currentloc ) ) {   
    if ( !contains_root_or_current_directory( mt_entry ) ) {          
      const rtems_filesystem_operations_table *mt_point_ops =         
40006e90:	c2 00 60 14 	ld  [ %g1 + 0x14 ], %g1                        
        mt_entry->mt_point_node->location.mt_entry->ops;              
                                                                      
      rv = (*mt_point_ops->unmount_h)( mt_entry );                    
40006e94:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
40006e98:	c2 00 60 38 	ld  [ %g1 + 0x38 ], %g1                        
40006e9c:	9f c0 40 00 	call  %g1                                      
40006ea0:	90 10 00 1d 	mov  %i5, %o0                                  
      if ( rv == 0 ) {                                                
40006ea4:	b0 92 20 00 	orcc  %o0, 0, %i0                              
40006ea8:	12 80 00 14 	bne  40006ef8 <unmount+0xe4>                   
40006eac:	01 00 00 00 	nop                                            
        rtems_id self_task_id = rtems_task_self();                    
40006eb0:	40 00 04 8d 	call  400080e4 <rtems_task_self>               
40006eb4:	01 00 00 00 	nop                                            
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_ISR_disable_and_acquire( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Disable( context->isr_level );                                 
40006eb8:	7f ff ed 3f 	call  400023b4 <sparc_disable_interrupts>      
40006ebc:	b8 10 00 08 	mov  %o0, %i4                                  
        rtems_filesystem_mt_entry_declare_lock_context( lock_context );
                                                                      
        rtems_filesystem_mt_entry_lock( lock_context );               
        mt_entry->unmount_task = self_task_id;                        
40006ec0:	f8 27 60 3c 	st  %i4, [ %i5 + 0x3c ]                        
        mt_entry->mounted = false;                                    
40006ec4:	c0 2f 60 28 	clrb  [ %i5 + 0x28 ]                           
{                                                                     
#if defined( RTEMS_SMP )                                              
  _SMP_lock_Release_and_ISR_enable( &lock->lock, &context->lock_context );
#else                                                                 
  (void) lock;                                                        
  _ISR_Enable( context->isr_level );                                  
40006ec8:	7f ff ed 3e 	call  400023c0 <sparc_enable_interrupts>       
40006ecc:	01 00 00 00 	nop                                            
40006ed0:	30 80 00 0a 	b,a   40006ef8 <unmount+0xe4>                  
        rtems_filesystem_mt_entry_unlock( lock_context );             
      }                                                               
    } else {                                                          
      errno = EBUSY;                                                  
40006ed4:	40 00 24 43 	call  4000ffe0 <__errno>                       
40006ed8:	01 00 00 00 	nop                                            
40006edc:	10 80 00 05 	b  40006ef0 <unmount+0xdc>                     
40006ee0:	82 10 20 10 	mov  0x10, %g1	! 10 <_TLS_Alignment+0xf>       
      rv = -1;                                                        
    }                                                                 
  } else {                                                            
    errno = EACCES;                                                   
40006ee4:	40 00 24 3f 	call  4000ffe0 <__errno>                       
40006ee8:	01 00 00 00 	nop                                            
40006eec:	82 10 20 0d 	mov  0xd, %g1	! d <_TLS_Alignment+0xc>         
40006ef0:	c2 22 00 00 	st  %g1, [ %o0 ]                               
    rv = -1;                                                          
40006ef4:	b0 10 3f ff 	mov  -1, %i0                                   
  }                                                                   
                                                                      
  rtems_filesystem_eval_path_cleanup( &ctx );                         
40006ef8:	7f ff f7 2b 	call  40004ba4 <rtems_filesystem_eval_path_cleanup>
40006efc:	90 07 bf c8 	add  %fp, -56, %o0                             
                                                                      
  if ( rv == 0 ) {                                                    
40006f00:	80 a6 20 00 	cmp  %i0, 0                                    
40006f04:	12 80 00 0b 	bne  40006f30 <unmount+0x11c>                  
40006f08:	11 20 00 00 	sethi  %hi(0x80000000), %o0                    
  rtems_interval ticks                                                
)                                                                     
{                                                                     
  rtems_event_set event_out;                                          
                                                                      
  return rtems_event_system_receive(                                  
40006f0c:	92 10 20 00 	clr  %o1                                       
40006f10:	94 10 20 00 	clr  %o2                                       
40006f14:	40 00 03 b6 	call  40007dec <rtems_event_system_receive>    
40006f18:	96 07 bf c4 	add  %fp, -60, %o3                             
    rtems_status_code sc = rtems_event_transient_receive(             
      RTEMS_WAIT,                                                     
      RTEMS_NO_TIMEOUT                                                
    );                                                                
                                                                      
    if ( sc != RTEMS_SUCCESSFUL ) {                                   
40006f1c:	80 a2 20 00 	cmp  %o0, 0                                    
40006f20:	02 80 00 04 	be  40006f30 <unmount+0x11c>                   <== ALWAYS TAKEN
40006f24:	11 37 ab 6f 	sethi  %hi(0xdeadbc00), %o0                    
      rtems_fatal_error_occurred( 0xdeadbeef );                       
40006f28:	40 00 05 11 	call  4000836c <rtems_fatal_error_occurred>    <== NOT EXECUTED
40006f2c:	90 12 22 ef 	or  %o0, 0x2ef, %o0	! deadbeef <RAM_END+0x9e6dbeef><== NOT EXECUTED
    }                                                                 
  }                                                                   
                                                                      
  return rv;                                                          
}                                                                     
40006f30:	81 c7 e0 08 	ret                                            
40006f34:	81 e8 00 00 	restore                                        
                                                                      

40006a2c <vprintk>: */ void vprintk( const char *fmt, va_list ap ) {
40006a2c:	9d e3 bf 78 	save  %sp, -136, %sp                           
      char *s, *str;                                                  
                                                                      
      str = va_arg(ap, char *);                                       
                                                                      
      if ( str == NULL ) {                                            
        str = "";                                                     
40006a30:	2b 10 00 57 	sethi  %hi(0x40015c00), %l5                    
40006a34:	a4 07 bf e8 	add  %fp, -24, %l2                             
void vprintk(                                                         
  const char *fmt,                                                    
  va_list     ap                                                      
)                                                                     
{                                                                     
  for (; *fmt != '\0'; fmt++) {                                       
40006a38:	d0 4e 00 00 	ldsb  [ %i0 ], %o0                             
40006a3c:	80 a2 20 00 	cmp  %o0, 0                                    
40006a40:	02 80 01 09 	be  40006e64 <vprintk+0x438>                   
40006a44:	80 a2 20 25 	cmp  %o0, 0x25                                 
    bool sign = false;                                                
    char lead = ' ';                                                  
    char c = *fmt;                                                    
    long long num;                                                    
                                                                      
    if (c != '%') {                                                   
40006a48:	12 80 00 3c 	bne  40006b38 <vprintk+0x10c>                  
40006a4c:	01 00 00 00 	nop                                            
      continue;                                                       
    }                                                                 
                                                                      
    ++fmt; c = *fmt;                                                  
                                                                      
    if (c == '0') {                                                   
40006a50:	c4 4e 20 01 	ldsb  [ %i0 + 1 ], %g2                         
40006a54:	80 a0 a0 30 	cmp  %g2, 0x30                                 
40006a58:	02 80 00 05 	be  40006a6c <vprintk+0x40>                    
40006a5c:	c2 0e 20 01 	ldub  [ %i0 + 1 ], %g1                         
    if (c != '%') {                                                   
      rtems_putc(c);                                                  
      continue;                                                       
    }                                                                 
                                                                      
    ++fmt; c = *fmt;                                                  
40006a60:	b0 06 20 01 	inc  %i0                                       
      LFLAG_LONG,                                                     
      LFLAG_LONG_LONG                                                 
    } lflag = LFLAG_INT;                                              
    bool minus = false;                                               
    bool sign = false;                                                
    char lead = ' ';                                                  
40006a64:	10 80 00 05 	b  40006a78 <vprintk+0x4c>                     
40006a68:	a6 10 20 20 	mov  0x20, %l3                                 
                                                                      
    ++fmt; c = *fmt;                                                  
                                                                      
    if (c == '0') {                                                   
      lead = '0';                                                     
      ++fmt; c = *fmt;                                                
40006a6c:	c2 0e 20 02 	ldub  [ %i0 + 2 ], %g1                         
    }                                                                 
                                                                      
    ++fmt; c = *fmt;                                                  
                                                                      
    if (c == '0') {                                                   
      lead = '0';                                                     
40006a70:	a6 10 20 30 	mov  0x30, %l3                                 
      ++fmt; c = *fmt;                                                
40006a74:	b0 06 20 02 	add  %i0, 2, %i0                               
    }                                                                 
                                                                      
    if (c == '-') {                                                   
40006a78:	85 28 60 18 	sll  %g1, 0x18, %g2                            
40006a7c:	85 38 a0 18 	sra  %g2, 0x18, %g2                            
40006a80:	80 a0 a0 2d 	cmp  %g2, 0x2d                                 
40006a84:	12 80 00 05 	bne  40006a98 <vprintk+0x6c>                   
40006a88:	86 10 20 00 	clr  %g3                                       
      minus = true;                                                   
      ++fmt; c = *fmt;                                                
40006a8c:	c2 0e 20 01 	ldub  [ %i0 + 1 ], %g1                         
      lead = '0';                                                     
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    if (c == '-') {                                                   
      minus = true;                                                   
40006a90:	86 10 20 01 	mov  1, %g3                                    
      ++fmt; c = *fmt;                                                
40006a94:	b0 06 20 01 	inc  %i0                                       
    enum {                                                            
      LFLAG_INT,                                                      
      LFLAG_LONG,                                                     
      LFLAG_LONG_LONG                                                 
    } lflag = LFLAG_INT;                                              
    bool minus = false;                                               
40006a98:	a2 10 20 00 	clr  %l1                                       
    if (c == '-') {                                                   
      minus = true;                                                   
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    while (c >= '0' && c <= '9' ) {                                   
40006a9c:	84 00 7f d0 	add  %g1, -48, %g2                             
40006aa0:	84 08 a0 ff 	and  %g2, 0xff, %g2                            
40006aa4:	80 a0 a0 09 	cmp  %g2, 9                                    
40006aa8:	18 80 00 0b 	bgu  40006ad4 <vprintk+0xa8>                   
40006aac:	85 28 60 18 	sll  %g1, 0x18, %g2                            
      width *= 10;                                                    
40006ab0:	83 2c 60 01 	sll  %l1, 1, %g1                               
      width += ((unsigned) c - '0');                                  
40006ab4:	85 38 a0 18 	sra  %g2, 0x18, %g2                            
      minus = true;                                                   
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    while (c >= '0' && c <= '9' ) {                                   
      width *= 10;                                                    
40006ab8:	a3 2c 60 03 	sll  %l1, 3, %l1                               
      width += ((unsigned) c - '0');                                  
      ++fmt; c = *fmt;                                                
40006abc:	b0 06 20 01 	inc  %i0                                       
      minus = true;                                                   
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    while (c >= '0' && c <= '9' ) {                                   
      width *= 10;                                                    
40006ac0:	a2 00 40 11 	add  %g1, %l1, %l1                             
      width += ((unsigned) c - '0');                                  
      ++fmt; c = *fmt;                                                
40006ac4:	c2 0e 00 00 	ldub  [ %i0 ], %g1                             
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    while (c >= '0' && c <= '9' ) {                                   
      width *= 10;                                                    
      width += ((unsigned) c - '0');                                  
40006ac8:	a2 04 40 02 	add  %l1, %g2, %l1                             
40006acc:	10 bf ff f4 	b  40006a9c <vprintk+0x70>                     
40006ad0:	a2 04 7f d0 	add  %l1, -48, %l1                             
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    if (c == 'l') {                                                   
40006ad4:	b7 38 a0 18 	sra  %g2, 0x18, %i3                            
40006ad8:	a0 10 00 11 	mov  %l1, %l0                                  
40006adc:	88 10 00 18 	mov  %i0, %g4                                  
40006ae0:	80 a6 e0 6c 	cmp  %i3, 0x6c                                 
40006ae4:	12 80 00 0c 	bne  40006b14 <vprintk+0xe8>                   
40006ae8:	84 10 20 00 	clr  %g2                                       
      lflag = LFLAG_LONG;                                             
      ++fmt; c = *fmt;                                                
                                                                      
      if (c == 'l') {                                                 
40006aec:	c4 4e 20 01 	ldsb  [ %i0 + 1 ], %g2                         
40006af0:	80 a0 a0 6c 	cmp  %g2, 0x6c                                 
40006af4:	02 80 00 05 	be  40006b08 <vprintk+0xdc>                    
40006af8:	c2 0e 20 01 	ldub  [ %i0 + 1 ], %g1                         
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    if (c == 'l') {                                                   
      lflag = LFLAG_LONG;                                             
      ++fmt; c = *fmt;                                                
40006afc:	b0 06 20 01 	inc  %i0                                       
      width += ((unsigned) c - '0');                                  
      ++fmt; c = *fmt;                                                
    }                                                                 
                                                                      
    if (c == 'l') {                                                   
      lflag = LFLAG_LONG;                                             
40006b00:	10 80 00 05 	b  40006b14 <vprintk+0xe8>                     
40006b04:	84 10 20 01 	mov  1, %g2                                    
      ++fmt; c = *fmt;                                                
                                                                      
      if (c == 'l') {                                                 
        lflag = LFLAG_LONG_LONG;                                      
        ++fmt; c = *fmt;                                              
40006b08:	c2 09 20 02 	ldub  [ %g4 + 2 ], %g1                         
40006b0c:	b0 06 20 02 	add  %i0, 2, %i0                               
    if (c == 'l') {                                                   
      lflag = LFLAG_LONG;                                             
      ++fmt; c = *fmt;                                                
                                                                      
      if (c == 'l') {                                                 
        lflag = LFLAG_LONG_LONG;                                      
40006b10:	84 10 20 02 	mov  2, %g2                                    
        ++fmt; c = *fmt;                                              
      }                                                               
    }                                                                 
                                                                      
    if ( c == 'c' ) {                                                 
40006b14:	91 28 60 18 	sll  %g1, 0x18, %o0                            
40006b18:	91 3a 20 18 	sra  %o0, 0x18, %o0                            
40006b1c:	80 a2 20 63 	cmp  %o0, 0x63                                 
40006b20:	12 80 00 0a 	bne  40006b48 <vprintk+0x11c>                  
40006b24:	80 a2 20 73 	cmp  %o0, 0x73                                 
      /* need a cast here since va_arg() only takes fully promoted types */
      char chr = (char) va_arg(ap, int);                              
40006b28:	d0 06 40 00 	ld  [ %i1 ], %o0                               
40006b2c:	b2 06 60 04 	add  %i1, 4, %i1                               
      rtems_putc(chr);                                                
40006b30:	91 2a 20 18 	sll  %o0, 0x18, %o0                            
40006b34:	91 3a 20 18 	sra  %o0, 0x18, %o0                            
40006b38:	40 00 16 1b 	call  4000c3a4 <rtems_putc>                    
40006b3c:	b0 06 20 01 	inc  %i0                                       
      continue;                                                       
40006b40:	10 bf ff bf 	b  40006a3c <vprintk+0x10>                     
40006b44:	d0 4e 00 00 	ldsb  [ %i0 ], %o0                             
    }                                                                 
                                                                      
    if ( c == 's' ) {                                                 
40006b48:	12 80 00 31 	bne  40006c0c <vprintk+0x1e0>                  
40006b4c:	82 08 7f df 	and  %g1, -33, %g1                             
      unsigned i, len;                                                
      char *s, *str;                                                  
                                                                      
      str = va_arg(ap, char *);                                       
40006b50:	f4 06 40 00 	ld  [ %i1 ], %i2                               
                                                                      
      if ( str == NULL ) {                                            
40006b54:	80 a6 a0 00 	cmp  %i2, 0                                    
40006b58:	12 80 00 03 	bne  40006b64 <vprintk+0x138>                  
40006b5c:	b2 06 60 04 	add  %i1, 4, %i1                               
        str = "";                                                     
40006b60:	b4 15 60 48 	or  %l5, 0x48, %i2                             
      }                                                               
                                                                      
      /* calculate length of string */                                
      for ( len=0, s=str ; *s ; len++, s++ )                          
40006b64:	b6 10 20 00 	clr  %i3                                       
40006b68:	c2 4e 80 1b 	ldsb  [ %i2 + %i3 ], %g1                       
40006b6c:	80 a0 60 00 	cmp  %g1, 0                                    
40006b70:	22 80 00 04 	be,a   40006b80 <vprintk+0x154>                
40006b74:	a6 88 e0 ff 	andcc  %g3, 0xff, %l3                          
40006b78:	10 bf ff fc 	b  40006b68 <vprintk+0x13c>                    
40006b7c:	b6 06 e0 01 	inc  %i3                                       
        ;                                                             
                                                                      
      /* leading spaces */                                            
      if ( !minus )                                                   
40006b80:	02 80 00 07 	be  40006b9c <vprintk+0x170>                   
40006b84:	a0 10 00 1b 	mov  %i3, %l0                                  
        for ( i=len ; i<width ; i++ )                                 
          rtems_putc(' ');                                            
                                                                      
      /* no width option */                                           
      if (width == 0) {                                               
40006b88:	80 a4 60 00 	cmp  %l1, 0                                    
40006b8c:	22 80 00 0b 	be,a   40006bb8 <vprintk+0x18c>                
40006b90:	a2 96 e0 00 	orcc  %i3, 0, %l1                              
          width = len;                                                
      }                                                               
                                                                      
      /* output the string */                                         
      for ( i=0 ; i<width && *str ; str++ )                           
40006b94:	10 80 00 10 	b  40006bd4 <vprintk+0x1a8>                    
40006b98:	d0 4e 80 00 	ldsb  [ %i2 ], %o0                             
      for ( len=0, s=str ; *s ; len++, s++ )                          
        ;                                                             
                                                                      
      /* leading spaces */                                            
      if ( !minus )                                                   
        for ( i=len ; i<width ; i++ )                                 
40006b9c:	80 a4 00 11 	cmp  %l0, %l1                                  
40006ba0:	1a bf ff fa 	bcc  40006b88 <vprintk+0x15c>                  
40006ba4:	90 10 20 20 	mov  0x20, %o0                                 
          rtems_putc(' ');                                            
40006ba8:	40 00 15 ff 	call  4000c3a4 <rtems_putc>                    
40006bac:	a0 04 20 01 	inc  %l0                                       
      for ( len=0, s=str ; *s ; len++, s++ )                          
        ;                                                             
                                                                      
      /* leading spaces */                                            
      if ( !minus )                                                   
        for ( i=len ; i<width ; i++ )                                 
40006bb0:	10 bf ff fc 	b  40006ba0 <vprintk+0x174>                    
40006bb4:	80 a4 00 11 	cmp  %l0, %l1                                  
      if (width == 0) {                                               
          width = len;                                                
      }                                                               
                                                                      
      /* output the string */                                         
      for ( i=0 ; i<width && *str ; str++ )                           
40006bb8:	32 80 00 07 	bne,a   40006bd4 <vprintk+0x1a8>               
40006bbc:	d0 4e 80 00 	ldsb  [ %i2 ], %o0                             
        rtems_putc(*str);                                             
                                                                      
      /* trailing spaces */                                           
      if ( minus )                                                    
40006bc0:	80 a4 e0 00 	cmp  %l3, 0                                    
40006bc4:	12 80 00 0b 	bne  40006bf0 <vprintk+0x1c4>                  
40006bc8:	80 a6 c0 11 	cmp  %i3, %l1                                  
void vprintk(                                                         
  const char *fmt,                                                    
  va_list     ap                                                      
)                                                                     
{                                                                     
  for (; *fmt != '\0'; fmt++) {                                       
40006bcc:	10 bf ff 9b 	b  40006a38 <vprintk+0xc>                      
40006bd0:	b0 06 20 01 	inc  %i0                                       
      if (width == 0) {                                               
          width = len;                                                
      }                                                               
                                                                      
      /* output the string */                                         
      for ( i=0 ; i<width && *str ; str++ )                           
40006bd4:	80 a2 20 00 	cmp  %o0, 0                                    
40006bd8:	02 bf ff fb 	be  40006bc4 <vprintk+0x198>                   
40006bdc:	80 a4 e0 00 	cmp  %l3, 0                                    
        rtems_putc(*str);                                             
40006be0:	40 00 15 f1 	call  4000c3a4 <rtems_putc>                    
40006be4:	b4 06 a0 01 	inc  %i2                                       
      if (width == 0) {                                               
          width = len;                                                
      }                                                               
                                                                      
      /* output the string */                                         
      for ( i=0 ; i<width && *str ; str++ )                           
40006be8:	10 bf ff fb 	b  40006bd4 <vprintk+0x1a8>                    
40006bec:	d0 4e 80 00 	ldsb  [ %i2 ], %o0                             
        rtems_putc(*str);                                             
                                                                      
      /* trailing spaces */                                           
      if ( minus )                                                    
        for ( i=len ; i<width ; i++ )                                 
40006bf0:	3a 80 00 9b 	bcc,a   40006e5c <vprintk+0x430>               
40006bf4:	b0 06 20 01 	inc  %i0                                       
          rtems_putc(' ');                                            
40006bf8:	90 10 20 20 	mov  0x20, %o0                                 
40006bfc:	40 00 15 ea 	call  4000c3a4 <rtems_putc>                    
40006c00:	b6 06 e0 01 	inc  %i3                                       
      for ( i=0 ; i<width && *str ; str++ )                           
        rtems_putc(*str);                                             
                                                                      
      /* trailing spaces */                                           
      if ( minus )                                                    
        for ( i=len ; i<width ; i++ )                                 
40006c04:	10 bf ff fb 	b  40006bf0 <vprintk+0x1c4>                    
40006c08:	80 a6 c0 11 	cmp  %i3, %l1                                  
                                                                      
      continue;                                                       
    }                                                                 
                                                                      
    /* must be a numeric format or something unsupported */           
    if ( c == 'o' || c == 'O' ) {                                     
40006c0c:	83 28 60 18 	sll  %g1, 0x18, %g1                            
40006c10:	83 38 60 18 	sra  %g1, 0x18, %g1                            
40006c14:	80 a0 60 4f 	cmp  %g1, 0x4f                                 
40006c18:	02 80 00 12 	be  40006c60 <vprintk+0x234>                   
40006c1c:	b6 10 20 00 	clr  %i3                                       
      base = 8; sign = false;                                         
    } else if ( c == 'i' || c == 'I' ||                               
40006c20:	80 a0 60 49 	cmp  %g1, 0x49                                 
40006c24:	02 80 00 11 	be  40006c68 <vprintk+0x23c>                   
40006c28:	b6 10 20 01 	mov  1, %i3                                    
                c == 'd' || c == 'D' ) {                              
40006c2c:	80 a0 60 44 	cmp  %g1, 0x44                                 
40006c30:	02 80 00 0e 	be  40006c68 <vprintk+0x23c>                   
40006c34:	80 a0 60 55 	cmp  %g1, 0x55                                 
      base = 10; sign = true;                                         
    } else if ( c == 'u' || c == 'U' ) {                              
40006c38:	22 80 00 0c 	be,a   40006c68 <vprintk+0x23c>                
40006c3c:	b6 10 20 00 	clr  %i3                                       
      base = 10; sign = false;                                        
    } else if ( c == 'x' || c == 'X' ) {                              
40006c40:	80 a0 60 58 	cmp  %g1, 0x58                                 
40006c44:	22 80 00 0b 	be,a   40006c70 <vprintk+0x244>                
40006c48:	b6 10 20 00 	clr  %i3                                       
      base = 16; sign = false;                                        
    } else if ( c == 'p' ) {                                          
40006c4c:	80 a2 20 70 	cmp  %o0, 0x70                                 
40006c50:	12 bf ff ba 	bne  40006b38 <vprintk+0x10c>                  
40006c54:	ac 10 20 10 	mov  0x10, %l6                                 
        num = sign ? (long long) va_arg(ap, int)                      
          : (long long) va_arg(ap, unsigned int);                     
        break;                                                        
      case LFLAG_LONG:                                                
        num = sign ? (long long) va_arg(ap, long)                     
          : (long long) va_arg(ap, unsigned long);                    
40006c58:	10 80 00 20 	b  40006cd8 <vprintk+0x2ac>                    
40006c5c:	f8 06 40 00 	ld  [ %i1 ], %i4                               
      continue;                                                       
    }                                                                 
                                                                      
    /* must be a numeric format or something unsupported */           
    if ( c == 'o' || c == 'O' ) {                                     
      base = 8; sign = false;                                         
40006c60:	10 80 00 05 	b  40006c74 <vprintk+0x248>                    
40006c64:	ac 10 20 08 	mov  8, %l6                                    
    } else if ( c == 'i' || c == 'I' ||                               
                c == 'd' || c == 'D' ) {                              
      base = 10; sign = true;                                         
    } else if ( c == 'u' || c == 'U' ) {                              
      base = 10; sign = false;                                        
40006c68:	10 80 00 03 	b  40006c74 <vprintk+0x248>                    
40006c6c:	ac 10 20 0a 	mov  0xa, %l6                                  
    } else if ( c == 'x' || c == 'X' ) {                              
      base = 16; sign = false;                                        
40006c70:	ac 10 20 10 	mov  0x10, %l6                                 
    } else {                                                          
      rtems_putc(c);                                                  
      continue;                                                       
    }                                                                 
                                                                      
    switch (lflag) {                                                  
40006c74:	80 a0 a0 01 	cmp  %g2, 1                                    
40006c78:	02 80 00 10 	be  40006cb8 <vprintk+0x28c>                   
40006c7c:	80 a0 a0 02 	cmp  %g2, 2                                    
40006c80:	02 80 00 1b 	be  40006cec <vprintk+0x2c0>                   
40006c84:	92 10 00 19 	mov  %i1, %o1                                  
      case LFLAG_INT:                                                 
        num = sign ? (long long) va_arg(ap, int)                      
          : (long long) va_arg(ap, unsigned int);                     
40006c88:	80 8e e0 ff 	btst  0xff, %i3                                
40006c8c:	02 80 00 06 	be  40006ca4 <vprintk+0x278>                   
40006c90:	82 06 60 04 	add  %i1, 4, %g1                               
40006c94:	c4 06 40 00 	ld  [ %i1 ], %g2                               
40006c98:	ba 10 00 02 	mov  %g2, %i5                                  
40006c9c:	10 80 00 05 	b  40006cb0 <vprintk+0x284>                    
40006ca0:	b9 38 a0 1f 	sra  %g2, 0x1f, %i4                            
40006ca4:	f8 06 40 00 	ld  [ %i1 ], %i4                               
40006ca8:	ba 10 00 1c 	mov  %i4, %i5                                  
40006cac:	b8 10 20 00 	clr  %i4                                       
40006cb0:	10 80 00 14 	b  40006d00 <vprintk+0x2d4>                    
40006cb4:	b2 10 00 01 	mov  %g1, %i1                                  
        break;                                                        
      case LFLAG_LONG:                                                
        num = sign ? (long long) va_arg(ap, long)                     
          : (long long) va_arg(ap, unsigned long);                    
40006cb8:	80 8e e0 ff 	btst  0xff, %i3                                
40006cbc:	22 80 00 07 	be,a   40006cd8 <vprintk+0x2ac>                
40006cc0:	f8 06 40 00 	ld  [ %i1 ], %i4                               
40006cc4:	c2 06 40 00 	ld  [ %i1 ], %g1                               
      case LFLAG_INT:                                                 
        num = sign ? (long long) va_arg(ap, int)                      
          : (long long) va_arg(ap, unsigned int);                     
        break;                                                        
      case LFLAG_LONG:                                                
        num = sign ? (long long) va_arg(ap, long)                     
40006cc8:	b2 06 60 04 	add  %i1, 4, %i1                               
          : (long long) va_arg(ap, unsigned long);                    
40006ccc:	ba 10 00 01 	mov  %g1, %i5                                  
40006cd0:	10 80 00 0c 	b  40006d00 <vprintk+0x2d4>                    
40006cd4:	b9 38 60 1f 	sra  %g1, 0x1f, %i4                            
40006cd8:	b6 10 20 00 	clr  %i3                                       
40006cdc:	ba 10 00 1c 	mov  %i4, %i5                                  
40006ce0:	b2 06 60 04 	add  %i1, 4, %i1                               
40006ce4:	10 80 00 07 	b  40006d00 <vprintk+0x2d4>                    
40006ce8:	b8 10 20 00 	clr  %i4                                       
        break;                                                        
      case LFLAG_LONG_LONG:                                           
        num = va_arg(ap, long long);                                  
40006cec:	90 07 bf e0 	add  %fp, -32, %o0                             
40006cf0:	40 00 25 32 	call  400101b8 <memcpy>                        
40006cf4:	94 10 20 08 	mov  8, %o2                                    
40006cf8:	f8 1f bf e0 	ldd  [ %fp + -32 ], %i4                        
40006cfc:	b2 06 60 08 	add  %i1, 8, %i1                               
  unsigned long long n;                                               
  unsigned count;                                                     
  #define UINT64_MAX_IN_OCTAL_FORMAT "1777777777777777777777"         
  char toPrint[sizeof(UINT64_MAX_IN_OCTAL_FORMAT)];                   
                                                                      
  if ( sign && (num <  0) ) {                                         
40006d00:	80 a7 20 00 	cmp  %i4, 0                                    
40006d04:	16 80 00 0e 	bge  40006d3c <vprintk+0x310>                  
40006d08:	b4 10 00 1c 	mov  %i4, %i2                                  
40006d0c:	80 8e e0 ff 	btst  0xff, %i3                                
40006d10:	02 80 00 0c 	be  40006d40 <vprintk+0x314>                   
40006d14:	b6 10 00 1d 	mov  %i5, %i3                                  
    rtems_putc('-');                                                  
40006d18:	40 00 15 a3 	call  4000c3a4 <rtems_putc>                    
40006d1c:	90 10 20 2d 	mov  0x2d, %o0                                 
    unsigned_num = (unsigned long long) -num;                         
40006d20:	b6 a0 00 1d 	subcc  %g0, %i5, %i3                           
40006d24:	b4 60 00 1c 	subx  %g0, %i4, %i2                            
    if (maxwidth) maxwidth--;                                         
40006d28:	80 a4 60 00 	cmp  %l1, 0                                    
40006d2c:	32 80 00 06 	bne,a   40006d44 <vprintk+0x318>               
40006d30:	a0 04 7f ff 	add  %l1, -1, %l0                              
  } else {                                                            
    unsigned_num = (unsigned long long) num;                          
40006d34:	10 80 00 05 	b  40006d48 <vprintk+0x31c>                    
40006d38:	a2 10 20 00 	clr  %l1                                       
40006d3c:	b6 10 00 1d 	mov  %i5, %i3                                  
40006d40:	a0 10 00 11 	mov  %l1, %l0                                  
40006d44:	a2 10 20 00 	clr  %l1                                       
  }                                                                   
                                                                      
  count = 0;                                                          
  while ((n = unsigned_num / base) > 0) {                             
40006d48:	90 10 00 1a 	mov  %i2, %o0                                  
40006d4c:	92 10 00 1b 	mov  %i3, %o1                                  
40006d50:	94 10 20 00 	clr  %o2                                       
40006d54:	96 10 00 16 	mov  %l6, %o3                                  
40006d58:	40 00 35 23 	call  400141e4 <__udivdi3>                     
40006d5c:	a8 04 60 01 	add  %l1, 1, %l4                               
40006d60:	84 10 00 08 	mov  %o0, %g2                                  
40006d64:	80 92 40 02 	orcc  %o1, %g2, %g0                            
40006d68:	02 80 00 0d 	be  40006d9c <vprintk+0x370>                   
40006d6c:	ae 10 00 09 	mov  %o1, %l7                                  
    toPrint[count++] = (char) (unsigned_num - (n * base));            
40006d70:	c4 27 bf dc 	st  %g2, [ %fp + -36 ]                         
40006d74:	90 10 00 17 	mov  %l7, %o0                                  
40006d78:	40 00 31 9e 	call  400133f0 <.umul>                         
40006d7c:	92 10 00 16 	mov  %l6, %o1                                  
40006d80:	90 26 c0 08 	sub  %i3, %o0, %o0                             
40006d84:	d0 2c 40 12 	stb  %o0, [ %l1 + %l2 ]                        
40006d88:	c4 07 bf dc 	ld  [ %fp + -36 ], %g2                         
40006d8c:	a2 10 00 14 	mov  %l4, %l1                                  
40006d90:	b4 10 00 02 	mov  %g2, %i2                                  
40006d94:	10 bf ff ed 	b  40006d48 <vprintk+0x31c>                    
40006d98:	b6 10 00 17 	mov  %l7, %i3                                  
    unsigned_num = n;                                                 
  }                                                                   
  toPrint[count++] = (char) unsigned_num;                             
40006d9c:	a2 07 80 11 	add  %fp, %l1, %l1                             
                                                                      
  for (n=maxwidth ; n > count; n-- )                                  
40006da0:	ac 10 20 00 	clr  %l6                                       
  count = 0;                                                          
  while ((n = unsigned_num / base) > 0) {                             
    toPrint[count++] = (char) (unsigned_num - (n * base));            
    unsigned_num = n;                                                 
  }                                                                   
  toPrint[count++] = (char) unsigned_num;                             
40006da4:	f6 2c 7f e8 	stb  %i3, [ %l1 + -24 ]                        
                                                                      
  for (n=maxwidth ; n > count; n-- )                                  
40006da8:	ae 10 20 00 	clr  %l7                                       
40006dac:	a2 10 00 10 	mov  %l0, %l1                                  
40006db0:	b4 10 20 00 	clr  %i2                                       
40006db4:	a0 10 20 00 	clr  %l0                                       
40006db8:	b6 10 00 14 	mov  %l4, %i3                                  
    rtems_putc(lead);                                                 
40006dbc:	a6 0c e0 30 	and  %l3, 0x30, %l3                            
40006dc0:	86 85 c0 11 	addcc  %l7, %l1, %g3                           
40006dc4:	84 45 80 10 	addx  %l6, %l0, %g2                            
    toPrint[count++] = (char) (unsigned_num - (n * base));            
    unsigned_num = n;                                                 
  }                                                                   
  toPrint[count++] = (char) unsigned_num;                             
                                                                      
  for (n=maxwidth ; n > count; n-- )                                  
40006dc8:	80 a0 a0 00 	cmp  %g2, 0                                    
40006dcc:	08 80 00 09 	bleu  40006df0 <vprintk+0x3c4>                 <== ALWAYS TAKEN
40006dd0:	01 00 00 00 	nop                                            
    rtems_putc(lead);                                                 
40006dd4:	40 00 15 74 	call  4000c3a4 <rtems_putc>                    
40006dd8:	90 10 00 13 	mov  %l3, %o0                                  
40006ddc:	86 85 ff ff 	addcc  %l7, -1, %g3                            
40006de0:	84 45 bf ff 	addx  %l6, -1, %g2                             
40006de4:	ae 10 00 03 	mov  %g3, %l7                                  
40006de8:	10 bf ff f6 	b  40006dc0 <vprintk+0x394>                    
40006dec:	ac 10 00 02 	mov  %g2, %l6                                  
    toPrint[count++] = (char) (unsigned_num - (n * base));            
    unsigned_num = n;                                                 
  }                                                                   
  toPrint[count++] = (char) unsigned_num;                             
                                                                      
  for (n=maxwidth ; n > count; n-- )                                  
40006df0:	12 80 00 04 	bne  40006e00 <vprintk+0x3d4>                  <== NEVER TAKEN
40006df4:	80 a0 c0 14 	cmp  %g3, %l4                                  
40006df8:	18 bf ff f7 	bgu  40006dd4 <vprintk+0x3a8>                  
40006dfc:	01 00 00 00 	nop                                            
40006e00:	86 86 ff ff 	addcc  %i3, -1, %g3                            
40006e04:	a6 10 20 00 	clr  %l3                                       
40006e08:	a0 10 20 00 	clr  %l0                                       
40006e0c:	a2 10 20 00 	clr  %l1                                       
40006e10:	ac 04 80 03 	add  %l2, %g3, %l6                             
    rtems_putc(lead);                                                 
                                                                      
  for (n = 0; n < count; n++) {                                       
    rtems_putc("0123456789ABCDEF"[(int)(toPrint[count-(n+1)])]);      
40006e14:	c2 4d 80 13 	ldsb  [ %l6 + %l3 ], %g1                       
40006e18:	07 10 00 57 	sethi  %hi(0x40015c00), %g3                    
40006e1c:	84 10 e0 f0 	or  %g3, 0xf0, %g2	! 40015cf0 <rtems_filesystem_null_handlers+0x40>
40006e20:	d0 48 80 01 	ldsb  [ %g2 + %g1 ], %o0                       
40006e24:	40 00 15 60 	call  4000c3a4 <rtems_putc>                    
40006e28:	a6 04 ff ff 	add  %l3, -1, %l3                              
  toPrint[count++] = (char) unsigned_num;                             
                                                                      
  for (n=maxwidth ; n > count; n-- )                                  
    rtems_putc(lead);                                                 
                                                                      
  for (n = 0; n < count; n++) {                                       
40006e2c:	86 84 60 01 	addcc  %l1, 1, %g3                             
40006e30:	84 44 20 00 	addx  %l0, 0, %g2                              
40006e34:	a2 10 00 03 	mov  %g3, %l1                                  
40006e38:	80 a6 80 02 	cmp  %i2, %g2                                  
40006e3c:	18 bf ff f6 	bgu  40006e14 <vprintk+0x3e8>                  <== NEVER TAKEN
40006e40:	a0 10 00 02 	mov  %g2, %l0                                  
40006e44:	80 a6 80 02 	cmp  %i2, %g2                                  
40006e48:	12 80 00 04 	bne  40006e58 <vprintk+0x42c>                  <== NEVER TAKEN
40006e4c:	80 a6 c0 03 	cmp  %i3, %g3                                  
40006e50:	38 bf ff f2 	bgu,a   40006e18 <vprintk+0x3ec>               
40006e54:	c2 4d 80 13 	ldsb  [ %l6 + %l3 ], %g1                       
void vprintk(                                                         
  const char *fmt,                                                    
  va_list     ap                                                      
)                                                                     
{                                                                     
  for (; *fmt != '\0'; fmt++) {                                       
40006e58:	b0 06 20 01 	inc  %i0                                       
40006e5c:	10 bf fe f8 	b  40006a3c <vprintk+0x10>                     
40006e60:	d0 4e 00 00 	ldsb  [ %i0 ], %o0                             
        break;                                                        
    }                                                                 
                                                                      
    printNum(num, base, sign, width, lead);                           
  }                                                                   
}                                                                     
40006e64:	81 c7 e0 08 	ret                                            
40006e68:	81 e8 00 00 	restore                                        
                                                                      

400073a8 <wait>: #include <rtems/seterr.h> int wait( int *stat_loc ) {
400073a8:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_set_errno_and_return_minus_one( ENOSYS );                     
400073ac:	40 00 23 83 	call  400101b8 <__errno>                       
400073b0:	b0 10 3f ff 	mov  -1, %i0                                   
400073b4:	82 10 20 58 	mov  0x58, %g1                                 
400073b8:	c2 22 00 00 	st  %g1, [ %o0 ]                               
}                                                                     
400073bc:	81 c7 e0 08 	ret                                            
400073c0:	81 e8 00 00 	restore                                        
                                                                      

40015024 <write>: ssize_t write( int fd, const void *buffer, size_t count ) {
40015024:	9d e3 bf a0 	save  %sp, -96, %sp                            
  rtems_libio_t     *iop;                                             
                                                                      
  rtems_libio_check_fd( fd );                                         
40015028:	03 10 00 5a 	sethi  %hi(0x40016800), %g1                    
4001502c:	c2 00 63 30 	ld  [ %g1 + 0x330 ], %g1	! 40016b30 <rtems_libio_number_iops>
40015030:	80 a6 00 01 	cmp  %i0, %g1                                  
40015034:	2a 80 00 06 	bcs,a   4001504c <write+0x28>                  
40015038:	83 2e 20 03 	sll  %i0, 3, %g1                               
4001503c:	7f ff ea 79 	call  4000fa20 <__errno>                       
40015040:	01 00 00 00 	nop                                            
40015044:	10 80 00 10 	b  40015084 <write+0x60>                       
40015048:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  iop = rtems_libio_iop( fd );                                        
4001504c:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40015050:	b0 26 00 01 	sub  %i0, %g1, %i0                             
40015054:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
40015058:	d0 00 63 30 	ld  [ %g1 + 0x330 ], %o0	! 40018330 <rtems_libio_iops>
4001505c:	90 02 00 18 	add  %o0, %i0, %o0                             
  rtems_libio_check_is_open( iop );                                   
40015060:	c2 02 20 10 	ld  [ %o0 + 0x10 ], %g1                        
40015064:	80 88 61 00 	btst  0x100, %g1                               
40015068:	02 bf ff f5 	be  4001503c <write+0x18>                      
4001506c:	80 a6 60 00 	cmp  %i1, 0                                    
  rtems_libio_check_buffer( buffer );                                 
40015070:	12 80 00 08 	bne  40015090 <write+0x6c>                     <== ALWAYS TAKEN
40015074:	80 a6 a0 00 	cmp  %i2, 0                                    
40015078:	7f ff ea 6a 	call  4000fa20 <__errno>                       <== NOT EXECUTED
4001507c:	01 00 00 00 	nop                                            <== NOT EXECUTED
40015080:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      <== NOT EXECUTED
40015084:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40015088:	81 c7 e0 08 	ret                                            
4001508c:	91 e8 3f ff 	restore  %g0, -1, %o0                          
  rtems_libio_check_count( count );                                   
40015090:	02 80 00 0a 	be  400150b8 <write+0x94>                      
40015094:	b0 10 20 00 	clr  %i0                                       
  rtems_libio_check_permissions_with_error( iop, LIBIO_FLAGS_WRITE, EBADF );
40015098:	80 88 60 04 	btst  4, %g1                                   
4001509c:	02 bf ff e8 	be  4001503c <write+0x18>                      
400150a0:	92 10 00 19 	mov  %i1, %o1                                  
                                                                      
  /*                                                                  
   *  Now process the write() request.                                
   */                                                                 
  return (*iop->pathinfo.handlers->write_h)( iop, buffer, count );    
400150a4:	c2 02 20 24 	ld  [ %o0 + 0x24 ], %g1                        
400150a8:	c2 00 60 0c 	ld  [ %g1 + 0xc ], %g1                         
400150ac:	9f c0 40 00 	call  %g1                                      
400150b0:	94 10 00 1a 	mov  %i2, %o2                                  
400150b4:	b0 10 00 08 	mov  %o0, %i0                                  
}                                                                     
400150b8:	81 c7 e0 08 	ret                                            
400150bc:	81 e8 00 00 	restore                                        
                                                                      

400087e8 <writev>: ssize_t writev( int fd, const struct iovec *iov, int iovcnt ) {
400087e8:	9d e3 bf a0 	save  %sp, -96, %sp                            
{                                                                     
  ssize_t        total;                                               
  int            v;                                                   
  rtems_libio_t *iop;                                                 
                                                                      
  rtems_libio_check_fd( fd );                                         
400087ec:	03 10 00 60 	sethi  %hi(0x40018000), %g1                    
400087f0:	c2 00 62 00 	ld  [ %g1 + 0x200 ], %g1	! 40018200 <rtems_libio_number_iops>
400087f4:	80 a6 00 01 	cmp  %i0, %g1                                  
400087f8:	2a 80 00 06 	bcs,a   40008810 <writev+0x28>                 
400087fc:	83 2e 20 03 	sll  %i0, 3, %g1                               
40008800:	40 00 22 e1 	call  40011384 <__errno>                       
40008804:	01 00 00 00 	nop                                            
40008808:	10 80 00 12 	b  40008850 <writev+0x68>                      
4000880c:	82 10 20 09 	mov  9, %g1	! 9 <_TLS_Alignment+0x8>           
  iop = rtems_libio_iop( fd );                                        
40008810:	b1 2e 20 06 	sll  %i0, 6, %i0                               
40008814:	b0 26 00 01 	sub  %i0, %g1, %i0                             
40008818:	03 10 00 66 	sethi  %hi(0x40019800), %g1                    
4000881c:	d0 00 61 f0 	ld  [ %g1 + 0x1f0 ], %o0	! 400199f0 <rtems_libio_iops>
40008820:	90 02 00 18 	add  %o0, %i0, %o0                             
  rtems_libio_check_is_open( iop );                                   
40008824:	c2 02 20 10 	ld  [ %o0 + 0x10 ], %g1                        
40008828:	80 88 61 00 	btst  0x100, %g1                               
4000882c:	02 bf ff f5 	be  40008800 <writev+0x18>                     
40008830:	80 88 60 04 	btst  4, %g1                                   
  rtems_libio_check_permissions_with_error( iop, flags, EBADF );      
40008834:	02 bf ff f3 	be  40008800 <writev+0x18>                     <== NEVER TAKEN
40008838:	80 a6 60 00 	cmp  %i1, 0                                    
  *iopp = iop;                                                        
                                                                      
  /*                                                                  
   *  Argument validation on IO vector                                
   */                                                                 
  if ( iov == NULL )                                                  
4000883c:	12 80 00 08 	bne  4000885c <writev+0x74>                    
40008840:	82 06 bf ff 	add  %i2, -1, %g1                              
    rtems_set_errno_and_return_minus_one( EINVAL );                   
40008844:	40 00 22 d0 	call  40011384 <__errno>                       
40008848:	01 00 00 00 	nop                                            
4000884c:	82 10 20 16 	mov  0x16, %g1	! 16 <_TLS_Alignment+0x15>      
40008850:	c2 22 00 00 	st  %g1, [ %o0 ]                               
40008854:	81 c7 e0 08 	ret                                            
40008858:	91 e8 3f ff 	restore  %g0, -1, %o0                          
                                                                      
  if ( iovcnt <= 0 )                                                  
4000885c:	80 a0 63 ff 	cmp  %g1, 0x3ff                                
40008860:	18 bf ff f9 	bgu  40008844 <writev+0x5c>                    
40008864:	09 1f ff ff 	sethi  %hi(0x7ffffc00), %g4                    
40008868:	87 2e a0 03 	sll  %i2, 3, %g3                               
4000886c:	82 10 20 00 	clr  %g1                                       
40008870:	96 10 20 00 	clr  %o3                                       
   */                                                                 
  total = 0;                                                          
  for ( v = 0 ; v < iovcnt ; ++v ) {                                  
    size_t len = iov[ v ].iov_len;                                    
                                                                      
    if ( len > ( size_t ) ( SSIZE_MAX - total ) ) {                   
40008874:	88 11 23 ff 	or  %g4, 0x3ff, %g4                            
40008878:	84 06 40 01 	add  %i1, %g1, %g2                             
   *  sum of the iov_len values in the iov array would overflow a     
   *  ssize_t.                                                        
   */                                                                 
  total = 0;                                                          
  for ( v = 0 ; v < iovcnt ; ++v ) {                                  
    size_t len = iov[ v ].iov_len;                                    
4000887c:	c4 00 a0 04 	ld  [ %g2 + 4 ], %g2                           
                                                                      
    if ( len > ( size_t ) ( SSIZE_MAX - total ) ) {                   
40008880:	ba 21 00 0b 	sub  %g4, %o3, %i5                             
40008884:	80 a0 80 1d 	cmp  %g2, %i5                                  
40008888:	18 bf ff ef 	bgu  40008844 <writev+0x5c>                    
4000888c:	01 00 00 00 	nop                                            
      rtems_set_errno_and_return_minus_one( EINVAL );                 
    }                                                                 
                                                                      
    total += ( ssize_t ) len;                                         
                                                                      
    if ( iov[ v ].iov_base == NULL && len != 0 ) {                    
40008890:	fa 06 40 01 	ld  [ %i1 + %g1 ], %i5                         
40008894:	80 a7 60 00 	cmp  %i5, 0                                    
40008898:	12 80 00 05 	bne  400088ac <writev+0xc4>                    
4000889c:	96 02 c0 02 	add  %o3, %g2, %o3                             
400088a0:	80 a0 a0 00 	cmp  %g2, 0                                    
400088a4:	12 bf ff e8 	bne  40008844 <writev+0x5c>                    
400088a8:	01 00 00 00 	nop                                            
400088ac:	82 00 60 08 	add  %g1, 8, %g1                               
   *  OpenGroup says that you are supposed to return EINVAL if the    
   *  sum of the iov_len values in the iov array would overflow a     
   *  ssize_t.                                                        
   */                                                                 
  total = 0;                                                          
  for ( v = 0 ; v < iovcnt ; ++v ) {                                  
400088b0:	80 a0 40 03 	cmp  %g1, %g3                                  
400088b4:	12 bf ff f2 	bne  4000887c <writev+0x94>                    
400088b8:	84 06 40 01 	add  %i1, %g1, %g2                             
  ssize_t        total;                                               
  rtems_libio_t *iop;                                                 
                                                                      
  total = rtems_libio_iovec_eval( fd, iov, iovcnt, LIBIO_FLAGS_WRITE, &iop );
                                                                      
  if ( total > 0 ) {                                                  
400088bc:	80 a2 e0 00 	cmp  %o3, 0                                    
400088c0:	02 80 00 08 	be  400088e0 <writev+0xf8>                     
400088c4:	b0 10 20 00 	clr  %i0                                       
    total = ( *iop->pathinfo.handlers->writev_h )( iop, iov, iovcnt, total );
400088c8:	c2 02 20 24 	ld  [ %o0 + 0x24 ], %g1                        
400088cc:	92 10 00 19 	mov  %i1, %o1                                  
400088d0:	c2 00 60 38 	ld  [ %g1 + 0x38 ], %g1                        
400088d4:	9f c0 40 00 	call  %g1                                      
400088d8:	94 10 00 1a 	mov  %i2, %o2                                  
400088dc:	b0 10 00 08 	mov  %o0, %i0                                  
  }                                                                   
                                                                      
  return total;                                                       
}                                                                     
400088e0:	81 c7 e0 08 	ret                                            
400088e4:	81 e8 00 00 	restore