4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
22 * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
23 * Copyright (c) 2013 by Delphix. All rights reserved.
24 * Copyright (c) 2013 by Saso Kiselkov. All rights reserved.
25 * Copyright 2013 Nexenta Systems, Inc. All rights reserved.
28 #ifndef _SYS_ARC_IMPL_H
29 #define _SYS_ARC_IMPL_H
32 #include <sys/zio_crypt.h>
34 #include <sys/aggsum.h>
41 * Note that buffers can be in one of 6 states:
42 * ARC_anon - anonymous (discussed below)
43 * ARC_mru - recently used, currently cached
44 * ARC_mru_ghost - recently used, no longer in cache
45 * ARC_mfu - frequently used, currently cached
46 * ARC_mfu_ghost - frequently used, no longer in cache
47 * ARC_l2c_only - exists in L2ARC but not other states
48 * When there are no active references to the buffer, they are
49 * are linked onto a list in one of these arc states. These are
50 * the only buffers that can be evicted or deleted. Within each
51 * state there are multiple lists, one for meta-data and one for
52 * non-meta-data. Meta-data (indirect blocks, blocks of dnodes,
53 * etc.) is tracked separately so that it can be managed more
54 * explicitly: favored over data, limited explicitly.
56 * Anonymous buffers are buffers that are not associated with
57 * a DVA. These are buffers that hold dirty block copies
58 * before they are written to stable storage. By definition,
59 * they are "ref'd" and are considered part of arc_mru
60 * that cannot be freed. Generally, they will acquire a DVA
61 * as they are written and migrate onto the arc_mru list.
63 * The ARC_l2c_only state is for buffers that are in the second
64 * level ARC but no longer in any of the ARC_m* lists. The second
65 * level ARC itself may also contain buffers that are in any of
66 * the ARC_m* states - meaning that a buffer can exist in two
67 * places. The reason for the ARC_l2c_only state is to keep the
68 * buffer header in the hash table, so that reads that hit the
69 * second level ARC benefit from these fast lookups.
72 typedef struct arc_state
{
74 * list of evictable buffers
76 multilist_t
*arcs_list
[ARC_BUFC_NUMTYPES
];
78 * total amount of evictable data in this state
80 zfs_refcount_t arcs_esize
[ARC_BUFC_NUMTYPES
];
82 * total amount of data in this state; this includes: evictable,
83 * non-evictable, ARC_BUFC_DATA, and ARC_BUFC_METADATA.
85 zfs_refcount_t arcs_size
;
87 * supports the "dbufs" kstat
89 arc_state_type_t arcs_state
;
92 typedef struct arc_callback arc_callback_t
;
96 arc_read_done_func_t
*acb_done
;
98 boolean_t acb_encrypted
;
99 boolean_t acb_compressed
;
100 boolean_t acb_noauth
;
101 zbookmark_phys_t acb_zb
;
102 zio_t
*acb_zio_dummy
;
104 arc_callback_t
*acb_next
;
107 typedef struct arc_write_callback arc_write_callback_t
;
109 struct arc_write_callback
{
111 arc_write_done_func_t
*awcb_ready
;
112 arc_write_done_func_t
*awcb_children_ready
;
113 arc_write_done_func_t
*awcb_physdone
;
114 arc_write_done_func_t
*awcb_done
;
119 * ARC buffers are separated into multiple structs as a memory saving measure:
120 * - Common fields struct, always defined, and embedded within it:
121 * - L2-only fields, always allocated but undefined when not in L2ARC
122 * - L1-only fields, only allocated when in L1ARC
124 * Buffer in L1 Buffer only in L2
125 * +------------------------+ +------------------------+
126 * | arc_buf_hdr_t | | arc_buf_hdr_t |
130 * +------------------------+ +------------------------+
131 * | l2arc_buf_hdr_t | | l2arc_buf_hdr_t |
132 * | (undefined if L1-only) | | |
133 * +------------------------+ +------------------------+
134 * | l1arc_buf_hdr_t |
139 * +------------------------+
141 * Because it's possible for the L2ARC to become extremely large, we can wind
142 * up eating a lot of memory in L2ARC buffer headers, so the size of a header
143 * is minimized by only allocating the fields necessary for an L1-cached buffer
144 * when a header is actually in the L1 cache. The sub-headers (l1arc_buf_hdr and
145 * l2arc_buf_hdr) are embedded rather than allocated separately to save a couple
146 * words in pointers. arc_hdr_realloc() is used to switch a header between
147 * these two allocation states.
149 typedef struct l1arc_buf_hdr
{
150 kmutex_t b_freeze_lock
;
151 zio_cksum_t
*b_freeze_cksum
;
155 /* for waiting on writes to complete */
160 /* protected by arc state mutex */
161 arc_state_t
*b_state
;
162 multilist_node_t b_arc_node
;
164 /* updated atomically */
165 clock_t b_arc_access
;
167 uint32_t b_mru_ghost_hits
;
169 uint32_t b_mfu_ghost_hits
;
172 /* self protecting */
173 zfs_refcount_t b_refcnt
;
175 arc_callback_t
*b_acb
;
180 * Encrypted blocks will need to be stored encrypted on the L2ARC
181 * disk as they appear in the main pool. In order for this to work we
182 * need to pass around the encryption parameters so they can be used
183 * to write data to the L2ARC. This struct is only defined in the
184 * arc_buf_hdr_t if the L1 header is defined and has the ARC_FLAG_ENCRYPTED
187 typedef struct arc_buf_hdr_crypt
{
188 abd_t
*b_rabd
; /* raw encrypted data */
189 dmu_object_type_t b_ot
; /* object type */
190 uint32_t b_ebufcnt
; /* count of encrypted buffers */
192 /* dsobj for looking up encryption key for l2arc encryption */
195 /* encryption parameters */
196 uint8_t b_salt
[ZIO_DATA_SALT_LEN
];
197 uint8_t b_iv
[ZIO_DATA_IV_LEN
];
200 * Technically this could be removed since we will always be able to
201 * get the mac from the bp when we need it. However, it is inconvenient
202 * for callers of arc code to have to pass a bp in all the time. This
203 * also allows us to assert that L2ARC data is properly encrypted to
204 * match the data in the main storage pool.
206 uint8_t b_mac
[ZIO_DATA_MAC_LEN
];
207 } arc_buf_hdr_crypt_t
;
209 typedef struct l2arc_dev
{
210 vdev_t
*l2ad_vdev
; /* vdev */
211 spa_t
*l2ad_spa
; /* spa */
212 uint64_t l2ad_hand
; /* next write location */
213 uint64_t l2ad_start
; /* first addr on device */
214 uint64_t l2ad_end
; /* last addr on device */
215 boolean_t l2ad_first
; /* first sweep through */
216 boolean_t l2ad_writing
; /* currently writing */
217 kmutex_t l2ad_mtx
; /* lock for buffer list */
218 list_t l2ad_buflist
; /* buffer list */
219 list_node_t l2ad_node
; /* device list node */
220 zfs_refcount_t l2ad_alloc
; /* allocated bytes */
223 typedef struct l2arc_buf_hdr
{
224 /* protected by arc_buf_hdr mutex */
225 l2arc_dev_t
*b_dev
; /* L2ARC device */
226 uint64_t b_daddr
; /* disk address, offset byte */
229 list_node_t b_l2node
;
232 typedef struct l2arc_write_callback
{
233 l2arc_dev_t
*l2wcb_dev
; /* device info */
234 arc_buf_hdr_t
*l2wcb_head
; /* head of write buflist */
235 } l2arc_write_callback_t
;
238 /* protected by hash lock */
242 arc_buf_contents_t b_type
;
243 arc_buf_hdr_t
*b_hash_next
;
247 * This field stores the size of the data buffer after
248 * compression, and is set in the arc's zio completion handlers.
249 * It is in units of SPA_MINBLOCKSIZE (e.g. 1 == 512 bytes).
251 * While the block pointers can store up to 32MB in their psize
252 * field, we can only store up to 32MB minus 512B. This is due
253 * to the bp using a bias of 1, whereas we use a bias of 0 (i.e.
254 * a field of zeros represents 512B in the bp). We can't use a
255 * bias of 1 since we need to reserve a psize of zero, here, to
256 * represent holes and embedded blocks.
258 * This isn't a problem in practice, since the maximum size of a
259 * buffer is limited to 16MB, so we never need to store 32MB in
260 * this field. Even in the upstream illumos code base, the
261 * maximum size of a buffer is limited to 16MB.
266 * This field stores the size of the data buffer before
267 * compression, and cannot change once set. It is in units
268 * of SPA_MINBLOCKSIZE (e.g. 2 == 1024 bytes)
270 uint16_t b_lsize
; /* immutable */
271 uint64_t b_spa
; /* immutable */
273 /* L2ARC fields. Undefined when not in L2ARC. */
274 l2arc_buf_hdr_t b_l2hdr
;
275 /* L1ARC fields. Undefined when in l2arc_only state */
276 l1arc_buf_hdr_t b_l1hdr
;
278 * Encryption parameters. Defined only when ARC_FLAG_ENCRYPTED
279 * is set and the L1 header exists.
281 arc_buf_hdr_crypt_t b_crypt_hdr
;
284 typedef struct arc_stats
{
285 kstat_named_t arcstat_hits
;
286 kstat_named_t arcstat_misses
;
287 kstat_named_t arcstat_demand_data_hits
;
288 kstat_named_t arcstat_demand_data_misses
;
289 kstat_named_t arcstat_demand_metadata_hits
;
290 kstat_named_t arcstat_demand_metadata_misses
;
291 kstat_named_t arcstat_prefetch_data_hits
;
292 kstat_named_t arcstat_prefetch_data_misses
;
293 kstat_named_t arcstat_prefetch_metadata_hits
;
294 kstat_named_t arcstat_prefetch_metadata_misses
;
295 kstat_named_t arcstat_mru_hits
;
296 kstat_named_t arcstat_mru_ghost_hits
;
297 kstat_named_t arcstat_mfu_hits
;
298 kstat_named_t arcstat_mfu_ghost_hits
;
299 kstat_named_t arcstat_deleted
;
301 * Number of buffers that could not be evicted because the hash lock
302 * was held by another thread. The lock may not necessarily be held
303 * by something using the same buffer, since hash locks are shared
304 * by multiple buffers.
306 kstat_named_t arcstat_mutex_miss
;
308 * Number of buffers skipped when updating the access state due to the
309 * header having already been released after acquiring the hash lock.
311 kstat_named_t arcstat_access_skip
;
313 * Number of buffers skipped because they have I/O in progress, are
314 * indirect prefetch buffers that have not lived long enough, or are
315 * not from the spa we're trying to evict from.
317 kstat_named_t arcstat_evict_skip
;
319 * Number of times arc_evict_state() was unable to evict enough
320 * buffers to reach its target amount.
322 kstat_named_t arcstat_evict_not_enough
;
323 kstat_named_t arcstat_evict_l2_cached
;
324 kstat_named_t arcstat_evict_l2_eligible
;
325 kstat_named_t arcstat_evict_l2_ineligible
;
326 kstat_named_t arcstat_evict_l2_skip
;
327 kstat_named_t arcstat_hash_elements
;
328 kstat_named_t arcstat_hash_elements_max
;
329 kstat_named_t arcstat_hash_collisions
;
330 kstat_named_t arcstat_hash_chains
;
331 kstat_named_t arcstat_hash_chain_max
;
332 kstat_named_t arcstat_p
;
333 kstat_named_t arcstat_c
;
334 kstat_named_t arcstat_c_min
;
335 kstat_named_t arcstat_c_max
;
336 /* Not updated directly; only synced in arc_kstat_update. */
337 kstat_named_t arcstat_size
;
339 * Number of compressed bytes stored in the arc_buf_hdr_t's b_pabd.
340 * Note that the compressed bytes may match the uncompressed bytes
341 * if the block is either not compressed or compressed arc is disabled.
343 kstat_named_t arcstat_compressed_size
;
345 * Uncompressed size of the data stored in b_pabd. If compressed
346 * arc is disabled then this value will be identical to the stat
349 kstat_named_t arcstat_uncompressed_size
;
351 * Number of bytes stored in all the arc_buf_t's. This is classified
352 * as "overhead" since this data is typically short-lived and will
353 * be evicted from the arc when it becomes unreferenced unless the
354 * zfs_keep_uncompressed_metadata or zfs_keep_uncompressed_level
355 * values have been set (see comment in dbuf.c for more information).
357 kstat_named_t arcstat_overhead_size
;
359 * Number of bytes consumed by internal ARC structures necessary
360 * for tracking purposes; these structures are not actually
361 * backed by ARC buffers. This includes arc_buf_hdr_t structures
362 * (allocated via arc_buf_hdr_t_full and arc_buf_hdr_t_l2only
363 * caches), and arc_buf_t structures (allocated via arc_buf_t
365 * Not updated directly; only synced in arc_kstat_update.
367 kstat_named_t arcstat_hdr_size
;
369 * Number of bytes consumed by ARC buffers of type equal to
370 * ARC_BUFC_DATA. This is generally consumed by buffers backing
371 * on disk user data (e.g. plain file contents).
372 * Not updated directly; only synced in arc_kstat_update.
374 kstat_named_t arcstat_data_size
;
376 * Number of bytes consumed by ARC buffers of type equal to
377 * ARC_BUFC_METADATA. This is generally consumed by buffers
378 * backing on disk data that is used for internal ZFS
379 * structures (e.g. ZAP, dnode, indirect blocks, etc).
380 * Not updated directly; only synced in arc_kstat_update.
382 kstat_named_t arcstat_metadata_size
;
384 * Number of bytes consumed by dmu_buf_impl_t objects.
385 * Not updated directly; only synced in arc_kstat_update.
387 kstat_named_t arcstat_dbuf_size
;
389 * Number of bytes consumed by dnode_t objects.
390 * Not updated directly; only synced in arc_kstat_update.
392 kstat_named_t arcstat_dnode_size
;
394 * Number of bytes consumed by bonus buffers.
395 * Not updated directly; only synced in arc_kstat_update.
397 kstat_named_t arcstat_bonus_size
;
399 * Total number of bytes consumed by ARC buffers residing in the
400 * arc_anon state. This includes *all* buffers in the arc_anon
401 * state; e.g. data, metadata, evictable, and unevictable buffers
402 * are all included in this value.
403 * Not updated directly; only synced in arc_kstat_update.
405 kstat_named_t arcstat_anon_size
;
407 * Number of bytes consumed by ARC buffers that meet the
408 * following criteria: backing buffers of type ARC_BUFC_DATA,
409 * residing in the arc_anon state, and are eligible for eviction
410 * (e.g. have no outstanding holds on the buffer).
411 * Not updated directly; only synced in arc_kstat_update.
413 kstat_named_t arcstat_anon_evictable_data
;
415 * Number of bytes consumed by ARC buffers that meet the
416 * following criteria: backing buffers of type ARC_BUFC_METADATA,
417 * residing in the arc_anon state, and are eligible for eviction
418 * (e.g. have no outstanding holds on the buffer).
419 * Not updated directly; only synced in arc_kstat_update.
421 kstat_named_t arcstat_anon_evictable_metadata
;
423 * Total number of bytes consumed by ARC buffers residing in the
424 * arc_mru state. This includes *all* buffers in the arc_mru
425 * state; e.g. data, metadata, evictable, and unevictable buffers
426 * are all included in this value.
427 * Not updated directly; only synced in arc_kstat_update.
429 kstat_named_t arcstat_mru_size
;
431 * Number of bytes consumed by ARC buffers that meet the
432 * following criteria: backing buffers of type ARC_BUFC_DATA,
433 * residing in the arc_mru state, and are eligible for eviction
434 * (e.g. have no outstanding holds on the buffer).
435 * Not updated directly; only synced in arc_kstat_update.
437 kstat_named_t arcstat_mru_evictable_data
;
439 * Number of bytes consumed by ARC buffers that meet the
440 * following criteria: backing buffers of type ARC_BUFC_METADATA,
441 * residing in the arc_mru state, and are eligible for eviction
442 * (e.g. have no outstanding holds on the buffer).
443 * Not updated directly; only synced in arc_kstat_update.
445 kstat_named_t arcstat_mru_evictable_metadata
;
447 * Total number of bytes that *would have been* consumed by ARC
448 * buffers in the arc_mru_ghost state. The key thing to note
449 * here, is the fact that this size doesn't actually indicate
450 * RAM consumption. The ghost lists only consist of headers and
451 * don't actually have ARC buffers linked off of these headers.
452 * Thus, *if* the headers had associated ARC buffers, these
453 * buffers *would have* consumed this number of bytes.
454 * Not updated directly; only synced in arc_kstat_update.
456 kstat_named_t arcstat_mru_ghost_size
;
458 * Number of bytes that *would have been* consumed by ARC
459 * buffers that are eligible for eviction, of type
460 * ARC_BUFC_DATA, and linked off the arc_mru_ghost state.
461 * Not updated directly; only synced in arc_kstat_update.
463 kstat_named_t arcstat_mru_ghost_evictable_data
;
465 * Number of bytes that *would have been* consumed by ARC
466 * buffers that are eligible for eviction, of type
467 * ARC_BUFC_METADATA, and linked off the arc_mru_ghost state.
468 * Not updated directly; only synced in arc_kstat_update.
470 kstat_named_t arcstat_mru_ghost_evictable_metadata
;
472 * Total number of bytes consumed by ARC buffers residing in the
473 * arc_mfu state. This includes *all* buffers in the arc_mfu
474 * state; e.g. data, metadata, evictable, and unevictable buffers
475 * are all included in this value.
476 * Not updated directly; only synced in arc_kstat_update.
478 kstat_named_t arcstat_mfu_size
;
480 * Number of bytes consumed by ARC buffers that are eligible for
481 * eviction, of type ARC_BUFC_DATA, and reside in the arc_mfu
483 * Not updated directly; only synced in arc_kstat_update.
485 kstat_named_t arcstat_mfu_evictable_data
;
487 * Number of bytes consumed by ARC buffers that are eligible for
488 * eviction, of type ARC_BUFC_METADATA, and reside in the
490 * Not updated directly; only synced in arc_kstat_update.
492 kstat_named_t arcstat_mfu_evictable_metadata
;
494 * Total number of bytes that *would have been* consumed by ARC
495 * buffers in the arc_mfu_ghost state. See the comment above
496 * arcstat_mru_ghost_size for more details.
497 * Not updated directly; only synced in arc_kstat_update.
499 kstat_named_t arcstat_mfu_ghost_size
;
501 * Number of bytes that *would have been* consumed by ARC
502 * buffers that are eligible for eviction, of type
503 * ARC_BUFC_DATA, and linked off the arc_mfu_ghost state.
504 * Not updated directly; only synced in arc_kstat_update.
506 kstat_named_t arcstat_mfu_ghost_evictable_data
;
508 * Number of bytes that *would have been* consumed by ARC
509 * buffers that are eligible for eviction, of type
510 * ARC_BUFC_METADATA, and linked off the arc_mru_ghost state.
511 * Not updated directly; only synced in arc_kstat_update.
513 kstat_named_t arcstat_mfu_ghost_evictable_metadata
;
514 kstat_named_t arcstat_l2_hits
;
515 kstat_named_t arcstat_l2_misses
;
516 kstat_named_t arcstat_l2_feeds
;
517 kstat_named_t arcstat_l2_rw_clash
;
518 kstat_named_t arcstat_l2_read_bytes
;
519 kstat_named_t arcstat_l2_write_bytes
;
520 kstat_named_t arcstat_l2_writes_sent
;
521 kstat_named_t arcstat_l2_writes_done
;
522 kstat_named_t arcstat_l2_writes_error
;
523 kstat_named_t arcstat_l2_writes_lock_retry
;
524 kstat_named_t arcstat_l2_evict_lock_retry
;
525 kstat_named_t arcstat_l2_evict_reading
;
526 kstat_named_t arcstat_l2_evict_l1cached
;
527 kstat_named_t arcstat_l2_free_on_write
;
528 kstat_named_t arcstat_l2_abort_lowmem
;
529 kstat_named_t arcstat_l2_cksum_bad
;
530 kstat_named_t arcstat_l2_io_error
;
531 kstat_named_t arcstat_l2_lsize
;
532 kstat_named_t arcstat_l2_psize
;
533 /* Not updated directly; only synced in arc_kstat_update. */
534 kstat_named_t arcstat_l2_hdr_size
;
535 kstat_named_t arcstat_memory_throttle_count
;
536 kstat_named_t arcstat_memory_direct_count
;
537 kstat_named_t arcstat_memory_indirect_count
;
538 kstat_named_t arcstat_memory_all_bytes
;
539 kstat_named_t arcstat_memory_free_bytes
;
540 kstat_named_t arcstat_memory_available_bytes
;
541 kstat_named_t arcstat_no_grow
;
542 kstat_named_t arcstat_tempreserve
;
543 kstat_named_t arcstat_loaned_bytes
;
544 kstat_named_t arcstat_prune
;
545 /* Not updated directly; only synced in arc_kstat_update. */
546 kstat_named_t arcstat_meta_used
;
547 kstat_named_t arcstat_meta_limit
;
548 kstat_named_t arcstat_dnode_limit
;
549 kstat_named_t arcstat_meta_max
;
550 kstat_named_t arcstat_meta_min
;
551 kstat_named_t arcstat_async_upgrade_sync
;
552 kstat_named_t arcstat_demand_hit_predictive_prefetch
;
553 kstat_named_t arcstat_demand_hit_prescient_prefetch
;
554 kstat_named_t arcstat_need_free
;
555 kstat_named_t arcstat_sys_free
;
556 kstat_named_t arcstat_raw_size
;
557 kstat_named_t arcstat_cached_only_in_progress
;
560 typedef enum free_memory_reason_t
{
565 FMR_PAGES_PP_MAXIMUM
,
568 } free_memory_reason_t
;
570 #define ARCSTAT(stat) (arc_stats.stat.value.ui64)
572 #define ARCSTAT_INCR(stat, val) \
573 atomic_add_64(&arc_stats.stat.value.ui64, (val))
575 #define ARCSTAT_BUMP(stat) ARCSTAT_INCR(stat, 1)
576 #define ARCSTAT_BUMPDOWN(stat) ARCSTAT_INCR(stat, -1)
578 #define arc_no_grow ARCSTAT(arcstat_no_grow) /* do not grow cache size */
579 #define arc_p ARCSTAT(arcstat_p) /* target size of MRU */
580 #define arc_c ARCSTAT(arcstat_c) /* target size of cache */
581 #define arc_c_min ARCSTAT(arcstat_c_min) /* min target cache size */
582 #define arc_c_max ARCSTAT(arcstat_c_max) /* max target cache size */
583 #define arc_sys_free ARCSTAT(arcstat_sys_free) /* target system free bytes */
584 #define arc_need_free ARCSTAT(arcstat_need_free) /* bytes to be freed */
586 extern int arc_zio_arena_free_shift
;
587 extern taskq_t
*arc_prune_taskq
;
588 extern arc_stats_t arc_stats
;
589 extern hrtime_t arc_growtime
;
590 extern boolean_t arc_warm
;
591 extern int arc_grow_retry
;
592 extern int arc_shrink_shift
;
593 extern zthr_t
*arc_adjust_zthr
;
594 extern kmutex_t arc_adjust_lock
;
595 extern kcondvar_t arc_adjust_waiters_cv
;
596 extern boolean_t arc_adjust_needed
;
597 extern kmutex_t arc_prune_mtx
;
598 extern list_t arc_prune_list
;
599 extern aggsum_t arc_size
;
600 extern arc_state_t
*arc_mfu
;
601 extern arc_state_t
*arc_mru
;
602 extern uint_t zfs_arc_pc_percent
;
603 extern int arc_lotsfree_percent
;
605 extern void arc_reduce_target_size(int64_t to_free
);
606 extern boolean_t
arc_reclaim_needed(void);
607 extern void arc_kmem_reap_soon(void);
609 extern void arc_lowmem_init(void);
610 extern void arc_lowmem_fini(void);
611 extern void arc_prune_async(int64_t);
612 extern int arc_memory_throttle(spa_t
*spa
, uint64_t reserve
, uint64_t txg
);
613 extern uint64_t arc_free_memory(void);
614 extern int64_t arc_available_memory(void);
615 extern void arc_tuning_update(void);
617 extern int param_set_arc_long(ZFS_MODULE_PARAM_ARGS
);
618 extern int param_set_arc_int(ZFS_MODULE_PARAM_ARGS
);
624 #endif /* _SYS_ARC_IMPL_H */