Re: [PATCH] SG_IO readcd and various bugs

uaca
2003-06-01T07:37:04Z

Hi all

I tested 2.5.70 with scsi-ioctl-2 patch

It works fine until It has to read the last sectors.
I get the following messages from readcd, using different CD-Rs

agapito:~# readcd dev=/dev/hdc f=/dev/null
Read speed: 8450 kB/s (CD 48x, DVD 6x).
Write speed: 7056 kB/s (CD 40x, DVD 5x).
Capacity: 353137 Blocks = 706274 kBytes = 689 MBytes = 723 prMB
Sectorsize: 2048 Bytes
Copy from SCSI (0,0,0) disk to file '/dev/null'
end: 353137
readcd: Success. read_g1: scsi sendcmd: no error
CDB: 28 00 00 05 63 5B 00 00 16 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 05 00 00 00 00 0A 00 00 00 00 64 00 00 00
Sense Key: 0x5 Illegal Request, Segment 0
Sense Code: 0x64 Qual 0x00 (illegal mode for this track) Fru 0x0
Sense flags: Blk 0 (not valid)
resid: 45056
cmd finished after 3.267s timeout 40s
readcd: Success. Cannot read source disk
readcd: Retrying from sector 353115.
.....................~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~
readcd: Success. Error on sector 353135 not corrected. Total of 1 errors.

Time total: 1094.406sec
Read 706230.00 kB at 645.3 kB/sec.

agapito:~# readcd dev=/dev/hdc f=/dev/null
Read speed: 8450 kB/s (CD 48x, DVD 6x).
Write speed: 7056 kB/s (CD 40x, DVD 5x).
Capacity: 355841 Blocks = 711682 kBytes = 695 MBytes = 728 prMB
Sectorsize: 2048 Bytes
Copy from SCSI (0,0,0) disk to file '/dev/null'
end: 355841
readcd: Success. read_g1: scsi sendcmd: no error
CDB: 28 00 00 05 6D F0 00 00 11 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 05 00 00 00 00 0A 00 00 00 00 64 00 00 00
Sense Key: 0x5 Illegal Request, Segment 0
Sense Code: 0x64 Qual 0x00 (illegal mode for this track) Fru 0x0
Sense flags: Blk 0 (not valid)
resid: 34816
cmd finished after 2.965s timeout 40s
readcd: Success. Cannot read source disk
readcd: Retrying from sector 355824.
................~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~+~~~-~~~
readcd: Success. Error on sector 355839 not corrected. Total of 1 errors.

Time total: 1058.468sec
Read 711648.00 kB at 672.3 kB/sec.

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

dmesg shows several
hdc: confused, missing data
and then (sometimes)
cdrom_newpc_intr: 2048 residual after xfer
for each run of readcd

readcd version comes from

ulisses@agapito:~$ dpkg -l | grep cdrecord
ii cdrecord 2.0+a14-1 A command line CD writing tool

the CDR/W recorder is not the best thing on this world...
agapito:~# cdrecord dev=/dev/hdc -checkdrive
Cdrecord 2.01a14 (i686-pc-linux-gnu) Copyright (C) 1995-2003 Jörg Schilling
scsidev: '/dev/hdc'
devname: '/dev/hdc'
scsibus: -2 target: -2 lun: -2
Warning: Open by 'devname' is unintentional and not supported.
Linux sg driver version: 3.5.27
Using libscg version 'schily-0.7'
Device type : Removable CD-ROM
Version : 0
Response Format: 1
Vendor_info : 'Polaroid'
Identifikation : 'BurnMAX48 '
Revision : '482E'
Device seems to be: Generic mmc CD-RW.
Using generic SCSI-3/mmc CD-R/CD-RW driver (mmc_cdr).
Driver flags : MMC-2 SWABAUDIO BURNFREE
Supported modes: TAO PACKET SAO SAO/R96P SAO/R96R RAW/R16 RAW/R96P RAW/R96R

Can I do anything else?

Ulisses

Debian GNU/Linux: a dream come true
-----------------------------------------------------------------------------
"Computers are useless. They can only give answers." Pablo Picasso

---> Visita http://www.valux.org/ para saber acerca de la <---
---> Asociación Valenciana de Usuarios de Linux <---