static inline void ssd_bio_endio(struct bio *bio, int error)
{
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,4,0))
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(4,13,0))
bio->bi_error = error;
+#else
+ bio->bi_status = errno_to_blk_status(error);
+#endif
bio_endio(bio);
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24))
bio_endio(bio, error);
goto out;
}
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,13,0))
+ blk_queue_split(q, &bio);
+#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0))
blk_queue_split(q, &bio, q->bio_split);
#endif