Commit Graph

8294 Commits

Author SHA1 Message Date
George Burgess IV 37395747a8 Merge "bootable: leak less memory"
am: 19073f2067

Change-Id: I55463429524f54941b47fce9f0c318ae47993414
2019-10-23 17:22:00 -07:00
Treehugger Robot 19073f2067 Merge "bootable: leak less memory" 2019-10-24 00:03:38 +00:00
George Burgess IV 1b03fc5493 bootable: leak less memory
`misc_device_` is a std::string, so it allocates and manages its own
memory. Hence, the strdup here is immediately leaked.

Caught by the static analyzer

Bug: None
Test: TreeHugger
Change-Id: Iffb1ff60f6087e470a0979d202150567272e8b1c
2019-10-23 12:09:07 -07:00
Xin Li a5d835720a Skip QD1A.190821.011 in stage-aosp-master
Bug: 141248619
Change-Id: I3404ae5bfb5c54df05495a62cba58cd4e818b2ff
2019-10-16 15:19:11 -07:00
Nick Desaulniers 843c0bbb01 Merge "[bootable][recovery] fix -Wreorder-init-list"
am: 0d76cad830

Change-Id: Ifd6c41936ad73a55b70c037fbc21bc12f6277a58
2019-10-11 09:22:05 -07:00
Nick Desaulniers 0d76cad830 Merge "[bootable][recovery] fix -Wreorder-init-list" 2019-10-11 15:50:07 +00:00
Nick Desaulniers 1cb510d96f [bootable][recovery] fix -Wreorder-init-list
C++20 will require members in a designated initializer to be in order
unlike C99.

Bug: 139945549
Test: mm
Change-Id: I6f8d658448f7e5dd980bf95b890b15cb0aab7407
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
2019-10-10 16:33:58 -07:00
David Anderson 1cde53c252 Merge "Add IBootControl 1.1 support to libboot_control."
am: 47bb0c8b59

Change-Id: I64763d0d67ad37686bc95c0c6e0f986b9a707267
2019-10-10 12:31:35 -07:00
David Anderson 47bb0c8b59 Merge "Add IBootControl 1.1 support to libboot_control." 2019-10-10 19:19:49 +00:00
Tao Bao 03a5bd4d0d Merge "Update OWNERS."
am: 938e736f91

Change-Id: I905db1a8c1a46b8ca00a3aef10fdae4487562d6b
2019-10-09 08:52:01 -07:00
Tao Bao 938e736f91 Merge "Update OWNERS." 2019-10-09 15:33:13 +00:00
Tao Bao 7d47aebd79 Update OWNERS.
Test: N/A
Change-Id: I290fe43ee14fa3751f9ddb2c009bff235d8e1cff
2019-10-08 20:32:42 -07:00
Tianjie Xu 0b89939ddf Merge "Run BORINGSSL_self_test() in updater_main"
am: 8316f2f09a

Change-Id: I7ba12a5cfde83239310ab76f6f7fef722b20366a
2019-10-07 16:08:48 -07:00
Tianjie Xu 8316f2f09a Merge "Run BORINGSSL_self_test() in updater_main" 2019-10-07 22:51:44 +00:00
Tao Bao 58b5a5a550 Merge "minadbd: Return battery level via getprop."
am: e0e34a7f5c

Change-Id: Ib714d7add905ac1b2084f4144a2017a01a21fd2f
2019-10-07 08:37:00 -07:00
Tao Bao e0e34a7f5c Merge "minadbd: Return battery level via getprop." 2019-10-07 15:17:40 +00:00
Tianjie Xu 97692467a1 Run BORINGSSL_self_test() in updater_main
We need to run the these tests when starting updater to verify the
statically linked libcrypto. The test function is based on the known
answer tests, and it doesn't compute the hash of the libcrypto library.

Bug: 141003171
Test: unit tests pass, run a updater on cuttlefish
Change-Id: I897918a54bca76ea0c928102e7287df27505e1cc
2019-10-05 17:06:48 -07:00
Bill Peckham 1bf401d03f Merge "Moving recovery resources from /system to /vendor"
am: 3903b26368

Change-Id: I477c2cbe802fff389a8e333ea693859d9a21a63e
2019-10-04 20:24:15 -07:00
Bill Peckham 3903b26368 Merge "Moving recovery resources from /system to /vendor" 2019-10-05 03:14:12 +00:00
Tao Bao b548bea778 minadbd: Return battery level via getprop.
`adb rescue getprop rescue.battery_level` returns the current battery
level.

Bug: 134560109
Test: Build and boot into rescue mode.
Test: `adb rescue getprop ro.build.fingerprint`
Test: `adb rescue getprop rescue.battery_level`
Test: `adb rescue getprop` to dump all the properties.
Test: Run recovery_unit_test.
Change-Id: I78a9e8ab9783ffc8532cb93e6a64fb2157c19bd5
2019-10-04 15:33:27 -07:00
Tao Bao 7018c5b2d8 Merge "recovery_utils: Use libvoid_headers."
am: 4782e79324

Change-Id: I4b1527c70eeaaea0cbf10702272b5cf8f5284714
2019-10-03 17:16:36 -07:00
Bill Peckham 341644d657 Moving recovery resources from /system to /vendor
This change is part of a topic that moves the recovery resources from the
system partition to the vendor partition, if it exists, or the vendor directory
on the system partition otherwise. The recovery resources are moving from the
system image to the vendor partition so that a single system image may be used
with either an A/B or a non-A/B vendor image. The topic removes a delta in the
system image that prevented such reuse in the past.

The recovery resources that are moving are involved with updating the recovery
partition after an update. In a non-A/B configuration, the system boots from
the recovery partition, updates the other partitions (system, vendor, etc.)
Then, the next time the system boots normally, a script updates the recovery
partition (if necessary). This script, the executables it invokes, and the data
files that it uses were previously on the system partition. The resources that
are moving include the following.

* install-recovery.sh
* applypatch
* recovery-resource.dat (if present)
* recovery-from-boot.p (if present)

This makes the applypatch executable a vendor module.

This change supports making dependencies of the applypatch executable available
to applypatch, which is now on vendor.

Since install-recovery.sh is now a vendor service, we add the
applypatch/vendor_flash_recovery.rc file to /vendor/etc/init to start the
service.

Bug: 68319577
Test: Ensure that recovery partition is updated correctly.
Change-Id: I01c0800ee6078aa6c9d716d5f154ad2d63c7af84
2019-10-04 00:04:56 +00:00
Treehugger Robot 4782e79324 Merge "recovery_utils: Use libvoid_headers." 2019-10-04 00:01:53 +00:00
Tao Bao 80b6831ddb Merge "Refactor battery info querying functions into librecovery_utils."
am: 678d6395b3

Change-Id: I566ad1bb6dd940e6fcd224c8d6cbed234d1ca3bc
2019-10-03 09:07:38 -07:00
Tao Bao 640175e9d1 recovery_utils: Use libvoid_headers.
Test: mmm bootable/recovery
Change-Id: I2ad7620d0f967cb018a415358379c34804e232c5
2019-10-03 08:48:49 -07:00
Tao Bao 678d6395b3 Merge "Refactor battery info querying functions into librecovery_utils." 2019-10-03 15:40:23 +00:00
Tao Bao 832c9cd24f Refactor battery info querying functions into librecovery_utils.
Bug: 134560109
Test: Run recovery_unit_test.
Change-Id: Ibbcdcfd507fa23657ee7ff677208b0003ec382ba
2019-10-02 22:04:25 -07:00
Tao Bao dc717a5c2b Merge "otautil: Factor out the utils that're private to recovery."
am: c6fb9f9df5

Change-Id: Ib1f978bb79f317d64bfa053ed34cecaf97353ba9
2019-10-02 14:24:27 -07:00
Tao Bao c6fb9f9df5 Merge "otautil: Factor out the utils that're private to recovery." 2019-10-02 21:00:08 +00:00
Tao Bao e3f09a72f5 otautil: Factor out the utils that're private to recovery.
A number of utility functions are intended for serving recovery's own
use. Exposing them via libotautil (which is a static lib) would pass the
dependencies onto libotautil's users (e.g. recovery image, updater, host
simulator, device-specific recovery UI/updater extensions etc). This CL
finds a new home for the utils that are private to recovery.

Test: mmma bootable/recovery
Change-Id: I575e97ad099b85fe1c1c8c7c9458a5a43d4e11e1
2019-10-02 10:56:46 -07:00
Tao Bao 7f9eb2e012 Merge "otautil: Drop a few unneeded includes."
am: 36f72131ff

Change-Id: I7c358332c176fbc425490fd416f70ef35ac02cdb
2019-10-01 19:16:00 -07:00
Treehugger Robot 36f72131ff Merge "otautil: Drop a few unneeded includes." 2019-10-02 02:00:52 +00:00
Tao Bao f6ed376b20 otautil: Drop a few unneeded includes.
Test: mmma bootable/recovery
Change-Id: I6ed8f9eca7183f84537c770baaffddd22b6e9f28
2019-10-01 16:00:17 -07:00
Tao Bao 48fb5e27a1 Merge changes I6c35d2e4,If16c3e19
am: c3f32b95e5

Change-Id: I2d0f9cbe2ec6d3a1429c0c01204bb41ff7e7cb13
2019-10-01 14:40:41 -07:00
Tao Bao c3f32b95e5 Merge changes I6c35d2e4,If16c3e19
* changes:
  Move mounts.cpp from libotautil into libupdater.
  otautil: roots.cpp no longer needs 'mounts.h'.
2019-10-01 21:18:42 +00:00
Tao Bao d628cfc153 Move mounts.cpp from libotautil into libupdater.
All the active users of mounts.h now live in updater/.

Test: mmma bootable/recovery
Test: Run recovery_unit_test on taimen.
Test: Code search shows no reference to otautil/mounts.h in device dirs.
Change-Id: I6c35d2e403e92a0111102d00aa4773f4f524650e
2019-10-01 12:13:04 -07:00
Tao Bao 331e5c4c98 otautil: roots.cpp no longer needs 'mounts.h'.
Commit 0f339e27bb moved part of the mounts
implementation into libfs_mgr. As a result, otautil/roots.cpp no longer
depends on anything in the local otautil/mounts.h.

Test: mmma bootable/recovery
Change-Id: If16c3e19a62933358fb0002a10e8556a99f9d29a
2019-10-01 12:02:56 -07:00
Steven Moreland 3746d95338 Merge "Remove libhidltransport deps"
am: e2ca8ba293

Change-Id: Ia3ea9dfe765659d34f44a3486ade41b06be6f7f0
2019-09-30 09:15:58 -07:00
Steven Moreland e2ca8ba293 Merge "Remove libhidltransport deps" 2019-09-30 15:56:03 +00:00
Tao Bao 79d93f9eee Merge "minadbd: Update README.md."
am: ec734e5851

Change-Id: I133418ea66cce3fdb70c3baba7fa8d6b68beb740
2019-09-27 17:23:45 -07:00
Tao Bao ec734e5851 Merge "minadbd: Update README.md." 2019-09-27 23:47:06 +00:00
Tao Bao 0cc2c5b453 minadbd: Update README.md.
Test: N/A
Change-Id: I7f4648f2b357de7d9700e38552a0156d13c1bd0b
2019-09-27 13:17:16 -07:00
Tao Bao 74c405d87f Merge "minadbd: Export minadbd/types.h to libinstall."
am: ffa9ffbd2b

Change-Id: I18571b1a696b02cab050b570bf36878e25a27462
2019-09-26 16:13:36 -07:00
Tao Bao ffa9ffbd2b Merge "minadbd: Export minadbd/types.h to libinstall." 2019-09-26 22:46:14 +00:00
Colin Cross 617d01a9c1 Merge "Use libcrypto_static instead of libcrypto"
am: 4c4c7dc26b

Change-Id: Ia77cc9f13f4807fd2276b332599a1b489cf4a9a6
2019-09-26 07:41:39 -07:00
Colin Cross 4c4c7dc26b Merge "Use libcrypto_static instead of libcrypto" 2019-09-26 14:32:33 +00:00
Tao Bao 3305d48b0b minadbd: Export minadbd/types.h to libinstall.
Test: mmma bootable/recovery
Change-Id: I503e942b23cc51024aa752c1eb3db5455a44a9d1
2019-09-26 00:04:11 -07:00
Steven Moreland ff9b62b781 Remove libhidltransport deps
Since this was combined into libhidlbase.

Bug: 135686713
Test: build only (libhidltransport is empty)
Change-Id: I253e50726967044714275ab995fb8a8a57bcde36
2019-09-25 15:12:30 -07:00
Bill Yi 92214baec2 Import translations. DO NOT MERGE
Change-Id: I18c2199dc9439d6013329d1f0eb40dd106618bfb
Auto-generated-cl: translation import
2019-09-24 14:36:40 -07:00
Tao Bao 164f4759a2 Merge "applypatch: Add backup_source parameter to PatchPartition."
am: 86b54dc493

Change-Id: I0776b40d710ba577667aaba055ed6555eb9fbefc
2019-09-23 16:23:57 -07:00