static struct cifsFileInfo *find_writable_file(struct cifsInodeInfo *cifs_inode)
struct cifsFileInfo *find_writable_file(struct cifsInodeInfo *cifs_inode)
static struct cifsFileInfo *find_writable_file(struct cifsInodeInfo *cifs_inode){	struct cifsFileInfo *open_file;	read_lock(&GlobalSMBSeslock);	list_for_each_entry(open_file, &cifs_inode->openFileList, flist) {		if (open_file->closePend)			continue;		if (open_file->pfile &&		    ((open_file->pfile->f_flags & O_RDWR) ||		     (open_file->pfile->f_flags & O_WRONLY))) {			read_unlock(&GlobalSMBSeslock);			if(open_file->invalidHandle) {				rc = cifs_reopen_file(cifs_inode->vfs_inode, 						      open_file->pfile, FALSE);				/* if it fails, try another handle - might be */				/* dangerous to hold up writepages with retry */				if(rc) {					cFYI(1,("failed on reopen file in wp"));					read_lock(&GlobalSMBSeslock);					continue;				}			}			return open_file;		}	}	read_unlock(&GlobalSMBSeslock);	return NULL;}