CS FundamentalsHardGATE CS

Priority inversion: low-priority L holds a mutex needed by high-priority H, and medium-priority M (which does not need the mutex) keeps preempting L. Which protocol bounds H's blocking to the length of L's critical section?

  1. A. Giving M a time quantum
  2. B. Aging H's priority upward
  3. C. Making the mutex a spinlock
  4. D. Priority inheritance: L temporarily runs at H's priority while holding the mutex

Correct answer: D. Priority inheritance: L temporarily runs at H's priority while holding the mutex

Raising L to H's priority prevents M from preempting L, so L finishes its critical section quickly and releases the mutex. This was the fix applied on the Mars Pathfinder lander.

More Operating Systems questions

Exams that ask this topic