get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/1.0/patches/2196716/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 2196716,
    "url": "http://patchwork.ozlabs.org/api/1.0/patches/2196716/?format=api",
    "project": {
        "id": 12,
        "url": "http://patchwork.ozlabs.org/api/1.0/projects/12/?format=api",
        "name": "Linux CIFS Client",
        "link_name": "linux-cifs-client",
        "list_id": "linux-cifs.vger.kernel.org",
        "list_email": "linux-cifs@vger.kernel.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20260216082018.156695-3-zhang.guodong@linux.dev>",
    "date": "2026-02-16T08:20:15",
    "name": "[v3,2/5] smb: move some definitions from common/smb2pdu.h into common/fscc.h",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "7459996de20980f062451ef15e3555ef4f5aad21",
    "submitter": {
        "id": 92649,
        "url": "http://patchwork.ozlabs.org/api/1.0/people/92649/?format=api",
        "name": "ZhangGuoDong",
        "email": "zhang.guodong@linux.dev"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/linux-cifs-client/patch/20260216082018.156695-3-zhang.guodong@linux.dev/mbox/",
    "series": [
        {
            "id": 492258,
            "url": "http://patchwork.ozlabs.org/api/1.0/series/492258/?format=api",
            "date": "2026-02-16T08:20:13",
            "name": "smb: move duplicate definitions into common header file, part 2",
            "version": 3,
            "mbox": "http://patchwork.ozlabs.org/series/492258/mbox/"
        }
    ],
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2196716/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "\n <linux-cifs+bounces-9392-incoming=patchwork.ozlabs.org@vger.kernel.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "linux-cifs@vger.kernel.org"
        ],
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=linux.dev header.i=@linux.dev header.a=rsa-sha256\n header.s=key1 header.b=uvI75Whe;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c15:e001:75::12fc:5321; helo=sin.lore.kernel.org;\n envelope-from=linux-cifs+bounces-9392-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)",
            "smtp.subspace.kernel.org;\n\tdkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev\n header.b=\"uvI75Whe\"",
            "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=95.215.58.180",
            "smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=linux.dev",
            "smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=linux.dev"
        ],
        "Received": [
            "from sin.lore.kernel.org (sin.lore.kernel.org\n [IPv6:2600:3c15:e001:75::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fDwjb3TCFz1xpY\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 16 Feb 2026 19:21:55 +1100 (AEDT)",
            "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sin.lore.kernel.org (Postfix) with ESMTP id 8BB3D300119F\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 16 Feb 2026 08:21:53 +0000 (UTC)",
            "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id ABB5527A122;\n\tMon, 16 Feb 2026 08:21:51 +0000 (UTC)",
            "from out-180.mta1.migadu.com (out-180.mta1.migadu.com\n [95.215.58.180])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 760232475E3\n\tfor <linux-cifs@vger.kernel.org>; Mon, 16 Feb 2026 08:21:49 +0000 (UTC)"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1771230111; cv=none;\n b=k3LsbfMfAftuojMtfq5D4Qa9EnBZ6uGXXc0FRTc43vjslwSNJJlws1+KmNUJPP2shq+urd+dXiFKfjzLQsJHw2xmdcDxHwLMIJxQRwcqzmNgnb/kEHlNn4qIPKF9uzPHTaVgNkhx9J2CD7VitIRsTsPWNMprJ03EtARCKuRVnPg=",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1771230111; c=relaxed/simple;\n\tbh=LwnOrFhRBejzOAsclcLL/CMh55Ab0Tb6RVzZtWdl88U=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=ciia3CiQcpEAB2wMppcXE2xus72ZwoYwhuYdgR4vQHtM306pJPb/xKwCAH5iHbUrefU0r07GzqGdpMM2V6DSI0XAx/1mK9W4MxfBiWO0t0EMFOdm1Tqc5wJbJAtrPmfyDg10AnkNSSRrvePWBtVALpUYKYN84ci3mdOho+q/K00=",
        "ARC-Authentication-Results": "i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=linux.dev;\n spf=pass smtp.mailfrom=linux.dev;\n dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev\n header.b=uvI75Whe; arc=none smtp.client-ip=95.215.58.180",
        "X-Report-Abuse": "Please report any abuse attempt to abuse@migadu.com and\n include these headers.",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1;\n\tt=1771230107;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\t to:to:cc:cc:mime-version:mime-version:\n\t content-transfer-encoding:content-transfer-encoding:\n\t in-reply-to:in-reply-to:references:references;\n\tbh=OgnvaNnhoG4CrqH1v7kTklrDX+n9JA7o0zkllLzES+g=;\n\tb=uvI75WhevK2HqCsdsb0wLurhsETRiNFWqTuz1xPdSJAXN7AkRXdBQBwTTPP4f8EWyJwVvT\n\tahxIm7BAhwN82Hk/TmFnhKBmgfUWozwBI6f32IPjEkzmYUICja3S3yMSudshVKETMGKGsb\n\tGPd4SjbPzOK5qKqV8aM/tKmXIMJLRbk=",
        "From": "zhang.guodong@linux.dev",
        "To": "smfrench@gmail.com,\n\tlinkinjeon@kernel.org,\n\tpc@manguebit.org,\n\tronniesahlberg@gmail.com,\n\tsprasad@microsoft.com,\n\ttom@talpey.com,\n\tbharathsm@microsoft.com,\n\tsenozhatsky@chromium.org,\n\tdhowells@redhat.com,\n\tchenxiaosong@kylinos.cn,\n\tchenxiaosong.chenxiaosong@linux.dev",
        "Cc": "linux-cifs@vger.kernel.org,\n\tZhangGuoDong <zhangguodong@kylinos.cn>,\n\tSteve French <stfrench@microsoft.com>",
        "Subject": "[PATCH v3 2/5] smb: move some definitions from common/smb2pdu.h into\n common/fscc.h",
        "Date": "Mon, 16 Feb 2026 08:20:15 +0000",
        "Message-ID": "<20260216082018.156695-3-zhang.guodong@linux.dev>",
        "In-Reply-To": "<20260216082018.156695-1-zhang.guodong@linux.dev>",
        "References": "<20260216082018.156695-1-zhang.guodong@linux.dev>",
        "Precedence": "bulk",
        "X-Mailing-List": "linux-cifs@vger.kernel.org",
        "List-Id": "<linux-cifs.vger.kernel.org>",
        "List-Subscribe": "<mailto:linux-cifs+subscribe@vger.kernel.org>",
        "List-Unsubscribe": "<mailto:linux-cifs+unsubscribe@vger.kernel.org>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-Migadu-Flow": "FLOW_OUT"
    },
    "content": "From: ZhangGuoDong <zhangguodong@kylinos.cn>\n\nThese definitions are specified in MS-FSCC, so move them into fscc.h.\n\nOnly add some documentation references, no other changes.\n\nSigned-off-by: ZhangGuoDong <zhangguodong@kylinos.cn>\nReviewed-by: ChenXiaoSong <chenxiaosong@kylinos.cn>\nReviewed-by: Steve French <stfrench@microsoft.com>\n---\n fs/smb/common/fscc.h    | 315 ++++++++++++++++++++++++++++++++++++++++\n fs/smb/common/smb2pdu.h | 307 ---------------------------------------\n 2 files changed, 315 insertions(+), 307 deletions(-)",
    "diff": "diff --git a/fs/smb/common/fscc.h b/fs/smb/common/fscc.h\nindex d2e00eba1a98..b209d818e95e 100644\n--- a/fs/smb/common/fscc.h\n+++ b/fs/smb/common/fscc.h\n@@ -12,6 +12,210 @@\n #ifndef _COMMON_SMB_FSCC_H\n #define _COMMON_SMB_FSCC_H\n \n+/* Reparse structures - see MS-FSCC 2.1.2 */\n+\n+/* struct fsctl_reparse_info_req is empty, only response structs (see below) */\n+struct reparse_data_buffer {\n+\t__le32\tReparseTag;\n+\t__le16\tReparseDataLength;\n+\t__u16\tReserved;\n+\t__u8\tDataBuffer[]; /* Variable Length */\n+} __packed;\n+\n+struct reparse_guid_data_buffer {\n+\t__le32\tReparseTag;\n+\t__le16\tReparseDataLength;\n+\t__u16\tReserved;\n+\t__u8\tReparseGuid[16];\n+\t__u8\tDataBuffer[]; /* Variable Length */\n+} __packed;\n+\n+struct reparse_mount_point_data_buffer {\n+\t__le32\tReparseTag;\n+\t__le16\tReparseDataLength;\n+\t__u16\tReserved;\n+\t__le16\tSubstituteNameOffset;\n+\t__le16\tSubstituteNameLength;\n+\t__le16\tPrintNameOffset;\n+\t__le16\tPrintNameLength;\n+\t__u8\tPathBuffer[]; /* Variable Length */\n+} __packed;\n+\n+#define SYMLINK_FLAG_RELATIVE 0x00000001\n+\n+struct reparse_symlink_data_buffer {\n+\t__le32\tReparseTag;\n+\t__le16\tReparseDataLength;\n+\t__u16\tReserved;\n+\t__le16\tSubstituteNameOffset;\n+\t__le16\tSubstituteNameLength;\n+\t__le16\tPrintNameOffset;\n+\t__le16\tPrintNameLength;\n+\t__le32\tFlags;\n+\t__u8\tPathBuffer[]; /* Variable Length */\n+} __packed;\n+\n+/* For IO_REPARSE_TAG_NFS - see MS-FSCC 2.1.2.6 */\n+#define NFS_SPECFILE_LNK\t0x00000000014B4E4C\n+#define NFS_SPECFILE_CHR\t0x0000000000524843\n+#define NFS_SPECFILE_BLK\t0x00000000004B4C42\n+#define NFS_SPECFILE_FIFO\t0x000000004F464946\n+#define NFS_SPECFILE_SOCK\t0x000000004B434F53\n+struct reparse_nfs_data_buffer {\n+\t__le32\tReparseTag;\n+\t__le16\tReparseDataLength;\n+\t__u16\tReserved;\n+\t__le64\tInodeType; /* NFS_SPECFILE_* */\n+\t__u8\tDataBuffer[];\n+} __packed;\n+\n+/* For IO_REPARSE_TAG_LX_SYMLINK - see MS-FSCC 2.1.2.7 */\n+struct reparse_wsl_symlink_data_buffer {\n+\t__le32\tReparseTag;\n+\t__le16\tReparseDataLength;\n+\t__u16\tReserved;\n+\t__le32\tVersion; /* Always 2 */\n+\t__u8\tTarget[]; /* Variable Length UTF-8 string without nul-term */\n+} __packed;\n+\n+/* See MS-FSCC 2.3.7 */\n+struct duplicate_extents_to_file {\n+\t__u64 PersistentFileHandle; /* source file handle, opaque endianness */\n+\t__u64 VolatileFileHandle;\n+\t__le64 SourceFileOffset;\n+\t__le64 TargetFileOffset;\n+\t__le64 ByteCount;  /* Bytes to be copied */\n+} __packed;\n+\n+/* See MS-FSCC 2.3.9 */\n+#define DUPLICATE_EXTENTS_DATA_EX_SOURCE_ATOMIC\t0x00000001\n+struct duplicate_extents_to_file_ex {\n+\t__le64 StructureSize; /* MUST be set to 0x30 */\n+\t__u64 PersistentFileHandle; /* source file handle, opaque endianness */\n+\t__u64 VolatileFileHandle;\n+\t__le64 SourceFileOffset;\n+\t__le64 TargetFileOffset;\n+\t__le64 ByteCount;  /* Bytes to be copied */\n+\t__le32 Flags;\n+\t__le32 Reserved;\n+} __packed;\n+\n+/* See MS-FSCC 2.3.20 */\n+struct fsctl_get_integrity_information_rsp {\n+\t__le16\tChecksumAlgorithm;\n+\t__le16\tReserved;\n+\t__le32\tFlags;\n+\t__le32\tChecksumChunkSizeInBytes;\n+\t__le32\tClusterSizeInBytes;\n+} __packed;\n+\n+/* See MS-FSCC 2.3.52 */\n+struct file_allocated_range_buffer {\n+\t__le64\tfile_offset;\n+\t__le64\tlength;\n+} __packed;\n+\n+/* See MS-FSCC 2.3.55 */\n+struct fsctl_query_file_regions_req {\n+\t__le64\tFileOffset;\n+\t__le64\tLength;\n+\t__le32\tDesiredUsage;\n+\t__le32\tReserved;\n+} __packed;\n+\n+/* DesiredUsage flags see MS-FSCC 2.3.56.1 */\n+#define FILE_USAGE_INVALID_RANGE\t0x00000000\n+#define FILE_USAGE_VALID_CACHED_DATA\t0x00000001\n+#define FILE_USAGE_NONCACHED_DATA\t0x00000002\n+struct file_region_info {\n+\t__le64\tFileOffset;\n+\t__le64\tLength;\n+\t__le32\tDesiredUsage;\n+\t__le32\tReserved;\n+} __packed;\n+\n+/* See MS-FSCC 2.3.56 */\n+struct fsctl_query_file_region_rsp {\n+\t__le32 Flags;\n+\t__le32 TotalRegionEntryCount;\n+\t__le32 RegionEntryCount;\n+\t__u32  Reserved;\n+\tstruct  file_region_info Regions[];\n+} __packed;\n+\n+/* See MS-FSCC 2.3.58 */\n+struct fsctl_query_on_disk_vol_info_rsp {\n+\t__le64\tDirectoryCount;\n+\t__le64\tFileCount;\n+\t__le16\tFsFormatMajVersion;\n+\t__le16\tFsFormatMinVersion;\n+\t__u8\tFsFormatName[24];\n+\t__le64\tFormatTime;\n+\t__le64\tLastUpdateTime;\n+\t__u8\tCopyrightInfo[68];\n+\t__u8\tAbstractInfo[68];\n+\t__u8\tFormatImplInfo[68];\n+\t__u8\tLastModifyImplInfo[68];\n+} __packed;\n+\n+/* See MS-FSCC 2.3.73 */\n+struct fsctl_set_integrity_information_req {\n+\t__le16\tChecksumAlgorithm;\n+\t__le16\tReserved;\n+\t__le32\tFlags;\n+} __packed;\n+\n+/* See MS-FSCC 2.3.75 */\n+struct fsctl_set_integrity_info_ex_req {\n+\t__u8\tEnableIntegrity;\n+\t__u8\tKeepState;\n+\t__u16\tReserved;\n+\t__le32\tFlags;\n+\t__u8\tVersion;\n+\t__u8\tReserved2[7];\n+} __packed;\n+\n+/*\n+ * this goes in the ioctl buffer when doing FSCTL_SET_ZERO_DATA\n+ * See MS-FSCC 2.3.85\n+ */\n+struct file_zero_data_information {\n+\t__le64\tFileOffset;\n+\t__le64\tBeyondFinalZero;\n+} __packed;\n+\n+/*\n+ * This level 18, although with struct with same name is different from cifs\n+ * level 0x107. Level 0x107 has an extra u64 between AccessFlags and\n+ * CurrentByteOffset.\n+ * See MS-FSCC 2.4.2\n+ */\n+struct smb2_file_all_info { /* data block encoding of response to level 18 */\n+\t__le64 CreationTime;\t/* Beginning of FILE_BASIC_INFO equivalent */\n+\t__le64 LastAccessTime;\n+\t__le64 LastWriteTime;\n+\t__le64 ChangeTime;\n+\t__le32 Attributes;\n+\t__u32  Pad1;\t\t/* End of FILE_BASIC_INFO_INFO equivalent */\n+\t__le64 AllocationSize;\t/* Beginning of FILE_STANDARD_INFO equivalent */\n+\t__le64 EndOfFile;\t/* size ie offset to first free byte in file */\n+\t__le32 NumberOfLinks;\t/* hard links */\n+\t__u8   DeletePending;\n+\t__u8   Directory;\n+\t__u16  Pad2;\t\t/* End of FILE_STANDARD_INFO equivalent */\n+\t__le64 IndexNumber;\n+\t__le32 EASize;\n+\t__le32 AccessFlags;\n+\t__le64 CurrentByteOffset;\n+\t__le32 Mode;\n+\t__le32 AlignmentRequirement;\n+\t__le32 FileNameLength;\n+\tunion {\n+\t\tchar __pad;\t/* Legacy structure padding */\n+\t\tDECLARE_FLEX_ARRAY(char, FileName);\n+\t};\n+} __packed; /* level 18 Query */\n+\n /* See MS-FSCC 2.4.8 */\n typedef struct {\n \t__le32 NextEntryOffset;\n@@ -46,6 +250,11 @@ typedef struct {\n \tchar FileName[];\n } __packed FILE_DIRECTORY_INFO;   /* level 0x101 FF resp data */\n \n+/* See MS-FSCC 2.4.13 */\n+struct smb2_file_eof_info { /* encoding of request for level 10 */\n+\t__le64 EndOfFile; /* new end of file value */\n+} __packed; /* level 20 Set */\n+\n /* See MS-FSCC 2.4.14 */\n typedef struct {\n \t__le32 NextEntryOffset;\n@@ -80,6 +289,26 @@ typedef struct {\n \tchar FileName[];\n } __packed FILE_ID_FULL_DIR_INFO; /* level 0x105 FF rsp data */\n \n+/* See MS-FSCC 2.4.27 */\n+struct smb2_file_internal_info {\n+\t__le64 IndexNumber;\n+} __packed; /* level 6 Query */\n+\n+/* See MS-FSCC 2.4.28.2 */\n+struct smb2_file_link_info { /* encoding of request for level 11 */\n+\t/* New members MUST be added within the struct_group() macro below. */\n+\t__struct_group(smb2_file_link_info_hdr, __hdr, __packed,\n+\t\t__u8   ReplaceIfExists; /* 1 = replace existing link with new */\n+\t\t\t\t\t/* 0 = fail if link already exists */\n+\t\t__u8   Reserved[7];\n+\t\t__u64  RootDirectory;  /* MBZ for network operations (why says spec?) */\n+\t\t__le32 FileNameLength;\n+\t);\n+\tchar   FileName[];     /* Name to be assigned to new link */\n+} __packed; /* level 11 Set */\n+static_assert(offsetof(struct smb2_file_link_info, FileName) == sizeof(struct smb2_file_link_info_hdr),\n+\t      \"struct member likely outside of __struct_group()\");\n+\n /* See MS-FSCC 2.4.34 */\n struct smb2_file_network_open_info {\n \tstruct_group_attr(network_open_info, __packed,\n@@ -94,6 +323,37 @@ struct smb2_file_network_open_info {\n \t__le32 Reserved;\n } __packed; /* level 34 Query also similar returned in close rsp and open rsp */\n \n+/* See MS-FSCC 2.4.42.2 */\n+struct smb2_file_rename_info { /* encoding of request for level 10 */\n+\t/* New members MUST be added within the struct_group() macro below. */\n+\t__struct_group(smb2_file_rename_info_hdr, __hdr, __packed,\n+\t\t__u8   ReplaceIfExists; /* 1 = replace existing target with new */\n+\t\t\t\t\t/* 0 = fail if target already exists */\n+\t\t__u8   Reserved[7];\n+\t\t__u64  RootDirectory;  /* MBZ for network operations (why says spec?) */\n+\t\t__le32 FileNameLength;\n+\t);\n+\tchar   FileName[];     /* New name to be assigned */\n+\t/* padding - overall struct size must be >= 24 so filename + pad >= 6 */\n+} __packed; /* level 10 Set */\n+static_assert(offsetof(struct smb2_file_rename_info, FileName) == sizeof(struct smb2_file_rename_info_hdr),\n+\t      \"struct member likely outside of __struct_group()\");\n+\n+/* File System Information Classes */\n+/* See MS-FSCC 2.5 */\n+#define FS_VOLUME_INFORMATION\t\t1 /* Query */\n+#define FS_LABEL_INFORMATION\t\t2 /* Set */\n+#define FS_SIZE_INFORMATION\t\t3 /* Query */\n+#define FS_DEVICE_INFORMATION\t\t4 /* Query */\n+#define FS_ATTRIBUTE_INFORMATION\t5 /* Query */\n+#define FS_CONTROL_INFORMATION\t\t6 /* Query, Set */\n+#define FS_FULL_SIZE_INFORMATION\t7 /* Query */\n+#define FS_OBJECT_ID_INFORMATION\t8 /* Query, Set */\n+#define FS_DRIVER_PATH_INFORMATION\t9 /* Query */\n+#define FS_SECTOR_SIZE_INFORMATION\t11 /* SMB3 or later. Query */\n+/* See POSIX Extensions to MS-FSCC 2.3.1.1 */\n+#define FS_POSIX_INFORMATION\t\t100 /* SMB3.1.1 POSIX. Query */\n+\n /* See MS-FSCC 2.5.1 */\n #define MAX_FS_NAME_LEN\t\t52\n typedef struct {\n@@ -130,6 +390,45 @@ typedef struct {\n #define FILE_CASE_PRESERVED_NAMES\t0x00000002\n #define FILE_CASE_SENSITIVE_SEARCH\t0x00000001\n \n+/*\n+ * File System Control Information\n+ * See MS-FSCC 2.5.2\n+ */\n+struct smb2_fs_control_info {\n+\t__le64 FreeSpaceStartFiltering;\n+\t__le64 FreeSpaceThreshold;\n+\t__le64 FreeSpaceStopFiltering;\n+\t__le64 DefaultQuotaThreshold;\n+\t__le64 DefaultQuotaLimit;\n+\t__le32 FileSystemControlFlags;\n+\t__le32 Padding;\n+} __packed;\n+\n+/* See MS-FSCC 2.5.4 */\n+struct smb2_fs_full_size_info {\n+\t__le64 TotalAllocationUnits;\n+\t__le64 CallerAvailableAllocationUnits;\n+\t__le64 ActualAvailableAllocationUnits;\n+\t__le32 SectorsPerAllocationUnit;\n+\t__le32 BytesPerSector;\n+} __packed;\n+\n+/* See MS-FSCC 2.5.7 */\n+#define SSINFO_FLAGS_ALIGNED_DEVICE\t\t0x00000001\n+#define SSINFO_FLAGS_PARTITION_ALIGNED_ON_DEVICE 0x00000002\n+#define SSINFO_FLAGS_NO_SEEK_PENALTY\t\t0x00000004\n+#define SSINFO_FLAGS_TRIM_ENABLED\t\t0x00000008\n+/* sector size info struct */\n+struct smb3_fs_ss_info {\n+\t__le32 LogicalBytesPerSector;\n+\t__le32 PhysicalBytesPerSectorForAtomicity;\n+\t__le32 PhysicalBytesPerSectorForPerf;\n+\t__le32 FSEffPhysicalBytesPerSectorForAtomicity;\n+\t__le32 Flags;\n+\t__le32 ByteOffsetForSectorAlignment;\n+\t__le32 ByteOffsetForPartitionAlignment;\n+} __packed;\n+\n /* See MS-FSCC 2.5.8 */\n typedef struct {\n \t__le64 TotalAllocationUnits;\n@@ -200,6 +499,22 @@ typedef struct {\n #define FILE_ATTRIBUTE_NO_SCRUB_DATA_LE\t\tcpu_to_le32(FILE_ATTRIBUTE_NO_SCRUB_DATA)\n #define FILE_ATTRIBUTE_MASK_LE\t\t\tcpu_to_le32(FILE_ATTRIBUTE_MASK)\n \n+/*\n+ * SMB2 Notify Action Flags\n+ * See MS-FSCC 2.7.1\n+ */\n+#define FILE_ACTION_ADDED                       0x00000001\n+#define FILE_ACTION_REMOVED                     0x00000002\n+#define FILE_ACTION_MODIFIED                    0x00000003\n+#define FILE_ACTION_RENAMED_OLD_NAME            0x00000004\n+#define FILE_ACTION_RENAMED_NEW_NAME            0x00000005\n+#define FILE_ACTION_ADDED_STREAM                0x00000006\n+#define FILE_ACTION_REMOVED_STREAM              0x00000007\n+#define FILE_ACTION_MODIFIED_STREAM             0x00000008\n+#define FILE_ACTION_REMOVED_BY_DELETE           0x00000009\n+#define FILE_ACTION_ID_NOT_TUNNELLED            0x0000000A\n+#define FILE_ACTION_TUNNELLED_ID_COLLISION      0x0000000B\n+\n /*\n  * Response contains array of the following structures\n  * See MS-FSCC 2.7.1\ndiff --git a/fs/smb/common/smb2pdu.h b/fs/smb/common/smb2pdu.h\nindex 69dd7c792804..85a4248d4f29 100644\n--- a/fs/smb/common/smb2pdu.h\n+++ b/fs/smb/common/smb2pdu.h\n@@ -1006,22 +1006,6 @@ struct smb2_set_info_rsp {\n #define FILE_NOTIFY_CHANGE_STREAM_SIZE\t\t0x00000400\n #define FILE_NOTIFY_CHANGE_STREAM_WRITE\t\t0x00000800\n \n-/*\n- * SMB2 Notify Action Flags\n- * See MS-FSCC 2.7.1\n- */\n-#define FILE_ACTION_ADDED                       0x00000001\n-#define FILE_ACTION_REMOVED                     0x00000002\n-#define FILE_ACTION_MODIFIED                    0x00000003\n-#define FILE_ACTION_RENAMED_OLD_NAME            0x00000004\n-#define FILE_ACTION_RENAMED_NEW_NAME            0x00000005\n-#define FILE_ACTION_ADDED_STREAM                0x00000006\n-#define FILE_ACTION_REMOVED_STREAM              0x00000007\n-#define FILE_ACTION_MODIFIED_STREAM             0x00000008\n-#define FILE_ACTION_REMOVED_BY_DELETE           0x00000009\n-#define FILE_ACTION_ID_NOT_TUNNELLED            0x0000000A\n-#define FILE_ACTION_TUNNELLED_ID_COLLISION      0x0000000B\n-\n /* See MS-SMB2 2.2.35 */\n struct smb2_change_notify_req {\n \tstruct smb2_hdr hdr;\n@@ -1499,105 +1483,6 @@ struct network_interface_info_ioctl_rsp {\n \t};\n } __packed;\n \n-/* this goes in the ioctl buffer when doing FSCTL_SET_ZERO_DATA */\n-struct file_zero_data_information {\n-\t__le64\tFileOffset;\n-\t__le64\tBeyondFinalZero;\n-} __packed;\n-\n-/* See MS-FSCC 2.3.7 */\n-struct duplicate_extents_to_file {\n-\t__u64 PersistentFileHandle; /* source file handle, opaque endianness */\n-\t__u64 VolatileFileHandle;\n-\t__le64 SourceFileOffset;\n-\t__le64 TargetFileOffset;\n-\t__le64 ByteCount;  /* Bytes to be copied */\n-} __packed;\n-\n-/* See MS-FSCC 2.3.9 */\n-#define DUPLICATE_EXTENTS_DATA_EX_SOURCE_ATOMIC\t0x00000001\n-struct duplicate_extents_to_file_ex {\n-\t__le64 StructureSize; /* MUST be set to 0x30 */\n-\t__u64 PersistentFileHandle; /* source file handle, opaque endianness */\n-\t__u64 VolatileFileHandle;\n-\t__le64 SourceFileOffset;\n-\t__le64 TargetFileOffset;\n-\t__le64 ByteCount;  /* Bytes to be copied */\n-\t__le32 Flags;\n-\t__le32 Reserved;\n-} __packed;\n-\n-\n-/* See MS-FSCC 2.3.20 */\n-struct fsctl_get_integrity_information_rsp {\n-\t__le16\tChecksumAlgorithm;\n-\t__le16\tReserved;\n-\t__le32\tFlags;\n-\t__le32\tChecksumChunkSizeInBytes;\n-\t__le32\tClusterSizeInBytes;\n-} __packed;\n-\n-/* See MS-FSCC 2.3.55 */\n-struct fsctl_query_file_regions_req {\n-\t__le64\tFileOffset;\n-\t__le64\tLength;\n-\t__le32\tDesiredUsage;\n-\t__le32\tReserved;\n-} __packed;\n-\n-/* DesiredUsage flags see MS-FSCC 2.3.56.1 */\n-#define FILE_USAGE_INVALID_RANGE\t0x00000000\n-#define FILE_USAGE_VALID_CACHED_DATA\t0x00000001\n-#define FILE_USAGE_NONCACHED_DATA\t0x00000002\n-\n-struct file_region_info {\n-\t__le64\tFileOffset;\n-\t__le64\tLength;\n-\t__le32\tDesiredUsage;\n-\t__le32\tReserved;\n-} __packed;\n-\n-/* See MS-FSCC 2.3.56 */\n-struct fsctl_query_file_region_rsp {\n-\t__le32 Flags;\n-\t__le32 TotalRegionEntryCount;\n-\t__le32 RegionEntryCount;\n-\t__u32  Reserved;\n-\tstruct  file_region_info Regions[];\n-} __packed;\n-\n-/* See MS-FSCC 2.3.58 */\n-struct fsctl_query_on_disk_vol_info_rsp {\n-\t__le64\tDirectoryCount;\n-\t__le64\tFileCount;\n-\t__le16\tFsFormatMajVersion;\n-\t__le16\tFsFormatMinVersion;\n-\t__u8\tFsFormatName[24];\n-\t__le64\tFormatTime;\n-\t__le64\tLastUpdateTime;\n-\t__u8\tCopyrightInfo[68];\n-\t__u8\tAbstractInfo[68];\n-\t__u8\tFormatImplInfo[68];\n-\t__u8\tLastModifyImplInfo[68];\n-} __packed;\n-\n-/* See MS-FSCC 2.3.73 */\n-struct fsctl_set_integrity_information_req {\n-\t__le16\tChecksumAlgorithm;\n-\t__le16\tReserved;\n-\t__le32\tFlags;\n-} __packed;\n-\n-/* See MS-FSCC 2.3.75 */\n-struct fsctl_set_integrity_info_ex_req {\n-\t__u8\tEnableIntegrity;\n-\t__u8\tKeepState;\n-\t__u16\tReserved;\n-\t__le32\tFlags;\n-\t__u8\tVersion;\n-\t__u8\tReserved2[7];\n-} __packed;\n-\n /* Integrity ChecksumAlgorithm choices for above */\n #define\tCHECKSUM_TYPE_NONE\t0x0000\n #define\tCHECKSUM_TYPE_CRC64\t0x0002\n@@ -1606,72 +1491,6 @@ struct fsctl_set_integrity_info_ex_req {\n /* Integrity flags for above */\n #define FSCTL_INTEGRITY_FLAG_CHECKSUM_ENFORCEMENT_OFF\t0x00000001\n \n-/* Reparse structures - see MS-FSCC 2.1.2 */\n-\n-/* struct fsctl_reparse_info_req is empty, only response structs (see below) */\n-struct reparse_data_buffer {\n-\t__le32\tReparseTag;\n-\t__le16\tReparseDataLength;\n-\t__u16\tReserved;\n-\t__u8\tDataBuffer[]; /* Variable Length */\n-} __packed;\n-\n-struct reparse_guid_data_buffer {\n-\t__le32\tReparseTag;\n-\t__le16\tReparseDataLength;\n-\t__u16\tReserved;\n-\t__u8\tReparseGuid[16];\n-\t__u8\tDataBuffer[]; /* Variable Length */\n-} __packed;\n-\n-struct reparse_mount_point_data_buffer {\n-\t__le32\tReparseTag;\n-\t__le16\tReparseDataLength;\n-\t__u16\tReserved;\n-\t__le16\tSubstituteNameOffset;\n-\t__le16\tSubstituteNameLength;\n-\t__le16\tPrintNameOffset;\n-\t__le16\tPrintNameLength;\n-\t__u8\tPathBuffer[]; /* Variable Length */\n-} __packed;\n-\n-#define SYMLINK_FLAG_RELATIVE 0x00000001\n-\n-struct reparse_symlink_data_buffer {\n-\t__le32\tReparseTag;\n-\t__le16\tReparseDataLength;\n-\t__u16\tReserved;\n-\t__le16\tSubstituteNameOffset;\n-\t__le16\tSubstituteNameLength;\n-\t__le16\tPrintNameOffset;\n-\t__le16\tPrintNameLength;\n-\t__le32\tFlags;\n-\t__u8\tPathBuffer[]; /* Variable Length */\n-} __packed;\n-\n-/* For IO_REPARSE_TAG_NFS - see MS-FSCC 2.1.2.6 */\n-#define NFS_SPECFILE_LNK\t0x00000000014B4E4C\n-#define NFS_SPECFILE_CHR\t0x0000000000524843\n-#define NFS_SPECFILE_BLK\t0x00000000004B4C42\n-#define NFS_SPECFILE_FIFO\t0x000000004F464946\n-#define NFS_SPECFILE_SOCK\t0x000000004B434F53\n-struct reparse_nfs_data_buffer {\n-\t__le32\tReparseTag;\n-\t__le16\tReparseDataLength;\n-\t__u16\tReserved;\n-\t__le64\tInodeType; /* NFS_SPECFILE_* */\n-\t__u8\tDataBuffer[];\n-} __packed;\n-\n-/* For IO_REPARSE_TAG_LX_SYMLINK - see MS-FSCC 2.1.2.7 */\n-struct reparse_wsl_symlink_data_buffer {\n-\t__le32\tReparseTag;\n-\t__le16\tReparseDataLength;\n-\t__u16\tReserved;\n-\t__le32\tVersion; /* Always 2 */\n-\t__u8\tTarget[]; /* Variable Length UTF-8 string without nul-term */\n-} __packed;\n-\n struct validate_negotiate_info_req {\n \t__le32 Capabilities;\n \t__u8   Guid[SMB2_CLIENT_GUID_SIZE];\n@@ -1791,84 +1610,6 @@ struct smb2_query_info_rsp {\n \t__u8   Buffer[];\n } __packed;\n \n-/*\n- *\tPDU query infolevel structure definitions\n- */\n-\n-/* See MS-FSCC 2.3.52 */\n-struct file_allocated_range_buffer {\n-\t__le64\tfile_offset;\n-\t__le64\tlength;\n-} __packed;\n-\n-struct smb2_file_internal_info {\n-\t__le64 IndexNumber;\n-} __packed; /* level 6 Query */\n-\n-struct smb2_file_rename_info { /* encoding of request for level 10 */\n-\t/* New members MUST be added within the struct_group() macro below. */\n-\t__struct_group(smb2_file_rename_info_hdr, __hdr, __packed,\n-\t\t__u8   ReplaceIfExists; /* 1 = replace existing target with new */\n-\t\t\t\t\t/* 0 = fail if target already exists */\n-\t\t__u8   Reserved[7];\n-\t\t__u64  RootDirectory;  /* MBZ for network operations (why says spec?) */\n-\t\t__le32 FileNameLength;\n-\t);\n-\tchar   FileName[];     /* New name to be assigned */\n-\t/* padding - overall struct size must be >= 24 so filename + pad >= 6 */\n-} __packed; /* level 10 Set */\n-static_assert(offsetof(struct smb2_file_rename_info, FileName) == sizeof(struct smb2_file_rename_info_hdr),\n-\t      \"struct member likely outside of __struct_group()\");\n-\n-struct smb2_file_link_info { /* encoding of request for level 11 */\n-\t/* New members MUST be added within the struct_group() macro below. */\n-\t__struct_group(smb2_file_link_info_hdr, __hdr, __packed,\n-\t\t__u8   ReplaceIfExists; /* 1 = replace existing link with new */\n-\t\t\t\t\t/* 0 = fail if link already exists */\n-\t\t__u8   Reserved[7];\n-\t\t__u64  RootDirectory;  /* MBZ for network operations (why says spec?) */\n-\t\t__le32 FileNameLength;\n-\t);\n-\tchar   FileName[];     /* Name to be assigned to new link */\n-} __packed; /* level 11 Set */\n-static_assert(offsetof(struct smb2_file_link_info, FileName) == sizeof(struct smb2_file_link_info_hdr),\n-\t      \"struct member likely outside of __struct_group()\");\n-\n-/*\n- * This level 18, although with struct with same name is different from cifs\n- * level 0x107. Level 0x107 has an extra u64 between AccessFlags and\n- * CurrentByteOffset.\n- */\n-struct smb2_file_all_info { /* data block encoding of response to level 18 */\n-\t__le64 CreationTime;\t/* Beginning of FILE_BASIC_INFO equivalent */\n-\t__le64 LastAccessTime;\n-\t__le64 LastWriteTime;\n-\t__le64 ChangeTime;\n-\t__le32 Attributes;\n-\t__u32  Pad1;\t\t/* End of FILE_BASIC_INFO_INFO equivalent */\n-\t__le64 AllocationSize;\t/* Beginning of FILE_STANDARD_INFO equivalent */\n-\t__le64 EndOfFile;\t/* size ie offset to first free byte in file */\n-\t__le32 NumberOfLinks;\t/* hard links */\n-\t__u8   DeletePending;\n-\t__u8   Directory;\n-\t__u16  Pad2;\t\t/* End of FILE_STANDARD_INFO equivalent */\n-\t__le64 IndexNumber;\n-\t__le32 EASize;\n-\t__le32 AccessFlags;\n-\t__le64 CurrentByteOffset;\n-\t__le32 Mode;\n-\t__le32 AlignmentRequirement;\n-\t__le32 FileNameLength;\n-\tunion {\n-\t\tchar __pad;\t/* Legacy structure padding */\n-\t\tDECLARE_FLEX_ARRAY(char, FileName);\n-\t};\n-} __packed; /* level 18 Query */\n-\n-struct smb2_file_eof_info { /* encoding of request for level 10 */\n-\t__le64 EndOfFile; /* new end of file value */\n-} __packed; /* level 20 Set */\n-\n /* Level 100 query info */\n struct smb311_posix_qinfo {\n \t__le64 CreationTime;\n@@ -1894,54 +1635,6 @@ struct smb311_posix_qinfo {\n \t */\n } __packed;\n \n-/* File System Information Classes */\n-#define FS_VOLUME_INFORMATION\t\t1 /* Query */\n-#define FS_LABEL_INFORMATION\t\t2 /* Set */\n-#define FS_SIZE_INFORMATION\t\t3 /* Query */\n-#define FS_DEVICE_INFORMATION\t\t4 /* Query */\n-#define FS_ATTRIBUTE_INFORMATION\t5 /* Query */\n-#define FS_CONTROL_INFORMATION\t\t6 /* Query, Set */\n-#define FS_FULL_SIZE_INFORMATION\t7 /* Query */\n-#define FS_OBJECT_ID_INFORMATION\t8 /* Query, Set */\n-#define FS_DRIVER_PATH_INFORMATION\t9 /* Query */\n-#define FS_SECTOR_SIZE_INFORMATION\t11 /* SMB3 or later. Query */\n-#define FS_POSIX_INFORMATION\t\t100 /* SMB3.1.1 POSIX. Query */\n-\n-struct smb2_fs_full_size_info {\n-\t__le64 TotalAllocationUnits;\n-\t__le64 CallerAvailableAllocationUnits;\n-\t__le64 ActualAvailableAllocationUnits;\n-\t__le32 SectorsPerAllocationUnit;\n-\t__le32 BytesPerSector;\n-} __packed;\n-\n-#define SSINFO_FLAGS_ALIGNED_DEVICE\t\t0x00000001\n-#define SSINFO_FLAGS_PARTITION_ALIGNED_ON_DEVICE 0x00000002\n-#define SSINFO_FLAGS_NO_SEEK_PENALTY\t\t0x00000004\n-#define SSINFO_FLAGS_TRIM_ENABLED\t\t0x00000008\n-\n-/* sector size info struct */\n-struct smb3_fs_ss_info {\n-\t__le32 LogicalBytesPerSector;\n-\t__le32 PhysicalBytesPerSectorForAtomicity;\n-\t__le32 PhysicalBytesPerSectorForPerf;\n-\t__le32 FSEffPhysicalBytesPerSectorForAtomicity;\n-\t__le32 Flags;\n-\t__le32 ByteOffsetForSectorAlignment;\n-\t__le32 ByteOffsetForPartitionAlignment;\n-} __packed;\n-\n-/* File System Control Information */\n-struct smb2_fs_control_info {\n-\t__le64 FreeSpaceStartFiltering;\n-\t__le64 FreeSpaceThreshold;\n-\t__le64 FreeSpaceStopFiltering;\n-\t__le64 DefaultQuotaThreshold;\n-\t__le64 DefaultQuotaLimit;\n-\t__le32 FileSystemControlFlags;\n-\t__le32 Padding;\n-} __packed;\n-\n /* See MS-SMB2 2.2.23 through 2.2.25 */\n struct smb2_oplock_break {\n \tstruct smb2_hdr hdr;\n",
    "prefixes": [
        "v3",
        "2/5"
    ]
}