Commit graph

21584 commits

Author SHA1 Message Date
Mark Salyzyn
d353c8b27f Merge "liblog: deal with warning messages" into nyc-dev
am: ac460fc6de

* commit 'ac460fc6de9607bdc04b3c3ed05d85e6b87a9f79':
  liblog: deal with warning messages
2016-02-22 23:58:50 +00:00
Mark Salyzyn
ac460fc6de Merge "liblog: deal with warning messages" into nyc-dev 2016-02-22 23:47:07 +00:00
Mark Salyzyn
b7a0166b00 liblog: deal with warning messages
(cherry pick from commit b525884edb)

- Fix bug in fake_log_devices when it can not allocate memory
  failing to use the full on-stack buffer as backup.
- remove superfluous code.

Bug: 27265662
Change-Id: I97b6cca5f4ce8ecad9beb3a08353de596d6a4ad1
2016-02-22 15:46:22 -08:00
Sami Tolvanen
e06bafb2a5 logd: enforce policy integrity
am: 0bdad0f231

* commit '0bdad0f231103db89f2c0931616dd78309258d3b':
  logd: enforce policy integrity
2016-02-22 23:30:29 +00:00
Sami Tolvanen
0bdad0f231 logd: enforce policy integrity
If a SELinux policy change or a switch to permissive mode is detected
on a user build, restart the device into safe mode, and keep it there
until an OTA is applied or user data is wiped.

This change deprecates the ro.logd.auditd property.

Needs matching changes from
  I781c3059ea8d4fb2f0c923e4488b1932d69678d3
  Ica825cf2af74f5624cf4091544bd24bb5482dbe7
  Id3ca7889ede30b54b7af73dd50653ca1a20d59aa

Bug: 26902605
Change-Id: Idcdc5bff133f13c1267f0ec0a75cc8cf1ddbda0d
(cherry picked from commit d122ee65b6)
2016-02-22 14:00:43 -08:00
Yabin Cui
f8eaff2dd9 Merge "healthd: support reading charge status from BatteryMonitor." am: d633106d3e
am: 0007c4efbe

* commit '0007c4efbe412148ebaf77a964226575a02e3af0':
  healthd: support reading charge status from BatteryMonitor.
2016-02-22 19:25:58 +00:00
Yabin Cui
0007c4efbe Merge "healthd: support reading charge status from BatteryMonitor."
am: d633106d3e

* commit 'd633106d3e43a77bb509ce1cf259b14f78f246ae':
  healthd: support reading charge status from BatteryMonitor.
2016-02-22 18:41:38 +00:00
Yabin Cui
d633106d3e Merge "healthd: support reading charge status from BatteryMonitor." 2016-02-22 18:34:15 +00:00
Calin Juravle
b219fe37c6 Merge "Create profiles folders" into nyc-dev
am: aed972dead

* commit 'aed972dead82d2a74c3a9be296ba3390477d30cf':
  Create profiles folders
2016-02-22 11:49:17 +00:00
Calin Juravle
aed972dead Merge "Create profiles folders" into nyc-dev 2016-02-22 11:42:02 +00:00
Pablo Ceballos
f9603bcb4f Merge "Add the setAutoRefresh interface in ANativeWindow" into nyc-dev
am: f411123ea0

* commit 'f411123ea06da276f435cfd27d824d11b2aebbfe':
  Add the setAutoRefresh interface in ANativeWindow
2016-02-20 18:38:58 +00:00
Pablo Ceballos
f411123ea0 Merge "Add the setAutoRefresh interface in ANativeWindow" into nyc-dev 2016-02-20 18:22:29 +00:00
Josh Gao
3b1c31c216 Merge "adb: sysdeps_test: improve smoke test." am: 0fc006685c
am: 2975a58f3c

* commit '2975a58f3c9ec1a76b9b3e975827d15b3e24eac3':
  adb: sysdeps_test: improve smoke test.
2016-02-20 02:46:11 +00:00
Josh Gao
2975a58f3c Merge "adb: sysdeps_test: improve smoke test."
am: 0fc006685c

* commit '0fc006685c20134b754cd96f7589ea6f93d93cd2':
  adb: sysdeps_test: improve smoke test.
2016-02-20 02:41:37 +00:00
Josh Gao
0fc006685c Merge "adb: sysdeps_test: improve smoke test." 2016-02-20 02:39:51 +00:00
Josh Gao
2275f7da73 adb: sysdeps_test: improve smoke test.
Make sure that adb_poll sets revents for all of the structs passed in.
Also, zero initialize all of the adb_pollfd structs in the tests.

Change-Id: Ia639679a7e6f77483655f1552e89081c4673aa87
2016-02-19 18:36:09 -08:00
Josh Gao
98ab5c1dc8 Merge changes I4a8aa840,I9708f2a3 am: 44b08c722d
am: fe07481ff9

* commit 'fe07481ff944cde33e6546579f83755000453e63':
  adb: check for an error response from adbd between each write.
  adbd: restore the old error handling behavior.
2016-02-20 02:33:46 +00:00
Josh Gao
fe07481ff9 Merge changes I4a8aa840,I9708f2a3
am: 44b08c722d

* commit '44b08c722d05f650c9b6872e28c73affe68eb55a':
  adb: check for an error response from adbd between each write.
  adbd: restore the old error handling behavior.
2016-02-20 02:29:54 +00:00
Josh Gao
44b08c722d Merge changes I4a8aa840,I9708f2a3
* changes:
  adb: check for an error response from adbd between each write.
  adbd: restore the old error handling behavior.
2016-02-20 02:28:22 +00:00
Josh Gao
3f8e3b79c6 Merge changes I9757ab85,Idac80a24 am: 2e70b2d5d8
am: 0640b14df2

* commit '0640b14df292cf48fc3aaee2058908c88cfc0419':
  adb: change unsigned to uint32_t in sync struct definitions.
  adb: detect when the client disconnects in wait-for-device.
2016-02-20 02:17:00 +00:00
Josh Gao
0640b14df2 Merge changes I9757ab85,Idac80a24
am: 2e70b2d5d8

* commit '2e70b2d5d82d6776fe8715de97220a8d7b11afd2':
  adb: change unsigned to uint32_t in sync struct definitions.
  adb: detect when the client disconnects in wait-for-device.
2016-02-20 02:12:46 +00:00
Josh Gao
2e70b2d5d8 Merge changes I9757ab85,Idac80a24
* changes:
  adb: change unsigned to uint32_t in sync struct definitions.
  adb: detect when the client disconnects in wait-for-device.
2016-02-20 02:11:07 +00:00
Yabin Cui
aedf6038dc healthd: support reading charge status from BatteryMonitor.
recovery needs to know whether the battery is charged.

Bug: 26879394
Change-Id: Ie2a1d06e81878efa3ff432c2015d409a625e473e
2016-02-19 18:03:23 -08:00
Josh Gao
afcdcd703e adb: check for an error response from adbd between each write.
When sending a file, do a 0-timeout poll to check to see if an error has
occurred, so that we can immediately report failure.

Bug: http://b/26816782
Change-Id: I4a8aa8408a36940bfda7b0ecfa5d13755f4aa14d
2016-02-19 18:01:09 -08:00
Josh Gao
20a96c7d79 adbd: restore the old error handling behavior.
Restore the previous file sync error handling behavior of reporting
failure, and then consuming packets from the other end until receiving a
DONE packet.

Bug: http://b/26816782
Change-Id: I9708f2a36c072547e191fa0b6b42dffc31f8a2f2
2016-02-19 18:01:09 -08:00
Josh Gao
8a907122f8 Merge changes I6541bb13,I486055bb,Id6ac1c54,I16cf7d44 am: 4a9084228a
am: 38d258ef70

* commit '38d258ef7005d0ac336e8571d72c092df6d42606':
  adb: make fdevent_test, socket_test compile on Windows.
  adb: add fd exhaustion test, fix errno reporting in sysdeps_win32.
  adb: move win32 fd base to 2048, fix fd allocation.
  adb: don't emulate fdevent or socketpair on Windows.
2016-02-20 01:48:29 +00:00
Josh Gao
38d258ef70 Merge changes I6541bb13,I486055bb,Id6ac1c54,I16cf7d44
am: 4a9084228a

* commit '4a9084228a447658dc7beda9334dad0b1f8bb780':
  adb: make fdevent_test, socket_test compile on Windows.
  adb: add fd exhaustion test, fix errno reporting in sysdeps_win32.
  adb: move win32 fd base to 2048, fix fd allocation.
  adb: don't emulate fdevent or socketpair on Windows.
2016-02-20 01:44:14 +00:00
Josh Gao
4a9084228a Merge changes I6541bb13,I486055bb,Id6ac1c54,I16cf7d44
* changes:
  adb: make fdevent_test, socket_test compile on Windows.
  adb: add fd exhaustion test, fix errno reporting in sysdeps_win32.
  adb: move win32 fd base to 2048, fix fd allocation.
  adb: don't emulate fdevent or socketpair on Windows.
2016-02-20 01:41:09 +00:00
Jeff Sharkey
7cb236c943 Merge "Temporary fix for bugreport symlink." into nyc-dev
am: a9061ece05

* commit 'a9061ece0519755808e84909ad3747462c1fe666':
  Temporary fix for bugreport symlink.
2016-02-19 23:01:30 +00:00
Jeff Sharkey
a9061ece05 Merge "Temporary fix for bugreport symlink." into nyc-dev 2016-02-19 22:52:47 +00:00
Jeff Sharkey
002aecf6e8 Temporary fix for bugreport symlink.
Bug: 27262109
Change-Id: I011da38f8ad1eeaf717dc03a0fb6f9fdc5654c4c
2016-02-19 15:51:42 -07:00
Josh Gao
69469c4e9f adb: change unsigned to uint32_t in sync struct definitions.
Change-Id: I9757ab853cfad1a2e1393ef32bcab222ab84acef
2016-02-19 14:37:04 -08:00
Josh Gao
09855472f4 adb: detect when the client disconnects in wait-for-device.
Avoid leaking a thread and its associated resources when a user cancels
wait-for-device.

Bug: http://b/26966721
Bug: https://code.google.com/p/android/issues/detail?id=199088
Change-Id: Idac80a24e9739ddd24e500fe14826a78f350c018
2016-02-19 14:35:48 -08:00
Colin Cross
f59f2b8c15 Merge "libmemunreachable: fix long timeout on error" am: ee127f3d6b
am: fccaa02a76

* commit 'fccaa02a76e83cdcc0937e05fe2b8e20d5af06b3':
  libmemunreachable: fix long timeout on error
2016-02-19 22:17:27 +00:00
Colin Cross
fccaa02a76 Merge "libmemunreachable: fix long timeout on error"
am: ee127f3d6b

* commit 'ee127f3d6b20c45e90f277d5571260b0250f0349':
  libmemunreachable: fix long timeout on error
2016-02-19 22:11:36 +00:00
Colin Cross
ee127f3d6b Merge "libmemunreachable: fix long timeout on error" 2016-02-19 22:04:26 +00:00
Colin Cross
b1b7923efe libmemunreachable: fix long timeout on error
The collection thread should unblock the parent when it fails in order
to prevent a 100 second timeout delay.  Also reduce the timeout to 30
seconds, and fix a few log messages.

Change-Id: I47f9ce4f645c453810fec57bef557c32a665eefb
2016-02-19 14:00:17 -08:00
Mohamad Ayyash
33748928da Revert "Update make_ext4fs_internal param-list to match new implementation"
am: 527cc0b7a4

* commit '527cc0b7a4d2a72f38d6f956a03864391f5562f1':
  Revert "Update make_ext4fs_internal param-list to match new implementation"
2016-02-19 21:23:33 +00:00
Mohamad Ayyash
527cc0b7a4 Revert "Update make_ext4fs_internal param-list to match new implementation"
This reverts commit 6d94dfee45.

Change-Id: Iec0832740e321e31a78a31d5358542d2ed4455fa
2016-02-19 21:16:38 +00:00
Elliott Hughes
cd905d01b0 Merge "Remove dead code from debuggerd." am: fbaefc4d9d
am: bdf9d18c34

* commit 'bdf9d18c34b791c4fc2156d18c41143d9f067778':
  Remove dead code from debuggerd.
2016-02-19 19:48:50 +00:00
Elliott Hughes
bdf9d18c34 Merge "Remove dead code from debuggerd."
am: fbaefc4d9d

* commit 'fbaefc4d9d4e7e40ec0262123cd54762b81ed47a':
  Remove dead code from debuggerd.
2016-02-19 19:42:29 +00:00
Mohamad Ayyash
8e9878f3e6 Update make_ext4fs_internal param-list to match new implementation
am: 6d94dfee45

* commit '6d94dfee451dccc07c9c158da97f9393ac4e0a83':
  Update make_ext4fs_internal param-list to match new implementation
2016-02-19 19:38:48 +00:00
Elliott Hughes
fbaefc4d9d Merge "Remove dead code from debuggerd." 2016-02-19 19:36:22 +00:00
Josh Gao
022d447e9e adb: make fdevent_test, socket_test compile on Windows.
Switch pthread_* to use the adb_thread_* abstractions to allow the fdevent
and socket tests to compile on Win32.

Bug: http://b/27105824
Change-Id: I6541bb1398780b999837e701837d7f86a5eee8ca
2016-02-19 11:24:51 -08:00
Josh Gao
6487e74a59 adb: add fd exhaustion test, fix errno reporting in sysdeps_win32.
Add a test for FD exhaustion, and fix cases where we weren't properly
setting errno.

Change-Id: I486055bb9ead31089ce76b210c11de9e973f3256
2016-02-19 11:24:51 -08:00
Josh Gao
b6232b96dd adb: move win32 fd base to 2048, fix fd allocation.
Windows has a maximum fd limit of 2048, so we can avoid collision with
real file descriptors by starting from there. Also, fds would be
previously be allocated by a linear walk from the last allocated FD,
instead of the lowest available FD, as required by POSIX. Keep track of
the lowest available file descriptor to make things feel more familiar.

Change-Id: Id6ac1c54f4f7964a6cdfa8d3f4f96262e4881964
2016-02-19 11:24:51 -08:00
Josh Gao
3777d2ecc0 adb: don't emulate fdevent or socketpair on Windows.
Change-Id: I16cf7d4427eb79f36db39e91f85402a268fa72f5
2016-02-19 11:24:51 -08:00
James Hawkins
22b6f7a559 resolve merge conflicts of 0f5d443d0c to nyc-dev-plus-aosp
Change-Id: I850bda0808ae17ade5bc0e667211a599d284d6e3
2016-02-19 11:10:30 -08:00
Elliott Hughes
6da1353863 Remove dead code from debuggerd.
system/core/debuggerd/debuggerd.cpp:683:5: warning: Value stored to 'logsocket' is never read
    logsocket = -1;
    ^           ~~

Bug: http://b/27264392
Change-Id: I8eab8a02b67f219c32aea49e4d4957e5642df38f
2016-02-19 10:41:17 -08:00
Mohamad Ayyash
6d94dfee45 Update make_ext4fs_internal param-list to match new implementation
BUG: 26839493
Change-Id: I4cd316ebc91457e2ec31c0e8b116798d9f94a223
Signed-off-by: Mohamad Ayyash <mkayyash@google.com>
2016-02-19 18:34:59 +00:00