diff --git a/drivers/android/binder.c b/drivers/android/binder.c index f39f52f378c1..4f89346dd283 100644 --- a/drivers/android/binder.c +++ b/drivers/android/binder.c @@ -3385,6 +3385,8 @@ static void binder_transaction(struct binder_proc *proc, t->from = thread; else t->from = NULL; + t->from_pid = proc->pid; + t->from_tid = thread->pid; t->sender_euid = task_euid(proc->tsk); t->to_proc = target_proc; t->to_thread = target_thread; @@ -6190,8 +6192,8 @@ static void print_binder_transaction_ilocked(struct seq_file *m, seq_printf(m, "%s %d: %pK from %d:%d to %d:%d code %x flags %x pri %d:%d r%d elapsed %lldms", prefix, t->debug_id, t, - t->from ? t->from->proc->pid : 0, - t->from ? t->from->pid : 0, + t->from_pid, + t->from_tid, to_proc ? to_proc->pid : 0, t->to_thread ? t->to_thread->pid : 0, t->code, t->flags, t->priority.sched_policy, diff --git a/drivers/android/binder_internal.h b/drivers/android/binder_internal.h index b3640301bce8..439c8c2403c3 100644 --- a/drivers/android/binder_internal.h +++ b/drivers/android/binder_internal.h @@ -552,6 +552,8 @@ struct binder_transaction { int debug_id; struct binder_work work; struct binder_thread *from; + pid_t from_pid; + pid_t from_tid; struct binder_transaction *from_parent; struct binder_proc *to_proc; struct binder_thread *to_thread;