xref: /freebsd/sys/contrib/openzfs/config/kernel-totalhigh_pages.m4 (revision 5ca8e32633c4ffbbcd6762e5888b6a4ba0708c6c)
1dnl #
2dnl # 5.0 API change
3dnl #
4AC_DEFUN([ZFS_AC_KERNEL_SRC_TOTALHIGH_PAGES], [
5	ZFS_LINUX_TEST_SRC([totalhigh_pages], [
6		#include <linux/highmem.h>
7	],[
8		unsigned long pages __attribute__ ((unused));
9		pages = totalhigh_pages();
10	])
11])
12
13AC_DEFUN([ZFS_AC_KERNEL_TOTALHIGH_PAGES], [
14	AC_MSG_CHECKING([whether totalhigh_pages() exists])
15	ZFS_LINUX_TEST_RESULT([totalhigh_pages], [
16		AC_MSG_RESULT(yes)
17		AC_DEFINE(HAVE_TOTALHIGH_PAGES, 1, [totalhigh_pages() exists])
18	],[
19		AC_MSG_RESULT(no)
20	])
21])
22