-<h2>lock_set_create</h2>\r<hr>\r<p>\r<strong>Function</strong> - Create a new lock set.\r<h3>SYNOPSIS</h3>\r<pre>\r<strong>kern_return_t lock_set_create</strong>\r <strong>(task_t</strong> <var>task</var>,\r <strong>lock_set_t</strong> <var>lock_set</var>,\r <strong>int</strong> <var>locks</var>,\r <strong>int</strong> <var>policy</var><strong>);</strong>\r</pre>\r<h3>PARAMETERS</h3>\r<dl>\r<p>\r<dt> <var>task</var>\r<dd>\rThe task receiving the send right to the newly created lock set.\r<p>\r<dt> <var>lock_set</var>\r<dd>\r[out send right] The port naming the lock set which represents the lock.\r<p>\r<dt> <var>locks</var>\r<dd>\r[in scalar] The number of locks the lock set will represent (must be a positive value).\r<p>\r<dt> <var>policy</var>\r<dd>\r[in scalar] The blocked thread wakeup policy for the newly created lock set. Valid policies are:\r <dl>\r<p>\r<dt> SYNC_POLICY_FIFO\r<dd>\ra first-in-first-out policy for scheduling thread wakeup.\r<p>\r<dt> SYNC_POLICY_FIXED_PRIORITY\r<dd>\ra fixed priority policy for scheduling thread wakeup.\r</dl>\r</dl>\r<h3>DESCRIPTION</h3>\r<p>\rThe <strong>lock_set_create</strong> function creates a new lock set representing a\rcollection of associated locks. The lock set is associated with the\rspecified task. A send right naming the lock set is returned to the\rcaller.\r<h3>RETURN VALUES</h3>\r<dl>\r<p>\r<dt> <strong>KERN_SUCCESS</strong>\r<dd>\rThe lock set was created.\r<p>\r<dt> <strong>KERN_INVALID_ARGUMENT</strong>\r<dd>\rEither the task or policy argument is invalid, or the locks argument\rhas a value that is less than or equal to zero.\r<p>\r<dt> <strong>KERN_RESOURCE_SHORTAGE</strong>\r<dd>\rThe kernel could not allocate the lock set.\r</dl>\r<h3>RELATED INFORMATION</h3>\r<p>\rFunctions:\r<a href="lock_acquire.html"><strong>lock_acquire</strong></a>,\r<a href="lock_make_stable.html"><strong>lock_make_stable</strong></a>,\r<a href="lock_try.html"><strong>lock_try</strong></a>,\r<a href="lock_handoff.html"><strong>lock_handoff</strong></a>,\r<a href="lock_handoff_accept.html"><strong>lock_handoff_accept</strong></a>,\r<a href="lock_try.html"><strong>lock_try</strong></a>,\r<a href="lock_set_destroy.html"><strong>lock_set_destroy</strong></a>.\r
\ No newline at end of file
+<h2>lock_set_create</h2>
+<hr>
+<p>
+<strong>Function</strong> - Create a new lock set.
+<h3>SYNOPSIS</h3>
+<pre>
+<strong>kern_return_t lock_set_create</strong>
+ <strong>(task_t</strong> <var>task</var>,
+ <strong>lock_set_t</strong> <var>lock_set</var>,
+ <strong>int</strong> <var>locks</var>,
+ <strong>int</strong> <var>policy</var><strong>);</strong>
+</pre>
+<h3>PARAMETERS</h3>
+<dl>
+<p>
+<dt> <var>task</var>
+<dd>
+The task receiving the send right to the newly created lock set.
+<p>
+<dt> <var>lock_set</var>
+<dd>
+[out send right] The port naming the lock set which represents the lock.
+<p>
+<dt> <var>locks</var>
+<dd>
+[in scalar] The number of locks the lock set will represent (must be a positive value).
+<p>
+<dt> <var>policy</var>
+<dd>
+[in scalar] The blocked thread wakeup policy for the newly created lock set. Valid policies are:
+ <dl>
+<p>
+<dt> SYNC_POLICY_FIFO
+<dd>
+a first-in-first-out policy for scheduling thread wakeup.
+<p>
+<dt> SYNC_POLICY_FIXED_PRIORITY
+<dd>
+a fixed priority policy for scheduling thread wakeup.
+</dl>
+</dl>
+<h3>DESCRIPTION</h3>
+<p>
+The <strong>lock_set_create</strong> function creates a new lock set representing a
+collection of associated locks. The lock set is associated with the
+specified task. A send right naming the lock set is returned to the
+caller.
+<h3>RETURN VALUES</h3>
+<dl>
+<p>
+<dt> <strong>KERN_SUCCESS</strong>
+<dd>
+The lock set was created.
+<p>
+<dt> <strong>KERN_INVALID_ARGUMENT</strong>
+<dd>
+Either the task or policy argument is invalid, or the locks argument
+has a value that is less than or equal to zero.
+<p>
+<dt> <strong>KERN_RESOURCE_SHORTAGE</strong>
+<dd>
+The kernel could not allocate the lock set.
+</dl>
+<h3>RELATED INFORMATION</h3>
+<p>
+Functions:
+<a href="lock_acquire.html"><strong>lock_acquire</strong></a>,
+<a href="lock_make_stable.html"><strong>lock_make_stable</strong></a>,
+<a href="lock_try.html"><strong>lock_try</strong></a>,
+<a href="lock_handoff.html"><strong>lock_handoff</strong></a>,
+<a href="lock_handoff_accept.html"><strong>lock_handoff_accept</strong></a>,
+<a href="lock_try.html"><strong>lock_try</strong></a>,
+<a href="lock_set_destroy.html"><strong>lock_set_destroy</strong></a>.