9774df613409c91f01ced1483bc01f42f6b4bf63 |
|
15-Jan-2015 |
Christopher Ferris <cferris@google.com> |
Move 32 bit/64 bit check into debuggerd. On 64 bit systems, calls to dump_backtrace_to_file or dump_tombstone try and directly contact the correct debuggerd (32 bit vs 64 bit) by reading the elf information for the executable. Unfortunately, system_server makes a call to dump_backtrace_to_file and it doesn't have permissions to read the executable data, so it defaults to always contacting the 64 bit debuggerd. This CL changes the code so that all dump requests go to the 64 bit debuggerd, which reads the elf information and redirects requests for 32 bit processes to the 32 bit debuggerd. Testing: - Forced the watchdog code in system_server to dump stacks and verified that all native stacks are dumped correctly. - Verified that dumpstate and bugreport still properly dump the native processes on a 64 bit and 32 bit system. - Intentionally forced the 64 bit to 32 bit redirect to write only a byte at a time and verified there are no errors, and no dropped data. - Used debuggerd and debuggerd64 to dump 32 bit and 64 bit processes seemlessly. - Used debuggerd on a 32 bit system to dump native stacks. Bug: https://code.google.com/p/android/issues/detail?id=97024 Change-Id: Ie01945153bdc1c4ded696c7334b61d58575314d1
/system/core/include/cutils/debugger.h
|
fa41e0f5c8fd69d2871548338a0c20345ddd0b03 |
|
14-Jan-2015 |
Christopher Ferris <cferris@google.com> |
Add timed versions of stack dumping functions. Under some unknown circumstances, debuggerd could become unresponsive. If you try and take a bugreport during this time, it will hang forever. Adding functions that have a timeout will allow dumpstate to stop if dumping is taking too long. Bug: 18766581 (cherry picked from commit 5f2ff6a9106083e2a79b8600a0bf6a5341c6ca38) Change-Id: I39e8e9c60209e3ef9efac795fedb8e1edce2bd3e
/system/core/include/cutils/debugger.h
|
6bcc4acc6f0387f7907741de34c8c2d7e44c1dd7 |
|
12-Sep-2014 |
Christopher Ferris <cferris@google.com> |
Use the correct debuggerd given the tid. On 64 bit systems, calling dump_backtrace_to_file will automatically call debuggerd64. If the process to dump is actually 32 bit, this creates an unrecognizable dump backtrace. Modify the code to check the type of the process and connect to the appropriate debuggerd process. This change refactors both the tombstone and backtrace functionality to allow both to work properly on 64 bit systems when dealing with mixed processes. Bug: 17487122 (cherry picked from commit a9fa7b87f1aefd7b96f749a545d3385ad384c12b) Change-Id: I3c9e0212c8720877a6af092071a3695df2a36df8
/system/core/include/cutils/debugger.h
|
855fcc3114c20ff9fd286fe1723d1413fec9685a |
|
26-Apr-2014 |
Elliott Hughes <enh@google.com> |
Use the si_code value bionic passes us. Bionic needs to re-raise various signals, which means the si_code debuggerd sees has been clobbered. If bionic sends us the original si_code value, we can use that instead of the one we see when the ptrace the crashed process' siginfo. Change-Id: If116a6bc667d55a6fb39b74f96673292af4e4c8c
/system/core/include/cutils/debugger.h
|
e9edf7a0efd8c62dacab7bf765c8037d8a94c3bb |
|
01-Feb-2014 |
Elliott Hughes <enh@google.com> |
LP64 should have debuggerd and debuggerd64. Change-Id: I4e39c200e6867bb9a5bbcfec1c449b8864028feb
/system/core/include/cutils/debugger.h
|
707b8bbe1800dbebd932f54e86347563ee86c36e |
|
04-Apr-2013 |
Elliott Hughes <enh@google.com> |
Modify debuggerd to cope with the abort message. Bug: 8531731 Change-Id: I416ec1da38a8a1b0d0a582ccd7c8aaa681ed4a29
/system/core/include/cutils/debugger.h
|
053b865412d1982ad1dc0e840898d82527deeb99 |
|
07-Jun-2012 |
Jeff Brown <jeffbrown@google.com> |
Enhance native stack dumps. Provides a new mechanism for dumpstate (while running as root) to request that debuggerd dump the stacks of native processes that we care about in bug reports. In this mode, the backtrace is formatted to look similar to a Dalvik backtrace. Moved the tombstone generating code into a separate file to make it easier to maintain. Fixed a bug where sometimes the stack traces would be incomplete because we were not waiting for each thread to stop after issuing PTRACE_ATTACH, only the main thread. So sometimes we were missing traces for some threads. Refactored the logging code to prevent accidentally writing data to logcat when explicitly dumping a tombstone or backtrace from the console. Only root or system server can request to dump backtraces but only root can dump tombstones. Bug: 6615693 Change-Id: Ib3edcc16f9f3a687e414e3f2d250d9500566123b
/system/core/include/cutils/debugger.h
|