linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: John Clark <clarkjc@runbox.com>
To: Tejun Heo <tj@kernel.org>
Cc: Jeff Garzik <jgarzik@pobox.com>, linux-ide@vger.kernel.org
Subject: Re: Interoperability problem with Quantum CD72SH SATA tape drive and libata
Date: Wed, 01 Oct 2008 19:13:25 -0400	[thread overview]
Message-ID: <48E40415.7050607@runbox.com> (raw)
In-Reply-To: <48E2ECA8.8060808@kernel.org>

Tejun Heo wrote:
> John Clark wrote:
>   
>> Hello,
>>
>> I've discovered an issue with the Quantum CD72SH SATA tape drive.  I set
>> it to variable block size, try to write a 5317 byte block with an ATAPI
>> issued WRITE(6), and it hangs.  The drive is connected to an Intel ICH9R
>> in AHCI mode.
>>
>> My debugging efforts have determined that it's a problem with the
>> drive's firmware.  It does not like ATAPI CDBs with odd (& 1) transfer
>> lengths with PIO.  If I let it use DMA, even if it's not a multiple of
>> 16 bytes, then it seems to work:
>>
>> --- libata-core.c.orig    2008-09-27 16:12:46.000000000 -0400
>> +++ libata-core.c    2008-09-27 16:11:29.000000000 -0400
>> @@ -4669,8 +4669,8 @@
>>     /* Don't allow DMA if it isn't multiple of 16 bytes.  Quite a
>>      * few ATAPI devices choke on such DMA requests.
>>      */
>> -    if (unlikely(qc->nbytes & 15))
>> -        return 1;
>> +    // if (unlikely(qc->nbytes & 15))
>> +    //     return 1;
>>
>>     if (ap->ops->check_atapi_dma)
>>         return ap->ops->check_atapi_dma(qc);
>>
>>
>>
>> This is an acceptable solution for my limited use, but I'd like to see
>> it work out of the box.  It seems frightening that there are ATAPI
>> devices out there that choke on PIO requests.  What would you like to do?
>>     
>
> We can create a HORKAGE for it.  Can you please post the result of
> "hdparm -I" of the device?
>
>   
Tejun,

Here it is:

/dev/nst0:

ATAPI Sequential-access device, with removable media
    Model Number:       QUANTUM DAT    DAT72-000               
    Serial Number:      JR001H1            
    Firmware Revision:  VC090000
Standards:
    Used: ATA/ATAPI-7 T13 1532D revision 4a
    Supported: 7 6 5 4
Configuration:
    DRQ response: 50us.
    Packet size: 12 bytes
Capabilities:
    LBA, IORDY(can be disabled)
    DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6
         Cycle time: min=120ns recommended=120ns
    PIO: pio0 pio1 pio2 pio3 pio4
         Cycle time: no flow control=120ns  IORDY flow control=120ns
Commands/features:
    Enabled    Supported:
       *    Power Management feature set
       *    PACKET command feature set
       *    DEVICE_RESET command
       *    NOP cmd
       *    SATA-I signaling speed (1.5Gb/s)
Integrity word not set (found 0x0000, expected 0x6da5)

Thank you.

- John

  reply	other threads:[~2008-10-01 23:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-27 20:25 Interoperability problem with Quantum CD72SH SATA tape drive and libata John Clark
2008-10-01  3:21 ` Tejun Heo
2008-10-01 23:13   ` John Clark [this message]
2008-10-04 20:45     ` Tejun Heo
2008-10-06 19:36       ` John Clark
2008-10-07  1:29         ` Tejun Heo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=48E40415.7050607@runbox.com \
    --to=clarkjc@runbox.com \
    --cc=jgarzik@pobox.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=tj@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).