Lines Matching defs:inode

56 		struct ext4_dir_entry_2 *prev, u32 inode, const char *name,
75 dentry->inode = inode;
86 and stores the location of the structure in an inode. The new inode's
87 .. link is set to dir_inode_num. Stores the location of the inode number
88 of each directory entry into dentries[i].inode, to be filled in later
89 when the inode for the entry is allocated. Returns the inode number of the
94 struct ext4_inode *inode;
114 error("failed to allocate inode\n");
120 inode = get_inode(inode_num);
121 if (inode == NULL) {
122 error("failed to get inode %u", inode_num);
126 data = inode_allocate_data_extents(inode, len, len);
132 inode->i_mode = S_IFDIR;
133 inode->i_links_count = dirs + 2;
134 inode->i_flags |= aux_info.default_i_flags;
156 dentries[i].inode = &dentry->inode;
164 dentry->inode = 0;
172 /* Creates a file on disk. Returns the inode number of the new file */
175 struct ext4_inode *inode;
180 error("failed to allocate inode\n");
184 inode = get_inode(inode_num);
185 if (inode == NULL) {
186 error("failed to get inode %u", inode_num);
191 inode_allocate_file_extents(inode, len, filename);
193 inode->i_mode = S_IFREG;
194 inode->i_links_count = 1;
195 inode->i_flags |= aux_info.default_i_flags;
200 /* Creates a file on disk. Returns the inode number of the new file */
203 struct ext4_inode *inode;
209 error("failed to allocate inode\n");
213 inode = get_inode(inode_num);
214 if (inode == NULL) {
215 error("failed to get inode %u", inode_num);
219 inode->i_mode = S_IFLNK;
220 inode->i_links_count = 1;
221 inode->i_flags |= aux_info.default_i_flags;
222 inode->i_size_lo = len;
224 if (len + 1 <= sizeof(inode->i_block)) {
226 memcpy((char*)inode->i_block, link, len);
228 u8 *data = inode_allocate_data_indirect(inode, info.block_size, info.block_size);
230 inode->i_blocks_lo = info.block_size / 512;
238 struct ext4_inode *inode = get_inode(inode_num);
240 if (!inode)
243 inode->i_mode |= mode;
244 inode->i_uid = uid;
245 inode->i_gid = gid;
246 inode->i_mtime = mtime;
247 inode->i_atime = mtime;
248 inode->i_ctime = mtime;
262 struct ext4_inode *inode = get_inode(inode_num);
273 if (!inode)
276 hdr = (u32 *) (inode + 1);
285 min_offs = (char *)inode + info.inode_size - (char*) entry;
291 inode->i_extra_isize = cpu_to_le16(sizeof(struct ext4_inode) - EXT4_GOOD_OLD_INODE_SIZE);