aboutsummaryrefslogtreecommitdiffstats
path: root/include/sys
diff options
context:
space:
mode:
authorRyan Moeller <[email protected]>2020-03-27 12:14:46 -0400
committerGitHub <[email protected]>2020-03-27 09:14:46 -0700
commit9a51738b60c2164822baefa17f8fdcebe9d82fbc (patch)
treea16926d3b550160a937d533e41a6651b6f3ad6c8 /include/sys
parent3f38797338f2e4b16e8e0065e21f1bca6ef59784 (diff)
Let default arc_c_max be platform dependent
Linux changed the default max ARC size to 1/2 of physical memory to deal with shortcomings of the Linux SLUB allocator. Other platforms do not require the same logic. Implement an arc_default_max() function to determine a default max ARC size in platform code. Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Ryan Moeller <[email protected]> Closes #10155
Diffstat (limited to 'include/sys')
-rw-r--r--include/sys/arc.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/sys/arc.h b/include/sys/arc.h
index 6f56f732a..75c483918 100644
--- a/include/sys/arc.h
+++ b/include/sys/arc.h
@@ -298,6 +298,7 @@ void arc_tempreserve_clear(uint64_t reserve);
int arc_tempreserve_space(spa_t *spa, uint64_t reserve, uint64_t txg);
uint64_t arc_all_memory(void);
+uint64_t arc_default_max(uint64_t min, uint64_t allmem);
uint64_t arc_target_bytes(void);
void arc_init(void);
void arc_fini(void);