Skip to contentSkip to conversation

locks: fix generic_delete_lease tracepoint to use victim pointer

PATCH New Jeff Layton 1 participant 1 message Mar 7, 2015

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 locks: fix generic_delete_lease tracepoint to use victim pointer

It's possible that "fl" won't point at a valid lock at this point, so have it instead point at "victim" which is either a valid lock or NULL.

---
 fs/locks.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/locks.c +1 -1
index 8f61ad524e3e..0915a3ead897 100644
@@ -1732,7 +1732,7 @@ static int generic_delete_lease(struct file *filp, void *owner)
 			break;
 		}
 	}
-	trace_generic_delete_lease(inode, fl);
+	trace_generic_delete_lease(inode, victim);
 	if (victim)
 		error = fl->fl_lmops->lm_change(victim, F_UNLCK, &dispose);
 	spin_unlock(&ctx->flc_lock);
Signature · 1 line
2.1.0