Lines Matching refs:open_file

54 	struct cifsFileInfo *open_file = req->cfile;  in cifs_prepare_write()  local
64 server = cifs_pick_channel(tlink_tcon(open_file->tlink)->ses); in cifs_prepare_write()
72 if (open_file->invalidHandle) { in cifs_prepare_write()
73 rc = cifs_reopen_file(open_file, false); in cifs_prepare_write()
274 struct cifsFileInfo *open_file = NULL; in cifs_init_request() local
281 open_file = file->private_data; in cifs_init_request()
283 req->cfile = cifsFileInfo_get(open_file); in cifs_init_request()
372 struct cifsFileInfo *open_file = NULL; in cifs_mark_open_files_invalid() local
391 open_file = list_entry(tmp, struct cifsFileInfo, tlist); in cifs_mark_open_files_invalid()
392 open_file->invalidHandle = true; in cifs_mark_open_files_invalid()
393 open_file->oplock_break_cancelled = true; in cifs_mark_open_files_invalid()
1492 struct cifsFileInfo *open_file, *tmp; in cifs_reopen_persistent_handles() local
1504 list_for_each_entry(open_file, &tcon->openFileList, tlist) { in cifs_reopen_persistent_handles()
1505 if (!open_file->invalidHandle) in cifs_reopen_persistent_handles()
1507 cifsFileInfo_get(open_file); in cifs_reopen_persistent_handles()
1508 list_add_tail(&open_file->rlist, &tmp_list); in cifs_reopen_persistent_handles()
1512 list_for_each_entry_safe(open_file, tmp, &tmp_list, rlist) { in cifs_reopen_persistent_handles()
1513 if (cifs_reopen_file(open_file, false /* do not flush */)) in cifs_reopen_persistent_handles()
1515 list_del_init(&open_file->rlist); in cifs_reopen_persistent_handles()
1516 cifsFileInfo_put(open_file); in cifs_reopen_persistent_handles()
2159 struct cifsFileInfo *open_file = NULL; in cifs_get_hardlink_path() local
2166 list_for_each_entry(open_file, &cinode->openFileList, flist) { in cifs_get_hardlink_path()
2167 if (file->f_flags == open_file->f_flags) { in cifs_get_hardlink_path()
2548 struct cifsFileInfo *open_file = NULL; in __find_readable_file() local
2558 list_for_each_entry(open_file, &cifs_inode->openFileList, flist) { in __find_readable_file()
2559 if (fsuid_only && !uid_eq(open_file->uid, current_fsuid())) in __find_readable_file()
2562 open_file->status_file_deleted) in __find_readable_file()
2566 open_file->f_flags)) in __find_readable_file()
2568 if (OPEN_FMODE(open_file->f_flags) & FMODE_READ) { in __find_readable_file()
2569 if ((!open_file->invalidHandle)) { in __find_readable_file()
2572 cifsFileInfo_get(open_file); in __find_readable_file()
2574 return open_file; in __find_readable_file()
2590 struct cifsFileInfo *open_file, *inv_file = NULL; in __cifs_get_writable_file() local
2627 list_for_each_entry(open_file, &cifs_inode->openFileList, flist) { in __cifs_get_writable_file()
2628 if (!any_available && open_file->pid != current->tgid) in __cifs_get_writable_file()
2630 if (fsuid_only && !uid_eq(open_file->uid, current_fsuid())) in __cifs_get_writable_file()
2632 if (with_delete && !(open_file->fid.access & DELETE)) in __cifs_get_writable_file()
2635 open_file->status_file_deleted) in __cifs_get_writable_file()
2639 open_file->f_flags)) in __cifs_get_writable_file()
2641 if (OPEN_FMODE(open_file->f_flags) & FMODE_WRITE) { in __cifs_get_writable_file()
2642 if (!open_file->invalidHandle) { in __cifs_get_writable_file()
2644 cifsFileInfo_get(open_file); in __cifs_get_writable_file()
2646 *ret_file = open_file; in __cifs_get_writable_file()
2650 inv_file = open_file; in __cifs_get_writable_file()
3125 struct cifsFileInfo *open_file; in is_inode_writable() local
3128 list_for_each_entry(open_file, &cifs_inode->openFileList, flist) { in is_inode_writable()
3129 if (OPEN_FMODE(open_file->f_flags) & FMODE_WRITE) { in is_inode_writable()