Lines Matching refs:ls
40 struct link_struct *ls = (struct link_struct *) priv_data;
47 if (ls->done)
50 rec_len = EXT2_DIR_REC_LEN(ls->namelen);
52 ls->err = ext2fs_get_rec_len(ls->fs, dirent, &curr_rec_len);
53 if (ls->err)
56 if (ext2fs_has_feature_metadata_csum(ls->fs->super))
67 ls->err = ext2fs_set_rec_len(ls->fs, curr_rec_len, dirent);
68 if (ls->err)
82 curr_rec_len == ls->fs->blocksize &&
85 ls->err = ext2fs_set_rec_len(ls->fs, curr_rec_len, dirent);
86 if (ls->err)
88 t = EXT2_DIRENT_TAIL(buf, ls->fs->blocksize);
89 ext2fs_initialize_dirent_tail(ls->fs, t);
95 curr_rec_len == ls->fs->blocksize - EXT2_DIR_REC_LEN(1) &&
99 ls->err = ext2fs_set_rec_len(ls->fs, curr_rec_len, dirent);
100 if (ls->err)
102 t = EXT2_DIRENT_TAIL(buf, ls->fs->blocksize);
103 ext2fs_initialize_dirent_tail(ls->fs, t);
117 ls->err = ext2fs_set_rec_len(ls->fs, min_rec_len, dirent);
118 if (ls->err)
125 ls->err = ext2fs_set_rec_len(ls->fs, rec_len, next);
126 if (ls->err)
137 dirent->inode = ls->inode;
138 ext2fs_dirent_set_name_len(dirent, ls->namelen);
139 strncpy(dirent->name, ls->name, ls->namelen);
140 if (ext2fs_has_feature_filetype(ls->sb))
141 ext2fs_dirent_set_file_type(dirent, ls->flags & 0x7);
143 ls->done++;
158 struct link_struct ls;
166 ls.fs = fs;
167 ls.name = name;
168 ls.namelen = name ? strlen(name) : 0;
169 ls.inode = ino;
170 ls.flags = flags;
171 ls.done = 0;
172 ls.sb = fs->super;
173 ls.blocksize = fs->blocksize;
174 ls.err = 0;
177 0, link_proc, &ls);
180 if (ls.err)
181 return ls.err;
183 if (!ls.done)