From 3f092f7778ed608d454df4c3dc3b3f7cb4afde3b Mon Sep 17 00:00:00 2001 From: Tom Marshall Date: Mon, 24 Nov 2014 16:02:04 -0800 Subject: recovery: Awakening of MiniVold A minimal vold client for recovery. Change-Id: Id25d955dc1861a910e5f5fc27d9a19e245d66833 --- roots.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'roots.h') diff --git a/roots.h b/roots.h index 6e3b243..f3e1903 100644 --- a/roots.h +++ b/roots.h @@ -18,6 +18,7 @@ #define RECOVERY_ROOTS_H_ #include "common.h" +#include // Load and parse volume data from /etc/recovery.fstab. void load_volume_table(); @@ -27,6 +28,7 @@ Volume* volume_for_path(const char* path); // Make sure that the volume 'path' is on is mounted. Returns 0 on // success (volume is mounted). +int ensure_volume_mounted(Volume* v); int ensure_path_mounted(const char* path); // Similar to ensure_path_mounted, but allows one to specify the mount_point. @@ -34,7 +36,8 @@ int ensure_path_mounted_at(const char* path, const char* mount_point); // Make sure that the volume 'path' is on is unmounted. Returns 0 on // success (volume is unmounted); -int ensure_path_unmounted(const char* path); +int ensure_volume_unmounted(Volume *v, bool detach=false); +int ensure_path_unmounted(const char* path, bool detach=false); // Reformat the given volume (must be the mount point only, eg // "/cache"), no paths permitted. Attempts to unmount the volume if @@ -45,4 +48,10 @@ int format_volume(const char* volume); // mounted (/tmp and /cache) are mounted. Returns 0 on success. int setup_install_mounts(); +int get_num_volumes(); + +int is_data_media(); + +#define MAX_NUM_MANAGED_VOLUMES 10 + #endif // RECOVERY_ROOTS_H_ -- cgit v1.1