OSDN Git Service

cifs: fix minor compile warning
authorSteve French <stfrench@microsoft.com>
Mon, 23 May 2022 02:25:24 +0000 (21:25 -0500)
committerSteve French <stfrench@microsoft.com>
Tue, 24 May 2022 01:24:12 +0000 (20:24 -0500)
Add ifdef around nodfs variable from patch:
  "cifs: don't call cifs_dfs_query_info_nonascii_quirk() if nodfs was set"
which is unused when CONFIG_DFS_UPCALL is not set.

Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/connect.c

index 44dc66f..0b08693 100644 (file)
@@ -3433,7 +3433,9 @@ static int is_path_remote(struct mount_ctx *mnt_ctx)
        struct cifs_tcon *tcon = mnt_ctx->tcon;
        struct smb3_fs_context *ctx = mnt_ctx->fs_ctx;
        char *full_path;
+#ifdef CONFIG_CIFS_DFS_UPCALL
        bool nodfs = cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_DFS;
+#endif
 
        if (!server->ops->is_path_accessible)
                return -EOPNOTSUPP;