|
@@ -726,12 +726,12 @@ int cifs_lock(struct file *file, int cmd, struct file_lock *pfLock)
|
|
|
|
|
|
/* BB we could chain these into one lock request BB */
|
|
|
rc = CIFSSMBLock(xid, tcon, netfid, length, pfLock->fl_start,
|
|
|
- 0, 1, lockType, 0 /* wait flag */ );
|
|
|
+ 0, 1, lockType, 0 /* wait flag */, 0);
|
|
|
if (rc == 0) {
|
|
|
rc = CIFSSMBLock(xid, tcon, netfid, length,
|
|
|
pfLock->fl_start, 1 /* numUnlock */ ,
|
|
|
0 /* numLock */ , lockType,
|
|
|
- 0 /* wait flag */ );
|
|
|
+ 0 /* wait flag */, 0);
|
|
|
pfLock->fl_type = F_UNLCK;
|
|
|
if (rc != 0)
|
|
|
cERROR(1, "Error unlocking previously locked "
|
|
@@ -748,13 +748,13 @@ int cifs_lock(struct file *file, int cmd, struct file_lock *pfLock)
|
|
|
rc = CIFSSMBLock(xid, tcon, netfid, length,
|
|
|
pfLock->fl_start, 0, 1,
|
|
|
lockType | LOCKING_ANDX_SHARED_LOCK,
|
|
|
- 0 /* wait flag */);
|
|
|
+ 0 /* wait flag */, 0);
|
|
|
if (rc == 0) {
|
|
|
rc = CIFSSMBLock(xid, tcon, netfid,
|
|
|
length, pfLock->fl_start, 1, 0,
|
|
|
lockType |
|
|
|
LOCKING_ANDX_SHARED_LOCK,
|
|
|
- 0 /* wait flag */);
|
|
|
+ 0 /* wait flag */, 0);
|
|
|
pfLock->fl_type = F_RDLCK;
|
|
|
if (rc != 0)
|
|
|
cERROR(1, "Error unlocking "
|
|
@@ -797,8 +797,8 @@ int cifs_lock(struct file *file, int cmd, struct file_lock *pfLock)
|
|
|
|
|
|
if (numLock) {
|
|
|
rc = CIFSSMBLock(xid, tcon, netfid, length,
|
|
|
- pfLock->fl_start,
|
|
|
- 0, numLock, lockType, wait_flag);
|
|
|
+ pfLock->fl_start, 0, numLock, lockType,
|
|
|
+ wait_flag, 0);
|
|
|
|
|
|
if (rc == 0) {
|
|
|
/* For Windows locks we must store them. */
|
|
@@ -818,9 +818,9 @@ int cifs_lock(struct file *file, int cmd, struct file_lock *pfLock)
|
|
|
(pfLock->fl_start + length) >=
|
|
|
(li->offset + li->length)) {
|
|
|
stored_rc = CIFSSMBLock(xid, tcon,
|
|
|
- netfid,
|
|
|
- li->length, li->offset,
|
|
|
- 1, 0, li->type, false);
|
|
|
+ netfid, li->length,
|
|
|
+ li->offset, 1, 0,
|
|
|
+ li->type, false, 0);
|
|
|
if (stored_rc)
|
|
|
rc = stored_rc;
|
|
|
else {
|
|
@@ -2192,7 +2192,8 @@ void cifs_oplock_break(struct work_struct *work)
|
|
|
*/
|
|
|
if (!cfile->oplock_break_cancelled) {
|
|
|
rc = CIFSSMBLock(0, tlink_tcon(cfile->tlink), cfile->netfid, 0,
|
|
|
- 0, 0, 0, LOCKING_ANDX_OPLOCK_RELEASE, false);
|
|
|
+ 0, 0, 0, LOCKING_ANDX_OPLOCK_RELEASE, false,
|
|
|
+ cinode->clientCanCacheRead ? 1 : 0);
|
|
|
cFYI(1, "Oplock release rc = %d", rc);
|
|
|
}
|
|
|
|