Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 36672 - 2.6 kernel seems to cause cdrecord to hang using ATAPI driver.
Summary: 2.6 kernel seems to cause cdrecord to hang using ATAPI driver.
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High major
Assignee: x86-kernel@gentoo.org (DEPRECATED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-12-28 11:18 UTC by bugs
Modified: 2003-12-29 16:26 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bugs 2003-12-28 11:18:51 UTC
Tried with cdrtools 2.01_alpha20 and 2.01_alpha14
Both worked with 2.4
When I tried running k3b, it clearly was being stupid.  Odd, since it had worked before.

System
-----------------------
K3b Version: 0.10.3
KDE Version: 3.1.4
QT Version:  3.2.3

cdrecord
-----------------------
/usr/bin/cdrecord: Operation not permitted. WARNING: Cannot do mlockall(2).
/usr/bin/cdrecord: WARNING: This causes a high risk for buffer underruns.
/usr/bin/cdrecord: Operation not permitted. WARNING: Cannot set RR-scheduler
/usr/bin/cdrecord: Permission denied. WARNING: Cannot set priority using setpriority().
/usr/bin/cdrecord: WARNING: This causes a high risk for buffer underruns.
scsidev: '/dev/ide/host0/bus1/target1/lun0/cd'
devname: '/dev/ide/host0/bus1/target1/lun0/cd'
scsibus: -2 target: -2 lun: -2
Warning: Open by 'devname' is unintentional and not supported.
Linux sg driver version: 3.5.27
SCSI buffer size: 64512
Cdrecord-Clone 2.01a19 (i686-pc-linux-gnu) Copyright (C) 1995-2003 J
Comment 1 bugs 2003-12-28 11:18:51 UTC
Tried with cdrtools 2.01_alpha20 and 2.01_alpha14
Both worked with 2.4
When I tried running k3b, it clearly was being stupid.  Odd, since it had worked before.

System
-----------------------
K3b Version: 0.10.3
KDE Version: 3.1.4
QT Version:  3.2.3

cdrecord
-----------------------
/usr/bin/cdrecord: Operation not permitted. WARNING: Cannot do mlockall(2).
/usr/bin/cdrecord: WARNING: This causes a high risk for buffer underruns.
/usr/bin/cdrecord: Operation not permitted. WARNING: Cannot set RR-scheduler
/usr/bin/cdrecord: Permission denied. WARNING: Cannot set priority using setpriority().
/usr/bin/cdrecord: WARNING: This causes a high risk for buffer underruns.
scsidev: '/dev/ide/host0/bus1/target1/lun0/cd'
devname: '/dev/ide/host0/bus1/target1/lun0/cd'
scsibus: -2 target: -2 lun: -2
Warning: Open by 'devname' is unintentional and not supported.
Linux sg driver version: 3.5.27
SCSI buffer size: 64512
Cdrecord-Clone 2.01a19 (i686-pc-linux-gnu) Copyright (C) 1995-2003 Jörg Schilling
TOC Type: 1 = CD-ROM
Using libscg version 'schily-0.7'
atapi: 1
Device type    : Removable CD-ROM
Version        : 0
Response Format: 1
Vendor_info    : 'CDWriter'
Identifikation : 'IDE128          '
Revision       : '1.04'
Device seems to be: Generic mmc CD-RW.
Using generic SCSI-3/mmc   CD-R/CD-RW driver (mmc_cdr).
Driver flags   : MMC SWABAUDIO 
Supported modes: TAO PACKET SAO SAO/R96R RAW/R16 RAW/R96R
Drive buf size : 1359872 = 1328 KB
FIFO size      : 4194304 = 4096 KB
/usr/bin/cdrecord: Success. read disk info: scsi sendcmd: no error
CDB:  51 00 00 00 00 00 00 00 04 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 02 00 00 00 00 0A 00 00 00 00 04 01 00 00
Sense Key: 0x2 Not Ready, Segment 0
Sense Code: 0x04 Qual 0x01 (logical unit is in process of becoming ready) Fru 0x0
Sense flags: Blk 0 (not valid) 
resid: 4
cmd finished after 0.002s timeout 240s
/usr/bin/cdrecord: Cannot get disk type.
/usr/bin/cdrecord: Success. prevent/allow medium removal: scsi sendcmd: no error
CDB:  1E 00 00 00 00 00
status: 0x2 (CHECK CONDITION)
Sense Bytes: 70 00 02 00 00 00 00 0A 00 00 00 00 04 01 00 00
Sense Key: 0x2 Not Ready, Segment 0
Sense Code: 0x04 Qual 0x01 (logical unit is in process of becoming ready) Fru 0x0
Sense flags: Blk 0 (not valid) 
cmd finished after 0.002s timeout 200s
Track 01: data   699 MB        
Total size:      803 MB (79:38.18) = 358364 sectors
Lout start:      804 MB (79:40/14) = 358364 sectors
Current Secsize: 2048

cdrecord comand:
-----------------------
/usr/bin/cdrecord -v gracetime=2 dev=/dev/ide/host0/bus1/target1/lun0/cd speed=8 -dao -data /home/nemo/ISO/KNOPPIX_V3.3-2003-11-19-EN.iso 


So I corrected on the commandline.

/usr/bin/cdrecord -v gracetime=2 dev=ATAPI:/dev/hdd speed=8 -dao -data /home/nemo/ISO/KNOPPIX_V3.3-2003-11-19-EN.iso
This had better results in terms of invoking the right driver, but process hung completely.
Cdrecord-Clone 2.01a19 (i686-pc-linux-gnu) Copyright (C) 1995-2003 Jörg Schilling
TOC Type: 1 = CD-ROM
scsidev: 'ATAPI:/dev/hdd'
devname: 'ATAPI:/dev/hdd'
scsibus: -2 target: -2 lun: -2
Warning: Using ATA Packet interface.
Warning: The related libscg interface code is in pre alpha.
Warning: There may be fatal problems.
Using libscg version 'schily-0.7'
SCSI buffer size: 64512
atapi: 1
Device type    : Removable CD-ROM
Version        : 0
Response Format: 1
Vendor_info    : 'CDWriter'
Identifikation : 'IDE128          '
Revision       : '1.04'
Device seems to be: Generic mmc CD-RW.
Using generic SCSI-3/mmc   CD-R/CD-RW driver (mmc_cdr).
Driver flags   : MMC SWABAUDIO
Supported modes: TAO PACKET SAO SAO/R96R RAW/R16 RAW/R96R
Drive buf size : 1359872 = 1328 KB
FIFO size      : 4194304 = 4096 KB
Track 01: data   699 MB
Total size:      803 MB (79:38.18) = 358364 sectors
Lout start:      804 MB (79:40/14) = 358364 sectors
Current Secsize: 2048

Process is in uninterruptible I/O sleep (I really hate that sleep).  Will have to reboot to get the drive back as right now anything I try to do to it becomes a process tarpit.

People on #gentoo claim they are using ATAPI burning fine with 2.6 - is this in fact possible?


Reproducible: Always
Steps to Reproduce:
1. /usr/bin/cdrecord -v gracetime=2 dev=ATAPI:/dev/hdd speed=8 -dao -data /home/nemo/ISO/KNOPPIX_V3.3-2003-11-19-EN.iso
2. wait
3. goto 2.

Actual Results:  
nothing

Expected Results:  
burned a CD
Comment 2 SpanKY gentoo-dev 2003-12-28 11:21:55 UTC
works fine here :x
Comment 3 bugs 2003-12-28 11:54:30 UTC
Update.  It *finally* timed out.  Wasn't an infinite sleep after all.
Just a good half hour.
...
Supported modes: TAO PACKET SAO SAO/R96R RAW/R16 RAW/R96R
Drive buf size : 1359872 = 1328 KB
FIFO size      : 4194304 = 4096 KB
Track 01: data   699 MB
Total size:      803 MB (79:38.18) = 358364 sectors
Lout start:      804 MB (79:40/14) = 358364 sectors
Current Secsize: 2048
/usr/bin/cdrecord: Input/output error. read disk info: scsi sendcmd: retryable error
CDB:  51 00 00 00 00 00 00 00 04 00
status: 0xa (Reserved)
Sense Bytes: 70 00 02 00 00 00 00 0A 00 00 00 00 04 01 00 00 00 00
Sense Key: 0x2 Not Ready, Segment 0
Sense Code: 0x04 Qual 0x01 (logical unit is in process of becoming ready) Fru 0x0
Sense flags: Blk 0 (not valid)
cmd finished after 0.002s timeout 240s
/usr/bin/cdrecord: Cannot get disk type.
/usr/bin/cdrecord: Input/output error. prevent/allow medium removal: scsi sendcmd: retryable error
CDB:  1E 00 00 00 00 00
status: 0xa (Reserved)
Sense Bytes: 70 00 02 00 00 00 00 0A 00 00 00 00 04 01 00 00 00 00
Sense Key: 0x2 Not Ready, Segment 0
Sense Code: 0x04 Qual 0x01 (logical unit is in process of becoming ready) Fru 0x0
Sense flags: Blk 0 (not valid)
cmd finished after 0.002s timeout 200s

Drive is a CDWriter model.  What's with all this SCSI stuff in ATAPI mode?
Comment 4 Tim Yamin (RETIRED) gentoo-dev 2003-12-28 15:09:15 UTC
Those ATAPI libraries are not kernel based, and are from cdrecord or some library used by it. They're flagged as "not recommended" and "pre-alpha" the last time I checked. The reason you see SCSI stuff is because those libraries get a SCSI interface over ATAPI: and it doesn't seem to be working that well :-/

Can I suggest trying it using IDE-SCSI emulation and see whether you get the same result? If it works fine, i.e. you can burn without needing any dev:atapi lines with IDE-SCSI emulation, this is an upstream bug for cdrtools.
Comment 5 bugs 2003-12-28 22:51:28 UTC
Well, thing is I *know* my crappy drive doesn't work with IDE-SCSI
Reason being IDE-SCSI does not allow DMA.
Drive breaks without DMA.  However, when I used 2.4 kernel, cdrtools did in fact work with ATAPI interface.  That is what puzzles me.  I will try falling back to 2.4 kernel and seeing if things still work.  I don't know about the dependancy on kernel interfaces, but that's how it seems to me at the moment.

2.4, IDE-SCSI, broken.
2.4, ATAPI, worked
2.6, ATAPI, broken
Comment 6 bugs 2003-12-29 16:26:12 UTC
Marking bug invalid since whatever it is, it ain't 2.6.
Just tried again, just for kicks, with 2.6 still.
Worked fine.
I suspect if it is anything, it is my cheap drive having gotten itself in some confused state.
Possibly due to K3b trying to treat it as a SCSI drive.
Possibly.

Sorry for the kernel accusations x86-kernel folks!