mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-05-14 06:49:16 +08:00
rtems-bsd-mutex: Update due to API changes
This commit is contained in:
parent
34545adafd
commit
87e3b46296
@ -51,14 +51,16 @@ rtems_bsd_mutex_lock_more(struct lock_object *lock, rtems_bsd_mutex *m,
|
|||||||
BSD_ASSERT(lock->lo_flags & LO_RECURSABLE);
|
BSD_ASSERT(lock->lo_flags & LO_RECURSABLE);
|
||||||
++m->nest_level;
|
++m->nest_level;
|
||||||
|
|
||||||
_Thread_queue_Release(&m->queue, &queue_context->Lock_context);
|
_Thread_queue_Release(&m->queue, queue_context);
|
||||||
} else {
|
} else {
|
||||||
_Thread_queue_Context_set_expected_level(queue_context, 1);
|
_Thread_queue_Context_set_thread_state(queue_context,
|
||||||
|
STATES_WAITING_FOR_SYS_LOCK_MUTEX);
|
||||||
_Thread_queue_Context_set_no_timeout(queue_context);
|
_Thread_queue_Context_set_no_timeout(queue_context);
|
||||||
|
_Thread_queue_Context_set_do_nothing_enqueue_callout(
|
||||||
|
queue_context);
|
||||||
_Thread_queue_Context_set_deadlock_callout(queue_context,
|
_Thread_queue_Context_set_deadlock_callout(queue_context,
|
||||||
_Thread_queue_Deadlock_fatal);
|
_Thread_queue_Deadlock_fatal);
|
||||||
_Thread_queue_Enqueue_critical(&m->queue.Queue,
|
_Thread_queue_Enqueue(&m->queue.Queue,
|
||||||
RTEMS_BSD_MUTEX_TQ_OPERATIONS, executing,
|
RTEMS_BSD_MUTEX_TQ_OPERATIONS, executing, queue_context);
|
||||||
STATES_WAITING_FOR_SYS_LOCK_MUTEX, queue_context);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user