Commit graph

24 commits

Author SHA1 Message Date
Mark Salyzyn
7e2f83c0bc logd: liblog: 64-bit issues
- structure packing
- move towards log_time from struct timespec
- extend log_time to cover differences between
  log_time and struct timespec

Change-Id: I106ed0b609917306d170044054b5b32645f2a295
2014-03-05 16:12:28 -08:00
Mark Salyzyn
154f4608aa liblog: enable logging to logd.
* Modify liblog to send all messages to the new syslog user
  space daemon.

Original-Change-Id: I0ce439738cd921efb2db4c1d6a289a96bdbc8bc2
Original-Change-Id: If4eb0d09409f7e9be3eb4bb7017073dc7e931ab4
Signed-off-by: Nick Kralevich <nnk@google.com>

* Add a TARGET_USES_LOGD make flag for BoardConfig.mk to manage
  whether logd is enabled for use or not.
* rename syslog to logd to avert confusion with bionic syslog
* Add fake log support back in
* prefilter for logging messages from logd
* Fill in timestamps at logging source
* update abstract log reader
* switch from using suffix for id to v3 format
* log a message when creating devices that a deprecated interface
  is being utilized.

Signed-off-by: Mark Salyzyn <salyzyn@google.com>

(cherry pick from commit 099e2c1f6f706a8600c1cef74cce9066fc315480)

Change-Id: I47929a5432977a1d7235267a435cec0a7d6bd440
2014-02-28 13:49:11 -08:00
Kristian Monsen
7ddca5adb6 Fix code style, put unused in the end
Change-Id: I7315b35049924d5067203a432584b8f29e5a1391
2014-01-28 13:19:11 -08:00
Mark Salyzyn
d2acdd82e6 Merge changes I70ab37d5,I716f89c0,I34c96adf,I77650923,I35b0d1ee, ...
* changes:
  libsysutils: SocketListener export release
  libsysutils: Add iovec/runOnEachSocket
  liblog: support struct logger_event_v2 format
  liblog: update timestamp on NOTICE file
  libcutils: resolve warning in iosched_policy.c
  liblog: Add const pedantics
  logcat: Add -T flag (-t w/o assumption of -d)
  logcat: Add logcat test suite
  liblog: Add cpu utilization test
  liblog: Add liblog test suite
  debuggerd: Support newline split in log messages
  liblog: deprecate export LOGGER ioctl definitions
  liblog: deprecate export of LOGGER_LOG_* defines
  liblog: Add README
  liblog: resolve build warning messages
  liblog: high CPU usage from logcat
  liblog: fix build again
  liblog: drop use of sys/cdefs.h
  liblog: git_master@964770 build problem
  logcat: Incorporate liblog reading API
  debuggerd: Incorporate liblog reading API
  liblog: Interface to support abstracting log read
  adb: deprecate legacy log service interface
  adb: regression from Move list.c to inlines
  liblog: whitespace cleanup
  libcutils: bug str_parms.c:str_parms_get_float().
  libcutils: UNUSED argument warnings
  libsysutils: Get rid of warnings
  libcutils: Move list.c to inlines on list.h
2014-01-28 21:09:37 +00:00
Kristian Monsen
b5a9890f90 Fixes some warnings
- Implicit decleared function
- Unused variable

Change-Id: Ia701e66682cb6788f0716a2ef7556ed07227f78f
2014-01-28 11:28:32 -08:00
Mark Salyzyn
e9c4196980 liblog: deprecate export of LOGGER_LOG_* defines
(cherry picked from commit 73459a5c87)

Change-Id: I263af8e889f8f2ad91b91757caf90a4d17823dab
2014-01-27 15:16:04 -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
Colin Cross
9227bd3855 Move liblog headers to system/core/include/log
Move the liblog headers to log/ instead of cutils/ to complete
the separation of libcutils and liblog.  cutils/log.h still
exists and includes log/log.h in order to support the many existing
modules that use cutils/log.h.

Change-Id: I2758c9f4aedcb809ca7ba8383d0f55041dd44345
2013-07-24 12:32:39 -07:00
Nick Kralevich
a170322083 liblog: fix fd leakage
File descriptors remain open across an exec unless FD_CLOEXEC is
set.  Add O_CLOEXEC to the open() call to prevent file descriptor
leakage.

In particular, the following program will eventually run out of
file descriptors:

int main(int argc, char **argv) {
  printf("===== entering main =====\n");
  ALOGW("entering main");
  system("ls -l /proc/self/fd/");

  execv(argv[0], argv);
  printf("exec failed\n");
  return -1;
}

Change-Id: I5be43ab3b9f82a05f242b1f586454c50568af388
2013-03-15 09:48:32 -07:00
Wink Saville
3761e963b3 Use Rlog instead of Log
Changing __android_log_write so the tag warns users relying on the
tag to direct log output to the radio buffer to instead use Rlog or RLOG.

Change-Id: I04b7bb5e620c1ab22b9b495382a252b539947e28
2012-12-06 10:28:34 -08:00
Jeff Sharkey
84dcf09148 Collapse IMS tags into a prefix check.
Bug: 6497974
Change-Id: I7fba1a07e2552ce16131b81f30d18eb3192de7ef
2012-08-13 11:27:54 -07:00
Jeff Sharkey
44e95651dd Force IMS logging into radio log.
Bug: 6497974
Change-Id: I4691f287b0abdce03ff211bd5b5b0037b8818ec9
2012-07-17 11:32:21 -07:00
Brett Chabot
7b023b293b Fix SDK build.
Revert "Fix build warnings"

This reverts commit 590e364868.
2011-06-27 11:14:46 -07:00
Glenn Kasten
590e364868 Fix build warnings
Change-Id: Ie24cf8e729813e4527c698fc7c1502a1efbc63e5
2011-06-24 15:40:56 -07:00
Chris Pearson
1929990434 Fixed LOG_ASSERT() compilation errors in native debug builds.
Invoking LOG_ASSERT, LOG_ALWAYS_FATAL or LOG_ALWAYS_FATAL_IF variadic macros
without the printf format string arg caused compilation errors because the
variable arg list (__VA_ARGS__) was eventually passed to
__android_log_assert() func in place of a required parameter. This error
only occured in debug builds because LOG_ASSERT() is a no-op in release
builds.  This change allows debug builds to succeed.

Change-Id: I7e7b7de3e501133468ce083e0e0d6e699dd59667
Signed-off-by: Chris Pearson <christopherx.c.pearson@intel.com>
2010-07-16 07:56:03 -07:00
Joe Onorato
3b6bd0267a remove stray printfs. 2010-03-03 17:18:28 -05:00
Joe Onorato
e2bf2ea4d2 Make logcat print both the main and system buffers by default. Make SLOGx macros work. 2010-03-01 13:03:19 -08:00
John Michelau
ed7ccae296 Route all log tags with "RIL" prefix to radio buffer. 2009-08-19 10:06:52 -07:00
Wink Saville
89efdc9c7f AI 144245: Fix merge conflict for megering in the CDMA changes in to master from donutburger.
Automated import of CL 144245
2009-04-02 11:00:57 -07:00
The Android Open Source Project
dd7bc3319d auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
The Android Open Source Project
e54eebbf1a auto import from //depot/cupcake/@135843 2009-03-03 18:29:04 -08:00
The Android Open Source Project
1b8e5a6b14 auto import from //branches/cupcake/...@131421 2009-02-13 12:57:54 -08:00
The Android Open Source Project
2eef60297a auto import from //branches/cupcake/...@126645 2009-01-15 16:12:14 -08:00
The Android Open Source Project
4f6e8d7a00 Initial Contribution 2008-10-21 07:00:00 -07:00