From c2ad8d4b00c4c559d9f68e04aae28dc0762e514b Mon Sep 17 00:00:00 2001 From: Raviteja Tamatam Date: Fri, 16 Oct 2020 15:07:02 +0530 Subject: [PATCH 1/2] ANDROID: ABI: update allowed list for QCOM Update the android/abi_gki_aarch64_qcom with recent symbol additions. No need to update the .xml file, as no new symbol addition. Bug: 171024164 Signed-off-by: Raviteja Tamatam Change-Id: I38fdb82878c578a19fb01df1e97eb7fafd7dac06 --- android/abi_gki_aarch64_qcom | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/android/abi_gki_aarch64_qcom b/android/abi_gki_aarch64_qcom index 9522a5ed5ad1..6c2539bdd013 100644 --- a/android/abi_gki_aarch64_qcom +++ b/android/abi_gki_aarch64_qcom @@ -574,6 +574,7 @@ dma_resv_test_signaled_rcu dma_resv_wait_timeout_rcu dma_set_coherent_mask + __dma_request_channel dma_set_mask do_exit do_wait_intr @@ -1333,11 +1334,18 @@ __mdiobus_register mdiobus_unregister media_create_pad_link + media_create_intf_link media_device_cleanup media_device_init __media_device_register + media_device_register_entity media_device_unregister + media_device_unregister_entity + media_devnode_create + media_devnode_remove media_entity_pads_init + media_entity_remove_links + media_remove_intf_links memblock_free memchr memcmp @@ -2679,7 +2687,9 @@ vb2_mmap vb2_ops_wait_finish vb2_ops_wait_prepare + vb2_plane_cookie vb2_plane_vaddr + vb2_prepare_buf vb2_poll vb2_qbuf vb2_querybuf @@ -2687,6 +2697,7 @@ vb2_queue_init vb2_queue_release vb2_reqbufs + vb2_request_object_is_buffer vb2_streamoff vb2_streamon vb2_vmalloc_memops From 8540985fd2ad34b2c6e055fb2a0bb33175f50b0d Mon Sep 17 00:00:00 2001 From: Riley Andrews Date: Fri, 2 Oct 2015 00:39:53 -0700 Subject: [PATCH 2/2] ANDROID: trace: sched: add sched blocked tracepoint which dumps out context of sleep. Declare war on uninterruptible sleep. Add a tracepoint which walks the kernel stack and dumps the first non-scheduler function called before the scheduler is invoked. Bug: 120445457 Change-Id: I19e965d5206329360a92cbfe2afcc8c30f65c229 Signed-off-by: Riley Andrews [astrachan: deleted an unnecessary whitespace change] Signed-off-by: Alistair Strachan Bug: 170916884 Signed-off-by: Todd Kjos --- include/trace/events/sched.h | 24 ++++++++++++++++++++++++ kernel/sched/fair.c | 1 + 2 files changed, 25 insertions(+) diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h index 420e80e56e55..202676bbbeb5 100644 --- a/include/trace/events/sched.h +++ b/include/trace/events/sched.h @@ -402,6 +402,30 @@ DEFINE_EVENT_SCHEDSTAT(sched_stat_template, sched_stat_blocked, TP_PROTO(struct task_struct *tsk, u64 delay), TP_ARGS(tsk, delay)); +/* + * Tracepoint for recording the cause of uninterruptible sleep. + */ +TRACE_EVENT(sched_blocked_reason, + + TP_PROTO(struct task_struct *tsk), + + TP_ARGS(tsk), + + TP_STRUCT__entry( + __field( pid_t, pid ) + __field( void*, caller ) + __field( bool, io_wait ) + ), + + TP_fast_assign( + __entry->pid = tsk->pid; + __entry->caller = (void *)get_wchan(tsk); + __entry->io_wait = tsk->in_iowait; + ), + + TP_printk("pid=%d iowait=%d caller=%pS", __entry->pid, __entry->io_wait, __entry->caller) +); + /* * Tracepoint for accounting runtime (time the task is executing * on a CPU). diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 1847651661e8..f78a92c2b54b 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -973,6 +973,7 @@ update_stats_enqueue_sleeper(struct cfs_rq *cfs_rq, struct sched_entity *se) } trace_sched_stat_blocked(tsk, delta); + trace_sched_blocked_reason(tsk); /* * Blocking time is in units of nanosecs, so shift by