Skip to content

Commit 48dc1c3

Browse files
Carlos Llamasgregkh
authored andcommitted
binder: log transaction code on failure
When a transaction fails, log the 'tr->code' to help indentify the problematic userspace call path. This additional information will simplify debugging efforts. Cc: Steven Moreland <[email protected]> Signed-off-by: Carlos Llamas <[email protected]> Reviewed-by: Alice Ryhl <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent be887fc commit 48dc1c3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/android/binder.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3801,13 +3801,13 @@ static void binder_transaction(struct binder_proc *proc,
38013801
}
38023802

38033803
binder_debug(BINDER_DEBUG_FAILED_TRANSACTION,
3804-
"%d:%d transaction %s to %d:%d failed %d/%d/%d, size %lld-%lld line %d\n",
3804+
"%d:%d transaction %s to %d:%d failed %d/%d/%d, code %u size %lld-%lld line %d\n",
38053805
proc->pid, thread->pid, reply ? "reply" :
38063806
(tr->flags & TF_ONE_WAY ? "async" : "call"),
38073807
target_proc ? target_proc->pid : 0,
38083808
target_thread ? target_thread->pid : 0,
38093809
t_debug_id, return_error, return_error_param,
3810-
(u64)tr->data_size, (u64)tr->offsets_size,
3810+
tr->code, (u64)tr->data_size, (u64)tr->offsets_size,
38113811
return_error_line);
38123812

38133813
if (target_thread)

0 commit comments

Comments
 (0)