Skip to content
Commit 86bb2d06 authored by Anas Nashif's avatar Anas Nashif
Browse files

kernel: mutex: add error checking



k_mutex_unlock will now perform error checking and return on failures.

If the current thread does not own the mutex, we will now return -EPERM.
In the unlikely situation where we own a lock and the lock count is
zero, we assert. This is considered an undefined bahviour and should not
happen.

Signed-off-by: default avatarAnas Nashif <anas.nashif@intel.com>
parent 22b95a20
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment