Lines Matching refs:fd
35 struct hfs_find_data fd; in hfsplus_lookup() local
45 err = hfs_find_init(HFSPLUS_SB(sb)->cat_tree, &fd); in hfsplus_lookup()
48 err = hfsplus_cat_build_key(sb, fd.search_key, dir->i_ino, in hfsplus_lookup()
53 err = hfs_brec_read(&fd, &entry, sizeof(entry)); in hfsplus_lookup()
56 hfs_find_exit(&fd); in hfsplus_lookup()
65 if (fd.entrylength < sizeof(struct hfsplus_cat_folder)) { in hfsplus_lookup()
72 if (fd.entrylength < sizeof(struct hfsplus_cat_file)) { in hfsplus_lookup()
104 err = hfsplus_cat_build_key(sb, fd.search_key, in hfsplus_lookup()
118 hfs_find_exit(&fd); in hfsplus_lookup()
128 hfs_find_exit(&fd); in hfsplus_lookup()
139 struct hfs_find_data fd; in hfsplus_readdir() local
146 err = hfs_find_init(HFSPLUS_SB(sb)->cat_tree, &fd); in hfsplus_readdir()
154 hfsplus_cat_build_key_with_cnid(sb, fd.search_key, inode->i_ino); in hfsplus_readdir()
155 err = hfs_brec_find(&fd, hfs_find_rec_by_key); in hfsplus_readdir()
166 if (fd.entrylength > sizeof(entry) || fd.entrylength < 0) { in hfsplus_readdir()
171 hfs_bnode_read(fd.bnode, &entry, fd.entryoffset, in hfsplus_readdir()
172 fd.entrylength); in hfsplus_readdir()
178 if (fd.entrylength < HFSPLUS_MIN_THREAD_SZ) { in hfsplus_readdir()
190 err = hfs_brec_goto(&fd, ctx->pos - 1); in hfsplus_readdir()
194 if (be32_to_cpu(fd.key->cat.parent) != inode->i_ino) { in hfsplus_readdir()
200 if (fd.entrylength > sizeof(entry) || fd.entrylength < 0) { in hfsplus_readdir()
205 hfs_bnode_read(fd.bnode, &entry, fd.entryoffset, in hfsplus_readdir()
206 fd.entrylength); in hfsplus_readdir()
209 err = hfsplus_uni2asc(sb, &fd.key->cat.name, strbuf, &len); in hfsplus_readdir()
213 if (fd.entrylength < in hfsplus_readdir()
230 if (fd.entrylength < sizeof(struct hfsplus_cat_file)) { in hfsplus_readdir()
262 err = hfs_brec_goto(&fd, 1); in hfsplus_readdir()
283 memcpy(&rd->key, fd.key, sizeof(struct hfsplus_cat_key)); in hfsplus_readdir()
286 hfs_find_exit(&fd); in hfsplus_readdir()