aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Hill <daniel@gluo.nz>2023-02-11 13:45:23 +1300
committerDaniel Hill <daniel@gluo.nz>2023-02-11 13:45:23 +1300
commit157ea20eb26e214374e917813a78ecf6068db76e (patch)
tree2d589e8308fa72771bbe5ff999585cec96912b14
parent284c1f5148afb088e64c8a77983a43732c4d499b (diff)
downloadbcachefs-tools-157ea20eb26e214374e917813a78ecf6068db76e.tar.gz
mount: support remount
remount is handled by libc, not the kernel mount procedure, this fixes remounts. Also sorted the list of flags. Signed-off-by: Daniel Hill <daniel@gluo.nz>
-rw-r--r--rust-src/mount/src/filesystem.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/rust-src/mount/src/filesystem.rs b/rust-src/mount/src/filesystem.rs
index f47319c9..28a2ab9e 100644
--- a/rust-src/mount/src/filesystem.rs
+++ b/rust-src/mount/src/filesystem.rs
@@ -128,9 +128,10 @@ fn parse_mount_options(options: impl AsRef<str>) -> (Option<String>, u64) {
"nodiratime" => Left(libc::MS_NODIRATIME),
"noexec" => Left(libc::MS_NOEXEC),
"nosuid" => Left(libc::MS_NOSUID),
+ "relatime" => Left(libc::MS_RELATIME),
+ "remount" => Left(libc::MS_REMOUNT),
"ro" => Left(libc::MS_RDONLY),
"rw" => Left(0),
- "relatime" => Left(libc::MS_RELATIME),
"strictatime" => Left(libc::MS_STRICTATIME),
"sync" => Left(libc::MS_SYNCHRONOUS),
"" => Left(0),