summaryrefslogtreecommitdiffstats
path: root/init/Android.mk
diff options
context:
space:
mode:
authorJosh Gao <jmgao@google.com>2017-03-28 13:07:15 -0700
committerJosh Gao <jmgao@google.com>2017-04-06 15:00:52 -0700
commitbf2dd482412cb7b93f52d2ed2d9be9a32fa8d2f9 (patch)
tree13e597ec30c32adb760606ef1ddb99bc0a989aa4 /init/Android.mk
parentebc87c98e35327e7403ed767c935a8e6a02b6f03 (diff)
downloadcore-bf2dd482412cb7b93f52d2ed2d9be9a32fa8d2f9.tar.gz
core-bf2dd482412cb7b93f52d2ed2d9be9a32fa8d2f9.tar.bz2
core-bf2dd482412cb7b93f52d2ed2d9be9a32fa8d2f9.zip
crash_dump: during early boot, output to kmsg on userdebug.
Crashes that happen before tombstoned is running are extremely hard to diagnose, because tombstones aren't written to disk, and the window of opportunity to get logs via `adb logcat` is small (potentially nonexistent). Solve this by adding a world-writable /dev/kmsg_debug on userdebug builds, and writing to it in addition to logcat when tombstoned hasn't started yet. Bug: http://b/36574794 Test: stop tombstoned; crasher; dmesg Change-Id: Ib22c02a002afb602933155fb2c9b7a8abbe9ed38
Diffstat (limited to 'init/Android.mk')
-rw-r--r--init/Android.mk6
1 files changed, 4 insertions, 2 deletions
diff --git a/init/Android.mk b/init/Android.mk
index 1ca88d7c5..61c2ec8f1 100644
--- a/init/Android.mk
+++ b/init/Android.mk
@@ -8,12 +8,14 @@ ifneq (,$(filter userdebug eng,$(TARGET_BUILD_VARIANT)))
init_options += \
-DALLOW_LOCAL_PROP_OVERRIDE=1 \
-DALLOW_PERMISSIVE_SELINUX=1 \
- -DREBOOT_BOOTLOADER_ON_PANIC=1
+ -DREBOOT_BOOTLOADER_ON_PANIC=1 \
+ -DWORLD_WRITABLE_KMSG=1
else
init_options += \
-DALLOW_LOCAL_PROP_OVERRIDE=0 \
-DALLOW_PERMISSIVE_SELINUX=0 \
- -DREBOOT_BOOTLOADER_ON_PANIC=0
+ -DREBOOT_BOOTLOADER_ON_PANIC=0 \
+ -DWORLD_WRITABLE_KMSG=0
endif
ifneq (,$(filter eng,$(TARGET_BUILD_VARIANT)))