=============================================================================== 30006d9c : static inline void _Timestamp64_implementation_Set_to_zero( Timestamp64_Control *_time ) { *_time = 0; 30006d9c: e3a02000 mov r2, #0 <== NOT EXECUTED 30006da0: e3a03000 mov r3, #0 <== NOT EXECUTED 30006da4: e5802080 str r2, [r0, #128] ; 0x80 <== NOT EXECUTED 30006da8: e5803084 str r3, [r0, #132] ; 0x84 <== NOT EXECUTED #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ _Timestamp_Set_to_zero( &the_thread->cpu_time_used ); #else the_thread->cpu_time_used = 0; #endif } 30006dac: e12fff1e bx lr <== NOT EXECUTED =============================================================================== 3000e758 : const char *name, size_t namelen, mode_t mode, const IMFS_types_union *info ) { 3000e758: e92d41f0 push {r4, r5, r6, r7, r8, lr} IMFS_jnode_t *node; struct timeval tv; if ( namelen > IMFS_NAME_MAX ) { 3000e75c: e3530020 cmp r3, #32 const char *name, size_t namelen, mode_t mode, const IMFS_types_union *info ) { 3000e760: e24dd008 sub sp, sp, #8 3000e764: e1a05003 mov r5, r3 3000e768: e1a06000 mov r6, r0 3000e76c: e1a07001 mov r7, r1 3000e770: e1a08002 mov r8, r2 IMFS_jnode_t *node; struct timeval tv; if ( namelen > IMFS_NAME_MAX ) { 3000e774: 8a000027 bhi 3000e818 errno = ENAMETOOLONG; return NULL; } gettimeofday( &tv, 0 ); 3000e778: e3a01000 mov r1, #0 3000e77c: e1a0000d mov r0, sp 3000e780: ebffe02a bl 30006830 /* * Allocate an IMFS jnode */ node = calloc( 1, sizeof( IMFS_jnode_t ) ); 3000e784: e3a00001 mov r0, #1 3000e788: e3a01064 mov r1, #100 ; 0x64 3000e78c: ebffdf61 bl 30006518 if ( !node ) { 3000e790: e2504000 subs r4, r0, #0 3000e794: 0a000024 beq 3000e82c } /* * Fill in the basic information */ node->reference_count = 1; 3000e798: e3a03001 mov r3, #1 node->st_nlink = 1; memcpy( node->name, name, namelen ); 3000e79c: e1a02005 mov r2, r5 3000e7a0: e1a01008 mov r1, r8 } /* * Fill in the basic information */ node->reference_count = 1; 3000e7a4: e1c433b4 strh r3, [r4, #52] ; 0x34 node->st_nlink = 1; 3000e7a8: e1c433b6 strh r3, [r4, #54] ; 0x36 memcpy( node->name, name, namelen ); 3000e7ac: e284000c add r0, r4, #12 3000e7b0: eb001266 bl 30013150 node->name [namelen] = '\0'; 3000e7b4: e0845005 add r5, r4, r5 3000e7b8: e3a03000 mov r3, #0 3000e7bc: e5c5300c strb r3, [r5, #12] node->control = node_control; /* * Fill in the mode and permission information for the jnode structure. */ node->st_mode = mode; 3000e7c0: e59d3020 ldr r3, [sp, #32] */ node->reference_count = 1; node->st_nlink = 1; memcpy( node->name, name, namelen ); node->name [namelen] = '\0'; node->control = node_control; 3000e7c4: e584704c str r7, [r4, #76] ; 0x4c /* * Fill in the mode and permission information for the jnode structure. */ node->st_mode = mode; 3000e7c8: e5843030 str r3, [r4, #48] ; 0x30 #if defined(RTEMS_POSIX_API) node->st_uid = geteuid(); 3000e7cc: eb00022d bl 3000f088 3000e7d0: e1c403bc strh r0, [r4, #60] ; 0x3c node->st_gid = getegid(); 3000e7d4: eb000226 bl 3000f074 */ node->stat_atime = (time_t) tv.tv_sec; node->stat_mtime = (time_t) tv.tv_sec; node->stat_ctime = (time_t) tv.tv_sec; node->st_ino = ++fs_info->ino_count; 3000e7d8: e5962004 ldr r2, [r6, #4] /* * Now set all the times. */ node->stat_atime = (time_t) tv.tv_sec; 3000e7dc: e59d3000 ldr r3, [sp] node->stat_mtime = (time_t) tv.tv_sec; node->stat_ctime = (time_t) tv.tv_sec; node->st_ino = ++fs_info->ino_count; 3000e7e0: e2822001 add r2, r2, #1 * Fill in the mode and permission information for the jnode structure. */ node->st_mode = mode; #if defined(RTEMS_POSIX_API) node->st_uid = geteuid(); node->st_gid = getegid(); 3000e7e4: e1c403be strh r0, [r4, #62] ; 0x3e /* * Now set all the times. */ node->stat_atime = (time_t) tv.tv_sec; 3000e7e8: e5843040 str r3, [r4, #64] ; 0x40 node->stat_mtime = (time_t) tv.tv_sec; 3000e7ec: e5843044 str r3, [r4, #68] ; 0x44 node->stat_ctime = (time_t) tv.tv_sec; 3000e7f0: e5843048 str r3, [r4, #72] ; 0x48 node->st_ino = ++fs_info->ino_count; return (*node->control->node_initialize)( node, info ); 3000e7f4: e1a00004 mov r0, r4 3000e7f8: e594304c ldr r3, [r4, #76] ; 0x4c 3000e7fc: e59d1024 ldr r1, [sp, #36] ; 0x24 */ node->stat_atime = (time_t) tv.tv_sec; node->stat_mtime = (time_t) tv.tv_sec; node->stat_ctime = (time_t) tv.tv_sec; node->st_ino = ++fs_info->ino_count; 3000e800: e5862004 str r2, [r6, #4] 3000e804: e5842038 str r2, [r4, #56] ; 0x38 return (*node->control->node_initialize)( node, info ); 3000e808: e1a0e00f mov lr, pc 3000e80c: e593f008 ldr pc, [r3, #8] } 3000e810: e28dd008 add sp, sp, #8 3000e814: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} { IMFS_jnode_t *node; struct timeval tv; if ( namelen > IMFS_NAME_MAX ) { errno = ENAMETOOLONG; 3000e818: eb001012 bl 30012868 <__errno> <== NOT EXECUTED 3000e81c: e3a0305b mov r3, #91 ; 0x5b <== NOT EXECUTED 3000e820: e5803000 str r3, [r0] <== NOT EXECUTED return NULL; 3000e824: e3a00000 mov r0, #0 <== NOT EXECUTED 3000e828: eafffff8 b 3000e810 <== NOT EXECUTED /* * Allocate an IMFS jnode */ node = calloc( 1, sizeof( IMFS_jnode_t ) ); if ( !node ) { errno = ENOMEM; 3000e82c: eb00100d bl 30012868 <__errno> 3000e830: e3a0300c mov r3, #12 3000e834: e5803000 str r3, [r0] return NULL; 3000e838: e1a00004 mov r0, r4 3000e83c: eafffff3 b 3000e810 =============================================================================== 3000e6e4 : int IMFS_chown( const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group ) { 3000e6e4: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED 3000e6e8: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED 3000e6ec: e1a02802 lsl r2, r2, #16 <== NOT EXECUTED 3000e6f0: e24dd008 sub sp, sp, #8 <== NOT EXECUTED IMFS_jnode_t *jnode; #if defined(RTEMS_POSIX_API) uid_t st_uid; #endif jnode = (IMFS_jnode_t *) loc->node_access; 3000e6f4: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED int IMFS_chown( const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group ) { 3000e6f8: e1a07821 lsr r7, r1, #16 <== NOT EXECUTED 3000e6fc: e1a06822 lsr r6, r2, #16 <== NOT EXECUTED /* * Verify I am the owner of the node or the super user. */ #if defined(RTEMS_POSIX_API) st_uid = geteuid(); 3000e700: eb000260 bl 3000f088 <== NOT EXECUTED if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) ) 3000e704: e1d453bc ldrh r5, [r4, #60] ; 0x3c <== NOT EXECUTED 3000e708: e3500000 cmp r0, #0 <== NOT EXECUTED 3000e70c: 11550000 cmpne r5, r0 <== NOT EXECUTED 3000e710: 03a05000 moveq r5, #0 <== NOT EXECUTED 3000e714: 13a05001 movne r5, #1 <== NOT EXECUTED 3000e718: 1a000009 bne 3000e744 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EPERM ); #endif jnode->st_uid = owner; 3000e71c: e1c473bc strh r7, [r4, #60] ; 0x3c <== NOT EXECUTED jnode->st_gid = group; 3000e720: e1c463be strh r6, [r4, #62] ; 0x3e <== NOT EXECUTED IMFS_update_ctime( jnode ); 3000e724: e1a0000d mov r0, sp <== NOT EXECUTED 3000e728: e1a01005 mov r1, r5 <== NOT EXECUTED 3000e72c: ebffe03f bl 30006830 <== NOT EXECUTED 3000e730: e59d3000 ldr r3, [sp] <== NOT EXECUTED return 0; 3000e734: e1a00005 mov r0, r5 <== NOT EXECUTED #endif jnode->st_uid = owner; jnode->st_gid = group; IMFS_update_ctime( jnode ); 3000e738: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED return 0; } 3000e73c: e28dd008 add sp, sp, #8 <== NOT EXECUTED 3000e740: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED #if defined(RTEMS_POSIX_API) st_uid = geteuid(); if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) ) rtems_set_errno_and_return_minus_one( EPERM ); 3000e744: eb001047 bl 30012868 <__errno> <== NOT EXECUTED 3000e748: e3a03001 mov r3, #1 <== NOT EXECUTED 3000e74c: e5803000 str r3, [r0] <== NOT EXECUTED 3000e750: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000e754: eafffff8 b 3000e73c <== NOT EXECUTED =============================================================================== 30008754 : */ static void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) { 30008754: e92d41f0 push {r4, r5, r6, r7, r8, lr} */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; 30008758: e5907050 ldr r7, [r0, #80] ; 0x50 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 )); 3000875c: e2808054 add r8, r0, #84 ; 0x54 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 ); 30008760: e1570008 cmp r7, r8 */ static void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) { 30008764: e1a06001 mov r6, r1 30008768: 159f516c ldrne r5, [pc, #364] ; 300088dc 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 ); 3000876c: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} !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++ ) 30008770: e3560000 cmp r6, #0 30008774: a3a04000 movge r4, #0 30008778: ba000008 blt 300087a0 fprintf(stdout, "...." ); 3000877c: e5953000 ldr r3, [r5] 30008780: e3a01001 mov r1, #1 !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++ ) 30008784: e0844001 add r4, r4, r1 fprintf(stdout, "...." ); 30008788: e59f0150 ldr r0, [pc, #336] ; 300088e0 3000878c: e3a02004 mov r2, #4 30008790: e5933008 ldr r3, [r3, #8] 30008794: eb003baa bl 30017644 !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++ ) 30008798: e1560004 cmp r6, r4 3000879c: aafffff6 bge 3000877c IMFS_jnode_t *the_jnode ) { IMFS_assert( the_jnode ); fprintf(stdout, "%s", the_jnode->name ); 300087a0: e5953000 ldr r3, [r5] 300087a4: e287000c add r0, r7, #12 300087a8: e5931008 ldr r1, [r3, #8] 300087ac: eb003893 bl 30016a00 rtems_chain_extract_unprotected( &node->Node ); } static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node ) { return node->control->imfs_type; 300087b0: e597304c ldr r3, [r7, #76] ; 0x4c 300087b4: e5932000 ldr r2, [r3] switch( IMFS_type( the_jnode ) ) { 300087b8: e3520006 cmp r2, #6 300087bc: 979ff102 ldrls pc, [pc, r2, lsl #2] 300087c0: ea000033 b 30008894 <== NOT EXECUTED 300087c4: 30008880 .word 0x30008880 <== NOT EXECUTED 300087c8: 3000885c .word 0x3000885c <== NOT EXECUTED 300087cc: 300087e0 .word 0x300087e0 <== NOT EXECUTED 300087d0: 300087e0 .word 0x300087e0 <== NOT EXECUTED 300087d4: 300088c4 .word 0x300088c4 <== NOT EXECUTED 300087d8: 300088a8 .word 0x300088a8 <== NOT EXECUTED 300087dc: 30008818 .word 0x30008818 <== NOT EXECUTED case IMFS_HARD_LINK: fprintf(stdout, " links not printed\n" ); return; case IMFS_SYM_LINK: fprintf(stdout, " links not printed\n" ); 300087e0: e5953000 ldr r3, [r5] <== NOT EXECUTED 300087e4: e3a01001 mov r1, #1 <== NOT EXECUTED 300087e8: e3a02013 mov r2, #19 <== NOT EXECUTED 300087ec: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED 300087f0: e59f00ec ldr r0, [pc, #236] ; 300088e4 <== NOT EXECUTED 300087f4: eb003b92 bl 30017644 <== NOT EXECUTED } static inline bool IMFS_is_directory( const IMFS_jnode_t *node ) { return node->control->imfs_type == IMFS_DIRECTORY; 300087f8: e597304c ldr r3, [r7, #76] ; 0x4c 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 ) ) 300087fc: e5933000 ldr r3, [r3] 30008800: e3530000 cmp r3, #0 30008804: 0a00000d beq 30008840 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 ) { 30008808: e5977000 ldr r7, [r7] 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 ); 3000880c: e1570008 cmp r7, r8 30008810: 1affffd6 bne 30008770 30008814: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} case IMFS_SYM_LINK: fprintf(stdout, " links not printed\n" ); return; case IMFS_FIFO: fprintf(stdout, " FIFO not printed\n" ); 30008818: e5953000 ldr r3, [r5] <== NOT EXECUTED 3000881c: e3a01001 mov r1, #1 <== NOT EXECUTED 30008820: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED 30008824: e3a02012 mov r2, #18 <== NOT EXECUTED 30008828: e59f00b8 ldr r0, [pc, #184] ; 300088e8 <== NOT EXECUTED 3000882c: eb003b84 bl 30017644 <== NOT EXECUTED 30008830: e597304c ldr r3, [r7, #76] ; 0x4c <== NOT EXECUTED 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 ) ) 30008834: e5933000 ldr r3, [r3] <== NOT EXECUTED 30008838: e3530000 cmp r3, #0 <== NOT EXECUTED 3000883c: 1afffff1 bne 30008808 <== NOT EXECUTED IMFS_dump_directory( the_jnode, level + 1 ); 30008840: e1a00007 mov r0, r7 30008844: e2861001 add r1, r6, #1 30008848: ebffffc1 bl 30008754 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 ) { 3000884c: e5977000 ldr r7, [r7] 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 ); 30008850: e1570008 cmp r7, r8 30008854: 1affffc5 bne 30008770 30008858: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} case IMFS_DIRECTORY: fprintf(stdout, "/" ); break; case IMFS_DEVICE: fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")", 3000885c: e5953000 ldr r3, [r5] 30008860: e59f1084 ldr r1, [pc, #132] ; 300088ec 30008864: e5930008 ldr r0, [r3, #8] 30008868: e5972050 ldr r2, [r7, #80] ; 0x50 3000886c: e5973054 ldr r3, [r7, #84] ; 0x54 30008870: eb00380d bl 300168ac default: fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) ); return; } puts(""); 30008874: e59f0074 ldr r0, [pc, #116] ; 300088f0 30008878: eb003f5e bl 300185f8 3000887c: eaffffdd b 300087f8 IMFS_assert( the_jnode ); fprintf(stdout, "%s", the_jnode->name ); switch( IMFS_type( the_jnode ) ) { case IMFS_DIRECTORY: fprintf(stdout, "/" ); 30008880: e5953000 ldr r3, [r5] 30008884: e3a0002f mov r0, #47 ; 0x2f 30008888: e5931008 ldr r1, [r3, #8] 3000888c: eb003826 bl 3001692c 30008890: eafffff7 b 30008874 case IMFS_FIFO: fprintf(stdout, " FIFO not printed\n" ); return; default: fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) ); 30008894: e5953000 ldr r3, [r5] <== NOT EXECUTED 30008898: e59f1054 ldr r1, [pc, #84] ; 300088f4 <== NOT EXECUTED 3000889c: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 300088a0: eb003801 bl 300168ac <== NOT EXECUTED 300088a4: eaffffd3 b 300087f8 <== NOT EXECUTED fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")", the_jnode->info.device.major, the_jnode->info.device.minor ); break; case IMFS_LINEAR_FILE: fprintf(stdout, " (file %" PRId32 " %p)", 300088a8: e5953000 ldr r3, [r5] 300088ac: e59f1044 ldr r1, [pc, #68] ; 300088f8 300088b0: e5930008 ldr r0, [r3, #8] 300088b4: e5972050 ldr r2, [r7, #80] ; 0x50 300088b8: e5973058 ldr r3, [r7, #88] ; 0x58 300088bc: eb0037fa bl 300168ac 300088c0: eaffffeb b 30008874 the_jnode->info.file.indirect, the_jnode->info.file.doubly_indirect, the_jnode->info.file.triply_indirect ); #else fprintf(stdout, " (file %" PRId32 ")", 300088c4: e5953000 ldr r3, [r5] <== NOT EXECUTED 300088c8: e59f102c ldr r1, [pc, #44] ; 300088fc <== NOT EXECUTED 300088cc: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 300088d0: e5972050 ldr r2, [r7, #80] ; 0x50 <== NOT EXECUTED 300088d4: eb0037f4 bl 300168ac <== NOT EXECUTED 300088d8: eaffffe5 b 30008874 <== NOT EXECUTED =============================================================================== 3000e8b0 : rtems_filesystem_eval_path_context_t *ctx, void *arg, const char *token, size_t tokenlen ) { 3000e8b0: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 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; 3000e8b4: e5905020 ldr r5, [r0, #32] rtems_filesystem_eval_path_context_t *ctx, void *arg, const char *token, size_t tokenlen ) { 3000e8b8: e24dd004 sub sp, sp, #4 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; bool access_ok = rtems_filesystem_eval_path_check_access( 3000e8bc: e1d5e3bc ldrh lr, [r5, #60] ; 0x3c 3000e8c0: e1d5c3be ldrh ip, [r5, #62] ; 0x3e rtems_filesystem_eval_path_context_t *ctx, void *arg, const char *token, size_t tokenlen ) { 3000e8c4: e1a07002 mov r7, r2 3000e8c8: e1a04003 mov r4, r3 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; bool access_ok = rtems_filesystem_eval_path_check_access( 3000e8cc: e5952030 ldr r2, [r5, #48] ; 0x30 3000e8d0: e3a01001 mov r1, #1 3000e8d4: e1a0300e mov r3, lr rtems_filesystem_eval_path_context_t *ctx, void *arg, const char *token, size_t tokenlen ) { 3000e8d8: e1a06000 mov r6, r0 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; bool access_ok = rtems_filesystem_eval_path_check_access( 3000e8dc: e58dc000 str ip, [sp] 3000e8e0: eb0002ff bl 3000f4e4 dir->st_mode, dir->st_uid, dir->st_gid ); if ( access_ok ) { 3000e8e4: e3500000 cmp r0, #0 3000e8e8: 0a000038 beq 3000e9d0 static inline bool rtems_filesystem_is_current_directory( const char *token, size_t tokenlen ) { return tokenlen == 1 && token [0] == '.'; 3000e8ec: e3540001 cmp r4, #1 3000e8f0: 0a000039 beq 3000e9dc static inline bool rtems_filesystem_is_parent_directory( const char *token, size_t tokenlen ) { return tokenlen == 2 && token [0] == '.' && token [1] == '.'; 3000e8f4: e3540002 cmp r4, #2 3000e8f8: 0a000051 beq 3000ea44 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; 3000e8fc: e5958050 ldr r8, [r5, #80] ; 0x50 if ( rtems_filesystem_is_parent_directory( token, tokenlen ) ) { return dir->Parent; } 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 ); 3000e900: e285a054 add sl, r5, #84 ; 0x54 while ( current != tail ) { 3000e904: e158000a cmp r8, sl 3000e908: 0a00002e beq 3000e9c8 IMFS_jnode_t *entry = (IMFS_jnode_t *) current; bool match = strncmp( entry->name, token, tokenlen ) == 0 3000e90c: e288000c add r0, r8, #12 3000e910: e1a01007 mov r1, r7 3000e914: e1a02004 mov r2, r4 3000e918: eb0015a6 bl 30013fb8 && entry->name [tokenlen] == '\0'; 3000e91c: e3500000 cmp r0, #0 3000e920: e0883004 add r3, r8, r4 3000e924: 1a000024 bne 3000e9bc 3000e928: e5d3300c ldrb r3, [r3, #12] 3000e92c: e3530000 cmp r3, #0 3000e930: 1a000021 bne 3000e9bc ); if ( access_ok ) { IMFS_jnode_t *entry = IMFS_search_in_directory( dir, token, tokenlen ); if ( entry != NULL ) { 3000e934: e3580000 cmp r8, #0 3000e938: 0a000022 beq 3000e9c8 rtems_chain_extract_unprotected( &node->Node ); } static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node ) { return node->control->imfs_type; 3000e93c: e598304c ldr r3, [r8, #76] ; 0x4c bool terminal = !rtems_filesystem_eval_path_has_path( ctx ); 3000e940: e5960004 ldr r0, [r6, #4] 3000e944: e5933000 ldr r3, [r3] 3000e948: e2700001 rsbs r0, r0, #1 3000e94c: 33a00000 movcc r0, #0 static inline void rtems_filesystem_eval_path_clear_token( rtems_filesystem_eval_path_context_t *ctx ) { ctx->tokenlen = 0; 3000e950: e3a02000 mov r2, #0 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)) { 3000e954: e3530002 cmp r3, #2 static inline int rtems_filesystem_eval_path_get_flags( const rtems_filesystem_eval_path_context_t *ctx ) { return ctx->flags; 3000e958: e5961010 ldr r1, [r6, #16] static inline void rtems_filesystem_eval_path_clear_token( rtems_filesystem_eval_path_context_t *ctx ) { ctx->tokenlen = 0; 3000e95c: e586200c str r2, [r6, #12] 3000e960: 0a000031 beq 3000ea2c entry = entry->info.hard_link.link_node; } if ( type == IMFS_SYM_LINK && (follow_sym_link || !terminal)) { 3000e964: e3530003 cmp r3, #3 3000e968: 0a000020 beq 3000e9f0 IMFS_jnode_types_t type ) { rtems_filesystem_global_location_t **fs_root_ptr = NULL; if ( type == IMFS_DIRECTORY ) { 3000e96c: e3530000 cmp r3, #0 3000e970: 1a000022 bne 3000ea00 if ( node->info.directory.mt_fs != NULL ) { 3000e974: e598c05c ldr ip, [r8, #92] ; 0x5c 3000e978: e35c0000 cmp ip, #0 3000e97c: 0a00001f beq 3000ea00 if ( !terminal ) { status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE; } } else { access_ok = rtems_filesystem_eval_path_check_access( 3000e980: e1d8e3be ldrh lr, [r8, #62] ; 0x3e 3000e984: e5982030 ldr r2, [r8, #48] ; 0x30 3000e988: e1d833bc ldrh r3, [r8, #60] ; 0x3c 3000e98c: e1a00006 mov r0, r6 3000e990: e3a01001 mov r1, #1 { 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; 3000e994: e28c4024 add r4, ip, #36 ; 0x24 if ( !terminal ) { status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_CONTINUE; } } else { access_ok = rtems_filesystem_eval_path_check_access( 3000e998: e58de000 str lr, [sp] 3000e99c: eb0002d0 bl 3000f4e4 RTEMS_FS_PERMS_EXEC, entry->st_mode, entry->st_uid, entry->st_gid ); if ( access_ok ) { 3000e9a0: e3500000 cmp r0, #0 3000e9a4: 0a000009 beq 3000e9d0 rtems_filesystem_eval_path_restart( ctx, fs_root_ptr ); 3000e9a8: e1a00006 mov r0, r6 3000e9ac: e1a01004 mov r1, r4 3000e9b0: ebffe46e bl 30007b70 void *arg, const char *token, size_t tokenlen ) { rtems_filesystem_eval_path_generic_status status = 3000e9b4: e3a00001 mov r0, #1 3000e9b8: ea000005 b 3000e9d4 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Next( Chain_Node *the_node ) { return the_node->next; 3000e9bc: e5988000 ldr r8, [r8] } 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 ); while ( current != tail ) { 3000e9c0: e15a0008 cmp sl, r8 3000e9c4: 1affffd0 bne 3000e90c rtems_filesystem_eval_path_restart( ctx, fs_root_ptr ); } } } } else { status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY; 3000e9c8: e3a00002 mov r0, #2 3000e9cc: ea000000 b 3000e9d4 void *arg, const char *token, size_t tokenlen ) { rtems_filesystem_eval_path_generic_status status = 3000e9d0: e3a00001 mov r0, #1 status = RTEMS_FILESYSTEM_EVAL_PATH_GENERIC_NO_ENTRY; } } return status; } 3000e9d4: e28dd004 add sp, sp, #4 3000e9d8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} static inline bool rtems_filesystem_is_current_directory( const char *token, size_t tokenlen ) { return tokenlen == 1 && token [0] == '.'; 3000e9dc: e5d73000 ldrb r3, [r7] 3000e9e0: e353002e cmp r3, #46 ; 0x2e 3000e9e4: 1affffc4 bne 3000e8fc 3000e9e8: e1a08005 mov r8, r5 3000e9ec: eaffffd0 b 3000e934 if ( type == IMFS_HARD_LINK && (follow_hard_link || !terminal)) { entry = entry->info.hard_link.link_node; } if ( type == IMFS_SYM_LINK && (follow_sym_link || !terminal)) { 3000e9f0: e3110010 tst r1, #16 3000e9f4: 1a00001a bne 3000ea64 3000e9f8: e3500000 cmp r0, #0 <== NOT EXECUTED 3000e9fc: 0a000018 beq 3000ea64 <== NOT EXECUTED } else { rtems_filesystem_global_location_t **fs_root_ptr = IMFS_is_mount_point( entry, type ); if ( fs_root_ptr == NULL ) { --dir->reference_count; 3000ea00: e1d523b4 ldrh r2, [r5, #52] ; 0x34 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; 3000ea04: e598304c ldr r3, [r8, #76] ; 0x4c 3000ea08: e2422001 sub r2, r2, #1 3000ea0c: e1c523b4 strh r2, [r5, #52] ; 0x34 ++entry->reference_count; 3000ea10: e1d823b4 ldrh r2, [r8, #52] ; 0x34 3000ea14: e5933004 ldr r3, [r3, #4] 3000ea18: e2822001 add r2, r2, #1 3000ea1c: e1c823b4 strh r2, [r8, #52] ; 0x34 currentloc->node_access = entry; 3000ea20: e5868020 str r8, [r6, #32] 3000ea24: e5863028 str r3, [r6, #40] ; 0x28 3000ea28: eaffffe9 b 3000e9d4 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)) { 3000ea2c: e3110008 tst r1, #8 <== NOT EXECUTED 3000ea30: 1a000001 bne 3000ea3c <== NOT EXECUTED 3000ea34: e1500002 cmp r0, r2 <== NOT EXECUTED 3000ea38: 1afffff0 bne 3000ea00 <== NOT EXECUTED entry = entry->info.hard_link.link_node; 3000ea3c: e5988050 ldr r8, [r8, #80] ; 0x50 <== NOT EXECUTED 3000ea40: eaffffee b 3000ea00 <== NOT EXECUTED static inline bool rtems_filesystem_is_parent_directory( const char *token, size_t tokenlen ) { return tokenlen == 2 && token [0] == '.' && token [1] == '.'; 3000ea44: e5d73000 ldrb r3, [r7] 3000ea48: e353002e cmp r3, #46 ; 0x2e 3000ea4c: 1affffaa bne 3000e8fc 3000ea50: e5d73001 ldrb r3, [r7, #1] 3000ea54: e353002e cmp r3, #46 ; 0x2e { if ( rtems_filesystem_is_current_directory( token, tokenlen ) ) { return dir; } else { if ( rtems_filesystem_is_parent_directory( token, tokenlen ) ) { return dir->Parent; 3000ea58: 05958008 ldreq r8, [r5, #8] 3000ea5c: 1affffa6 bne 3000e8fc 3000ea60: eaffffb3 b 3000e934 if ( type == IMFS_HARD_LINK && (follow_hard_link || !terminal)) { entry = entry->info.hard_link.link_node; } if ( type == IMFS_SYM_LINK && (follow_sym_link || !terminal)) { const char *target = entry->info.sym_link.name; 3000ea64: e5984050 ldr r4, [r8, #80] ; 0x50 rtems_filesystem_eval_path_recursive( ctx, target, strlen( target ) ); 3000ea68: e1a00004 mov r0, r4 3000ea6c: eb001539 bl 30013f58 3000ea70: e1a01004 mov r1, r4 3000ea74: e1a02000 mov r2, r0 3000ea78: e1a00006 mov r0, r6 3000ea7c: ebffe455 bl 30007bd8 void *arg, const char *token, size_t tokenlen ) { rtems_filesystem_eval_path_generic_status status = 3000ea80: e3a00001 mov r0, #1 if ( type == IMFS_HARD_LINK && (follow_hard_link || !terminal)) { entry = entry->info.hard_link.link_node; } if ( type == IMFS_SYM_LINK && (follow_sym_link || !terminal)) { 3000ea84: eaffffd2 b 3000e9d4 =============================================================================== 3000ea98 : int IMFS_fchmod( const rtems_filesystem_location_info_t *loc, mode_t mode ) { 3000ea98: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED 3000ea9c: e24dd008 sub sp, sp, #8 <== NOT EXECUTED IMFS_jnode_t *jnode; #if defined(RTEMS_POSIX_API) uid_t st_uid; #endif jnode = loc->node_access; 3000eaa0: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED int IMFS_fchmod( const rtems_filesystem_location_info_t *loc, mode_t mode ) { 3000eaa4: e1a06001 mov r6, r1 <== NOT EXECUTED /* * Verify I am the owner of the node or the super user. */ #if defined(RTEMS_POSIX_API) st_uid = geteuid(); 3000eaa8: eb000176 bl 3000f088 <== NOT EXECUTED if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) ) 3000eaac: e1d453bc ldrh r5, [r4, #60] ; 0x3c <== NOT EXECUTED 3000eab0: e3500000 cmp r0, #0 <== NOT EXECUTED 3000eab4: 11550000 cmpne r5, r0 <== NOT EXECUTED 3000eab8: 03a05000 moveq r5, #0 <== NOT EXECUTED 3000eabc: 13a05001 movne r5, #1 <== NOT EXECUTED 3000eac0: 1a00000d bne 3000eafc <== NOT EXECUTED /* * Change only the RWX permissions on the jnode to mode. */ jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); 3000eac4: e5943030 ldr r3, [r4, #48] ; 0x30 <== NOT EXECUTED jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); 3000eac8: e1a06a06 lsl r6, r6, #20 <== NOT EXECUTED /* * Change only the RWX permissions on the jnode to mode. */ jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); 3000eacc: e3c33eff bic r3, r3, #4080 ; 0xff0 <== NOT EXECUTED 3000ead0: e3c3300f bic r3, r3, #15 <== NOT EXECUTED jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); 3000ead4: e1836a26 orr r6, r3, r6, lsr #20 <== NOT EXECUTED 3000ead8: e5846030 str r6, [r4, #48] ; 0x30 <== NOT EXECUTED IMFS_update_ctime( jnode ); 3000eadc: e1a0000d mov r0, sp <== NOT EXECUTED 3000eae0: e1a01005 mov r1, r5 <== NOT EXECUTED 3000eae4: ebffdf51 bl 30006830 <== NOT EXECUTED 3000eae8: e59d3000 ldr r3, [sp] <== NOT EXECUTED return 0; 3000eaec: e1a00005 mov r0, r5 <== NOT EXECUTED */ jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); IMFS_update_ctime( jnode ); 3000eaf0: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED return 0; } 3000eaf4: e28dd008 add sp, sp, #8 <== NOT EXECUTED 3000eaf8: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED */ #if defined(RTEMS_POSIX_API) st_uid = geteuid(); if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) ) rtems_set_errno_and_return_minus_one( EPERM ); 3000eafc: eb000f59 bl 30012868 <__errno> <== NOT EXECUTED 3000eb00: e3a03001 mov r3, #1 <== NOT EXECUTED 3000eb04: e5803000 str r3, [r0] <== NOT EXECUTED 3000eb08: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000eb0c: eafffff8 b 3000eaf4 <== NOT EXECUTED =============================================================================== 30006ccc : static int IMFS_fifo_ioctl( rtems_libio_t *iop, ioctl_command_t command, void *buffer ) { 30006ccc: e1a03000 mov r3, r0 int err; if (command == FIONBIO) { 30006cd0: e59f0068 ldr r0, [pc, #104] ; 30006d40 static int IMFS_fifo_ioctl( rtems_libio_t *iop, ioctl_command_t command, void *buffer ) { 30006cd4: e92d4010 push {r4, lr} int err; if (command == FIONBIO) { 30006cd8: e1510000 cmp r1, r0 30006cdc: 0a000007 beq 30006d00 iop->flags &= ~LIBIO_FLAGS_NO_DELAY; return 0; } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop); 30006ce0: e5930018 ldr r0, [r3, #24] <== NOT EXECUTED 30006ce4: e5900050 ldr r0, [r0, #80] ; 0x50 <== NOT EXECUTED 30006ce8: eb002aa1 bl 30011774 <== NOT EXECUTED IMFS_FIFO_RETURN(err); 30006cec: e2502000 subs r2, r0, #0 <== NOT EXECUTED 30006cf0: b2624000 rsblt r4, r2, #0 <== NOT EXECUTED 30006cf4: ba00000d blt 30006d30 <== NOT EXECUTED } 30006cf8: e1a00002 mov r0, r2 <== NOT EXECUTED 30006cfc: e8bd8010 pop {r4, pc} <== NOT EXECUTED ) { int err; if (command == FIONBIO) { if (buffer == NULL) 30006d00: e3520000 cmp r2, #0 30006d04: 0a000008 beq 30006d2c err = -EFAULT; else { if (*(int *)buffer) 30006d08: e5922000 ldr r2, [r2] iop->flags |= LIBIO_FLAGS_NO_DELAY; 30006d0c: e593100c ldr r1, [r3, #12] if (command == FIONBIO) { if (buffer == NULL) err = -EFAULT; else { if (*(int *)buffer) 30006d10: e3520000 cmp r2, #0 iop->flags |= LIBIO_FLAGS_NO_DELAY; 30006d14: 13a02000 movne r2, #0 30006d18: 13811001 orrne r1, r1, #1 else iop->flags &= ~LIBIO_FLAGS_NO_DELAY; 30006d1c: 03c11001 biceq r1, r1, #1 30006d20: e583100c str r1, [r3, #12] } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop); IMFS_FIFO_RETURN(err); } 30006d24: e1a00002 mov r0, r2 30006d28: e8bd8010 pop {r4, pc} ) { int err; if (command == FIONBIO) { if (buffer == NULL) 30006d2c: e3a0400e mov r4, #14 <== NOT EXECUTED } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop); IMFS_FIFO_RETURN(err); 30006d30: eb003736 bl 30014a10 <__errno> <== NOT EXECUTED 30006d34: e3e02000 mvn r2, #0 <== NOT EXECUTED 30006d38: e5804000 str r4, [r0] <== NOT EXECUTED 30006d3c: eaffffed b 30006cf8 <== NOT EXECUTED =============================================================================== 30006c94 : mode_t mode ) { IMFS_jnode_t *jnode = iop->pathinfo.node_access; int err = fifo_open(&JNODE2PIPE(jnode), iop); 30006c94: e5903018 ldr r3, [r0, #24] rtems_libio_t *iop, const char *pathname, int oflag, mode_t mode ) { 30006c98: e92d4010 push {r4, lr} 30006c9c: e1a01000 mov r1, r0 IMFS_jnode_t *jnode = iop->pathinfo.node_access; int err = fifo_open(&JNODE2PIPE(jnode), iop); 30006ca0: e2830050 add r0, r3, #80 ; 0x50 30006ca4: eb0028af bl 30010f68 IMFS_FIFO_RETURN(err); 30006ca8: e2504000 subs r4, r0, #0 30006cac: ba000001 blt 30006cb8 } 30006cb0: e1a00004 mov r0, r4 30006cb4: e8bd8010 pop {r4, pc} ) { IMFS_jnode_t *jnode = iop->pathinfo.node_access; int err = fifo_open(&JNODE2PIPE(jnode), iop); IMFS_FIFO_RETURN(err); 30006cb8: eb003754 bl 30014a10 <__errno> <== NOT EXECUTED 30006cbc: e2644000 rsb r4, r4, #0 <== NOT EXECUTED 30006cc0: e5804000 str r4, [r0] <== NOT EXECUTED 30006cc4: e3e04000 mvn r4, #0 <== NOT EXECUTED 30006cc8: eafffff8 b 30006cb0 <== NOT EXECUTED =============================================================================== 3000eb10 : ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) void IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { 3000eb10: e92d4030 push {r4, r5, lr} /* * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ loc = temp_mt_entry->mt_fs_root->location; 3000eb14: e5905024 ldr r5, [r0, #36] ; 0x24 ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) void IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { 3000eb18: e24dd018 sub sp, sp, #24 /* * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ loc = temp_mt_entry->mt_fs_root->location; 3000eb1c: e1a0c00d mov ip, sp 3000eb20: e1a04005 mov r4, r5 3000eb24: e8b4000f ldm r4!, {r0, r1, r2, r3} 3000eb28: e8ac000f stmia ip!, {r0, r1, r2, r3} 3000eb2c: e8940003 ldm r4, {r0, r1} /* * Set this to null to indicate that it is being unmounted. */ temp_mt_entry->mt_fs_root->location.node_access = NULL; 3000eb30: e592304c ldr r3, [r2, #76] ; 0x4c /* * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ loc = temp_mt_entry->mt_fs_root->location; 3000eb34: e88c0003 stm ip, {r0, r1} /* * Set this to null to indicate that it is being unmounted. */ temp_mt_entry->mt_fs_root->location.node_access = NULL; 3000eb38: e3a01000 mov r1, #0 * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ loc = temp_mt_entry->mt_fs_root->location; jnode = (IMFS_jnode_t *)loc.node_access; 3000eb3c: e1a04002 mov r4, r2 /* * Set this to null to indicate that it is being unmounted. */ temp_mt_entry->mt_fs_root->location.node_access = NULL; 3000eb40: e5932000 ldr r2, [r3] 3000eb44: e5851008 str r1, [r5, #8] 3000eb48: e5933004 ldr r3, [r3, #4] do { next = jnode->Parent; loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc ); if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { 3000eb4c: e3520000 cmp r2, #0 */ temp_mt_entry->mt_fs_root->location.node_access = NULL; do { next = jnode->Parent; 3000eb50: e5945008 ldr r5, [r4, #8] loc.node_access = (void *)jnode; 3000eb54: e58d4008 str r4, [sp, #8] 3000eb58: e58d3010 str r3, [sp, #16] IMFS_Set_handlers( &loc ); if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { 3000eb5c: 1a000018 bne 3000ebc4 3000eb60: e5942050 ldr r2, [r4, #80] ; 0x50 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); 3000eb64: e2843054 add r3, r4, #84 ; 0x54 3000eb68: e1520003 cmp r2, r3 3000eb6c: 0a000014 beq 3000ebc4 if ( result != 0 ) rtems_fatal_error_occurred( 0xdeadbeef ); IMFS_node_destroy( jnode ); jnode = next; } if ( jnode != NULL ) { 3000eb70: e3540000 cmp r4, #0 3000eb74: 0a00001c beq 3000ebec return node->control->imfs_type; } static inline bool IMFS_is_directory( const IMFS_jnode_t *node ) { return node->control->imfs_type == IMFS_DIRECTORY; 3000eb78: e594304c ldr r3, [r4, #76] ; 0x4c 3000eb7c: e5932000 ldr r2, [r3] if ( IMFS_is_directory( jnode ) ) { 3000eb80: e3520000 cmp r2, #0 3000eb84: 1affffef bne 3000eb48 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; 3000eb88: e5941050 ldr r1, [r4, #80] ; 0x50 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); 3000eb8c: e2840054 add r0, r4, #84 ; 0x54 if ( jnode_has_children( jnode ) ) 3000eb90: e1510000 cmp r1, r0 3000eb94: 0affffeb beq 3000eb48 jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL); 3000eb98: e3510000 cmp r1, #0 3000eb9c: 0a000012 beq 3000ebec 3000eba0: e591304c ldr r3, [r1, #76] ; 0x4c 3000eba4: e1a04001 mov r4, r1 3000eba8: e5932000 ldr r2, [r3] 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; 3000ebac: e5933004 ldr r3, [r3, #4] do { next = jnode->Parent; loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc ); if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { 3000ebb0: e3520000 cmp r2, #0 */ temp_mt_entry->mt_fs_root->location.node_access = NULL; do { next = jnode->Parent; 3000ebb4: e5945008 ldr r5, [r4, #8] loc.node_access = (void *)jnode; 3000ebb8: e58d4008 str r4, [sp, #8] 3000ebbc: e58d3010 str r3, [sp, #16] IMFS_Set_handlers( &loc ); if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { 3000ebc0: 0affffe6 beq 3000eb60 result = IMFS_rmnod( NULL, &loc ); 3000ebc4: e3a00000 mov r0, #0 3000ebc8: e1a0100d mov r1, sp 3000ebcc: ebffddbc bl 300062c4 if ( result != 0 ) 3000ebd0: e3500000 cmp r0, #0 3000ebd4: 1a000006 bne 3000ebf4 rtems_fatal_error_occurred( 0xdeadbeef ); IMFS_node_destroy( jnode ); 3000ebd8: e1a00004 mov r0, r4 jnode = next; 3000ebdc: e1a04005 mov r4, r5 if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { result = IMFS_rmnod( NULL, &loc ); if ( result != 0 ) rtems_fatal_error_occurred( 0xdeadbeef ); IMFS_node_destroy( jnode ); 3000ebe0: ebffdce5 bl 30005f7c jnode = next; } if ( jnode != NULL ) { 3000ebe4: e3540000 cmp r4, #0 3000ebe8: 1affffe2 bne 3000eb78 if ( jnode_has_children( jnode ) ) jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL); } 3000ebec: e28dd018 add sp, sp, #24 3000ebf0: e8bd8030 pop {r4, r5, pc} IMFS_Set_handlers( &loc ); if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { result = IMFS_rmnod( NULL, &loc ); if ( result != 0 ) rtems_fatal_error_occurred( 0xdeadbeef ); 3000ebf4: e59f0000 ldr r0, [pc] ; 3000ebfc <== NOT EXECUTED 3000ebf8: ebfff0fa bl 3000afe8 <== NOT EXECUTED =============================================================================== 30005e54 : 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] ) { 30005e54: e92d41f0 push {r4, r5, r6, r7, r8, lr} 30005e58: e1a05000 mov r5, r0 30005e5c: e24dd008 sub sp, sp, #8 30005e60: e1a07001 mov r7, r1 static int imfs_instance; int rv = 0; IMFS_fs_info_t *fs_info = calloc( 1, sizeof( *fs_info ) ); 30005e64: e3a00001 mov r0, #1 30005e68: e3a01024 mov r1, #36 ; 0x24 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] ) { 30005e6c: e1a08002 mov r8, r2 static int imfs_instance; int rv = 0; IMFS_fs_info_t *fs_info = calloc( 1, sizeof( *fs_info ) ); 30005e70: eb0001a8 bl 30006518 if ( fs_info != NULL ) { 30005e74: e2504000 subs r4, r0, #0 30005e78: 0a00002f beq 30005f3c IMFS_jnode_t *root_node; fs_info->instance = imfs_instance++; 30005e7c: e59f60cc ldr r6, [pc, #204] ; 30005f50 30005e80: e1a00004 mov r0, r4 30005e84: e5963000 ldr r3, [r6] memcpy( 30005e88: e1a01008 mov r1, r8 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++; 30005e8c: e4803008 str r3, [r0], #8 memcpy( 30005e90: e3a0201c mov r2, #28 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++; 30005e94: e2833001 add r3, r3, #1 30005e98: e5863000 str r3, [r6] memcpy( 30005e9c: eb0034ab bl 30013150 fs_info->node_controls, node_controls, sizeof( fs_info->node_controls ) ); root_node = IMFS_allocate_node( 30005ea0: e3a0c000 mov ip, #0 30005ea4: e59fe0a8 ldr lr, [pc, #168] ; 30005f54 30005ea8: e5941008 ldr r1, [r4, #8] 30005eac: e1a00004 mov r0, r4 30005eb0: e59f20a0 ldr r2, [pc, #160] ; 30005f58 30005eb4: e1a0300c mov r3, ip 30005eb8: e58de000 str lr, [sp] 30005ebc: e58dc004 str ip, [sp, #4] 30005ec0: eb002224 bl 3000e758 "", 0, (S_IFDIR | 0755), NULL ); if ( root_node != NULL ) { 30005ec4: e3500000 cmp r0, #0 30005ec8: 0a00001b beq 30005f3c errno = ENOMEM; rv = -1; } if ( rv == 0 ) { IMFS_determine_bytes_per_block( 30005ecc: e59f3088 ldr r3, [pc, #136] ; 30005f5c 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; 30005ed0: e590104c ldr r1, [r0, #76] ; 0x4c 30005ed4: e5932000 ldr r2, [r3] 30005ed8: e5911004 ldr r1, [r1, #4] ); if ( root_node != NULL ) { mt_entry->fs_info = fs_info; 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; 30005edc: e5953024 ldr r3, [r5, #36] ; 0x24 NULL ); if ( root_node != NULL ) { mt_entry->fs_info = fs_info; mt_entry->ops = op_table; mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS; 30005ee0: e59fc078 ldr ip, [pc, #120] ; 30005f60 /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { if (bit_mask == requested_bytes_per_block) { 30005ee4: e3520010 cmp r2, #16 0, (S_IFDIR | 0755), NULL ); if ( root_node != NULL ) { mt_entry->fs_info = fs_info; 30005ee8: e5854008 str r4, [r5, #8] mt_entry->ops = op_table; 30005eec: e585700c str r7, [r5, #12] mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS; 30005ef0: e585c02c str ip, [r5, #44] ; 0x2c mt_entry->mt_fs_root->location.node_access = root_node; 30005ef4: e5830008 str r0, [r3, #8] 30005ef8: e5831010 str r1, [r3, #16] /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { if (bit_mask == requested_bytes_per_block) { 30005efc: 0a00000a beq 30005f2c is_valid = true; break; } if(bit_mask > requested_bytes_per_block) 30005f00: e352000f cmp r2, #15 30005f04: c3a01005 movgt r1, #5 30005f08: c3a03020 movgt r3, #32 30005f0c: da000005 ble 30005f28 /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { if (bit_mask == requested_bytes_per_block) { 30005f10: e1520003 cmp r2, r3 30005f14: 0a000004 beq 30005f2c is_valid = true; break; } if(bit_mask > requested_bytes_per_block) 30005f18: ba000002 blt 30005f28 int bit_mask; /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { 30005f1c: e2511001 subs r1, r1, #1 30005f20: e1a03083 lsl r3, r3, #1 30005f24: 1afffff9 bne 30005f10 if(bit_mask > requested_bytes_per_block) break; } *dest_bytes_per_block = ((is_valid) ? requested_bytes_per_block : default_bytes_per_block); 30005f28: e3a02080 mov r2, #128 ; 0x80 break; } if(bit_mask > requested_bytes_per_block) break; } *dest_bytes_per_block = ((is_valid) 30005f2c: e5862004 str r2, [r6, #4] const IMFS_node_control *const node_controls [IMFS_TYPE_COUNT] ) { static int imfs_instance; int rv = 0; 30005f30: e3a00000 mov r0, #0 IMFS_MEMFILE_DEFAULT_BYTES_PER_BLOCK ); } return rv; } 30005f34: e28dd008 add sp, sp, #8 30005f38: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} } else { errno = ENOMEM; rv = -1; } } else { errno = ENOMEM; 30005f3c: eb003249 bl 30012868 <__errno> <== NOT EXECUTED 30005f40: e3a0300c mov r3, #12 <== NOT EXECUTED 30005f44: e5803000 str r3, [r0] <== NOT EXECUTED 30005f48: e3e00000 mvn r0, #0 <== NOT EXECUTED 30005f4c: eafffff8 b 30005f34 <== NOT EXECUTED =============================================================================== 30007ca4 : bool IMFS_is_imfs_instance( const rtems_filesystem_location_info_t *loc ) { const char *type = loc->mt_entry->type; 30007ca4: e5903014 ldr r3, [r0, #20] } bool IMFS_is_imfs_instance( const rtems_filesystem_location_info_t *loc ) { 30007ca8: e92d4010 push {r4, lr} const char *type = loc->mt_entry->type; 30007cac: e5934034 ldr r4, [r3, #52] ; 0x34 return strcmp(type, RTEMS_FILESYSTEM_TYPE_IMFS) == 0 30007cb0: e59f102c ldr r1, [pc, #44] ; 30007ce4 30007cb4: e1a00004 mov r0, r4 30007cb8: eb004230 bl 30018580 || strcmp(type, RTEMS_FILESYSTEM_TYPE_MINIIMFS) == 0; 30007cbc: e3500000 cmp r0, #0 30007cc0: 0a000005 beq 30007cdc 30007cc4: e1a00004 mov r0, r4 <== NOT EXECUTED 30007cc8: e59f1018 ldr r1, [pc, #24] ; 30007ce8 <== NOT EXECUTED 30007ccc: eb00422b bl 30018580 <== NOT EXECUTED 30007cd0: e2700001 rsbs r0, r0, #1 <== NOT EXECUTED 30007cd4: 33a00000 movcc r0, #0 <== NOT EXECUTED 30007cd8: e8bd8010 pop {r4, pc} <== NOT EXECUTED 30007cdc: e3a00001 mov r0, #1 } 30007ce0: e8bd8010 pop {r4, pc} =============================================================================== 30005fb0 : const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *targetloc, const char *name, size_t namelen ) { 30005fb0: e92d4010 push {r4, lr} <== NOT EXECUTED IMFS_types_union info; IMFS_jnode_t *new_node; IMFS_jnode_t *target; target = targetloc->node_access; 30005fb4: e5914008 ldr r4, [r1, #8] <== NOT EXECUTED const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *targetloc, const char *name, size_t namelen ) { 30005fb8: e24dd024 sub sp, sp, #36 ; 0x24 <== NOT EXECUTED info.hard_link.link_node = target; /* * Verify this node can be linked to. */ if ( target->st_nlink >= LINK_MAX ) 30005fbc: e1d413b6 ldrh r1, [r4, #54] ; 0x36 <== NOT EXECUTED IMFS_types_union info; IMFS_jnode_t *new_node; IMFS_jnode_t *target; target = targetloc->node_access; info.hard_link.link_node = target; 30005fc0: e58d4008 str r4, [sp, #8] <== NOT EXECUTED /* * Verify this node can be linked to. */ if ( target->st_nlink >= LINK_MAX ) 30005fc4: e3510007 cmp r1, #7 <== NOT EXECUTED 30005fc8: 8a000017 bhi 3000602c <== NOT EXECUTED size_t namelen, mode_t mode, const IMFS_types_union *info ) { const IMFS_fs_info_t *fs_info = 30005fcc: e5901014 ldr r1, [r0, #20] <== NOT EXECUTED (const IMFS_fs_info_t *) parentloc->mt_entry->fs_info; return IMFS_create_node_with_control( 30005fd0: e59fc07c ldr ip, [pc, #124] ; 30006054 <== NOT EXECUTED 30005fd4: e5911008 ldr r1, [r1, #8] <== NOT EXECUTED 30005fd8: e5911010 ldr r1, [r1, #16] <== NOT EXECUTED 30005fdc: e58dc000 str ip, [sp] <== NOT EXECUTED 30005fe0: e28dc008 add ip, sp, #8 <== NOT EXECUTED 30005fe4: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 30005fe8: eb002214 bl 3000e840 <== NOT EXECUTED namelen, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if ( !new_node ) 30005fec: e3500000 cmp r0, #0 <== NOT EXECUTED 30005ff0: 0a000012 beq 30006040 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOMEM ); /* * Increment the link count of the node being pointed to. */ target->reference_count++; 30005ff4: e1d423b4 ldrh r2, [r4, #52] ; 0x34 <== NOT EXECUTED target->st_nlink++; 30005ff8: e1d433b6 ldrh r3, [r4, #54] ; 0x36 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOMEM ); /* * Increment the link count of the node being pointed to. */ target->reference_count++; 30005ffc: e2822001 add r2, r2, #1 <== NOT EXECUTED target->st_nlink++; 30006000: e2833001 add r3, r3, #1 <== NOT EXECUTED 30006004: e1c433b6 strh r3, [r4, #54] ; 0x36 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( ENOMEM ); /* * Increment the link count of the node being pointed to. */ target->reference_count++; 30006008: e1c423b4 strh r2, [r4, #52] ; 0x34 <== NOT EXECUTED target->st_nlink++; IMFS_update_ctime( target ); 3000600c: e28d001c add r0, sp, #28 <== NOT EXECUTED 30006010: e3a01000 mov r1, #0 <== NOT EXECUTED 30006014: eb000205 bl 30006830 <== NOT EXECUTED 30006018: e59d301c ldr r3, [sp, #28] <== NOT EXECUTED return 0; 3000601c: e3a00000 mov r0, #0 <== NOT EXECUTED /* * Increment the link count of the node being pointed to. */ target->reference_count++; target->st_nlink++; IMFS_update_ctime( target ); 30006020: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED return 0; } 30006024: e28dd024 add sp, sp, #36 ; 0x24 <== NOT EXECUTED 30006028: e8bd8010 pop {r4, pc} <== NOT EXECUTED /* * Verify this node can be linked to. */ if ( target->st_nlink >= LINK_MAX ) rtems_set_errno_and_return_minus_one( EMLINK ); 3000602c: eb00320d bl 30012868 <__errno> <== NOT EXECUTED 30006030: e3a0301f mov r3, #31 <== NOT EXECUTED 30006034: e5803000 str r3, [r0] <== NOT EXECUTED 30006038: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000603c: eafffff8 b 30006024 <== NOT EXECUTED ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if ( !new_node ) rtems_set_errno_and_return_minus_one( ENOMEM ); 30006040: eb003208 bl 30012868 <__errno> <== NOT EXECUTED 30006044: e3a0300c mov r3, #12 <== NOT EXECUTED 30006048: e5803000 str r3, [r0] <== NOT EXECUTED 3000604c: e3e00000 mvn r0, #0 <== NOT EXECUTED 30006050: eafffff3 b 30006024 <== NOT EXECUTED =============================================================================== 30007cec : void *context ) { int rv = 0; mode &= ~rtems_filesystem_umask; 30007cec: e59fc108 ldr ip, [pc, #264] ; 30007dfc const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { 30007cf0: e92d40f0 push {r4, r5, r6, r7, lr} int rv = 0; mode &= ~rtems_filesystem_umask; 30007cf4: e59cc000 ldr ip, [ip] const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { 30007cf8: e1a06003 mov r6, r3 int rv = 0; mode &= ~rtems_filesystem_umask; 30007cfc: e59c4008 ldr r4, [ip, #8] const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { 30007d00: e24dd05c sub sp, sp, #92 ; 0x5c int rv = 0; mode &= ~rtems_filesystem_umask; 30007d04: e1c14004 bic r4, r1, r4 switch (mode & S_IFMT) { 30007d08: e2043a0f and r3, r4, #61440 ; 0xf000 30007d0c: e3530a02 cmp r3, #8192 ; 0x2000 const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { 30007d10: e1a05002 mov r5, r2 int rv = 0; mode &= ~rtems_filesystem_umask; switch (mode & S_IFMT) { 30007d14: 0a00000d beq 30007d50 30007d18: 8a000008 bhi 30007d40 30007d1c: e3530a01 cmp r3, #4096 ; 0x1000 <== NOT EXECUTED 30007d20: 0a00000a beq 30007d50 <== NOT EXECUTED rv = -1; } rtems_filesystem_eval_path_cleanup( &ctx ); } else { errno = EINVAL; 30007d24: eb003e6b bl 300176d8 <__errno> <== NOT EXECUTED 30007d28: e3a03016 mov r3, #22 <== NOT EXECUTED 30007d2c: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; 30007d30: e3e05000 mvn r5, #0 <== NOT EXECUTED } } return rv; } 30007d34: e1a00005 mov r0, r5 30007d38: e28dd05c add sp, sp, #92 ; 0x5c 30007d3c: e8bd80f0 pop {r4, r5, r6, r7, pc} { int rv = 0; mode &= ~rtems_filesystem_umask; switch (mode & S_IFMT) { 30007d40: e3530a06 cmp r3, #24576 ; 0x6000 30007d44: 0a000001 beq 30007d50 30007d48: e3530902 cmp r3, #32768 ; 0x8000 <== NOT EXECUTED 30007d4c: 1afffff4 bne 30007d24 <== NOT EXECUTED rv = -1; break; } if ( rv == 0 ) { if ( node_control->imfs_type == IMFS_GENERIC ) { 30007d50: e5953000 ldr r3, [r5] 30007d54: e3530007 cmp r3, #7 30007d58: 1afffff1 bne 30007d24 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 = 30007d5c: e1a01000 mov r1, r0 30007d60: e3a02078 mov r2, #120 ; 0x78 30007d64: e28d0008 add r0, sp, #8 30007d68: eb0007fc bl 30009d60 30007d6c: e1a07000 mov r7, r0 rtems_filesystem_eval_path_start( &ctx, path, eval_flags ); if ( IMFS_is_imfs_instance( currentloc ) ) { 30007d70: ebffffcb bl 30007ca4 30007d74: e3500000 cmp r0, #0 30007d78: 0a00001a beq 30007de8 IMFS_types_union info; IMFS_jnode_t *new_node; info.generic.context = context; new_node = IMFS_create_node_with_control( 30007d7c: e1a01005 mov r1, r5 30007d80: e28dc040 add ip, sp, #64 ; 0x40 30007d84: e1a00007 mov r0, r7 30007d88: e59d2010 ldr r2, [sp, #16] 30007d8c: e59d3014 ldr r3, [sp, #20] if ( IMFS_is_imfs_instance( currentloc ) ) { IMFS_types_union info; IMFS_jnode_t *new_node; info.generic.context = context; 30007d90: e58d6040 str r6, [sp, #64] ; 0x40 new_node = IMFS_create_node_with_control( 30007d94: e58d4000 str r4, [sp] 30007d98: e58dc004 str ip, [sp, #4] 30007d9c: eb002e2d bl 30013658 rtems_filesystem_eval_path_get_tokenlen( &ctx ), mode, &info ); if ( new_node != NULL ) { 30007da0: e3500000 cmp r0, #0 IMFS_jnode_t *parent = currentloc->node_access; IMFS_update_ctime( parent ); IMFS_update_mtime( parent ); } else { rv = -1; 30007da4: 03e05000 mvneq r5, #0 rtems_filesystem_eval_path_get_tokenlen( &ctx ), mode, &info ); if ( new_node != NULL ) { 30007da8: 0a00000b beq 30007ddc IMFS_jnode_t *parent = currentloc->node_access; IMFS_update_ctime( parent ); 30007dac: e3a01000 mov r1, #0 30007db0: e28d0054 add r0, sp, #84 ; 0x54 mode, &info ); if ( new_node != NULL ) { IMFS_jnode_t *parent = currentloc->node_access; 30007db4: e5974008 ldr r4, [r7, #8] IMFS_update_ctime( parent ); 30007db8: eb000266 bl 30008758 30007dbc: e59d3054 ldr r3, [sp, #84] ; 0x54 IMFS_update_mtime( parent ); 30007dc0: e28d0054 add r0, sp, #84 ; 0x54 ); if ( new_node != NULL ) { IMFS_jnode_t *parent = currentloc->node_access; IMFS_update_ctime( parent ); 30007dc4: e5843048 str r3, [r4, #72] ; 0x48 IMFS_update_mtime( parent ); 30007dc8: e3a01000 mov r1, #0 30007dcc: eb000261 bl 30008758 30007dd0: e59d3054 ldr r3, [sp, #84] ; 0x54 30007dd4: e3a05000 mov r5, #0 30007dd8: e5843044 str r3, [r4, #68] ; 0x44 } else { rtems_filesystem_eval_path_error( &ctx, ENOTSUP ); rv = -1; } rtems_filesystem_eval_path_cleanup( &ctx ); 30007ddc: e28d0008 add r0, sp, #8 30007de0: eb0007e8 bl 30009d88 30007de4: eaffffd2 b 30007d34 IMFS_update_mtime( parent ); } else { rv = -1; } } else { rtems_filesystem_eval_path_error( &ctx, ENOTSUP ); 30007de8: e28d0008 add r0, sp, #8 <== NOT EXECUTED 30007dec: e3a01086 mov r1, #134 ; 0x86 <== NOT EXECUTED 30007df0: eb000719 bl 30009a5c <== NOT EXECUTED rv = -1; 30007df4: e3e05000 mvn r5, #0 <== NOT EXECUTED 30007df8: eafffff7 b 30007ddc <== NOT EXECUTED =============================================================================== 3001160c : MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { 3001160c: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 30011610: e24dd018 sub sp, sp, #24 30011614: e88d000c stm sp, {r2, r3} IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Verify new file size is supported */ if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) 30011618: e59f218c ldr r2, [pc, #396] ; 300117ac 3001161c: e3a05000 mov r5, #0 30011620: e5928000 ldr r8, [r2] MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { 30011624: e1a06000 mov r6, r0 IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Verify new file size is supported */ if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) 30011628: e1a03128 lsr r3, r8, #2 3001162c: e0223393 mla r2, r3, r3, r3 30011630: e0233392 mla r3, r2, r3, r3 30011634: e2433001 sub r3, r3, #1 30011638: e0030398 mul r3, r8, r3 3001163c: e1a04003 mov r4, r3 30011640: e89d000c ldm sp, {r2, r3} 30011644: e1520004 cmp r2, r4 30011648: e0d33005 sbcs r3, r3, r5 MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { 3001164c: e20190ff and r9, r1, #255 ; 0xff IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Verify new file size is supported */ if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) 30011650: aa000050 bge 30011798 rtems_set_errno_and_return_minus_one( EFBIG ); /* * Verify new file size is actually larger than current size */ if ( new_length <= the_jnode->info.file.size ) 30011654: e2802050 add r2, r0, #80 ; 0x50 30011658: e8920006 ldm r2, {r1, r2} 3001165c: e89d0018 ldm sp, {r3, r4} 30011660: e1510003 cmp r1, r3 30011664: e0d24004 sbcs r4, r2, r4 30011668: e58d1008 str r1, [sp, #8] 3001166c: e58d200c str r2, [sp, #12] return 0; 30011670: a3a00000 movge r0, #0 rtems_set_errno_and_return_minus_one( EFBIG ); /* * Verify new file size is actually larger than current size */ if ( new_length <= the_jnode->info.file.size ) 30011674: aa00003a bge 30011764 return 0; /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK; 30011678: e1a05fc8 asr r5, r8, #31 3001167c: e1a02008 mov r2, r8 30011680: e1a03005 mov r3, r5 30011684: e89d0003 ldm sp, {r0, r1} 30011688: eb002b6f bl 3001c44c <__divdi3> old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK; 3001168c: e1a02008 mov r2, r8 return 0; /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK; 30011690: e1a0a000 mov sl, r0 old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK; 30011694: e1a03005 mov r3, r5 30011698: e28d1008 add r1, sp, #8 3001169c: e8910003 ldm r1, {r0, r1} 300116a0: eb002b69 bl 3001c44c <__divdi3> 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++ ) { 300116a4: e15a0000 cmp sl, r0 /* * 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; 300116a8: e1a0b000 mov fp, r0 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++ ) { 300116ac: 3a00001e bcc 3001172c /* * 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; 300116b0: e0080890 mul r8, r0, r8 300116b4: e59d1008 ldr r1, [sp, #8] 300116b8: e1a04000 mov r4, r0 300116bc: e0688001 rsb r8, r8, r1 300116c0: ea000002 b 300116d0 /* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) { 300116c4: e2844001 add r4, r4, #1 300116c8: e15a0004 cmp sl, r4 300116cc: 3a000016 bcc 3001172c if ( !IMFS_memfile_addblock( the_jnode, block ) ) { 300116d0: e1a01004 mov r1, r4 300116d4: e1a00006 mov r0, r6 300116d8: ebffff48 bl 30011400 300116dc: e2505000 subs r5, r0, #0 300116e0: 1a000025 bne 3001177c if ( zero_fill ) { 300116e4: e3590000 cmp r9, #0 300116e8: 0afffff5 beq 300116c4 size_t count = IMFS_MEMFILE_BYTES_PER_BLOCK - offset; 300116ec: e59f20b8 ldr r2, [pc, #184] ; 300117ac <== NOT EXECUTED block_p *block_ptr = 300116f0: e1a01004 mov r1, r4 <== NOT EXECUTED * 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; 300116f4: e5927000 ldr r7, [r2] <== NOT EXECUTED block_p *block_ptr = 300116f8: e1a00006 mov r0, r6 <== NOT EXECUTED 300116fc: e1a02005 mov r2, r5 <== NOT EXECUTED 30011700: ebfffe2d bl 30010fbc <== NOT EXECUTED IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); memset( &(*block_ptr) [offset], 0, count); 30011704: e5900000 ldr r0, [r0] <== NOT EXECUTED * 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; 30011708: e0687007 rsb r7, r8, r7 <== NOT EXECUTED block_p *block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); memset( &(*block_ptr) [offset], 0, count); 3001170c: e0800008 add r0, r0, r8 <== NOT EXECUTED 30011710: e1a01005 mov r1, r5 <== NOT EXECUTED 30011714: e1a02007 mov r2, r7 <== NOT EXECUTED 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++ ) { 30011718: e2844001 add r4, r4, #1 <== NOT EXECUTED if ( zero_fill ) { size_t count = IMFS_MEMFILE_BYTES_PER_BLOCK - offset; block_p *block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); memset( &(*block_ptr) [offset], 0, count); 3001171c: eb0006c1 bl 30013228 <== NOT EXECUTED 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++ ) { 30011720: e15a0004 cmp sl, r4 <== NOT EXECUTED size_t count = IMFS_MEMFILE_BYTES_PER_BLOCK - offset; block_p *block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); memset( &(*block_ptr) [offset], 0, count); offset = 0; 30011724: e1a08005 mov r8, r5 <== NOT EXECUTED 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++ ) { 30011728: 2affffe8 bcs 300116d0 <== NOT EXECUTED } /* * Set the new length of the file. */ the_jnode->info.file.size = new_length; 3001172c: e89d0018 ldm sp, {r3, r4} IMFS_update_ctime(the_jnode); 30011730: e3a01000 mov r1, #0 } /* * Set the new length of the file. */ the_jnode->info.file.size = new_length; 30011734: e5863050 str r3, [r6, #80] ; 0x50 30011738: e5864054 str r4, [r6, #84] ; 0x54 IMFS_update_ctime(the_jnode); 3001173c: e28d0010 add r0, sp, #16 30011740: ebffd43a bl 30006830 30011744: e59d3010 ldr r3, [sp, #16] IMFS_update_mtime(the_jnode); 30011748: e28d0010 add r0, sp, #16 /* * Set the new length of the file. */ the_jnode->info.file.size = new_length; IMFS_update_ctime(the_jnode); 3001174c: e5863048 str r3, [r6, #72] ; 0x48 IMFS_update_mtime(the_jnode); 30011750: e3a01000 mov r1, #0 30011754: ebffd435 bl 30006830 30011758: e59d3010 ldr r3, [sp, #16] return 0; 3001175c: e3a00000 mov r0, #0 * Set the new length of the file. */ the_jnode->info.file.size = new_length; IMFS_update_ctime(the_jnode); IMFS_update_mtime(the_jnode); 30011760: e5863044 str r3, [r6, #68] ; 0x44 return 0; } 30011764: e28dd018 add sp, sp, #24 30011768: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} memset( &(*block_ptr) [offset], 0, count); offset = 0; } } else { for ( ; block>=old_blocks ; block-- ) { IMFS_memfile_remove_block( the_jnode, block ); 3001176c: e1a01004 mov r1, r4 <== NOT EXECUTED 30011770: e1a00006 mov r0, r6 <== NOT EXECUTED memset( &(*block_ptr) [offset], 0, count); offset = 0; } } else { for ( ; block>=old_blocks ; block-- ) { 30011774: e2444001 sub r4, r4, #1 <== NOT EXECUTED IMFS_memfile_remove_block( the_jnode, block ); 30011778: ebffff99 bl 300115e4 <== NOT EXECUTED memset( &(*block_ptr) [offset], 0, count); offset = 0; } } else { for ( ; block>=old_blocks ; block-- ) { 3001177c: e15b0004 cmp fp, r4 <== NOT EXECUTED 30011780: 9afffff9 bls 3001176c <== NOT EXECUTED IMFS_memfile_remove_block( the_jnode, block ); } rtems_set_errno_and_return_minus_one( ENOSPC ); 30011784: eb000437 bl 30012868 <__errno> <== NOT EXECUTED 30011788: e3a0301c mov r3, #28 <== NOT EXECUTED 3001178c: e5803000 str r3, [r0] <== NOT EXECUTED 30011790: e3e00000 mvn r0, #0 <== NOT EXECUTED 30011794: eafffff2 b 30011764 <== NOT EXECUTED /* * Verify new file size is supported */ if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) rtems_set_errno_and_return_minus_one( EFBIG ); 30011798: eb000432 bl 30012868 <__errno> <== NOT EXECUTED 3001179c: e3a0301b mov r3, #27 <== NOT EXECUTED 300117a0: e5803000 str r3, [r0] <== NOT EXECUTED 300117a4: e3e00000 mvn r0, #0 <== NOT EXECUTED 300117a8: eaffffed b 30011764 <== NOT EXECUTED =============================================================================== 30010fbc : my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { 30010fbc: e59f31fc ldr r3, [pc, #508] ; 300111c0 #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { 30010fc0: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { 30010fc4: e5934000 ldr r4, [r3] #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { 30010fc8: e24dd004 sub sp, sp, #4 my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { 30010fcc: e1a04124 lsr r4, r4, #2 30010fd0: e2443001 sub r3, r4, #1 30010fd4: e1510003 cmp r1, r3 #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { 30010fd8: e1a05000 mov r5, r0 30010fdc: e1a06002 mov r6, r2 my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { 30010fe0: 8a000007 bhi 30011004 p = info->indirect; if ( malloc_it ) { 30010fe4: e3520000 cmp r2, #0 /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { p = info->indirect; 30010fe8: e5900058 ldr r0, [r0, #88] ; 0x58 if ( malloc_it ) { 30010fec: 0a000040 beq 300110f4 if ( !p ) { 30010ff0: e3500000 cmp r0, #0 30010ff4: 0a000050 beq 3001113c } if ( !p ) return 0; return &info->indirect[ my_block ]; 30010ff8: e0800101 add r0, r0, r1, lsl #2 /* * This means the requested block number is out of range. */ return 0; } 30010ffc: e28dd004 add sp, sp, #4 30011000: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} /* * Is the block number in the doubly indirect portion? */ if ( my_block <= LAST_DOUBLY_INDIRECT ) { 30011004: e0274494 mla r7, r4, r4, r4 30011008: e2473001 sub r3, r7, #1 3001100c: e1510003 cmp r1, r3 30011010: 9a000023 bls 300110a4 } /* * Is the block number in the triply indirect portion? */ if ( my_block <= LAST_TRIPLY_INDIRECT ) { 30011014: e0234497 mla r3, r7, r4, r4 <== NOT EXECUTED 30011018: e2433001 sub r3, r3, #1 <== NOT EXECUTED 3001101c: e1510003 cmp r1, r3 <== NOT EXECUTED } /* * This means the requested block number is out of range. */ return 0; 30011020: 83a00000 movhi r0, #0 <== NOT EXECUTED } /* * Is the block number in the triply indirect portion? */ if ( my_block <= LAST_TRIPLY_INDIRECT ) { 30011024: 8afffff4 bhi 30010ffc <== NOT EXECUTED my_block -= FIRST_TRIPLY_INDIRECT; 30011028: e0677001 rsb r7, r7, r1 <== NOT EXECUTED singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; 3001102c: e1a00007 mov r0, r7 <== NOT EXECUTED 30011030: e1a01004 mov r1, r4 <== NOT EXECUTED 30011034: eb002a42 bl 3001b944 <__umodsi3> <== NOT EXECUTED doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; 30011038: e1a01004 mov r1, r4 <== NOT EXECUTED * 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; 3001103c: e1a09000 mov r9, r0 <== NOT EXECUTED doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; 30011040: e1a00007 mov r0, r7 <== NOT EXECUTED 30011044: eb0029f8 bl 3001b82c <__aeabi_uidiv> <== NOT EXECUTED triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; 30011048: e1a01004 mov r1, r4 <== NOT EXECUTED */ if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; 3001104c: e1a0a000 mov sl, r0 <== NOT EXECUTED triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; 30011050: eb0029f5 bl 3001b82c <__aeabi_uidiv> <== NOT EXECUTED doubly %= IMFS_MEMFILE_BLOCK_SLOTS; 30011054: e1a01004 mov r1, r4 <== NOT EXECUTED if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; 30011058: e1a07000 mov r7, r0 <== NOT EXECUTED doubly %= IMFS_MEMFILE_BLOCK_SLOTS; 3001105c: e1a0000a mov r0, sl <== NOT EXECUTED 30011060: eb002a37 bl 3001b944 <__umodsi3> <== NOT EXECUTED p = info->triply_indirect; if ( malloc_it ) { 30011064: e3560000 cmp r6, #0 <== NOT EXECUTED my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; doubly %= IMFS_MEMFILE_BLOCK_SLOTS; 30011068: e1a04000 mov r4, r0 <== NOT EXECUTED p = info->triply_indirect; 3001106c: e5950060 ldr r0, [r5, #96] ; 0x60 <== NOT EXECUTED if ( malloc_it ) { 30011070: 0a000028 beq 30011118 <== NOT EXECUTED if ( !p ) { 30011074: e3500000 cmp r0, #0 <== NOT EXECUTED 30011078: 0a000045 beq 30011194 <== NOT EXECUTED if ( !p ) return 0; info->triply_indirect = p; } p1 = (block_p *) p[ triply ]; 3001107c: e7903107 ldr r3, [r0, r7, lsl #2] <== NOT EXECUTED 30011080: e0807107 add r7, r0, r7, lsl #2 <== NOT EXECUTED if ( !p1 ) { 30011084: e3530000 cmp r3, #0 <== NOT EXECUTED 30011088: 0a000046 beq 300111a8 <== NOT EXECUTED if ( !p1 ) return 0; p[ triply ] = (block_p) p1; } p2 = (block_p *)p1[ doubly ]; 3001108c: e7930104 ldr r0, [r3, r4, lsl #2] <== NOT EXECUTED 30011090: e0834104 add r4, r3, r4, lsl #2 <== NOT EXECUTED if ( !p2 ) { 30011094: e3500000 cmp r0, #0 <== NOT EXECUTED 30011098: 0a000033 beq 3001116c <== NOT EXECUTED p2 = (block_p *)p1[ doubly ]; if ( !p2 ) return 0; return (block_p *)&p2[ singly ]; 3001109c: e0800109 add r0, r0, r9, lsl #2 <== NOT EXECUTED 300110a0: eaffffd5 b 30010ffc <== NOT EXECUTED /* * Is the block number in the doubly indirect portion? */ if ( my_block <= LAST_DOUBLY_INDIRECT ) { my_block -= FIRST_DOUBLY_INDIRECT; 300110a4: e0647001 rsb r7, r4, r1 singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; 300110a8: e1a00007 mov r0, r7 300110ac: e1a01004 mov r1, r4 300110b0: eb002a23 bl 3001b944 <__umodsi3> doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; 300110b4: e1a01004 mov r1, r4 */ if ( my_block <= LAST_DOUBLY_INDIRECT ) { my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; 300110b8: e1a08000 mov r8, r0 doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; 300110bc: e1a00007 mov r0, r7 300110c0: eb0029d9 bl 3001b82c <__aeabi_uidiv> p = info->doubly_indirect; if ( malloc_it ) { 300110c4: e3560000 cmp r6, #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; 300110c8: e1a04000 mov r4, r0 p = info->doubly_indirect; 300110cc: e595305c ldr r3, [r5, #92] ; 0x5c if ( malloc_it ) { 300110d0: 0a00000a beq 30011100 if ( !p ) { 300110d4: e3530000 cmp r3, #0 300110d8: 0a000028 beq 30011180 if ( !p ) return 0; info->doubly_indirect = p; } p1 = (block_p *)p[ doubly ]; 300110dc: e7930104 ldr r0, [r3, r4, lsl #2] 300110e0: e0834104 add r4, r3, r4, lsl #2 if ( !p1 ) { 300110e4: e3500000 cmp r0, #0 300110e8: 0a00001a beq 30011158 p = (block_p *)p[ doubly ]; if ( !p ) return 0; return (block_p *)&p[ singly ]; 300110ec: e0800108 add r0, r0, r8, lsl #2 300110f0: eaffffc1 b 30010ffc info->indirect = p; } return &info->indirect[ my_block ]; } if ( !p ) 300110f4: e3500000 cmp r0, #0 300110f8: 1affffbe bne 30010ff8 300110fc: eaffffbe b 30010ffc <== NOT EXECUTED } return (block_p *)&p1[ singly ]; } if ( !p ) 30011100: e3530000 cmp r3, #0 30011104: 0a00002b beq 300111b8 return 0; p = (block_p *)p[ doubly ]; 30011108: e7930100 ldr r0, [r3, r0, lsl #2] if ( !p ) 3001110c: e3500000 cmp r0, #0 return 0; return (block_p *)&p[ singly ]; 30011110: 10800108 addne r0, r0, r8, lsl #2 30011114: eaffffb8 b 30010ffc p1[ doubly ] = (block_p) p2; } return (block_p *)&p2[ singly ]; } if ( !p ) 30011118: e3500000 cmp r0, #0 <== NOT EXECUTED 3001111c: 0affffb6 beq 30010ffc <== NOT EXECUTED return 0; p1 = (block_p *) p[ triply ]; 30011120: e7900107 ldr r0, [r0, r7, lsl #2] <== NOT EXECUTED if ( !p1 ) 30011124: e3500000 cmp r0, #0 <== NOT EXECUTED 30011128: 0affffb3 beq 30010ffc <== NOT EXECUTED return 0; p2 = (block_p *)p1[ doubly ]; 3001112c: e7900104 ldr r0, [r0, r4, lsl #2] <== NOT EXECUTED if ( !p2 ) 30011130: e3500000 cmp r0, #0 <== NOT EXECUTED return 0; return (block_p *)&p2[ singly ]; 30011134: 10800109 addne r0, r0, r9, lsl #2 <== NOT EXECUTED 30011138: eaffffaf b 30010ffc <== NOT EXECUTED p = info->indirect; if ( malloc_it ) { if ( !p ) { p = memfile_alloc_block(); 3001113c: e58d1000 str r1, [sp] 30011140: ebffff90 bl 30010f88 if ( !p ) 30011144: e3500000 cmp r0, #0 30011148: e59d1000 ldr r1, [sp] return 0; info->indirect = p; 3001114c: 15850058 strne r0, [r5, #88] ; 0x58 if ( malloc_it ) { if ( !p ) { p = memfile_alloc_block(); if ( !p ) 30011150: 1affffa8 bne 30010ff8 30011154: eaffffa8 b 30010ffc <== NOT EXECUTED info->doubly_indirect = p; } p1 = (block_p *)p[ doubly ]; if ( !p1 ) { p1 = memfile_alloc_block(); 30011158: ebffff8a bl 30010f88 if ( !p1 ) 3001115c: e3500000 cmp r0, #0 return 0; p[ doubly ] = (block_p) p1; 30011160: 15840000 strne r0, [r4] p = (block_p *)p[ doubly ]; if ( !p ) return 0; return (block_p *)&p[ singly ]; 30011164: 10800108 addne r0, r0, r8, lsl #2 30011168: eaffffa3 b 30010ffc p[ triply ] = (block_p) p1; } p2 = (block_p *)p1[ doubly ]; if ( !p2 ) { p2 = memfile_alloc_block(); 3001116c: ebffff85 bl 30010f88 <== NOT EXECUTED if ( !p2 ) 30011170: e3500000 cmp r0, #0 <== NOT EXECUTED return 0; p1[ doubly ] = (block_p) p2; 30011174: 15840000 strne r0, [r4] <== NOT EXECUTED p2 = (block_p *)p1[ doubly ]; if ( !p2 ) return 0; return (block_p *)&p2[ singly ]; 30011178: 10800109 addne r0, r0, r9, lsl #2 <== NOT EXECUTED 3001117c: eaffff9e b 30010ffc <== NOT EXECUTED p = info->doubly_indirect; if ( malloc_it ) { if ( !p ) { p = memfile_alloc_block(); 30011180: ebffff80 bl 30010f88 if ( !p ) 30011184: e2503000 subs r3, r0, #0 30011188: 0a00000a beq 300111b8 return 0; info->doubly_indirect = p; 3001118c: e585305c str r3, [r5, #92] ; 0x5c 30011190: eaffffd1 b 300110dc p = info->triply_indirect; if ( malloc_it ) { if ( !p ) { p = memfile_alloc_block(); 30011194: ebffff7b bl 30010f88 <== NOT EXECUTED if ( !p ) 30011198: e3500000 cmp r0, #0 <== NOT EXECUTED 3001119c: 0affff96 beq 30010ffc <== NOT EXECUTED return 0; info->triply_indirect = p; 300111a0: e5850060 str r0, [r5, #96] ; 0x60 <== NOT EXECUTED 300111a4: eaffffb4 b 3001107c <== NOT EXECUTED } p1 = (block_p *) p[ triply ]; if ( !p1 ) { p1 = memfile_alloc_block(); 300111a8: ebffff76 bl 30010f88 <== NOT EXECUTED if ( !p1 ) 300111ac: e2503000 subs r3, r0, #0 <== NOT EXECUTED return 0; p[ triply ] = (block_p) p1; 300111b0: 15873000 strne r3, [r7] <== NOT EXECUTED 300111b4: 1affffb4 bne 3001108c <== NOT EXECUTED p1 = (block_p *) p[ triply ]; if ( !p1 ) { p1 = memfile_alloc_block(); if ( !p1 ) return 0; 300111b8: e1a00003 mov r0, r3 <== NOT EXECUTED 300111bc: eaffff8e b 30010ffc <== NOT EXECUTED =============================================================================== 30008980 : } int IMFS_memfile_maximum_size( void ) { return IMFS_MEMFILE_MAXIMUM_SIZE; 30008980: e59f3018 ldr r3, [pc, #24] ; 300089a0 <== NOT EXECUTED 30008984: e5932000 ldr r2, [r3] <== NOT EXECUTED 30008988: e1a03122 lsr r3, r2, #2 <== NOT EXECUTED 3000898c: e0203393 mla r0, r3, r3, r3 <== NOT EXECUTED 30008990: e0233390 mla r3, r0, r3, r3 <== NOT EXECUTED 30008994: e2430001 sub r0, r3, #1 <== NOT EXECUTED } 30008998: e0000092 mul r0, r2, r0 <== NOT EXECUTED 3000899c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== 300111c4 : IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) { 300111c4: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 300111c8: e1a09000 mov r9, r0 rtems_chain_extract_unprotected( &node->Node ); } static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node ) { return node->control->imfs_type; 300111cc: e590004c ldr r0, [r0, #76] ; 0x4c 300111d0: e24dd014 sub sp, sp, #20 300111d4: e88d0006 stm sp, {r1, r2} * 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 ) { 300111d8: e5902000 ldr r2, [r0] IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) { 300111dc: e58d3008 str r3, [sp, #8] * 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 ) { 300111e0: e3520005 cmp r2, #5 IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) { 300111e4: e59d7038 ldr r7, [sp, #56] ; 0x38 * 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 ) { 300111e8: 0a000059 beq 30011354 /* * 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; 300111ec: e59dc000 ldr ip, [sp] */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 300111f0: e59f81bc ldr r8, [pc, #444] ; 300113b4 /* * 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; 300111f4: e087100c add r1, r7, ip */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 300111f8: e5986000 ldr r6, [r8] /* * 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 ) 300111fc: e1a02001 mov r2, r1 30011200: e3a03000 mov r3, #0 30011204: e2891050 add r1, r9, #80 ; 0x50 30011208: e8910003 ldm r1, {r0, r1} */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 3001120c: e1a05fc6 asr r5, r6, #31 /* * 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 ) 30011210: e1500002 cmp r0, r2 30011214: e0d1e003 sbcs lr, r1, r3 my_length = the_jnode->info.file.size - start; 30011218: b06c7000 rsblt r7, ip, r0 */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 3001121c: e1a03005 mov r3, r5 30011220: e1a02006 mov r2, r6 30011224: e89d0003 ldm sp, {r0, r1} 30011228: eb002dc2 bl 3001c938 <__moddi3> block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; 3001122c: e1a03005 mov r3, r5 */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 30011230: e1a0a000 mov sl, r0 block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; 30011234: e1a02006 mov r2, r6 30011238: e89d0003 ldm sp, {r0, r1} 3001123c: eb002c82 bl 3001c44c <__divdi3> if ( start_offset ) { 30011240: e35a0000 cmp sl, #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; 30011244: e1a04000 mov r4, r0 unsigned int last_byte; unsigned int copied; unsigned int start_offset; unsigned char *dest; dest = destination; 30011248: 059d5008 ldreq r5, [sp, #8] /* * 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 ) { 3001124c: 1a000016 bne 300112ac /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 30011250: e1570006 cmp r7, r6 30011254: 2a000008 bcs 3001127c 30011258: ea000029 b 30011304 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); 3001125c: e5931000 ldr r1, [r3] 30011260: eb0007ba bl 30013150 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 30011264: e5983000 ldr r3, [r8] block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); dest += to_copy; 30011268: e0855006 add r5, r5, r6 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 3001126c: e1530007 cmp r3, r7 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); dest += to_copy; block++; 30011270: e2844001 add r4, r4, #1 my_length -= to_copy; copied += to_copy; 30011274: e08aa006 add sl, sl, r6 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 30011278: 8a000021 bhi 30011304 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 3001127c: e3a02000 mov r2, #0 30011280: e1a01004 mov r1, r4 30011284: e1a00009 mov r0, r9 30011288: ebffff4b bl 30010fbc if ( !block_ptr ) 3001128c: e2503000 subs r3, r0, #0 return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); 30011290: e1a02006 mov r2, r6 dest += to_copy; block++; my_length -= to_copy; 30011294: e0667007 rsb r7, r6, r7 to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); 30011298: e1a00005 mov r0, r5 * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) 3001129c: 1affffee bne 3001125c IMFS_assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); if ( my_length ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; 300112a0: e1a0000a mov r0, sl <== NOT EXECUTED } IMFS_update_atime( the_jnode ); return copied; } 300112a4: e28dd014 add sp, sp, #20 300112a8: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; if ( start_offset ) { to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset; if ( to_copy > my_length ) to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 300112ac: e1a00009 mov r0, r9 300112b0: e1a01004 mov r1, r4 300112b4: e3a02000 mov r2, #0 300112b8: ebffff3f bl 30010fbc if ( !block_ptr ) 300112bc: e3500000 cmp r0, #0 300112c0: 0afffff7 beq 300112a4 * 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; 300112c4: e06a6006 rsb r6, sl, r6 if ( to_copy > my_length ) to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ start_offset ], to_copy ); 300112c8: e5901000 ldr r1, [r0] * 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; 300112cc: e1570006 cmp r7, r6 300112d0: 31a0b007 movcc fp, r7 300112d4: 21a0b006 movcs fp, r6 if ( to_copy > my_length ) to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ start_offset ], to_copy ); 300112d8: e081100a add r1, r1, sl 300112dc: e59d0008 ldr r0, [sp, #8] 300112e0: e1a0200b mov r2, fp 300112e4: eb000799 bl 30013150 dest += to_copy; 300112e8: e59dc008 ldr ip, [sp, #8] block++; 300112ec: e2844001 add r4, r4, #1 to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ start_offset ], to_copy ); dest += to_copy; 300112f0: e08c500b add r5, ip, fp block++; my_length -= to_copy; 300112f4: e06b7007 rsb r7, fp, r7 300112f8: e5986000 ldr r6, [r8] copied += to_copy; 300112fc: e1a0a00b mov sl, fp 30011300: eaffffd2 b 30011250 /* * Phase 3: possibly the first part of one block */ IMFS_assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); if ( my_length ) { 30011304: e3570000 cmp r7, #0 30011308: 0a00000a beq 30011338 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 3001130c: e1a00009 mov r0, r9 30011310: e1a01004 mov r1, r4 30011314: e3a02000 mov r2, #0 30011318: ebffff27 bl 30010fbc if ( !block_ptr ) 3001131c: e2503000 subs r3, r0, #0 30011320: 0affffde beq 300112a0 return copied; memcpy( dest, &(*block_ptr)[ 0 ], my_length ); 30011324: e1a00005 mov r0, r5 30011328: e5931000 ldr r1, [r3] 3001132c: e1a02007 mov r2, r7 30011330: eb000786 bl 30013150 copied += my_length; 30011334: e08aa007 add sl, sl, r7 } IMFS_update_atime( the_jnode ); 30011338: e28d000c add r0, sp, #12 3001133c: e3a01000 mov r1, #0 30011340: ebffd53a bl 30006830 30011344: e59d300c ldr r3, [sp, #12] return copied; 30011348: e1a0000a mov r0, sl return copied; memcpy( dest, &(*block_ptr)[ 0 ], my_length ); copied += my_length; } IMFS_update_atime( the_jnode ); 3001134c: e5893040 str r3, [r9, #64] ; 0x40 return copied; 30011350: eaffffd3 b 300112a4 if ( IMFS_type( the_jnode ) == IMFS_LINEAR_FILE ) { unsigned char *file_ptr; file_ptr = (unsigned char *)the_jnode->info.linearfile.direct; if (my_length > (the_jnode->info.linearfile.size - start)) 30011354: e1a02007 mov r2, r7 30011358: e2895050 add r5, r9, #80 ; 0x50 3001135c: e8950030 ldm r5, {r4, r5} 30011360: e3a03000 mov r3, #0 30011364: e89d0003 ldm sp, {r0, r1} 30011368: e0540000 subs r0, r4, r0 3001136c: e0c51001 sbc r1, r5, r1 30011370: e1500002 cmp r0, r2 30011374: e0d1c003 sbcs ip, r1, r3 my_length = the_jnode->info.linearfile.size - start; 30011378: b59de000 ldrlt lr, [sp] memcpy(dest, &file_ptr[start], my_length); 3001137c: e59d3000 ldr r3, [sp] my_length = length; if ( IMFS_type( the_jnode ) == IMFS_LINEAR_FILE ) { unsigned char *file_ptr; file_ptr = (unsigned char *)the_jnode->info.linearfile.direct; 30011380: e5991058 ldr r1, [r9, #88] ; 0x58 if (my_length > (the_jnode->info.linearfile.size - start)) my_length = the_jnode->info.linearfile.size - start; 30011384: b06e7004 rsblt r7, lr, r4 memcpy(dest, &file_ptr[start], my_length); 30011388: e0811003 add r1, r1, r3 3001138c: e1a02007 mov r2, r7 30011390: e59d0008 ldr r0, [sp, #8] 30011394: eb00076d bl 30013150 IMFS_update_atime( the_jnode ); 30011398: e28d000c add r0, sp, #12 3001139c: e3a01000 mov r1, #0 300113a0: ebffd522 bl 30006830 300113a4: e59d300c ldr r3, [sp, #12] return my_length; 300113a8: e1a00007 mov r0, r7 if (my_length > (the_jnode->info.linearfile.size - start)) my_length = the_jnode->info.linearfile.size - start; memcpy(dest, &file_ptr[start], my_length); IMFS_update_atime( the_jnode ); 300113ac: e5893040 str r3, [r9, #64] ; 0x40 return my_length; 300113b0: eaffffbb b 300112a4 =============================================================================== 300114ac : * is better to stick to simple, easy to understand algorithms. */ IMFS_jnode_t *IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) { 300114ac: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} /* * 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; 300114b0: e59f6128 ldr r6, [pc, #296] ; 300115e0 * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; if ( info->indirect ) { 300114b4: e5903058 ldr r3, [r0, #88] ; 0x58 /* * Eventually this could be set smarter at each call to * memfile_free_blocks_in_table to greatly speed this up. */ to_free = IMFS_MEMFILE_BLOCK_SLOTS; 300114b8: e5967000 ldr r7, [r6] * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; if ( info->indirect ) { 300114bc: e3530000 cmp r3, #0 * is better to stick to simple, easy to understand algorithms. */ IMFS_jnode_t *IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) { 300114c0: e1a0a000 mov sl, r0 /* * 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; 300114c4: e1a07127 lsr r7, r7, #2 * + triply indirect */ info = &the_jnode->info.file; if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free ); 300114c8: 12800058 addne r0, r0, #88 ; 0x58 300114cc: 11a01007 movne r1, r7 300114d0: 1bffffe0 blne 30011458 } if ( info->doubly_indirect ) { 300114d4: e59a305c ldr r3, [sl, #92] ; 0x5c 300114d8: e3530000 cmp r3, #0 300114dc: 0a000013 beq 30011530 for ( i=0 ; i <== NOT EXECUTED 300114ec: e3a00000 mov r0, #0 <== NOT EXECUTED 300114f0: e1a04000 mov r4, r0 <== NOT EXECUTED 300114f4: ea000000 b 300114fc <== NOT EXECUTED 300114f8: e59a305c ldr r3, [sl, #92] ; 0x5c <== NOT EXECUTED if ( info->doubly_indirect[i] ) { 300114fc: e7932100 ldr r2, [r3, r0, lsl #2] <== NOT EXECUTED if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; idoubly_indirect[i] ) { 30011504: e3520000 cmp r2, #0 <== NOT EXECUTED memfile_free_blocks_in_table( 30011508: e1a01007 mov r1, r7 <== NOT EXECUTED memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; idoubly_indirect[i] ) { 3001150c: e0830100 add r0, r3, r0, lsl #2 <== NOT EXECUTED memfile_free_blocks_in_table( 30011510: 1bffffd0 blne 30011458 <== NOT EXECUTED if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i <== 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 ); 30011524: e28a005c add r0, sl, #92 ; 0x5c <== NOT EXECUTED 30011528: e1a01007 mov r1, r7 <== NOT EXECUTED 3001152c: ebffffc9 bl 30011458 <== NOT EXECUTED } if ( info->triply_indirect ) { 30011530: e59a0060 ldr r0, [sl, #96] ; 0x60 30011534: e3500000 cmp r0, #0 30011538: 0a000026 beq 300115d8 for ( i=0 ; i <== NOT EXECUTED p = (block_p *) info->triply_indirect[i]; 30011548: e5905000 ldr r5, [r0] <== NOT EXECUTED if ( !p ) /* ensure we have a valid pointer */ 3001154c: e3550000 cmp r5, #0 <== NOT EXECUTED } if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; 30011550: 13a09000 movne r9, #0 <== NOT EXECUTED if ( !p ) /* ensure we have a valid pointer */ 30011554: 11a08009 movne r8, r9 <== NOT EXECUTED 30011558: 0a00001b beq 300115cc <== NOT EXECUTED break; for ( j=0 ; j <== NOT EXECUTED 30011564: e3a00000 mov r0, #0 <== NOT EXECUTED 30011568: e1a04000 mov r4, r0 <== NOT EXECUTED if ( p[j] ) { 3001156c: e7953100 ldr r3, [r5, r0, lsl #2] <== NOT EXECUTED if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; if ( !p ) /* ensure we have a valid pointer */ break; for ( j=0 ; jtriply_indirect[i]; if ( !p ) /* ensure we have a valid pointer */ break; for ( j=0 ; j <== NOT EXECUTED if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; if ( !p ) /* ensure we have a valid pointer */ break; for ( j=0 ; j <== NOT EXECUTED 30011594: e59a0060 ldr r0, [sl, #96] ; 0x60 <== NOT EXECUTED if ( p[j] ) { memfile_free_blocks_in_table( (block_p **)&p[j], to_free); } } memfile_free_blocks_in_table( 30011598: e0800009 add r0, r0, r9 <== NOT EXECUTED 3001159c: e1a01007 mov r1, r7 <== NOT EXECUTED 300115a0: ebffffac bl 30011458 <== NOT EXECUTED memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i <== NOT EXECUTED p = (block_p *) info->triply_indirect[i]; 300115b8: e59a0060 ldr r0, [sl, #96] ; 0x60 <== NOT EXECUTED * a significant difference in the performance of this routine. * * Regardless until the IMFS implementation is proven, it * is better to stick to simple, easy to understand algorithms. */ IMFS_jnode_t *IMFS_memfile_remove( 300115bc: e1a09108 lsl r9, r8, #2 <== NOT EXECUTED } if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; 300115c0: e7905108 ldr r5, [r0, r8, lsl #2] <== NOT EXECUTED if ( !p ) /* ensure we have a valid pointer */ 300115c4: e3550000 cmp r5, #0 <== NOT EXECUTED 300115c8: 1affffe3 bne 3001155c <== NOT EXECUTED } } memfile_free_blocks_in_table( (block_p **)&info->triply_indirect[i], to_free ); } memfile_free_blocks_in_table( 300115cc: e28a0060 add r0, sl, #96 ; 0x60 <== NOT EXECUTED 300115d0: e1a01007 mov r1, r7 <== NOT EXECUTED 300115d4: ebffff9f bl 30011458 <== NOT EXECUTED (block_p **)&info->triply_indirect, to_free ); } return the_jnode; } 300115d8: e1a0000a mov r0, sl 300115dc: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== 300115e4 : */ MEMFILE_STATIC int IMFS_memfile_remove_block( IMFS_jnode_t *the_jnode, unsigned int block ) { 300115e4: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED block_p *block_ptr; block_p ptr; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 300115e8: e3a02000 mov r2, #0 <== NOT EXECUTED 300115ec: ebfffe72 bl 30010fbc <== NOT EXECUTED IMFS_assert( block_ptr ); ptr = *block_ptr; *block_ptr = 0; 300115f0: e3a02000 mov r2, #0 <== NOT EXECUTED ) { block_p *block_ptr; block_p ptr; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 300115f4: e1a03000 mov r3, r0 <== NOT EXECUTED IMFS_assert( block_ptr ); ptr = *block_ptr; 300115f8: e5900000 ldr r0, [r0] <== NOT EXECUTED *block_ptr = 0; 300115fc: e5832000 str r2, [r3] <== NOT EXECUTED memfile_free_block( ptr ); 30011600: ebffff8c bl 30011438 <== NOT EXECUTED return 1; } 30011604: e3a00001 mov r0, #1 <== NOT EXECUTED 30011608: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== 300117b0 : IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) { 300117b0: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 300117b4: e24dd010 sub sp, sp, #16 300117b8: e59db034 ldr fp, [sp, #52] ; 0x34 300117bc: e88d0006 stm sp, {r1, r2} * 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 ) { 300117c0: e2805050 add r5, r0, #80 ; 0x50 300117c4: e8950030 ldm r5, {r4, r5} /* * 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; 300117c8: e08b2001 add r2, fp, r1 if ( last_byte > the_jnode->info.file.size ) { 300117cc: e1a06002 mov r6, r2 300117d0: e3a07000 mov r7, #0 300117d4: e1540006 cmp r4, r6 300117d8: e0d51007 sbcs r1, r5, r7 IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) { 300117dc: e1a09000 mov r9, r0 300117e0: e1a08003 mov r8, r3 * 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 ) { 300117e4: ba000050 blt 3001192c */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 300117e8: e59f7168 ldr r7, [pc, #360] ; 30011958 300117ec: e89d0003 ldm sp, {r0, r1} 300117f0: e5976000 ldr r6, [r7] 300117f4: e1a05fc6 asr r5, r6, #31 300117f8: e1a03005 mov r3, r5 300117fc: e1a02006 mov r2, r6 30011800: eb002c4c bl 3001c938 <__moddi3> block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; 30011804: e1a03005 mov r3, r5 */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 30011808: e1a0a000 mov sl, r0 block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; 3001180c: e1a02006 mov r2, r6 30011810: e89d0003 ldm sp, {r0, r1} 30011814: eb002b0c bl 3001c44c <__divdi3> if ( start_offset ) { 30011818: e35a0000 cmp sl, #0 */ /* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; 3001181c: e1a04006 mov r4, r6 block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; 30011820: e1a05000 mov r5, r0 if ( start_offset ) { 30011824: 01a0400b moveq r4, fp 30011828: 1a000016 bne 30011888 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 3001182c: e1540006 cmp r4, r6 30011830: 2a000008 bcs 30011858 30011834: ea000027 b 300118d8 if ( !block_ptr ) return copied; #if 0 fprintf(stdout, "write %d in %d: %*s\n", to_copy, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ 0 ], src, to_copy ); 30011838: e5900000 ldr r0, [r0] 3001183c: eb000643 bl 30013150 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 30011840: e5973000 ldr r3, [r7] return copied; #if 0 fprintf(stdout, "write %d in %d: %*s\n", to_copy, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ 0 ], src, to_copy ); src += to_copy; 30011844: e0888006 add r8, r8, r6 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 30011848: e1530004 cmp r3, r4 #if 0 fprintf(stdout, "write %d in %d: %*s\n", to_copy, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ 0 ], src, to_copy ); src += to_copy; block++; 3001184c: e2855001 add r5, r5, #1 * IMFS_memfile_write * * This routine writes the specified data buffer into the in memory * file pointed to by the_jnode. The file is extended as needed. */ MEMFILE_STATIC ssize_t IMFS_memfile_write( 30011850: e08aa006 add sl, sl, r6 /* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { 30011854: 8a00001f bhi 300118d8 block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 30011858: e1a01005 mov r1, r5 3001185c: e3a02000 mov r2, #0 30011860: e1a00009 mov r0, r9 30011864: ebfffdd4 bl 30010fbc if ( !block_ptr ) 30011868: e3500000 cmp r0, #0 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 ); 3001186c: e1a01008 mov r1, r8 30011870: e1a02006 mov r2, r6 src += to_copy; block++; my_length -= to_copy; 30011874: e0664004 rsb r4, r6, r4 */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) 30011878: 1affffee bne 30011838 IMFS_assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); to_copy = my_length; if ( my_length ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); if ( !block_ptr ) 3001187c: e1a0000a mov r0, sl <== NOT EXECUTED } IMFS_mtime_ctime_update( the_jnode ); return copied; } 30011880: e28dd010 add sp, sp, #16 30011884: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} block = start / IMFS_MEMFILE_BYTES_PER_BLOCK; if ( start_offset ) { to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK - start_offset; if ( to_copy > my_length ) to_copy = my_length; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 30011888: e1a00009 mov r0, r9 <== NOT EXECUTED 3001188c: e1a01005 mov r1, r5 <== NOT EXECUTED 30011890: e3a02000 mov r2, #0 <== NOT EXECUTED 30011894: ebfffdc8 bl 30010fbc <== NOT EXECUTED if ( !block_ptr ) 30011898: e3500000 cmp r0, #0 <== NOT EXECUTED 3001189c: 0afffff7 beq 30011880 <== NOT EXECUTED * 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; 300118a0: e06a6006 rsb r6, sl, r6 <== NOT EXECUTED block, to_copy, src ); #endif memcpy( &(*block_ptr)[ start_offset ], src, to_copy ); 300118a4: e5900000 ldr r0, [r0] <== NOT EXECUTED * 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; 300118a8: e156000b cmp r6, fp <== NOT EXECUTED 300118ac: 21a0600b movcs r6, fp <== NOT EXECUTED block, to_copy, src ); #endif memcpy( &(*block_ptr)[ start_offset ], src, to_copy ); 300118b0: e080000a add r0, r0, sl <== NOT EXECUTED 300118b4: e1a01008 mov r1, r8 <== NOT EXECUTED 300118b8: e1a02006 mov r2, r6 <== NOT EXECUTED 300118bc: eb000623 bl 30013150 <== NOT EXECUTED src += to_copy; 300118c0: e0888006 add r8, r8, r6 <== NOT EXECUTED block++; my_length -= to_copy; 300118c4: e066400b rsb r4, r6, fp <== NOT EXECUTED copied += to_copy; 300118c8: e1a0a006 mov sl, r6 <== NOT EXECUTED src ); #endif memcpy( &(*block_ptr)[ start_offset ], src, to_copy ); src += to_copy; block++; 300118cc: e2855001 add r5, r5, #1 <== NOT EXECUTED my_length -= to_copy; copied += to_copy; 300118d0: e5976000 ldr r6, [r7] <== NOT EXECUTED 300118d4: eaffffd4 b 3001182c <== NOT EXECUTED * 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 ) { 300118d8: e3540000 cmp r4, #0 300118dc: 0a00000a beq 3001190c block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); 300118e0: e1a00009 mov r0, r9 300118e4: e1a01005 mov r1, r5 300118e8: e3a02000 mov r2, #0 300118ec: ebfffdb2 bl 30010fbc if ( !block_ptr ) 300118f0: e3500000 cmp r0, #0 300118f4: 0affffe0 beq 3001187c 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 ); 300118f8: e5900000 ldr r0, [r0] 300118fc: e1a01008 mov r1, r8 30011900: e1a02004 mov r2, r4 30011904: eb000611 bl 30013150 my_length = 0; copied += to_copy; 30011908: e08aa004 add sl, sl, r4 } IMFS_mtime_ctime_update( the_jnode ); 3001190c: e28d0008 add r0, sp, #8 30011910: e3a01000 mov r1, #0 30011914: ebffd3c5 bl 30006830 30011918: e59d3008 ldr r3, [sp, #8] return copied; 3001191c: e1a0000a mov r0, sl memcpy( &(*block_ptr)[ 0 ], src, my_length ); my_length = 0; copied += to_copy; } IMFS_mtime_ctime_update( the_jnode ); 30011920: e5893044 str r3, [r9, #68] ; 0x44 30011924: e5893048 str r3, [r9, #72] ; 0x48 return copied; 30011928: eaffffd4 b 30011880 last_byte = start + my_length; if ( last_byte > the_jnode->info.file.size ) { bool zero_fill = start > the_jnode->info.file.size; status = IMFS_memfile_extend( the_jnode, zero_fill, last_byte ); 3001192c: e89d000c ldm sp, {r2, r3} 30011930: e1540002 cmp r4, r2 30011934: e0d53003 sbcs r3, r5, r3 30011938: a3a01000 movge r1, #0 3001193c: b3a01001 movlt r1, #1 30011940: e1a02006 mov r2, r6 30011944: e1a03007 mov r3, r7 30011948: ebffff2f bl 3001160c if ( status ) 3001194c: e3500000 cmp r0, #0 30011950: 0affffa4 beq 300117e8 30011954: eaffffc9 b 30011880 <== NOT EXECUTED =============================================================================== 30006128 : #include "imfs.h" int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { int rv = 0; IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; 30006128: e5903020 ldr r3, [r0, #32] #endif #include "imfs.h" int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { 3000612c: e52de004 push {lr} ; (str lr, [sp, #-4]!) int rv = 0; IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; 30006130: e5933008 ldr r3, [r3, #8] return node->control->imfs_type; } static inline bool IMFS_is_directory( const IMFS_jnode_t *node ) { return node->control->imfs_type == IMFS_DIRECTORY; 30006134: e593204c ldr r2, [r3, #76] ; 0x4c if ( IMFS_is_directory( node ) ) { 30006138: e5922000 ldr r2, [r2] 3000613c: e3520000 cmp r2, #0 30006140: 1a000009 bne 3000616c if ( node->info.directory.mt_fs == NULL ) { 30006144: e593205c ldr r2, [r3, #92] ; 0x5c 30006148: e3520000 cmp r2, #0 node->info.directory.mt_fs = mt_entry; 3000614c: 0583005c streq r0, [r3, #92] ; 0x5c #include "imfs.h" int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { int rv = 0; 30006150: 01a00002 moveq r0, r2 IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; if ( IMFS_is_directory( node ) ) { if ( node->info.directory.mt_fs == NULL ) { 30006154: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) node->info.directory.mt_fs = mt_entry; } else { errno = EBUSY; 30006158: eb0031c2 bl 30012868 <__errno> <== NOT EXECUTED 3000615c: e3a03010 mov r3, #16 <== NOT EXECUTED 30006160: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; 30006164: e3e00000 mvn r0, #0 <== NOT EXECUTED 30006168: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } } else { errno = ENOTDIR; 3000616c: eb0031bd bl 30012868 <__errno> 30006170: e3a03014 mov r3, #20 30006174: e5803000 str r3, [r0] rv = -1; 30006178: e3e00000 mvn r0, #0 } return rv; } 3000617c: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== 3000ed78 : return node; } static IMFS_jnode_t *IMFS_node_destroy_sym_link( IMFS_jnode_t *node ) { 3000ed78: e92d4010 push {r4, lr} <== NOT EXECUTED 3000ed7c: e1a04000 mov r4, r0 <== NOT EXECUTED free( node->info.sym_link.name ); 3000ed80: e5900050 ldr r0, [r0, #80] ; 0x50 <== NOT EXECUTED 3000ed84: ebffde80 bl 3000678c <== NOT EXECUTED return node; } 3000ed88: e1a00004 mov r0, r4 <== NOT EXECUTED 3000ed8c: e8bd8010 pop {r4, pc} <== NOT EXECUTED =============================================================================== 3000ecd4 : static IMFS_jnode_t *IMFS_node_initialize_hard_link( IMFS_jnode_t *node, const IMFS_types_union *info ) { node->info.hard_link.link_node = info->hard_link.link_node; 3000ecd4: e5913000 ldr r3, [r1] <== NOT EXECUTED 3000ecd8: e5803050 str r3, [r0, #80] ; 0x50 <== NOT EXECUTED return node; } 3000ecdc: e12fff1e bx lr <== NOT EXECUTED =============================================================================== 3000ec8c : static IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node ) { if ( !rtems_chain_is_empty( &node->info.directory.Entries ) ) { 3000ec8c: e5902050 ldr r2, [r0, #80] ; 0x50 RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( const Chain_Control *the_chain ) { return _Chain_Immutable_first( the_chain ) == _Chain_Immutable_tail( the_chain ); 3000ec90: e2803054 add r3, r0, #84 ; 0x54 3000ec94: e1520003 cmp r2, r3 } static IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node ) { 3000ec98: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !rtems_chain_is_empty( &node->info.directory.Entries ) ) { 3000ec9c: 1a000007 bne 3000ecc0 errno = ENOTEMPTY; node = NULL; } else if ( IMFS_is_mount_point( node ) ) { 3000eca0: e590305c ldr r3, [r0, #92] ; 0x5c 3000eca4: e3530000 cmp r3, #0 3000eca8: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) errno = EBUSY; 3000ecac: eb000eed bl 30012868 <__errno> <== NOT EXECUTED 3000ecb0: e3a03010 mov r3, #16 <== NOT EXECUTED 3000ecb4: e5803000 str r3, [r0] <== NOT EXECUTED 3000ecb8: e3a00000 mov r0, #0 <== NOT EXECUTED node = NULL; } return node; } 3000ecbc: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED static IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node ) { if ( !rtems_chain_is_empty( &node->info.directory.Entries ) ) { errno = ENOTEMPTY; 3000ecc0: eb000ee8 bl 30012868 <__errno> <== NOT EXECUTED 3000ecc4: e3a0305a mov r3, #90 ; 0x5a <== NOT EXECUTED 3000ecc8: e5803000 str r3, [r0] <== NOT EXECUTED node = NULL; 3000eccc: e3a00000 mov r0, #0 <== NOT EXECUTED 3000ecd0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== 3000ed90 : } static IMFS_jnode_t *IMFS_node_remove_hard_link( IMFS_jnode_t *node ) { 3000ed90: e92d4030 push {r4, r5, lr} <== NOT EXECUTED IMFS_jnode_t *target = node->info.hard_link.link_node; 3000ed94: e5904050 ldr r4, [r0, #80] ; 0x50 <== NOT EXECUTED } static IMFS_jnode_t *IMFS_node_remove_hard_link( IMFS_jnode_t *node ) { 3000ed98: e24dd008 sub sp, sp, #8 <== NOT EXECUTED IMFS_jnode_t *target = node->info.hard_link.link_node; if ( target->st_nlink == 1) { 3000ed9c: e1d433b6 ldrh r3, [r4, #54] ; 0x36 <== NOT EXECUTED } static IMFS_jnode_t *IMFS_node_remove_hard_link( IMFS_jnode_t *node ) { 3000eda0: e1a05000 mov r5, r0 <== NOT EXECUTED IMFS_jnode_t *target = node->info.hard_link.link_node; if ( target->st_nlink == 1) { 3000eda4: e3530001 cmp r3, #1 <== NOT EXECUTED 3000eda8: 0a000009 beq 3000edd4 <== NOT EXECUTED target = (*target->control->node_remove)( target ); if ( target == NULL ) { node = NULL; } } else { --target->st_nlink; 3000edac: e2433001 sub r3, r3, #1 <== NOT EXECUTED 3000edb0: e1c433b6 strh r3, [r4, #54] ; 0x36 <== NOT EXECUTED IMFS_update_ctime( target ); 3000edb4: e1a0000d mov r0, sp <== NOT EXECUTED 3000edb8: e3a01000 mov r1, #0 <== NOT EXECUTED 3000edbc: ebffde9b bl 30006830 <== NOT EXECUTED 3000edc0: e59d3000 ldr r3, [sp] <== NOT EXECUTED 3000edc4: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED } return node; } 3000edc8: e1a00005 mov r0, r5 <== NOT EXECUTED 3000edcc: e28dd008 add sp, sp, #8 <== NOT EXECUTED 3000edd0: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED ) { IMFS_jnode_t *target = node->info.hard_link.link_node; if ( target->st_nlink == 1) { target = (*target->control->node_remove)( target ); 3000edd4: e594304c ldr r3, [r4, #76] ; 0x4c <== NOT EXECUTED 3000edd8: e1a00004 mov r0, r4 <== NOT EXECUTED 3000eddc: e1a0e00f mov lr, pc <== NOT EXECUTED 3000ede0: e593f00c ldr pc, [r3, #12] <== NOT EXECUTED if ( target == NULL ) { node = NULL; 3000ede4: e3500000 cmp r0, #0 <== NOT EXECUTED 3000ede8: 03a05000 moveq r5, #0 <== NOT EXECUTED 3000edec: eafffff5 b 3000edc8 <== NOT EXECUTED =============================================================================== 30006180 : rtems_filesystem_node_types_t IMFS_node_type( const rtems_filesystem_location_info_t *loc ) { const IMFS_jnode_t *node = loc->node_access; 30006180: e5903008 ldr r3, [r0, #8] rtems_chain_extract_unprotected( &node->Node ); } static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node ) { return node->control->imfs_type; 30006184: e593204c ldr r2, [r3, #76] ; 0x4c 30006188: e5920000 ldr r0, [r2] IMFS_jnode_types_t imfs_type = IMFS_type( node ); rtems_filesystem_node_types_t type; switch ( imfs_type ) { 3000618c: e3500002 cmp r0, #2 30006190: 0a000002 beq 300061a0 30006194: e3500005 cmp r0, #5 30006198: 03a00004 moveq r0, #4 3000619c: e12fff1e bx lr 300061a0: e5933050 ldr r3, [r3, #80] ; 0x50 <== NOT EXECUTED 300061a4: e593304c ldr r3, [r3, #76] ; 0x4c <== NOT EXECUTED 300061a8: e5930000 ldr r0, [r3] <== NOT EXECUTED type = imfs_type; break; } return type; } 300061ac: e12fff1e bx lr <== NOT EXECUTED =============================================================================== 300061b0 : node = loc->node_access; IMFS_assert( node->control->imfs_type == IMFS_SYM_LINK ); for( i=0; ((iinfo.sym_link.name[i] != '\0')); i++ ) 300061b0: e3520000 cmp r2, #0 <== NOT EXECUTED ssize_t IMFS_readlink( const rtems_filesystem_location_info_t *loc, char *buf, size_t bufsize ) { 300061b4: e52d4004 push {r4} ; (str r4, [sp, #-4]!) <== NOT EXECUTED IMFS_jnode_t *node; ssize_t i; node = loc->node_access; 300061b8: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED IMFS_assert( node->control->imfs_type == IMFS_SYM_LINK ); for( i=0; ((iinfo.sym_link.name[i] != '\0')); i++ ) 300061bc: 01a00002 moveq r0, r2 <== NOT EXECUTED 300061c0: 0a000010 beq 30006208 <== NOT EXECUTED 300061c4: e5943050 ldr r3, [r4, #80] ; 0x50 <== NOT EXECUTED 300061c8: e5d33000 ldrb r3, [r3] <== NOT EXECUTED 300061cc: e3530000 cmp r3, #0 <== NOT EXECUTED 300061d0: 01a00003 moveq r0, r3 <== NOT EXECUTED 300061d4: 0a00000b beq 30006208 <== NOT EXECUTED 300061d8: e3a0c000 mov ip, #0 <== NOT EXECUTED 300061dc: e1a0000c mov r0, ip <== NOT EXECUTED 300061e0: ea000003 b 300061f4 <== NOT EXECUTED 300061e4: e5943050 ldr r3, [r4, #80] ; 0x50 <== NOT EXECUTED 300061e8: e7d33000 ldrb r3, [r3, r0] <== NOT EXECUTED 300061ec: e3530000 cmp r3, #0 <== NOT EXECUTED 300061f0: 0a000004 beq 30006208 <== NOT EXECUTED 300061f4: e2800001 add r0, r0, #1 <== NOT EXECUTED 300061f8: e1500002 cmp r0, r2 <== NOT EXECUTED buf[i] = node->info.sym_link.name[i]; 300061fc: e7c1300c strb r3, [r1, ip] <== NOT EXECUTED node = loc->node_access; IMFS_assert( node->control->imfs_type == IMFS_SYM_LINK ); for( i=0; ((iinfo.sym_link.name[i] != '\0')); i++ ) 30006200: e1a0c000 mov ip, r0 <== NOT EXECUTED 30006204: 1afffff6 bne 300061e4 <== NOT EXECUTED buf[i] = node->info.sym_link.name[i]; return i; } 30006208: e8bd0010 pop {r4} <== NOT EXECUTED 3000620c: e12fff1e bx lr <== NOT EXECUTED =============================================================================== 30006210 : const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { 30006210: e92d40f0 push {r4, r5, r6, r7, lr} <== NOT EXECUTED int rv = 0; IMFS_jnode_t *node = oldloc->node_access; 30006214: e5914008 ldr r4, [r1, #8] <== NOT EXECUTED const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { 30006218: e24dd008 sub sp, sp, #8 <== NOT EXECUTED /* * FIXME: Due to insufficient checks we can create inaccessible nodes with * this operation. */ if ( node->Parent != NULL ) { 3000621c: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { 30006220: e59d601c ldr r6, [sp, #28] <== NOT EXECUTED /* * FIXME: Due to insufficient checks we can create inaccessible nodes with * this operation. */ if ( node->Parent != NULL ) { 30006224: e3500000 cmp r0, #0 <== NOT EXECUTED size_t namelen ) { int rv = 0; IMFS_jnode_t *node = oldloc->node_access; IMFS_jnode_t *new_parent = newparentloc->node_access; 30006228: e5925008 ldr r5, [r2, #8] <== NOT EXECUTED /* * FIXME: Due to insufficient checks we can create inaccessible nodes with * this operation. */ if ( node->Parent != NULL ) { 3000622c: 0a00001f beq 300062b0 <== NOT EXECUTED if ( namelen < IMFS_NAME_MAX ) { 30006230: e356001f cmp r6, #31 <== NOT EXECUTED 30006234: 8a000018 bhi 3000629c <== NOT EXECUTED memcpy( node->name, name, namelen ); 30006238: e1a01003 mov r1, r3 <== NOT EXECUTED 3000623c: e1a02006 mov r2, r6 <== NOT EXECUTED node->name [namelen] = '\0'; 30006240: e3a07000 mov r7, #0 <== NOT EXECUTED * this operation. */ if ( node->Parent != NULL ) { if ( namelen < IMFS_NAME_MAX ) { memcpy( node->name, name, namelen ); 30006244: e284000c add r0, r4, #12 <== NOT EXECUTED node->name [namelen] = '\0'; 30006248: e0846006 add r6, r4, r6 <== NOT EXECUTED * this operation. */ if ( node->Parent != NULL ) { if ( namelen < IMFS_NAME_MAX ) { memcpy( node->name, name, namelen ); 3000624c: eb0033bf bl 30013150 <== NOT EXECUTED node->name [namelen] = '\0'; 30006250: e5c6700c strb r7, [r6, #12] <== NOT EXECUTED { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; 30006254: e8940003 ldm r4, {r0, r1} <== NOT EXECUTED next->previous = previous; 30006258: e5801004 str r1, [r0, #4] <== NOT EXECUTED Chain_Control *the_chain, Chain_Node *the_node ) { Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_last = tail->previous; 3000625c: e5953058 ldr r3, [r5, #88] ; 0x58 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Chain_Append_unprotected( Chain_Control *the_chain, Chain_Node *the_node ) { Chain_Node *tail = _Chain_Tail( the_chain ); 30006260: e2852054 add r2, r5, #84 ; 0x54 <== NOT EXECUTED Chain_Node *previous; next = the_node->next; previous = the_node->previous; next->previous = previous; previous->next = next; 30006264: e5810000 str r0, [r1] <== NOT EXECUTED static inline void IMFS_add_to_directory( IMFS_jnode_t *dir, IMFS_jnode_t *node ) { node->Parent = dir; 30006268: e5845008 str r5, [r4, #8] <== NOT EXECUTED ) { Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_last = tail->previous; the_node->next = tail; 3000626c: e5842000 str r2, [r4] <== NOT EXECUTED tail->previous = the_node; 30006270: e5854058 str r4, [r5, #88] ; 0x58 <== NOT EXECUTED old_last->next = the_node; 30006274: e5834000 str r4, [r3] <== NOT EXECUTED the_node->previous = old_last; 30006278: e5843004 str r3, [r4, #4] <== NOT EXECUTED IMFS_remove_from_directory( node ); IMFS_add_to_directory( new_parent, node ); IMFS_update_ctime( node ); 3000627c: e1a0000d mov r0, sp <== NOT EXECUTED 30006280: e1a01007 mov r1, r7 <== NOT EXECUTED 30006284: eb000169 bl 30006830 <== NOT EXECUTED 30006288: e59d3000 ldr r3, [sp] <== NOT EXECUTED const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { int rv = 0; 3000628c: e1a00007 mov r0, r7 <== NOT EXECUTED memcpy( node->name, name, namelen ); node->name [namelen] = '\0'; IMFS_remove_from_directory( node ); IMFS_add_to_directory( new_parent, node ); IMFS_update_ctime( node ); 30006290: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED errno = EINVAL; rv = -1; } return rv; } 30006294: e28dd008 add sp, sp, #8 <== NOT EXECUTED 30006298: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED IMFS_remove_from_directory( node ); IMFS_add_to_directory( new_parent, node ); IMFS_update_ctime( node ); } else { errno = ENAMETOOLONG; 3000629c: eb003171 bl 30012868 <__errno> <== NOT EXECUTED 300062a0: e3a0305b mov r3, #91 ; 0x5b <== NOT EXECUTED 300062a4: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; 300062a8: e3e00000 mvn r0, #0 <== NOT EXECUTED 300062ac: eafffff8 b 30006294 <== NOT EXECUTED } } else { errno = EINVAL; 300062b0: eb00316c bl 30012868 <__errno> <== NOT EXECUTED 300062b4: e3a03016 mov r3, #22 <== NOT EXECUTED 300062b8: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; 300062bc: e3e00000 mvn r0, #0 <== NOT EXECUTED 300062c0: eafffff3 b 30006294 <== NOT EXECUTED =============================================================================== 300062c4 : const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc ) { int rv = 0; IMFS_jnode_t *node = loc->node_access; 300062c4: e5910008 ldr r0, [r1, #8] int IMFS_rmnod( const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc ) { 300062c8: e52de004 push {lr} ; (str lr, [sp, #-4]!) int rv = 0; IMFS_jnode_t *node = loc->node_access; node = (*node->control->node_remove)( node ); 300062cc: e590304c ldr r3, [r0, #76] ; 0x4c 300062d0: e1a0e00f mov lr, pc 300062d4: e593f00c ldr pc, [r3, #12] if ( node != NULL ) { 300062d8: e2503000 subs r3, r0, #0 300062dc: 0a00000d beq 30006318 --node->reference_count; --node->st_nlink; if ( node->Parent != NULL ) { 300062e0: e5930008 ldr r0, [r3, #8] int rv = 0; IMFS_jnode_t *node = loc->node_access; node = (*node->control->node_remove)( node ); if ( node != NULL ) { --node->reference_count; 300062e4: e1d313b4 ldrh r1, [r3, #52] ; 0x34 --node->st_nlink; 300062e8: e1d323b6 ldrh r2, [r3, #54] ; 0x36 if ( node->Parent != NULL ) { 300062ec: e3500000 cmp r0, #0 int rv = 0; IMFS_jnode_t *node = loc->node_access; node = (*node->control->node_remove)( node ); if ( node != NULL ) { --node->reference_count; 300062f0: e2411001 sub r1, r1, #1 --node->st_nlink; 300062f4: e2422001 sub r2, r2, #1 } static inline void IMFS_remove_from_directory( IMFS_jnode_t *node ) { IMFS_assert( node->Parent != NULL ); node->Parent = NULL; 300062f8: 13a00000 movne r0, #0 int rv = 0; IMFS_jnode_t *node = loc->node_access; node = (*node->control->node_remove)( node ); if ( node != NULL ) { --node->reference_count; 300062fc: e1c313b4 strh r1, [r3, #52] ; 0x34 --node->st_nlink; 30006300: e1c323b6 strh r2, [r3, #54] ; 0x36 30006304: 15830008 strne r0, [r3, #8] { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; 30006308: 18930006 ldmne r3, {r1, r2} next->previous = previous; 3000630c: 15812004 strne r2, [r1, #4] previous->next = next; 30006310: 15821000 strne r1, [r2] 30006314: e49df004 pop {pc} ; (ldr pc, [sp], #4) if ( node->Parent != NULL ) { IMFS_remove_from_directory( node ); } } else { rv = -1; 30006318: e3e00000 mvn r0, #0 <== NOT EXECUTED } return rv; } 3000631c: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== 3000ecec : static int IMFS_stat_link( const rtems_filesystem_location_info_t *loc, struct stat *buf ) { const IMFS_jnode_t *node = loc->node_access; 3000ecec: e5903008 ldr r3, [r0, #8] <== NOT EXECUTED static int IMFS_stat_link( const rtems_filesystem_location_info_t *loc, struct stat *buf ) { 3000ecf0: e92d4070 push {r4, r5, r6, lr} <== 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; 3000ecf4: e593204c ldr r2, [r3, #76] ; 0x4c <== NOT EXECUTED 3000ecf8: e24dd018 sub sp, sp, #24 <== NOT EXECUTED const IMFS_jnode_t *node = loc->node_access; if ( IMFS_type( node ) != IMFS_HARD_LINK ) { 3000ecfc: e5922000 ldr r2, [r2] <== NOT EXECUTED static int IMFS_stat_link( const rtems_filesystem_location_info_t *loc, struct stat *buf ) { 3000ed00: e1a06000 mov r6, r0 <== NOT EXECUTED const IMFS_jnode_t *node = loc->node_access; if ( IMFS_type( node ) != IMFS_HARD_LINK ) { 3000ed04: e3520002 cmp r2, #2 <== NOT EXECUTED static int IMFS_stat_link( const rtems_filesystem_location_info_t *loc, struct stat *buf ) { 3000ed08: e1a04001 mov r4, r1 <== NOT EXECUTED const IMFS_jnode_t *node = loc->node_access; if ( IMFS_type( node ) != IMFS_HARD_LINK ) { 3000ed0c: 0a000009 beq 3000ed38 <== NOT EXECUTED buf->st_size = strlen( node->info.sym_link.name ); 3000ed10: e5930050 ldr r0, [r3, #80] ; 0x50 <== NOT EXECUTED 3000ed14: eb00148f bl 30013f58 <== NOT EXECUTED 3000ed18: e3a03000 mov r3, #0 <== NOT EXECUTED 3000ed1c: e5840020 str r0, [r4, #32] <== NOT EXECUTED 3000ed20: e5843024 str r3, [r4, #36] ; 0x24 <== NOT EXECUTED return IMFS_stat( loc, buf ); 3000ed24: e1a00006 mov r0, r6 <== NOT EXECUTED 3000ed28: e1a01004 mov r1, r4 <== NOT EXECUTED 3000ed2c: eb00003b bl 3000ee20 <== NOT EXECUTED targetloc.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &targetloc ); return (targetloc.handlers->fstat_h)( &targetloc, buf ); } } 3000ed30: e28dd018 add sp, sp, #24 <== NOT EXECUTED 3000ed34: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED return IMFS_stat( loc, buf ); } else { rtems_filesystem_location_info_t targetloc = *loc; targetloc.node_access = node->info.hard_link.link_node; 3000ed38: e5935050 ldr r5, [r3, #80] ; 0x50 <== NOT EXECUTED if ( IMFS_type( node ) != IMFS_HARD_LINK ) { buf->st_size = strlen( node->info.sym_link.name ); return IMFS_stat( loc, buf ); } else { rtems_filesystem_location_info_t targetloc = *loc; 3000ed3c: e1a0c00d mov ip, sp <== NOT EXECUTED 3000ed40: e1a0e000 mov lr, r0 <== NOT EXECUTED 3000ed44: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 3000ed48: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 3000ed4c: e89e0003 ldm lr, {r0, r1} <== NOT EXECUTED 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; 3000ed50: e595304c ldr r3, [r5, #76] ; 0x4c <== NOT EXECUTED 3000ed54: e88c0003 stm ip, {r0, r1} <== NOT EXECUTED 3000ed58: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED targetloc.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &targetloc ); return (targetloc.handlers->fstat_h)( &targetloc, buf ); 3000ed5c: e1a0000d mov r0, sp <== NOT EXECUTED return IMFS_stat( loc, buf ); } else { rtems_filesystem_location_info_t targetloc = *loc; targetloc.node_access = node->info.hard_link.link_node; 3000ed60: e58d5008 str r5, [sp, #8] <== NOT EXECUTED 3000ed64: e58d3010 str r3, [sp, #16] <== NOT EXECUTED IMFS_Set_handlers( &targetloc ); return (targetloc.handlers->fstat_h)( &targetloc, buf ); 3000ed68: e1a01004 mov r1, r4 <== NOT EXECUTED 3000ed6c: e1a0e00f mov lr, pc <== NOT EXECUTED 3000ed70: e593f018 ldr pc, [r3, #24] <== NOT EXECUTED 3000ed74: eaffffed b 3000ed30 <== NOT EXECUTED =============================================================================== 30006320 : const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, const char *target ) { 30006320: e92d4070 push {r4, r5, r6, lr} 30006324: e1a04000 mov r4, r0 30006328: e24dd01c sub sp, sp, #28 IMFS_jnode_t *new_node; /* * Duplicate link name */ info.sym_link.name = strdup(target); 3000632c: e1a00003 mov r0, r3 const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, const char *target ) { 30006330: e1a06001 mov r6, r1 30006334: e1a05002 mov r5, r2 IMFS_jnode_t *new_node; /* * Duplicate link name */ info.sym_link.name = strdup(target); 30006338: eb00356e bl 300138f8 if (info.sym_link.name == NULL) { 3000633c: e3500000 cmp r0, #0 IMFS_jnode_t *new_node; /* * Duplicate link name */ info.sym_link.name = strdup(target); 30006340: e58d0008 str r0, [sp, #8] if (info.sym_link.name == NULL) { 30006344: 0a000011 beq 30006390 size_t namelen, mode_t mode, const IMFS_types_union *info ) { const IMFS_fs_info_t *fs_info = 30006348: e5943014 ldr r3, [r4, #20] (const IMFS_fs_info_t *) parentloc->mt_entry->fs_info; return IMFS_create_node_with_control( 3000634c: e59fc050 ldr ip, [pc, #80] ; 300063a4 30006350: e5933008 ldr r3, [r3, #8] 30006354: e1a00004 mov r0, r4 30006358: e5931014 ldr r1, [r3, #20] 3000635c: e1a02006 mov r2, r6 30006360: e58dc000 str ip, [sp] 30006364: e1a03005 mov r3, r5 30006368: e28dc008 add ip, sp, #8 3000636c: e58dc004 str ip, [sp, #4] 30006370: eb002132 bl 3000e840 namelen, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) { 30006374: e3500000 cmp r0, #0 free(info.sym_link.name); rtems_set_errno_and_return_minus_one(ENOMEM); } return 0; 30006378: 13a00000 movne r0, #0 namelen, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) { 3000637c: 0a000001 beq 30006388 free(info.sym_link.name); rtems_set_errno_and_return_minus_one(ENOMEM); } return 0; } 30006380: e28dd01c add sp, sp, #28 30006384: e8bd8070 pop {r4, r5, r6, pc} ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) { free(info.sym_link.name); 30006388: e59d0008 ldr r0, [sp, #8] <== NOT EXECUTED 3000638c: eb0000fe bl 3000678c <== NOT EXECUTED rtems_set_errno_and_return_minus_one(ENOMEM); 30006390: eb003134 bl 30012868 <__errno> <== NOT EXECUTED 30006394: e3a0300c mov r3, #12 <== NOT EXECUTED 30006398: e5803000 str r3, [r0] <== NOT EXECUTED 3000639c: e3e00000 mvn r0, #0 <== NOT EXECUTED 300063a0: eafffff6 b 30006380 <== NOT EXECUTED =============================================================================== 300063a8 : #include "imfs.h" int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) { int rv = 0; IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; 300063a8: e5903020 ldr r3, [r0, #32] #endif #include "imfs.h" int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) { 300063ac: e52de004 push {lr} ; (str lr, [sp, #-4]!) int rv = 0; IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; 300063b0: e5933008 ldr r3, [r3, #8] return node->control->imfs_type; } static inline bool IMFS_is_directory( const IMFS_jnode_t *node ) { return node->control->imfs_type == IMFS_DIRECTORY; 300063b4: e593204c ldr r2, [r3, #76] ; 0x4c if ( IMFS_is_directory( node ) ) { 300063b8: e5922000 ldr r2, [r2] 300063bc: e3520000 cmp r2, #0 300063c0: 1a000009 bne 300063ec if ( node->info.directory.mt_fs == mt_entry ) { 300063c4: e593105c ldr r1, [r3, #92] ; 0x5c 300063c8: e1510000 cmp r1, r0 node->info.directory.mt_fs = NULL; 300063cc: 0583205c streq r2, [r3, #92] ; 0x5c #include "imfs.h" int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) { int rv = 0; 300063d0: 01a00002 moveq r0, r2 IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; if ( IMFS_is_directory( node ) ) { if ( node->info.directory.mt_fs == mt_entry ) { 300063d4: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) node->info.directory.mt_fs = NULL; } else { errno = EINVAL; 300063d8: eb003122 bl 30012868 <__errno> <== NOT EXECUTED 300063dc: e3a03016 mov r3, #22 <== NOT EXECUTED 300063e0: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; 300063e4: e3e00000 mvn r0, #0 <== NOT EXECUTED 300063e8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } } else { errno = ENOTDIR; 300063ec: eb00311d bl 30012868 <__errno> <== NOT EXECUTED 300063f0: e3a03014 mov r3, #20 <== NOT EXECUTED 300063f4: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; 300063f8: e3e00000 mvn r0, #0 <== NOT EXECUTED } return rv; } 300063fc: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== 30006400 : int IMFS_utime( const rtems_filesystem_location_info_t *loc, time_t actime, time_t modtime ) { 30006400: e92d4010 push {r4, lr} <== NOT EXECUTED IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) loc->node_access; 30006404: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED the_jnode->stat_atime = actime; the_jnode->stat_mtime = modtime; the_jnode->stat_ctime = time( NULL ); 30006408: e3a00000 mov r0, #0 <== NOT EXECUTED { IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) loc->node_access; the_jnode->stat_atime = actime; 3000640c: e5841040 str r1, [r4, #64] ; 0x40 <== NOT EXECUTED the_jnode->stat_mtime = modtime; 30006410: e5842044 str r2, [r4, #68] ; 0x44 <== NOT EXECUTED the_jnode->stat_ctime = time( NULL ); 30006414: eb003737 bl 300140f8