]> git.saurik.com Git - apple/libsystem.git/blame - alloc_once_private.h
Libsystem-1292.100.5.tar.gz
[apple/libsystem.git] / alloc_once_private.h
CommitLineData
afef526e
A
1/*
2 * Copyright (c) 2012-2013 Apple Inc. All rights reserved.
3 *
4 * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
5 *
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. The rights granted to you under the License
10 * may not be used to create, or enable the creation or redistribution of,
11 * unlawful or unlicensed copies of an Apple operating system, or to
12 * circumvent, violate, or enable the circumvention or violation of, any
13 * terms of an Apple operating system software license agreement.
14 *
15 * Please obtain a copy of the License at
16 * http://www.opensource.apple.com/apsl/ and read it before using this file.
17 *
18 * The Original Code and all software distributed under the License are
19 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
20 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
21 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
22 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
23 * Please see the License for the specific language governing rights and
24 * limitations under the License.
25 *
26 * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
27 */
28
29#ifndef __OS_ALLOC__
30#define __OS_ALLOC__
31
32#ifndef __OS_ALLOC_INDIRECT__
33#define __OS_ALLOC_INDIRECT__
34#endif // __OS_ALLOC_INDIRECT__
35
36#include <os/alloc_once_impl.h>
37
38/* Keys for use with os_once_alloc. */
39
40/* Keys for Libsystem. */
a8f6861e
A
41#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_NOTIFY 0
42#define OS_ALLOC_ONCE_KEY_LIBXPC 1
43#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_C 2
44#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_INFO 3
45#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_NETWORK 4
46#define OS_ALLOC_ONCE_KEY_LIBCACHE 5
47#define OS_ALLOC_ONCE_KEY_LIBCOMMONCRYPTO 6
48#define OS_ALLOC_ONCE_KEY_LIBDISPATCH 7
49#define OS_ALLOC_ONCE_KEY_LIBDYLD 8
50#define OS_ALLOC_ONCE_KEY_LIBKEYMGR 9
51#define OS_ALLOC_ONCE_KEY_LIBLAUNCH 10
52#define OS_ALLOC_ONCE_KEY_LIBMACHO 11
53#define OS_ALLOC_ONCE_KEY_OS_TRACE 12
54#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_BLOCKS 13
55#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_MALLOC 14
56#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_PLATFORM 15
57#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_PTHREAD 16
58#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_STATS 17
59#define OS_ALLOC_ONCE_KEY_LIBSECINIT 18
60#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_CORESERVICES 19
61#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_SYMPTOMS 20
62#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_PLATFORM_ASL 21
b8ce8438 63#define OS_ALLOC_ONCE_KEY_LIBSYSTEM_FEATUREFLAGS 22
afef526e
A
64
65/* Keys OS_ALLOC_ONCE_KEY_MAX - 10 upwards are reserved for the system. */
66#define OS_ALLOC_ONCE_KEY_RESERVED_0 (OS_ALLOC_ONCE_KEY_MAX - 10)
67#define OS_ALLOC_ONCE_KEY_RESERVED_1 (OS_ALLOC_ONCE_KEY_MAX - 9)
68#define OS_ALLOC_ONCE_KEY_RESERVED_2 (OS_ALLOC_ONCE_KEY_MAX - 8)
69#define OS_ALLOC_ONCE_KEY_RESERVED_3 (OS_ALLOC_ONCE_KEY_MAX - 7)
70#define OS_ALLOC_ONCE_KEY_RESERVED_4 (OS_ALLOC_ONCE_KEY_MAX - 6)
71#define OS_ALLOC_ONCE_KEY_RESERVED_5 (OS_ALLOC_ONCE_KEY_MAX - 5)
72#define OS_ALLOC_ONCE_KEY_RESERVED_6 (OS_ALLOC_ONCE_KEY_MAX - 4)
73#define OS_ALLOC_ONCE_KEY_RESERVED_7 (OS_ALLOC_ONCE_KEY_MAX - 3)
74#define OS_ALLOC_ONCE_KEY_RESERVED_8 (OS_ALLOC_ONCE_KEY_MAX - 2)
75#define OS_ALLOC_ONCE_KEY_RESERVED_9 (OS_ALLOC_ONCE_KEY_MAX - 1)
76
77/* OS_ALLOC_ONCE_KEY_MAX cannot be used. */
78
79#endif // __OS_ALLOC__