Home
last modified time | relevance | path

Searched refs:inode (Results 1 – 10 of 10) sorted by relevance

/lk-master/lib/fs/ext2/
A Dfile.c34 err = ext2_load_inode(ext2, inum, &file->inode); in ext2_open_file()
51 if (!S_ISREG(file->inode.i_mode)) { in ext2_read_file()
78 off_t ext2_file_len(ext2_t *ext2, struct ext2_inode *inode) { in ext2_file_len() argument
80 off_t len = inode->i_size; in ext2_file_len()
83 len |= (off_t)inode->i_size_high << 32; in ext2_file_len()
92 stat->size = ext2_file_len(file->ext2, &file->inode); in ext2_stat_file()
96 if (S_ISDIR(file->inode.i_mode)) in ext2_stat_file()
103 LTRACEF("inode %p, str %p, len %zu\n", inode, str, len); in ext2_read_link()
105 off_t linklen = ext2_file_len(ext2, inode); in ext2_read_link()
111 int err = ext2_read_inode(ext2, inode, str, 0, linklen); in ext2_read_link()
[all …]
A Dext2.c63 LE16SWAP(inode->i_mode); in endian_swap_inode()
64 LE16SWAP(inode->i_uid_low); in endian_swap_inode()
65 LE32SWAP(inode->i_size); in endian_swap_inode()
66 LE32SWAP(inode->i_atime); in endian_swap_inode()
67 LE32SWAP(inode->i_ctime); in endian_swap_inode()
68 LE32SWAP(inode->i_mtime); in endian_swap_inode()
69 LE32SWAP(inode->i_dtime); in endian_swap_inode()
72 LE32SWAP(inode->i_blocks); in endian_swap_inode()
73 LE32SWAP(inode->i_flags); in endian_swap_inode()
80 LE32SWAP(inode->i_faddr); in endian_swap_inode()
[all …]
A Dext3_fs.h502 static inline struct ext3_inode_info *EXT3_I(struct inode *inode) { in EXT3_I() argument
520 #define NEXT_ORPHAN(inode) EXT3_I(inode)->i_dtime argument
755 extern ext3_fsblk_t ext3_new_block (handle_t *handle, struct inode *inode,
757 extern ext3_fsblk_t ext3_new_blocks (handle_t *handle, struct inode *inode,
759 extern void ext3_free_blocks (handle_t *handle, struct inode *inode,
790 extern struct inode *ext3_new_inode (handle_t *, struct inode *, int);
800 int ext3_forget(handle_t *handle, int is_metadata, struct inode *inode,
804 int ext3_get_blocks_handle(handle_t *handle, struct inode *inode,
808 extern void ext3_read_inode (struct inode *);
817 extern void ext3_truncate (struct inode *);
[all …]
A Dio.c78 static int ext2_get_indirect_block_pointer_cache_block(ext2_t *ext2, struct ext2_inode *inode, in ext2_get_indirect_block_pointer_cache_block() argument
94 current_block = LE32(inode->i_block[pos[0]]); in ext2_get_indirect_block_pointer_cache_block()
127 static blocknum_t file_block_to_fs_block(ext2_t *ext2, struct ext2_inode *inode, uint fileblock) { in file_block_to_fs_block() argument
131 LTRACEF("inode %p, fileblock %u\n", inode, fileblock); in file_block_to_fs_block()
141 block = LE32(inode->i_block[fileblock]); in file_block_to_fs_block()
163 ssize_t ext2_read_inode(ext2_t *ext2, struct ext2_inode *inode, void *_buf, off_t offset, size_t le… in ext2_read_inode() argument
169 off_t file_size = ext2_file_len(ext2, inode); in ext2_read_inode()
171 LTRACEF("inode %p, offset %lld, len %zd, file_size %lld\n", inode, offset, len, file_size); in ext2_read_inode()
189 blocknum_t phys_block = file_block_to_fs_block(ext2, inode, file_block); in ext2_read_inode()
211 blocknum_t phys_block = file_block_to_fs_block(ext2, inode, file_block); in ext2_read_inode()
[all …]
A Ddir.c45 … file_blocknum, pos, LE32(ent->inode), LE16(ent->rec_len), ent->name_len/* , ent->name*/); in ext2_dir_lookup()
53 *inum = LE32(ent->inode); in ext2_dir_lookup()
75 struct ext2_inode inode; in ext2_walk() local
114 err = ext2_load_inode(ext2, *inum, &inode); in ext2_walk()
119 if (S_ISLNK(inode.i_mode)) { in ext2_walk()
124 err = ext2_read_link(ext2, &inode, link, sizeof(link)); in ext2_walk()
147 } else if (S_ISDIR(inode.i_mode)) { in ext2_walk()
149 memcpy(&dir_inode, &inode, sizeof(struct ext2_inode)); in ext2_walk()
A Dext2_priv.h39 struct ext2_inode inode; member
43 int ext2_load_inode(ext2_t *ext2, inodenum_t num, struct ext2_inode *inode);
51 off_t ext2_file_len(ext2_t *ext2, struct ext2_inode *inode);
52 ssize_t ext2_read_inode(ext2_t *ext2, struct ext2_inode *inode, void *buf, off_t offset, size_t len…
53 int ext2_read_link(ext2_t *ext2, struct ext2_inode *inode, char *str, size_t len);
A Dext2_fs.h389 uint32_t inode; /* Inode number */ member
402 uint32_t inode; /* Inode number */ member
/lk-master/lib/norfs/
A Dnorfs.c130 if (!inode) in get_inode()
133 *inode = NULL; in get_inode()
139 *inode = curr_inode; in get_inode()
203 struct norfs_inode *inode; in norfs_read_obj_iovec() local
216 read_ptr = inode->location; in norfs_read_obj_iovec()
440 struct norfs_inode *inode; in norfs_remove_obj() local
501 struct norfs_inode *inode; in norfs_put_obj_iovec() local
584 if (!inode) in remove_inode()
587 free(inode); in remove_inode()
588 inode = NULL; in remove_inode()
[all …]
/lk-master/lib/norfs/test/include/
A Dnorfs_test_helper.h24 bool get_inode(uint32_t key, struct norfs_inode **inode);
/lk-master/lib/norfs/test/
A Dnorfs_test.c330 struct norfs_inode *inode = NULL; in test_deletion() local
341 status = get_inode(2, &inode); in test_deletion()
346 EXPECT_EQ(2, (inode)->reference_count, in test_deletion()
348 EXPECT_EQ(24, (inode)->location, "Not pointing to current version"); in test_deletion()
354 EXPECT_EQ(false, get_inode(2, &inode), in test_deletion()
364 EXPECT_EQ(true, get_inode(2, &inode), in test_deletion()

Completed in 24 milliseconds