Lines Matching refs:ses
644 static int get_dfs_referral(const unsigned int xid, struct cifs_ses *ses, const char *path, in get_dfs_referral() argument
653 if (!ses || !ses->server || !ses->server->ops->get_dfs_refer) in get_dfs_referral()
658 cifs_dbg(FYI, "%s: ipc=%s referral=%s\n", __func__, ses->tcon_ipc->tree_name, path); in get_dfs_referral()
659 rc = ses->server->ops->get_dfs_refer(xid, ses, path, refs, numrefs, cache_cp, in get_dfs_referral()
682 struct cifs_ses *ses, in cache_refresh_path() argument
717 rc = get_dfs_referral(xid, ses, path, &refs, &numrefs); in cache_refresh_path()
854 int dfs_cache_find(const unsigned int xid, struct cifs_ses *ses, const struct nls_table *cp, in dfs_cache_find() argument
866 ce = cache_refresh_path(xid, ses, npath, false); in dfs_cache_find()
1098 struct TCP_Server_Info *server = tcon->ses->server; in target_share_equal()
1123 static bool is_ses_good(struct cifs_tcon *tcon, struct cifs_ses *ses) in is_ses_good() argument
1125 struct TCP_Server_Info *server = ses->server; in is_ses_good()
1130 spin_lock(&ses->ses_lock); in is_ses_good()
1131 spin_lock(&ses->chan_lock); in is_ses_good()
1133 ret = !cifs_chan_needs_reconnect(ses, server) && in is_ses_good()
1134 ses->ses_status == SES_GOOD; in is_ses_good()
1136 spin_unlock(&ses->chan_lock); in is_ses_good()
1141 if (likely(ses->tcon_ipc)) { in is_ses_good()
1142 if (ses->tcon_ipc->need_reconnect) { in is_ses_good()
1147 spin_unlock(&ses->ses_lock); in is_ses_good()
1150 ipc = cifs_setup_ipc(ses, tcon->seal); in is_ses_good()
1153 spin_lock(&ses->ses_lock); in is_ses_good()
1155 if (!ses->tcon_ipc) { in is_ses_good()
1156 ses->tcon_ipc = ipc; in is_ses_good()
1166 spin_unlock(&ses->ses_lock); in is_ses_good()
1179 static void refresh_ses_referral(struct cifs_tcon *tcon, struct cifs_ses *ses) in refresh_ses_referral() argument
1188 path = dfs_ses_refpath(ses); in refresh_ses_referral()
1194 ses = CIFS_DFS_ROOT_SES(ses); in refresh_ses_referral()
1195 if (!is_ses_good(tcon, ses)) { in refresh_ses_referral()
1201 ce = cache_refresh_path(xid, ses, path, false); in refresh_ses_referral()
1248 cifs_signal_cifsd_for_reconnect(tcon->ses->server, true); in __refresh_tcon_referral()
1257 struct cifs_ses *ses; in refresh_tcon_referral() local
1265 ses = tcon->ses; in refresh_tcon_referral()
1267 path = dfs_ses_refpath(ses); in refresh_tcon_referral()
1282 ses = CIFS_DFS_ROOT_SES(ses); in refresh_tcon_referral()
1283 if (!is_ses_good(tcon, ses)) { in refresh_tcon_referral()
1289 rc = get_dfs_referral(xid, ses, path, &refs, &numrefs); in refresh_tcon_referral()
1346 struct cifs_ses *ses; in dfs_cache_refresh() local
1350 list_for_each_entry(ses, &tcon->dfs_ses_list, dlist) in dfs_cache_refresh()
1351 refresh_ses_referral(tcon, ses); in dfs_cache_refresh()