scst_vdisk: Fix a bug in the Linux kernel v4.13 port

See also trunk r7240.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7248 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2017-10-09 18:10:48 +00:00
parent a9750a6bff
commit 16fe64bc13
2 changed files with 2 additions and 1 deletions

View File

@@ -57,6 +57,7 @@ static inline struct bio_set *bioset_create_backport(unsigned int pool_size,
return bioset_create(pool_size, front_pad);
}
#define bioset_create bioset_create_backport
#define BIOSET_NEED_BVECS 1
#endif
/* <linux/blkdev.h> */

View File

@@ -7818,7 +7818,7 @@ static int vdisk_create_bioset(struct scst_vdisk_dev *virt_dev)
EXTRACHECKS_BUG_ON(virt_dev->vdisk_bioset || !virt_dev->blockio);
/* Pool size doesn't really matter */
virt_dev->vdisk_bioset = bioset_create(2, 0, 0);
virt_dev->vdisk_bioset = bioset_create(2, 0, BIOSET_NEED_BVECS);
if (virt_dev->vdisk_bioset == NULL) {
PRINT_ERROR("Failed to create bioset (dev %s)", virt_dev->name);
res = -ENOMEM;