From 3b5a94c0bcd5be3d88ada907e638c338a21a6aff Mon Sep 17 00:00:00 2001 From: Todd Poynor Date: Sat, 21 Jul 2018 06:34:58 -0700 Subject: [PATCH] staging: gasket: print mmap starting address as unsigned long Page alignment error log should print the offending value as an unsigned long, not as a kernel pointer. Reported-by: Guenter Roeck Signed-off-by: Todd Poynor Signed-off-by: Greg Kroah-Hartman --- gasket_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gasket_core.c b/gasket_core.c index 5e269c4..cde9d85 100644 --- a/gasket_core.c +++ b/gasket_core.c @@ -1606,8 +1606,8 @@ static int gasket_mmap(struct file *filp, struct vm_area_struct *vma) if (vma->vm_start & ~PAGE_MASK) { gasket_log_error( - gasket_dev, "Base address not page-aligned: 0x%p\n", - (void *)vma->vm_start); + gasket_dev, "Base address not page-aligned: 0x%lx\n", + vma->vm_start); trace_gasket_mmap_exit(-EINVAL); return -EINVAL; }