Commit graph

19188 commits

Author SHA1 Message Date
Colin Cross
4db7607987 Merge "Turn off CRC checking for append2simg"
am: 9df73b007a

* commit '9df73b007a2751223ea3ba8287c40c55b4e576a5':
  Turn off CRC checking for append2simg
2015-12-18 20:40:43 +00:00
Mark Salyzyn
0b57d1efcc Merge "logcat: test: rotated logs can exceed size during crash"
am: 55c636a29f

* commit '55c636a29f87049af75bb8198d031ae9fb7039e5':
  logcat: test: rotated logs can exceed size during crash
2015-12-18 20:40:38 +00:00
Mark Salyzyn
0f33cfab28 Merge "logd: test drop __unused"
am: fb9ff0e8ad

* commit 'fb9ff0e8ade1fca7260a18686d7b02eb912bba36':
  logd: test drop __unused
2015-12-18 20:40:31 +00:00
Tim Murray
430a5d3b43 resolve merge conflicts of e9cf477488 to mnc-dr2-dev-plus-aosp.
Change-Id: I162578bdbb831c0442df03cee142dbc9df657799
2015-12-18 11:27:33 -08:00
Tim Murray
e9cf477488 resolve merge conflicts of 14b307fa47 to mnc-dr2-dev.
Change-Id: I82f17b717b509553389185e6bc9886c105fcd59d
2015-12-18 10:55:00 -08:00
Colin Cross
9df73b007a Merge "Turn off CRC checking for append2simg" 2015-12-18 18:47:30 +00:00
Mark Salyzyn
55c636a29f Merge "logcat: test: rotated logs can exceed size during crash" 2015-12-18 18:37:33 +00:00
Mark Salyzyn
fb9ff0e8ad Merge "logd: test drop __unused" 2015-12-18 18:36:47 +00:00
Mark Salyzyn
8beb0d3ad7 logcat: test: rotated logs can exceed size during crash
Some crash messages can be as large as 4K, so allow
the rotated logs to have a larger size.

Change-Id: I20ef8d526ad2d5eca128d1f99f4ea2d2da426403
2015-12-18 10:35:20 -08:00
Mark Salyzyn
7b4a2049b0 logd: test drop __unused
Change-Id: I1ccf49809b8a0a125601bdb52834c463e2d94165
2015-12-18 10:35:00 -08:00
Colin Cross
b5619d9630 Turn off CRC checking for append2simg
make_ext4fs doesn't write out a CRC chunk, and append2simg doesn't
either, but append2simg was still performing a CRC on every input
block.  Cuts append2simg time in half.

Change-Id: I678f807abbb741042461ed68a0f61b406d3665fb
2015-12-17 17:28:44 -08:00
Mark Salyzyn
6773967938 Merge "logd: ro.config.low_ram set buffer size to 64K"
am: 236fecd923

* commit '236fecd92352217e8a3272751b44c1e5a23ad1b2':
  logd: ro.config.low_ram set buffer size to 64K
2015-12-17 23:54:40 +00:00
Mark Salyzyn
236fecd923 Merge "logd: ro.config.low_ram set buffer size to 64K" 2015-12-17 23:47:14 +00:00
Elliott Hughes
ba7a198c29 Merge "adb host: add device state in "adb wait-for-*""
am: 82509e7925

* commit '82509e79253309af7d78ebc833ca922b7f7b3c48':
  adb host: add device state in "adb wait-for-*"
2015-12-17 22:50:16 +00:00
Elliott Hughes
82509e7925 Merge "adb host: add device state in "adb wait-for-*"" 2015-12-17 22:44:15 +00:00
Josh Gao
67a6d861ce Merge "adb: extract USB FFS read/write limit constants."
am: 1ff73936a7

* commit '1ff73936a77df18395b347bd9245308141269e36':
  adb: extract USB FFS read/write limit constants.
2015-12-17 14:34:57 -08:00
Josh Gao
1ff73936a7 Merge "adb: extract USB FFS read/write limit constants." 2015-12-17 22:29:12 +00:00
Josh Gao
ae72b5aa4b adb: extract USB FFS read/write limit constants.
Change-Id: I5e9fb7959a1c4744cb8d53ece4634138239d4e49
2015-12-17 14:28:24 -08:00
Elliott Hughes
79abeb68f2 Merge "Improve "adb install"\'s error message slightly."
am: d361582dc0

* commit 'd361582dc04063ca93d9939d0315373b10b9200f':
  Improve "adb install"'s error message slightly.
2015-12-17 22:22:33 +00:00
Elliott Hughes
d361582dc0 Merge "Improve "adb install"'s error message slightly." 2015-12-17 22:17:38 +00:00
Elliott Hughes
fe01885c9b Improve "adb install"'s error message slightly.
We still don't really have a clue what went wrong, but "Failed to write"
made it sound like we did.

Change-Id: Ic58b13202e2d8ea6b095f7046db9d0771d77ce65
2015-12-17 14:04:38 -08:00
Tim Murray
14b307fa47 Merge "Fix logspam from system-background cpuset." into mnc-dr1.5-dev 2015-12-17 21:46:29 +00:00
Tim Murray
d31cb63db4 Fix logspam from system-background cpuset.
system-background can't be opened by most processes, since system-bg is
a privileged cpuset. Remove the log message when it can't be
opened. We'll still log a failure to use the fd if we try to use it
after it can't be opened, which is fine.

bug 26249842

Change-Id: I99f185c51645bc81b6a41732848227c27675cdf7
2015-12-17 13:11:50 -08:00
Jorge Lucangeli Obes
f733d6acad Merge "adb: Use Minijail for privilege dropping."
am: 297a8381b5

* commit '297a8381b585ffe2a843581bb1cddd94327f9a2d':
  adb: Use Minijail for privilege dropping.
2015-12-17 19:47:05 +00:00
Jorge Lucangeli Obes
297a8381b5 Merge "adb: Use Minijail for privilege dropping." 2015-12-17 19:39:47 +00:00
Jorge Lucangeli Obes
683dc4817f adb: Use Minijail for privilege dropping.
By using Minijail we avoid writing the same priv-dropping code over
and over again. This also enables future hardening opportunities.
We're already using Minijail for priv-dropping on Brillo.

Minijail is unit- and integration-tested on the
Chrome OS CI infrastructure (pulling from the same repo, see
https://wmatrix.googleplex.com/security?tests=security_Minijail0).
Once CI comes to Android, it will be continuously tested there as well.

Both 'adb root' and 'adb unroot' still work.

Bug: 26099611
Change-Id: I52c456ea272d27bd6fbc71200f4fdd928a592158
2015-12-17 10:49:53 -08:00
Tom Cherry
4692984e92 Merge "Use selinux_android_setcon() instead of setcon()"
am: 64cc0825a6

* commit '64cc0825a639bf022b052cf4fa6aa3e8d13f61b1':
  Use selinux_android_setcon() instead of setcon()
2015-12-17 10:06:03 -08:00
Tom Cherry
64cc0825a6 Merge "Use selinux_android_setcon() instead of setcon()" 2015-12-17 17:54:05 +00:00
Leo Sartre
1fbc9dbd0f adb host: add device state in "adb wait-for-*"
The current implementation of the host commands "adb wait-for-*" allows
to specify only the transport layer (local, usb or any).
This patch allows the specification of the expected device state
(bootloader, recovery, device or sideload), this is usefull for
scripting purposes.

Use case:
$ adb reboot sideload-auto-reboot
$ adb wait-for-usb-sideload && adb sideload package.zip

Change-Id: I276a6be4d82f8b7901f74e1e5395b86d16548e8f
Signed-off-by: Leo Sartre <leox.sartre@intel.com>
2015-12-16 18:11:18 -08:00
Tom Cherry
38cd57a145 Use selinux_android_setcon() instead of setcon()
Bug 26114086

Change-Id: I02d20ee7a5f487fc73d7a33d50b0b8f1cd9ad3a4
2015-12-16 17:42:08 -08:00
David Pursell
9526f21b56 Merge "fastboot: implement UDP networking interface."
am: b6dfab03b6

* commit 'b6dfab03b6b248bf0528d5ea5d91353bf8487bc6':
  fastboot: implement UDP networking interface.
2015-12-17 00:36:53 +00:00
David Pursell
b6dfab03b6 Merge "fastboot: implement UDP networking interface." 2015-12-17 00:27:06 +00:00
David Pursell
815c7beae7 fastboot: implement UDP networking interface.
This CL creates a UdpSocket class that provides a simple unified
interface to send and receive UDP packets for all platforms. Nothing
uses this interface yet except for tests.

The eventual goal is to implement a UDP protocol for fastboot, but it
makes the code much simpler and more modular if we handle the low-level
networking here independently of our custom fastboot protocol.

Some of the Windows code is similar to adb. I'd like to create a
library to hold the common functionality, but it is going to be a
little delicate to separate out the features unique to adb (e.g. the
custom file descriptor system), and I don't want to risk breaking
something in adb before the holiday break, so I'm hoping to get this in
for now and merge them early next year.

Tests are included in this CL to exercise this functionality using a
loopback connection.

Bug: http://b/26154763.
Tests: `fastboot_test` loopback tests on Linux, Mac, and Windows 7.
Change-Id: I81d1b7ace8d864246b99f6c80b8e29f64b8aa375
2015-12-16 16:16:08 -08:00
Jeff Sharkey
8fd865fb48 Re-derive permissions after package changes. am: f7aad11c1c
am: c22e31435d  -s ours

* commit 'c22e31435d8ae6a2bcfec44733297ea4dc1141e5':
  Re-derive permissions after package changes.
2015-12-16 22:16:08 +00:00
Jeff Sharkey
c22e31435d Re-derive permissions after package changes.
am: f7aad11c1c

* commit 'f7aad11c1cc133e352333f83e3abbf323cd41ead':
  Re-derive permissions after package changes.
2015-12-16 14:02:43 -08:00
Nick Kralevich
2dda6ac98d Merge "trace-dev.c: more O_CLOEXEC"
am: a8d3fdf4c6

* commit 'a8d3fdf4c62b485073b439ed46b4814f1608f77a':
  trace-dev.c: more O_CLOEXEC
2015-12-16 21:50:01 +00:00
Nick Kralevich
a8d3fdf4c6 Merge "trace-dev.c: more O_CLOEXEC" 2015-12-16 21:40:32 +00:00
Josh Gao
bf2c482b56 Merge "adb: split up reads longer than 16k."
am: 56d7d4e85f

* commit '56d7d4e85f41ddeea5ca256e5a9c05f73b2f40f0':
  adb: split up reads longer than 16k.
2015-12-16 21:02:50 +00:00
Alex Vakulenko
6170653ce5 Merge "Fix metricsd to conform to the lastest server schema"
am: 2fcf449886

* commit '2fcf449886a52d47a4b57279993e59b13d3be1cb':
  Fix metricsd to conform to the lastest server schema
2015-12-16 20:59:44 +00:00
Josh Gao
56d7d4e85f Merge "adb: split up reads longer than 16k." 2015-12-16 20:47:32 +00:00
Alex Vakulenko
2fcf449886 Merge "Fix metricsd to conform to the lastest server schema" 2015-12-16 20:43:54 +00:00
Jeff Sharkey
e0e5922ec5 Merge "Re-derive permissions after package changes."
am: db72fe1772

* commit 'db72fe1772bb8e9ef72b737f231266a49a1ec042':
  Re-derive permissions after package changes.
2015-12-16 20:37:05 +00:00
Nick Kralevich
dee1ef48a9 trace-dev.c: more O_CLOEXEC
Stop the file descriptors from leaking.

Change-Id: Ib5ca1c2e5031fbec8751bde9e86b32e51e10fcbc
2015-12-16 12:32:26 -08:00
Jeff Sharkey
db72fe1772 Merge "Re-derive permissions after package changes." 2015-12-16 20:28:01 +00:00
Alex Vakulenko
33c5935852 Fix metricsd to conform to the lastest server schema
The new server push enabled component/trait validation rules. This
allows us to use the new schema that does not require vendor commands,
parameters and state to start with underscore ("_").

Also fixed a few minor errors in schema definition.

Change-Id: I184dd8e4c69c05e0dd1b0dddb1f9a7b0aef78841
2015-12-16 12:23:14 -08:00
Jeff Sharkey
f7aad11c1c Re-derive permissions after package changes.
When packages change, existing package-specific directories may have
gained/lost a UID mapping, so we need to update the permissions for
any in-memory nodes.

This allows an app to deliver data for another package before that
package is installed, which is the typical pattern of how OBB files
are delivered.

Also fix bug by re-deriving permissions when files are moved.

Bug: 25399427
Change-Id: I06f38a24ad7dee5f5099ba81429aef03208e5683
2015-12-16 13:20:53 -07:00
Jeff Sharkey
22b912628e Re-derive permissions after package changes.
When packages change, existing package-specific directories may have
gained/lost a UID mapping, so we need to update the permissions for
any in-memory nodes.

This allows an app to deliver data for another package before that
package is installed, which is the typical pattern of how OBB files
are delivered.

Also fix bug by re-deriving permissions when files are moved.

Bug: 25399427
Change-Id: I06f38a24ad7dee5f5099ba81429aef03208e5683
2015-12-16 13:08:29 -07:00
Josh Gao
0b19540dee adb: split up reads longer than 16k.
Reads from functionfs allocate contiguous buffers in the kernel, causing
long ones to sometimes fail because of memory fragmentation.

Bug: http://b/26206622
Change-Id: Id40753d6f29b37b5ca97c3e2fa3921f52b4242de
2015-12-16 11:40:38 -08:00
Elliott Hughes
84ca63eef2 Merge "libpixelflinger: MIPS64 assembler test bug fix"
am: f8d892c84a

* commit 'f8d892c84a2cec5f6ac24748d966873e69227041':
  libpixelflinger: MIPS64 assembler test bug fix
2015-12-16 18:40:10 +00:00
Elliott Hughes
6ed33e5ada Merge "Make host ashmem_create_region more robust."
am: ec2f506e74

* commit 'ec2f506e741bbc9252d25f0f2ba1c24b1aa0ab7d':
  Make host ashmem_create_region more robust.
2015-12-16 18:40:04 +00:00