fs_mgr: add support for new recoveryonly flag
If a device has an ext4 partition that contains the radio
firmware, and that filesystem is not mounted in normal
operation, we need a flag to prevent mount_all from
mounting it, so the new flag recoveryonly was added.
Change-Id: I361800c494e751b04c4faf956870f15fd0d8fe20
diff --git a/fs_mgr/fs_mgr.c b/fs_mgr/fs_mgr.c
index fd6f13d..8f64757 100644
--- a/fs_mgr/fs_mgr.c
+++ b/fs_mgr/fs_mgr.c
@@ -75,6 +75,7 @@
{ "nonremovable",MF_NONREMOVABLE },
{ "voldmanaged=",MF_VOLDMANAGED},
{ "length=", MF_LENGTH },
+ { "recoveryonly",MF_RECOVERYONLY },
{ "defaults", 0 },
{ 0, 0 },
};
@@ -523,7 +524,7 @@
for (i = 0; i < fstab->num_entries; i++) {
/* Don't mount entries that are managed by vold */
- if (fstab->recs[i].fs_mgr_flags & MF_VOLDMANAGED) {
+ if (fstab->recs[i].fs_mgr_flags & (MF_VOLDMANAGED | MF_RECOVERYONLY)) {
continue;
}
diff --git a/fs_mgr/fs_mgr_priv.h b/fs_mgr/fs_mgr_priv.h
index 374931b..75dad49 100644
--- a/fs_mgr/fs_mgr_priv.h
+++ b/fs_mgr/fs_mgr_priv.h
@@ -68,6 +68,7 @@
#define MF_NONREMOVABLE 0x8
#define MF_VOLDMANAGED 0x10
#define MF_LENGTH 0x20
+#define MF_RECOVERYONLY 0x40
#endif /* __CORE_FS_MGR_PRIV_H */