#include <kern/ledger.h>

kern/ledger.h Kernel.framework

ledger_t, ledger_entry_id_t
7 macros · 5 structs

macroLEDGER_INFO

#define LEDGER_INFO 0

macroLEDGER_ENTRY_INFO

#define LEDGER_ENTRY_INFO 1

macroLEDGER_TEMPLATE_INFO

#define LEDGER_TEMPLATE_INFO 2

macroLEDGER_LIMIT

#define LEDGER_LIMIT 3

macroLEDGER_ENTRY_INFO_V2

#define LEDGER_ENTRY_INFO_V2 4

macroLEDGER_MAX_CMD

LEDGER_MAX_CMD always tracks the index of the last ledger command.
#define LEDGER_MAX_CMD LEDGER_ENTRY_INFO_V2

macroLEDGER_NAME_MAX

#define LEDGER_NAME_MAX 32

structledger_info

size 48, align 8
char[32]li_name
int64_tli_id
int64_tli_entries

structledger_template_info

size 96, align 1
char[32]lti_name
char[32]lti_group
char[32]lti_units

structledger_entry_info

size 48, align 8
int64_tlei_balance
int64_tlei_credit
int64_tlei_debit
uint64_tlei_limit
uint64_tlei_refill_periodIn nanoseconds
uint64_tlei_last_refillTime since last refill

structledger_entry_info_v2

size 88, align 8
int64_tlei_balance
int64_tlei_credit
int64_tlei_debit
uint64_tlei_limit
uint64_tlei_refill_periodIn nanoseconds
uint64_tlei_last_refillTime since last refill
int64_tlei_lifetime_maxfor phys_footprint/neural_nofootprint_lifetime_max
uint64_t[4]lei_reserved

structledger_limit_args

size 48, align 8
char[32]lla_name
uint64_tlla_limit
uint64_tlla_refill_period