svn commit: r273324 - stable/10/sys/cam/ctl
Alexander Motin
mav at FreeBSD.org
Mon Oct 20 08:08:44 UTC 2014
Author: mav
Date: Mon Oct 20 08:08:43 2014
New Revision: 273324
URL: https://svnweb.freebsd.org/changeset/base/273324
Log:
MFC r273046:
Don't confuse frontend with zero length data moves, just return immediately.
Modified:
stable/10/sys/cam/ctl/ctl.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/cam/ctl/ctl.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl.c Mon Oct 20 08:07:29 2014 (r273323)
+++ stable/10/sys/cam/ctl/ctl.c Mon Oct 20 08:08:43 2014 (r273324)
@@ -10823,15 +10823,9 @@ ctl_inquiry_std(struct ctl_scsiio *ctsio
}
ctsio->scsi_status = SCSI_STATUS_OK;
- if (ctsio->kern_data_len > 0) {
- ctsio->io_hdr.flags |= CTL_FLAG_ALLOCATED;
- ctsio->be_move_done = ctl_config_move_done;
- ctl_datamove((union ctl_io *)ctsio);
- } else {
- ctsio->io_hdr.status = CTL_SUCCESS;
- ctl_done((union ctl_io *)ctsio);
- }
-
+ ctsio->io_hdr.flags |= CTL_FLAG_ALLOCATED;
+ ctsio->be_move_done = ctl_config_move_done;
+ ctl_datamove((union ctl_io *)ctsio);
return (CTL_RETVAL_COMPLETE);
}
@@ -12903,6 +12897,12 @@ ctl_datamove(union ctl_io *io)
return;
}
+ /* Don't confuse frontend with zero length data move. */
+ if (io->scsiio.kern_data_len == 0) {
+ io->scsiio.be_move_done(io);
+ return;
+ }
+
/*
* If we're in XFER mode and this I/O is from the other shelf
* controller, we need to send the DMA to the other side to
More information about the svn-src-stable-10
mailing list