Message ID | 20210409162422.1326565-4-brauner@kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | ecryptfs: fixes and port to private mounts | expand |
diff --git a/fs/ecryptfs/main.c b/fs/ecryptfs/main.c index 9dcf9a0dd37b..cdf37d856c62 100644 --- a/fs/ecryptfs/main.c +++ b/fs/ecryptfs/main.c @@ -569,7 +569,7 @@ static struct dentry *ecryptfs_mount(struct file_system_type *fs_type, int flags * 1) The lower mount is ro * 2) The ecryptfs_encrypted_view mount option is specified */ - if (sb_rdonly(path.dentry->d_sb) || mount_crypt_stat->flags & ECRYPTFS_ENCRYPTED_VIEW_ENABLED) + if (__mnt_is_readonly(mnt) || mount_crypt_stat->flags & ECRYPTFS_ENCRYPTED_VIEW_ENABLED) s->s_flags |= SB_RDONLY; s->s_maxbytes = path.dentry->d_sb->s_maxbytes;