linux/drivers/scsi/qla2xxx
Nicholas Bellinger 6bcbb3174c qla2xxx: Fix incorrect tcm_qla2xxx_free_cmd use during TMR ABORT (v2)
This patch drops two incorrect usages of tcm_qla2xxx_free_cmd()
during TMR ABORT within tcm_qla2xxx_handle_data_work() and
tcm_qla2xxx_aborted_task(), which where attempting to dispatch
into workqueue context to do tcm_qla2xxx_complete_free() and
subsequently invoke transport_generic_free_cmd().

This is incorrect because during TMR ABORT target-core will
drop the outstanding se_cmd->cmd_kref references once it has
quiesced the se_cmd via transport_wait_for_tasks(), and in
the case of qla2xxx it should not attempt to do it's own
transport_generic_free_cmd() once the abort has occured.

As reported by Pascal, this was originally manifesting as a
BUG_ON(cmd->cmd_in_wq) in qlt_free_cmd() during TMR ABORT,
with a LIO backend that had sufficently high enough WRITE
latency to trigger a host side TMR ABORT_TASK.

(v2: Drop the qla_tgt_cmd->write_pending_abort_comp changes,
     as they will be addressed in a seperate series)

Reported-by: Pascal de Bruijn <p.debruijn@unilogic.nl>
Tested-by: Pascal de Bruijn <p.debruijn@unilogic.nl>
Cc: Pascal de Bruijn <p.debruijn@unilogic.nl>
Reported-by: Lukasz Engel <lukasz.engel@softax.pl>
Cc: Lukasz Engel <lukasz.engel@softax.pl>
Acked-by: Himanshu Madhani <himanshu.madhani@cavium.com>
Cc: Quinn Tran <quinn.tran@cavium.com>
Cc: <stable@vger.kernel.org> # 3.10+
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
2017-07-30 16:48:43 -07:00
..
Kconfig scsi: qla2xxx: avoid unused-function warning 2017-07-01 17:14:58 -04:00
Makefile scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_attr.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_bsg.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_bsg.h qla2xxx: Add bsg interface to support statistics counter reset. 2016-07-15 15:35:37 -04:00
qla_dbg.c scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_dbg.h scsi: qla2xxx: Include Exchange offload/Extended Login into FW dump 2017-06-27 21:21:41 -04:00
qla_def.h scsi: qla2xxx: Send FC4 type NVMe to the management server 2017-06-27 21:21:47 -04:00
qla_devtbl.h
qla_dfs.c scsi: qla2xxx: Move target stat counters from vha to qpair. 2017-06-27 21:21:41 -04:00
qla_fw.h scsi: qla2xxx: Add FC-NVMe command handling 2017-06-27 21:21:47 -04:00
qla_gbl.h scsi: qla2xxx: Send FC4 type NVMe to the management server 2017-06-27 21:21:47 -04:00
qla_gs.c scsi: qla2xxx: Use FC-NVMe FC4 type for FDMI registration 2017-06-27 21:24:00 -04:00
qla_init.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_inline.h scsi: qla2xxx: Add function call to qpair for door bell 2017-06-27 21:21:41 -04:00
qla_iocb.c scsi: qla2xxx: Protect access to qpair members with qpair->qp_lock 2017-07-01 16:49:27 -04:00
qla_isr.c Merge branch 'for-linus' of git://git.kernel.dk/linux-block 2017-07-11 15:36:52 -07:00
qla_mbx.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_mid.c scsi: qla2xxx: Fix mailbox failure while deleting Queue pairs 2017-06-27 21:21:40 -04:00
qla_mr.c Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2017-03-02 14:52:05 -08:00
qla_mr.h
qla_nvme.c qla2xxx: Fix NVMe entry_type for iocb packet on BE system 2017-07-01 17:20:42 -04:00
qla_nvme.h scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_nx2.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_nx2.h qla2xxx: Move two arrays from header files to .c files 2017-01-17 11:26:41 -08:00
qla_nx.c scsi: qla2xxx: fix a bunch of typos and spelling mistakes 2017-07-01 17:12:31 -04:00
qla_nx.h scsi: qla2xxx: remove writeq/readq function definitions 2017-06-12 20:48:08 -04:00
qla_os.c scsi: qla2xxx: Add FC-NVMe F/W initialization and transport registration 2017-06-27 21:21:47 -04:00
qla_settings.h
qla_sup.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
qla_target.c SCSI fixes on 20170715 2017-07-17 12:26:12 -07:00
qla_target.h Revert "qla2xxx: Fix incorrect tcm_qla2xxx_free_cmd use during TMR ABORT" 2017-07-11 10:56:38 -07:00
qla_tmpl.c scsi: qla2xxx: Retain loop test for fwdump length exceeding buffer length 2017-06-12 20:48:07 -04:00
qla_tmpl.h
qla_version.h scsi: qla2xxx: Update Driver version to 10.00.00.00-k 2017-06-27 21:24:13 -04:00
tcm_qla2xxx.c qla2xxx: Fix incorrect tcm_qla2xxx_free_cmd use during TMR ABORT (v2) 2017-07-30 16:48:43 -07:00
tcm_qla2xxx.h qla2xxx: Track I-T nexus as single fc_port struct 2017-02-08 23:34:07 -08:00