mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 16:50:54 +07:00
ceph: don't request excl caps when mount is readonly
Signed-off-by: "Yan, Zheng" <zyan@redhat.com> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
This commit is contained in:
parent
3c1392d4c4
commit
8a2ac3a8e9
@ -1862,6 +1862,9 @@ void ceph_check_caps(struct ceph_inode_info *ci, int flags,
|
||||
* revoking the shared cap on every create/unlink
|
||||
* operation.
|
||||
*/
|
||||
if (IS_RDONLY(inode))
|
||||
want = CEPH_CAP_ANY_SHARED;
|
||||
else
|
||||
want = CEPH_CAP_ANY_SHARED | CEPH_CAP_FILE_EXCL;
|
||||
retain |= want;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user