summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Revert "Exporting C headers from system/core""Vijay Venkatraman2017-01-2530-2296/+1
| | | | | | | This reverts commit a3f2be2b73cebb057218db2a19e8fad04ecb88f6. Test: compile Change-Id: I04b3a8e47e1fa3eb9d80c14ae3a90c68a780e858
* Merge "Remove unused klog_get_level."Elliott Hughes2017-01-251-1/+0
|\
| * Remove unused klog_get_level.Elliott Hughes2017-01-131-1/+0
| | | | | | | | | | | | | | | | Every little helps... Bug: N/A Test: builds Change-Id: Ibcac5cda1619420c95903211ed0b96af81351f9e
* | Revert "Exporting C headers from system/core"Vijay Venkatraman2017-01-2430-1/+2297
| | | | | | | | | | | | This reverts commit 3c6763ca21c1150d66daf8fde9b440b1c3219fe6. Change-Id: If3b3e106478d28a5df927d57649abdca0a99dd0e
* | Exporting C headers from system/coreVijay Venkatraman2017-01-2230-2297/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Moved headers from include/libcutils and include/liblog to libcutils/include and liblog/include respectively, so they can be exported via these libs. They needed to be moved since Soong does not allow export from external folder. Added symlink from old locations. They are needed since Soong includes system/core/include by default. Once all modules are cleaned up to explicitly add the required libs, the symlinks will be removed. Also added liblog_vndk_headers that exports a special log/log.h for VNDK. Moved headers of libcutils to libcutils_headers. They should be used by modules for header-only inlines. Added libcutils_headers as dependency of libcutils. Added libcutils_vndk_headers that exports a special cutils/log.h deprecating usage of the file. A later CL will deprecate the one in libcutils_headers Test: Add above libs to shared lib of local module Change-Id: I6e1f9c5f23d8b6eae13dc3b7e5dfe7fae93b8510
* | Define GID range for external data and OBBs.Jeff Sharkey2017-01-181-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | To quickly answer the question of "how much data is a UID using?" we need a GID range to label files on external storage, similar to the GID ranges already defined for cached and shared data. Also define a new GID that will be used to label the OBB files shared between all users under /data/media/obb. Test: builds, newly added tests pass Bug: 34263266 Change-Id: I16fb7d166c3dcdeafbf477162d191d3b73ae8ac2
* | debuggerd: advance our amazing bet.Josh Gao2017-01-171-55/+0
|/ | | | | | | | | Remove debuggerd in favor of a helper process that gets execed by crashing processes. Bug: http://b/30705528 Test: debuggerd_test Change-Id: I9906c69473989cbf7fe5ea6cccf9a9c563d75906
* libcutils: change klog_level to KLOG_INFO_LEVELWei Wang2017-01-131-2/+0
| | | | | | | | | | | | Some of Android componets e.g. init have migrated to use base/logging to get rid of klog utilities. However, without explicit initilization, the default klog_level is set to 3 which masks the logwrap output. This patch sets default klog_level to KLOG_INFO_LEVEL to make android_fork_execvp_ext log available. Bug: 34256270 Test: manual Change-Id: Ibe74707a92c954053cd0e6828a984fbd72b4acae
* Define range of GIDs for cached app data.Jeff Sharkey2016-12-131-8/+8
| | | | | | | | | | | | | | | To support upcoming disk usage calculation optimizations, this change creates a new GID for each app that will be used to mark its cached data. We're allocating these unique GIDs so that we can use quotactl() to track cached data on a per-app basis. This change also tightens up the implementation of both the cache and shared GID calculation to ensure that they stay inside the valid ranges, and includes tests to verify. Test: builds, boots, tests pass Bug: 27948817 Change-Id: Ie4377e5aae267f2da39a165888139228995987cb
* cutils: add adb trace tag.Josh Gao2016-12-121-1/+2
| | | | | | Bug: http://b/31289465 Test: systrace Change-Id: I8537731febc6629f055b86f6e19b16104208c4f8
* Merge "libcutils: move cutils/files.h to cutils/android_get_control_file.h"Mark Salyzyn2016-11-172-3/+4
|\ | | | | | | | | | | am: 8c41e791ed Change-Id: Ifbc00285da734859d590153a7c6cfc8e51c014f9
| * libcutils: move cutils/files.h to cutils/android_get_control_file.hMark Salyzyn2016-11-162-3/+4
| | | | | | | | | | | | | | | | | | | | files.[h|cpp] is bound to be abused with junk, replace with android_get_control_file.[h|cpp]. Plus some sundry cleanup. Test: gTest libcutils-tests, logd-unit-tests, liblog-unit-tests, logcat-unit-tests and init_tests Bug: 32450474 Change-Id: Ibd4a7aa4624ea19a43d1f98a3c71ac37805d36b5
* | libcutils: add android_get_control_file()Mark Salyzyn2016-11-041-0/+37
|\| | | | | | | | | | | am: 0b034d9d7b Change-Id: I7d0a58c12839dba59aa43b96e5a920d3c415efcf
| * libcutils: add android_get_control_file()Mark Salyzyn2016-11-031-0/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Solve one more issue where privilege is required to open a file and we do not want to grant such to the service. This is the client side of the picture, init is the server. The file's descriptor was placed into the environment as "ANDROID_FILE_<path>" where non-alpha and non-numeric characters in the <path> are replaced with _ and this function picks the file descriptor up. Added definition ANDROID_FILE_ENV_PREFIX ("ANDROID_FILE_") and android_get_control_file() prototype in a new include <cutils/files.h> android_get_control_file() checks if the resulting file descriptor is valid, open and matches the name reference, which on purpose will fail if a symbolic link is in the path rather than using a fully qualified path. Add gTest unit test for both. Test: gTest libcutils_test --gtest_filter=FileTest.android_get_control_file Bug: 32450474 Change-Id: I2d0310a1727f1e393a00d9fc7e6cf5d028f27905
* | Merge "liblog: restructure log/log.h and android/log.h"Mark Salyzyn2016-10-241-1/+1
|\| | | | | | | | | | | am: 11a7165ecf Change-Id: I6ebdebdd82e8a59a711ee0fe41056abdacb084b3
| * liblog: restructure log/log.h and android/log.hMark Salyzyn2016-10-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | We went too far, so this is a partial revert, part deux. Keep general purpose logging macros in android/log.h for the NDK. More internal features like Radio, System and Events logging are moved back to log/log.h. Correct liblog ndk symbols. Correct for some Android Coding standards. Test: compile Bug: 31992412 Change-Id: Id3731496fa226e8c170305d0d2a1859e8cf67e14
* | Merge "Remove socket_loopback_client."Elliott Hughes2016-10-141-1/+0
|\| | | | | | | | | | | am: 5171bebf41 Change-Id: I28080f043ba5a042573e81a6da3f5be83c7a4251
| * Merge "Remove socket_loopback_client."Treehugger Robot2016-10-141-1/+0
| |\
| | * Remove socket_loopback_client.Elliott Hughes2016-10-131-1/+0
| | | | | | | | | | | | | | | | | | Bug: http://b/31537253 Test: builds Change-Id: If02c8107206fb60e4622f8937bee0d0a362e1c7d
* | | Merge "Fallback to IPv6 when IPv4 is not available in adb" am: c32d7fd66f ↵Tao Wu2016-10-131-0/+1
|\| | | | | | | | | | | | | | | | | | | | | | | am: 5b7c6772b0 am: 27c6c4cf04 Change-Id: I2ceb40b4589dfc2721197065ae5a85e9dc83b907
| * | Merge "Fallback to IPv6 when IPv4 is not available in adb"Treehugger Robot2016-10-131-0/+1
| |\ \
| | * | Fallback to IPv6 when IPv4 is not available in adbTao Wu2016-10-131-0/+1
| | |/ | | | | | | | | | | | | | | | | | | Test: manual - make sure it works in both IPv4/IPv6 env. BUG: 31537253 Change-Id: Ica492bff34a8c0441516a213d0e8b78fcdfd3282 Signed-off-by: Tao Wu <lepton@google.com>
* | | Merge "Add native_handle_init" am: d790aae4bc am: 28423b86feChia-I Wu2016-10-131-0/+15
|\| | | | | | | | | | | | | | | | | am: bf72cf21dc Change-Id: I5d4cc013421350dd30fa13d168112d30ad93e7cd
| * | Add native_handle_initChia-I Wu2016-10-121-0/+15
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | HIDL requires file descriptors to be wrapped in native_handle_t. We want a low overhead way to do that when the number of file descriptors is known at compile time. Instead of // wrap an fd in native_handle_t native_handle_t* fd_handle = native_handle_create(1, 0); if (!fd_handle) { // clean up and return error } fd_handle->data[0] = fd; hidl_cb(..., fd_handle); native_handle_delete(fd_handle); this change adds native_handle_init to allow for // wrap an fd in native_handle_t NATIVE_HANDLE_DECLARE_STORAGE(fd_storage, 1, 0); native_handle_t* fd_handle = native_handle_init(fd_storage, 1, 0); fd_handle->data[0] = fd; hidl_cb(..., fd_handle); Test: make libcutils Bug: 32021609 Change-Id: If1fd07482243d37492fdea57c602a1b13c8953cc
* | Merge "Add native_handle_clone" am: e8f6c7398b am: 462e087e40Chia-I Wu2016-10-071-0/+9
|\| | | | | | | | | | | am: cb52dc258e Change-Id: I011555d429120a26e61fbce5f7a125ce96fadb3f
| * Merge "Add native_handle_clone"Chia-I Wu2016-10-071-0/+9
| |\
| | * Add native_handle_cloneChia-I Wu2016-09-261-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | libhwbinder's Parcel::readNativeHandleNoDup returns a temporary native_handle_t. We want a way to save the temporary handle for later use. Change-Id: I16f32043aa8b7d2c0aa57d67551500259b411410
* | | libcutils: Replace cutils/log.h with android/log.h am: 23ed4c242a am: f56fce0240Mark Salyzyn2016-09-301-1/+1
|\| | | | | | | | | | | | | | | | | am: 9fd2eaf827 Change-Id: If01fd686fc15aaf74b6f06b7e661eb46e127d51b
| * | libcutils: Replace cutils/log.h with android/log.hMark Salyzyn2016-09-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace references to cutils/log.h and log/log.h with android/log.h. Point cutils/log.h to android/log.h. Adjust header order to comply with Android Coding standards. Test: Compile Bug: 26552300 Bug: 31289077 Change-Id: I4b00c0dff3a0a50cbb54301fdc5a6c29c21dab65
* | | Merge "Fix more system/core/include warnings" am: 18fbd80504 am: 5fe194a9fdColin Cross2016-09-291-0/+7
|\| | | | | | | | | | | | | | | | | am: b5ca47989c Change-Id: I8d5a602f94bc57866aa3827cc508c94afb4ac4ba
| * | Fix more system/core/include warningsColin Cross2016-09-271-0/+7
| |/ | | | | | | | | | | | | | | | | The warnings in these files were hidden by -isystem framework/native/include. Bug: 31752268 Test: m -j Change-Id: I2a54376aea380ee24e6483fb7d35fdfe8991c490
* | Merge "Move android_get_control_socket out of line" am: 4b5abcdba2 am: ↵Colin Cross2016-09-231-21/+2
|\| | | | | | | | | | | | | | | 4873829953 am: ea2b61c7a8 Change-Id: Ib406546b998d6d525829f0023a5f693c2e1dfd6c
| * Move android_get_control_socket out of lineColin Cross2016-09-231-21/+2
| | | | | | | | | | | | | | | | | | | | | | | | android_get_control_socket has a warning from the implicit cast from long to int. The warning was being hidden because cutils/sockets.h was included with -isystem. Move android_get_control_socket to sockets.cpp, since we don't want header only dependencies anyways, and fix the warning with a range check and a static_cast. Bug: 31492149 Test: m -j <module that uses sockets.h and -Wall> Change-Id: I1f394ab26d4ec8a7dd0e7907c10416d7f8647624
* | Merge "Hide warning in cutils/trace.h" am: 5cf3db6d2b am: a802e570b3Colin Cross2016-09-221-2/+2
|\| | | | | | | | | | | am: 06ec4b1352 Change-Id: If41d5b551ffe237922f4768cf403cadf7ee15887
| * Hide warning in cutils/trace.hColin Cross2016-09-211-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | system/core/include is included in the global include path using -isystem, which hides all warnings. cutils/trace.h has an ignored return value warning, move the implementation to trace-dev.c so it doesn't cause warnings in every module that includes it in preparation for moving from -isystem to -I. Test: m -j native Bug: 31492149 Change-Id: If8b3fe13059c9e59c2d5208294d427d84fa6e588
* | Merge "Fix warnings in cutils/atomic.h" am: 5e093f367c am: 6f292bcab9Colin Cross2016-09-161-15/+24
|\| | | | | | | | | | | am: a205ed0aad Change-Id: I03b1bcf695452b7f0322aaa166c2fe64fc0b49bb
| * Fix warnings in cutils/atomic.hColin Cross2016-09-151-15/+24
| | | | | | | | | | | | | | | | | | | | system/core/include is included in the global include path using -isystem, which hides all warnings. Fix warnings in cutils/atomic.h in preparation for moving from -isystem to -I. Test: m -j native Bug: 31492149 Change-Id: I2a212f192309090a16d507e9ab6acf0fd7cac02d
* | Added a NETWORK trace tag. am: 785735bde1Felipe Leme2016-09-071-1/+2
|\ \ | |/ |/| | | | | | | am: 860f100454 Change-Id: I729a74de3a1da6cbf176e33dfda253ac47d4dfd8
| * Added a NETWORK trace tag.Felipe Leme2016-09-071-1/+2
| | | | | | | | | | BUG: 31281543 Change-Id: I4d7c7fc26c77fec099bbf0f9426e3a9f3a722e6d
* | Merge "libcutils: Add ashmem_valid() function"Mark Salyzyn2016-08-241-0/+1
|\ \ | | | | | | | | | | | | | | | am: d00c7470ea Change-Id: Ib09d3ee7bb131c30f59ea273f357c045394206fb
| * | libcutils: Add ashmem_valid() functionMark Salyzyn2016-08-231-0/+1
| | | | | | | | | | | | | | | Bug: 30310689 Change-Id: I14c52c5d52745a725799652b87c86281ac214899
* | | Merge "Remove process_name.c"Dmitriy Filchenko2016-08-181-42/+0
|\| | | | | | | | | | | | | | | | | am: e5b7ad1c39 Change-Id: I8f98f5fe9ff526ed8780971eddef128ed46de271
| * | Remove process_name.cDmitriy Filchenko2016-08-181-42/+0
| | | | | | | | | | | | | | | | | | BUG: 29824203 Change-Id: I88d67cafb8ec0c4eea3db047bac0671de698ba02
* | | Merge \"Remove no-op klog_init.\"Elliott Hughes2016-07-191-1/+0
|\| | | | | | | | | | | | | | | | | am: 5558cd362b Change-Id: I3f2112bead6740f1df48bc5b028f62c91d40425b
| * | Remove no-op klog_init.Elliott Hughes2016-07-191-1/+0
| | | | | | | | | | | | Change-Id: I467edad1d004ac16647f4aa1f0eead04e808efa0
* | | Merge \"Make klog_fd thread-safe and make klog_init a no-op.\"Elliott Hughes2016-07-081-1/+0
|\| | | | | | | | | | | | | | | | | am: 588b770063 Change-Id: I884276a8f8b8209f6e956c5fb410e8265184e1b5
| * | Make klog_fd thread-safe and make klog_init a no-op.Elliott Hughes2016-06-291-1/+0
| | | | | | | | | | | | | | | | | | | | | I'll come back and remove klog_init when I've removed other calls to it. Change-Id: Iad7fd26d853b4ddc54e9abd44516b6f138cbbfcb Test: booted N9, looked at "adb shell dmesg" output.
* | | Merge changes from topic \'debuggerd_client\'Josh Gao2016-06-201-24/+2
|\| | | | | | | | | | | | | | | | | am: abf88685e3 Change-Id: I2a61e4e8b5ec5a4ab6566ab4f8eb31653255fbc5
| * | debuggerd: add libdebuggerd_client.Josh Gao2016-06-171-24/+2
| | | | | | | | | | | | | | | Bug: http://b/24414818 Change-Id: I079c534d2c952b6975bf0428eb86cc7a55525737
* | | Merge "cutils: don\'t fortify property_get on clang." am: 310da0b990Josh Gao2016-06-031-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | am: 2a1f209245 * commit '2a1f20924516b41e22adb766b6751869fb5c3af4': cutils: don't fortify property_get on clang. Change-Id: Idd7402dca16633fa19e2110b6d74b005b3e519f9