Commit graph

6843 commits

Author SHA1 Message Date
Mark Salyzyn
d0a83fddf1 liblog: high CPU usage from logcat
BUG: 12457855

- log_read.c poll timeout should be -1 instead of 0 when idling

(cherry picked from commit 080bbfab94)

Change-Id: I9082a15fae0fbf999c0ed516950a49d65a279298
2014-01-27 15:14:18 -08:00
Colin Cross
11aa6ee98c liblog: fix build again
log_read.c has to be in the target sources on all platforms, but
never needs to be in the host sources.

(cherry picked from commit 3c37fae4a4)

Change-Id: Ie0829f3f1daf16d151c401653dbef603b1c2f59d
2014-01-27 15:13:49 -08:00
Mark Salyzyn
f387fa5df0 liblog: drop use of sys/cdefs.h
(cherry picked from commit c96a44888a)

Change-Id: I44ea5d6b572e3712c301e6ebf4b34e6225d7e18b
2014-01-27 15:13:17 -08:00
Mark Salyzyn
015c8e76ca liblog: git_master@964770 build problem
- darwin does not get log reader

(cherry picked from commit 5feea68908)

Change-Id: I64eb69a6099a88d2acf501de725c35741fd7e551
2014-01-27 15:12:15 -08:00
Mark Salyzyn
95132e97e5 logcat: Incorporate liblog reading API
(cherry picked from commit a1062c728a)

Change-Id: I1e1a55d13ac55350e8d54bfe92b392de07f26a5d
2014-01-27 15:11:46 -08:00
Mark Salyzyn
22b5cef127 debuggerd: Incorporate liblog reading API
(cherry picked from commit a63f927ce1)

Change-Id: Ic26e9dba3b45c827d122b03e34cc4a5bd48f7deb
2014-01-27 15:11:10 -08:00
Mark Salyzyn
4295841ebe liblog: Interface to support abstracting log read
(cherry picked from commit 6c1b07fbbd)

Change-Id: Iedc55c1316029b4bb72f51cc656b53b0e3f90aee
2014-01-27 15:10:39 -08:00
Mark Salyzyn
7aa39a7b19 adb: deprecate legacy log service interface
(cherry picked form commit c66a7537df)

Change-Id: If96019cc13b3d7a4dcd7785c7137e0cbcc622981
2014-01-27 15:09:59 -08:00
Mark Salyzyn
c788278abc adb: regression from Move list.c to inlines
(cherry picked from commit 5f64d528be)

Change-Id: I057dbe3db80b1460f774e9f9ade11e0929529ec6
2014-01-27 15:09:22 -08:00
Mark Salyzyn
cf4aa030ce liblog: whitespace cleanup
- change cutils to liblog directory path
- change tabs to spaces

(cherry picked from commit c1215c0b46)

Change-Id: I7d9db1e2b817ba0ec9a224340c5c7535a2387fd5
2014-01-27 15:08:42 -08:00
Mark Salyzyn
b957baccd2 libcutils: bug str_parms.c:str_parms_get_float().
str_parms_get_float did not return the output into
*val. Only output if returning with no error. Audit
shows no internal users of this library function

(cherry picked from commit 8e71ddeac0)

Change-Id: I14a3f08a098072a159dd93f85ead36b3f445816f
2014-01-27 15:07:58 -08:00
Mark Salyzyn
2b94cc264f libcutils: UNUSED argument warnings
(cherry picked from commit ba02cd1e9b)

Change-Id: Ie427d481298af8d911bb2b157ebba30954335354
2014-01-27 15:07:15 -08:00
Mark Salyzyn
e16baef4d2 libsysutils: Get rid of warnings
- UNUSED argument warnings
- Remove LOG_NDEBUG define

(cherry picked from commit 696f267ff5)

Change-Id: I48b0942adfdb7a46a7693e580bc6ed5a685b0d5b
2014-01-27 15:06:22 -08:00
Mark Salyzyn
a6aad4cdb3 libcutils: Move list.c to inlines on list.h
(cherry picked from commit 0ea3624b3e)

Change-Id: I0572555a194d2560e74dfbf07abcec05e9a276a2
2014-01-27 15:04:56 -08:00
Elliott Hughes
fb6d601f5a Merge "Use <stdint.h> for INT32_MIN and INT32_MAX." 2014-01-25 01:25:50 +00:00
Elliott Hughes
81eb357b58 Use <stdint.h> for INT32_MIN and INT32_MAX.
Bug: 12708004
Change-Id: I99f222b2db1d128abf6ffbf7173a5aaff48f8e85
2014-01-24 16:08:03 -08:00
Colin Cross
4800e20eaf Merge "system/core: rename aarch64 target to arm64" 2014-01-24 20:32:49 +00:00
Brian Carlstrom
794b587b37 Merge "Fix entry handling for 0 length entries." 2014-01-24 18:18:12 +00:00
Nick Kralevich
0620e3ddb8 Merge "adbd: switch to su domain when running as root" 2014-01-24 17:59:39 +00:00
Narayan Kamath
48953a1b8f Fix entry handling for 0 length entries.
Two minor issues were fixed:
- The offset to entry data can be the same as the
  central directory offset when the last entry in the
  file has length 0 and is stored (not deflated). Fix
  a check that disallowed this. We already have a strict
  check that entry data must end before the central directory,
  so we're covered.
- We would attempt to map a segment of length 0 when writing
  an entry whose length is 0. We should just return early in
  this case.

bug: 12623277
Change-Id: I2a4ca0c4d170cc3cbf326e5ca13894acd9c434c9
2014-01-24 13:41:55 +00:00
Colin Cross
d4146e6091 system/core: rename aarch64 target to arm64
Rename aarch64 build targets to arm64.  The gcc toolchain is still
aarch64.

Change-Id: Ia92d8a50824e5329cf00fd6f4f92eae112b7f3a3
2014-01-23 18:01:14 -08:00
Colin Cross
5bd11b4887 Merge changes Ib13d9654,I98723ccd
* changes:
  system/core: remove $(KERNEL_HEADERS) from includes
  libcutils: fix atomic_memory_store_barrier
2014-01-24 00:26:59 +00:00
Colin Cross
65dd88becc system/core: remove $(KERNEL_HEADERS) from includes
The kernel headers are already in the include path, and manually
adding them again will break on a multiarch build, where the
kernel headers may be different for each arch.

Change-Id: Ib13d96543f2c97b1b487a46e1748ceb2c5724169
2014-01-22 19:06:04 -08:00
Colin Cross
3510637c85 libcutils: fix atomic_memory_store_barrier
dmb isht is not a valid instruction, fix it to be dmb ishst
(data memory barrier, inner shareable, on writes).

Change-Id: I98723ccd8618b7863cb55da53dc29b979c9905a5
2014-01-22 19:04:28 -08:00
Nick Kralevich
d49aa2537c adbd: switch to su domain when running as root
When adbd runs as root, it should transition into the
su domain. This is needed to run the adbd and shell
domains in enforcing on userdebug / eng devices without
breaking developer workflows.

Introduce a new device_banner command line option.

Change-Id: Ib33c0dd2dd6172035230514ac84fcaed2ecf44d6
2014-01-22 14:20:17 -08:00
Christopher Ferris
1db584b899 Merge "Attempt to fix Mac build" 2014-01-18 23:47:21 +00:00
Brian Carlstrom
db5911a08a Attempt to fix Mac build
Change-Id: I1364255bfed7788a35531962508bad804b8d5b7f
2014-01-18 13:55:54 -08:00
Nick Kralevich
0a72d2930a Merge "Fix "adb push /sdcard/filename"" 2014-01-18 01:01:11 +00:00
Nick Kralevich
72917837e6 Fix "adb push /sdcard/filename"
Don't assume that calling chown(filename, getuid(), getgid())
will always succeed. In the case of /sdcard, a file you create
will be owned by root, so the chown call will fail.

Instead, use uid=gid=-1 so that the chown call is truly a no-op.

Ignore the results of calling chmod. Again, for /sdcard, the
chmod call will never succeed, because the file isn't owned by
the shell user.

Bug: 12441485
Change-Id: I11eaf1d6f6049c1158afc29754fbb7af2baf2c78
2014-01-17 16:16:42 -08:00
Elliott Hughes
6192eedb43 Merge "Fix 'r' for LP64." 2014-01-17 18:03:40 +00:00
Elliott Hughes
2430a064bd Fix 'r' for LP64.
Change-Id: I8332a0a8045a70b3992fe34b0b9e334a721265a9
2014-01-17 09:50:56 -08:00
Christopher Ferris
17b9c82765 Merge "Add PROT_* constants not found on windows." 2014-01-17 16:26:37 +00:00
Christopher Ferris
0dbce4564b Add PROT_* constants not found on windows.
Change-Id: Ic515363ed66dfb2d8e1a6fdfa274508b3a91311d
2014-01-17 08:25:26 -08:00
Christopher Ferris
eb8d73b675 Merge "Rewrite libbacktrace to be all C++." 2014-01-17 15:07:18 +00:00
Christopher Ferris
46756821c4 Rewrite libbacktrace to be all C++.
This includes removing the map_info.c source and replacing it with the
BacktraceMap class to handle all map related code.

Change all callers of libbacktrace map functionality.

Also modify the corkscrew thread code so that it doesn't need to build
the map twice (once in the corkscrew format and once in the libbacktrace
format).

Change-Id: I32865a39f83a3dd6f958fc03c2759ba47d12382e
2014-01-16 16:12:29 -08:00
Elliott Hughes
524b3a0c40 Merge "Remove obsolete 'setconsole' command." 2014-01-16 23:55:50 +00:00
Elliott Hughes
c1e91b0034 Remove obsolete 'setconsole' command.
Change-Id: I643a48653006b97bb10d7b996ecc003dbafad590
2014-01-16 14:50:23 -08:00
Elliott Hughes
7cd1561410 Merge "system/core 64-bit cleanup." 2014-01-16 21:59:58 +00:00
Elliott Hughes
ccecf14254 system/core 64-bit cleanup.
This cleans up most of the size-related problems in system/core.
There are still a few changes needed for a clean 64-bit build,
but they look like they might require changes to things like the
fastboot protocol.

Change-Id: I1560425a289fa158e13e2e3173cc3e71976f92c0
2014-01-16 12:54:18 -08:00
Nick Kralevich
7580661df1 Merge "fs_mgr: increase verboseness on mount errors" 2014-01-16 19:14:30 +00:00
Nick Kralevich
e847f429f4 Merge "restorecon /data/misc/media." 2014-01-15 20:06:52 +00:00
William Roberts
071f28ae0e fs_mgr: increase verboseness on mount errors
While debugging a mount error, the dmesg output was less
than ideal. The error would be declared but why the mount
failed, and what options were passed was not present. This
patch ensures that the mount options and underlying
errno are printed.

Change-Id: I2b3a2c113149df878c0a8a10ef86fd9e4f909658
2014-01-15 13:26:26 -05:00
Stephen Smalley
9e9f05e5eb restorecon /data/misc/media.
Otherwise it will be mislabeled on upgrades with existing userdata.

Change-Id: Ibde88d5d692ead45b480bb34cfe0831baeffbf94
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
2014-01-15 13:19:31 -05:00
Nick Kralevich
37fd839fc2 Merge "Revert "fs_mgr: correct warning on unused function parameter"" 2014-01-15 06:20:42 +00:00
Nick Kralevich
bc7776716a Revert "fs_mgr: correct warning on unused function parameter"
The build is broken.

system/core/fs_mgr/fs_mgr.c:824:77: error: expected '(' before 'unused'
                      const char *blk_device, long long length  __attribute__(unused))
                                                                             ^
system/core/fs_mgr/fs_mgr.c: In function 'fs_mgr_add_entry':
system/core/fs_mgr/fs_mgr.c:824:56: warning: unused parameter 'length' [-Wunused-parameter]
                      const char *blk_device, long long length  __attribute__(unused))
                                                        ^
make: *** [out/target/product/generic_x86/obj/STATIC_LIBRARIES/libfs_mgr_intermediates/fs_mgr.o] Error 1
make: *** Waiting for unfinished jobs....
This reverts commit 21095d0cae.

Change-Id: I64f8c4d9c17c0e3bbf2eb427a2c0b81bbe66ec3a
2014-01-15 06:18:54 +00:00
Nick Kralevich
7169b2303d Merge "fs_mgr: correct warning on unused function parameter" 2014-01-15 05:57:33 +00:00
Elliott Hughes
3352c50375 Merge "Copy the bionic -fstack-protector hack into libbacktrace." 2014-01-15 00:46:48 +00:00
Elliott Hughes
1380ddcab2 Copy the bionic -fstack-protector hack into libbacktrace.
aarch64 doesn't support -fstack-protector yet.

Change-Id: Id1e589742ba074f59d3390d059248c9b371aff58
2014-01-14 16:44:31 -08:00
Elliott Hughes
21ecc30cd0 Merge "Fix fastbootd build for 64-bit." 2014-01-15 00:24:37 +00:00
Elliott Hughes
4f24125ccc Fix fastbootd build for 64-bit.
Change-Id: I04bef46f0125fd6a8fc0cb966bd257ad594aff1e
2014-01-14 16:17:08 -08:00