WSL2-Linux-Kernel/include
Damien Le Moal 70e42fd02c scsi: sd_zbc: Write unlock zone from sd_uninit_cmnd()
Releasing a zone write lock only when the write commnand that acquired
the lock completes can cause deadlocks due to potential command
reordering if the lock owning request is requeued and not executed. This
problem exists only with the scsi-mq path as, unlike the legacy path,
requests are moved out of the dispatch queue before being prepared and
so before locking a zone for a write command.

Since sd_uninit_cmnd() is now always called when a request is requeued,
call sd_zbc_write_unlock_zone() from that function for write requests
that acquired a zone lock instead of from sd_done(). Acquisition of a zone
lock by a write command is indicated using the new command
flag SCMD_ZONE_WRITE_LOCK.

Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Bart Van Assche <Bart.VanAssche@wdc.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2017-08-16 20:01:31 -04:00
..
acpi More ACPI updates for v4.13-rc1 2017-07-10 15:19:40 -07:00
asm-generic asm-generic/bug.h: declare struct pt_regs; before function prototype 2017-07-10 16:32:34 -07:00
clocksource
crypto crypto: engine - replace pr_xxx by dev_xxx 2017-06-19 14:19:54 +08:00
drm main drm pull for v4.13 2017-07-09 18:48:37 -07:00
dt-bindings This is the bulk of GPIO changes for the v4.13 series: 2017-07-07 12:40:27 -07:00
keys
kvm
linux scsi: bnx2i: Simplify cpu hotplug code 2017-07-26 21:51:25 -04:00
math-emu
media main drm pull for v4.13 2017-07-09 18:48:37 -07:00
memory
misc cxl: Export library to support IBM XSL 2017-07-03 23:07:03 +10:00
net Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-07-08 12:01:22 -07:00
pcmcia
ras trace, ras: add ARM processor error trace event 2017-06-22 18:22:05 +01:00
rdma Fixes #3 for 4.12-rc 2017-07-06 11:45:08 -07:00
rxrpc
scsi scsi: sd_zbc: Write unlock zone from sd_uninit_cmnd() 2017-08-16 20:01:31 -04:00
soc Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2017-07-05 12:31:59 -07:00
sound ASoC: Updates for v4.13 2017-07-03 19:51:42 +02:00
target
trace Merge branch 'akpm' (patches from Andrew) 2017-07-10 16:58:42 -07:00
uapi Fix up over-eager 'wait_queue_t' renaming 2017-07-10 11:40:19 -07:00
video
xen This is the first pull request for the new dma-mapping subsystem 2017-07-06 19:20:54 -07:00