Commit Graph

29773 Commits

Author SHA1 Message Date
Keun-young Park 010efc6a1c Merge "combine wait for exec log with service exit log"
am: 483d2f9a59

Change-Id: I58622d8a76f6f9ecc5df5bb421a4c6af6b72b41a
2017-04-28 20:25:31 +00:00
Keun-young Park 483d2f9a59 Merge "combine wait for exec log with service exit log" 2017-04-28 20:12:00 +00:00
Josh Gao ae29339ca1 base: make boot_clock work on host linux, hide it on non-linux.
boot_clock was previously returning zero on any platform that doesn't
define __ANDROID__, including host bionic. Instead of returning a bogus
value, just hide it on non-Linux platforms.

Bug: http://b/37758947
Test: libbase_test32/64 on linux
Change-Id: I96e1d8b92dc44c6308408900cf0d27e1e7db5569
2017-04-28 13:00:00 -07:00
Jocelyn Bohr 4cd2da28ff Merge changes I5b1a1ce0,I483a18f9
am: 9349b72a67

Change-Id: Ia2a70526d7fd97a45d62f896f6e3888c9df3e982
2017-04-28 18:42:27 +00:00
Treehugger Robot 9349b72a67 Merge changes I5b1a1ce0,I483a18f9
* changes:
  fastboot: Add 'get_staged' command
  fastboot: Add 'stage' command
2017-04-28 18:34:08 +00:00
Keun-young Park 4de31e1481 combine wait for exec log with service exit log
- allows easier tracking of wait time from monitoring tools
- this change also reduces unnecessary log spam
- service exit log looks like this:
  init: Service 'exec 4 (/system/bin/otapreopt_slot)' (pid 611) exited with status 0 waiting took 0.060771 seconds

bug: 37752410
Test: reboot and check log
Change-Id: I122902538697f33939eede548e39f155ec419e03
2017-04-28 11:20:12 -07:00
Bowgo Tsai 359bed3615 fs_mgr: code clean up
- Returns FS_MGR_MNTALL_FAIL for failure paths in fs_mgr_mount_all()
- Removes the 'goto out' in fs_mgr_do_mount() as there is nothing to do in
  the 'out' label now. Also removes the "ret = FS_MGR_DOMNT_FAILED;" and
  just return FS_MGR_DOMNT_FAILED directly for the default failure path.
- Changes some LERROR to PERROR

Test: Use fs_mgr_do_mount() to mount /system with AVB
Change-Id: I126a0124a5c9d61302f40ab9db16989500d9777e
2017-04-28 12:47:18 +08:00
Josh Gao f405fe0edb Merge "debuggerd_handler: don't assume that abort message implies fatal."
am: 263e1e9509

Change-Id: I9f89164e889b7ec7d7de6c8989044955875e3d0e
2017-04-28 03:02:35 +00:00
Treehugger Robot 263e1e9509 Merge "debuggerd_handler: don't assume that abort message implies fatal." 2017-04-28 02:47:16 +00:00
Josh Gao 637483de91 base: remove execute bit from utf8.cpp, utf8_test.cpp.
Test: none
Change-Id: Idcd7feb2f3a7dc8706c498c55100e82d029858e0
2017-04-27 19:10:07 -07:00
Jaesoo Lee 371e0bf298 Merge "added include for unistd.h that was missing"
am: 98cc0e1f02

Change-Id: Iba8ad7abd27b0e82e2ed23c9f539bd3511726e9c
2017-04-28 01:48:58 +00:00
Treehugger Robot 98cc0e1f02 Merge "added include for unistd.h that was missing" 2017-04-28 01:39:55 +00:00
Bowgo Tsai b66306c7c1 Merge "fs_mgr: set "partition.system.verified" when AVB is used in a A/B device"
am: 5c7543569a

Change-Id: I7d630bc3dc15554400f0e0c9b35919452cd7b03f
2017-04-28 01:27:46 +00:00
Treehugger Robot 5c7543569a Merge "fs_mgr: set "partition.system.verified" when AVB is used in a A/B device" 2017-04-28 01:21:13 +00:00
Jerry Zhang 935d600800 Merge "Revert "adb: Lower EP_ALLOC retry count""
am: 169590c47f

Change-Id: Ia31c905eab9cb5c1c51a951896a8d1ed17978927
2017-04-28 01:08:13 +00:00
Jerry Zhang 169590c47f Merge "Revert "adb: Lower EP_ALLOC retry count"" 2017-04-28 01:06:09 +00:00
Jaesoo Lee 0951ddeb69 Merge changes from topic 'libutils-export-headers'
am: 4af3a7966b

Change-Id: I390c56cfc6312ded05ee359931faabf9517c4067
2017-04-28 00:55:51 +00:00
Jaesoo Lee 4af3a7966b Merge changes from topic 'libutils-export-headers'
* changes:
  libutils_headers: export libcutils_headers
  libutils: export libbacktrace headers
  libutils: export system_headers
2017-04-28 00:47:35 +00:00
Jaesoo Lee 1e8ac0fd03 libutils_headers: export libcutils_headers
These headers are used in headers in libutils_headers and must be
re-exported.

include/utils/Atomic.h:20:#include <cutils/atomic.h>
include/utils/Trace.h:24:#include <cutils/trace.h>
include/utils/Singleton.h:27:#include <cutils/compiler.h>

Test: modules using libutils_headers don't have to have
libcutils_headers include dirs set.
Bug: 33241851

Change-Id: I039aaaad93bf0944d42f04d2a9e6654b4f867042
2017-04-28 09:42:50 +09:00
Steven Moreland 4ad9d5155b libutils: export libbacktrace headers
This is used in CallStack.h.

Test: m -j libutils
Test: links
Test: trying to compile with BOARD_VNDK_VERSION := current
Bug: 33241851
Change-Id: I076c9551d356824d6e69b82349b890369bc7eea3
Merged-In: If7258e7b38000a72fd520f725030fb0038f90167
2017-04-28 09:42:50 +09:00
Steven Moreland 2d0dc9966a libutils: export system_headers
vendor + vendor_available modules built with BOARD_VNDK_VERSION :=
current aren't allowed to use global headers. Since libutils uses
system headers itself, it should export them as well.

Bug: 33241851
Test: building with BOARD_VNDK_VERSION := current produces many fewer
errors.

Change-Id: Icc7d2beb2a17da291434c6282eb1b9eb458f114c
Merged-In: I950821f1dae3ddc110db50869247913d5b1aa638
2017-04-28 09:42:50 +09:00
Abodunrinwa Toki f566376046 Merge "Initialize textclassifier model update directory"
am: a079e453a3

Change-Id: I387317dc16006c110680bfa920246e00affb5564
2017-04-28 00:38:41 +00:00
Treehugger Robot a079e453a3 Merge "Initialize textclassifier model update directory" 2017-04-28 00:30:26 +00:00
Josh Gao e06f2a4886 debuggerd_handler: don't assume that abort message implies fatal.
Applications can set abort messages via android_set_abort_message
without actually aborting. This leads to following non-fatal dumps
printing their output to logcat in the same format as a regular crash.

Bug: http://b/37754992
Test: debuggerd_test
Change-Id: I9c5e942984dfda36448860202b0ff1c2950bdd07
2017-04-27 17:28:05 -07:00
Jerry Zhang fa14b1de73 Merge "Move adbd stopped trigger for configfs into core."
am: e21b2fb6b4

Change-Id: I3b1162d5467fa3443849889564ae3e92bdbea4eb
2017-04-27 23:59:02 +00:00
Jerry Zhang e21b2fb6b4 Merge "Move adbd stopped trigger for configfs into core." 2017-04-27 23:50:15 +00:00
Jocelyn Bohr 91fefadc2e fastboot: Add 'get_staged' command
(cherry-picked from internal nyc-iot-dev to AOSP)

New user-level command usage:

 * fastboot get_staged <outfile>
   Reads staged data from the last command handled by the device. If the
   last command did not result in staged data, this command will fail.

This enables data staged by OEM commands to be transferred from device
to host. get_staged wraps new device command "upload". Fastboot
clients are not required to support "upload", so get_staged won't
work on all devices.

Bug: 36002804
Test: Implemented "upload" in fastboot on imx6ul. Verified that uploading
      ~100K data from the device works.
Change-Id: I5b1a1ce023f362062505ee62746ea8ab6f36bfbf
(cherry-picked from commit 83a875de994bf48f0faa2a8a23ceb0b8f52b6b04)
2017-04-27 16:47:51 -07:00
Jerry Zhang c6faf65758 Merge "Add ffs.mtp.ready triggers to mtp configs."
am: a06ac26dd1

Change-Id: I7e3e206172d1385f27bea26d5d3e0471cc13ec8b
2017-04-27 22:12:31 +00:00
Jerry Zhang 40a8778491 Revert "adb: Lower EP_ALLOC retry count"
This reverts commit 05fe272a87.

Commit "adb: Do not signal gaget stack unless descriptors are written"
fixed the main issue for configfs devices where device wasn't enabled
until after the ioctl was attempted. Thus it is safe to bring up the
retry count so that the ioctl doesn't fail due to small delays in
usb stack.

Test: use adb, switch configs on configfs devices
2017-04-27 15:00:13 -07:00
Jerry Zhang 75f8d89a8a Move adbd stopped trigger for configfs into core.
This trigger resets ffs.ready in situations where
adbd is stopped via commandline.

Test: stop adbd
Change-Id: Ib5028d55c4883a8291d6de2dbcb0641ff8eb7a48
2017-04-27 14:59:48 -07:00
Jerry Zhang a06ac26dd1 Merge "Add ffs.mtp.ready triggers to mtp configs." 2017-04-27 21:58:44 +00:00
Abodunrinwa Toki 40673e3381 Initialize textclassifier model update directory
Test: Builds successfully. Directory is initialized on install. Tests pass.
bit FrameworksCoreTests:android.view.textclassifier.TextClassificationManagerTest
Bug: 34780396

Change-Id: Icbf7962f11b66579931f48053132da6e03e62c61
2017-04-27 22:56:43 +01:00
Steven Moreland 3257727096 Merge "libtrusty: Android.mk -> Android.bp"
am: de70e33092

Change-Id: Ic18c86fd29f3793026fb830d91ad44d62b3aed42
2017-04-27 20:20:45 +00:00
Treehugger Robot de70e33092 Merge "libtrusty: Android.mk -> Android.bp" 2017-04-27 20:02:17 +00:00
Tom Cherry 2be5884903 Merge "init: fix last_reboot_reason string"
am: 59c74a3bd1

Change-Id: I77a91f303ffce4f040d774047d2c72920c1acaee
2017-04-27 19:49:30 +00:00
Treehugger Robot 59c74a3bd1 Merge "init: fix last_reboot_reason string" 2017-04-27 19:39:53 +00:00
Elliott Hughes 8e0ded0c6c Merge "Make "fastboot update" respect $TMPDIR."
am: 8e0ccc9ff3

Change-Id: I74e6b2fb1e69de03960dfb0bfdd711af9e9cbd8f
2017-04-27 15:52:22 +00:00
Elliott Hughes 8e0ccc9ff3 Merge "Make "fastboot update" respect $TMPDIR." 2017-04-27 15:40:03 +00:00
Bowgo Tsai 48fdc292f9 fs_mgr: set "partition.system.verified" when AVB is used in a A/B device
In a A/B device, system partition is mounted by kernel as root.
In vboot 1.0, the dm device name of system partition is "system" with
the following configuration in kernel command line:
    - dm="system none ro,0 1 android-verity /dev/sda34"

In AVB, the dm device name is switched to vroot as:
    - dm="1 vroot none ro 1,0 5201456 verity 1 ..."

When sending ioctl DM_TABLE_STATUS to query status, we should use "vroot" as the
dm device name for AVB. But still pass "system" for the callback function to set
property [partition.system.verified] instead of [partition.vroot.verified].

Bug: 36900078
Test: Use AVB to mount system in a A/B device, checks the property exists
      [partition.system.verified]
Test: Use vboot 1.0 to mount system in a A/B device, checks the property exists
      [partition.system.verified]
Test: Checks 'adb remount' will output warning message:
        - dm_verity is enabled on the system and vendor partitions.
        - Use "adb disable-verity" to disable verity.

Change-Id: Iaee7eb2b00b03729bc07fa24f1b449488716d2ea
2017-04-27 18:58:29 +08:00
Steven Moreland f304a20523 libtrusty: Android.mk -> Android.bp
Test: links

Change-Id: Ic64361f98e9e51b62bfda8b2b1c3a00ae03f0a37
2017-04-26 18:58:18 -07:00
Elliott Hughes bbfc281485 Make "fastboot update" respect $TMPDIR.
Bug: http://b/32701538
Test: TMPDIR=/ fastboot update
Change-Id: I06d1bc8d43b306855dfe19bc736513d3336df287
2017-04-26 17:20:36 -07:00
Jerry Zhang fb256b696b Add ffs.mtp.ready triggers to mtp configs.
This allows devices to use functionfs for mtp and ptp instead
of the ordinary functions. The property is set regardless of
which function is enabled so mtp and ptp functions will continue
to work.

Bug: 33220530
Test: use mtp with ffs and non ffs devices
Change-Id: I4527e153bd10ef1e262e487482ae455835d1c698
2017-04-26 17:11:50 -07:00
Steven Moreland 5076014708 Merge "libbinderwrapper: Android.mk -> Android.bp"
am: 8a85c253bf

Change-Id: I48f566cc646a6b708a34389b8836a4441fe86af5
2017-04-26 23:34:36 +00:00
Treehugger Robot 8a85c253bf Merge "libbinderwrapper: Android.mk -> Android.bp" 2017-04-26 23:24:58 +00:00
Keun-young Park 0020d4c076 Merge "set default shutdown timeout to 6 secs"
am: 47d15ed5b9

Change-Id: I076911247627894009490047caa9f04b8e616755
2017-04-26 22:43:29 +00:00
Erik Staats d32331fb27 Change set_sched_policy to set slack for current thread.
Change set_sched_policy to use prctl PR_SET_TIMERSLACK if setting the policy
for the current thread and /proc/<tid>/timerslack_ns is not supported by the
kernel.

Bug: 32972117
Test: Verified that libcutils SchedPolicy tests pass.  See details in
testing done comment in
https://android-review.googlesource.com/381303 .
Change-Id: Id70940ed7f9ed94c3d105213f069bf3e5a8d8824
2017-04-26 15:39:26 -07:00
Keun-young Park 47d15ed5b9 Merge "set default shutdown timeout to 6 secs" 2017-04-26 22:35:26 +00:00
Keun-young Park 76a3b3ce5c Merge "do not start shutdown animation from init"
am: 84d43c8df7

Change-Id: I2cc5860c125a34b356bff9b62a9027ee293da683
2017-04-26 21:05:41 +00:00
Keun-young Park fadad58262 Merge "add additional dump for timeout"
am: 8cde09064e

Change-Id: I7413854112a4d4d2f8e286e7f8be177ec4e282dc
2017-04-26 21:05:22 +00:00
Treehugger Robot 84d43c8df7 Merge "do not start shutdown animation from init" 2017-04-26 20:59:56 +00:00