mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 10:58:12 +00:00
Kernel+Userland: Support remounting filesystems :^)
This makes it possible to change flags of a mount after the fact, with the caveats outlined in the man page.
This commit is contained in:
parent
d395b93b15
commit
3847d00727
8 changed files with 58 additions and 0 deletions
|
@ -4103,6 +4103,11 @@ int Process::sys$mount(const Syscall::SC_mount_params* user_params)
|
|||
|
||||
auto& target_custody = custody_or_error.value();
|
||||
|
||||
if (params.flags & MS_REMOUNT) {
|
||||
// We're not creating a new mount, we're updating an existing one!
|
||||
return VFS::the().remount(target_custody, params.flags & ~MS_REMOUNT);
|
||||
}
|
||||
|
||||
if (params.flags & MS_BIND) {
|
||||
// We're doing a bind mount.
|
||||
if (description.is_null())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue