Machine-translated by Google. Questions are authored in English.
Top

Discussion

A mutex differs from a binary semaphore chiefly in having

  • A.a timeout that cannot be specified by the caller
  • B.an owner, so only the taking task may release it
  • C.a count that may rise above one
  • D.no ability to block a task that finds it taken

Answer: B

Ownership is what lets the kernel apply priority inheritance and what makes releasing another task's lock an error rather than a legal operation. A semaphore has no owner, which is exactly why it suits signalling between two different tasks.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.