Lines Matching refs:tcon
440 cifs_negotiate_wsize(struct cifs_tcon *tcon, struct smb3_fs_context *ctx) in cifs_negotiate_wsize() argument
442 __u64 unix_cap = le64_to_cpu(tcon->fsUnixInfo.Capability); in cifs_negotiate_wsize()
443 struct TCP_Server_Info *server = tcon->ses->server; in cifs_negotiate_wsize()
449 else if (tcon->unix_ext && (unix_cap & CIFS_UNIX_LARGE_WRITE_CAP)) in cifs_negotiate_wsize()
455 if (!tcon->unix_ext || !(unix_cap & CIFS_UNIX_LARGE_WRITE_CAP)) in cifs_negotiate_wsize()
475 cifs_negotiate_rsize(struct cifs_tcon *tcon, struct smb3_fs_context *ctx) in cifs_negotiate_rsize() argument
477 __u64 unix_cap = le64_to_cpu(tcon->fsUnixInfo.Capability); in cifs_negotiate_rsize()
478 struct TCP_Server_Info *server = tcon->ses->server; in cifs_negotiate_rsize()
493 if (tcon->unix_ext && (unix_cap & CIFS_UNIX_LARGE_READ_CAP)) in cifs_negotiate_rsize()
516 cifs_qfs_tcon(const unsigned int xid, struct cifs_tcon *tcon, in cifs_qfs_tcon() argument
519 CIFSSMBQFSDeviceInfo(xid, tcon); in cifs_qfs_tcon()
520 CIFSSMBQFSAttributeInfo(xid, tcon); in cifs_qfs_tcon()
524 cifs_is_path_accessible(const unsigned int xid, struct cifs_tcon *tcon, in cifs_is_path_accessible() argument
534 rc = CIFSSMBQPathInfo(xid, tcon, full_path, file_info, in cifs_is_path_accessible()
539 rc = SMBQueryInformation(xid, tcon, full_path, file_info, in cifs_is_path_accessible()
545 static int cifs_query_path_info(const unsigned int xid, struct cifs_tcon *tcon, in cifs_query_path_info() argument
555 rc = CIFSSMBQPathInfo(xid, tcon, full_path, &fi, 0 /* not legacy */, cifs_sb->local_nls, in cifs_query_path_info()
563 rc = SMBQueryInformation(xid, tcon, full_path, &fi, cifs_sb->local_nls, in cifs_query_path_info()
579 oparms.tcon = tcon; in cifs_query_path_info()
593 CIFSSMBClose(xid, tcon, fid.netfid); in cifs_query_path_info()
599 static int cifs_get_srv_inum(const unsigned int xid, struct cifs_tcon *tcon, in cifs_get_srv_inum() argument
614 return CIFSGetSrvInodeNumber(xid, tcon, full_path, uniqueid, in cifs_get_srv_inum()
619 static int cifs_query_file_info(const unsigned int xid, struct cifs_tcon *tcon, in cifs_query_file_info() argument
631 rc = CIFSSMBQFileInfo(xid, tcon, cfile->fid.netfid, &fi); in cifs_query_file_info()
638 cifs_clear_stats(struct cifs_tcon *tcon) in cifs_clear_stats() argument
640 atomic_set(&tcon->stats.cifs_stats.num_writes, 0); in cifs_clear_stats()
641 atomic_set(&tcon->stats.cifs_stats.num_reads, 0); in cifs_clear_stats()
642 atomic_set(&tcon->stats.cifs_stats.num_flushes, 0); in cifs_clear_stats()
643 atomic_set(&tcon->stats.cifs_stats.num_oplock_brks, 0); in cifs_clear_stats()
644 atomic_set(&tcon->stats.cifs_stats.num_opens, 0); in cifs_clear_stats()
645 atomic_set(&tcon->stats.cifs_stats.num_posixopens, 0); in cifs_clear_stats()
646 atomic_set(&tcon->stats.cifs_stats.num_posixmkdirs, 0); in cifs_clear_stats()
647 atomic_set(&tcon->stats.cifs_stats.num_closes, 0); in cifs_clear_stats()
648 atomic_set(&tcon->stats.cifs_stats.num_deletes, 0); in cifs_clear_stats()
649 atomic_set(&tcon->stats.cifs_stats.num_mkdirs, 0); in cifs_clear_stats()
650 atomic_set(&tcon->stats.cifs_stats.num_rmdirs, 0); in cifs_clear_stats()
651 atomic_set(&tcon->stats.cifs_stats.num_renames, 0); in cifs_clear_stats()
652 atomic_set(&tcon->stats.cifs_stats.num_t2renames, 0); in cifs_clear_stats()
653 atomic_set(&tcon->stats.cifs_stats.num_ffirst, 0); in cifs_clear_stats()
654 atomic_set(&tcon->stats.cifs_stats.num_fnext, 0); in cifs_clear_stats()
655 atomic_set(&tcon->stats.cifs_stats.num_fclose, 0); in cifs_clear_stats()
656 atomic_set(&tcon->stats.cifs_stats.num_hardlinks, 0); in cifs_clear_stats()
657 atomic_set(&tcon->stats.cifs_stats.num_symlinks, 0); in cifs_clear_stats()
658 atomic_set(&tcon->stats.cifs_stats.num_locks, 0); in cifs_clear_stats()
659 atomic_set(&tcon->stats.cifs_stats.num_acl_get, 0); in cifs_clear_stats()
660 atomic_set(&tcon->stats.cifs_stats.num_acl_set, 0); in cifs_clear_stats()
664 cifs_print_stats(struct seq_file *m, struct cifs_tcon *tcon) in cifs_print_stats() argument
667 atomic_read(&tcon->stats.cifs_stats.num_oplock_brks)); in cifs_print_stats()
669 atomic_read(&tcon->stats.cifs_stats.num_reads), in cifs_print_stats()
670 (long long)(tcon->bytes_read)); in cifs_print_stats()
672 atomic_read(&tcon->stats.cifs_stats.num_writes), in cifs_print_stats()
673 (long long)(tcon->bytes_written)); in cifs_print_stats()
675 atomic_read(&tcon->stats.cifs_stats.num_flushes)); in cifs_print_stats()
677 atomic_read(&tcon->stats.cifs_stats.num_locks), in cifs_print_stats()
678 atomic_read(&tcon->stats.cifs_stats.num_hardlinks), in cifs_print_stats()
679 atomic_read(&tcon->stats.cifs_stats.num_symlinks)); in cifs_print_stats()
681 atomic_read(&tcon->stats.cifs_stats.num_opens), in cifs_print_stats()
682 atomic_read(&tcon->stats.cifs_stats.num_closes), in cifs_print_stats()
683 atomic_read(&tcon->stats.cifs_stats.num_deletes)); in cifs_print_stats()
685 atomic_read(&tcon->stats.cifs_stats.num_posixopens), in cifs_print_stats()
686 atomic_read(&tcon->stats.cifs_stats.num_posixmkdirs)); in cifs_print_stats()
688 atomic_read(&tcon->stats.cifs_stats.num_mkdirs), in cifs_print_stats()
689 atomic_read(&tcon->stats.cifs_stats.num_rmdirs)); in cifs_print_stats()
691 atomic_read(&tcon->stats.cifs_stats.num_renames), in cifs_print_stats()
692 atomic_read(&tcon->stats.cifs_stats.num_t2renames)); in cifs_print_stats()
694 atomic_read(&tcon->stats.cifs_stats.num_ffirst), in cifs_print_stats()
695 atomic_read(&tcon->stats.cifs_stats.num_fnext), in cifs_print_stats()
696 atomic_read(&tcon->stats.cifs_stats.num_fclose)); in cifs_print_stats()
701 struct cifs_sb_info *cifs_sb, struct cifs_tcon *tcon, in cifs_mkdir_setinfo() argument
713 rc = CIFSSMBSetPathInfo(xid, tcon, full_path, &info, cifs_sb->local_nls, in cifs_mkdir_setinfo()
726 if (!(oparms->tcon->ses->capabilities & CAP_NT_SMBS)) in cifs_open_file()
727 rc = SMBLegacyOpen(xid, oparms->tcon, oparms->path, in cifs_open_file()
753 cifs_close_file(const unsigned int xid, struct cifs_tcon *tcon, in cifs_close_file() argument
756 CIFSSMBClose(xid, tcon, fid->netfid); in cifs_close_file()
760 cifs_flush_file(const unsigned int xid, struct cifs_tcon *tcon, in cifs_flush_file() argument
763 return CIFSSMBFlush(xid, tcon, fid->netfid); in cifs_flush_file()
798 struct cifs_tcon *tcon; in smb_set_file_info() local
805 tcon = tlink_tcon(open_file->tlink); in smb_set_file_info()
815 tcon = tlink_tcon(tlink); in smb_set_file_info()
817 rc = CIFSSMBSetPathInfo(xid, tcon, full_path, buf, cifs_sb->local_nls, in smb_set_file_info()
826 oparms.tcon = tcon; in smb_set_file_info()
846 rc = CIFSSMBSetFileInfo(xid, tcon, buf, fid.netfid, netpid); in smb_set_file_info()
851 CIFSSMBClose(xid, tcon, fid.netfid); in smb_set_file_info()
861 cifs_set_compression(const unsigned int xid, struct cifs_tcon *tcon, in cifs_set_compression() argument
864 return CIFSSMB_set_compression(xid, tcon, cfile->fid.netfid); in cifs_set_compression()
868 cifs_query_dir_first(const unsigned int xid, struct cifs_tcon *tcon, in cifs_query_dir_first() argument
875 rc = CIFSFindFirst(xid, tcon, path, cifs_sb, in cifs_query_dir_first()
883 cifs_query_dir_next(const unsigned int xid, struct cifs_tcon *tcon, in cifs_query_dir_next() argument
887 return CIFSFindNext(xid, tcon, fid->netfid, search_flags, srch_inf); in cifs_query_dir_next()
891 cifs_close_dir(const unsigned int xid, struct cifs_tcon *tcon, in cifs_close_dir() argument
894 return CIFSFindClose(xid, tcon, fid->netfid); in cifs_close_dir()
898 cifs_oplock_response(struct cifs_tcon *tcon, struct cifs_fid *fid, in cifs_oplock_response() argument
901 return CIFSSMBLock(0, tcon, fid->netfid, current->tgid, 0, 0, 0, 0, in cifs_oplock_response()
907 cifs_queryfs(const unsigned int xid, struct cifs_tcon *tcon, in cifs_queryfs() argument
917 if ((tcon->ses->capabilities & CAP_UNIX) && in cifs_queryfs()
918 (CIFS_POSIX_EXTENSIONS & le64_to_cpu(tcon->fsUnixInfo.Capability))) in cifs_queryfs()
919 rc = CIFSSMBQFSPosixInfo(xid, tcon, buf); in cifs_queryfs()
925 if (rc && (tcon->ses->capabilities & CAP_NT_SMBS)) in cifs_queryfs()
926 rc = CIFSSMBQFSInfo(xid, tcon, buf); in cifs_queryfs()
934 rc = SMBOldQFSInfo(xid, tcon, buf); in cifs_queryfs()
948 cifs_unix_dfs_readlink(const unsigned int xid, struct cifs_tcon *tcon, in cifs_unix_dfs_readlink() argument
956 rc = get_dfs_path(xid, tcon->ses, searchName, nls_codepage, &referral, in cifs_unix_dfs_readlink()
972 cifs_query_symlink(const unsigned int xid, struct cifs_tcon *tcon, in cifs_query_symlink() argument
989 if (cap_unix(tcon->ses)) { in cifs_query_symlink()
990 rc = CIFSSMBUnixQuerySymLink(xid, tcon, full_path, target_path, in cifs_query_symlink()
994 rc = cifs_unix_dfs_readlink(xid, tcon, full_path, in cifs_query_symlink()
1001 oparms.tcon = tcon; in cifs_query_symlink()
1015 rc = CIFSSMBQuerySymLink(xid, tcon, fid.netfid, target_path, in cifs_query_symlink()
1022 CIFSSMBClose(xid, tcon, fid.netfid); in cifs_query_symlink()
1058 struct dentry *dentry, struct cifs_tcon *tcon, in cifs_make_node() argument
1073 if (tcon->unix_ext) { in cifs_make_node()
1092 rc = CIFSSMBUnixSetPathInfo(xid, tcon, full_path, &args, in cifs_make_node()
1118 oparms.tcon = tcon; in cifs_make_node()
1128 if (tcon->ses->server->oplocks) in cifs_make_node()
1132 rc = tcon->ses->server->ops->open(xid, &oparms, &oplock, &buf); in cifs_make_node()
1143 io_parms.tcon = tcon; in cifs_make_node()
1152 rc = tcon->ses->server->ops->sync_write(xid, &fid, &io_parms, in cifs_make_node()
1158 rc = tcon->ses->server->ops->sync_write(xid, &fid, &io_parms, in cifs_make_node()
1161 tcon->ses->server->ops->close(xid, tcon, &fid); in cifs_make_node()