ANDROID: init_task: Init android vendor and oem data
Without initialization, it will be random data and hard for vendor hook to decide. Bug: 207739506 Change-Id: I278772d87eea38c03a40d4f0bef20ac8644e2ecd Signed-off-by: Maria Yu <quic_aiquny@quicinc.com>
This commit is contained in:
@@ -213,6 +213,8 @@ struct task_struct init_task
|
|||||||
#ifdef CONFIG_SECCOMP_FILTER
|
#ifdef CONFIG_SECCOMP_FILTER
|
||||||
.seccomp = { .filter_count = ATOMIC_INIT(0) },
|
.seccomp = { .filter_count = ATOMIC_INIT(0) },
|
||||||
#endif
|
#endif
|
||||||
|
.android_vendor_data1 = {0, },
|
||||||
|
.android_oem_data1 = {0, },
|
||||||
};
|
};
|
||||||
EXPORT_SYMBOL(init_task);
|
EXPORT_SYMBOL(init_task);
|
||||||
|
|
||||||
|
@@ -978,6 +978,8 @@ static struct task_struct *dup_task_struct(struct task_struct *orig, int node)
|
|||||||
#ifdef CONFIG_MEMCG
|
#ifdef CONFIG_MEMCG
|
||||||
tsk->active_memcg = NULL;
|
tsk->active_memcg = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
memset(&tsk->android_vendor_data1, 0, sizeof(tsk->android_vendor_data1));
|
||||||
|
memset(&tsk->android_oem_data1, 0, sizeof(tsk->android_oem_data1));
|
||||||
trace_android_vh_dup_task_struct(tsk, orig);
|
trace_android_vh_dup_task_struct(tsk, orig);
|
||||||
return tsk;
|
return tsk;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user