RTEMS-6
Annotated Report
libfsmount
Sun Feb 28 23:20:23 2021

00118d30 <rtems_fsmount>:                                                                 
 )                                                                                        
/*-------------------------------------------------------------------------*\             
  | Return Value:                                                             |           
  |    0, if success, -1 and errno if failed                                  |           
  \*=========================================================================*/           
{                                                                                         
  118d30:   55                      push   %ebp                                           <== NOT EXECUTED
  118d31:   89 e5                   mov    %esp,%ebp                                      <== NOT EXECUTED
  118d33:   57                      push   %edi                                           <== NOT EXECUTED
  int rc = 0;                                                                             
  int tmp_rc;                                                                             
  size_t fstab_idx = 0;                                                                   
  118d34:   31 ff                   xor    %edi,%edi                                      <== NOT EXECUTED
{                                                                                         
  118d36:   56                      push   %esi                                           <== NOT EXECUTED
  118d37:   53                      push   %ebx                                           <== NOT EXECUTED
  118d38:   83 ec 3c                sub    $0x3c,%esp                                     <== NOT EXECUTED
  bool terminate = false;                                                                 
                                                                                          
  /*                                                                                      
   * scan through all fstab entries;                                                      
   */                                                                                     
  while (!terminate &&                                                                    
  118d3b:   8b 75 0c                mov    0xc(%ebp),%esi                                 <== NOT EXECUTED
{                                                                                         
  118d3e:   8b 5d 08                mov    0x8(%ebp),%ebx                                 <== NOT EXECUTED
  while (!terminate &&                                                                    
  118d41:   85 f6                   test   %esi,%esi                                      <== NOT EXECUTED
  118d43:   75 2a                   jne    118d6f <rtems_fsmount+0x3f>                    <== NOT EXECUTED
  118d45:   e9 96 01 00 00          jmp    118ee0 <rtems_fsmount+0x1b0>                   <== NOT EXECUTED
  118d4a:   8d b6 00 00 00 00       lea    0x0(%esi),%esi                                 <== NOT EXECUTED
     * create mount point                                                                 
     */                                                                                   
    if (tmp_rc == 0) {                                                                    
      tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);               
      if (tmp_rc != 0) {                                                                  
        if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNTPNT_CRTERR)) {                   
  118d50:   f6 43 10 02             testb  $0x2,0x10(%ebx)                                <== NOT EXECUTED
  118d54:   0f 85 a6 00 00 00       jne    118e00 <rtems_fsmount+0xd0>                    <== NOT EXECUTED
          fprintf(stdout,"fsmount: creation of mount point \"%s\" failed: %s\n",          
                  fstab_ptr->target,                                                      
                  strerror(errno));                                                       
        }                                                                                 
        if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNTPNT_CRTERR)) {                    
  118d5a:   f6 43 12 02             testb  $0x2,0x12(%ebx)                                <== NOT EXECUTED
  118d5e:   66 90                   xchg   %ax,%ax                                        <== NOT EXECUTED
  118d60:   75 62                   jne    118dc4 <rtems_fsmount+0x94>                    <== NOT EXECUTED
    /*                                                                                    
     * proceed to next entry                                                              
     */                                                                                   
    if (!terminate) {                                                                     
      fstab_ptr++;                                                                        
      fstab_idx++;                                                                        
  118d62:   47                      inc    %edi                                           <== NOT EXECUTED
      fstab_ptr++;                                                                        
  118d63:   83 c3 14                add    $0x14,%ebx                                     <== NOT EXECUTED
  while (!terminate &&                                                                    
  118d66:   39 7d 0c                cmp    %edi,0xc(%ebp)                                 <== NOT EXECUTED
  118d69:   0f 84 71 01 00 00       je     118ee0 <rtems_fsmount+0x1b0>                   <== NOT EXECUTED
      tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);               
  118d6f:   b9 ff 01 00 00          mov    $0x1ff,%ecx                                    <== NOT EXECUTED
  118d74:   89 4c 24 04             mov    %ecx,0x4(%esp)                                 <== NOT EXECUTED
  118d78:   8b 43 04                mov    0x4(%ebx),%eax                                 <== NOT EXECUTED
  118d7b:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118d7e:   e8 fd 15 02 00          call   13a380 <rtems_mkdir>                           <== NOT EXECUTED
      if (tmp_rc != 0) {                                                                  
  118d83:   85 c0                   test   %eax,%eax                                      <== NOT EXECUTED
      tmp_rc = rtems_mkdir(fstab_ptr->target, S_IRWXU | S_IRWXG | S_IRWXO);               
  118d85:   89 c6                   mov    %eax,%esi                                      <== NOT EXECUTED
      if (tmp_rc != 0) {                                                                  
  118d87:   75 c7                   jne    118d50 <rtems_fsmount+0x20>                    <== NOT EXECUTED
      tmp_rc = mount(fstab_ptr->source,                                                   
  118d89:   31 f6                   xor    %esi,%esi                                      <== NOT EXECUTED
  118d8b:   89 74 24 10             mov    %esi,0x10(%esp)                                <== NOT EXECUTED
  118d8f:   8b 43 0c                mov    0xc(%ebx),%eax                                 <== NOT EXECUTED
  118d92:   89 44 24 0c             mov    %eax,0xc(%esp)                                 <== NOT EXECUTED
  118d96:   8b 43 08                mov    0x8(%ebx),%eax                                 <== NOT EXECUTED
  118d99:   89 44 24 08             mov    %eax,0x8(%esp)                                 <== NOT EXECUTED
  118d9d:   8b 43 04                mov    0x4(%ebx),%eax                                 <== NOT EXECUTED
  118da0:   89 44 24 04             mov    %eax,0x4(%esp)                                 <== NOT EXECUTED
  118da4:   8b 03                   mov    (%ebx),%eax                                    <== NOT EXECUTED
  118da6:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118da9:   e8 72 f4 fe ff          call   108220 <mount>                                 <== NOT EXECUTED
      if (tmp_rc != 0) {                                                                  
  118dae:   85 c0                   test   %eax,%eax                                      <== NOT EXECUTED
      tmp_rc = mount(fstab_ptr->source,                                                   
  118db0:   89 c6                   mov    %eax,%esi                                      <== NOT EXECUTED
      if (tmp_rc != 0) {                                                                  
  118db2:   74 2c                   je     118de0 <rtems_fsmount+0xb0>                    <== NOT EXECUTED
        if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_FAILED)) {                      
  118db4:   f6 43 10 04             testb  $0x4,0x10(%ebx)                                <== NOT EXECUTED
  118db8:   0f 85 92 00 00 00       jne    118e50 <rtems_fsmount+0x120>                   <== NOT EXECUTED
        if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNT_FAILED)) {                       
  118dbe:   f6 43 12 04             testb  $0x4,0x12(%ebx)                                <== NOT EXECUTED
  118dc2:   74 9e                   je     118d62 <rtems_fsmount+0x32>                    <== NOT EXECUTED
    }                                                                                     
  }                                                                                       
  if (fail_idx != NULL) {                                                                 
  118dc4:   8b 45 10                mov    0x10(%ebp),%eax                                <== NOT EXECUTED
  118dc7:   85 c0                   test   %eax,%eax                                      <== NOT EXECUTED
  118dc9:   74 05                   je     118dd0 <rtems_fsmount+0xa0>                    <== NOT EXECUTED
    *fail_idx = fstab_idx;                                                                
  118dcb:   8b 45 10                mov    0x10(%ebp),%eax                                <== NOT EXECUTED
  118dce:   89 38                   mov    %edi,(%eax)                                    <== NOT EXECUTED
  }                                                                                       
  return rc;                                                                              
}                                                                                         
  118dd0:   83 c4 3c                add    $0x3c,%esp                                     <== NOT EXECUTED
  118dd3:   89 f0                   mov    %esi,%eax                                      <== NOT EXECUTED
  118dd5:   5b                      pop    %ebx                                           <== NOT EXECUTED
  118dd6:   5e                      pop    %esi                                           <== NOT EXECUTED
  118dd7:   5f                      pop    %edi                                           <== NOT EXECUTED
  118dd8:   5d                      pop    %ebp                                           <== NOT EXECUTED
  118dd9:   c3                      ret                                                   <== NOT EXECUTED
  118dda:   8d b6 00 00 00 00       lea    0x0(%esi),%esi                                 <== NOT EXECUTED
        if (0 != (fstab_ptr->report_reasons & FSMOUNT_MNT_OK)) {                          
  118de0:   f6 43 10 01             testb  $0x1,0x10(%ebx)                                <== NOT EXECUTED
  118de4:   0f 85 b6 00 00 00       jne    118ea0 <rtems_fsmount+0x170>                   <== NOT EXECUTED
        if (0 != (fstab_ptr->abort_reasons & FSMOUNT_MNT_OK)) {                           
  118dea:   f6 43 12 01             testb  $0x1,0x12(%ebx)                                <== NOT EXECUTED
  118dee:   75 d4                   jne    118dc4 <rtems_fsmount+0x94>                    <== NOT EXECUTED
  118df0:   e9 6d ff ff ff          jmp    118d62 <rtems_fsmount+0x32>                    <== NOT EXECUTED
  118df5:   8d b4 26 00 00 00 00    lea    0x0(%esi,%eiz,1),%esi                          <== NOT EXECUTED
  118dfc:   8d 74 26 00             lea    0x0(%esi,%eiz,1),%esi                          <== NOT EXECUTED
                  strerror(errno));                                                       
  118e00:   e8 db 7d 05 00          call   170be0 <__errno>                               <== NOT EXECUTED
          fprintf(stdout,"fsmount: creation of mount point \"%s\" failed: %s\n",          
  118e05:   8b 00                   mov    (%eax),%eax                                    <== NOT EXECUTED
  118e07:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118e0a:   e8 21 ee 05 00          call   177c30 <strerror>                              <== NOT EXECUTED
  118e0f:   8b 4b 04                mov    0x4(%ebx),%ecx                                 <== NOT EXECUTED
  118e12:   89 4d e4                mov    %ecx,-0x1c(%ebp)                               <== NOT EXECUTED
  118e15:   89 45 e0                mov    %eax,-0x20(%ebp)                               <== NOT EXECUTED
  118e18:   e8 63 90 fe ff          call   101e80 <__getreent>                            <== NOT EXECUTED
  118e1d:   8b 55 e0                mov    -0x20(%ebp),%edx                               <== NOT EXECUTED
  118e20:   8b 4d e4                mov    -0x1c(%ebp),%ecx                               <== NOT EXECUTED
  118e23:   89 54 24 0c             mov    %edx,0xc(%esp)                                 <== NOT EXECUTED
  118e27:   ba 20 ec 18 00          mov    $0x18ec20,%edx                                 <== NOT EXECUTED
  118e2c:   89 4c 24 08             mov    %ecx,0x8(%esp)                                 <== NOT EXECUTED
  118e30:   89 54 24 04             mov    %edx,0x4(%esp)                                 <== NOT EXECUTED
  118e34:   8b 40 08                mov    0x8(%eax),%eax                                 <== NOT EXECUTED
  118e37:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118e3a:   e8 a1 8c 05 00          call   171ae0 <fprintf>                               <== NOT EXECUTED
  118e3f:   e9 16 ff ff ff          jmp    118d5a <rtems_fsmount+0x2a>                    <== NOT EXECUTED
  118e44:   8d b4 26 00 00 00 00    lea    0x0(%esi,%eiz,1),%esi                          <== NOT EXECUTED
  118e4b:   8d 74 26 00             lea    0x0(%esi,%eiz,1),%esi                          <== NOT EXECUTED
  118e4f:   90                      nop                                                   <== NOT EXECUTED
                  strerror(errno));                                                       
  118e50:   e8 8b 7d 05 00          call   170be0 <__errno>                               <== NOT EXECUTED
          fprintf(stdout,"fsmount: mounting of \"%s\" to"                                 
  118e55:   8b 00                   mov    (%eax),%eax                                    <== NOT EXECUTED
  118e57:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118e5a:   e8 d1 ed 05 00          call   177c30 <strerror>                              <== NOT EXECUTED
  118e5f:   8b 4b 04                mov    0x4(%ebx),%ecx                                 <== NOT EXECUTED
  118e62:   89 4d e0                mov    %ecx,-0x20(%ebp)                               <== NOT EXECUTED
  118e65:   89 45 dc                mov    %eax,-0x24(%ebp)                               <== NOT EXECUTED
  118e68:   8b 03                   mov    (%ebx),%eax                                    <== NOT EXECUTED
  118e6a:   89 45 e4                mov    %eax,-0x1c(%ebp)                               <== NOT EXECUTED
  118e6d:   e8 0e 90 fe ff          call   101e80 <__getreent>                            <== NOT EXECUTED
  118e72:   8b 55 dc                mov    -0x24(%ebp),%edx                               <== NOT EXECUTED
  118e75:   8b 4d e0                mov    -0x20(%ebp),%ecx                               <== NOT EXECUTED
  118e78:   89 54 24 10             mov    %edx,0x10(%esp)                                <== NOT EXECUTED
  118e7c:   8b 55 e4                mov    -0x1c(%ebp),%edx                               <== NOT EXECUTED
  118e7f:   89 4c 24 0c             mov    %ecx,0xc(%esp)                                 <== NOT EXECUTED
  118e83:   b9 54 ec 18 00          mov    $0x18ec54,%ecx                                 <== NOT EXECUTED
  118e88:   89 4c 24 04             mov    %ecx,0x4(%esp)                                 <== NOT EXECUTED
  118e8c:   89 54 24 08             mov    %edx,0x8(%esp)                                 <== NOT EXECUTED
  118e90:   8b 40 08                mov    0x8(%eax),%eax                                 <== NOT EXECUTED
  118e93:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118e96:   e8 45 8c 05 00          call   171ae0 <fprintf>                               <== NOT EXECUTED
  118e9b:   e9 1e ff ff ff          jmp    118dbe <rtems_fsmount+0x8e>                    <== NOT EXECUTED
          fprintf(stdout,"fsmount: mounting of \"%s\" to"                                 
  118ea0:   8b 53 04                mov    0x4(%ebx),%edx                                 <== NOT EXECUTED
  118ea3:   8b 0b                   mov    (%ebx),%ecx                                    <== NOT EXECUTED
  118ea5:   89 55 e0                mov    %edx,-0x20(%ebp)                               <== NOT EXECUTED
  118ea8:   89 4d e4                mov    %ecx,-0x1c(%ebp)                               <== NOT EXECUTED
  118eab:   e8 d0 8f fe ff          call   101e80 <__getreent>                            <== NOT EXECUTED
  118eb0:   8b 55 e0                mov    -0x20(%ebp),%edx                               <== NOT EXECUTED
  118eb3:   8b 4d e4                mov    -0x1c(%ebp),%ecx                               <== NOT EXECUTED
  118eb6:   89 54 24 0c             mov    %edx,0xc(%esp)                                 <== NOT EXECUTED
  118eba:   ba 84 ec 18 00          mov    $0x18ec84,%edx                                 <== NOT EXECUTED
  118ebf:   89 4c 24 08             mov    %ecx,0x8(%esp)                                 <== NOT EXECUTED
  118ec3:   89 54 24 04             mov    %edx,0x4(%esp)                                 <== NOT EXECUTED
  118ec7:   8b 40 08                mov    0x8(%eax),%eax                                 <== NOT EXECUTED
  118eca:   89 04 24                mov    %eax,(%esp)                                    <== NOT EXECUTED
  118ecd:   e8 0e 8c 05 00          call   171ae0 <fprintf>                               <== NOT EXECUTED
  118ed2:   e9 13 ff ff ff          jmp    118dea <rtems_fsmount+0xba>                    <== NOT EXECUTED
  118ed7:   8d b4 26 00 00 00 00    lea    0x0(%esi,%eiz,1),%esi                          <== NOT EXECUTED
  118ede:   66 90                   xchg   %ax,%ax                                        <== NOT EXECUTED
  int rc = 0;                                                                             
  118ee0:   31 f6                   xor    %esi,%esi                                      <== NOT EXECUTED
  118ee2:   e9 dd fe ff ff          jmp    118dc4 <rtems_fsmount+0x94>                    <== NOT EXECUTED
  118ee7:   90                      nop                                                   
  118ee8:   90                      nop                                                   
  118ee9:   90                      nop                                                   
  118eea:   90                      nop                                                   
  118eeb:   90                      nop                                                   
  118eec:   90                      nop                                                   
  118eed:   90                      nop                                                   
  118eee:   90                      nop                                                   
  118eef:   90                      nop