smb: client: fix missing mode bits for SMB symlinks
[platform/kernel/linux-starfive.git] / fs / smb / client / inode.c
index c03a286..2fc3690 100644 (file)
@@ -748,7 +748,7 @@ bool cifs_reparse_point_to_fattr(struct cifs_sb_info *cifs_sb,
        case 0: /* SMB1 symlink */
        case IO_REPARSE_TAG_SYMLINK:
        case IO_REPARSE_TAG_NFS:
-               fattr->cf_mode = S_IFLNK;
+               fattr->cf_mode = S_IFLNK | cifs_sb->ctx->file_mode;
                fattr->cf_dtype = DT_LNK;
                break;
        default: