From f6f174e6d16b9ca940f14a4cad884a963f6c6300 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Thu, 1 Nov 2018 04:18:26 +0000 Subject: [PATCH] scst: Kernel v4.15 build fix git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.3.x@7553 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/src/scst_lib.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scst/src/scst_lib.c b/scst/src/scst_lib.c index 08fedff24..0a2c5842f 100644 --- a/scst/src/scst_lib.c +++ b/scst/src/scst_lib.c @@ -7979,12 +7979,18 @@ static struct request *blk_make_request(struct request_queue *q, blk_put_request(rq); return ERR_PTR(ret); } -#else +#elif LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0) ret = blk_rq_append_bio(rq, bio); if (unlikely(ret)) { blk_put_request(rq); return ERR_PTR(ret); } +#else + ret = blk_rq_append_bio(rq, &bio); + if (unlikely(ret)) { + blk_put_request(rq); + return ERR_PTR(ret); + } #endif }