Loading fs/cifs/smb2ops.c +2 −2 Original line number Diff line number Diff line Loading @@ -1582,7 +1582,7 @@ smb2_queryfs(const unsigned int xid, struct cifs_tcon *tcon, struct smb_rqst rqst[3]; int resp_buftype[3]; struct kvec rsp_iov[3]; struct kvec open_iov[5]; /* 4 + potential padding. */ struct kvec open_iov[SMB2_CREATE_IOV_SIZE]; struct kvec qi_iov[1]; struct kvec close_iov[1]; struct cifs_ses *ses = tcon->ses; Loading @@ -1603,7 +1603,7 @@ smb2_queryfs(const unsigned int xid, struct cifs_tcon *tcon, memset(&open_iov, 0, sizeof(open_iov)); rqst[0].rq_iov = open_iov; rqst[0].rq_nvec = 4; rqst[0].rq_nvec = SMB2_CREATE_IOV_SIZE; oparms.tcon = tcon; oparms.desired_access = FILE_READ_ATTRIBUTES; Loading fs/cifs/smb2pdu.c +2 −2 Original line number Diff line number Diff line Loading @@ -2256,7 +2256,7 @@ SMB2_open(const unsigned int xid, struct cifs_open_parms *oparms, __le16 *path, struct TCP_Server_Info *server; struct cifs_tcon *tcon = oparms->tcon; struct cifs_ses *ses = tcon->ses; struct kvec iov[5]; /* make sure at least one for each open context */ struct kvec iov[SMB2_CREATE_IOV_SIZE]; struct kvec rsp_iov = {NULL, 0}; int resp_buftype; int rc = 0; Loading @@ -2274,7 +2274,7 @@ SMB2_open(const unsigned int xid, struct cifs_open_parms *oparms, __le16 *path, memset(&rqst, 0, sizeof(struct smb_rqst)); memset(&iov, 0, sizeof(iov)); rqst.rq_iov = iov; rqst.rq_nvec = 5; rqst.rq_nvec = SMB2_CREATE_IOV_SIZE; rc = SMB2_open_init(tcon, &rqst, oplock, oparms, path); if (rc) Loading fs/cifs/smb2pdu.h +12 −0 Original line number Diff line number Diff line Loading @@ -614,6 +614,18 @@ struct smb2_tree_disconnect_rsp { #define SMB2_CREATE_TAG_POSIX 0x93AD25509CB411E7B42383DE968BCD7C /* * Maximum number of iovs we need for an open/create request. * [0] : struct smb2_create_req * [1] : path * [2] : lease context * [3] : durable context * [4] : posix context * [5] : time warp context * [6] : compound padding */ #define SMB2_CREATE_IOV_SIZE 7 struct smb2_create_req { struct smb2_sync_hdr sync_hdr; __le16 StructureSize; /* Must be 57 */ Loading Loading
fs/cifs/smb2ops.c +2 −2 Original line number Diff line number Diff line Loading @@ -1582,7 +1582,7 @@ smb2_queryfs(const unsigned int xid, struct cifs_tcon *tcon, struct smb_rqst rqst[3]; int resp_buftype[3]; struct kvec rsp_iov[3]; struct kvec open_iov[5]; /* 4 + potential padding. */ struct kvec open_iov[SMB2_CREATE_IOV_SIZE]; struct kvec qi_iov[1]; struct kvec close_iov[1]; struct cifs_ses *ses = tcon->ses; Loading @@ -1603,7 +1603,7 @@ smb2_queryfs(const unsigned int xid, struct cifs_tcon *tcon, memset(&open_iov, 0, sizeof(open_iov)); rqst[0].rq_iov = open_iov; rqst[0].rq_nvec = 4; rqst[0].rq_nvec = SMB2_CREATE_IOV_SIZE; oparms.tcon = tcon; oparms.desired_access = FILE_READ_ATTRIBUTES; Loading
fs/cifs/smb2pdu.c +2 −2 Original line number Diff line number Diff line Loading @@ -2256,7 +2256,7 @@ SMB2_open(const unsigned int xid, struct cifs_open_parms *oparms, __le16 *path, struct TCP_Server_Info *server; struct cifs_tcon *tcon = oparms->tcon; struct cifs_ses *ses = tcon->ses; struct kvec iov[5]; /* make sure at least one for each open context */ struct kvec iov[SMB2_CREATE_IOV_SIZE]; struct kvec rsp_iov = {NULL, 0}; int resp_buftype; int rc = 0; Loading @@ -2274,7 +2274,7 @@ SMB2_open(const unsigned int xid, struct cifs_open_parms *oparms, __le16 *path, memset(&rqst, 0, sizeof(struct smb_rqst)); memset(&iov, 0, sizeof(iov)); rqst.rq_iov = iov; rqst.rq_nvec = 5; rqst.rq_nvec = SMB2_CREATE_IOV_SIZE; rc = SMB2_open_init(tcon, &rqst, oplock, oparms, path); if (rc) Loading
fs/cifs/smb2pdu.h +12 −0 Original line number Diff line number Diff line Loading @@ -614,6 +614,18 @@ struct smb2_tree_disconnect_rsp { #define SMB2_CREATE_TAG_POSIX 0x93AD25509CB411E7B42383DE968BCD7C /* * Maximum number of iovs we need for an open/create request. * [0] : struct smb2_create_req * [1] : path * [2] : lease context * [3] : durable context * [4] : posix context * [5] : time warp context * [6] : compound padding */ #define SMB2_CREATE_IOV_SIZE 7 struct smb2_create_req { struct smb2_sync_hdr sync_hdr; __le16 StructureSize; /* Must be 57 */ Loading