]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - fs/ceph/dir.c
ceph: send LSSNAP request to auth mds of directory inode
[mirror_ubuntu-bionic-kernel.git] / fs / ceph / dir.c
index ef7240ace5767a0439f9eab941725b900281e844..019c2036d36f3e15b86a4da732b5cfd862e4670a 100644 (file)
@@ -377,8 +377,10 @@ more:
                }
                /* hints to request -> mds selection code */
                req->r_direct_mode = USE_AUTH_MDS;
-               req->r_direct_hash = ceph_frag_value(frag);
-               __set_bit(CEPH_MDS_R_DIRECT_IS_HASH, &req->r_req_flags);
+               if (op == CEPH_MDS_OP_READDIR) {
+                       req->r_direct_hash = ceph_frag_value(frag);
+                       __set_bit(CEPH_MDS_R_DIRECT_IS_HASH, &req->r_req_flags);
+               }
                if (fi->last_name) {
                        req->r_path2 = kstrdup(fi->last_name, GFP_KERNEL);
                        if (!req->r_path2) {