summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_aops.c
diff options
context:
space:
mode:
authorDarrick J. Wong2018-01-09 21:02:55 +0100
committerDarrick J. Wong2018-01-12 23:09:08 +0100
commitc96900435fa9fdfd9702a60cd765bd85e380303e (patch)
treebbda292a21a12d0e37644506400a65b5acdb5c81 /fs/xfs/xfs_aops.c
parentxfs: use %pS printk format for direct instruction addresses (diff)
downloadkernel-qcow2-linux-c96900435fa9fdfd9702a60cd765bd85e380303e.tar.gz
kernel-qcow2-linux-c96900435fa9fdfd9702a60cd765bd85e380303e.tar.xz
kernel-qcow2-linux-c96900435fa9fdfd9702a60cd765bd85e380303e.zip
xfs: use %px for data pointers when debugging
Starting with commit 57e734423ad ("vsprintf: refactor %pK code out of pointer"), the behavior of the raw '%p' printk format specifier was changed to print a 32-bit hash of the pointer value to avoid leaking kernel pointers into dmesg. For most situations that's good. This is /undesirable/ behavior when we're trying to debug XFS, however, so define a PTR_FMT that prints the actual pointer when we're in debug mode. Note that %p for tracepoints still prints the raw pointer, so in the long run we could consider rewriting some of these messages as tracepoints. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/xfs_aops.c')
-rw-r--r--fs/xfs/xfs_aops.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c
index 4fc526a27a94..2e094c76bd45 100644
--- a/fs/xfs/xfs_aops.c
+++ b/fs/xfs/xfs_aops.c
@@ -791,7 +791,7 @@ xfs_aops_discard_page(
goto out_invalidate;
xfs_alert(ip->i_mount,
- "page discard on page %p, inode 0x%llx, offset %llu.",
+ "page discard on page "PTR_FMT", inode 0x%llx, offset %llu.",
page, ip->i_ino, offset);
xfs_ilock(ip, XFS_ILOCK_EXCL);