ANDROID: fork: Export task_newtask tracepoint
android_rvh_sched_fork() and android_rvh_sched_fork_init() already let us register probes during fork(), but those are invoked *before* the new task is added to the tasklist, which can lead to some undesired races when a module is trying to initialize vendor-specific task_struct fields. Export the task_newtask tracepoint to register probes to run during fork() but *after* the task has been inserted into the tasklist. Bug: 192873984 Signed-off-by: Jing-Ting Wu <Jing-Ting.Wu@mediatek.com> Cc: Valentin Schneider <valentin.schneider@arm.com> Change-Id: Ifef14819264385b5e955a5966b4e4f66d50da5e3
This commit is contained in:
@@ -121,6 +121,8 @@
|
|||||||
*/
|
*/
|
||||||
#define MAX_THREADS FUTEX_TID_MASK
|
#define MAX_THREADS FUTEX_TID_MASK
|
||||||
|
|
||||||
|
EXPORT_TRACEPOINT_SYMBOL_GPL(task_newtask);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Protected counters by write_lock_irq(&tasklist_lock)
|
* Protected counters by write_lock_irq(&tasklist_lock)
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user