summaryrefslogtreecommitdiff
path: root/fs/ceph/acl.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ceph/acl.c')
-rw-r--r--fs/ceph/acl.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/ceph/acl.c b/fs/ceph/acl.c
index d0b6b342dff9..987044bca1c2 100644
--- a/fs/ceph/acl.c
+++ b/fs/ceph/acl.c
@@ -125,6 +125,11 @@ int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type)
goto out_free;
}
+ if (ceph_snap(inode) != CEPH_NOSNAP) {
+ ret = -EROFS;
+ goto out_free;
+ }
+
if (new_mode != old_mode) {
newattrs.ia_mode = new_mode;
newattrs.ia_valid = ATTR_MODE;