lkml.org 
[lkml]   [2022]   [Nov]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH v2 0/1] binder: return pending info for frozen async txns
Date
From: Li Li <dualli@google.com>

User applications need to know if their binder transactions reach a
frozen process or not. For sync binder calls, Linux kernel already
has a dedicated return value BR_FROZEN_REPLY, indicating this sync
binder transaction will be rejected (similar to BR_DEAD_REPLY) as the
target process is frozen. But for async binder calls, the user space
application doesn't have a way to know if the target process is frozen.

This patch adds a new return value, BR_TRANSACTION_PENDING, to fix this
issue. Similar to BR_TRANSACTION_COMPLETE, it means the async binder
transaction has been put in the queue of the target process, but it's
waiting for the target process to be unfrozen.

v1: checkpatch.pl --strict passed
v2: protect proc->is_frozen with lock, fix typo in comments

Li Li (1):
binder: return pending info for frozen async txns

drivers/android/binder.c | 31 +++++++++++++++++++++++------
drivers/android/binder_internal.h | 3 ++-
include/uapi/linux/android/binder.h | 7 ++++++-
3 files changed, 33 insertions(+), 8 deletions(-)

--
2.38.1.431.g37b22c650d-goog

\
 
 \ /
  Last update: 2022-11-10 21:34    [W:0.041 / U:4.324 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site