Mutex Lock
What is the differnce with mutex lock?
- Mutex lock is used solely to provide mutual exclusion.
Has these fields
bool avail; // resource available ?
Task * owner; // lock owner
queue<Task> blocked;
SpinLock lock;The binary semaphore has the same fields, but we don’t keep track of the owner.