=============================================================================== a000dca4 : ) { IMFS_jnode_t *node; struct timeval tv; if ( namelen > IMFS_NAME_MAX ) { a000dca4: e3530020 cmp r3, #32 const char *name, size_t namelen, mode_t mode, const IMFS_types_union *info ) { a000dca8: e92d41f3 push {r0, r1, r4, r5, r6, r7, r8, lr} a000dcac: e1a04000 mov r4, r0 a000dcb0: e1a05001 mov r5, r1 a000dcb4: e1a08002 mov r8, r2 a000dcb8: e1a07003 mov r7, r3 IMFS_jnode_t *node; struct timeval tv; if ( namelen > IMFS_NAME_MAX ) { a000dcbc: 9a000004 bls a000dcd4 errno = ENAMETOOLONG; a000dcc0: eb000f15 bl a001191c <__errno> <== NOT EXECUTED a000dcc4: e3a0305b mov r3, #91 ; 0x5b <== NOT EXECUTED a000dcc8: e5803000 str r3, [r0] <== NOT EXECUTED return NULL; a000dccc: e3a00000 mov r0, #0 <== NOT EXECUTED a000dcd0: ea00002a b a000dd80 <== NOT EXECUTED } gettimeofday( &tv, 0 ); a000dcd4: e3a01000 mov r1, #0 a000dcd8: e1a0000d mov r0, sp a000dcdc: ebffe208 bl a0006504 /* * Allocate an IMFS jnode */ node = calloc( 1, sizeof( IMFS_jnode_t ) ); a000dce0: e3a00001 mov r0, #1 a000dce4: e3a01064 mov r1, #100 ; 0x64 a000dce8: ebffe139 bl a00061d4 if ( !node ) { a000dcec: e2506000 subs r6, r0, #0 a000dcf0: 1a000004 bne a000dd08 errno = ENOMEM; a000dcf4: eb000f08 bl a001191c <__errno> a000dcf8: e3a0300c mov r3, #12 a000dcfc: e5803000 str r3, [r0] return NULL; a000dd00: e1a00006 mov r0, r6 a000dd04: ea00001d b a000dd80 } /* * Fill in the basic information */ node->reference_count = 1; a000dd08: e3a03001 mov r3, #1 node->st_nlink = 1; memcpy( node->name, name, namelen ); a000dd0c: e1a01008 mov r1, r8 a000dd10: e1a02007 mov r2, r7 } /* * Fill in the basic information */ node->reference_count = 1; a000dd14: e1c633b4 strh r3, [r6, #52] ; 0x34 node->st_nlink = 1; a000dd18: e1c633b6 strh r3, [r6, #54] ; 0x36 memcpy( node->name, name, namelen ); a000dd1c: e286000c add r0, r6, #12 a000dd20: eb001137 bl a0012204 node->name [namelen] = '\0'; a000dd24: e0867007 add r7, r6, r7 a000dd28: e3a03000 mov r3, #0 a000dd2c: e5c7300c strb r3, [r7, #12] node->control = node_control; /* * Fill in the mode and permission information for the jnode structure. */ node->st_mode = mode; a000dd30: 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; a000dd34: e586504c str r5, [r6, #76] ; 0x4c /* * Fill in the mode and permission information for the jnode structure. */ node->st_mode = mode; a000dd38: e5863030 str r3, [r6, #48] ; 0x30 #if defined(RTEMS_POSIX_API) node->st_uid = geteuid(); a000dd3c: eb0001f9 bl a000e528 a000dd40: e1c603bc strh r0, [r6, #60] ; 0x3c node->st_gid = getegid(); a000dd44: eb0001f2 bl a000e514 /* * Now set all the times. */ node->stat_atime = (time_t) tv.tv_sec; a000dd48: e59d3000 ldr r3, [sp] * 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(); a000dd4c: e1c603be strh r0, [r6, #62] ; 0x3e 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; return (*node->control->node_initialize)( node, info ); a000dd50: e59d1024 ldr r1, [sp, #36] ; 0x24 /* * Now set all the times. */ node->stat_atime = (time_t) tv.tv_sec; a000dd54: e5863040 str r3, [r6, #64] ; 0x40 node->stat_mtime = (time_t) tv.tv_sec; a000dd58: e5863044 str r3, [r6, #68] ; 0x44 node->stat_ctime = (time_t) tv.tv_sec; a000dd5c: e5863048 str r3, [r6, #72] ; 0x48 node->st_ino = ++fs_info->ino_count; a000dd60: e5943004 ldr r3, [r4, #4] return (*node->control->node_initialize)( node, info ); a000dd64: e1a00006 mov r0, r6 */ 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; a000dd68: e2833001 add r3, r3, #1 a000dd6c: e5843004 str r3, [r4, #4] a000dd70: e5863038 str r3, [r6, #56] ; 0x38 return (*node->control->node_initialize)( node, info ); a000dd74: e596304c ldr r3, [r6, #76] ; 0x4c a000dd78: e5933008 ldr r3, [r3, #8] a000dd7c: e12fff33 blx r3 } a000dd80: e8bd81fc pop {r2, r3, r4, r5, r6, r7, r8, pc} =============================================================================== a000dc38 : int IMFS_chown( const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group ) { a000dc38: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} a000dc3c: e1a02802 lsl r2, r2, #16 a000dc40: e1a01801 lsl r1, r1, #16 IMFS_jnode_t *jnode; #if defined(RTEMS_POSIX_API) uid_t st_uid; #endif jnode = (IMFS_jnode_t *) loc->node_access; a000dc44: e5904008 ldr r4, [r0, #8] int IMFS_chown( const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group ) { a000dc48: e1a06821 lsr r6, r1, #16 a000dc4c: e1a07822 lsr r7, r2, #16 /* * Verify I am the owner of the node or the super user. */ #if defined(RTEMS_POSIX_API) st_uid = geteuid(); a000dc50: eb000234 bl a000e528 if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) ) a000dc54: e1d453bc ldrh r5, [r4, #60] ; 0x3c a000dc58: e3500000 cmp r0, #0 a000dc5c: 11550000 cmpne r5, r0 a000dc60: 03a05000 moveq r5, #0 a000dc64: 13a05001 movne r5, #1 a000dc68: 0a000004 beq a000dc80 rtems_set_errno_and_return_minus_one( EPERM ); a000dc6c: eb000f2a bl a001191c <__errno> <== NOT EXECUTED a000dc70: e3a03001 mov r3, #1 <== NOT EXECUTED a000dc74: e5803000 str r3, [r0] <== NOT EXECUTED a000dc78: e3e00000 mvn r0, #0 <== NOT EXECUTED a000dc7c: ea000007 b a000dca0 <== NOT EXECUTED #endif jnode->st_uid = owner; a000dc80: e1c463bc strh r6, [r4, #60] ; 0x3c jnode->st_gid = group; a000dc84: e1c473be strh r7, [r4, #62] ; 0x3e IMFS_update_ctime( jnode ); a000dc88: e1a0000d mov r0, sp a000dc8c: e1a01005 mov r1, r5 a000dc90: ebffe21b bl a0006504 a000dc94: e59d3000 ldr r3, [sp] return 0; a000dc98: e1a00005 mov r0, r5 #endif jnode->st_uid = owner; jnode->st_gid = group; IMFS_update_ctime( jnode ); a000dc9c: e5843048 str r3, [r4, #72] ; 0x48 return 0; } a000dca0: e8bd80fc pop {r2, r3, r4, r5, r6, r7, pc} =============================================================================== a0008428 : */ static void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) { a0008428: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} a000842c: e59f5140 ldr r5, [pc, #320] ; a0008574 a0008430: e1a06000 mov r6, r0 a0008434: e1a07001 mov r7, r1 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_First( Chain_Control *the_chain ) { return _Chain_Head( the_chain )->next; a0008438: e5904050 ldr r4, [r0, #80] ; 0x50 a000843c: e1a08005 mov r8, r5 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 ); a0008440: ea000047 b a0008564 the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; for ( i=0 ; i<=level ; i++ ) fprintf(stdout, "...." ); a0008444: e5953000 ldr r3, [r5] a0008448: e59f0128 ldr r0, [pc, #296] ; a0008578 !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++ ) a000844c: e28aa001 add sl, sl, #1 fprintf(stdout, "...." ); a0008450: e5931008 ldr r1, [r3, #8] a0008454: eb00354e bl a0015994 a0008458: ea000000 b a0008460 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 ); a000845c: e3a0a000 mov sl, #0 !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++ ) a0008460: e15a0007 cmp sl, r7 a0008464: dafffff6 ble a0008444 IMFS_jnode_t *the_jnode ) { IMFS_assert( the_jnode ); fprintf(stdout, "%s", the_jnode->name ); a0008468: e5983000 ldr r3, [r8] a000846c: e284000c add r0, r4, #12 a0008470: e5931008 ldr r1, [r3, #8] a0008474: eb003546 bl a0015994 rtems_chain_extract_unprotected( &node->Node ); } static inline IMFS_jnode_types_t IMFS_type( const IMFS_jnode_t *node ) { return node->control->imfs_type; a0008478: e594304c ldr r3, [r4, #76] ; 0x4c a000847c: e5932000 ldr r2, [r3] switch( IMFS_type( the_jnode ) ) { a0008480: e3520006 cmp r2, #6 a0008484: 979ff102 ldrls pc, [pc, r2, lsl #2] a0008488: ea000026 b a0008528 <== NOT EXECUTED a000848c: a00084a8 .word 0xa00084a8 <== NOT EXECUTED a0008490: a00084bc .word 0xa00084bc <== NOT EXECUTED a0008494: a0008508 .word 0xa0008508 <== NOT EXECUTED a0008498: a0008508 .word 0xa0008508 <== NOT EXECUTED a000849c: a00084f0 .word 0xa00084f0 <== NOT EXECUTED a00084a0: a00084d4 .word 0xa00084d4 <== NOT EXECUTED a00084a4: a0008514 .word 0xa0008514 <== NOT EXECUTED case IMFS_DIRECTORY: fprintf(stdout, "/" ); a00084a8: e5953000 ldr r3, [r5] a00084ac: e3a0002f mov r0, #47 ; 0x2f a00084b0: e5931008 ldr r1, [r3, #8] a00084b4: eb003501 bl a00158c0 a00084b8: ea00001f b a000853c break; case IMFS_DEVICE: fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")", a00084bc: e5953000 ldr r3, [r5] a00084c0: e59f10b4 ldr r1, [pc, #180] ; a000857c a00084c4: e5942050 ldr r2, [r4, #80] ; 0x50 a00084c8: e5930008 ldr r0, [r3, #8] a00084cc: e5943054 ldr r3, [r4, #84] ; 0x54 a00084d0: ea000004 b a00084e8 the_jnode->info.device.major, the_jnode->info.device.minor ); break; case IMFS_LINEAR_FILE: fprintf(stdout, " (file %" PRId32 " %p)", a00084d4: e5953000 ldr r3, [r5] a00084d8: e59f10a0 ldr r1, [pc, #160] ; a0008580 a00084dc: e5942050 ldr r2, [r4, #80] ; 0x50 a00084e0: e5930008 ldr r0, [r3, #8] a00084e4: e5943058 ldr r3, [r4, #88] ; 0x58 a00084e8: eb0034d4 bl a0015840 a00084ec: ea000012 b a000853c the_jnode->info.file.indirect, the_jnode->info.file.doubly_indirect, the_jnode->info.file.triply_indirect ); #else fprintf(stdout, " (file %" PRId32 ")", a00084f0: e5953000 ldr r3, [r5] <== NOT EXECUTED a00084f4: e59f1088 ldr r1, [pc, #136] ; a0008584 <== NOT EXECUTED a00084f8: e5942050 ldr r2, [r4, #80] ; 0x50 <== NOT EXECUTED a00084fc: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED a0008500: eb0034ce bl a0015840 <== NOT EXECUTED a0008504: ea00000c b a000853c <== NOT EXECUTED case IMFS_HARD_LINK: fprintf(stdout, " links not printed\n" ); return; case IMFS_SYM_LINK: fprintf(stdout, " links not printed\n" ); a0008508: e5953000 ldr r3, [r5] <== NOT EXECUTED a000850c: e59f0074 ldr r0, [pc, #116] ; a0008588 <== NOT EXECUTED a0008510: ea000001 b a000851c <== NOT EXECUTED return; case IMFS_FIFO: fprintf(stdout, " FIFO not printed\n" ); a0008514: e5953000 ldr r3, [r5] <== NOT EXECUTED a0008518: e59f006c ldr r0, [pc, #108] ; a000858c <== NOT EXECUTED a000851c: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED a0008520: eb00351b bl a0015994 <== NOT EXECUTED a0008524: ea000006 b a0008544 <== NOT EXECUTED return; default: fprintf(stdout, " bad type %d\n", IMFS_type( the_jnode ) ); a0008528: e5953000 ldr r3, [r5] <== NOT EXECUTED a000852c: e59f105c ldr r1, [pc, #92] ; a0008590 <== NOT EXECUTED a0008530: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED a0008534: eb0034c1 bl a0015840 <== NOT EXECUTED a0008538: ea000001 b a0008544 <== NOT EXECUTED return; } puts(""); a000853c: e59f0050 ldr r0, [pc, #80] ; a0008594 a0008540: eb003bd8 bl a00174a8 } static inline bool IMFS_is_directory( const IMFS_jnode_t *node ) { return node->control->imfs_type == IMFS_DIRECTORY; a0008544: e594304c ldr r3, [r4, #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 ) ) a0008548: e5933000 ldr r3, [r3] a000854c: e3530000 cmp r3, #0 a0008550: 1a000002 bne a0008560 IMFS_dump_directory( the_jnode, level + 1 ); a0008554: e1a00004 mov r0, r4 a0008558: e2871001 add r1, r7, #1 a000855c: ebffffb1 bl a0008428 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 ) { a0008560: e5944000 ldr r4, [r4] 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 )); a0008564: e2863054 add r3, r6, #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 ); a0008568: e1540003 cmp r4, r3 a000856c: 1affffba bne a000845c fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode ); if ( IMFS_is_directory( the_jnode ) ) IMFS_dump_directory( the_jnode, level + 1 ); } } a0008570: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} =============================================================================== a000dfc8 : int IMFS_fchmod( const rtems_filesystem_location_info_t *loc, mode_t mode ) { a000dfc8: e92d4073 push {r0, r1, r4, r5, r6, lr} <== NOT EXECUTED IMFS_jnode_t *jnode; #if defined(RTEMS_POSIX_API) uid_t st_uid; #endif jnode = loc->node_access; a000dfcc: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED int IMFS_fchmod( const rtems_filesystem_location_info_t *loc, mode_t mode ) { a000dfd0: 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(); a000dfd4: eb000153 bl a000e528 <== NOT EXECUTED if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) ) a000dfd8: e1d453bc ldrh r5, [r4, #60] ; 0x3c <== NOT EXECUTED a000dfdc: e3500000 cmp r0, #0 <== NOT EXECUTED a000dfe0: 11550000 cmpne r5, r0 <== NOT EXECUTED a000dfe4: 03a05000 moveq r5, #0 <== NOT EXECUTED a000dfe8: 13a05001 movne r5, #1 <== NOT EXECUTED a000dfec: 0a000004 beq a000e004 <== NOT EXECUTED rtems_set_errno_and_return_minus_one( EPERM ); a000dff0: eb000e49 bl a001191c <__errno> <== NOT EXECUTED a000dff4: e3a03001 mov r3, #1 <== NOT EXECUTED a000dff8: e5803000 str r3, [r0] <== NOT EXECUTED a000dffc: e3e00000 mvn r0, #0 <== NOT EXECUTED a000e000: ea00000b b a000e034 <== 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); a000e004: e5943030 ldr r3, [r4, #48] ; 0x30 <== NOT EXECUTED jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); a000e008: e1a06a06 lsl r6, r6, #20 <== NOT EXECUTED IMFS_update_ctime( jnode ); a000e00c: e1a0000d mov r0, sp <== 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); a000e010: e3c33eff bic r3, r3, #4080 ; 0xff0 <== NOT EXECUTED a000e014: e3c3300f bic r3, r3, #15 <== NOT EXECUTED jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); a000e018: e1833a26 orr r3, r3, r6, lsr #20 <== NOT EXECUTED a000e01c: e5843030 str r3, [r4, #48] ; 0x30 <== NOT EXECUTED IMFS_update_ctime( jnode ); a000e020: e1a01005 mov r1, r5 <== NOT EXECUTED a000e024: ebffe136 bl a0006504 <== NOT EXECUTED a000e028: e59d3000 ldr r3, [sp] <== NOT EXECUTED return 0; a000e02c: 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 ); a000e030: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED return 0; } a000e034: e8bd807c pop {r2, r3, r4, r5, r6, pc} <== NOT EXECUTED =============================================================================== a00068bc : void *buffer ) { int err; if (command == FIONBIO) { a00068bc: e59fc06c ldr ip, [pc, #108] ; a0006930 static int IMFS_fifo_ioctl( rtems_libio_t *iop, ioctl_command_t command, void *buffer ) { a00068c0: e92d4010 push {r4, lr} int err; if (command == FIONBIO) { a00068c4: e151000c cmp r1, ip static int IMFS_fifo_ioctl( rtems_libio_t *iop, ioctl_command_t command, void *buffer ) { a00068c8: e1a03000 mov r3, r0 int err; if (command == FIONBIO) { a00068cc: 1a00000a bne a00068fc if (buffer == NULL) a00068d0: e3520000 cmp r2, #0 a00068d4: 0a00000e beq a0006914 err = -EFAULT; else { if (*(int *)buffer) a00068d8: e5924000 ldr r4, [r2] a00068dc: e593200c ldr r2, [r3, #12] a00068e0: e3540000 cmp r4, #0 iop->flags |= LIBIO_FLAGS_NO_DELAY; a00068e4: 13822001 orrne r2, r2, #1 else iop->flags &= ~LIBIO_FLAGS_NO_DELAY; a00068e8: 03c22001 biceq r2, r2, #1 if (command == FIONBIO) { if (buffer == NULL) err = -EFAULT; else { if (*(int *)buffer) iop->flags |= LIBIO_FLAGS_NO_DELAY; a00068ec: 1583200c strne r2, [r3, #12] a00068f0: 13a04000 movne r4, #0 else iop->flags &= ~LIBIO_FLAGS_NO_DELAY; a00068f4: 0583200c streq r2, [r3, #12] a00068f8: ea00000a b a0006928 return 0; } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop); a00068fc: e5930018 ldr r0, [r3, #24] <== NOT EXECUTED a0006900: e5900050 ldr r0, [r0, #80] ; 0x50 <== NOT EXECUTED a0006904: eb0027ef bl a00108c8 <== NOT EXECUTED IMFS_FIFO_RETURN(err); a0006908: e2504000 subs r4, r0, #0 <== NOT EXECUTED a000690c: aa000005 bge a0006928 <== NOT EXECUTED a0006910: ea000000 b a0006918 <== NOT EXECUTED { int err; if (command == FIONBIO) { if (buffer == NULL) err = -EFAULT; a0006914: e3e0400d mvn r4, #13 } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop); IMFS_FIFO_RETURN(err); a0006918: eb0033b7 bl a00137fc <__errno> a000691c: e2644000 rsb r4, r4, #0 a0006920: e5804000 str r4, [r0] a0006924: e3e04000 mvn r4, #0 } a0006928: e1a00004 mov r0, r4 a000692c: e8bd8010 pop {r4, pc} =============================================================================== a000e038 : ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) void IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) { a000e038: 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; a000e03c: 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 ) { a000e040: 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; a000e044: e1a0c00d mov ip, sp a000e048: e1a04005 mov r4, r5 a000e04c: e8b4000f ldm r4!, {r0, r1, r2, r3} a000e050: e8ac000f stmia ip!, {r0, r1, r2, r3} a000e054: 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; a000e058: e3a03000 mov r3, #0 /* * Traverse tree that starts at the mt_fs_root and deallocate memory * associated memory space */ loc = temp_mt_entry->mt_fs_root->location; a000e05c: e88c0003 stm ip, {r0, r1} jnode = (IMFS_jnode_t *)loc.node_access; a000e060: 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; a000e064: e5853008 str r3, [r5, #8] a000e068: ea000000 b a000e070 if ( IMFS_is_directory( jnode ) ) { if ( jnode_has_children( jnode ) ) jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL); a000e06c: e1a04003 mov r4, r3 a000e070: e594304c ldr r3, [r4, #76] ; 0x4c */ temp_mt_entry->mt_fs_root->location.node_access = NULL; do { next = jnode->Parent; a000e074: e5945008 ldr r5, [r4, #8] loc.node_access = (void *)jnode; a000e078: e58d4008 str r4, [sp, #8] a000e07c: e5932004 ldr r2, [r3, #4] IMFS_Set_handlers( &loc ); if ( !IMFS_is_directory( jnode ) || jnode_has_no_children( jnode ) ) { a000e080: e5933000 ldr r3, [r3] a000e084: e58d2010 str r2, [sp, #16] a000e088: e3530000 cmp r3, #0 a000e08c: 1a000003 bne a000e0a0 a000e090: 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 ); a000e094: e2843054 add r3, r4, #84 ; 0x54 a000e098: e1520003 cmp r2, r3 a000e09c: 1a000009 bne a000e0c8 result = IMFS_rmnod( NULL, &loc ); a000e0a0: e3a00000 mov r0, #0 a000e0a4: e1a0100d mov r1, sp a000e0a8: ebffdfb8 bl a0005f90 if ( result != 0 ) a000e0ac: e3500000 cmp r0, #0 a000e0b0: 0a000001 beq a000e0bc rtems_fatal_error_occurred( 0xdeadbeef ); a000e0b4: e59f0044 ldr r0, [pc, #68] ; a000e100 <== NOT EXECUTED a000e0b8: ebfff1db bl a000a82c <== NOT EXECUTED IMFS_node_destroy( jnode ); a000e0bc: e1a00004 mov r0, r4 a000e0c0: ebffdef3 bl a0005c94 jnode = next; a000e0c4: e1a04005 mov r4, r5 } if ( jnode != NULL ) { a000e0c8: e3540000 cmp r4, #0 a000e0cc: 0a000009 beq a000e0f8 return node->control->imfs_type; } static inline bool IMFS_is_directory( const IMFS_jnode_t *node ) { return node->control->imfs_type == IMFS_DIRECTORY; a000e0d0: e594304c ldr r3, [r4, #76] ; 0x4c if ( IMFS_is_directory( jnode ) ) { a000e0d4: e5933000 ldr r3, [r3] a000e0d8: e3530000 cmp r3, #0 a000e0dc: 1affffe3 bne a000e070 */ RTEMS_INLINE_ROUTINE const Chain_Node *_Chain_Immutable_first( const Chain_Control *the_chain ) { return _Chain_Immutable_head( the_chain )->next; a000e0e0: e5943050 ldr r3, [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 ); a000e0e4: e2842054 add r2, r4, #84 ; 0x54 if ( jnode_has_children( jnode ) ) a000e0e8: e1530002 cmp r3, r2 a000e0ec: 0affffdf beq a000e070 jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL); a000e0f0: e3530000 cmp r3, #0 a000e0f4: 1affffdc bne a000e06c } a000e0f8: e28dd018 add sp, sp, #24 a000e0fc: e8bd8030 pop {r4, r5, pc} =============================================================================== a0005b80 : 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] ) { a0005b80: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} a0005b84: e1a04000 mov r4, r0 a0005b88: e1a06001 mov r6, r1 static int imfs_instance; int rv = 0; IMFS_fs_info_t *fs_info = calloc( 1, sizeof( *fs_info ) ); a0005b8c: e3a00001 mov r0, #1 a0005b90: 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] ) { a0005b94: e1a07002 mov r7, r2 static int imfs_instance; int rv = 0; IMFS_fs_info_t *fs_info = calloc( 1, sizeof( *fs_info ) ); a0005b98: eb00018d bl a00061d4 if ( fs_info != NULL ) { a0005b9c: e2505000 subs r5, r0, #0 a0005ba0: 0a000020 beq a0005c28 IMFS_jnode_t *root_node; fs_info->instance = imfs_instance++; a0005ba4: e59f30bc ldr r3, [pc, #188] ; a0005c68 a0005ba8: e1a00005 mov r0, r5 memcpy( a0005bac: e1a01007 mov r1, r7 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++; a0005bb0: e5932000 ldr r2, [r3] a0005bb4: e4802008 str r2, [r0], #8 a0005bb8: e2822001 add r2, r2, #1 a0005bbc: e5832000 str r2, [r3] memcpy( a0005bc0: e3a0201c mov r2, #28 a0005bc4: eb00318e bl a0012204 fs_info->node_controls, node_controls, sizeof( fs_info->node_controls ) ); root_node = IMFS_allocate_node( a0005bc8: e59f309c ldr r3, [pc, #156] ; a0005c6c a0005bcc: e1a00005 mov r0, r5 a0005bd0: e59f2098 ldr r2, [pc, #152] ; a0005c70 a0005bd4: e58d3000 str r3, [sp] a0005bd8: e3a03000 mov r3, #0 a0005bdc: e58d3004 str r3, [sp, #4] a0005be0: e5951008 ldr r1, [r5, #8] a0005be4: eb00202e bl a000dca4 "", 0, (S_IFDIR | 0755), NULL ); if ( root_node != NULL ) { a0005be8: e3500000 cmp r0, #0 a0005bec: 0a00000d beq a0005c28 mt_entry->fs_info = fs_info; mt_entry->ops = op_table; mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS; a0005bf0: e59f307c ldr r3, [pc, #124] ; a0005c74 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; a0005bf4: e590204c ldr r2, [r0, #76] ; 0x4c 0, (S_IFDIR | 0755), NULL ); if ( root_node != NULL ) { mt_entry->fs_info = fs_info; a0005bf8: e5845008 str r5, [r4, #8] mt_entry->ops = op_table; mt_entry->pathconf_limits_and_options = &IMFS_LIMITS_AND_OPTIONS; a0005bfc: e584302c str r3, [r4, #44] ; 0x2c a0005c00: e5922004 ldr r2, [r2, #4] mt_entry->mt_fs_root->location.node_access = root_node; a0005c04: e5943024 ldr r3, [r4, #36] ; 0x24 (S_IFDIR | 0755), NULL ); if ( root_node != NULL ) { mt_entry->fs_info = fs_info; mt_entry->ops = op_table; a0005c08: e584600c str r6, [r4, #12] errno = ENOMEM; rv = -1; } if ( rv == 0 ) { IMFS_determine_bytes_per_block( a0005c0c: e3a01006 mov r1, #6 a0005c10: e5832010 str r2, [r3, #16] ); 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; a0005c14: e5830008 str r0, [r3, #8] errno = ENOMEM; rv = -1; } if ( rv == 0 ) { IMFS_determine_bytes_per_block( a0005c18: e59f3058 ldr r3, [pc, #88] ; a0005c78 int bit_mask; /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { a0005c1c: e3a02010 mov r2, #16 errno = ENOMEM; rv = -1; } if ( rv == 0 ) { IMFS_determine_bytes_per_block( a0005c20: e5933000 ldr r3, [r3] a0005c24: ea000004 b a0005c3c } else { errno = ENOMEM; rv = -1; } } else { errno = ENOMEM; a0005c28: eb002f3b bl a001191c <__errno> <== NOT EXECUTED a0005c2c: e3a0300c mov r3, #12 <== NOT EXECUTED a0005c30: e5803000 str r3, [r0] <== NOT EXECUTED a0005c34: e3e00000 mvn r0, #0 <== NOT EXECUTED a0005c38: ea000009 b a0005c64 <== NOT EXECUTED /* * 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) { a0005c3c: e1520003 cmp r2, r3 a0005c40: 0a000004 beq a0005c58 is_valid = true; break; } if(bit_mask > requested_bytes_per_block) a0005c44: ca000002 bgt a0005c54 int bit_mask; /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) { a0005c48: e2511001 subs r1, r1, #1 a0005c4c: e1a02082 lsl r2, r2, #1 a0005c50: 1afffff9 bne a0005c3c if(bit_mask > requested_bytes_per_block) break; } *dest_bytes_per_block = ((is_valid) ? requested_bytes_per_block : default_bytes_per_block); a0005c54: e3a03080 mov r3, #128 ; 0x80 break; } if(bit_mask > requested_bytes_per_block) break; } *dest_bytes_per_block = ((is_valid) a0005c58: e59f2008 ldr r2, [pc, #8] ; a0005c68 const IMFS_node_control *const node_controls [IMFS_TYPE_COUNT] ) { static int imfs_instance; int rv = 0; a0005c5c: e3a00000 mov r0, #0 break; } if(bit_mask > requested_bytes_per_block) break; } *dest_bytes_per_block = ((is_valid) a0005c60: e5823004 str r3, [r2, #4] IMFS_MEMFILE_DEFAULT_BYTES_PER_BLOCK ); } return rv; } a0005c64: e8bd80fc pop {r2, r3, r4, r5, r6, r7, pc} =============================================================================== a0005cc8 : const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *targetloc, const char *name, size_t namelen ) { a0005cc8: e92d4010 push {r4, lr} IMFS_types_union info; IMFS_jnode_t *new_node; IMFS_jnode_t *target; target = targetloc->node_access; a0005ccc: e5914008 ldr r4, [r1, #8] const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *targetloc, const char *name, size_t namelen ) { a0005cd0: e24dd024 sub sp, sp, #36 ; 0x24 info.hard_link.link_node = target; /* * Verify this node can be linked to. */ if ( target->st_nlink >= LINK_MAX ) a0005cd4: e1d413b6 ldrh r1, [r4, #54] ; 0x36 IMFS_types_union info; IMFS_jnode_t *new_node; IMFS_jnode_t *target; target = targetloc->node_access; info.hard_link.link_node = target; a0005cd8: e58d4008 str r4, [sp, #8] /* * Verify this node can be linked to. */ if ( target->st_nlink >= LINK_MAX ) a0005cdc: e3510007 cmp r1, #7 a0005ce0: 9a000002 bls a0005cf0 rtems_set_errno_and_return_minus_one( EMLINK ); a0005ce4: eb002f0c bl a001191c <__errno> <== NOT EXECUTED a0005ce8: e3a0301f mov r3, #31 <== NOT EXECUTED a0005cec: ea00000b b a0005d20 <== NOT EXECUTED size_t namelen, mode_t mode, const IMFS_types_union *info ) { const IMFS_fs_info_t *fs_info = a0005cf0: e5901014 ldr r1, [r0, #20] (const IMFS_fs_info_t *) parentloc->mt_entry->fs_info; return IMFS_create_node_with_control( a0005cf4: e59fc068 ldr ip, [pc, #104] ; a0005d64 a0005cf8: e5911008 ldr r1, [r1, #8] a0005cfc: e58dc000 str ip, [sp] parentloc, IMFS_HARD_LINK, name, namelen, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info a0005d00: e28dc008 add ip, sp, #8 a0005d04: e58dc004 str ip, [sp, #4] a0005d08: e5911010 ldr r1, [r1, #16] a0005d0c: eb00201c bl a000dd84 ); if ( !new_node ) a0005d10: e3500000 cmp r0, #0 a0005d14: 1a000004 bne a0005d2c rtems_set_errno_and_return_minus_one( ENOMEM ); a0005d18: eb002eff bl a001191c <__errno> <== NOT EXECUTED a0005d1c: e3a0300c mov r3, #12 <== NOT EXECUTED a0005d20: e5803000 str r3, [r0] <== NOT EXECUTED a0005d24: e3e00000 mvn r0, #0 <== NOT EXECUTED a0005d28: ea00000b b a0005d5c <== NOT EXECUTED /* * Increment the link count of the node being pointed to. */ target->reference_count++; a0005d2c: e1d433b4 ldrh r3, [r4, #52] ; 0x34 target->st_nlink++; IMFS_update_ctime( target ); a0005d30: e28d001c add r0, sp, #28 a0005d34: e3a01000 mov r1, #0 rtems_set_errno_and_return_minus_one( ENOMEM ); /* * Increment the link count of the node being pointed to. */ target->reference_count++; a0005d38: e2833001 add r3, r3, #1 a0005d3c: e1c433b4 strh r3, [r4, #52] ; 0x34 target->st_nlink++; a0005d40: e1d433b6 ldrh r3, [r4, #54] ; 0x36 a0005d44: e2833001 add r3, r3, #1 a0005d48: e1c433b6 strh r3, [r4, #54] ; 0x36 IMFS_update_ctime( target ); a0005d4c: eb0001ec bl a0006504 a0005d50: e59d301c ldr r3, [sp, #28] return 0; a0005d54: e3a00000 mov r0, #0 /* * Increment the link count of the node being pointed to. */ target->reference_count++; target->st_nlink++; IMFS_update_ctime( target ); a0005d58: e5843048 str r3, [r4, #72] ; 0x48 return 0; } a0005d5c: e28dd024 add sp, sp, #36 ; 0x24 a0005d60: e8bd8010 pop {r4, pc} =============================================================================== a00075ac : const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { a00075ac: e92d40f0 push {r4, r5, r6, r7, lr} a00075b0: e1a07003 mov r7, r3 int rv = 0; mode &= ~rtems_filesystem_umask; a00075b4: e59f3100 ldr r3, [pc, #256] ; a00076bc const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { a00075b8: e24dd05c sub sp, sp, #92 ; 0x5c a00075bc: e1a0c000 mov ip, r0 int rv = 0; mode &= ~rtems_filesystem_umask; a00075c0: e5933000 ldr r3, [r3] const char *path, mode_t mode, const IMFS_node_control *node_control, void *context ) { a00075c4: e1a05002 mov r5, r2 int rv = 0; mode &= ~rtems_filesystem_umask; a00075c8: e5936008 ldr r6, [r3, #8] a00075cc: e1c16006 bic r6, r1, r6 switch (mode & S_IFMT) { a00075d0: e2063a0f and r3, r6, #61440 ; 0xf000 a00075d4: e3530a02 cmp r3, #8192 ; 0x2000 a00075d8: 0a000006 beq a00075f8 a00075dc: 8a000001 bhi a00075e8 a00075e0: e3530a01 cmp r3, #4096 ; 0x1000 <== NOT EXECUTED a00075e4: ea000002 b a00075f4 <== NOT EXECUTED a00075e8: e3530a06 cmp r3, #24576 ; 0x6000 a00075ec: 0a000001 beq a00075f8 a00075f0: e3530902 cmp r3, #32768 ; 0x8000 a00075f4: 1a000029 bne a00076a0 rv = -1; break; } if ( rv == 0 ) { if ( node_control->imfs_type == IMFS_GENERIC ) { a00075f8: e5953000 ldr r3, [r5] a00075fc: e3530007 cmp r3, #7 a0007600: 1a000026 bne a00076a0 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 = a0007604: e1a0100c mov r1, ip a0007608: e3a02078 mov r2, #120 ; 0x78 a000760c: e28d0008 add r0, sp, #8 a0007610: eb0007c4 bl a0009528 a0007614: e1a04000 mov r4, r0 rtems_filesystem_eval_path_start( &ctx, path, eval_flags ); if ( IMFS_is_imfs_instance( currentloc ) ) { a0007618: ebffffd1 bl a0007564 a000761c: e3500000 cmp r0, #0 a0007620: 0a000017 beq a0007684 IMFS_types_union info; IMFS_jnode_t *new_node; info.generic.context = context; a0007624: e28d305c add r3, sp, #92 ; 0x5c a0007628: e523701c str r7, [r3, #-28]! new_node = IMFS_create_node_with_control( a000762c: e58d3004 str r3, [sp, #4] a0007630: e1a00004 mov r0, r4 a0007634: e1a01005 mov r1, r5 a0007638: e59d2010 ldr r2, [sp, #16] a000763c: e59d3014 ldr r3, [sp, #20] a0007640: e58d6000 str r6, [sp] a0007644: eb002a95 bl a00120a0 rtems_filesystem_eval_path_get_tokenlen( &ctx ), mode, &info ); if ( new_node != NULL ) { a0007648: e3500000 cmp r0, #0 a000764c: 0a00000f beq a0007690 IMFS_jnode_t *parent = currentloc->node_access; IMFS_update_ctime( parent ); a0007650: e3a01000 mov r1, #0 a0007654: e28d0054 add r0, sp, #84 ; 0x54 mode, &info ); if ( new_node != NULL ) { IMFS_jnode_t *parent = currentloc->node_access; a0007658: e5944008 ldr r4, [r4, #8] IMFS_update_ctime( parent ); a000765c: eb00025a bl a0007fcc a0007660: e59d3054 ldr r3, [sp, #84] ; 0x54 IMFS_update_mtime( parent ); a0007664: e28d0054 add r0, sp, #84 ; 0x54 a0007668: e3a01000 mov r1, #0 ); if ( new_node != NULL ) { IMFS_jnode_t *parent = currentloc->node_access; IMFS_update_ctime( parent ); a000766c: e5843048 str r3, [r4, #72] ; 0x48 IMFS_update_mtime( parent ); a0007670: eb000255 bl a0007fcc a0007674: e59d3054 ldr r3, [sp, #84] ; 0x54 a0007678: e5843044 str r3, [r4, #68] ; 0x44 a000767c: e3a04000 mov r4, #0 a0007680: ea000003 b a0007694 } else { rv = -1; } } else { rtems_filesystem_eval_path_error( &ctx, ENOTSUP ); a0007684: e28d0008 add r0, sp, #8 a0007688: e3a01086 mov r1, #134 ; 0x86 a000768c: eb0006ef bl a0009250 IMFS_jnode_t *parent = currentloc->node_access; IMFS_update_ctime( parent ); IMFS_update_mtime( parent ); } else { rv = -1; a0007690: e3e04000 mvn r4, #0 } else { rtems_filesystem_eval_path_error( &ctx, ENOTSUP ); rv = -1; } rtems_filesystem_eval_path_cleanup( &ctx ); a0007694: e28d0008 add r0, sp, #8 a0007698: eb0007aa bl a0009548 a000769c: ea000003 b a00076b0 } else { errno = EINVAL; a00076a0: eb0039d1 bl a0015dec <__errno> a00076a4: e3a03016 mov r3, #22 a00076a8: e5803000 str r3, [r0] rv = -1; a00076ac: e3e04000 mvn r4, #0 } } return rv; } a00076b0: e1a00004 mov r0, r4 a00076b4: e28dd05c add sp, sp, #92 ; 0x5c a00076b8: e8bd80f0 pop {r4, r5, r6, r7, pc} =============================================================================== a0010600 : */ MEMFILE_STATIC int IMFS_memfile_addblock( IMFS_jnode_t *the_jnode, unsigned int block ) { a0010600: e92d4030 push {r4, r5, lr} IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Obtain the pointer for the specified block number */ block_entry_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 1 ); a0010604: e3a02001 mov r2, #1 a0010608: ebfffef9 bl a00101f4 if ( *block_entry_ptr ) a001060c: e5904000 ldr r4, [r0] IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Obtain the pointer for the specified block number */ block_entry_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 1 ); a0010610: e1a05000 mov r5, r0 if ( *block_entry_ptr ) a0010614: e3540000 cmp r4, #0 a0010618: 1a000005 bne a0010634 return 0; /* * There is no memory for this block number so allocate it. */ memory = memfile_alloc_block(); a001061c: ebfffee7 bl a00101c0 if ( !memory ) a0010620: e3500000 cmp r0, #0 a0010624: 0a000004 beq a001063c return 1; *block_entry_ptr = memory; a0010628: e5850000 str r0, [r5] return 0; a001062c: e1a00004 mov r0, r4 a0010630: e8bd8030 pop {r4, r5, pc} /* * Obtain the pointer for the specified block number */ block_entry_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 1 ); if ( *block_entry_ptr ) return 0; a0010634: e3a00000 mov r0, #0 a0010638: e8bd8030 pop {r4, r5, pc} /* * There is no memory for this block number so allocate it. */ memory = memfile_alloc_block(); if ( !memory ) return 1; a001063c: e3a00001 mov r0, #1 <== NOT EXECUTED *block_entry_ptr = memory; return 0; } a0010640: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED =============================================================================== a00107f0 : MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { a00107f0: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Verify new file size is supported */ if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) a00107f4: e59f9184 ldr r9, [pc, #388] ; a0010980 MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { a00107f8: e24dd01c sub sp, sp, #28 a00107fc: 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 ) a0010800: e5998000 ldr r8, [r9] MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { a0010804: e20110ff and r1, r1, #255 ; 0xff a0010808: e58d1010 str r1, [sp, #16] IMFS_assert( IMFS_type( the_jnode ) == IMFS_MEMORY_FILE ); /* * Verify new file size is supported */ if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE ) a001080c: e1a03128 lsr r3, r8, #2 a0010810: e2831001 add r1, r3, #1 a0010814: e0010193 mul r1, r3, r1 a0010818: e2811001 add r1, r1, #1 a001081c: e0010193 mul r1, r3, r1 a0010820: e2411001 sub r1, r1, #1 a0010824: e0010198 mul r1, r8, r1 a0010828: e3a03000 mov r3, #0 a001082c: e1a02001 mov r2, r1 MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, bool zero_fill, off_t new_length ) { a0010830: 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 ) a0010834: e89d0003 ldm sp, {r0, r1} a0010838: e1500002 cmp r0, r2 a001083c: e0d11003 sbcs r1, r1, r3 a0010840: ba000002 blt a0010850 rtems_set_errno_and_return_minus_one( EFBIG ); a0010844: eb000434 bl a001191c <__errno> a0010848: e3a0301b mov r3, #27 a001084c: ea000035 b a0010928 /* * Verify new file size is actually larger than current size */ if ( new_length <= the_jnode->info.file.size ) a0010850: e2863050 add r3, r6, #80 ; 0x50 a0010854: e893000c ldm r3, {r2, r3} a0010858: e89d0003 ldm sp, {r0, r1} a001085c: e1520000 cmp r2, r0 a0010860: e0d31001 sbcs r1, r3, r1 a0010864: e58d2008 str r2, [sp, #8] a0010868: e58d300c str r3, [sp, #12] a001086c: aa000040 bge a0010974 return 0; /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK; a0010870: e1a05fc8 asr r5, r8, #31 a0010874: e1a02008 mov r2, r8 a0010878: e1a03005 mov r3, r5 a001087c: e89d0003 ldm sp, {r0, r1} a0010880: eb002b09 bl a001b4ac <__divdi3> old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK; a0010884: e1a02008 mov r2, r8 return 0; /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK; a0010888: e1a0b000 mov fp, r0 old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK; a001088c: e1a03005 mov r3, r5 a0010890: e28d1008 add r1, sp, #8 a0010894: e8910003 ldm r1, {r0, r1} a0010898: eb002b03 bl a001b4ac <__divdi3> offset = the_jnode->info.file.size - old_blocks * IMFS_MEMFILE_BYTES_PER_BLOCK; a001089c: e0080890 mul r8, r0, r8 a00108a0: e59d2008 ldr r2, [sp, #8] /* * 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; a00108a4: e1a0a000 mov sl, 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++ ) { a00108a8: e1a04000 mov r4, 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; offset = the_jnode->info.file.size - old_blocks * IMFS_MEMFILE_BYTES_PER_BLOCK; a00108ac: e0688002 rsb r8, r8, r2 a00108b0: ea000020 b a0010938 /* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) { if ( !IMFS_memfile_addblock( the_jnode, block ) ) { a00108b4: e1a00006 mov r0, r6 a00108b8: e1a01004 mov r1, r4 a00108bc: ebffff4f bl a0010600 a00108c0: e2507000 subs r7, r0, #0 a00108c4: 1a000013 bne a0010918 if ( zero_fill ) { a00108c8: e59d3010 ldr r3, [sp, #16] a00108cc: e3530000 cmp r3, #0 a00108d0: 0a000017 beq a0010934 size_t count = IMFS_MEMFILE_BYTES_PER_BLOCK - offset; block_p *block_ptr = a00108d4: e1a01004 mov r1, r4 <== NOT EXECUTED a00108d8: e1a02007 mov r2, r7 <== NOT EXECUTED a00108dc: e1a00006 mov r0, r6 <== 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; a00108e0: e5995000 ldr r5, [r9] <== NOT EXECUTED block_p *block_ptr = a00108e4: ebfffe42 bl a00101f4 <== NOT EXECUTED IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); memset( &(*block_ptr) [offset], 0, count); a00108e8: 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; a00108ec: e0685005 rsb r5, r8, r5 <== NOT EXECUTED block_p *block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); memset( &(*block_ptr) [offset], 0, count); a00108f0: e1a01007 mov r1, r7 <== NOT EXECUTED a00108f4: e0800008 add r0, r0, r8 <== NOT EXECUTED a00108f8: e1a02005 mov r2, r5 <== NOT EXECUTED a00108fc: eb000676 bl a00122dc <== NOT EXECUTED offset = 0; a0010900: e1a08007 mov r8, r7 <== NOT EXECUTED a0010904: ea00000a b a0010934 <== NOT EXECUTED } } else { for ( ; block>=old_blocks ; block-- ) { IMFS_memfile_remove_block( the_jnode, block ); a0010908: e1a01004 mov r1, r4 <== NOT EXECUTED a001090c: e1a00006 mov r0, r6 <== NOT EXECUTED a0010910: ebffffac bl a00107c8 <== NOT EXECUTED memset( &(*block_ptr) [offset], 0, count); offset = 0; } } else { for ( ; block>=old_blocks ; block-- ) { a0010914: e2444001 sub r4, r4, #1 <== NOT EXECUTED a0010918: e154000a cmp r4, sl <== NOT EXECUTED a001091c: 2afffff9 bcs a0010908 <== NOT EXECUTED IMFS_memfile_remove_block( the_jnode, block ); } rtems_set_errno_and_return_minus_one( ENOSPC ); a0010920: eb0003fd bl a001191c <__errno> <== NOT EXECUTED a0010924: e3a0301c mov r3, #28 <== NOT EXECUTED a0010928: e5803000 str r3, [r0] a001092c: e3e00000 mvn r0, #0 a0010930: ea000010 b a0010978 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++ ) { a0010934: e2844001 add r4, r4, #1 a0010938: e154000b cmp r4, fp a001093c: 9affffdc bls a00108b4 } /* * Set the new length of the file. */ the_jnode->info.file.size = new_length; a0010940: e89d0003 ldm sp, {r0, r1} a0010944: e5860050 str r0, [r6, #80] ; 0x50 a0010948: e5861054 str r1, [r6, #84] ; 0x54 IMFS_update_ctime(the_jnode); a001094c: e3a01000 mov r1, #0 a0010950: e28d0014 add r0, sp, #20 a0010954: ebffd6ea bl a0006504 a0010958: e59d3014 ldr r3, [sp, #20] IMFS_update_mtime(the_jnode); a001095c: e28d0014 add r0, sp, #20 a0010960: e3a01000 mov r1, #0 /* * Set the new length of the file. */ the_jnode->info.file.size = new_length; IMFS_update_ctime(the_jnode); a0010964: e5863048 str r3, [r6, #72] ; 0x48 IMFS_update_mtime(the_jnode); a0010968: ebffd6e5 bl a0006504 a001096c: e59d3014 ldr r3, [sp, #20] a0010970: e5863044 str r3, [r6, #68] ; 0x44 /* * Verify new file size is actually larger than current size */ if ( new_length <= the_jnode->info.file.size ) return 0; a0010974: e3a00000 mov r0, #0 the_jnode->info.file.size = new_length; IMFS_update_ctime(the_jnode); IMFS_update_mtime(the_jnode); return 0; } a0010978: e28dd01c add sp, sp, #28 a001097c: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} =============================================================================== a00101f4 : my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { a00101f4: e59f31e4 ldr r3, [pc, #484] ; a00103e0 #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { a00101f8: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { a00101fc: e5935000 ldr r5, [r3] #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { a0010200: e1a04000 mov r4, r0 a0010204: e1a06001 mov r6, r1 my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { a0010208: e1a05125 lsr r5, r5, #2 a001020c: e2453001 sub r3, r5, #1 a0010210: e1510003 cmp r1, r3 #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) { a0010214: e1a08002 mov r8, r2 my_block = block; /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { a0010218: 8a00000e bhi a0010258 p = info->indirect; if ( malloc_it ) { a001021c: e3520000 cmp r2, #0 /* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) { p = info->indirect; a0010220: e5900058 ldr r0, [r0, #88] ; 0x58 if ( malloc_it ) { a0010224: 0a000007 beq a0010248 if ( !p ) { a0010228: e3500000 cmp r0, #0 a001022c: 1a000003 bne a0010240 p = memfile_alloc_block(); a0010230: ebffffe2 bl a00101c0 if ( !p ) a0010234: e3500000 cmp r0, #0 a0010238: 0a000067 beq a00103dc return 0; info->indirect = p; a001023c: e5840058 str r0, [r4, #88] ; 0x58 } return &info->indirect[ my_block ]; a0010240: e5940058 ldr r0, [r4, #88] ; 0x58 a0010244: ea000001 b a0010250 } if ( !p ) a0010248: e3500000 cmp r0, #0 a001024c: 0a000062 beq a00103dc return 0; return &info->indirect[ my_block ]; a0010250: e0800106 add r0, r0, r6, lsl #2 a0010254: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} /* * Is the block number in the doubly indirect portion? */ if ( my_block <= LAST_DOUBLY_INDIRECT ) { a0010258: e2853001 add r3, r5, #1 a001025c: e0030395 mul r3, r5, r3 a0010260: e2432001 sub r2, r3, #1 a0010264: e1510002 cmp r1, r2 a0010268: 8a000021 bhi a00102f4 my_block -= FIRST_DOUBLY_INDIRECT; a001026c: e0656001 rsb r6, r5, r1 singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; a0010270: e1a00006 mov r0, r6 a0010274: e1a01005 mov r1, r5 a0010278: eb0029de bl a001a9f8 <__umodsi3> doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; a001027c: e1a01005 mov r1, r5 */ if ( my_block <= LAST_DOUBLY_INDIRECT ) { my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; a0010280: e1a07000 mov r7, r0 doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; a0010284: e1a00006 mov r0, r6 a0010288: eb002994 bl a001a8e0 <__aeabi_uidiv> p = info->doubly_indirect; if ( malloc_it ) { a001028c: e3580000 cmp r8, #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; a0010290: e1a05000 mov r5, r0 p = info->doubly_indirect; a0010294: e594005c ldr r0, [r4, #92] ; 0x5c if ( malloc_it ) { a0010298: 0a00000e beq a00102d8 if ( !p ) { a001029c: e3500000 cmp r0, #0 a00102a0: 1a000003 bne a00102b4 p = memfile_alloc_block(); a00102a4: ebffffc5 bl a00101c0 if ( !p ) a00102a8: e3500000 cmp r0, #0 a00102ac: 0a00004a beq a00103dc return 0; info->doubly_indirect = p; a00102b0: e584005c str r0, [r4, #92] ; 0x5c } p1 = (block_p *)p[ doubly ]; a00102b4: e0804105 add r4, r0, r5, lsl #2 a00102b8: e7900105 ldr r0, [r0, r5, lsl #2] if ( !p1 ) { a00102bc: e3500000 cmp r0, #0 a00102c0: 1a000009 bne a00102ec p1 = memfile_alloc_block(); a00102c4: ebffffbd bl a00101c0 if ( !p1 ) a00102c8: e3500000 cmp r0, #0 return 0; p[ doubly ] = (block_p) p1; a00102cc: 15840000 strne r0, [r4] } p1 = (block_p *)p[ doubly ]; if ( !p1 ) { p1 = memfile_alloc_block(); if ( !p1 ) a00102d0: 1a000005 bne a00102ec a00102d4: ea000040 b a00103dc <== NOT EXECUTED } return (block_p *)&p1[ singly ]; } if ( !p ) a00102d8: e3500000 cmp r0, #0 a00102dc: 0a00003e beq a00103dc return 0; p = (block_p *)p[ doubly ]; a00102e0: e7900105 ldr r0, [r0, r5, lsl #2] if ( !p ) a00102e4: e3500000 cmp r0, #0 a00102e8: 0a00003b beq a00103dc return 0; return (block_p *)&p[ singly ]; a00102ec: e0800107 add r0, r0, r7, lsl #2 a00102f0: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} } /* * Is the block number in the triply indirect portion? */ if ( my_block <= LAST_TRIPLY_INDIRECT ) { a00102f4: e2832001 add r2, r3, #1 a00102f8: e0020295 mul r2, r5, r2 a00102fc: e2422001 sub r2, r2, #1 a0010300: e1510002 cmp r1, r2 a0010304: 8a000033 bhi a00103d8 my_block -= FIRST_TRIPLY_INDIRECT; a0010308: e0636001 rsb r6, r3, r1 singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; a001030c: e1a00006 mov r0, r6 a0010310: e1a01005 mov r1, r5 a0010314: eb0029b7 bl a001a9f8 <__umodsi3> doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; a0010318: e1a01005 mov r1, r5 * 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; a001031c: e1a0a000 mov sl, r0 doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; a0010320: e1a00006 mov r0, r6 a0010324: eb00296d bl a001a8e0 <__aeabi_uidiv> triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; a0010328: e1a01005 mov r1, r5 */ 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; a001032c: e1a06000 mov r6, r0 triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; a0010330: eb00296a bl a001a8e0 <__aeabi_uidiv> doubly %= IMFS_MEMFILE_BLOCK_SLOTS; a0010334: e1a01005 mov r1, r5 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; a0010338: e1a07000 mov r7, r0 doubly %= IMFS_MEMFILE_BLOCK_SLOTS; a001033c: e1a00006 mov r0, r6 a0010340: eb0029ac bl a001a9f8 <__umodsi3> p = info->triply_indirect; if ( malloc_it ) { a0010344: e3580000 cmp r8, #0 my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS; triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS; doubly %= IMFS_MEMFILE_BLOCK_SLOTS; a0010348: e1a05000 mov r5, r0 p = info->triply_indirect; a001034c: e5940060 ldr r0, [r4, #96] ; 0x60 if ( malloc_it ) { a0010350: 0a000016 beq a00103b0 if ( !p ) { a0010354: e3500000 cmp r0, #0 a0010358: 1a000003 bne a001036c p = memfile_alloc_block(); a001035c: ebffff97 bl a00101c0 if ( !p ) a0010360: e3500000 cmp r0, #0 a0010364: 0a00001c beq a00103dc return 0; info->triply_indirect = p; a0010368: e5840060 str r0, [r4, #96] ; 0x60 } p1 = (block_p *) p[ triply ]; a001036c: e0804107 add r4, r0, r7, lsl #2 a0010370: e7900107 ldr r0, [r0, r7, lsl #2] if ( !p1 ) { a0010374: e3500000 cmp r0, #0 a0010378: 1a000003 bne a001038c p1 = memfile_alloc_block(); a001037c: ebffff8f bl a00101c0 if ( !p1 ) a0010380: e3500000 cmp r0, #0 a0010384: 0a000014 beq a00103dc return 0; p[ triply ] = (block_p) p1; a0010388: e5840000 str r0, [r4] } p2 = (block_p *)p1[ doubly ]; a001038c: e0804105 add r4, r0, r5, lsl #2 a0010390: e7900105 ldr r0, [r0, r5, lsl #2] if ( !p2 ) { a0010394: e3500000 cmp r0, #0 a0010398: 1a00000c bne a00103d0 p2 = memfile_alloc_block(); a001039c: ebffff87 bl a00101c0 if ( !p2 ) a00103a0: e3500000 cmp r0, #0 return 0; p1[ doubly ] = (block_p) p2; a00103a4: 15840000 strne r0, [r4] } p2 = (block_p *)p1[ doubly ]; if ( !p2 ) { p2 = memfile_alloc_block(); if ( !p2 ) a00103a8: 1a000008 bne a00103d0 a00103ac: ea00000a b a00103dc <== NOT EXECUTED p1[ doubly ] = (block_p) p2; } return (block_p *)&p2[ singly ]; } if ( !p ) a00103b0: e3500000 cmp r0, #0 a00103b4: 0a000008 beq a00103dc return 0; p1 = (block_p *) p[ triply ]; a00103b8: e7900107 ldr r0, [r0, r7, lsl #2] if ( !p1 ) a00103bc: e3500000 cmp r0, #0 a00103c0: 0a000005 beq a00103dc return 0; p2 = (block_p *)p1[ doubly ]; a00103c4: e7900105 ldr r0, [r0, r5, lsl #2] if ( !p2 ) a00103c8: e3500000 cmp r0, #0 a00103cc: 0a000002 beq a00103dc return 0; return (block_p *)&p2[ singly ]; a00103d0: e080010a add r0, r0, sl, lsl #2 a00103d4: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} } /* * This means the requested block number is out of range. */ return 0; a00103d8: e3a00000 mov r0, #0 <== NOT EXECUTED } a00103dc: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED =============================================================================== a00106b4 : /* * 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; a00106b4: e59f3108 ldr r3, [pc, #264] ; a00107c4 * is better to stick to simple, easy to understand algorithms. */ IMFS_jnode_t *IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) { a00106b8: 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; a00106bc: e5935000 ldr r5, [r3] * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; if ( info->indirect ) { a00106c0: e5903058 ldr r3, [r0, #88] ; 0x58 * is better to stick to simple, easy to understand algorithms. */ IMFS_jnode_t *IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) { a00106c4: e1a04000 mov r4, 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; a00106c8: e1a05125 lsr r5, r5, #2 * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; if ( info->indirect ) { a00106cc: e3530000 cmp r3, #0 a00106d0: 0a000002 beq a00106e0 memfile_free_blocks_in_table( &info->indirect, to_free ); a00106d4: e2800058 add r0, r0, #88 ; 0x58 <== NOT EXECUTED a00106d8: e1a01005 mov r1, r5 <== NOT EXECUTED a00106dc: ebffffe0 bl a0010664 <== NOT EXECUTED } if ( info->doubly_indirect ) { a00106e0: e594305c ldr r3, [r4, #92] ; 0x5c a00106e4: e3530000 cmp r3, #0 a00106e8: 13a06000 movne r6, #0 for ( i=0 ; i if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { a00106f0: 1a000008 bne a0010718 a00106f4: ea00000d b a0010730 for ( i=0 ; idoubly_indirect[i] ) { a00106f8: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED a00106fc: e0830106 add r0, r3, r6, lsl #2 <== NOT EXECUTED a0010700: e7933106 ldr r3, [r3, r6, lsl #2] <== NOT EXECUTED a0010704: e3530000 cmp r3, #0 <== NOT EXECUTED a0010708: 0a000001 beq a0010714 <== NOT EXECUTED memfile_free_blocks_in_table( a001070c: e1a01005 mov r1, r5 <== NOT EXECUTED a0010710: ebffffd3 bl a0010664 <== 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 ); a0010724: e284005c add r0, r4, #92 ; 0x5c <== NOT EXECUTED a0010728: e1a01005 mov r1, r5 <== NOT EXECUTED a001072c: ebffffcc bl a0010664 <== NOT EXECUTED } if ( info->triply_indirect ) { a0010730: e5943060 ldr r3, [r4, #96] ; 0x60 a0010734: e3530000 cmp r3, #0 a0010738: 13a06000 movne r6, #0 for ( i=0 ; i } memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { a0010740: 1a000017 bne a00107a4 a0010744: ea00001c b a00107bc for ( i=0 ; itriply_indirect[i]; a0010748: e5943060 ldr r3, [r4, #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( a001074c: e1a09106 lsl r9, r6, #2 <== NOT EXECUTED } if ( info->triply_indirect ) { for ( i=0 ; itriply_indirect[i]; a0010750: e7938106 ldr r8, [r3, r6, lsl #2] <== NOT EXECUTED if ( !p ) /* ensure we have a valid pointer */ a0010754: e3580000 cmp r8, #0 <== NOT EXECUTED a0010758: 0a000014 beq a00107b0 <== NOT EXECUTED a001075c: e3a07000 mov r7, #0 <== NOT EXECUTED a0010760: ea000007 b a0010784 <== NOT EXECUTED break; for ( j=0 ; j <== NOT EXECUTED memfile_free_blocks_in_table( (block_p **)&p[j], to_free); a0010778: e1a01005 mov r1, r5 <== NOT EXECUTED a001077c: ebffffb8 bl a0010664 <== 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 if ( p[j] ) { memfile_free_blocks_in_table( (block_p **)&p[j], to_free); } } memfile_free_blocks_in_table( a0010790: e5940060 ldr r0, [r4, #96] ; 0x60 <== NOT EXECUTED a0010794: e1a01005 mov r1, r5 <== NOT EXECUTED memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i <== NOT EXECUTED memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i <== NOT EXECUTED } } memfile_free_blocks_in_table( (block_p **)&info->triply_indirect[i], to_free ); } memfile_free_blocks_in_table( a00107b0: e2840060 add r0, r4, #96 ; 0x60 <== NOT EXECUTED a00107b4: e1a01005 mov r1, r5 <== NOT EXECUTED a00107b8: ebffffa9 bl a0010664 <== NOT EXECUTED (block_p **)&info->triply_indirect, to_free ); } return the_jnode; } a00107bc: e1a00004 mov r0, r4 a00107c0: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} =============================================================================== a00107c8 : */ MEMFILE_STATIC int IMFS_memfile_remove_block( IMFS_jnode_t *the_jnode, unsigned int block ) { a00107c8: 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 ); a00107cc: e3a02000 mov r2, #0 <== NOT EXECUTED a00107d0: ebfffe87 bl a00101f4 <== NOT EXECUTED IMFS_assert( block_ptr ); ptr = *block_ptr; *block_ptr = 0; a00107d4: e3a02000 mov r2, #0 <== NOT EXECUTED ) { block_p *block_ptr; block_p ptr; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); a00107d8: e1a03000 mov r3, r0 <== NOT EXECUTED IMFS_assert( block_ptr ); ptr = *block_ptr; a00107dc: e5900000 ldr r0, [r0] <== NOT EXECUTED *block_ptr = 0; a00107e0: e5832000 str r2, [r3] <== NOT EXECUTED memfile_free_block( ptr ); a00107e4: ebffff96 bl a0010644 <== NOT EXECUTED return 1; } a00107e8: e3a00001 mov r0, #1 <== NOT EXECUTED a00107ec: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0005e34 : #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; a0005e34: e5903020 ldr r3, [r0, #32] #endif #include "imfs.h" int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { a0005e38: e52de004 push {lr} ; (str lr, [sp, #-4]!) int rv = 0; IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; a0005e3c: 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; a0005e40: e593204c ldr r2, [r3, #76] ; 0x4c if ( IMFS_is_directory( node ) ) { a0005e44: e5922000 ldr r2, [r2] a0005e48: e3520000 cmp r2, #0 a0005e4c: 1a000009 bne a0005e78 if ( node->info.directory.mt_fs == NULL ) { a0005e50: e593205c ldr r2, [r3, #92] ; 0x5c a0005e54: e3520000 cmp r2, #0 node->info.directory.mt_fs = mt_entry; a0005e58: 0583005c streq r0, [r3, #92] ; 0x5c #include "imfs.h" int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) { int rv = 0; a0005e5c: 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 ) { a0005e60: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) node->info.directory.mt_fs = mt_entry; } else { errno = EBUSY; a0005e64: eb002eac bl a001191c <__errno> <== NOT EXECUTED a0005e68: e3a03010 mov r3, #16 <== NOT EXECUTED a0005e6c: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; a0005e70: e3e00000 mvn r0, #0 <== NOT EXECUTED a0005e74: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } } else { errno = ENOTDIR; a0005e78: eb002ea7 bl a001191c <__errno> a0005e7c: e3a03014 mov r3, #20 a0005e80: e5803000 str r3, [r0] rv = -1; a0005e84: e3e00000 mvn r0, #0 } return rv; } a0005e88: e49df004 pop {pc} ; (ldr pc, [sp], #4) =============================================================================== a000e180 : static IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node ) { if ( !rtems_chain_is_empty( &node->info.directory.Entries ) ) { a000e180: 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 ); a000e184: e2803054 add r3, r0, #84 ; 0x54 } static IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node ) { a000e188: e52de004 push {lr} ; (str lr, [sp, #-4]!) if ( !rtems_chain_is_empty( &node->info.directory.Entries ) ) { a000e18c: e1520003 cmp r2, r3 a000e190: 0a000004 beq a000e1a8 errno = ENOTEMPTY; a000e194: eb000de0 bl a001191c <__errno> <== NOT EXECUTED a000e198: e3a0305a mov r3, #90 ; 0x5a <== NOT EXECUTED a000e19c: e5803000 str r3, [r0] <== NOT EXECUTED node = NULL; a000e1a0: e3a00000 mov r0, #0 <== NOT EXECUTED a000e1a4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } else if ( IMFS_is_mount_point( node ) ) { a000e1a8: e590305c ldr r3, [r0, #92] ; 0x5c a000e1ac: e3530000 cmp r3, #0 a000e1b0: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) errno = EBUSY; a000e1b4: eb000dd8 bl a001191c <__errno> <== NOT EXECUTED a000e1b8: e3a03010 mov r3, #16 <== NOT EXECUTED a000e1bc: e5803000 str r3, [r0] <== NOT EXECUTED a000e1c0: e3a00000 mov r0, #0 <== NOT EXECUTED node = NULL; } return node; } a000e1c4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0005e8c : rtems_filesystem_node_types_t IMFS_node_type( const rtems_filesystem_location_info_t *loc ) { const IMFS_jnode_t *node = loc->node_access; a0005e8c: 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; a0005e90: e593204c ldr r2, [r3, #76] ; 0x4c a0005e94: e5920000 ldr r0, [r2] IMFS_jnode_types_t imfs_type = IMFS_type( node ); rtems_filesystem_node_types_t type; switch ( imfs_type ) { a0005e98: e3500002 cmp r0, #2 a0005e9c: 0a000002 beq a0005eac a0005ea0: e3500005 cmp r0, #5 a0005ea4: 03a00004 moveq r0, #4 a0005ea8: e12fff1e bx lr a0005eac: e5933050 ldr r3, [r3, #80] ; 0x50 <== NOT EXECUTED a0005eb0: e593304c ldr r3, [r3, #76] ; 0x4c <== NOT EXECUTED a0005eb4: e5930000 ldr r0, [r3] <== NOT EXECUTED type = imfs_type; break; } return type; } a0005eb8: e12fff1e bx lr <== NOT EXECUTED =============================================================================== a0005eec : const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { a0005eec: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} <== NOT EXECUTED int rv = 0; IMFS_jnode_t *node = oldloc->node_access; a0005ef0: e5914008 ldr r4, [r1, #8] <== NOT EXECUTED IMFS_jnode_t *new_parent = newparentloc->node_access; a0005ef4: e5925008 ldr r5, [r2, #8] <== NOT EXECUTED const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { a0005ef8: e59d601c ldr r6, [sp, #28] <== NOT EXECUTED /* * FIXME: Due to insufficient checks we can create inaccessible nodes with * this operation. */ if ( node->Parent != NULL ) { a0005efc: e5942008 ldr r2, [r4, #8] <== NOT EXECUTED a0005f00: e3520000 cmp r2, #0 <== NOT EXECUTED a0005f04: 0a00001c beq a0005f7c <== NOT EXECUTED if ( namelen < IMFS_NAME_MAX ) { a0005f08: e356001f cmp r6, #31 <== NOT EXECUTED a0005f0c: 8a000017 bhi a0005f70 <== NOT EXECUTED memcpy( node->name, name, namelen ); a0005f10: e1a01003 mov r1, r3 <== NOT EXECUTED a0005f14: e1a02006 mov r2, r6 <== NOT EXECUTED node->name [namelen] = '\0'; a0005f18: e3a07000 mov r7, #0 <== NOT EXECUTED * this operation. */ if ( node->Parent != NULL ) { if ( namelen < IMFS_NAME_MAX ) { memcpy( node->name, name, namelen ); a0005f1c: e284000c add r0, r4, #12 <== NOT EXECUTED node->name [namelen] = '\0'; a0005f20: e0846006 add r6, r4, r6 <== NOT EXECUTED * this operation. */ if ( node->Parent != NULL ) { if ( namelen < IMFS_NAME_MAX ) { memcpy( node->name, name, namelen ); a0005f24: eb0030b6 bl a0012204 <== NOT EXECUTED node->name [namelen] = '\0'; a0005f28: e5c6700c strb r7, [r6, #12] <== NOT EXECUTED { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a0005f2c: e894000c ldm r4, {r2, r3} <== NOT EXECUTED next->previous = previous; a0005f30: e5823004 str r3, [r2, #4] <== NOT EXECUTED previous->next = next; a0005f34: e5832000 str r2, [r3] <== NOT EXECUTED Chain_Control *the_chain, Chain_Node *the_node ) { Chain_Node *tail = _Chain_Tail( the_chain ); Chain_Node *old_last = tail->previous; a0005f38: 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 ); a0005f3c: e2852054 add r2, r5, #84 ; 0x54 <== NOT EXECUTED static inline void IMFS_add_to_directory( IMFS_jnode_t *dir, IMFS_jnode_t *node ) { node->Parent = dir; a0005f40: e5845008 str r5, [r4, #8] <== NOT EXECUTED Chain_Node *old_last = tail->previous; the_node->next = tail; a0005f44: e5842000 str r2, [r4] <== NOT EXECUTED tail->previous = the_node; a0005f48: e5854058 str r4, [r5, #88] ; 0x58 <== NOT EXECUTED old_last->next = the_node; a0005f4c: e5834000 str r4, [r3] <== NOT EXECUTED the_node->previous = old_last; a0005f50: e5843004 str r3, [r4, #4] <== NOT EXECUTED IMFS_remove_from_directory( node ); IMFS_add_to_directory( new_parent, node ); IMFS_update_ctime( node ); a0005f54: e1a0000d mov r0, sp <== NOT EXECUTED a0005f58: e1a01007 mov r1, r7 <== NOT EXECUTED a0005f5c: eb000168 bl a0006504 <== NOT EXECUTED a0005f60: e59d3000 ldr r3, [sp] <== NOT EXECUTED const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen ) { int rv = 0; a0005f64: 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 ); a0005f68: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED a0005f6c: ea000006 b a0005f8c <== NOT EXECUTED } else { errno = ENAMETOOLONG; a0005f70: eb002e69 bl a001191c <__errno> <== NOT EXECUTED a0005f74: e3a0305b mov r3, #91 ; 0x5b <== NOT EXECUTED a0005f78: ea000001 b a0005f84 <== NOT EXECUTED rv = -1; } } else { errno = EINVAL; a0005f7c: eb002e66 bl a001191c <__errno> <== NOT EXECUTED a0005f80: e3a03016 mov r3, #22 <== NOT EXECUTED a0005f84: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; a0005f88: e3e00000 mvn r0, #0 <== NOT EXECUTED } return rv; } a0005f8c: e8bd80fc pop {r2, r3, r4, r5, r6, r7, pc} <== NOT EXECUTED =============================================================================== a0005f90 : const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc ) { int rv = 0; IMFS_jnode_t *node = loc->node_access; a0005f90: e5910008 ldr r0, [r1, #8] int IMFS_rmnod( const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc ) { a0005f94: e52de004 push {lr} ; (str lr, [sp, #-4]!) int rv = 0; IMFS_jnode_t *node = loc->node_access; node = (*node->control->node_remove)( node ); a0005f98: e590304c ldr r3, [r0, #76] ; 0x4c a0005f9c: e593300c ldr r3, [r3, #12] a0005fa0: e12fff33 blx r3 if ( node != NULL ) { a0005fa4: e2503000 subs r3, r0, #0 a0005fa8: 0a00000d beq a0005fe4 --node->reference_count; a0005fac: e1d323b4 ldrh r2, [r3, #52] ; 0x34 --node->st_nlink; if ( node->Parent != NULL ) { a0005fb0: 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; a0005fb4: e2422001 sub r2, r2, #1 a0005fb8: e1c323b4 strh r2, [r3, #52] ; 0x34 --node->st_nlink; a0005fbc: e1d323b6 ldrh r2, [r3, #54] ; 0x36 if ( node->Parent != NULL ) { a0005fc0: e3500000 cmp r0, #0 } static inline void IMFS_remove_from_directory( IMFS_jnode_t *node ) { IMFS_assert( node->Parent != NULL ); node->Parent = NULL; a0005fc4: 13a00000 movne r0, #0 IMFS_jnode_t *node = loc->node_access; node = (*node->control->node_remove)( node ); if ( node != NULL ) { --node->reference_count; --node->st_nlink; a0005fc8: e2422001 sub r2, r2, #1 a0005fcc: e1c323b6 strh r2, [r3, #54] ; 0x36 a0005fd0: 15830008 strne r0, [r3, #8] { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; a0005fd4: 1893000c ldmne r3, {r2, r3} next->previous = previous; a0005fd8: 15823004 strne r3, [r2, #4] previous->next = next; a0005fdc: 15832000 strne r2, [r3] a0005fe0: e49df004 pop {pc} ; (ldr pc, [sp], #4) if ( node->Parent != NULL ) { IMFS_remove_from_directory( node ); } } else { rv = -1; a0005fe4: e3e00000 mvn r0, #0 <== NOT EXECUTED } return rv; } a0005fe8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a0005fec : const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, const char *target ) { a0005fec: e92d4070 push {r4, r5, r6, lr} a0005ff0: e1a04000 mov r4, r0 a0005ff4: e24dd01c sub sp, sp, #28 IMFS_jnode_t *new_node; /* * Duplicate link name */ info.sym_link.name = strdup(target); a0005ff8: e1a00003 mov r0, r3 const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, const char *target ) { a0005ffc: e1a06001 mov r6, r1 a0006000: e1a05002 mov r5, r2 IMFS_jnode_t *new_node; /* * Duplicate link name */ info.sym_link.name = strdup(target); a0006004: eb003268 bl a00129ac if (info.sym_link.name == NULL) { a0006008: e3500000 cmp r0, #0 IMFS_jnode_t *new_node; /* * Duplicate link name */ info.sym_link.name = strdup(target); a000600c: e58d0008 str r0, [sp, #8] if (info.sym_link.name == NULL) { a0006010: 0a00000f beq a0006054 size_t namelen, mode_t mode, const IMFS_types_union *info ) { const IMFS_fs_info_t *fs_info = a0006014: e5943014 ldr r3, [r4, #20] (const IMFS_fs_info_t *) parentloc->mt_entry->fs_info; return IMFS_create_node_with_control( a0006018: e59f204c ldr r2, [pc, #76] ; a000606c a000601c: e1a00004 mov r0, r4 a0006020: e5933008 ldr r3, [r3, #8] a0006024: e58d2000 str r2, [sp] parentloc, IMFS_SYM_LINK, name, namelen, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info a0006028: e28d2008 add r2, sp, #8 a000602c: e58d2004 str r2, [sp, #4] a0006030: e5931014 ldr r1, [r3, #20] a0006034: e1a02006 mov r2, r6 a0006038: e1a03005 mov r3, r5 a000603c: eb001f50 bl a000dd84 ); if (new_node == NULL) { a0006040: e3500000 cmp r0, #0 free(info.sym_link.name); rtems_set_errno_and_return_minus_one(ENOMEM); } return 0; a0006044: 13a00000 movne r0, #0 namelen, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) { a0006048: 1a000005 bne a0006064 free(info.sym_link.name); a000604c: e59d0008 ldr r0, [sp, #8] <== NOT EXECUTED a0006050: eb0000f6 bl a0006430 <== NOT EXECUTED rtems_set_errno_and_return_minus_one(ENOMEM); a0006054: eb002e30 bl a001191c <__errno> <== NOT EXECUTED a0006058: e3a0300c mov r3, #12 <== NOT EXECUTED a000605c: e5803000 str r3, [r0] <== NOT EXECUTED a0006060: e3e00000 mvn r0, #0 <== NOT EXECUTED } return 0; } a0006064: e28dd01c add sp, sp, #28 a0006068: e8bd8070 pop {r4, r5, r6, pc} =============================================================================== a0006070 : #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; a0006070: e5903020 ldr r3, [r0, #32] #endif #include "imfs.h" int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) { a0006074: e52de004 push {lr} ; (str lr, [sp, #-4]!) int rv = 0; IMFS_jnode_t *node = mt_entry->mt_point_node->location.node_access; a0006078: e5932008 ldr r2, [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; a000607c: e592304c ldr r3, [r2, #76] ; 0x4c if ( IMFS_is_directory( node ) ) { a0006080: e5933000 ldr r3, [r3] a0006084: e3530000 cmp r3, #0 a0006088: 1a000009 bne a00060b4 if ( node->info.directory.mt_fs == mt_entry ) { a000608c: e592105c ldr r1, [r2, #92] ; 0x5c a0006090: e1510000 cmp r1, r0 node->info.directory.mt_fs = NULL; a0006094: 0582305c streq r3, [r2, #92] ; 0x5c #include "imfs.h" int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) { int rv = 0; a0006098: 01a00003 moveq r0, r3 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 ) { a000609c: 049df004 popeq {pc} ; (ldreq pc, [sp], #4) node->info.directory.mt_fs = NULL; } else { errno = EINVAL; a00060a0: eb002e1d bl a001191c <__errno> <== NOT EXECUTED a00060a4: e3a03016 mov r3, #22 <== NOT EXECUTED a00060a8: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; a00060ac: e3e00000 mvn r0, #0 <== NOT EXECUTED a00060b0: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED } } else { errno = ENOTDIR; a00060b4: eb002e18 bl a001191c <__errno> <== NOT EXECUTED a00060b8: e3a03014 mov r3, #20 <== NOT EXECUTED a00060bc: e5803000 str r3, [r0] <== NOT EXECUTED rv = -1; a00060c0: e3e00000 mvn r0, #0 <== NOT EXECUTED } return rv; } a00060c4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED =============================================================================== a00060c8 : int IMFS_utime( const rtems_filesystem_location_info_t *loc, time_t actime, time_t modtime ) { a00060c8: e92d4010 push {r4, lr} <== NOT EXECUTED IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) loc->node_access; a00060cc: e5904008 ldr r4, [r0, #8] <== NOT EXECUTED the_jnode->stat_atime = actime; the_jnode->stat_mtime = modtime; the_jnode->stat_ctime = time( NULL ); a00060d0: e3a00000 mov r0, #0 <== NOT EXECUTED { IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) loc->node_access; the_jnode->stat_atime = actime; a00060d4: e5841040 str r1, [r4, #64] ; 0x40 <== NOT EXECUTED the_jnode->stat_mtime = modtime; a00060d8: e5842044 str r2, [r4, #68] ; 0x44 <== NOT EXECUTED the_jnode->stat_ctime = time( NULL ); a00060dc: eb003432 bl a00131ac