linux/drivers/target
Nicholas Bellinger 7f54ab5ff5 target: Drop incorrect ABORT_TASK put for completed commands
This patch fixes a recent ABORT_TASK regression associated
with commit febe562c, where a left-over target_put_sess_cmd()
would still be called when __target_check_io_state() detected
a command has already been completed, and explicit ABORT must
be avoided.

Note commit febe562c dropped the local kref_get_unless_zero()
check in core_tmr_abort_task(), but did not drop this extra
corresponding target_put_sess_cmd() in the failure path.

So go ahead and drop this now bogus target_put_sess_cmd(),
and avoid this potential use-after-free.

Reported-by: Dan Lane <dracodan@gmail.com>
Cc: Quinn Tran <quinn.tran@qlogic.com>
Cc: Himanshu Madhani <himanshu.madhani@qlogic.com>
Cc: Sagi Grimberg <sagig@mellanox.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Hannes Reinecke <hare@suse.de>
Cc: Andy Grover <agrover@redhat.com>
Cc: Mike Christie <mchristi@redhat.com>
Cc: stable@vger.kernel.org # 3.14+
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
2016-03-05 20:24:47 -08:00
..
iscsi Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2016-01-20 17:20:53 -08:00
loopback tcm_loop: Show address of tpg in configfs 2015-11-29 03:01:45 -08:00
sbp sbp-target: Remove a superfluous forward declaration 2016-01-06 13:39:53 -08:00
tcm_fc tcm_fc: Convert acl lookup to modern get_initiator_node_acl usage 2016-01-12 23:17:51 -08:00
Kconfig
Makefile
target_core_alua.c
target_core_alua.h
target_core_configfs.c target: Fix incorrect unmap_zeroes_data_store return 2016-02-10 20:34:56 -08:00
target_core_device.c target: Fix WRITE_SAME/DISCARD conversion to linux 512b sectors 2016-01-29 19:29:34 -08:00
target_core_fabric_configfs.c target: use per-attribute show and store methods 2015-10-13 22:17:49 -07:00
target_core_fabric_lib.c
target_core_file.c target: Fix WRITE_SAME/DISCARD conversion to linux 512b sectors 2016-01-29 19:29:34 -08:00
target_core_file.h
target_core_hba.c target: Fix target_sense_desc_format NULL pointer dereference 2015-09-24 23:17:23 -07:00
target_core_iblock.c target: Fix WRITE_SAME/DISCARD conversion to linux 512b sectors 2016-01-29 19:29:34 -08:00
target_core_iblock.h
target_core_internal.h target: Drop legacy se_cmd->task_stop_comp + REQUEST_STOP usage 2016-02-06 15:59:56 -08:00
target_core_pr.c target: Fix spelling + remove set-but-not-used variables 2016-01-06 13:38:37 -08:00
target_core_pr.h
target_core_pscsi.c block: add a bi_error field to struct bio 2015-07-29 08:55:15 -06:00
target_core_pscsi.h
target_core_rd.c Merge branch 'for-4.3/sg' of git://git.kernel.dk/linux-block 2015-09-02 13:22:38 -07:00
target_core_rd.h
target_core_sbc.c Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2016-01-20 17:20:53 -08:00
target_core_spc.c target/sbc: Add LBPRZ attribute + control CDB emulation 2016-01-06 13:39:55 -08:00
target_core_stat.c target/stat: print full t10_wwn.model buffer 2015-11-28 21:23:13 -08:00
target_core_tmr.c target: Drop incorrect ABORT_TASK put for completed commands 2016-03-05 20:24:47 -08:00
target_core_tpg.c target: Obtain se_node_acl->acl_kref during get_initiator_node_acl 2016-01-20 01:34:15 -08:00
target_core_transport.c target/transport: add flag to indicate CPU Affinity is observed 2016-02-10 23:08:55 -08:00
target_core_ua.c
target_core_ua.h
target_core_user.c target/user: Fix cast from pointer to phys_addr_t 2016-02-06 15:59:57 -08:00
target_core_xcopy.c target: Attach EXTENDED_COPY local I/O descriptors to xcopy_pt_sess 2015-09-11 00:32:26 -07:00
target_core_xcopy.h