[v3,02/11] core/lock: Use try_lock_caller() in lock_caller() to capture owner

Message ID 20181009073237.16251-3-andrew@aj.id.au
State Accepted
Headers show
Series
  • Add and integrate an IPMI flash implementation
Related show

Checks

Context Check Description
snowpatch_ozlabs/apply_patch success master/apply_patch Successfully applied

Commit Message

Andrew Jeffery Oct. 9, 2018, 7:32 a.m.
Otherwise we can get reports of core/lock.c owning the lock, which is
not helpful when tracking down ownership issues.

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
---
 core/lock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/core/lock.c b/core/lock.c
index fca8f465f262..a26d6621bbd0 100644
--- a/core/lock.c
+++ b/core/lock.c
@@ -230,7 +230,7 @@  void lock_caller(struct lock *l, const char *owner)
 
 	lock_check(l);
 
-	if (try_lock(l))
+	if (try_lock_caller(l, owner))
 		return;
 	add_lock_request(l);