MFC r267641:
Add some more CTL_FLAG_ABORT check points. This should allow to abort commands doing mostly disk I/O, such as VERIFY or WRITE SAME. Before this change CTL_FLAG_ABORT was only checked around data moves, which for these commands may not happen for a very long time.
This commit is contained in:
parent
37a9790756
commit
dc2d478426
@ -5009,9 +5009,10 @@ ctl_data_submit_done(union ctl_io *io)
|
||||
* If there is an error, though, we don't want to keep processing.
|
||||
* Instead, just send status back to the initiator.
|
||||
*/
|
||||
if ((io->io_hdr.flags & CTL_FLAG_IO_CONT)
|
||||
&& (((io->io_hdr.status & CTL_STATUS_MASK) == CTL_STATUS_NONE)
|
||||
|| ((io->io_hdr.status & CTL_STATUS_MASK) == CTL_SUCCESS))) {
|
||||
if ((io->io_hdr.flags & CTL_FLAG_IO_CONT) &&
|
||||
(io->io_hdr.flags & CTL_FLAG_ABORT) == 0 &&
|
||||
((io->io_hdr.status & CTL_STATUS_MASK) == CTL_STATUS_NONE ||
|
||||
(io->io_hdr.status & CTL_STATUS_MASK) == CTL_SUCCESS)) {
|
||||
io->scsiio.io_cont(io);
|
||||
return;
|
||||
}
|
||||
|
@ -944,8 +944,9 @@ ctl_be_block_cw_done_ws(struct ctl_be_block_io *beio)
|
||||
|
||||
io = beio->io;
|
||||
ctl_free_beio(beio);
|
||||
if (((io->io_hdr.status & CTL_STATUS_MASK) != CTL_STATUS_NONE)
|
||||
&& ((io->io_hdr.status & CTL_STATUS_MASK) != CTL_SUCCESS)) {
|
||||
if ((io->io_hdr.flags & CTL_FLAG_ABORT) ||
|
||||
((io->io_hdr.status & CTL_STATUS_MASK) != CTL_STATUS_NONE &&
|
||||
(io->io_hdr.status & CTL_STATUS_MASK) != CTL_SUCCESS)) {
|
||||
ctl_config_write_done(io);
|
||||
return;
|
||||
}
|
||||
@ -1186,8 +1187,9 @@ ctl_be_block_next(struct ctl_be_block_io *beio)
|
||||
io = beio->io;
|
||||
be_lun = beio->lun;
|
||||
ctl_free_beio(beio);
|
||||
if (((io->io_hdr.status & CTL_STATUS_MASK) != CTL_STATUS_NONE)
|
||||
&& ((io->io_hdr.status & CTL_STATUS_MASK) != CTL_SUCCESS)) {
|
||||
if ((io->io_hdr.flags & CTL_FLAG_ABORT) ||
|
||||
((io->io_hdr.status & CTL_STATUS_MASK) != CTL_STATUS_NONE &&
|
||||
(io->io_hdr.status & CTL_STATUS_MASK) != CTL_SUCCESS)) {
|
||||
ctl_data_submit_done(io);
|
||||
return;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user