Merge "Check mm_events persistent property after persistent properties are ready during boot." into main am: 80f53f4d05
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/2954641
Change-Id: Ia097616f74fc190e14718d89b5da9671844fcaf1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/cmds/atrace/atrace.rc b/cmds/atrace/atrace.rc
index 9b357e7..fdac5db 100644
--- a/cmds/atrace/atrace.rc
+++ b/cmds/atrace/atrace.rc
@@ -319,7 +319,7 @@
# Only create the tracing instance if persist.mm_events.enabled
# Attempting to remove the tracing instance after it has been created
# will likely fail with EBUSY as it would be in use by traced_probes.
-on post-fs-data && property:persist.mm_events.enabled=true
+on mm_events_property_available && property:persist.mm_events.enabled=true
# Create MM Events Tracing Instance for Kmem Activity Trigger
mkdir /sys/kernel/debug/tracing/instances/mm_events 0755 system system
mkdir /sys/kernel/tracing/instances/mm_events 0755 system system
@@ -404,6 +404,9 @@
chmod 0666 /sys/kernel/debug/tracing/instances/mm_events/per_cpu/cpu23/trace
chmod 0666 /sys/kernel/tracing/instances/mm_events/per_cpu/cpu23/trace
+on property:ro.persistent_properties.ready=true
+ trigger mm_events_property_available
+
# Handle hyp tracing instance
on late-init && property:ro.boot.hypervisor.vm.supported=1