diff options
author | Tony Hutter <[email protected]> | 2019-01-10 14:28:10 -0800 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2019-01-28 10:11:14 -0800 |
commit | 031cea17a3db1dae3b6968a8c71bcfb678a03235 (patch) | |
tree | a60ac674f73053dc6f69000686687ff734d61753 /module/zfs/arc.c | |
parent | 77e50c3070a0009c4ed8b50dbb7cf0df48bdda90 (diff) |
Linux 5.0 compat: Use totalram_pages()
totalram_pages() was converted to an atomic variable in 5.0:
https://patchwork.kernel.org/patch/10652795/
Its value should now be read though the totalram_pages() helper
function.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Tony Hutter <[email protected]>
Closes #8263
Diffstat (limited to 'module/zfs/arc.c')
-rw-r--r-- | module/zfs/arc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/module/zfs/arc.c b/module/zfs/arc.c index 7e0963334..f5d94cbf9 100644 --- a/module/zfs/arc.c +++ b/module/zfs/arc.c @@ -4821,9 +4821,9 @@ arc_all_memory(void) { #ifdef _KERNEL #ifdef CONFIG_HIGHMEM - return (ptob(totalram_pages - totalhigh_pages)); + return (ptob(zfs_totalram_pages - totalhigh_pages)); #else - return (ptob(totalram_pages)); + return (ptob(zfs_totalram_pages)); #endif /* CONFIG_HIGHMEM */ #else return (ptob(physmem) / 2); |