From c6abe376e9df0943f6f8bf9f6ef01566f5e3ee8b Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Sun, 17 Nov 2019 19:21:33 +0000 Subject: [PATCH] scst_vdisk, async file I/O: Fix a WARN_ON_ONCE() statement git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8661 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/src/dev_handlers/scst_vdisk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scst/src/dev_handlers/scst_vdisk.c b/scst/src/dev_handlers/scst_vdisk.c index c9485c9b4..6d2171274 100644 --- a/scst/src/dev_handlers/scst_vdisk.c +++ b/scst/src/dev_handlers/scst_vdisk.c @@ -3261,7 +3261,7 @@ static enum compl_status_e fileio_exec_async(struct vdisk_cmd_params *p) length = scst_get_buf_next(cmd, &address); } - WARN_ON_ONCE(sg_cnt != scst_get_buf_count(cmd)); + WARN_ON_ONCE(sg_cnt != cmd->sg_cnt); #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 20, 0) iov_iter_kvec(&iter, dir, p->async.kvec, sg_cnt, total);