])
])
+dnl #
+dnl # 5.9: added blk_queue_update_readahead(),
+dnl # 5.15: renamed to disk_update_readahead()
+dnl #
+AC_DEFUN([ZFS_AC_KERNEL_SRC_BLK_QUEUE_UPDATE_READAHEAD], [
+ ZFS_LINUX_TEST_SRC([blk_queue_update_readahead], [
+ #include <linux/blkdev.h>
+ ],[
+ struct request_queue q;
+ blk_queue_update_readahead(&q);
+ ])
+
+ ZFS_LINUX_TEST_SRC([disk_update_readahead], [
+ #include <linux/blkdev.h>
+ ],[
+ struct gendisk disk;
+ disk_update_readahead(&disk);
+ ])
+])
+
+AC_DEFUN([ZFS_AC_KERNEL_BLK_QUEUE_UPDATE_READAHEAD], [
+ AC_MSG_CHECKING([whether blk_queue_update_readahead() exists])
+ ZFS_LINUX_TEST_RESULT([blk_queue_update_readahead], [
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_BLK_QUEUE_UPDATE_READAHEAD, 1,
+ [blk_queue_update_readahead() exists])
+ ],[
+ AC_MSG_CHECKING([whether disk_update_readahead() exists])
+ ZFS_LINUX_TEST_RESULT([disk_update_readahead], [
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_DISK_UPDATE_READAHEAD, 1,
+ [disk_update_readahead() exists])
+ ],[
+ AC_MSG_RESULT(no)
+ ])
+ ])
+])
+
dnl #
dnl # 2.6.32 API,
dnl # blk_queue_discard()
AC_DEFUN([ZFS_AC_KERNEL_SRC_BLK_QUEUE], [
ZFS_AC_KERNEL_SRC_BLK_QUEUE_PLUG
ZFS_AC_KERNEL_SRC_BLK_QUEUE_BDI
+ ZFS_AC_KERNEL_SRC_BLK_QUEUE_UPDATE_READAHEAD
ZFS_AC_KERNEL_SRC_BLK_QUEUE_DISCARD
ZFS_AC_KERNEL_SRC_BLK_QUEUE_SECURE_ERASE
ZFS_AC_KERNEL_SRC_BLK_QUEUE_FLAG_SET
AC_DEFUN([ZFS_AC_KERNEL_BLK_QUEUE], [
ZFS_AC_KERNEL_BLK_QUEUE_PLUG
ZFS_AC_KERNEL_BLK_QUEUE_BDI
+ ZFS_AC_KERNEL_BLK_QUEUE_UPDATE_READAHEAD
ZFS_AC_KERNEL_BLK_QUEUE_DISCARD
ZFS_AC_KERNEL_BLK_QUEUE_SECURE_ERASE
ZFS_AC_KERNEL_BLK_QUEUE_FLAG_SET