diff --git a/drivers/android/vendor_hooks.c b/drivers/android/vendor_hooks.c index d87dbd27a382..74821c4dee98 100644 --- a/drivers/android/vendor_hooks.c +++ b/drivers/android/vendor_hooks.c @@ -154,6 +154,7 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_f2fs_restore_priority); EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_f2fs_printk); EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_f2fs_create); EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_io_statistics); +EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_dpm_prepare); EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_ogki_check_vip_status); EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_ogki_task_util); EXPORT_TRACEPOINT_SYMBOL_GPL(android_rvh_ogki_uclamp_task_util); diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c index 4c3043f11d93..cc4fb6c83db0 100644 --- a/drivers/base/power/main.c +++ b/drivers/base/power/main.c @@ -1869,7 +1869,9 @@ int dpm_prepare(pm_message_t state) * disable probing of devices. This sync point is important at least * at boot time + hibernation restore. */ + trace_android_rvh_dpm_prepare(0); wait_for_device_probe(); + trace_android_rvh_dpm_prepare(1); /* * It is unsafe if probing of devices will happen during suspend or * hibernation and system behavior will be unpredictable in this case. diff --git a/include/trace/hooks/dtask.h b/include/trace/hooks/dtask.h index 52aae20f7136..628ff9d7e789 100644 --- a/include/trace/hooks/dtask.h +++ b/include/trace/hooks/dtask.h @@ -146,6 +146,10 @@ DECLARE_HOOK(android_vh_record_pcpu_rwsem_starttime, DECLARE_HOOK(android_vh_exit_check, TP_PROTO(struct task_struct *p), TP_ARGS(p)); + +DECLARE_RESTRICTED_HOOK(android_rvh_dpm_prepare, + TP_PROTO(int flag), + TP_ARGS(flag), 1); #endif /* _TRACE_HOOK_DTASK_H */ /* This part must be outside protection */