diff options
author | Carlos Llamas <cmllamas@google.com> | 2023-12-01 20:21:55 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-12-05 03:23:40 +0300 |
commit | 162c79731448a5a052e93af7753df579dfe0bf7a (patch) | |
tree | d7f8aa2ec27f49810d6c0471f3612f9f4cd3ea71 /drivers/android/binder.c | |
parent | f07b83a48e944c8a1cc1e9f6703fae5e34df2ba4 (diff) | |
download | linux-162c79731448a5a052e93af7753df579dfe0bf7a.tar.xz |
binder: avoid user addresses in debug logs
Prefer logging vma offsets instead of addresses or simply drop the debug
log altogether if not useful. Note this covers the instances affected by
the switch to store addresses as unsigned long. However, there are other
sections in the driver that could do the same.
Signed-off-by: Carlos Llamas <cmllamas@google.com>
Reviewed-by: Alice Ryhl <aliceryhl@google.com>
Link: https://lore.kernel.org/r/20231201172212.1813387-27-cmllamas@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/android/binder.c')
-rw-r--r-- | drivers/android/binder.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/android/binder.c b/drivers/android/binder.c index 45674af6310f..c4bb18305e77 100644 --- a/drivers/android/binder.c +++ b/drivers/android/binder.c @@ -5980,9 +5980,9 @@ static void print_binder_transaction_ilocked(struct seq_file *m, } if (buffer->target_node) seq_printf(m, " node %d", buffer->target_node->debug_id); - seq_printf(m, " size %zd:%zd data %lx\n", + seq_printf(m, " size %zd:%zd offset %lx\n", buffer->data_size, buffer->offsets_size, - buffer->user_data); + proc->alloc.buffer - buffer->user_data); } static void print_binder_work_ilocked(struct seq_file *m, |