X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/0a7de7458d150b5d4dffc935ba399be265ef0a1a..cb3231590a3c94ab4375e2228bd5e86b0cf1ad7e:/osfmk/kern/ledger.h diff --git a/osfmk/kern/ledger.h b/osfmk/kern/ledger.h index 3e3e6c323..9be77bb0c 100644 --- a/osfmk/kern/ledger.h +++ b/osfmk/kern/ledger.h @@ -96,7 +96,7 @@ struct ledger_entry { struct ledger { uint64_t l_id; - struct os_refcnt l_refs; + os_refcnt_t l_refs; int32_t l_size; struct ledger_template *l_template; struct ledger_entry l_entries[0] __attribute__((aligned(8))); @@ -141,6 +141,7 @@ typedef void (*ledger_callback_t)(int warning, const void * param0, const void * extern void ledger_init(void); extern ledger_template_t ledger_template_create(const char *name); +extern ledger_template_t ledger_template_copy(ledger_template_t template, const char *name); extern void ledger_template_dereference(ledger_template_t template); extern int ledger_entry_add(ledger_template_t template, const char *key, const char *group, const char *units); @@ -207,9 +208,8 @@ extern kern_return_t ledger_rollup_entry(ledger_t to_ledger, ledger_t from_ledge extern void ledger_ast(thread_t thread); -extern int ledger_reference_count(ledger_t ledger); -extern kern_return_t ledger_reference(ledger_t ledger); -extern kern_return_t ledger_dereference(ledger_t ledger); +extern void ledger_reference(ledger_t ledger); +extern void ledger_dereference(ledger_t ledger); /* Support for ledger() syscall */ #ifdef LEDGER_DEBUG