Skip to main content
Sign in
Snippets Groups Projects
Commit ee519781 authored by Divya Ponnusamy's avatar Divya Ponnusamy Committed by Pat Tjin
Browse files

staging: android: Change %p to %pK in debug messages


The format specifier %p can leak kernel addresses
while not valuing the kptr_restrict system settings.
Use %pK instead of %p, which also evaluates whether
kptr_restrict is set.

Bug: 30148243
Change-Id: Ib1adf14e9620ad7b1bd3e962001c852610210d46
Signed-off-by: default avatarDivya Ponnusamy <pdivya@codeaurora.org>
parent 2bb100e0
No related branches found
No related tags found
No related merge requests found
......@@ -611,14 +611,14 @@ int sync_fence_wait(struct sync_fence *fence, long timeout)
return err;
if (fence->status < 0) {
pr_info("fence error %d on [%p]\n", fence->status, fence);
pr_info("fence error %d on [%pK]\n", fence->status, fence);
sync_dump(fence);
return fence->status;
}
if (fence->status == 0) {
if (timeout > 0) {
pr_info("fence timeout on [%p] after %dms\n", fence,
pr_info("fence timeout on [%pK] after %dms\n", fence,
jiffies_to_msecs(timeout));
sync_dump(fence);
}
......@@ -914,7 +914,7 @@ static void sync_print_fence(struct seq_file *s, struct sync_fence *fence)
struct list_head *pos;
unsigned long flags;
seq_printf(s, "[%p] %s: %s\n", fence, fence->name,
seq_printf(s, "[%pK] %s: %s\n", fence, fence->name,
sync_status_str(fence->status));
list_for_each(pos, &fence->pt_list_head) {
......
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment