Lines Matching refs:zone

90  *	A zone is a collection of fixed size blocks for which there
92 * use zones to manage data structures dynamically, creating a zone
100 struct zone {
103 queue_head_t any_free_foreign; /* foreign pages crammed into zone */
110 lck_attr_t lock_attr; /* zone lock attribute */
111 decl_lck_mtx_data(,lock) /* zone lock */
114 vm_size_t max_size; /* how large can this zone grow */
117 uint64_t page_count __attribute__((aligned(8))); /* number of pages used by this zone */
118 uint64_t sum_count; /* count of allocs (life of zone) */
122 /* boolean_t */ expandable :1, /* (T) expand zone (with message)? */
124 /* boolean_t */ doing_alloc :1, /* is zone expanding now? */
138 int index; /* index into zone_info arrays for this zone */
139 struct zone *next_zone; /* Link for all-zones list */
140 const char *zone_name; /* a name for the zone */
146 uint32_t zleak_capture; /* per-zone counter for capturing every N allocations */
157 * structure for tracking zone usage
158 * Used either one per task/thread for all zones or <per-task,per-zone>.
170 /* Steal memory for zone module */
173 /* Bootstrap zone module (create zone zone) */
176 /* Init zone module */
180 /* Handle per-task zone info */
217 /* Allocate from zone */
219 zone_t zone);
221 /* Free zone element */
223 zone_t zone,
226 /* Create zone */
231 const char *name); /* a name for the zone */
236 zone_t zone);
240 zone_t zone,
243 /* Get from zone free list */
245 zone_t zone);
247 /* Fill zone with memory */
249 zone_t zone,
253 /* Initially fill zone with specified number of elements */
255 zone_t zone,
258 /* Change zone parameters */
260 zone_t zone,
265 #define Z_EXHAUST 1 /* Make zone exhaustible */
266 #define Z_COLLECT 2 /* Make zone collectable */
267 #define Z_EXPAND 3 /* Make zone expandable */
268 #define Z_FOREIGN 4 /* Allow collectable zone to contain foreign elements */
270 #define Z_NOENCRYPT 6 /* Don't encrypt zone during hibernation */
271 #define Z_NOCALLOUT 7 /* Don't asynchronously replenish the zone via
277 /* Preallocate space for zone from zone map */
279 zone_t zone,
283 zone_t zone);
286 * MAX_ZTRACE_DEPTH configures how deep of a stack trace is taken on each zalloc in the zone of interest. 15
290 * This is used both for the zone leak detector and the zone corruption log.
327 #define lock_zone(zone) \
329 lck_mtx_lock_spin(&(zone)->lock); \
332 #define unlock_zone(zone) \
334 lck_mtx_unlock(&(zone)->lock); \