Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
On low power turn off rather than rebooting to allow device to charge
The code was using encrypted_upto == 0 as an indicator that encryption has succeeded. This meant that if no encryption happened, we would reboot continually. We now set encrypted_upto to fs_size when encryption is complete. Also don't start to encrypt unless we are at 10% power. Stop when we get to 5% power. This should lead to partial encryptions only very rarely. Bug: 15513202 Change-Id: I6214d78579d1fbbe2f63ee8862473d86a89d29b3
- Loading branch information
1 parent
cba4ab2
commit 73d7a02
Showing
3 changed files
with
69 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters