diff options
author | Steve French <stfrench@microsoft.com> | 2022-06-01 22:08:46 -0500 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2022-06-01 22:30:36 -0500 |
commit | 7ef93ffccd55fb0ba000ed16ef6a81cd7dee07b5 (patch) | |
tree | bebdbda9aaf7f86954a934d29da956119607413e /fs/cifs/cifsglob.h | |
parent | 387ba9bf4cb80277fb01a7b753da611ab1260a1a (diff) | |
download | linux-7ef93ffccd55fb0ba000ed16ef6a81cd7dee07b5.tar.gz |
cifs: version operations for smb20 unneeded when legacy support disabled
We should not be including unused smb20 specific code when legacy
support is disabled (CONFIG_CIFS_ALLOW_INSECURE_LEGACY turned
off). For example smb2_operations and smb2_values aren't used
in that case. Over time we can move more and more SMB1/CIFS and SMB2.0
code into the insecure legacy ifdefs
Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/cifs/cifsglob.h')
-rw-r--r-- | fs/cifs/cifsglob.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h index d589e687611d..f873379066c7 100644 --- a/fs/cifs/cifsglob.h +++ b/fs/cifs/cifsglob.h @@ -1963,11 +1963,13 @@ extern mempool_t *cifs_mid_poolp; /* Operations for different SMB versions */ #define SMB1_VERSION_STRING "1.0" +#define SMB20_VERSION_STRING "2.0" +#ifdef CONFIG_CIFS_ALLOW_INSECURE_LEGACY extern struct smb_version_operations smb1_operations; extern struct smb_version_values smb1_values; -#define SMB20_VERSION_STRING "2.0" extern struct smb_version_operations smb20_operations; extern struct smb_version_values smb20_values; +#endif /* CIFS_ALLOW_INSECURE_LEGACY */ #define SMB21_VERSION_STRING "2.1" extern struct smb_version_operations smb21_operations; extern struct smb_version_values smb21_values; |