Skip to contentSkip to conversation

backports: add missing returns on ww_mutex backpots

PATCH New Luis R. Rodriguez 1 participant 1 message Aug 28, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 backports: add missing returns on ww_mutex backpots

From: "Luis R. Rodriguez" <[email protected]>

Two returns were missing on the ww_mutex backport, add these. The enhancements are not supported on older kernels so just bail out early.

---
 backport/compat/kernel/ww_mutex.c |    2 ++
 1 file changed, 2 insertions(+)
backport/compat/kernel/ww_mutex.c +2 -0
index 257c2a4..204ac8f 100644
@@ -206,10 +206,12 @@ static void mspin_unlock(struct mspin_node **lock, struct mspin_node *node)
 
 static inline bool owner_running(struct mutex *lock, struct task_struct *owner)
 {
+	return false;
 }
 
 int mutex_spin_on_owner(struct mutex *lock, struct task_struct *owner)
 {
+	return 1;
 }
 
 static inline int mutex_can_spin_on_owner(struct mutex *lock)
Signature · 1 line
1.7.10.4