----- Original Message ----- From: "Kenneth D. Merry" <k...@kdm.org>
To: "Steven Hartland" <s...@freebsd.org>
Cc: <src-committ...@freebsd.org>; <svn-src-...@freebsd.org>; 
<svn-src-head@FreeBSD.org>
Sent: Monday, April 29, 2013 11:56 PM
Subject: Re: svn commit: r249939 - head/sys/cam/scsi


On Fri, Apr 26, 2013 at 16:17:05 +0000, Steven Hartland wrote:
Author: smh
Date: Fri Apr 26 16:17:04 2013
New Revision: 249939
URL: http://svnweb.freebsd.org/changeset/base/249939

Log:
  Added available delete methods discovery during device probe, including the
  maximum sizes for said methods, which are used when processing BIO_DELETE
  requests. This includes updating UNMAP support discovery to be based on
  SBC-3 T10/1799-D Revision 31 specification.
Added ATA TRIM support to cam scsi devices via ATA Pass-Through(16) sys/cam/scsi/scsi_da.c:
          - Added ATA Data Set Management TRIM support via ATA Pass-Through(16)
            as a delete_method

This adds a lot of unnecessary verbosity for devices that don't support ATA
passthrough.  For example:

(da7:iscsi4:0:0:0): ATA COMMAND PASS THROUGH(16). CDB: 85 08 0a 00 00 02 00 00 
00 00 00 00 00 40 ec 00
(da7:iscsi4:0:0:0): CAM status: SCSI Status Error
(da7:iscsi4:0:0:0): SCSI status: Check Condition
(da7:iscsi4:0:0:0): Retrying command (per sense data)
(2:2:0:0): ATA COMMAND PASS THROUGH(16). CDB: 85 08 0a 00 00 02 00 00 00 00 00 
00 00 40 ec 00
(2:2:0:0): Tag: 0x00f6, Type: 1
(2:2:0:0): CTL Status: SCSI Error
(2:2:0:0): SCSI Status: Check Condition
(2:2:0:0): SCSI sense: ILLEGAL REQUEST asc:20,0 (Invalid command operation code)
(2:2:0:0): Command byte 0 is invalid

(da8:iscsi4:0:0:1): ATA COMMAND PASS THROUGH(16). CDB: 85 08 0a 00 00 02 00 00 
00 00 00 00 00 40 ec 00
(da8:iscsi4:0:0:1): CAM status: SCSI Status Error
(da8:iscsi4:0:0:1): SCSI status: Check Condition
(da8:iscsi4:0:0:1): Retrying command (per sense data)
(da8:iscsi4:0:0:1): ATA COMMAND PASS THROUGH(16). CDB: 85 08 0a 00 00 02 00 00 
00 00 00 00 00 40 ec 00
(da8:iscsi4:0:0:1): CAM status: SCSI Status Error
(da8:iscsi4:0:0:1): SCSI status: Check Condition
(da8:iscsi4:0:0:1): Error 5, Retries exhausted

That is with CTL and and trasz's new iSCSI initiator, but you should see it
with any CTL configuration.  (And probably with any controller or device
that doesn't support ATA passthrough.)

So, please:
- Check for the presence of VPD page 0x89 before sending an ATA
  passthrough command.  The spec (sat3r03 in this case) says that
  it "shall" be implemented, so I think we can count on that.
- If the target returns an illegal request sense key, don't retry
  again.  The target will keep returning illegal request

Thanks for the report Ken I'll check this on a card I know doesn't support
pass-through.

   Regards
   Steve
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to