From f27a0fe083bf46fef0d7045aa2e9a7e56e72d8d8 Mon Sep 17 00:00:00 2001 From: Jeff Layton Date: Thu, 7 Jan 2016 15:08:51 -0500 Subject: locks: pass inode pointer to locks_free_lock_context ...so we can print information about it if there are leaked locks. Signed-off-by: Jeff Layton Acked-by: "J. Bruce Fields" --- fs/locks.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'fs/locks.c') diff --git a/fs/locks.c b/fs/locks.c index 0af2387bd91e..ed9ab930d093 100644 --- a/fs/locks.c +++ b/fs/locks.c @@ -234,8 +234,10 @@ out: } void -locks_free_lock_context(struct file_lock_context *ctx) +locks_free_lock_context(struct inode *inode) { + struct file_lock_context *ctx = inode->i_flctx; + if (ctx) { WARN_ON_ONCE(!list_empty(&ctx->flc_flock)); WARN_ON_ONCE(!list_empty(&ctx->flc_posix)); -- cgit v1.2.3