2 dnl # 2.6.30 API change
3 dnl # The blk_queue_physical_block_size() function was introduced to
4 dnl # indicate the smallest I/O the device can write without incurring
5 dnl # a read-modify-write penalty.
7 AC_DEFUN([ZFS_AC_KERNEL_BLK_QUEUE_PHYSICAL_BLOCK_SIZE], [
8 AC_MSG_CHECKING([whether blk_queue_physical_block_size() is available])
9 tmp_flags="$EXTRA_KCFLAGS"
10 EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
11 ZFS_LINUX_TRY_COMPILE([
12 #include <linux/blkdev.h>
14 struct request_queue *q = NULL;
15 unsigned short block_size = 1;
16 (void) blk_queue_physical_block_size(q, block_size);
19 AC_DEFINE(HAVE_BLK_QUEUE_PHYSICAL_BLOCK_SIZE, 1,
20 [blk_queue_physical_block_size() is available])
24 EXTRA_KCFLAGS="$tmp_flags"