Commit Graph

1994 Commits

Author SHA1 Message Date
Ying Wang fcf142be17 Merge "Rename .l/.y to .ll/.yy" am: ab9db5284e
am: f607e5a0bc

* commit 'f607e5a0bc1c1481331dc32ac203fc66770dec71':
  Rename .l/.y to .ll/.yy
2016-01-13 18:45:22 +00:00
Ying Wang c577660702 Rename .l/.y to .ll/.yy
Now to generate .cpp you need to use .ll/.yy.

Bug: 26492989
Change-Id: Ib078e03b3b0758f7a62595c343e52ae856bcb33f
2016-01-12 21:09:10 -08:00
Ying Wang f607e5a0bc Merge "Rename .l/.y to .ll/.yy"
am: ab9db5284e

* commit 'ab9db5284ec6113c7d84f70f805dca21c3e6efd7':
  Rename .l/.y to .ll/.yy
2016-01-12 18:57:20 +00:00
Ying Wang ab9db5284e Merge "Rename .l/.y to .ll/.yy" 2016-01-12 17:35:33 +00:00
Ying Wang c8abc4ec45 Rename .l/.y to .ll/.yy
Now to generate .cpp you need to use .ll/.yy.

Bug: 26492989
Change-Id: Ib078e03b3b0758f7a62595c343e52ae856bcb33f
2016-01-11 18:14:17 -08:00
Jed Estep b1cc5d8434 Merge "IO fault injection for OTA packages" 2016-01-08 23:28:32 +00:00
Tianjie Xu cb93b61578 Merge "updater: Add a function to check first block" am: 6f8b9b60db
am: a3c89623e7

* commit 'a3c89623e765a7d91d781cbd83dd8e50c6c865c9':
  updater: Add a function to check first block
2016-01-08 00:30:45 +00:00
Tianjie Xu a3c89623e7 Merge "updater: Add a function to check first block"
am: 6f8b9b60db

* commit '6f8b9b60dbf2d73e0ee6e757d565035f017e1ccd':
  updater: Add a function to check first block
2016-01-08 00:28:42 +00:00
Tianjie Xu 6f8b9b60db Merge "updater: Add a function to check first block" 2016-01-08 00:23:50 +00:00
Tianjie Xu 57bed6d8c9 updater: Add a function to check first block
Add and register a function to check if the device has been remounted
since last update during incremental OTA. This function reads block 0
and executes before partition recovery for version >= 4.

Bug: 21124327
Change-Id: I8b915b9f1d4736b3609daa9d16bd123225be357f
(cherry picked from commit 30bf476559)
2016-01-07 11:19:48 -08:00
Tianjie Xu c94a4f5371 Merge "updater: Add a function to check first block" 2016-01-07 01:33:13 +00:00
Jed Estep f1fc48c6e6 IO fault injection for OTA packages
Bug: 25951086
Change-Id: I31c74c735eb7a975b7f41fe2b2eff042e5699c0c
2016-01-06 12:23:42 -08:00
David Riley 085fc1361f Merge "imgdiff: skip spurious gzip headers in image files" am: 8e150a5b24
am: c1de9837e3

* commit 'c1de9837e3bdb64bc1f5d9779df7a944326f5f2b':
  imgdiff: skip spurious gzip headers in image files
2016-01-04 18:07:54 +00:00
David Riley c1de9837e3 Merge "imgdiff: skip spurious gzip headers in image files"
am: 8e150a5b24

* commit '8e150a5b240833ddf54cbc572cea30ab18e06d86':
  imgdiff: skip spurious gzip headers in image files
2016-01-04 18:05:34 +00:00
David Riley 8e150a5b24 Merge "imgdiff: skip spurious gzip headers in image files" 2016-01-04 18:02:04 +00:00
David Riley 0779fc9814 imgdiff: skip spurious gzip headers in image files
dragon kernel is compressed via lz4 for boot speed and bootloader
support reasons and recent prebuilts happen to include the gzip header
sequence which is causing imgdiff to fail.

Detect a spurious gzip header and treat the section as a normal section.

Bug: 26133184
Change-Id: I369d7d576fd7d2c579c0780fc5c669a5b6ea0d3d
(cherry picked from commit 0f2f6a746af517afca9e5e089a4a17be0a9766d6)
Signed-off-by: David Riley <davidriley@google.com>
2015-12-23 09:43:59 -08:00
Tao Bao 2538b952b8 Merge "res: Embed FPS into icon_installing.png." am: 29b0fbe160
am: ef911716b0

* commit 'ef911716b04a773bcba1e693638cfd9cbb9e4ddc':
  res: Embed FPS into icon_installing.png.
2015-12-18 22:32:36 +00:00
Tao Bao ef911716b0 Merge "res: Embed FPS into icon_installing.png."
am: 29b0fbe160

* commit '29b0fbe160f815a142fa0d056c1ce10186cea516':
  res: Embed FPS into icon_installing.png.
2015-12-18 22:30:28 +00:00
Tao Bao 29b0fbe160 Merge "res: Embed FPS into icon_installing.png." 2015-12-18 22:20:20 +00:00
Tianjie Xu 30bf476559 updater: Add a function to check first block
Add and register a function to check if the device has been remounted
since last update during incremental OTA. This function reads block 0
and executes before partition recovery for version >= 4.

Bug: 21124327
Change-Id: I8b915b9f1d4736b3609daa9d16bd123225be357f
2015-12-18 13:35:35 -08:00
Tao Bao b723f4f38f res: Embed FPS into icon_installing.png.
We allow vendor-specific icon installing image but have defined private
animation_fps that can't be overridden. This CL changes the image
generator to optionally embed FPS (otherwise use the default value of
20) into the generated image.

For wear devices, they are using individual images instead of the
interlaced one. Change the animation_fps from private to protected so
that it can be customized.

Bug: 26009230
Change-Id: I9fbf64ec717029d4c54f72316f6cb079e8dbfb5e
2015-12-16 11:35:52 -08:00
Tao Bao afd85ecad2 Merge "updater: Use O_SYNC and fsync() for package_extract_file()." am: 4e72d1a81e
am: 125a6349b9

* commit '125a6349b9b390bd531690099939aaaf8a7513a8':
  updater: Use O_SYNC and fsync() for package_extract_file().
2015-12-15 18:32:33 +00:00
Tao Bao 125a6349b9 Merge "updater: Use O_SYNC and fsync() for package_extract_file()."
am: 4e72d1a81e

* commit '4e72d1a81e2194caf101dc8633858efaa9bdb39b':
  updater: Use O_SYNC and fsync() for package_extract_file().
2015-12-15 18:23:53 +00:00
Tao Bao 4e72d1a81e Merge "updater: Use O_SYNC and fsync() for package_extract_file()." 2015-12-15 17:55:05 +00:00
Tao Bao d3cac34430 updater: Use O_SYNC and fsync() for package_extract_file().
We are already using O_SYNC and fsync() for the recursive case
(package_extract_dir()). Make it consistent for the single-file case.

Bug: 20625549
Change-Id: I487736fe5a0647dd4a2428845e76bf642e0f0dff
2015-12-14 17:13:34 -08:00
Tao Bao 3af5e554af Merge "update_verifier: Track the API change for isSlotBootable()." am: e062645efa
am: 1a76924301

* commit '1a7692430123ec4af3acc01c4d08f738efc12513':
  update_verifier: Track the API change for isSlotBootable().
2015-12-10 21:02:56 -08:00
Tao Bao 5ac61d7a9e Merge "uncrypt: Suppress the compiler warnings on LP64." am: ca18526760
am: 8fa5f006c1

* commit '8fa5f006c190c1f4a9e48cfbf4112ca15459cbb1':
  uncrypt: Suppress the compiler warnings on LP64.
2015-12-10 21:02:52 -08:00
Tianjie Xu 9c4fbbcde7 Merge "updater: Output msg when recovery is called" am: 32f6298742
am: 3e67970c2c

* commit '3e67970c2cbbed221f8c33fafa6b2f44a50cacb3':
  updater: Output msg when recovery is called
2015-12-10 21:02:47 -08:00
Tao Bao 1a76924301 Merge "update_verifier: Track the API change for isSlotBootable()."
am: e062645efa

* commit 'e062645efa77ce3ab9ab802daee9e36b58e67bc4':
  update_verifier: Track the API change for isSlotBootable().
2015-12-10 21:00:17 -08:00
Tao Bao e062645efa Merge "update_verifier: Track the API change for isSlotBootable()." 2015-12-11 04:53:48 +00:00
Tao Bao 8fa5f006c1 Merge "uncrypt: Suppress the compiler warnings on LP64."
am: ca18526760

* commit 'ca185267607fff06b4d70c7bdbb23152f64d4582':
  uncrypt: Suppress the compiler warnings on LP64.
2015-12-10 16:50:03 -08:00
Tao Bao ca18526760 Merge "uncrypt: Suppress the compiler warnings on LP64." 2015-12-11 00:43:18 +00:00
Tianjie Xu 3e67970c2c Merge "updater: Output msg when recovery is called"
am: 32f6298742

* commit '32f6298742d5072c4b0d9f1cd09e0d0ae44cb972':
  updater: Output msg when recovery is called
2015-12-10 16:32:26 -08:00
Tianjie Xu 32f6298742 Merge "updater: Output msg when recovery is called" 2015-12-11 00:23:45 +00:00
Tianjie Xu 3b010bc393 updater: Output msg when recovery is called
Output messages in log when recovery is attempted or succeeded during
incremental OTA update.

Change-Id: I4033df7ae3aaecbc61921d5337eda26f79164fda
(cherry picked from commit b686ba2114)
2015-12-10 16:20:48 -08:00
Tianjie Xu 72c87cc88f Merge "updater: Output msg when recovery is called" 2015-12-11 00:12:30 +00:00
Tianjie Xu b686ba2114 updater: Output msg when recovery is called
Output messages in log when recovery is attempted or succeeded during
incremental OTA update.

Change-Id: I4033df7ae3aaecbc61921d5337eda26f79164fda
2015-12-10 11:12:29 -08:00
Tao Bao 612161ef1c update_verifier: Track the API change for isSlotBootable().
[1] added a new API isSlotMarkedSuccessful() to actually query if a
given slot has been marked as successful.

[1]: commit 72c88c915d957bf2eba73950e7f0407b220d1ef4

Change-Id: I9155c9b9233882a295a9a6e607a844d9125e4c56
2015-12-09 14:41:40 -08:00
Tao Bao b8df5fb90e uncrypt: Suppress the compiler warnings on LP64.
We have the following warnings when compiling uncrypt on LP64 (e.g.
aosp_angler-userdebug).

bootable/recovery/uncrypt/uncrypt.cpp:77:53: warning: format specifies type 'long long' but the argument has type 'off64_t' (aka 'long') [-Wformat]
        ALOGE("error seeking to offset %lld: %s\n", offset, strerror(errno));
                                       ~~~~         ^~~~~~
                                       %ld
bootable/recovery/uncrypt/uncrypt.cpp:84:54: warning: format specifies type 'long long' but the argument has type 'unsigned long' [-Wformat]
            ALOGE("error writing offset %lld: %s\n", (offset + written), strerror(errno));
                                        ~~~~         ^~~~~~~~~~~~~~~~~~
                                        %lu
bootable/recovery/uncrypt/uncrypt.cpp:246:16: warning: comparison of integers of different signs: 'size_t' (aka 'unsigned long') and 'off_t' (aka 'long') [-Wsign-compare]
    while (pos < sb.st_size) {
           ~~~ ^ ~~~~~~~~~~

According to POSIX spec [1], we have:
  off_t and blksize_t shall be signed integer types;
  size_t shall be an unsigned integer type;
  blksize_t and size_t are no greater than the width of type long.

And on Android, we always have a 64-bit st_size from stat(2)
(//bionic/libc/include/sys/stat.h).

Fix the type and add necessary casts to suppress the warnings.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_types.h.html

Change-Id: I5d64d5b7919c541441176c364752de047f9ecb20
2015-12-09 10:45:39 -08:00
Tao Bao 78837c285a Merge changes If00669a7,Ia5504ed2 am: ddde4676b6
am: 50b7cfa5d7

* commit '50b7cfa5d7d9bdd1607c6c4276c63efa9e51e341':
  update_verifier: Log to logd instead of kernel log.
  Add update_verifier for A/B OTA update.
2015-12-08 19:36:55 +00:00
Tao Bao 50b7cfa5d7 Merge changes If00669a7,Ia5504ed2
am: ddde4676b6

* commit 'ddde4676b6c0e175699115a67e44f09a665439b5':
  update_verifier: Log to logd instead of kernel log.
  Add update_verifier for A/B OTA update.
2015-12-08 19:33:10 +00:00
Tao Bao 8594fabc36 Merge "updater: Replace strtok() with android::base::Split()." am: d0acbb56ed
am: 26edcd8f5a

* commit '26edcd8f5a60ad80e98d8d289aa0130ba199c2a4':
  updater: Replace strtok() with android::base::Split().
2015-12-08 11:29:34 -08:00
Tao Bao 8ff5c46ce8 update_verifier: Log to logd instead of kernel log. am: 45eac58ef1
am: 8162eca526

* commit '8162eca52659307879d086feb195f24d3d58e749':
  update_verifier: Log to logd instead of kernel log.
2015-12-08 11:29:31 -08:00
Tao Bao 93a0dd2019 Add update_verifier for A/B OTA update. am: 1171d3a12b
am: 6bc2155d22

* commit '6bc2155d22d059d4d744e2dcf018190faa33aad3':
  Add update_verifier for A/B OTA update.
2015-12-08 11:29:26 -08:00
Tao Bao 26edcd8f5a Merge "updater: Replace strtok() with android::base::Split()."
am: d0acbb56ed

* commit 'd0acbb56ed9c002ccd8021b3e09567647b499e58':
  updater: Replace strtok() with android::base::Split().
2015-12-08 11:26:02 -08:00
Tao Bao ddde4676b6 Merge changes If00669a7,Ia5504ed2
* changes:
  update_verifier: Log to logd instead of kernel log.
  Add update_verifier for A/B OTA update.
2015-12-08 19:25:26 +00:00
Tao Bao 740e01e2bd update_verifier: Log to logd instead of kernel log.
logd already gets started before we call update_verifier.

Bug: 26039641
Change-Id: If00669a77bf9a6e5534e33f4e50b42eabba2667a
(cherry picked from commit 45eac58ef1)
2015-12-08 11:24:35 -08:00
Tao Bao 7197ee0e39 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
(cherry picked from commit 1171d3a12b)
2015-12-08 11:24:11 -08:00
Tao Bao d0acbb56ed Merge "updater: Replace strtok() with android::base::Split()." 2015-12-08 19:18:29 +00:00
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