summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* liblog: replace "frontend" with "transport"Mark Salyzyn2017-03-091-1/+1
| | | | | | | | | | | | We still do not have any users of the 'frontend' interface, let's right a wrong and rename it to 'transport' as it makes more sense. Renames android_log_set_frontend, android_log_get_frontend and include/log/log_frontend.h. SideEffects: None Test: gTest liblog-unit-tests Bug: 27405083 Change-Id: I7c1c0f3dfdc7cf047285403e306edbd16ad1324d
* liblog: stay away from C++ keyword privateMark Salyzyn2017-03-091-1/+1
| | | | | | | | | Replace with void* private with priv in context structure. SideEffects: None Test: gTest liblog-unit-tests Bug: 27405083 Change-Id: I670cb0b7fb2f3085ea13b4ac836d84239a3c8572
* liblog: specify clang formatMark Salyzyn2017-03-091-69/+66
| | | | | | | | | Switch coding style to match SideEffects: None Test: compile Bug: 27405083 Change-Id: Id426d5c5e3b18f2ceec22b31bbc9781aabf6bcca
* liblog: add local_loggerMark Salyzyn2017-02-081-0/+2
| | | | | | | | | | | | | | | | | | | | | | - Create the local-only logger module - Add LOGGER_LOCAL flag to android_set_log_frontend to enable - Permit log reader for host compilation android_set_log_frontend(LOGGER_LOCAL) will result in logs going into application local memory. logcat can not retrieve the data, the user must utilize the log reading interface directly to acquire their own logs. Some local logger tests dropped as they represent testing other liblog facilities. Other local logger tests dropped because we make the conscious decision to not support LOG_ID_SECURITY logging. ToDo: Some local logger tests dropped because of missing functionality associated with blocking reader. Test: gTest libcutils-tests, logd-unit-tests, liblog-unit-tests, logcat-unit-tests, liblog-benchmarks and CtsLiblogTestCases_list Bug: 27405083 Change-Id: Ia23b932af9e05756eaa60bab9139876b14faf72d
* liblog: add android_log_logger_list managementMark Salyzyn2017-02-081-0/+36
| | | | | | | | | | | | | | Add list of android_log_logger_list entities as a way of accessing the list of transport contexts from within one of the transports. This will enable us to iterate back to an internal transport context which may house a last index or signalling semaphore to propagate a wakeup on a blocking read. Test: gTest libcutils-tests, logd-unit-tests, liblog-unit-tests, logcat-unit-tests Bug: 27405083 Change-Id: I0a5e793946c020d97ffe10192369998e4ed92a83
* liblog: logger.h fortify commentsMark Salyzyn2017-02-071-14/+17
| | | | | | Test: none Bug: 27405083 Change-Id: I88ae9f33daa457454edfc5e95cb9e9e74e8cd5f0
* liblog: logd: logcat: Split out log/logger.h into public and private.Mark Salyzyn2016-10-241-2/+1
| | | | | | | | | | | | log/logger.h pieces moved into log/log.h. Correct for some minor Android Coding standards. Test: gTests liblog-unit-tests, logd-unit-tests and logcat-unit-tests Bug: 19235719 Bug: 26552300 Bug: 31289077 Bug: 31456426 Change-Id: I0a19fd8788eec20a582e72e4c62c04534bdb1b9a
* system/core: preparation to pull back interfaces from android/log.hMark Salyzyn2016-10-201-1/+1
| | | | | | | | | | | | | | | | Point to log/log.h where necessary, define LOG_TAG where necessary. Accept that private/android_logger.h is suitable replacement for log/logger.h and android/log.h. Correct liblog/README Effectively a cleanup and controlled select revert of 'system/core: drop or replace log/logger.h' and 'system/core: Replace log/log.h with android/log.h'. Test: compile Bug: 30465923 Change-Id: Ic2ad157bad6f5efe2c6af293a73bb753300b17a2
* Merge "liblog: LIBLOG_ABI_PRIVATE __android_log_is_debuggable()"Treehugger Robot2016-10-171-1/+0
|\
| * liblog: LIBLOG_ABI_PRIVATE __android_log_is_debuggable()Mark Salyzyn2016-10-141-1/+0
| | | | | | | | | | | | | | | | | | | | Allow our own libraries to use this privately instead of running the less efficient get_properties and doing the math. Test: compile and boot smoke test Bug: 27566046 Bug: 31456426 Change-Id: I2f677276d27fbcb6af01b600ac1d9891c8938d43
* | liblog: __android_log_pmsg_file_write() cleanupMark Salyzyn2016-10-131-2/+4
|/ | | | | | | | | | | | | __android_log_pmsg_file_write() will open /dev/pmsg0 if not already, and will close it if we opened it. Added atomic access to the android_log_context as insurance. Fortify and correct pmsg tests. Test: gTest liblog-unit-tests --gtest_filter=liblog.__android_log_pmsg_file_* Bug: 31958686 Change-Id: I2cf6f971b6968938f471fda67367efe20dae3004
* liblog: Replace log/log.h with android/log.hMark Salyzyn2016-09-301-1/+1
| | | | | | | | | | Move all liblog related content into android/log.h, and make log/log.h points to android/log.h. Test: Compile Bug: 26552300 Bug: 31289077 Change-Id: I858e0ebe047b86f2a8530a99bc9c380d3d58edbb
* liblog: logd: logcat: deprecate log/log_read.hMark Salyzyn2016-09-301-1/+0
| | | | | | | | | | | | Always used in combination with log/logger.h except in log_time.cpp, and not used externally. As a result liblog has to support stl, a small price to pay since goal is to convert liblog to C++ internally. Test: compile Bug: 31456426 Bug: 26552300 Bug: 31289077 Change-Id: I72828ec807d0a2c8e40bbdebd7a69f147a7ca5a9
* liblog: reset pid and uid cache after a vfork()Mark Salyzyn2016-07-141-2/+4
| | | | | | | | | Bionic getuid() and getpid() calls cache to reduce the need to perform a syscall, and also reset their own cache after a vfork(). No more need for liblog to be performing this flawed cache operation. Bug: 30085794 Change-Id: I70feed8bff0ddd919c2885a348ba67b14ddc0e0d
* Fix misc-macro-parentheses warnings in liblog.Chih-Hung Hsieh2016-05-181-8/+8
| | | | | Bug: 28705665 Change-Id: Ib272a83cb93b09d986c19a40e23a2679b9e17558
* liblog: suppress pmsg on user buildsMark Salyzyn2016-03-291-0/+1
| | | | | | | | | - add optimized & cached LIBLOG_HIDDEN __android_log_is_debuggable() - check when writing, either LOG_ID_SECURITY, SafetyNet or debuggable when pushing content to the pmsg buffer. Bug: 27566046 Change-Id: I85f1b55ec329b38e00f4183836b6ed53046c323d
* liblog: gate write on log id availableMark Salyzyn2016-03-291-0/+1
| | | | | | | | | | - Secure LOG_ID_KERNEL in writer - Secure LOG_ID_SECURITY in reader and writer - if writer transport says not available, do not write to that log id Bug: 27566046 Bug: 27896341 Change-Id: If63a78a56fb94adfbf9979454c4cadb81af45c19
* liblog: split out transports into separate filesMark Salyzyn2016-03-221-0/+159
Create config_logger, logger and logger_read to house the log interfaces. Add fake_logger, logd_logger and pmsg_logger to house the write and read transports. Allows for an easier and direct path to add new transports to the library. SideEffects: None, logger benchmark performance unaffected Bug: 27176738 Bug: 27405083 Change-Id: I01b38637334a5242905c8c89f6ab0a92e2540008