qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Thomas Schmitt <scdbackup@gmx.net>
Cc: kwolf@redhat.com, stefanha@gmail.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Do you have a use for a tester of virtio-scsi with CD drives ?
Date: Sat, 05 Nov 2011 16:53:17 +0100	[thread overview]
Message-ID: <4EB55BED.1080605@redhat.com> (raw)
In-Reply-To: <97415193721205@192.168.2.69>

On 11/05/2011 03:37 PM, Thomas Schmitt wrote:
> MMC-3 5.2 and MMC-5 6.2.3 state about processing of command BLANK with
> Immed bit set to one:
> "In response to the REQUEST SENSE command, unless an error has occurred,
>   the Drive shall return a SK/ASC/ASCQ values set to
>   NOT READY/LOGICAL UNIT NOT READY/OPERATION IN PROGRESS,
>   with the sense key specific bytes set for progress indication."
>
> But libburn gets on qemu
>
>    TEST UNIT READY
>    00 00 00 00 00 00
>    +++ sense data = 71 00 02 00 00 00 00 0A 00 00 00 00 04 08 00 80 24 8B
>    +++ key=2  asc=04h  ascq=08h   (     0 ms)
>
>    REQUEST SENSE
>    03 00 00 00 12 00
>    From drive: 18b
>    f0 00 00 00 00 00 00 0a 00 00 00 00 00 00 00 00 00 00
>         0 ms
>
> It is ok that TEST UNIT READY reports the sense data with
>    2 04 08 LOGICAL UNIT NOT READY, LONG WRITE IN PROGRESS
> But it is not ok that REQUEST SENSE does not do the same.
> On qemu it reports:
>    0 00 00 NO ADDITIONAL SENSE INFORMATION

This is because QEMU always emulates REQUEST SENSE and always returns 
the sense data from the last request.  Is this git master or 0.15?  For 
git master, I would have expected REQUEST SENSE to return the correct 
sense data, but without updating it.

In general, it seems safer (and simpler?) if libburn uses TEST UNIT 
READY and its autosense data to report progress.  REQUEST SENSE would be 
used if SG_IO reports CHECK CONDITION without SG_ERR_DRIVER_SENSE (but 
modern OSes will always emulate autosense even if the HBA does not 
support it) and possibly if TEST UNIT READY returns GOOD which is 
allowed by deprecated in MMC.

Paolo

  reply	other threads:[~2011-11-05 15:53 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-01 17:27 [Qemu-devel] Do you have a use for a tester of virtio-scsi with CD drives ? Thomas Schmitt
2011-11-01 21:03 ` Thomas Schmitt
2011-11-02 11:25   ` Stefan Hajnoczi
2011-11-02 12:08     ` Paolo Bonzini
2011-11-02 16:26       ` Thomas Schmitt
2011-11-02 16:34         ` Paolo Bonzini
2011-11-02 18:05           ` Thomas Schmitt
2011-11-02 19:50             ` Paolo Bonzini
2011-11-02 21:22               ` Thomas Schmitt
2011-11-02 22:08                 ` Thomas Schmitt
2011-11-02 22:16                   ` [Qemu-devel] Compile error Frans de Boer
2011-11-02 22:19                     ` Anthony Liguori
2011-11-02 22:31                       ` Frans de Boer
2011-11-03  7:49                 ` [Qemu-devel] Do you have a use for a tester of virtio-scsi with CD drives ? Paolo Bonzini
2011-11-03  9:15                   ` Thomas Schmitt
2011-11-03  9:36                     ` Paolo Bonzini
2011-11-03 13:10                   ` Thomas Schmitt
2011-11-03 22:30                     ` Thomas Schmitt
2011-11-04  9:18                       ` Thomas Schmitt
2011-11-04  9:38                         ` Paolo Bonzini
2011-11-04 11:09                           ` Thomas Schmitt
2011-11-04 11:31                             ` Paolo Bonzini
2011-11-04 13:03                               ` Thomas Schmitt
2011-11-04 20:28                                 ` Thomas Schmitt
2011-11-05  8:33                                   ` Paolo Bonzini
2011-11-05 13:00                                     ` Thomas Schmitt
2011-11-05 14:37                                   ` Thomas Schmitt
2011-11-05 15:53                                     ` Paolo Bonzini [this message]
2011-11-05 16:38                                       ` Thomas Schmitt
2011-11-05 20:47                                     ` Thomas Schmitt
2011-11-06  8:17                                       ` Paolo Bonzini
2011-11-06 10:35                                         ` Thomas Schmitt
2011-11-06 20:14                                         ` Thomas Schmitt
2011-11-07  8:02                                           ` Paolo Bonzini
2011-11-07 10:04                                             ` Thomas Schmitt
2011-11-07 11:13                                               ` Paolo Bonzini
2011-11-07 11:24                                                 ` Zhi Yong Wu
2011-11-07 11:29                                                   ` Paolo Bonzini
2011-11-07 11:40                                                     ` Zhi Yong Wu
2011-11-06  9:31                                       ` Thomas Schmitt
2011-11-04 13:26                       ` Andreas Färber
2011-11-04 14:46                         ` Thomas Schmitt
2011-11-07  8:48             ` Zhi Yong Wu
2011-11-02 15:15     ` Thomas Schmitt
2011-11-02 16:22       ` Paolo Bonzini

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=4EB55BED.1080605@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=scdbackup@gmx.net \
    --cc=stefanha@gmail.com \
    /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).