mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
vfs: prevent remount read-only if pending removes
If there are any inodes on the super block that have been unlinked (i_nlink == 0) but have not yet been deleted then prevent the remounting the super block read-only. Reported-by: Toshiyuki Okajima <[email protected]> Signed-off-by: Miklos Szeredi <[email protected]> Tested-by: Toshiyuki Okajima <[email protected]> Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
7ada4db886
commit
8e8b87964b
4 changed files with 7 additions and 29 deletions
|
|
@ -729,10 +729,6 @@ int do_remount_sb(struct super_block *sb, int flags, void *data, int force)
|
|||
retval = sb_prepare_remount_readonly(sb);
|
||||
if (retval)
|
||||
return retval;
|
||||
|
||||
retval = -EBUSY;
|
||||
if (!fs_may_remount_ro(sb))
|
||||
goto cancel_readonly;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue