summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorDeepak Kushwah <dkushwah@codeaurora.org>2017-08-17 16:46:03 +0530
committerDeepak Kushwah <dkushwah@codeaurora.org>2017-08-18 11:44:57 +0530
commita94bbf3797c9cef6802cc70d6a24bab8c9b2fc83 (patch)
treecae5b797193cc427e18ec1a8ed824568e85eea33 /drivers
parenta49bb61510b938152025049730fa922c5da950a1 (diff)
msm: vidc: use %pK instead of %p which respects kptr_restrict sysctl
Hide kernel pointers from unprivileged users by using %pK format- specifier instead of %p. This respects the kptr_restrict sysctl setting which is by default on. echo 0 to kptr_restrict to print proper kernel addresses. Change-Id: I6f14b039f2f193196edfce8160ae38341229085c Signed-off-by: Deepak Kushwah <dkushwah@codeaurora.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/platform/msm/vidc/msm_vidc_debug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/platform/msm/vidc/msm_vidc_debug.c b/drivers/media/platform/msm/vidc/msm_vidc_debug.c
index 5c13b6fef3ec..2be52b10c84b 100644
--- a/drivers/media/platform/msm/vidc/msm_vidc_debug.c
+++ b/drivers/media/platform/msm/vidc/msm_vidc_debug.c
@@ -445,7 +445,7 @@ struct dentry *msm_vidc_debugfs_init_inst(struct msm_vidc_inst *inst,
dprintk(VIDC_ERR, "Invalid params, inst: %pK\n", inst);
goto exit;
}
- snprintf(debugfs_name, MAX_DEBUGFS_NAME, "inst_%p", inst);
+ snprintf(debugfs_name, MAX_DEBUGFS_NAME, "inst_%pK", inst);
idata = kzalloc(sizeof(struct core_inst_pair), GFP_KERNEL);
if (!idata) {