4 dnl # The bio_set_dev() helper macro was introduced as part of the transition
5 dnl # to have struct gendisk in struct bio.
9 dnl # The bio_set_dev() helper macro was updated to internally depend on
10 dnl # bio_associate_blkg() symbol which is exported GPL-only.
12 AC_DEFUN([ZFS_AC_KERNEL_SRC_BIO_SET_DEV], [
13 ZFS_LINUX_TEST_SRC([bio_set_dev], [
14 #include <linux/bio.h>
17 struct block_device *bdev = NULL;
18 struct bio *bio = NULL;
19 bio_set_dev(bio, bdev);
20 ], [], [$ZFS_META_LICENSE])
23 AC_DEFUN([ZFS_AC_KERNEL_BIO_SET_DEV], [
24 AC_MSG_CHECKING([whether bio_set_dev() is available])
25 ZFS_LINUX_TEST_RESULT([bio_set_dev], [
27 AC_DEFINE(HAVE_BIO_SET_DEV, 1, [bio_set_dev() is available])
29 AC_MSG_CHECKING([whether bio_set_dev() is GPL-only])
30 ZFS_LINUX_TEST_RESULT([bio_set_dev_license], [
34 AC_DEFINE(HAVE_BIO_SET_DEV_GPL_ONLY, 1,
35 [bio_set_dev() GPL-only])