aboutsummaryrefslogtreecommitdiff
path: root/car_product/init/init.bootstat.rc
blob: 430a96b0dc6c64c97d93a7c558c33159da62bf17 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Copyright (C) 2016 The Android Open Source Project
#
# IMPORTANT: Do not create world writable files or directories.
# This is a common source of Android security bugs.
#
on post-fs-data
    mkdir /data/misc/bootstat 0700 root root

# Record the time at which the user has successfully entered the pin to decrypt
# the device, /data is decrypted, and the system is entering the main boot phase.
#
# post-fs-data: /data is writable
# property:init.svc.bootanim=running: The boot animation is running
on post-fs-data && property:init.svc.bootanim=running
    exec - root root -- /system/bin/bootstat -r post_decrypt_time_elapsed

# Boot animation stopped, is considered the point at which
# the user may interact with the device, so it is a good proxy for the boot
# complete signal.
on property:init.svc.bootanim=stopped
    # Record boot_complete and related stats (decryption, etc).
    exec - root root -- /system/bin/bootstat --record_boot_complete

on property:dev.bootcomplete=1
    exec - root root -- /system/bin/bootstat -r dev_bootcomplete
    # Log all boot events.
    exec - root root -- /system/bin/bootstat -l

on property:boot.car_service_created=1
    exec - root root -- /system/bin/bootstat -r car_service_created

on property:init.svc.zygote=running
    exec - root root -- /system/bin/bootstat -r zygote_running