|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [qemu-upstream-unstable] scsi: fix cancellation when I/O was completed but DMA was not.
commit b0a231a9a9ab7cca0ad24b8c2eb2249e17727fdb
Author: Paolo Bonzini <pbonzini@xxxxxxxxxx>
AuthorDate: Mon Jan 12 11:47:30 2015 +0100
Commit: Michael Roth <mdroth@xxxxxxxxxxxxxxxxxx>
CommitDate: Sun Feb 22 18:12:51 2015 -0600
scsi: fix cancellation when I/O was completed but DMA was not.
Commit d577646 (scsi: Introduce scsi_req_cancel_complete, 2014-09-25)
was supposed to have no semantic change, but it missed a case. When
r->aiocb has already been NULLed, but DMA was not complete and the
SCSI layer was waiting for scsi_req_continue, after the patch the
SCSI layer will not call the .cancel callback of SCSIBusInfo.
Fixes: d5776465ee9a55815792efa34d79de240f4ffd99
Cc: qemu-stable@xxxxxxxxxx
Reported-by: Dr. David Alan Gilbert <dgilbert@xxxxxxxxxx>
Tested-by: Dr. David Alan Gilbert <dgilbert@xxxxxxxxxx>
Reviewed-by: Fam Zheng <famz@xxxxxxxxxx>
Signed-off-by: Paolo Bonzini <pbonzini@xxxxxxxxxx>
(cherry picked from commit 488eef2f1d16c97cf7f9ebf644ecafa1ea1e9acc)
Signed-off-by: Michael Roth <mdroth@xxxxxxxxxxxxxxxxxx>
---
hw/scsi/scsi-bus.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/hw/scsi/scsi-bus.c b/hw/scsi/scsi-bus.c
index 24f7b74..9b740a3 100644
--- a/hw/scsi/scsi-bus.c
+++ b/hw/scsi/scsi-bus.c
@@ -1770,6 +1770,8 @@ void scsi_req_cancel(SCSIRequest *req)
req->io_canceled = true;
if (req->aiocb) {
blk_aio_cancel(req->aiocb);
+ } else {
+ scsi_req_cancel_complete(req);
}
}
--
generated by git-patchbot for /home/xen/git/qemu-upstream-unstable.git
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |