msleep() with PDROP
msleep() with PDROP
- Subject: msleep() with PDROP
- From: Rick Macklem <email@hidden>
- Date: Sun, 9 Dec 2007 16:08:51 -0500 (EST)
In various places in the xnu kernel I see code like the following:
#1 msleep(<event>, my_mutex, PDROP, "mysleep", 0);
lck_mtx_lock(my_mutex);
So, why do the above instead of:
#2 msleep(<event>, my_mutex, 0, "mysleep", 0);
My understanding was that msleep() would release the mutex and then
re-acquire it, if PDROP isn't specified.
Is there any fundamental difference between door #1 and door #2?
Thanks in advance for any info, rick
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden