xfs: enable buffer deadlock postmortem diagnosis via ftrace
authorDarrick J. Wong <darrick.wong@oracle.com>
Tue, 21 Jun 2016 01:53:28 +0000 (11:53 +1000)
committerDave Chinner <david@fromorbit.com>
Tue, 21 Jun 2016 01:53:28 +0000 (11:53 +1000)
commit479c641273df632478cda7fe76b833df64e319bc
treefcfade01ced0f2aab76e3366aaba93ad3d574acc
parent3f94c441e2c3dea029a46a2326b2170acf2c7713
xfs: enable buffer deadlock postmortem diagnosis via ftrace

Create a second buf_trylock tracepoint so that we can distinguish
between a successful and a failed trylock.  With this piece, we can
use a script to look at the ftrace output to detect buffer deadlocks.

[dchinner: update to if/else as per hch's suggestion]

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Dave Chinner <david@fromorbit.com>
fs/xfs/xfs_buf.c
fs/xfs/xfs_trace.h