f2fs: fix missing bio_alloc(1)

For discard commands, we should use bio_alloc(1) in old versions.

Fixes: 373bb0247a ("f2fs: support async discard based on v4.9")
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
Jaegeuk Kim
2017-02-23 09:52:35 -08:00
parent 33f44e9f9c
commit 6cd8a15438

View File

@@ -769,7 +769,7 @@ static int __blkdev_issue_discard(struct block_device *bdev, sector_t sector,
if (ret)
return ret;
}
bio = f2fs_bio_alloc(0);
bio = f2fs_bio_alloc(1);
bio->bi_iter.bi_sector = sector;
bio->bi_bdev = bdev;
bio_set_op_attrs(bio, op, 0);