qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Do you have a use for a tester of virtio-scsi with CD d


From: Thomas Schmitt
Subject: Re: [Qemu-devel] Do you have a use for a tester of virtio-scsi with CD drives ?
Date: Sat, 05 Nov 2011 15:37:49 +0100

Hi,

i completed my tests on DVD-RW (next will be DVD+R).

Sequential DVD-RW can be written with write type Incremental (aka Packet)
and be blanked.

The write run commands of this DVD-RW profile 0x14 are the same as the
ones for profile 0x11 DVD-R. So i boldly declare write success for both.

Thoroughly formatted DVD-RW (profile 0x13) can be written. This state
is achieved by formatting and writing data to all blocks (only possible
on the host system for now).

But i have failures with:

- Write type DAO in sequential blank DVD-RW

- Formatting sequential DVD-RW to overwritable profile 0x13

- Expanding of formatted area of a partially formatted DVD-RW

- Inquiring blanking progress by REQUEST SENSE

--------------------------------------------------------------------

DVD-RW write type DAO makes the guest go stuck.
qemu is on 100 % CPU after:

  MODE SELECT
  55 10 00 00 00 00 00 00 3c 00 
  To drive: 60b
  00 00 00 00 00 00 00 00 05 32 42 05 08 00 00 00 00 00 00 00
  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
       0 ms

  READ TRACK INFORMATION
  52 01 00 00 00 01 00 00 14 00 
  From drive: 20b
  00 26 01 01 00 04 41 01 00 00 00 00 00 00 00 00 00 23 12 80
       4 ms

  START/STOP UNIT
  1b 01 00 00 01 00 
  1808 ms

  TEST UNIT READY
  00 00 00 00 00 00 
       0 ms

  START/STOP UNIT
  1b 00 00 00 01 00 

qemu can be killed (no -9 necessary). The drive is accessible by the
host system afterwards. qemu can be restarted and the drive can be used,
without the need for rebooting the host.
So it is not as bad as with CD SAO.

The next command after the stuck START/STOP UNIT would have been RESERVE
TRACK. I suspect that it happened although i did not see its log
message, because the medium is in unhealthy state afterwards.

It pretends to be blank with only 195 MB free and refuses on RESERVE TRACK.
195 MiB is about the expected size of the failed session.

Writing to the medium in this state on the host system made the drive
mad. The drive did not get ready after all data were written. After about
3 minutes it began to make lots of noise. Only reboot did help.
After reboot it was possible to blank the medium, and to write a DAO
session on the host system.

--------------------------------------------------------------------

The attempt to format a DVD-RW to profile 0x13 "Restricted Overwrite"
fails:

  FORMAT UNIT
  04 11 00 00 00 00 
  To drive: 12b
  00 02 00 08 00 23 10 20 00 00 08 00 
  +++ sense data = F0 00 0B 00 00 00 00 0A 00 00 00 00 00 00 00 00 00 00
  +++ key=B  asc=00h  ascq=00h   (   488 ms)

Formatted DVD-RW behave like DVD+RW, except their hard alignment
constraints to full 32 kiB ECC blocks (this is the "restriction").
They usually have a longer life than sequential DVD-RW.

This FORMAT UNIT command can be performed without special preparations.

--------------------------------------------------------------------

DVD-RW with profile 0x13 are fully formatted only after they were
entirely overwritten with data. In this case, formatting has to be
restarted before writing further data onto medium.

As the other FORMAT UNIT commands, it fails:

  FORMAT UNIT
  04 11 00 00 00 00 
  To drive: 12b
  00 02 00 08 00 20 71 e0 4c 00 00 10 
  +++ sense data = F0 00 0B 00 00 00 00 0A 00 00 00 00 00 00 00 00 00 00
  +++ key=B  asc=00h  ascq=00h   (   544 ms)

--------------------------------------------------------------------

REQUEST SENSE does not behave as prescribed for blanking DVD-RW by

  BLANK
  a1 10 00 00 00 00 00 00 00 00 00 00 

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 causes libburn's progress meter to show no progress, although i
can see the two last bytes of the sense data counting upwards.
(0= 0 % done , 65335 = 100 % done)

On the host system, i see:

  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 00 00
  +++ key=2  asc=04h  ascq=08h   (     4 ms)

  REQUEST SENSE
  03 00 00 00 12 00 
  From drive: 18b
  70 00 02 00 00 00 00 0a 00 00 00 00 04 08 00 80 00 00 
     0 ms
  ...

  REQUEST SENSE
  03 00 00 00 12 00 
  From drive: 18b
  70 00 02 00 00 00 00 0a 00 00 00 00 04 08 00 80 05 ea 
       0 ms

So that xorriso can report:

  xorriso : UPDATE : Blanking  ( 3.3% done in 25 seconds )

The BLANK command can be performed without special preparations.
The medium should not already be blank, though.

--------------------------------------------------------------------

Have a nice day :)

Thomas




reply via email to

[Prev in Thread] Current Thread [Next in Thread]