1*4f1223e8SApple OSS Distributions<h2>ledger_create</h2> 2*4f1223e8SApple OSS Distributions<hr> 3*4f1223e8SApple OSS Distributions<p> 4*4f1223e8SApple OSS Distributions<strong>Function</strong> - Create a subordinate ledger. 5*4f1223e8SApple OSS Distributions<h3>SYNOPSIS</h3> 6*4f1223e8SApple OSS Distributions<pre> 7*4f1223e8SApple OSS Distributions<strong>kern_return_t ledger_create</strong> 8*4f1223e8SApple OSS Distributions <strong>(ledger_port_t</strong> <var>parent_ledger</var>, 9*4f1223e8SApple OSS Distributions <strong>ledger_port_t</strong> <var>ledger_ledger</var>, 10*4f1223e8SApple OSS Distributions <strong>ledger_port_t</strong> <var>child_ledger</var>, 11*4f1223e8SApple OSS Distributions <strong>ledger_item_t</strong> <var>transfer</var><strong>);</strong> 12*4f1223e8SApple OSS Distributions</pre> 13*4f1223e8SApple OSS Distributions<h3>PARAMETERS</h3> 14*4f1223e8SApple OSS Distributions<dl> 15*4f1223e8SApple OSS Distributions<p> 16*4f1223e8SApple OSS Distributions<dt> <var>parent_ledger</var> 17*4f1223e8SApple OSS Distributions<dd> 18*4f1223e8SApple OSS Distributions[in ledger send right] 19*4f1223e8SApple OSS DistributionsThe parent ledger. 20*4f1223e8SApple OSS Distributions<p> 21*4f1223e8SApple OSS Distributions<dt> <var>ledger_ledger</var> 22*4f1223e8SApple OSS Distributions<dd> 23*4f1223e8SApple OSS Distributions[in ledger send right] 24*4f1223e8SApple OSS DistributionsThe wired kernel memory ledger providing the 25*4f1223e8SApple OSS Distributionsspace from which the ledger itself is drawn. 26*4f1223e8SApple OSS Distributions<p> 27*4f1223e8SApple OSS Distributions<dt> <var>child_ledger</var> 28*4f1223e8SApple OSS Distributions<dd> 29*4f1223e8SApple OSS Distributions[out ledger send right] 30*4f1223e8SApple OSS DistributionsThe new child ledger, of the same resource type 31*4f1223e8SApple OSS Distributionsas the parent ledger. 32*4f1223e8SApple OSS Distributions<p> 33*4f1223e8SApple OSS Distributions<dt> <var>transfer</var> 34*4f1223e8SApple OSS Distributions<dd> 35*4f1223e8SApple OSS Distributions[in scalar] 36*4f1223e8SApple OSS DistributionsThe resource amount to transfer to the new ledger. 37*4f1223e8SApple OSS Distributions</dl> 38*4f1223e8SApple OSS Distributions<h3>DESCRIPTION</h3> 39*4f1223e8SApple OSS Distributions<p> 40*4f1223e8SApple OSS DistributionsThe <strong>ledger_create</strong> function creates a subordinate ledger. 41*4f1223e8SApple OSS DistributionsResource limits can be 42*4f1223e8SApple OSS Distributionstransferred from the parent ledger. The child ledger itself 43*4f1223e8SApple OSS Distributionsis accounted against 44*4f1223e8SApple OSS Distributionsthe <var>ledger_ledger</var>. A new ledger inherits the remote service port. 45*4f1223e8SApple OSS Distributions<h3>NOTES</h3> 46*4f1223e8SApple OSS Distributions<p> 47*4f1223e8SApple OSS DistributionsThis interface is not implemented in OSF/1 R1.3. 48*4f1223e8SApple OSS Distributions<p> 49*4f1223e8SApple OSS DistributionsA ledger limit of <strong>LEDGER_ITEM_INFINITE</strong> allows any amount (even 50*4f1223e8SApple OSS Distributionsinfinity) to be withdrawn. The root ledger has such a limit. 51*4f1223e8SApple OSS Distributions<h3>RETURN VALUES</h3> 52*4f1223e8SApple OSS Distributions<dl> 53*4f1223e8SApple OSS Distributions<p> 54*4f1223e8SApple OSS Distributions<dt> <strong>KERN_RESOURCE_SHORTAGE</strong> 55*4f1223e8SApple OSS Distributions<dd> 56*4f1223e8SApple OSS DistributionsTransferring the resources would cause the parent ledger to exceed its 57*4f1223e8SApple OSS Distributionslimits. 58*4f1223e8SApple OSS Distributions<p> 59*4f1223e8SApple OSS Distributions<dt> <strong>KERN_INVALID_LEDGER</strong> 60*4f1223e8SApple OSS Distributions<dd> 61*4f1223e8SApple OSS Distributions<var>ledger_ledger</var> is not a wired kernel memory ledger. 62*4f1223e8SApple OSS Distributions</dl> 63*4f1223e8SApple OSS Distributions<h3>RELATED INFORMATION</h3> 64*4f1223e8SApple OSS Distributions<p> 65*4f1223e8SApple OSS DistributionsFunctions: 66*4f1223e8SApple OSS Distributions<a href="ledger_transfer.html"><strong>ledger_transfer</strong></a>, 67*4f1223e8SApple OSS Distributions<a href="ledger_terminate.html"><strong>ledger_terminate</strong></a>, 68*4f1223e8SApple OSS Distributions<a href="ledger_read.html"><strong>ledger_read</strong></a>, 69*4f1223e8SApple OSS Distributions<a href="ledger_set_remote.html"><strong>ledger_set_remote</strong></a>. 70