diff options
author | Paul Lawrence <paullawrence@google.com> | 2016-03-04 15:52:33 -0800 |
---|---|---|
committer | Paul Lawrence <paullawrence@google.com> | 2016-03-04 15:52:33 -0800 |
commit | 1098aacde46dffeb97d03e4079a9ef8ffac8199e (patch) | |
tree | 5b3fc56367bcbe19a8f0f88fc35bca035640d99a /init/builtins.cpp | |
parent | a996c2963a9c1fa9d2339e560c7d6dad2be4a2f8 (diff) |
Distinguish between unencrypted and unencryptable
Set ro.crypto.state flag to unencrypted and unsupported accordingly
Bug: 18002358
Change-Id: I1f88ce9704c5505d7b63256e2ebe5f8441c79ad0
Diffstat (limited to 'init/builtins.cpp')
-rw-r--r-- | init/builtins.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/init/builtins.cpp b/init/builtins.cpp index 229487fe7..2e7283206 100644 --- a/init/builtins.cpp +++ b/init/builtins.cpp @@ -501,9 +501,9 @@ static int do_mount_all(const std::vector<std::string>& args) { property_set("vold.decrypt", "trigger_default_encryption"); } else if (ret == FS_MGR_MNTALL_DEV_NOT_ENCRYPTED) { property_set("ro.crypto.state", "unencrypted"); - /* If fs_mgr determined this is an unencrypted device, then trigger - * that action. - */ + ActionManager::GetInstance().QueueEventTrigger("nonencrypted"); + } else if (ret == FS_MGR_MNTALL_DEV_NOT_ENCRYPTABLE) { + property_set("ro.crypto.state", "unsupported"); ActionManager::GetInstance().QueueEventTrigger("nonencrypted"); } else if (ret == FS_MGR_MNTALL_DEV_NEEDS_RECOVERY) { /* Setup a wipe via recovery, and reboot into recovery */ |