HomeFreeBSD

isp: Improve task aborts handling

Description

isp: Improve task aborts handling

  • When handling notify acknowledge from target code for task abort

request, not only send abort to the firmware, but also delete the
ATIO private data associated with the command. It is required for
proper tag reuse, allowing new "conflicting" commands to be passed
to the target. CTL was already fixed to handle that right, instead
of delaying them in restart queue of the driver.

  • When target finally aborts the command (which it should have

done before the notify ack) we should not send another abort to
the firmware. Since we already sent the abort and deleted ATIO
private data above, just return successful completion here, doing
nothing. Since the tag can be reused by that time, we can not
rely on its uniqueness, so when searching to the ATIO private data
compare also the aborted CCB pointer in addition to the tag.

  • Fix BA_RJT sending in isp_acknak_abts(). While it should be

rare, teach the code to send error responses for ABTS requests.

MFC after: 2 weeks

Details

Provenance
mavAuthored on Mon, Dec 9, 4:52 PM
Parents
rG40fb1b8bc1cf: isp: Fix use after free in aborts handling
Branches
Unknown
Tags
Unknown