diff options
| author | Manu Gautam <mgautam@codeaurora.org> | 2017-02-24 15:22:40 +0530 |
|---|---|---|
| committer | Moyster <oysterized@gmail.com> | 2018-11-27 16:09:55 +0100 |
| commit | 513cef2c53c2b3846f6c571823412f514b6f66c7 (patch) | |
| tree | 91c79e2c53b67916729fbfea3150bf7d9571bbdc /drivers/usb/host/whci/debug.c | |
| parent | b32e2d51665e3b6af648dec474db214b6312d967 (diff) | |
| download | android_kernel_m2note-513cef2c53c2b3846f6c571823412f514b6f66c7.tar.gz | |
usb: replace %p with %pK
Format specifier %p can leak kernel addresses while not valuing the
kptr_restrict system settings. When kptr_restrict is set to (1), kernel
pointers printed using the %pK format specifier will be replaced with 0's.
Debugging Note : &pK prints only Zeros as address. If you need actual
address information, write 0 to kptr_restrict.
echo 0 > /proc/sys/kernel/kptr_restrict
CRs-fixed: 1052849
Change-Id: I0e98145730380ea983fa8f46a28d15dd6c2c31df
Signed-off-by: Manu Gautam <mgautam@codeaurora.org>
Signed-off-by: Yasir Malik <ymalik@codeaurora.org>
Signed-off-by: Kevin F. Haggerty <haggertk@lineageos.org>
Diffstat (limited to 'drivers/usb/host/whci/debug.c')
| -rw-r--r-- | drivers/usb/host/whci/debug.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/host/whci/debug.c b/drivers/usb/host/whci/debug.c index ba61dae9e..f541308be 100644 --- a/drivers/usb/host/whci/debug.c +++ b/drivers/usb/host/whci/debug.c @@ -68,7 +68,7 @@ static void qset_print(struct seq_file *s, struct whc_qset *qset) list_for_each_entry(std, &qset->stds, list_node) { if (urb != std->urb) { urb = std->urb; - seq_printf(s, " urb %p transferred: %d bytes\n", urb, + seq_printf(s, " urb %pK transferred: %d bytes\n", urb, urb->actual_length); } if (std->qtd) |
