mirror of
https://github.com/SCST-project/scst.git
synced 2026-09-28 18:55:40 +00:00
scst, iscsi-scst: Port to RHEL / CentOS 8.2
Apparently the Linux kernel v4.20 iov_iter_kvec() function has been backported to RHEL / CentOS 8.2. This patch fixes the following kernel warning: WARNING: CPU: 26 PID: 21141 at lib/iov_iter.c:1083 iov_iter_kvec+0x25/0x30 Call Trace: fileio_exec_async+0x216/0x3a0 [scst_vdisk] fileio_exec_write+0x3b9/0x450 [scst_vdisk] vdev_do_job+0x34/0xc0 [scst_vdisk] scst_do_real_exec+0x54/0x100 [scst] scst_exec_check_blocking+0xbb/0x210 [scst] scst_process_active_cmd+0x64d/0x1550 [scst] scst_cmd_thread+0x170/0x5a0 [scst] kthread+0x112/0x130 ret_from_fork+0x35/0x40 See also https://github.com/bvanassche/scst/issues/26. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@9026 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -3261,11 +3261,7 @@ static enum compl_status_e fileio_exec_async(struct vdisk_cmd_params *p)
|
||||
|
||||
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);
|
||||
#else
|
||||
iov_iter_kvec(&iter, ITER_KVEC | dir, p->async.kvec, sg_cnt, total);
|
||||
#endif
|
||||
*iocb = (struct kiocb) {
|
||||
.ki_pos = p->loff,
|
||||
.ki_filp = fd,
|
||||
|
||||
Reference in New Issue
Block a user