Unverified Commit 9632dafe authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files
parents 42fe67fa 63a5782f
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -880,6 +880,16 @@ binder_enqueue_thread_work_ilocked(struct binder_thread *thread,
{
	WARN_ON(!list_empty(&thread->waiting_thread_node));
	binder_enqueue_work_ilocked(work, &thread->todo);

	/* (e)poll-based threads require an explicit wakeup signal when
	 * queuing their own work; they rely on these events to consume
	 * messages without I/O block. Without it, threads risk waiting
	 * indefinitely without handling the work.
	 */
	if (thread->looper & BINDER_LOOPER_STATE_POLL &&
	    thread->pid == current->pid && !thread->process_todo)
		wake_up_interruptible_sync(&thread->wait);

	thread->process_todo = true;
}