]> git.proxmox.com Git - mirror_zfs-debian.git/blame - config/kernel-blk-queue-physical-block-size.m4
Add '--with-spl-timeout' option
[mirror_zfs-debian.git] / config / kernel-blk-queue-physical-block-size.m4
CommitLineData
34037afe
ED
1dnl #
2dnl # 2.6.30 API change
3dnl # The blk_queue_physical_block_size() function was introduced to
4dnl # indicate the smallest I/O the device can write without incurring
5dnl # a read-modify-write penalty.
6dnl #
7AC_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>
13 ],[
14 struct request_queue *q = NULL;
15 unsigned short block_size = 1;
16 (void) blk_queue_physical_block_size(q, block_size);
17 ],[
18 AC_MSG_RESULT(yes)
19 AC_DEFINE(HAVE_BLK_QUEUE_PHYSICAL_BLOCK_SIZE, 1,
20 [blk_queue_physical_block_size() is available])
21 ],[
22 AC_MSG_RESULT(no)
23 ])
24 EXTRA_KCFLAGS="$tmp_flags"
25])