Commit graph

2095 commits

Author SHA1 Message Date
Tao Bao
8162eca526 update_verifier: Log to logd instead of kernel log.
am: 45eac58ef1

* commit '45eac58ef188679f6df2d80efc0391c6d7904cd8':
  update_verifier: Log to logd instead of kernel log.
2015-12-07 17:53:41 -08:00
Tao Bao
45eac58ef1 update_verifier: Log to logd instead of kernel log.
logd already gets started before we call update_verifier.

Bug: 26039641
Change-Id: If00669a77bf9a6e5534e33f4e50b42eabba2667a
2015-12-07 17:23:49 -08:00
Tao Bao
6bc2155d22 Add update_verifier for A/B OTA update.
am: 1171d3a12b

* commit '1171d3a12b13ca3f1d4301985cf068076e55ae26':
  Add update_verifier for A/B OTA update.
2015-12-08 00:22:07 +00:00
Tao Bao
1171d3a12b Add update_verifier for A/B OTA update.
update_verifier checks the integrity of the updated system and vendor
partitions on the first boot post an A/B OTA update. It marks the
current slot as having booted successfully if it passes the verification.

This CL doesn't perform any actual verification work which will be
addressed in follow-up CLs.

Bug: 26039641
Change-Id: Ia5504ed25b799b48b5886c2fc68073a360127f42
2015-12-07 10:25:02 -08:00
Tao Bao
baad2d454d updater: Replace strtok() with android::base::Split().
Change-Id: I36346fa199a3261da1ae1bc310b3557fe1716d96
2015-12-06 16:56:27 -08:00
Elliott Hughes
22d89ecb8a Merge "Track rename from base/ to android-base/." am: 06ca938ce2
am: ff4c2c07e8

* commit 'ff4c2c07e899ab049c7499f2818cd8a45e0213d3':
  Track rename from base/ to android-base/.
2015-12-05 00:55:43 +00:00
Tao Bao
da21859d3d Merge "Remove the building rules for applypatch_static." am: fc23a50cef
am: 0eded2ae7f

* commit '0eded2ae7f38aef9ffaff4f41081851aafebb073':
  Remove the building rules for applypatch_static.
2015-12-05 00:53:42 +00:00
Elliott Hughes
ff4c2c07e8 Merge "Track rename from base/ to android-base/."
am: 06ca938ce2

* commit '06ca938ce22681455bf75f0b6282b776814df30e':
  Track rename from base/ to android-base/.
2015-12-04 23:43:39 +00:00
Elliott Hughes
06ca938ce2 Merge "Track rename from base/ to android-base/." 2015-12-04 23:33:59 +00:00
Elliott Hughes
4b166f0e69 Track rename from base/ to android-base/.
Change-Id: I354a8c424d340a9abe21fd716a4ee0d3b177d86f
2015-12-04 15:30:20 -08:00
Tao Bao
0eded2ae7f Merge "Remove the building rules for applypatch_static."
am: fc23a50cef

* commit 'fc23a50cef6347651b2d25facd53cf6d50cfae67':
  Remove the building rules for applypatch_static.
2015-12-02 23:09:11 +00:00
Tao Bao
fc23a50cef Merge "Remove the building rules for applypatch_static." 2015-12-02 22:54:52 +00:00
Tao Bao
f2448d0cd5 Remove the building rules for applypatch_static.
The CL in [1] has stopped building and packaging the obsolete
applypatch_static tool.

[1]: commit a04fca31bf1fadcdf982090c942ccbe4d9b95c71

Bug: 24621915
Change-Id: I5e98951ad7ea5c2a7b351af732fd6722763f59bd
2015-12-02 14:05:38 -08:00
Elliott Hughes
8a4b7e5df1 Merge "Track name change from adb_main to adb_server_main." am: ee5c87eea7
am: cca6ca0953

* commit 'cca6ca0953b56176ebb406fa89766e326f4d72ac':
  Track name change from adb_main to adb_server_main.
2015-11-20 21:16:39 +00:00
Elliott Hughes
cca6ca0953 Merge "Track name change from adb_main to adb_server_main."
am: ee5c87eea7

* commit 'ee5c87eea737e47ab38e19625a32ac2fc0057ddd':
  Track name change from adb_main to adb_server_main.
2015-11-20 21:14:27 +00:00
Elliott Hughes
ee5c87eea7 Merge "Track name change from adb_main to adb_server_main." 2015-11-20 21:06:51 +00:00
Elliott Hughes
9f4fdb3def Track name change from adb_main to adb_server_main.
Change-Id: I835805348a9817c81639ad8471e3b49cae93c107
2015-11-20 13:03:24 -08:00
David Zeuthen
897fa0779f Add slot_suffix field to struct bootloader_message. am: 846c094fee
am: 8f9a1575aa

* commit '8f9a1575aaafa9160c247be93eabe3c50933bdeb':
  Add slot_suffix field to struct bootloader_message.
2015-11-19 23:04:13 +00:00
Qiwen Zhao
348355ebe9 Merge commit \'8f90389966fabf532b24741d49245215279533e1\' into mnc-dr2-dev-plus-aosp
am: a550e6b412

* commit 'a550e6b4122108fa2db438afcfd7d40386b71b0b':
  recovery: Allow "Mount /system" for system_root_image.
2015-11-19 23:04:11 +00:00
Qiwen Zhao
6824e1d1b7 Merge commit \'32ac97675bade3681203c46d001f76b11a359fd5\' into mnc-dr2-dev-plus-aosp
am: 312f7c71f4

* commit '312f7c71f4a71feb0e8c3d202164ddeefa0ec661':
  applypatch: Fix the checking in WriteToPartition().
2015-11-19 23:04:08 +00:00
Qiwen Zhao
61ff9a511b Merge commit \'f47259b18492c921445d9e437a9f9ed11c52fac6\' into mnc-dr2-dev-plus-aosp
am: 681b3c9fd0

* commit '681b3c9fd0ecf378e054e0c039c6085844705a9c':
  applypatch: Support flash mode.
2015-11-19 23:04:05 +00:00
Qiwen Zhao
3364006cbe Merge commit \'3b199267d6d4c279cbef3286a74e16bf92dd8d8a\' into mnc-dr2-dev-plus-aosp
am: 06ec3bab56

* commit '06ec3bab56371fee051326cbd5f2b72a53462d29':
  updater: libapplypatch needs libbase now.
2015-11-19 23:04:02 +00:00
Qiwen Zhao
a259540f59 Merge commit \'27604fcbee0010b800bfc16b5bf7a48c365c2cf3\' into mnc-dr2-dev-plus-aosp
am: 8b254cfc3c

* commit '8b254cfc3ccb67953b62412b0a453f382907b841':
  applypatch: Refactor strtok().
2015-11-19 23:03:58 +00:00
David Zeuthen
8f9a1575aa Add slot_suffix field to struct bootloader_message.
am: 846c094fee

* commit '846c094fee9e50ed2b2e63dee17f5bafb2b9d1ce':
  Add slot_suffix field to struct bootloader_message.
2015-11-19 23:00:30 +00:00
Tao Bao
e8617cf83e DO NOT MERGE recovery: Switch applypatch/ and updater/ to cpp. am: 818fa781d1 -s ours
am: f4848f63ad  -s ours

* commit 'f4848f63ad6041fcc01ad1f520ccc0ceddd80f61':
  DO NOT MERGE recovery: Switch applypatch/ and updater/ to cpp.
2015-11-19 22:58:20 +00:00
Qiwen Zhao
a550e6b412 Merge commit '8f90389966fabf532b24741d49245215279533e1' into mnc-dr2-dev-plus-aosp 2015-11-19 14:56:59 -08:00
Qiwen Zhao
312f7c71f4 Merge commit '32ac97675bade3681203c46d001f76b11a359fd5' into mnc-dr2-dev-plus-aosp 2015-11-19 14:56:45 -08:00
Qiwen Zhao
681b3c9fd0 Merge commit 'f47259b18492c921445d9e437a9f9ed11c52fac6' into mnc-dr2-dev-plus-aosp 2015-11-19 14:56:28 -08:00
Qiwen Zhao
06ec3bab56 Merge commit '3b199267d6d4c279cbef3286a74e16bf92dd8d8a' into mnc-dr2-dev-plus-aosp 2015-11-19 14:56:14 -08:00
Qiwen Zhao
8b254cfc3c Merge commit '27604fcbee0010b800bfc16b5bf7a48c365c2cf3' into mnc-dr2-dev-plus-aosp 2015-11-19 14:56:00 -08:00
Tao Bao
f4848f63ad DO NOT MERGE recovery: Switch applypatch/ and updater/ to cpp.
am: 818fa781d1  -s ours

* commit '818fa781d1dbe35c0c5bfff3ebff1b45a2a676f0':
  DO NOT MERGE recovery: Switch applypatch/ and updater/ to cpp.
2015-11-19 22:53:47 +00:00
Sami Tolvanen
d32cfe9286 Add error and range checks to parse_range am: 806f72f9e6 -s ours
am: 81faa274d0

* commit '81faa274d0c3e36eb68b4a436695047949130d70':
  Add error and range checks to parse_range
2015-11-19 22:51:56 +00:00
Dan Albert
0ea84ea8e4 Stop using libstdc++. am: 56deefba73 -s ours
am: 34a265cbac

* commit '34a265cbacc3d365cca4aaa7edbe738ef3e904d6':
  Stop using libstdc++.
2015-11-19 22:51:52 +00:00
Sami Tolvanen
81faa274d0 Add error and range checks to parse_range
am: 806f72f9e6  -s ours

* commit '806f72f9e6ec0d15b550b79b0baa92a93fc646e3':
  Add error and range checks to parse_range
2015-11-19 22:47:41 +00:00
Dan Albert
34a265cbac Stop using libstdc++.
am: 56deefba73  -s ours

* commit '56deefba73fb318ba0498da49adc64de960a6e29':
  Stop using libstdc++.
2015-11-19 22:42:24 +00:00
Tao Bao
f4b871890b recovery: Switch to clang am: 7101b2e285 -s ours
am: 29cc06e50c

* commit '29cc06e50c3702e1835c1af911f5d2c69699e1c7':
  recovery: Switch to clang
2015-11-19 22:06:50 +00:00
Tao Bao
29cc06e50c recovery: Switch to clang
am: 7101b2e285  -s ours

* commit '7101b2e2854985727b7ef65e5b5057e0ecf2d034':
  recovery: Switch to clang
2015-11-19 21:59:07 +00:00
David Zeuthen
846c094fee Add slot_suffix field to struct bootloader_message.
This is needed by fs_mgr for certain A/B implementations.

Change-Id: I7bb404d61198eb7a962c2b693911f5156745daae
2015-11-16 14:28:40 -08:00
Tao Bao
8f90389966 recovery: Allow "Mount /system" for system_root_image.
When system images contain the root directory, there is no entry of
"/system" in the fstab. Change it to look for "/" instead if
ro.build.system_root_image is true. We actually mount the partition
to /system_root instead, and create a symlink to /system_root/system
for /system. This allows "adb shell" to work properly.

Bug: 22855115
Change-Id: I91864444950dc3229fda3cc133ddbadeb8817fb8
(cherry picked from commit abb8f7785e)
2015-11-16 14:28:40 -08:00
Tao Bao
32ac97675b applypatch: Fix the checking in WriteToPartition().
WriteToPartition() should consider a target name as valid if it contains
multiple colons. But only the first two fields will be used.

Bug: 22725128
Change-Id: I9d0236eaf97df9db9704acf53690d0ef85188e45
(cherry picked from commit 1ce7a2a63d)
2015-11-16 14:28:40 -08:00
Tao Bao
f47259b184 applypatch: Support flash mode.
We may carry a full copy of recovery image in the /system, and use
/system/bin/install-recovery.sh to install the recovery. This CL adds
support to flash the recovery partition with the given image.

Bug: 22641135
Change-Id: I345eaaee269f6443527f45a9be7e4ee47f6b2b39
(cherry picked from commit 68c5a67967)
2015-11-16 14:28:40 -08:00
Tao Bao
3b199267d6 updater: libapplypatch needs libbase now.
Change-Id: Ibe3173edd6274b61bd9ca5ec394d7f6b4a403639
(cherry picked from commit 1b1ea17d55)
2015-11-16 14:28:40 -08:00
Tao Bao
27604fcbee applypatch: Refactor strtok().
We have android::base::Split() for the work.

Change-Id: Ic529db42090f700e6455d465c8b84b7f52d34d63
(cherry picked from commit 0a47ce27de)
2015-11-16 14:28:40 -08:00
Tao Bao
818fa781d1 DO NOT MERGE recovery: Switch applypatch/ and updater/ to cpp.
Mostly trivial changes to make cpp compiler happy.

Change-Id: I69bd1d96fcccf506007f6144faf37e11cfba1270
(cherry picked from commit ba9a42aa7e)
2015-11-16 14:28:40 -08:00
Sami Tolvanen
806f72f9e6 Add error and range checks to parse_range
Only trusted input is passed to parse_range, but check for invalid
input to catch possible problems in transfer lists.

Bug: 21033983
Bug: 21034030
Bug: 21034172
Bug: 21034406
Change-Id: I1e266de3de15c99ee596ebdb034419fdfe7eba1f
(cherry picked from commit f2bac04e1b)
2015-11-16 14:28:40 -08:00
Dan Albert
56deefba73 Stop using libstdc++.
These are already getting libc++, so it isn't necessary. If any of the
other static libraries (such as adb) use new or delete from libc++,
there will be symbol collisions.

Change-Id: I55e43ec60006d3c2403122fa1174bde06f18e09f
(cherry picked from commit e49a9e527a)
2015-11-16 14:28:40 -08:00
Tao Bao
7101b2e285 recovery: Switch to clang
And a few trival fixes to suppress warnings.

Change-Id: Id28e3581aaca4bda59826afa80c0c1cdfb0442fc
(cherry picked from commit 80e46e08de)
2015-11-16 14:28:40 -08:00
Paul Lawrence
fd1bfa2a41 Merge "Create convert_fbe breadcrumb file to support conversion to FBE" 2015-11-13 17:25:09 +00:00
Elliott Hughes
11c26abe2d Merge "We can use fclose directly in std::unique_ptr."
am: 5c6912148b

* commit '5c6912148b2143cbdf4cc580c723fac05e9324f8':
  We can use fclose directly in std::unique_ptr.
2015-11-13 16:37:44 +00:00
Elliott Hughes
5c6912148b Merge "We can use fclose directly in std::unique_ptr." 2015-11-13 16:27:55 +00:00