linux-brain/drivers/target
David Disseldorp b454d754cb scsi: target/iblock: fix WRITE SAME zeroing
commit 1d2ff149b263c9325875726a7804a0c75ef7112e upstream.

SBC4 specifies that WRITE SAME requests with the UNMAP bit set to zero
"shall perform the specified write operation to each LBA specified by the
command".  Commit 2237498f0b ("target/iblock: Convert WRITE_SAME to
blkdev_issue_zeroout") modified the iblock backend to call
blkdev_issue_zeroout() when handling WRITE SAME requests with UNMAP=0 and a
zero data segment.

The iblock blkdev_issue_zeroout() call incorrectly provides a flags
parameter of 0 (bool false), instead of BLKDEV_ZERO_NOUNMAP.  The bool
false parameter reflects the blkdev_issue_zeroout() API prior to commit
ee472d835c ("block: add a flags argument to (__)blkdev_issue_zeroout")
which was merged shortly before 2237498f0b.

Link: https://lore.kernel.org/r/20200419163109.11689-1-ddiss@suse.de
Fixes: 2237498f0b ("target/iblock: Convert WRITE_SAME to blkdev_issue_zeroout")
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: David Disseldorp <ddiss@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-05-06 08:13:31 +02:00
..
iscsi scsi: target: fix hang when multiple threads try to destroy the same iscsi session 2020-04-21 09:03:11 +02:00
loopback SCSI misc on 20180815 2018-08-15 22:06:26 -07:00
sbp scsi: target: srp, vscsi, sbp, qla: use target_remove_session 2018-08-02 15:29:31 -04:00
tcm_fc scsi: tcm_fc: use target_remove_session 2018-08-02 15:29:31 -04:00
Kconfig target: don't depend on SCSI 2018-08-02 15:19:49 -06:00
Makefile
target_core_alua.c
target_core_alua.h
target_core_configfs.c scsi: target: add helper to check if dev is configured 2018-07-30 23:17:53 -04:00
target_core_device.c scsi: target/core: Fix a race condition in the LUN lookup code 2020-01-27 14:50:38 +01:00
target_core_fabric_configfs.c scsi: target: add helper to check if dev is configured 2018-07-30 23:17:53 -04:00
target_core_fabric_lib.c scsi: target: fix PR IN / READ FULL STATUS for FC 2020-05-02 17:25:56 +02:00
target_core_file.c scsi: target: target/file: Add support of direct and async I/O 2018-05-14 22:40:08 -04:00
target_core_file.h scsi: target: target/file: Add support of direct and async I/O 2018-05-14 22:40:08 -04:00
target_core_hba.c
target_core_iblock.c scsi: target/iblock: fix WRITE SAME zeroing 2020-05-06 08:13:31 +02:00
target_core_iblock.h scsi: target/core: Use the SECTOR_SHIFT constant 2019-09-16 08:22:16 +02:00
target_core_internal.h scsi: target: Fold core_tmr_handle_tas_abort() into transport_cmd_finish_abort() 2018-07-02 16:44:31 -04:00
target_core_pr.c scsi: target: Fix truncated PR-in ReadKeys response 2018-06-19 21:36:37 -04:00
target_core_pr.h
target_core_pscsi.c SCSI misc on 20180610 2018-06-10 13:01:12 -07:00
target_core_pscsi.h
target_core_rd.c
target_core_rd.h
target_core_sbc.c scsi: target: Use config_item_name() instead of open-coding it 2018-07-02 16:44:30 -04:00
target_core_spc.c scsi: target: use consistent left-aligned ASCII INQUIRY data 2019-01-26 09:32:38 +01:00
target_core_stat.c
target_core_tmr.c scsi: target: Fold core_tmr_handle_tas_abort() into transport_cmd_finish_abort() 2018-07-02 16:44:31 -04:00
target_core_tpg.c
target_core_transport.c scsi: target/core: Use kmem_cache_free() instead of kfree() 2019-02-23 09:07:26 +01:00
target_core_ua.c scsi: target: Remove se_dev_entry.ua_count 2018-07-02 16:44:32 -04:00
target_core_ua.h scsi: target: Fix handling of removed LUNs 2018-07-02 16:44:32 -04:00
target_core_user.c scsi: target: tcmu: reset_ring should reset TCMU_DEV_BIT_BROKEN 2020-05-02 17:25:56 +02:00
target_core_xcopy.c scsi: target/core: Make sure that target_wait_for_sess_cmds() waits long enough 2019-01-26 09:32:38 +01:00
target_core_xcopy.h