Lines Matching defs:server

53  * max sleep time before retry to server
86 /* smb multichannel query server interfaces interval in seconds */
95 * defaults to 128 credits, the Windows server allows clients up to
96 * 512 credits (or 8K for later versions), and the NetApp server
100 * to reduce possibility of seeing more server credit overflow bugs.
137 /* associated with each tree connection to the server */
195 __u32 server_flags; /* sent by server in type 2 ntlmssp exchange */
196 unsigned char ciphertext[CIFS_CPHTXT_SIZE]; /* sent to server */
250 * A smb_rqst represents a complete request to be issued to a server. It's
292 void (*add_credits)(struct TCP_Server_Info *server,
299 void (*revert_current_mid)(struct TCP_Server_Info *server,
323 void (*downgrade_oplock)(struct TCP_Server_Info *server,
331 /* negotiate to the server */
334 struct TCP_Server_Info *server);
341 struct TCP_Server_Info *server,
345 /* connect to a server share */
357 /* query for server interfaces */
363 /* query path data from the server */
369 /* query file data from the server */
379 /* get server index number */
449 /* send a flush request to the server */
451 /* async read from the server */
453 /* async write to the server */
455 /* sync read from the server */
459 /* sync write to the server */
478 bool (*is_status_pending)(char *buf, struct TCP_Server_Info *server);
487 /* send mandatory brlock to the server */
493 /* push brlocks from the cache to the server */
502 struct TCP_Server_Info *server);
552 int (*adjust_credits)(struct TCP_Server_Info *server,
567 int (*next_header)(struct TCP_Server_Info *server, char *buf,
624 #define HEADER_SIZE(server) (server->vals->header_size)
625 #define MAX_HEADER_SIZE(server) (server->vals->max_header_size)
626 #define HEADER_PREAMBLE_SIZE(server) (server->vals->header_preamble_size)
627 #define MID_HEADER_SIZE(server) (HEADER_SIZE(server) - 1 - HEADER_PREAMBLE_SIZE(server))
679 /* 15 character server name + 0x20 16th byte indicating type = srv */
703 unsigned int in_flight; /* number of requests on the wire to server */
718 u16 dialect; /* dialect index that server chose */
721 /* than maxReq distinct unanswered SMBs to the server when using */
724 /* message size the server can send or receive for non-raw SMBs */
728 /* message size the server can send or receive for */
731 int timeAdj; /* Adjust for difference in server time zone in sec */
739 unsigned long lstrp; /* when we got last response from this server */
744 /* extended security flavors that server supports */
775 bool enabled; /* actually negotiated with server */
776 __le16 alg; /* preferred alg negotiated with server */
782 bool signing_negotiated; /* true if valid signing context rcvd from server */
801 #define SERVER_IS_CHAN(server) (!!(server)->primary_server)
827 static inline bool is_smb1(struct TCP_Server_Info *server)
829 return HEADER_PREAMBLE_SIZE(server) != 0;
832 static inline void cifs_server_lock(struct TCP_Server_Info *server)
836 mutex_lock(&server->_srv_mutex);
837 server->nofs_flag = nofs_flag;
840 static inline void cifs_server_unlock(struct TCP_Server_Info *server)
842 unsigned int nofs_flag = server->nofs_flag;
844 mutex_unlock(&server->_srv_mutex);
854 in_flight(struct TCP_Server_Info *server)
858 spin_lock(&server->req_lock);
859 num = server->in_flight;
860 spin_unlock(&server->req_lock);
865 has_credits(struct TCP_Server_Info *server, int *credits, int num_credits)
869 spin_lock(&server->req_lock);
871 spin_unlock(&server->req_lock);
876 add_credits(struct TCP_Server_Info *server, const struct cifs_credits *credits,
879 server->ops->add_credits(server, credits, optype);
883 add_credits_and_wake_if(struct TCP_Server_Info *server,
887 server->ops->add_credits(server, credits, optype);
888 wake_up(&server->request_q);
894 set_credits(struct TCP_Server_Info *server, const int val)
896 server->ops->set_credits(server, val);
900 adjust_credits(struct TCP_Server_Info *server, struct cifs_credits *credits,
903 return server->ops->adjust_credits ?
904 server->ops->adjust_credits(server, credits, payload_size) : 0;
908 get_next_mid64(struct TCP_Server_Info *server)
910 return cpu_to_le64(server->ops->get_next_mid(server));
914 get_next_mid(struct TCP_Server_Info *server)
916 __u16 mid = server->ops->get_next_mid(server);
925 revert_current_mid(struct TCP_Server_Info *server, const unsigned int val)
927 if (server->ops->revert_current_mid)
928 server->ops->revert_current_mid(server, val);
932 revert_current_mid_from_hdr(struct TCP_Server_Info *server,
937 return revert_current_mid(server, num > 0 ? num : 1);
953 * When the server supports very large reads and writes via POSIX extensions,
969 * When the server doesn't allow large posix writes, only allow a rsize/wsize
1046 struct TCP_Server_Info *server;
1063 struct TCP_Server_Info *server; /* pointer to server info */
1067 char *serverOS; /* name of operating system underlying server */
1068 char *serverNOS; /* name of network operating system of server */
1069 char *serverDomain; /* security realm of server */
1082 struct ntlmssp_auth *ntlmssp; /* ciphertext, flags, server challenge */
1095 * Network interfaces available on the server this session is
1151 return ses->server->vals->cap_unix & ses->capabilities;
1197 atomic_t num_remote_opens; /* num of all network opens on server */
1249 bool nohandlecache:1; /* if strange server resource prob can turn off */
1253 for this mount even if server would support */
1256 bool broken_posix_open; /* e.g. Samba server versions < 3.3.2, 3.2.9 */
1257 bool broken_sparse_sup; /* if server or share does not support sparse */
1278 u64 resource_id; /* server resource id */
1468 struct TCP_Server_Info *server;
1513 struct TCP_Server_Info *server;
1569 #define CIFS_INO_DELETE_PENDING (3) /* delete pending on server */
1578 u64 uniqueid; /* server inode number */
1579 u64 createtime; /* creation time on server */
1662 typedef int (mid_receive_t)(struct TCP_Server_Info *server,
1679 typedef int (mid_handle_t)(struct TCP_Server_Info *server,
1682 /* one of these for every pending CIFS request to the server */
1684 struct list_head qhead; /* mids waiting on reply from this server */
1686 struct TCP_Server_Info *server; /* server corresponding to this mid */
1724 static inline void cifs_in_send_inc(struct TCP_Server_Info *server)
1726 atomic_inc(&server->in_send);
1729 static inline void cifs_in_send_dec(struct TCP_Server_Info *server)
1731 atomic_dec(&server->in_send);
1734 static inline void cifs_num_waiters_inc(struct TCP_Server_Info *server)
1736 atomic_inc(&server->num_waiters);
1739 static inline void cifs_num_waiters_dec(struct TCP_Server_Info *server)
1741 atomic_dec(&server->num_waiters);
1788 struct TCP_Server_Info *server;
1897 #define CIFS_NO_SRV_RSP 0x1000 /* there is no server response */
2020 * connecting our client to a distinct server (ip address), is
2030 * the reference counters for the server, smb session, and tcon.
2077 extern unsigned int cifs_max_pending; /* MAX requests at once to server*/
2143 static inline bool is_smb1_server(struct TCP_Server_Info *server)
2145 return strcmp(server->vals->version_string, SMB1_VERSION_STRING) == 0;
2157 if (!tcon || !tcon->ses || !tcon->ses->server)
2159 return is_smb1_server(tcon->ses->server) ? tcon->Flags & SMB_SHARE_IS_IN_DFS :
2180 if (WARN_ON_ONCE(!ses || !ses->server))
2186 if (ses->server->dialect <= SMB20_PROT_ID)