Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 361881
b: refs/heads/master
c: 90563b1
h: refs/heads/master
i:
  361879: 346a167
v: v3
  • Loading branch information
Eric W. Biederman committed Mar 27, 2013
1 parent 3d89622 commit 8a50d3a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3151527ee007b73a0ebd296010f1c0454a919c7d
refs/heads/master: 90563b198e4c6674c63672fae1923da467215f45
3 changes: 3 additions & 0 deletions trunk/fs/namespace.c
Original file line number Diff line number Diff line change
Expand Up @@ -1713,6 +1713,9 @@ static int change_mount_flags(struct vfsmount *mnt, int ms_flags)
if (readonly_request == __mnt_is_readonly(mnt))
return 0;

if (mnt->mnt_flags & MNT_LOCK_READONLY)
return -EPERM;

if (readonly_request)
error = mnt_make_readonly(real_mount(mnt));
else
Expand Down
2 changes: 2 additions & 0 deletions trunk/include/linux/mount.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ struct mnt_namespace;

#define MNT_INTERNAL 0x4000

#define MNT_LOCK_READONLY 0x400000

struct vfsmount {
struct dentry *mnt_root; /* root of the mounted tree */
struct super_block *mnt_sb; /* pointer to superblock */
Expand Down

0 comments on commit 8a50d3a

Please sign in to comment.