|
@@ -1933,6 +1933,27 @@ CIFSSMBClose(const int xid, struct cifsTconInfo *tcon, int smb_file_id)
|
|
|
return rc;
|
|
|
}
|
|
|
|
|
|
+int
|
|
|
+CIFSSMBFlush(const int xid, struct cifsTconInfo *tcon, int smb_file_id)
|
|
|
+{
|
|
|
+ int rc = 0;
|
|
|
+ FLUSH_REQ *pSMB = NULL;
|
|
|
+ cFYI(1, ("In CIFSSMBFlush"));
|
|
|
+
|
|
|
+ rc = small_smb_init(SMB_COM_FLUSH, 1, tcon, (void **) &pSMB);
|
|
|
+ if (rc)
|
|
|
+ return rc;
|
|
|
+
|
|
|
+ pSMB->FileID = (__u16) smb_file_id;
|
|
|
+ pSMB->ByteCount = 0;
|
|
|
+ rc = SendReceiveNoRsp(xid, tcon->ses, (struct smb_hdr *) pSMB, 0);
|
|
|
+ cifs_stats_inc(&tcon->num_flushes);
|
|
|
+ if (rc)
|
|
|
+ cERROR(1, ("Send error in Flush = %d", rc));
|
|
|
+
|
|
|
+ return rc;
|
|
|
+}
|
|
|
+
|
|
|
int
|
|
|
CIFSSMBRename(const int xid, struct cifsTconInfo *tcon,
|
|
|
const char *fromName, const char *toName,
|