]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - config/kernel-readpages.m4
Silence -Winfinite-recursion warning in luaD_throw()
[FreeBSD/FreeBSD.git] / config / kernel-readpages.m4
1 dnl #
2 dnl # Linux 5.18 removes address_space_operations ->readpages in favour of
3 dnl # ->readahead
4 dnl #
5 AC_DEFUN([ZFS_AC_KERNEL_SRC_VFS_READPAGES], [
6         ZFS_LINUX_TEST_SRC([vfs_has_readpages], [
7                 #include <linux/fs.h>
8
9                 static const struct address_space_operations
10                     aops __attribute__ ((unused)) = {
11                         .readpages = NULL,
12                 };
13         ],[])
14 ])
15
16 AC_DEFUN([ZFS_AC_KERNEL_VFS_READPAGES], [
17         AC_MSG_CHECKING([whether aops->readpages exists])
18         ZFS_LINUX_TEST_RESULT([vfs_has_readpages], [
19                 AC_MSG_RESULT([yes])
20                 AC_DEFINE(HAVE_VFS_READPAGES, 1,
21                         [address_space_operations->readpages exists])
22         ],[
23                 AC_MSG_RESULT([no])
24         ])
25 ])