aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* minui: add ev_get_epollfd() to retrieve epoll file descriptorTodd Poynor2013-09-122-0/+6
| | | | | | To allow use of ev_* functions with an external main loop. Change-Id: If73717b64d7c455ca726b90a815a31c1edf52544
* recovery: ui changes for ev_*() switch to epollTodd Poynor2013-09-122-3/+3
| | | | | | Convert callback events parameter to unsigned int. Change-Id: Ife0e983f307c07bf4aca807d70574aeb20c460cd
* minui: convert ev_*() event interface to epollTodd Poynor2013-09-122-27/+58
| | | | | | | | | | | Help enable external main loop combined with ev_*() key event processing. Specify EPOLLWAKEUP to hold a wakelock on any event, assuming this is needed (may need to make this optional). Convert callback events parameter to unsigned int. Change-Id: Ib5e09abbd7724ffd830e2cf8e25e7eb59d3aa072
* am 1306a7ef: am cc2958fd: fix secure adb in recoveryDoug Zongker2013-09-111-0/+1
|\ | | | | | | | | * commit '1306a7effafab77cf2769091619518c2ab263ee8': fix secure adb in recovery
| * am cc2958fd: fix secure adb in recoveryDoug Zongker2013-09-111-0/+1
| |\ | | | | | | | | | | | | * commit 'cc2958fd7f32f79d1a034eee005e04afeb310a87': fix secure adb in recovery
| | * fix secure adb in recoveryDoug Zongker2013-09-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Recovery's init.rc was missing a line (added to the main system's init.rc in change Ic97fd464440ff4a29fc9da7ad15949ac5215ade3) is required for secure adb to work. Change-Id: Id79b94d2abb4cbe3cca7cabeb4bc5faf7205e56b
* | | updater: Delete dead codeNick Kralevich2013-09-113-153/+0
| | | | | | | | | | | | | | | | | | set_perm and set_perm_recursive are no longer used. Delete. Change-Id: I3bb40b934b6c093b24b88aa4ed6f3c7de2bb52f0
* | | am af677d78: am e461251e: Don\'t apply permission changes to symlink.Nick Kralevich2013-09-101-0/+5
|\ \ \ | |/ / | | | | | | | | | * commit 'af677d786e6333187ccbd4f7fe6f371a09b71645': Don't apply permission changes to symlink.
| * | am e461251e: Don\'t apply permission changes to symlink.Nick Kralevich2013-09-101-0/+5
| |\ \ | | |/ | | | | | | | | | * commit 'e461251e2caa5561cf6a315bffaebfd4eb896b1d': Don't apply permission changes to symlink.
| | * Don't apply permission changes to symlink.Nick Kralevich2013-09-101-0/+5
| | | | | | | | | | | | | | | | | | | | | Bug: 10183961 Bug: 10186213 Bug: 8985290 Change-Id: I57cb14af59682c5f25f1e091564548bdbf20f74e
* | | am cc421662: am 5dbdef0e: updater: introduce and set_metadata and ↵Nick Kralevich2013-09-101-0/+274
|\ \ \ | |/ / | | | | | | | | | | | | | | | set_metadata_recursive * commit 'cc421662d7f9b68627204b8c8bfb4a5cada74125': updater: introduce and set_metadata and set_metadata_recursive
| * | am 5dbdef0e: updater: introduce and set_metadata and set_metadata_recursiveNick Kralevich2013-09-101-0/+274
| |\ \ | | |/ | | | | | | | | | * commit '5dbdef0e5b8a841fadc64d016d10ce81a962b284': updater: introduce and set_metadata and set_metadata_recursive
| | * updater: introduce and set_metadata and set_metadata_recursiveNick Kralevich2013-09-101-0/+274
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce two new updater functions: * set_metadata * set_metadata_recursive Long term, these functions are intended to be more flexible replacements for the following methods: * set_perm * set_perm_recursive Usage: set_metadata("filename", "key1", "value1", "key2", "value2", ...) set_metadata_recursive("dirname", "key1", "value1", "key2", "value2", ...) Description: set_metadata() and set_metadata_recursive() set the attributes on a file/directory according to the key/value pairs provided. Today, the following keys are supported: * uid * gid * mode (set_perm_extd only) * fmode (set_perm_extd_recursive only) * dmode (set_perm_extd_recursive only) * selabel * capabilities Unknown keys are logged as warnings, but are not fatal errors. Examples: * set_metadata("/system/bin/netcfg", "selabel", "u:object_r:system_file:s0"); This sets the SELinux label of /system/bin/netcfg to u:object_r:system_file:s0. No other changes occur. * set_metadata("/system/bin/netcfg", "uid", 0, "gid", 3003, "mode", 02750, "selabel", "u:object_r:system_file:s0", "capabilities", 0x0); This sets /system/bin/netcfg to uid=0, gid=3003, mode=02750, selinux label=u:object_r:system_file:s0, and clears the capabilities associated with the file. * set_metadata_recursive("/system", "uid", 0, "gid", 0, "fmode", 0644, "dmode", 0755, "selabel", "u:object_r:system_file:s0", "capabilities", 0x0); All files and directories under /system are set to uid=0, gid=0, and selinux label=u:object_r:system_file:s0. Directories are set to mode=0755. Files are set to mode=0644 and all capabilities are cleared. Bug: 10183961 Bug: 10186213 Bug: 8985290 Change-Id: Ifdcf186a7ed45265511dc493c4036e1ac5e3d0af
* | | am 5ae88e89: am 3328e3bc: Revert "Update OTA installer to understand SELinux ↵Nick Kralevich2013-09-103-32/+8
|\ \ \ | |/ / | | | | | | | | | | | | | | | filesystem labels" * commit '5ae88e899836e7e3350db55ac47aee6f219cf126': Revert "Update OTA installer to understand SELinux filesystem labels"
| * | am 3328e3bc: Revert "Update OTA installer to understand SELinux filesystem ↵Nick Kralevich2013-09-103-32/+8
| |\ \ | | |/ | | | | | | | | | | | | | | | labels" * commit '3328e3bc81161c2a57ea94d304162276facdd826': Revert "Update OTA installer to understand SELinux filesystem labels"
| | * Revert "Update OTA installer to understand SELinux filesystem labels"Nick Kralevich2013-09-093-32/+8
| | | | | | | | | | | | | | | | | | | | | This reverts commit 627eb30f73c29257acaeb6568f3da38880784f7c. Bug: 10183961 Bug: 10186213
* | | allow CheckKey to request mounting /systemDoug Zongker2013-09-043-3/+52
| | | | | | | | | | | | | | | | | | | | | Also provide a default implementation of CheckKey that's reasonable for many devices (those that have power and volume keys). Change-Id: Icf6c7746ebd866152d402059dbd27fd16bd51ff8
* | | am f187a543: am 3b5a987c: recovery: fix use of init reboot methodDoug Zongker2013-09-031-1/+1
|\ \ \ | |/ / | | | | | | | | | * commit 'f187a5438d5a0651c344038f2203469e193704f9': recovery: fix use of init reboot method
| * | am 3b5a987c: recovery: fix use of init reboot methodDoug Zongker2013-09-031-1/+1
| |\ \ | | |/ | | | | | | | | | * commit '3b5a987cd7fd76c038e9875b430028216d21ace3': recovery: fix use of init reboot method
| | * recovery: fix use of init reboot methodDoug Zongker2013-09-031-1/+1
| | | | | | | | | | | | | | | | | | | | | We need to set the system property to "reboot,", not an empty string. Bug: 10605007 Change-Id: I776e0d273764cf254651ab2b25c2743395b990e0
* | | am 366f78a9: am 77ea71d6: recovery: fix rebootingDoug Zongker2013-08-302-1/+4
|\ \ \ | |/ / | | | | | | | | | * commit '366f78a9df45d6648746de8454655224b22c31fd': recovery: fix rebooting
| * | am 77ea71d6: recovery: fix rebootingDoug Zongker2013-08-302-1/+4
| |\ \ | | |/ | | | | | | | | | * commit '77ea71d6a85a93c9bf423466e87661b1bf67c512': recovery: fix rebooting
| | * recovery: fix rebootingDoug Zongker2013-08-302-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | Change I84c0513acb549720cb0e8c9fcbda0050f5c396f5 moved reboot functionality into init but did not update the recovery partition; so "adb reboot" and /system/bin/reboot in recovery are both broken. Change-Id: Ie2d14627a686ffb5064256b6c399723636dff116
* | | am 19877de5: am 5c4e1dac: Merge "Update libpng API usage"John Reck2013-08-270-0/+0
|\ \ \ | |/ / | | | | | | | | | * commit '19877de513a9493dad77488144089b4f30103b74': Update libpng API usage
| * | am 5c4e1dac: Merge "Update libpng API usage"John Reck2013-08-271-12/+12
| |\ \ | | |/ | |/| | | | | | | * commit '5c4e1dac0bd8f31559bd50eec4343b7a17b7a976': Update libpng API usage
| | * Merge "Update libpng API usage"John Reck2013-08-271-12/+12
| | |\
| | | * Update libpng API usageJohn Reck2013-08-261-12/+12
| | |/ | | | | | | | | | | | | | | | Remove usage of deprecated methods Change-Id: I747568a2c8c0c65ecbc9a3da4bac7b9cac7708ab
* | | am 239ac6ab: recovery: install packages in a known mount environmentDoug Zongker2013-08-225-11/+35
|\ \ \ | |/ / | | | | | | | | | * commit '239ac6abac4524be93fce710360c0512c6cc2ab3': recovery: install packages in a known mount environment
| * | recovery: install packages in a known mount environmentDoug Zongker2013-08-215-11/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When installing a package, we should have /tmp and /cache mounted and nothing else. Ensure this is true by explicitly mounting them and unmounting everything else as the first step of every install. Also fix an error in the progress bar that crops up when you do multiple package installs in one instance of recovery. Change-Id: I4837ed707cb419ddd3d9f6188b6355ba1bcfe2b2
* | | Fix libpng API usageJohn Reck2013-08-131-12/+12
|/ / | | | | | | | | | | Remove usage of deprecated methods that were removed in 1.6 Change-Id: I2a669bf5201197f60adfdbe512fd729bebb74f9c
* | notify about pending long pressDoug Zongker2013-07-315-27/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recovery changes: - add a method to the UI class that is called when a key is held down long enough to be a "long press" (but before it is released). Device-specific subclasses can override this to indicate a long press. - do color selection for ScreenRecoveryUI's menu-and-log drawing function. Subclasses can override this to customize the colors they use for various elements. - Include the value of ro.build.display.id in the menu headers, so you can see on the screen what version of recovery you are running. Change-Id: I426a6daf892b9011638e2035aebfa2831d4f596d
* | Merge "start healthd in recovery"Todd Poynor2013-07-261-0/+4
|\ \
| * | start healthd in recoveryTodd Poynor2013-06-181-0/+4
| | | | | | | | | | | | Change-Id: I16e3e0ddb8ca062431deb4be83c5be5eb786d76f
* | | Update OTA installer to understand SELinux filesystem labelsNick Kralevich2013-07-183-8/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Modify the OTA installer to understand SELinux filesystem labels. We do this by introducing new set_perm2 / set_perm2_recursive calls, which understand SELinux filesystem labels. These filesystem labels are applied at the same time that we apply the UID / GID / permission changes. For compatibility, we preserve the behavior of the existing set_perm / set_perm_recursive calls. If the destination kernel doesn't support security labels, don't fail. SELinux isn't enabled on all kernels. Bug: 8985290 Change-Id: I99800499f01784199e4918a82e3e2db1089cf25b
* | | am a69b50c5: am 901b898d: recovery: remove O_DIRECT, use O_SYNC onlyDoug Zongker2013-07-111-2/+2
|\ \ \ | | |/ | |/| | | | | | | * commit 'a69b50c567d46afad73c4d6ab9e57f078ee73327': recovery: remove O_DIRECT, use O_SYNC only
| * | am 901b898d: recovery: remove O_DIRECT, use O_SYNC onlyDoug Zongker2013-07-111-2/+2
| |\ \ | | | | | | | | | | | | | | | | * commit '901b898d5e4d7cc555974b8132f83f948f8fbaee': recovery: remove O_DIRECT, use O_SYNC only
| | * | recovery: remove O_DIRECT, use O_SYNC onlyDoug Zongker2013-07-111-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | O_DIRECT writes fail with EINVAL due to alignment issues. Change-Id: If8cf38a636313e4f4b4e61e66287dc903c473e5b
* | | | am 660637f3: am e8d953aa: recovery: more cargo-cult programmingDoug Zongker2013-07-111-2/+2
|\ \ \ \ | |/ / / | | | | | | | | | | | | * commit '660637f3fc6fe20e8b7f47b98152138c2c92b7ec': recovery: more cargo-cult programming
| * | | am e8d953aa: recovery: more cargo-cult programmingDoug Zongker2013-07-111-2/+2
| |\ \ \ | | |/ / | | | | | | | | | | | | * commit 'e8d953aa7ed0c16beb1b03a05d16cb23dd85e198': recovery: more cargo-cult programming
| | * | recovery: more cargo-cult programmingDoug Zongker2013-07-111-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Add O_DIRECT|O_SYNC when opening partitions for write. Change-Id: I9825ad8e60fba87e482f8abc5593d6f54a1e3a1c
* | | | am 51ffaf54: (-s ours) Reconcile with jb-mr2-release - do not mergeThe Android Open Source Project2013-07-110-0/+0
|\ \ \ \ | |/ / / | | | | | | | | | | | | * commit '51ffaf54a56441bba053d37a00122761c3a18f16': recovery: sleep after writing partition and closing it
| * | | Reconcile with jb-mr2-release - do not mergeThe Android Open Source Project2013-07-110-0/+0
| |\ \ \ | | | | | | | | | | | | | | | Change-Id: Id35004f465f5152c1de0796eb66989f234185208
| | * | | recovery: sleep after writing partition and closing itDoug Zongker2013-07-101-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Another speculative attempt to get everything we write actually stored to the device. Change-Id: Icf40b0741b4c535e55ea34848073a97d90dc0e70
* | | | | am fbcfad33: am bf4a69ac: recovery: sleep after writing partition and closing itDoug Zongker2013-07-111-2/+7
|\ \ \ \ \ | |/ / / / | | | | | | | | | | | | | | | * commit 'fbcfad33face5d3b9e6b8cb04379168bceb517df': recovery: sleep after writing partition and closing it
| * | | | am bf4a69ac: recovery: sleep after writing partition and closing itDoug Zongker2013-07-101-2/+7
| |\ \ \ \ | | | |/ / | | |/| | | | | | | | | | | | * commit 'bf4a69ac41696fe78f6cc67b10cf1816186f1c5d': recovery: sleep after writing partition and closing it
| | * | | recovery: sleep after writing partition and closing itDoug Zongker2013-07-101-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Another speculative attempt to get everything we write actually stored to the device. Change-Id: Icf40b0741b4c535e55ea34848073a97d90dc0e70
* | | | | am e352c88f: (-s ours) Reconcile with jb-mr2-release - do not mergeThe Android Open Source Project2013-07-110-0/+0
|\ \ \ \ \ | |/ / / / | | | | | | | | | | | | | | | | | | | | * commit 'e352c88fbcfd917f6614597364d2e550aa691e79': recovery: write partitions more conservatively recovery: try to write EMMC partitions more reliably
| * | | | Reconcile with jb-mr2-release - do not mergeThe Android Open Source Project2013-07-090-0/+0
| |\ \ \ \ | | | |/ / | | |/| | | | | | | Change-Id: Ib99b7cd6aede63006c91be2635112e16dd0f2b24
| | * | | recovery: write partitions more conservativelyDoug Zongker2013-07-091-24/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Write and verify partitions using write(2) and read(2) rather than the stdio functions. Read and write in 4kb blocks. When writing, fsync() every 1MB. Bug: 9602014 Change-Id: Ie98ce38e857786fc0f4ebf36bb5ffc93b41bc96f
| | * | | recovery: try to write EMMC partitions more reliablyDoug Zongker2013-07-092-7/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Nexus 4 has flash errors that manifest during large writes (eg, of the radio partition). Writes of some blocks seem to be dropped silently, without any errors being returned to the user level. Make two changes to the partition-writing code: - break it up into 1MB writes instead of writing partitions with a single fwrite() call. Pause for 50ms in between every chunk. - read the partition back after writing and verify that we read what we wrote. Drop caches before reading so we (hopefully) are reading off the actual flash and not some cache. Neither of these should be necessary. Bug: 9602014 Change-Id: Ice2e24dd4c11f1a57968277b5eb1468c772f6f63