Skip to content

Commit 7588b83

Browse files
committed
Add definition for new smb3.1.1 command type
Add structs and defines for new SMB3.1.1 command, server to client notification. See MS-SMB2 section 2.2.44 Signed-off-by: Steve French <stfrench@microsoft.com>
1 parent d5a3c15 commit 7588b83

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

fs/smb/common/smb2pdu.h

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
#define SMB2_QUERY_INFO_HE 0x0010
3535
#define SMB2_SET_INFO_HE 0x0011
3636
#define SMB2_OPLOCK_BREAK_HE 0x0012
37+
#define SMB2_SERVER_TO_CLIENT_NOTIFICATION 0x0013
3738

3839
/* The same list in little endian */
3940
#define SMB2_NEGOTIATE cpu_to_le16(SMB2_NEGOTIATE_HE)
@@ -411,6 +412,7 @@ struct smb2_tree_disconnect_rsp {
411412
#define SMB2_GLOBAL_CAP_PERSISTENT_HANDLES 0x00000010 /* New to SMB3 */
412413
#define SMB2_GLOBAL_CAP_DIRECTORY_LEASING 0x00000020 /* New to SMB3 */
413414
#define SMB2_GLOBAL_CAP_ENCRYPTION 0x00000040 /* New to SMB3 */
415+
#define SMB2_GLOBAL_CAP_NOTIFICATIONS 0x00000080 /* New to SMB3.1.1 */
414416
/* Internal types */
415417
#define SMB2_NT_FIND 0x00100000
416418
#define SMB2_LARGE_FILES 0x00200000
@@ -981,6 +983,19 @@ struct smb2_change_notify_rsp {
981983
__u8 Buffer[]; /* array of file notify structs */
982984
} __packed;
983985

986+
/*
987+
* SMB2_SERVER_TO_CLIENT_NOTIFICATION: See MS-SMB2 section 2.2.44
988+
*/
989+
990+
#define SMB2_NOTIFY_SESSION_CLOSED 0x0000
991+
992+
struct smb2_server_client_notification {
993+
struct smb2_hdr hdr;
994+
__le16 StructureSize;
995+
__u16 Reserved; /* MBZ */
996+
__le32 NotificationType;
997+
__u8 NotificationBuffer[4]; /* MBZ */
998+
} __packed;
984999

9851000
/*
9861001
* SMB2_CREATE See MS-SMB2 section 2.2.13

0 commit comments

Comments
 (0)