aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ceph
diff options
context:
space:
mode:
authorSage Weil <sage@inktank.com>2013-01-21 00:55:30 -0500
committerSage Weil <sage@inktank.com>2013-02-13 21:25:55 -0500
commitd421acb1ad7dfa31b7463b67f1593714b0b727c3 (patch)
treef35d7a19bbd533269bc273be20b0fbfcb26b64e0 /fs/ceph
parent3adf654ddbc355c23d75c6684128d4b067a7b792 (diff)
ceph: pass ceph.* removexattrs through to MDS
If we do not explicitly recognized a vxattr (e.g., as readonly), pass the request through to the MDS and deal with it there. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Sam Lang <sam.lang@inktank.com>
Diffstat (limited to 'fs/ceph')
-rw-r--r--fs/ceph/xattr.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/ceph/xattr.c b/fs/ceph/xattr.c
index edc47de77fed..234270f00c2a 100644
--- a/fs/ceph/xattr.c
+++ b/fs/ceph/xattr.c
@@ -892,6 +892,10 @@ int ceph_removexattr(struct dentry *dentry, const char *name)
892 if (vxattr && vxattr->readonly) 892 if (vxattr && vxattr->readonly)
893 return -EOPNOTSUPP; 893 return -EOPNOTSUPP;
894 894
895 /* pass any unhandled ceph.* xattrs through to the MDS */
896 if (!strncmp(name, XATTR_CEPH_PREFIX, XATTR_CEPH_PREFIX_LEN))
897 goto do_sync_unlocked;
898
895 err = -ENOMEM; 899 err = -ENOMEM;
896 spin_lock(&ci->i_ceph_lock); 900 spin_lock(&ci->i_ceph_lock);
897retry: 901retry:
@@ -931,6 +935,7 @@ retry:
931 return err; 935 return err;
932do_sync: 936do_sync:
933 spin_unlock(&ci->i_ceph_lock); 937 spin_unlock(&ci->i_ceph_lock);
938do_sync_unlocked:
934 err = ceph_send_removexattr(dentry, name); 939 err = ceph_send_removexattr(dentry, name);
935out: 940out:
936 return err; 941 return err;