summaryrefslogtreecommitdiff
path: root/firmware/kernel/mutex.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/kernel/mutex.c')
-rw-r--r--firmware/kernel/mutex.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/firmware/kernel/mutex.c b/firmware/kernel/mutex.c
index cb9e6816b8..b1ae3e9e54 100644
--- a/firmware/kernel/mutex.c
+++ b/firmware/kernel/mutex.c
@@ -39,6 +39,8 @@ void mutex_init(struct mutex *m)
39/* Gain ownership of a mutex object or block until it becomes free */ 39/* Gain ownership of a mutex object or block until it becomes free */
40void mutex_lock(struct mutex *m) 40void mutex_lock(struct mutex *m)
41{ 41{
42 ASSERT_CPU_MODE(CPU_MODE_THREAD_CONTEXT);
43
42 struct thread_entry *current = __running_self_entry(); 44 struct thread_entry *current = __running_self_entry();
43 45
44 if(current == m->blocker.thread) 46 if(current == m->blocker.thread)