Gilad Ben-Yossef wrote: > > As far as I udnerstand, if you sleep between mutex unlock and lock > (not a tight loop), > the fairness should be depedant on the task scheduler. The mutex is > then as fair as the scheduler is fair. Whether the Linux scheduler is > fair or not is a completly different question :-) > > But yes, I'd expact it to work as you want it to work in that case. > Does it? For "sleep", it does. I'm a little more worried about what happens if I were busy (but outside of the lock). I guess the answer is that if I spend 10% of the time inside the lock and 90% outside, then there is a 90% chance that my slice will be up when I don't have the lock, and someone who does need the lock will get control, which is ok. A 90% chance of switching is reasonable as far as starvation prevention is concerned. > > Gilad > Shachar
================================================================= To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]