Lines Matching defs:fufh

187 fuse_filehandle_close(struct vnode *vp, struct fuse_filehandle *fufh,
209 fri->fh = fufh->fh_id;
210 fri->flags = fufh_type_2_fflags(fufh->fufh_type);
223 LIST_REMOVE(fufh, next);
224 free(fufh, M_FUSE_FILEHANDLE);
233 * a fufh type that includes the provided one.
241 struct fuse_filehandle *fufh;
248 LIST_FOREACH(fufh, &fvdat->handles, next) {
249 if (fufh->fufh_type == fufh_type &&
250 fufh->uid == cred->cr_uid &&
251 fufh->gid == cred->cr_rgid &&
252 (pid == 0 || fufh->pid == pid))
260 LIST_FOREACH(fufh, &fvdat->handles, next) {
261 if (fufh->fufh_type == FUFH_RDWR &&
262 fufh->uid == cred->cr_uid &&
263 fufh->gid == cred->cr_rgid &&
264 (pid == 0 || fufh->pid == pid))
276 struct fuse_filehandle *fufh;
284 LIST_FOREACH(fufh, &fvdat->handles, next) {
285 if (fufh->fufh_type == fufh_type &&
286 fufh->uid == cred->cr_uid &&
287 fufh->gid == cred->cr_rgid &&
288 (pid == 0 || fufh->pid == pid))
294 LIST_FOREACH(fufh, &fvdat->handles, next) {
295 if (fufh->fufh_type == fufh_type)
299 if (fufh == NULL)
304 *fufhp = fufh;
314 struct fuse_filehandle *fufh;
319 LIST_FOREACH(fufh, &fvdat->handles, next) {
320 if (fufh->uid == cred->cr_uid &&
321 fufh->gid == cred->cr_rgid &&
322 (pid == 0 || fufh->pid == pid))
328 fufh = LIST_FIRST(&fvdat->handles);
330 if (fufh == NULL)
335 *fufhp = fufh;
357 struct fuse_filehandle *fufh;
359 fufh = malloc(sizeof(struct fuse_filehandle), M_FUSE_FILEHANDLE,
361 MPASS(fufh != NULL);
362 fufh->fh_id = foo->fh;
363 fufh->fufh_type = fufh_type;
364 fufh->gid = cred->cr_rgid;
365 fufh->uid = cred->cr_uid;
366 fufh->pid = td->td_proc->p_pid;
367 fufh->fuse_open_flags = foo->open_flags;
368 if (!FUFH_IS_VALID(fufh)) {
371 LIST_INSERT_HEAD(&fvdat->handles, fufh, next);
373 *fufhp = fufh;