summaryrefslogtreecommitdiffstats
path: root/firmware.c
diff options
context:
space:
mode:
authorDoug Zongker <dougz@android.com>2010-01-21 01:34:10 +0100
committerDoug Zongker <dougz@android.com>2010-01-21 21:50:04 +0100
commit687bc12ccfbda26ad134b27d09d1d70a2b8705a6 (patch)
tree83d313c1cb3e9a3a6795faeceb832cfd1f423870 /firmware.c
parentam 4e9332cb: am 22d79a5c: make offsets in firmware update header not point to bad blocks (diff)
downloadandroid_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.tar
android_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.tar.gz
android_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.tar.bz2
android_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.tar.lz
android_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.tar.xz
android_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.tar.zst
android_bootable_recovery-687bc12ccfbda26ad134b27d09d1d70a2b8705a6.zip
Diffstat (limited to 'firmware.c')
-rw-r--r--firmware.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/firmware.c b/firmware.c
index e2e4fe630..6739c1e93 100644
--- a/firmware.c
+++ b/firmware.c
@@ -76,7 +76,8 @@ int firmware_update_pending() {
* It is recovery's responsibility to clean up the mess afterwards.
*/
-int maybe_install_firmware_update(const char *send_intent) {
+int maybe_install_firmware_update(const char *send_intent,
+ const char *log_filename) {
if (update_data == NULL || update_length == 0) return 0;
/* We destroy the cache partition to pass the update image to the
@@ -104,7 +105,7 @@ int maybe_install_firmware_update(const char *send_intent) {
ui_print("Writing %s image...\n", update_type);
if (write_update_for_bootloader(
update_data, update_length,
- width, height, bpp, busy_image, fail_image)) {
+ width, height, bpp, busy_image, fail_image, log_filename)) {
LOGE("Can't write %s image\n(%s)\n", update_type, strerror(errno));
format_root_device("CACHE:"); // Attempt to clean cache up, at least.
return -1;
@@ -118,6 +119,7 @@ int maybe_install_firmware_update(const char *send_intent) {
* wipe the cache and reboot into the system.)
*/
snprintf(boot.command, sizeof(boot.command), "update-%s", update_type);
+ strlcat(boot.recovery, "--recover_log\n", sizeof(boot.recovery));
if (set_bootloader_message(&boot)) {
format_root_device("CACHE:");
return -1;