1dnl # 2dnl # 5.16 API change 3dnl # add_disk grew a must-check return code 4dnl # 5AC_DEFUN([ZFS_AC_KERNEL_SRC_ADD_DISK], [ 6 ZFS_LINUX_TEST_SRC([add_disk_ret], [ 7 #include <linux/blkdev.h> 8 ], [ 9 struct gendisk *disk = NULL; 10 int err = add_disk(disk); 11 err = err; 12 ]) 13]) 14 15AC_DEFUN([ZFS_AC_KERNEL_ADD_DISK], [ 16 AC_MSG_CHECKING([whether add_disk() returns int]) 17 ZFS_LINUX_TEST_RESULT([add_disk_ret], 18 [ 19 AC_MSG_RESULT(yes) 20 AC_DEFINE(HAVE_ADD_DISK_RET, 1, 21 [add_disk() returns int]) 22 ], [ 23 AC_MSG_RESULT(no) 24 ]) 25]) 26