Bug#265747: more info on hangs with Cyberdrive and VIA chipset.

2006-04-08 Thread Joerg Schilling
This is definitely a Linux Kernel bug!

It is obvious that a ioctl() that hangs (does not return) although
it has been given a timeout is the evidence for a kernel bug.


Jörg

-- 
 EMail:[EMAIL PROTECTED] (home) Jörg Schilling D-13353 Berlin
   [EMAIL PROTECTED](uni)  
   [EMAIL PROTECTED] (work) Blog: http://schily.blogspot.com/
 URL:  http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily



Bug#265747: more info on hangs with Cyberdrive and VIA chipset.

2005-12-04 Thread Ivan Baldo

   Hello.
   I disabled the rezero_unit but didn't change anything, I reenabled 
it and disabled the get_dmaspeed.

   This time I can write from the command line and from XCDRoast too!
   Maybe the get_dmaspeed makes this drives go crazy, it would be nice 
to have a way to disable it in runtime, without needing to recompile 
cdrecord.
   Or maybe just disable it by default... I wonder why it is useful 
nowadays since drives have underrun protections.
   I have a cdrecord package with the get_dmaspeed thing disabled, if 
someone doesn't want to recompile the package I can send the .deb (just 
dpkg -i it).
   Please, can someone else test without the get_dmaspeed thing to see 
if it fixes its problems and post results (either succesful or not)? If 
I am not the only one then some solution could be considered...

   Thanks for your times!
   Goodbye.



diff -urN cdrtools-2.01.01.antescambios/cdrecord/cdrecord.c 
cdrtools-2.01.01/cdrecord/cdrecord.c
--- cdrtools-2.01.01.antescambios/cdrecord/cdrecord.c   2004-10-17 
09:44:58.0 -0200
+++ cdrtools-2.01.01/cdrecord/cdrecord.c2005-09-02 
11:45:35.0 -0300

@@ -3969,6 +3969,7 @@
   int bs;
   int tsize;

+   return (-1); //FIXME: Ivan.
   fillbytes((caddr_t)buf, 4, '\0');
   tsize = 0;
   scgp->silent++;

   That is at the start of the get_dmaspeed() function, effectively 
disabling it.




--- cdrtools-2.01.01/cdrecord/cdrecord.c.orig2005-10-14 
14:58:58.0 +0200
+++ cdrtools-2.01.01/cdrecord/cdrecord.c2005-10-14 
14:59:25.0 +0200

@@ -3880,7 +3880,7 @@ load_media(scgp, dp, doexit)
scsi_start_stop_unit(scgp, 1, 0, immed);
wait_unit_ready(scgp, 120);
scgp->silent++;
-rezero_unit(scgp);/* Is this needed? Not supported by some 
drvives */
+/*rezero_unit(scgp);*//* Is this needed? Not supported by 
some drvives */

scgp->silent--;
test_unit_ready(scgp);
scsi_start_stop_unit(scgp, 1, 0, immed);

   It is from Michal Schmidt <[EMAIL PROTECTED]> in a post 
to <[EMAIL PROTECTED]>.




--
Ivan Baldo - [EMAIL PROTECTED] - http://ibaldo.codigolibre.net/
ICQ 10215364 - Phone/FAX (598) (2) 613 3223.
Caldas 1781, Malvin, Montevideo, Uruguay, South America, planet Earth.
In favour of world peace and freedom, against U.S.A. and allies!!!
Alternatives: [EMAIL PROTECTED] - http://go.to/ibaldo




--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#265747: more info on hangs with Cyberdrive and VIA chipset.

2005-12-03 Thread Ivan Baldo

   Hello Alban!

El 03/12/05 16:23, Alban BROWAEYS escribió:


Could you tell if windows have disabled dma
automatically ?

 

   It always writes at Ultra DMA mode 2, I looked before starting Nero 
and while Nero was writing; also the performance is very smooth and I 
don't think such good performance could be achieved without DMA (though 
this is subjective).




PS: you could try latest >= 2.6.14-rc3* kernels if
your are easy with compiling a the kernel.
 

   Yesterday I have compiled 2.6.14.3 and I am with Debian Testing up 
to date, it still doesn't work :-(.
   Some time ago I remember I recompiled the cdrtools package with a 
small change someone proposed here and I was able to write CDs from the 
command line, but my old friend XCDRoast didn't work yet and I miss it, 
snif...


diff -urN cdrtools-2.01.01.antescambios/cdrecord/cdrecord.c 
cdrtools-2.01.01/cdrecord/cdrecord.c
--- cdrtools-2.01.01.antescambios/cdrecord/cdrecord.c   2004-10-17 
09:44:58.0 -0200
+++ cdrtools-2.01.01/cdrecord/cdrecord.c2005-09-02 
11:45:35.0 -0300

@@ -3969,6 +3969,7 @@
   int bs;
   int tsize;

+   return (-1); //FIXME: Ivan.
   fillbytes((caddr_t)buf, 4, '\0');
   tsize = 0;
   scgp->silent++;

   That is at the start of the get_dmaspeed() function, effectively 
disabling it.


   Here is the output of my new test with cdrtools unmodified from 
Debian Testing and kernel 2.6.14.3:

[EMAIL PROTECTED]:~$ cdrecord -v blank=fast gracetime=2
Cdrecord-Clone 2.01.01a03 (i686-pc-linux-gnu) Copyright (C) 1995-2005 
Joerg Schilling
NOTE: this version of cdrecord is an inofficial (modified) release of 
cdrecord

 and thus may have bugs that are not present in the original version.
 Please send bug reports and support requests to 
<[EMAIL PROTECTED]>.
 The original author should not be bothered with problems of this 
version.


cdrecord: Warning: Running on Linux-2.6.14.3
cdrecord: There are unsettled issues with Linux-2.5 and newer.
cdrecord: If you have unexpected problems, please try Linux-2.4 or Solaris.
TOC Type: 1 = CD-ROM
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 'ubuntu-0.8ubuntu1'.
cdrecord: Warning: using inofficial version of libscg (ubuntu-0.8ubuntu1 
'@(#)scsitransp.c  1.91 04/06/17 Copyright 1988,1995,2000-2004 J. 
Schilling').

Driveropts: 'burnfree'
SCSI buffer size: 64512
atapi: 1
Device type: Removable CD-ROM
Version: 0
Response Format: 1
Vendor_info: 'CyberDrv'
Identifikation : 'CW078D CD-R/RW  '
Revision   : '140D'
Device seems to be: Generic mmc CD-RW.
Current: 0x000A
Profile: 0x000A (current)
Profile: 0x0009
Profile: 0x0008
Profile: 0x0002 (current)
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
Drive buf size : 1806336 = 1764 KB
Drive DMA Speed: 268800 kB/s 1527x CD 194x DVD
Current Secsize: 2048
ATIP info from disk:
 Indicated writing power: 3
 Reference speed: 6
 Is not unrestricted
 Is erasable
 Disk sub type: High speed Rewritable (CAV) media (1)
 ATIP start of lead in:  -11745 (97:25/30)
 ATIP start of lead out: 359848 (79:59/73)
 1T speed low:  4 1T speed high: 10
 2T speed low:  4 2T speed high:  6
 power mult factor: 1 5
 recommended erase/write power: 5
 A1 values: 24 1A D0
 A2 values: 23 B1 45
Disk type:Phase change
Manuf. index: 40
Manufacturer: INFODISC Technology Co., Ltd.
Starting to write CD/DVD at speed 12 in real BLANK mode for single session.
Last chance to quit, starting real write0 seconds. Operation starts.
Performing OPC...
Blanking PMA, TOC, pregap
Blanking time:   23.069s

(yes, it worked nicely)

[EMAIL PROTECTED]:~$ mkisofs -rvJ 
/mnt/f/reponorepli/respaldo.lily.2005-09-10.tar.bz2 | cdrecord -v 
gracetime=2 -data -

INFO:   ISO-8859-1 character encoding detected by locale settings.
   Assuming ISO-8859-1 encoded filenames on source filesystem,
   use -input-charset to override.
cdrecord: No write mode specified.
cdrecord: Asuming -tao mode.
cdrecord: Future versions of cdrecord may have different drive dependent 
defaults.

cdrecord: Continuing in 5 seconds...
mkisofs 2.01.01a03-unofficial-iconv (i686-pc-linux-gnu)
Writing:   Initial PadblockStart Block 0
Done with: Initial PadblockBlock(s)16
Writing:   Primary Volume Descriptor   Start Block 16
Done with: Primary Volume Descriptor   Block(s)1
Writing:   Joliet Volume DescriptorStart Block 17
Done with: Joliet Volume DescriptorBlock(s)1
Writing:   End Volume Descriptor   Start Block 18
Done with: End Volume Descriptor   Block(s)1
Writing:   Version block   Start Block 19
Done with: Vers

Bug#265747: more info on hangs with Cyberdrive and VIA chipset.

2005-12-03 Thread Alban BROWAEYS
>I hate to report that Windows XP with Nero works
without problems, 
>but is not my favorite OS.

Could you tell if windows have disabled dma
automatically ?

Once you know the "ide controller" your cdrom is bound
to (see the note at the end of the mail):

- open Device Manager > IDE ATA/ATAPI Controller,
select the wanted controller.
- open its "properties" window and switch to "advanced
settings" tab.
There you have two "device data" group (0 and 1). I do
not know how to find which one related to the cdrom
(here I only have the cdrom on the "secondary ide
channel" so it is the entry with a "current transfer
mode").

please gives us the "current transfert mode". I have
"ultra DMA mode 2" here (only as reference, the bug
does not show up on this box). This means DMA is
enabled. 

Greetings.
Alban

PS: you could try latest >= 2.6.14-rc3* kernels if
your are easy with compiling a the kernel.
 The reimplementation of the "IDE" code is mostly
complete nows (this is/was the biggest remaining "not
so good" code in linux).
I do not have access to the box I own which have the
"broken" cdwriter before monthes. 

I highly expect your results (even if only the windows
behaviour - disabling the dma or relying on via to
provide a driver with an unknown trick to work well
even with the hardware behaving badly).


---

"HOWTO find the IDE Controller the cdrom is bound" 
... to without opening the box and knowing about pc
internals.

- linux : if your cdrom is on the first ide connector
it is bound tohda or hdb 
- windows :
Device Manager > IDE ATA/ATAPI Controller 
the open "properties" window for each IDE controller
and switch to "details" tab. In the list choose "Bus
relations" and you will see a name.
This name is in "device manager" cdrom list.











___ 
Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger 
Téléchargez cette version sur http://fr.messenger.yahoo.com


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#265747: more info on hangs with Cyberdrive and VIA chipset.

2005-09-01 Thread Ivan Baldo
Package: cdrecord
Version: 4:2.01+01a01-4
Followup-For: Bug #265747

I was going to write the following bug report and I found this one that seems
the same, but I still submit my information, maybe it helps.

Cdrecord-Clone 2.01.01a01
Linux 2.6.12.5
Debian Testing of 1 september 2005.

Cdrecord freezes, I can't write CDs.
I tried diferent transports: ATA, ATAPI, /dev/hdc, and even ide-scsi, they all
freeze.
I hate to report that Windows XP with Nero works without problems, but is not
my favorite OS.
I tried Knoppix 3.6 too, both with 2.4 and 2.6 kernels and it doesn't work
too, the Debian package kernel-image-2.6.8-2-k7 version 2.6.8-16 doesn't work
neither.
I want to be as helpful to you as I can, so tell me what to do and I will do
it, I appreciate your help.
I use Linux since 1996 and I never had problems with CD writing.
The same CD Writer works on my old computer, I buyed a new one but keeped my
old CD Writer.
Yes, I know that I don't have the best brands of hardware, but they are more
expensive and I live in the 3rd. world, though it works on Windows so hopefuly
it could work on Linux.

The kernel complains in multiple ways, sometimes it simply says several times:
hdc: lost interrupt

and other times it says all this:

hdc: drive_cmd: status=0x51 { DriveReady SeekComplete Error }
hdc: drive_cmd: error=0x04 { AbortedCommand }
ide: failed opcode was: 0xec
hdc: status timeout: status=0xd0 { Busy }
ide: failed opcode was: unknown
hdc: DMA disabled
hdc: drive not ready for command
hdc: ATAPI reset complete
hdc: request sense failure: status=0x51 { DriveReady SeekComplete Error }
hdc: request sense failure: error=0x50 { LastFailedSense=0x05 }


With any type of media (CD-R or CD-RW):
# cdrecord -v dev=ATA:1,0,0 -atip 
Cdrecord-Clone 2.01.01a01 (i686-pc-linux-gnu) Copyright (C) 1995-2004 Joerg 
Schilling
NOTE: this version of cdrecord is an inofficial (modified) release of cdrecord
  and thus may have bugs that are not present in the original version.
  Please send bug reports and support requests to <[EMAIL PROTECTED]>.
  The original author should not be bothered with problems of this version.

cdrecord: Warning: Running on Linux-2.6.12.5
cdrecord: There are unsettled issues with Linux-2.5 and newer.
cdrecord: If you have unexpected problems, please try Linux-2.4 or Solaris.
TOC Type: 1 = CD-ROM
scsidev: 'ATA:1,0,0'
devname: 'ATA'
scsibus: 1 target: 0 lun: 0
Warning: Using badly designed ATAPI via /dev/hd* interface.
Linux sg driver version: 3.5.27
Using libscg version 'ubuntu-0.8ubuntu1'.
cdrecord: Warning: using inofficial version of libscg (ubuntu-0.8ubuntu1 
'@(#)scsitransp.c  1.91 04/06/17 Copyright 1988,1995,2000-2004 J. 
Schilling').
SCSI buffer size: 64512
atapi: -1
Device type: Removable CD-ROM
Version: 0
Response Format: 1
Vendor_info: 'CyberDrv'
Identifikation : 'CW078D CD-R/RW  '
Revision   : '140D'
Device seems to be: Generic mmc CD-RW.
Current: 0x000A
Profile: 0x000A (current)
Profile: 0x0009 
Profile: 0x0008 
Profile: 0x0002 (current)
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
Drive buf size : 1806336 = 1764 KB


The motherboard is an Asrock K7VT6.

:00:0f.1 IDE interface: VIA Technologies, Inc. 
VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06) (prog-if 8a 
[Master SecP PriP])
Subsystem: ASRock Incorporation K7VT2 motherboard
Flags: bus master, medium devsel, latency 32, IRQ 169
I/O ports at fc00 [size=16]
Capabilities: [c0] Power Management version 2

--VIA BusMastering IDE Configuration
Driver Version: 3.38
South Bridge:   VIA vt8237
Revision:   ISA 0x0 IDE 0x6
Highest DMA rate:   UDMA133
BM-DMA base:0xfc00
PCI clock:  33.3MHz
Master Read  Cycle IRDY:0ws
Master Write Cycle IRDY:0ws
BM IDE Status Register Read Retry:  yes
Max DRDY Pulse Width:   No limit
---Primary IDE---Secondary IDE--
Read DMA FIFO flush:  yes yes
End Sector FIFO flush: no  no
Prefetch Buffer:  yes yes
Post Write Buffer:yes yes
Enabled:  yes yes
Simplex only:  no  no
Cable Type:   80w 80w
---drive0drive1drive2drive3-
Transfer Mode:   UDMA   PIO  UDMA   DMA
Address Setup:  120ns 120ns 120ns 120ns
Cmd Active:  90ns  90ns  90ns  90ns
Cmd Recovery:30ns  30ns  30ns  30ns
Data Active: 90ns 330ns  90ns  90ns
Data Recovery:   30ns 270ns  30ns  30ns
Cycle Time: