Patch "ksmbd: set v2 lease version on lease upgrade" has been added to the 6.7-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    ksmbd: set v2 lease version on lease upgrade

to the 6.7-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     ksmbd-set-v2-lease-version-on-lease-upgrade.patch
and it can be found in the queue-6.7 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From stable+bounces-15511-greg=kroah.com@xxxxxxxxxxxxxxx Tue Jan 23 03:42:50 2024
From: Namjae Jeon <linkinjeon@xxxxxxxxxx>
Date: Tue, 23 Jan 2024 20:42:24 +0900
Subject: ksmbd: set v2 lease version on lease upgrade
To: gregkh@xxxxxxxxxxxxxxxxxxx, sashal@xxxxxxxxxx
Cc: stable@xxxxxxxxxxxxxxx, Namjae Jeon <linkinjeon@xxxxxxxxxx>, Tom Talpey <tom@xxxxxxxxxx>, Steve French <stfrench@xxxxxxxxxxxxx>
Message-ID: <20240123114228.205260-2-linkinjeon@xxxxxxxxxx>

From: Namjae Jeon <linkinjeon@xxxxxxxxxx>

[ Upstream commit bb05367a66a9990d2c561282f5620bb1dbe40c28 ]

If file opened with v2 lease is upgraded with v1 lease, smb server
should response v2 lease create context to client.
This patch fix smb2.lease.v2_epoch2 test failure.

This test case assumes the following scenario:
 1. smb2 create with v2 lease(R, LEASE1 key)
 2. smb server return smb2 create response with v2 lease context(R,
LEASE1 key, epoch + 1)
 3. smb2 create with v1 lease(RH, LEASE1 key)
 4. smb server return smb2 create response with v2 lease context(RH,
LEASE1 key, epoch + 2)

i.e. If same client(same lease key) try to open a file that is being
opened with v2 lease with v1 lease, smb server should return v2 lease.

Signed-off-by: Namjae Jeon <linkinjeon@xxxxxxxxxx>
Acked-by: Tom Talpey <tom@xxxxxxxxxx>
Signed-off-by: Steve French <stfrench@xxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 fs/smb/server/oplock.c |    1 +
 1 file changed, 1 insertion(+)

--- a/fs/smb/server/oplock.c
+++ b/fs/smb/server/oplock.c
@@ -1036,6 +1036,7 @@ static void copy_lease(struct oplock_inf
 	lease2->duration = lease1->duration;
 	lease2->flags = lease1->flags;
 	lease2->epoch = lease1->epoch++;
+	lease2->version = lease1->version;
 }
 
 static int add_lease_global_list(struct oplock_info *opinfo)


Patches currently in stable-queue which might be from kroah.com@xxxxxxxxxxxxxxx are

queue-6.7/ksmbd-send-lease-break-notification-on-file_rename_information.patch
queue-6.7/ksmbd-fix-potential-circular-locking-issue-in-smb2_set_ea.patch
queue-6.7/ksmbd-add-missing-set_freezable-for-freezable-kthread.patch
queue-6.7/ksmbd-set-v2-lease-version-on-lease-upgrade.patch
queue-6.7/ksmbd-don-t-increment-epoch-if-current-state-and-request-state-are-same.patch




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux